diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/.distignore b/wp-content/upgrade-temp-backup/plugins/activitypub/.distignore index 782f2e88..871e8074 100644 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/.distignore +++ b/wp-content/upgrade-temp-backup/plugins/activitypub/.distignore @@ -15,6 +15,8 @@ Makefile README.md readme.md CODE_OF_CONDUCT.md +FEDERATION.md +SECURITY.md LICENSE.md _site _config.yml @@ -36,3 +38,4 @@ phpunit.xml.dist tests node_modules vendor +src diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/LICENSE b/wp-content/upgrade-temp-backup/plugins/activitypub/LICENSE index e59f0cc6..644800f2 100644 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/LICENSE +++ b/wp-content/upgrade-temp-backup/plugins/activitypub/LICENSE @@ -1,6 +1,7 @@ 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 diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/activitypub.php b/wp-content/upgrade-temp-backup/plugins/activitypub/activitypub.php index 7320f0c6..521a3795 100644 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/activitypub.php +++ b/wp-content/upgrade-temp-backup/plugins/activitypub/activitypub.php @@ -3,7 +3,7 @@ * Plugin Name: ActivityPub * Plugin URI: https://github.com/pfefferle/wordpress-activitypub/ * Description: The ActivityPub protocol is a decentralized social networking protocol based upon the ActivityStreams 2.0 data format. - * Version: 0.17.0 + * Version: 1.0.7 * Author: Matthias Pfefferle & Automattic * Author URI: https://automattic.com/ * License: MIT @@ -15,85 +15,124 @@ namespace Activitypub; +use function Activitypub\is_blog_public; +use function Activitypub\site_supports_blocks; + +require_once __DIR__ . '/includes/compat.php'; +require_once __DIR__ . '/includes/functions.php'; + /** - * Initialize plugin + * Initialize the plugin constants. */ -function init() { - \defined( 'ACTIVITYPUB_EXCERPT_LENGTH' ) || \define( 'ACTIVITYPUB_EXCERPT_LENGTH', 400 ); - \defined( 'ACTIVITYPUB_MAX_IMAGE_ATTACHMENTS' ) || \define( 'ACTIVITYPUB_MAX_IMAGE_ATTACHMENTS', 3 ); - \defined( 'ACTIVITYPUB_HASHTAGS_REGEXP' ) || \define( 'ACTIVITYPUB_HASHTAGS_REGEXP', '(?:(?<=\s)|(?<=

)|(?<=
)|^)#([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_ALLOWED_HTML' ) || \define( 'ACTIVITYPUB_ALLOWED_HTML', '

",{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 5738848a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/functions.php +++ /dev/null @@ -1,1356 +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' ); - - $microdata = ' itemtype="https://schema.org/SiteNavigationElement" itemscope="itemscope"'; - - if ( function_exists( 'generate_get_schema_type' ) && 'microdata' !== generate_get_schema_type() ) { - $microdata = ''; - } - ?> - - - - '; - 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', - ); - } - - /** - * 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 2f8e9284..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/class-site-library-rest.php +++ /dev/null @@ -1,922 +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(); - - $data = wp_safe_remote_get( 'https://gpsites.co/wp-json/wp/v2/sites?per_page=100' ); - - 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' ) ); - - // 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 ); - - 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 e29438c6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/class-site-library.php +++ /dev/null @@ -1,412 +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' : '', - ); - - 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 bb3462da..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/css/woocommerce-mobile.css +++ /dev/null @@ -1,201 +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 { - -ms-grid-columns: 1fr; - 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 { - -ms-grid-columns: 1fr 1fr; - 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 { - -ms-grid-columns: 1fr 1fr 1fr; - 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 489a04fd..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{-ms-grid-columns:1fr;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{-ms-grid-columns:1fr 1fr;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{-ms-grid-columns:1fr 1fr 1fr;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 a7eb7ad8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/css/woocommerce.css +++ /dev/null @@ -1,1284 +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: -ms-grid; - 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 4533dae1..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:-ms-grid;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 7451494a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/functions.php +++ /dev/null @@ -1,1532 +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' ); - $css->add_property( 'color', esc_attr( $settings['form_button_text_color'] ) ); - $css->add_property( 'background-color', esc_attr( $settings['form_button_background_color'] ) ); - - 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'] : 'px'; - - if ( ! empty( $data['fontSize'] ) ) { - $css->add_property( 'font-size', floatval( $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' ) ); - $css->add_property( 'font-size', floatval( $data['fontSizeTablet'] ), false, $unit ); - $css->stop_media_query(); - } - - if ( ! empty( $data['fontSizeMobile'] ) ) { - $css->start_media_query( generate_premium_get_media_query( 'mobile' ) ); - $css->add_property( 'font-size', floatval( $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' ); - $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'] ) ); - - // 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 e3af57e1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/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). - -## 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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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/images/in-progress-db145d62b5ef09c05ad7.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/images/in-progress-db145d62b5ef09c05ad7.png deleted file mode 100644 index 21176718..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/images/in-progress-db145d62b5ef09c05ad7.png and /dev/null differ 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 e9339e55..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('moment', 'react', 'wp-api-fetch', 'wp-components', 'wp-compose', 'wp-data', 'wp-date', 'wp-element', 'wp-i18n', 'wp-polyfill', 'wp-primitives', 'wp-url'), 'version' => 'f5a19d5afbdcef2dfd58'); 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 f397a746..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.css +++ /dev/null @@ -1 +0,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{fill:var(--jp-gray);flex-shrink:0;margin:0 var(--spacing-base)}.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)}.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)}: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-10:#f2cf75;--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-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}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{grid-gap:24px;display:grid;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 .components-popover__content{border:1px solid var(--jp-gray);border-radius:4px;outline:none;padding:24px;white-space:normal;width:304px}.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-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}.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.5px;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.5px 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)}.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)}.terms-of-service{color:var(--jp-black);font-size:var(--font-body)}.terms-of-service .terms-of-service__link{color:var(--jp-green-50)}.dovianZYLKhnbnh9I06o{align-items:flex-start;display:flex;flex-wrap:wrap;justify-content:flex-end}.lljtQMhW7lq5tE5SDJEf{flex-basis:0;flex-grow:2}.dhFQXpZfMwVI8vuYHnwC{align-items:flex-start;display:inline-flex;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}.UL3B1tQ854mN7r6taB61{align-items:center;display:flex;flex-wrap:wrap;justify-content:space-between}.IG56Hw7ZR_7rKVsM78qw:focus:not(:disabled){box-shadow:none}.sexr0jUxC1jVixdKiDnC{margin-left:-20px}@media(max-width:782px){.sexr0jUxC1jVixdKiDnC{margin-left:-10px}}.sexr0jUxC1jVixdKiDnC.vKQ11sLeAM45M04P1ccj{background-color:var(--jp-white)}.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}}.jp-dashboard-footer{align-items:center;color:#000;display:flex;flex-flow:row wrap;justify-content:space-between;max-width:1128px;width:100%}.jp-dashboard-footer a,.jp-dashboard-footer a:hover,.jp-dashboard-footer a:visited{color:#000;text-decoration:none}.jp-dashboard-footer__jetpack-symbol,.jp-dashboard-footer__module-name{display:inline-block;vertical-align:middle}.jp-dashboard-footer__module-name{font-size:12px;font-weight:600;margin-left:5px}.vMa4i_Dza2t5Zi_Bw9Nf{background:var(--jp-white-off)}.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)}.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}.uQlXhcfYn9tbnK27_Gct{align-items:center;display:flex}.uQlXhcfYn9tbnK27_Gct input[type=checkbox]:checked{background:var(--jp-green-40);border-color:var(--jp-green-40)}.uQlXhcfYn9tbnK27_Gct input[type=checkbox]:indeterminate{background:var(--jp-green-40);border-color:var(--jp-green-40)}.uQlXhcfYn9tbnK27_Gct input[type=checkbox]:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px var(--jp-green-40)}.PO9zDOaSkcv_RqpfZF_v,.e5YHJiYcvfgdEEJsS_YM{margin-bottom:calc(var(--spacing-base)*7);margin-top:calc(var(--spacing-base)*7)}@media(max-width:599px){.PO9zDOaSkcv_RqpfZF_v{margin-top:0}}.gTWkHo5lqwE_OCesAhBx{color:var(--jp-gray-50)}.gTWkHo5lqwE_OCesAhBx:before{background:var(--jp-gray-50);border-radius:50%;content:"";display:inline-block;height:8px;margin-right:var(--spacing-base);width:8px}.gTWkHo5lqwE_OCesAhBx.JeLxNe31ii68Utrr2xr6{color:var(--jp-green-40)}.gTWkHo5lqwE_OCesAhBx.JeLxNe31ii68Utrr2xr6:before{background:var(--jp-green-40)}svg.V6B8ltQ7TH3UKzUC_qy1{color:var(--jp-black);height:32px;margin:0;width:32px}.C9hcvYAbgHPhN2Tl22xg{align-items:center;display:flex;flex-wrap:wrap;justify-content:flex-start}.C9hcvYAbgHPhN2Tl22xg .XkbIpr2gzB4XEhHgzkY4{margin-right:calc(var(--spacing-base)/2)}.BfcZn0_X33Ajdd1Gl18G{display:flex}.BfcZn0_X33Ajdd1Gl18G>.rBmVJIeTNpd0RJWaRGuJ{fill:var(--jp-gray-20);display:flex;margin-left:calc(var(--spacing-base)/2)}.jVq5444f1Xh6nNkz0Qe_{margin-top:calc(var(--spacing-base)*4)}.amF9cOnMiv2nHbkMXQiQ{align-items:center;display:flex;flex-wrap:wrap;justify-content:space-between}.FodE_7RbLD8zeBSd6eVR{display:flex;flex-wrap:wrap;margin-left:auto}.FodE_7RbLD8zeBSd6eVR>:first-child{margin-right:calc(var(--spacing-base)*3)}.twyPhW_K164HITnDrwEg{padding:calc(var(--spacing-base)*2);width:250px}.tbcd9xc_TjcFdokOt3F_{font-size:18px}@media(max-width:599px){.pnoqLV3l30xuvj2hLlJc{width:90%}.FodE_7RbLD8zeBSd6eVR{margin-top:calc(var(--spacing-base)*3)}.FodE_7RbLD8zeBSd6eVR>:first-child{margin-bottom:var(--spacing-base);margin-right:0}}.IunwKwdvL271DxBIniPb[type=checkbox]{display:none}.svA9WxEcOByd5S2fZonA{border:2px solid var(--jp-black);border-radius:100px;box-sizing:border-box;cursor:pointer;display:inline-block;height:24px;outline:0;padding:2px;position:relative;transition:all .4s ease,box-shadow 0s;vertical-align:middle;width:48px}.svA9WxEcOByd5S2fZonA:after{background:var(--jp-black);border-radius:50%;content:"";display:block;height:16px;left:0;position:relative;transition:all .2s ease;width:16px}.IunwKwdvL271DxBIniPb:checked+.svA9WxEcOByd5S2fZonA:after{left:22px}.IunwKwdvL271DxBIniPb:checked:disabled+.svA9WxEcOByd5S2fZonA{background-color:var(--jp-black);border-color:var(--jp-black)}.IunwKwdvL271DxBIniPb:checked:disabled+.svA9WxEcOByd5S2fZonA:after{background-color:var(--jp-white)}.IunwKwdvL271DxBIniPb:checked:not(:disabled)+.svA9WxEcOByd5S2fZonA{background-color:var(--jp-green);border-color:var(--jp-green)}.IunwKwdvL271DxBIniPb:checked:not(:disabled)+.svA9WxEcOByd5S2fZonA:after{background-color:var(--jp-white)}.IunwKwdvL271DxBIniPb:disabled+span.svA9WxEcOByd5S2fZonA{cursor:default;opacity:.25}.IunwKwdvL271DxBIniPb.wOd7DeP76v1fczKfah5n+.svA9WxEcOByd5S2fZonA{border-radius:8px;height:16px;width:24px}.IunwKwdvL271DxBIniPb.wOd7DeP76v1fczKfah5n+.svA9WxEcOByd5S2fZonA:after{height:12px;width:12px}.IunwKwdvL271DxBIniPb.wOd7DeP76v1fczKfah5n:checked+.svA9WxEcOByd5S2fZonA:after{left:8px}._aiMxmJRAw5jRPbZFX57{background-color:var(--jp-gray-90);border-radius:var(--jp-border-radius);color:var(--jp-white);display:flex;overflow:hidden}._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{fill:var(--jp-white);align-items:center;background-color:var(--jp-yellow-30);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:transparent;border:none;cursor:pointer;display:flex;justify-content:center;padding:calc(var(--spacing-base)*1.5)}.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:calc(var(--spacing-base)*2)}.DM4b8iQ0ewvRYdIPxvZ8{max-width:calc(744px + var(--spacing-base)*6);width:100%}.bW6ZuNzJBYU5PVPktE2S{display:flex}.bW6ZuNzJBYU5PVPktE2S:not(:first-child){margin-top:calc(var(--spacing-base)*7)}.di3wjXHrX1rk_H6rlxKM{margin-right:calc(var(--spacing-base)*2);padding-top:calc(var(--spacing-base)/2)}@media(min-width:600px){.di3wjXHrX1rk_H6rlxKM{margin-right:calc(var(--spacing-base)*5)}}.IrzHnNkRvORtyCL0yiWa{width:100%}.sU82bpLEYPC9n_CFAKoz{align-items:center;display:flex}.ZZc0LldcbJpcftqCe43T .IrzHnNkRvORtyCL0yiWa{opacity:.5}.T17WOOJI7XHN7KRmYaCe>:last-child{margin-top:calc(var(--spacing-base)*2)}@media(min-width:600px){.T17WOOJI7XHN7KRmYaCe{display:flex;justify-content:space-between}}.typbjN2keZ97hj2TmuMC{display:flex;flex-wrap:wrap;margin-top:calc(var(--spacing-base)*2)}.UUXAN8VTAZY0h8t9rCHG{color:var(--jp-green-50);margin-right:calc(var(--spacing-base)/2)}.eFjcadLMEXY5O61vsTrx{color:var(--jp-gray-50)}.Tr5uYvclUiwlC5kuGk7E{color:var(--jp-red-50)}.zPZcNgYx2X5778nHHtlH{display:flex;flex-wrap:wrap}.lNtkRXnB1z_kYB28MUWq{color:var(--jp-gray-50)}.JgH5ykcLynEgqXYurT78{margin-right:calc(var(--spacing-base)/2)}.JgH5ykcLynEgqXYurT78,.xlWW0IoKZwTZt1Ti0tcQ{color:var(--jp-green-50)}.zhBcgCUGgyC7PvWk8ewB{margin-top:calc(var(--spacing-base)*3)}@media(min-width:600px){.zhBcgCUGgyC7PvWk8ewB{padding-left:calc(var(--spacing-base)*11)}}.mah_f2OWxZ3Vqt_jRFdR{margin-bottom:calc(var(--spacing-base)*4)}.Ax2SmW57c0U5xOTjZuAA{margin:calc(var(--spacing-base)*-1) calc(var(--spacing-base)*-2)}.xGZeYQr0_nPJTFmd8pW4{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)}.RYTIt8kwLbKcUbWOfG4g{padding:calc(var(--spacing-base)*3);width:304px}.BqXge2rIUP0a_74yvYbr{display:flex;justify-content:space-between}.Lr10UUCcSLF3T_0QqoPr{margin:calc(var(--spacing-base)*-1) calc(var(--spacing-base)*-3)}.Lr10UUCcSLF3T_0QqoPr:focus,.Lr10UUCcSLF3T_0QqoPr:focus:not(:disabled){box-shadow:none}.th_VukMuODIOVLC7oJo6{display:flex;justify-content:flex-end}.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{margin-right:20px}.FGpSkMCiIHQjszcV0dbn,.KoWZcCwhW13xvkEb0QON{height:calc(var(--spacing-base)*3);width:calc(var(--spacing-base)*3)}.KoWZcCwhW13xvkEb0QON{background-color:transparent;border:none;cursor:pointer;outline:none}@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;margin-top:20px}.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)}.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);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}._Wc3apZobag_9Ag_THTb{display:flex;justify-content:space-between}.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 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%}.JiJhrZaThvWCpM2AfGen{border-radius:32px;flex-shrink:0;font-size:12px;font-style:normal;font-weight:600;line-height:16px;padding:calc(var(--spacing-base)/2);position:relative;text-align:center;width:60px}._7SGksgOpcPbHfPPpQTV{background:var(--jp-red-5);color:var(--jp-red-60)}.pGNquShR54adQ61sx3lP{background:var(--jp-yellow-5);color:var(--jp-yellow-60)}.IM5kkexAfwGLM6zz0Exd{background:var(--jp-gray-0);color:var(--jp-gray-50)}.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)}.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)}.WtVEv641JBaLl929sZq2{align-items:flex-start;background-color:rgba(0,0,0,.25);bottom:0;display:flex;justify-content:center;left:0;padding-top:calc(var(--spacing-base)*12 + 2px);position:fixed;right:0;top:0;z-index:999999}.G0aPt7WmA1rkUE0wcTno{background:var(--jp-white);border:1px solid var(--jp-gray);border-radius:calc(var(--jp-border-radius)*2);box-shadow:0 8px 20px rgba(0,0,0,.25);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}.EU0Rvu4PDqVtnCAmbgHg{height:56px;margin-bottom:calc(var(--spacing-base)*8);width:48px}.EU0Rvu4PDqVtnCAmbgHg>svg{left:-40px;position:relative;top:-36px}.vzMlFr1AXWqefpRrb976{align-items:center;display:flex;justify-content:space-between;margin-bottom:calc(var(--spacing-base)*3)}.gYSOMa4xxLXmsNzvFPkW{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)}.Clxt94RgGnDrhORZZyPr,.K2OG1vK5PSOYDWKtqKKG{margin-top:calc(var(--spacing-base)*7)}.ZMBDiTLzs27F012iOsMK>:first-child{flex:1}@media(min-width:960px){.ZMBDiTLzs27F012iOsMK{align-items:center;display:flex}}.zI2DKzqRc1MhF6aq5eHt{align-items:center;color:var(--jp-black);display:flex}.iHgPFku9KaLz8FIQV1Qw{margin-left:-4px;margin-right:var(--spacing-base)}.xuIO_ubyDN6IGJ67NTlx{margin-top:calc(var(--spacing-base)*3)}@media(min-width:960px){.xuIO_ubyDN6IGJ67NTlx{margin-top:0}}.ctq2nQkzIfSoMkldF9t9{margin-top:calc(var(--spacing-base)*2);width:100%}@media(min-width:960px){.ctq2nQkzIfSoMkldF9t9{margin-left:calc(var(--spacing-base)*2);margin-top:0;width:auto}}.cuoSlhSNrqf1dozY22Xb{fill:#000}.JLquNpQVlysAamuh5lJO,.lAIiifeLMmZAPlQ9n9ZR{fill:var(--jp-green-primary)}.cbOwD8Y4tFjwimmtchQI{fill:#757575}.cbOwD8Y4tFjwimmtchQI.aHOlEBGD5EA8NKRw3xTw{fill:var(--color-facebook);border-radius:50%!important}.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)}.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}.r4Id5qht2FD68jCAH2Cl{margin-left: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)}.ZSZPabDoB8MVVPttP0tu{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%}.ZSZPabDoB8MVVPttP0tu>span:first-child{grid-column:1/7}.ZSZPabDoB8MVVPttP0tu>span:not(:first-child){text-align:center}.iJ_biSBRDribuNKX0Zuw{margin:calc(var(--spacing-base)*4) calc(var(--spacing-base)*8);text-align:center}.iJ_biSBRDribuNKX0Zuw>button span{color:var(--jp-gray-70);font-size:var(--font-body-small);font-weight:400}.iJ_biSBRDribuNKX0Zuw button:hover:not(:disabled){text-decoration-line:none}.iJ_biSBRDribuNKX0Zuw button:focus:not(:disabled){box-shadow:none}@media(max-width:599px){.uym7dGHhp6ifjF57yOAO{margin-bottom:calc(var(--spacing-base)*3)}.e_2eFTR8RyHwmfeqJL4F{display:none}.r4Id5qht2FD68jCAH2Cl{flex:1}.r4Id5qht2FD68jCAH2Cl:first-of-type{margin-left:0}.pkw2LnOTd8VvQ3oT8sXQ{justify-content:center}.pkw2LnOTd8VvQ3oT8sXQ>*{width:50%}}.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 rgba(0,0,0,.08);margin:0;padding:var(--spacing-base) 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)}.t5TwI3d3FnCJvFBlkmm5{display:block}.kSa6ERuVPsCMPXugb030{display:none}.LumryWNddoF092fZgN2O{font-size:var(--font-body);line-height:1.5}.NFMwU3H5k2qArZe2TTp9{background-color:var(--jp-gray-10);font-weight:600;padding:calc(var(--spacing-base)/2) var(--spacing-base)}.G5W9M8qfo3sGl2OIbwg9{background-color:var(--jp-gray-0);display:flex;flex-direction:row;font-family:Courier\ 10 Pitch,Courier,monospace;overflow-x:scroll;white-space:pre}.Bx4RDCUR316fm_jgGS8N{background-color:var(--jp-gray-10);color:var(--jp-gray-50);display:flex;flex-direction:column;padding:0 var(--spacing-base);text-align:right}.GhN0JvAyRQI3SnVWp2Ot{display:flex;flex-direction:column;flex-grow:1;overflow-x:visible}.GhN0JvAyRQI3SnVWp2Ot del,.GhN0JvAyRQI3SnVWp2Ot div,.GhN0JvAyRQI3SnVWp2Ot ins{padding:0 var(--spacing-base);text-decoration:none}.GhN0JvAyRQI3SnVWp2Ot del{background-color:var(--jp-red-0);color:var(--jp-red-60)}.GhN0JvAyRQI3SnVWp2Ot ins{background-color:var(--jp-green-5);color:var(--jp-green-60)}.xpPHTch5ul0xuZaUoTNa{background-color:var(--jp-gray-0);display:flex;flex-direction:row;font-family:monospace;overflow-x:scroll;padding:0}.AMOpkL9LURkyTK8316cw{background-color:var(--jp-red-0)}.i0_0xMrNWoak1brIaDQq{display:flex;flex-direction:column;text-align:right}.C9fLawPLkMNSZthfwxj6{background-color:var(--jp-gray-10);color:var(--font-body);padding:0 calc(var(--spacing-base)/2)}.C9fLawPLkMNSZthfwxj6.AMOpkL9LURkyTK8316cw{background-color:var(--jp-red-50);color:var(--jp-white)}.ogixgg8fRGekmYGtevh1{display:flex;flex:1;flex-direction:column;overflow-x:visible;white-space:pre}.jYPCgKMDRKfT3vnx0mdG{padding-left:var(--spacing-base)}.UEQ1NqkrwNmaQR7qdEK3{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)}.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;margin-bottom:var(--spacing-base);margin-left:calc(var(--spacing-base)*4)}.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)}@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}}.A6a9HOtaZnLUleNgxQrX{padding:calc(var(--spacing-base)*7) 0}.CGT5fOs6LDTFHWCAgIiT,.RFKxbzQ8N58qEyVO0yzW{align-items:center;display:flex}.RFKxbzQ8N58qEyVO0yzW{height:100%}.RFKxbzQ8N58qEyVO0yzW img{object-fit:cover;width:100%}.SvMuuouOkDt2sE0PAn_D{margin-top:calc(var(--spacing-base)*3 + 1px)}.urouayitSUT8zW0V3p_0{margin-bottom:0}.iXXJlk08gFDeCvsTTlNQ{border:1px solid var(--jp-gray);border-left:6px solid var(--jp-red-50);border-radius:var(--jp-border-radius);box-shadow:0 4px 8px rgba(0,0,0,.03),0 1px 2px rgba(0,0,0,.06);box-sizing:border-box;color:var(--jp-gray-80);font-size:16px;line-height:22px;margin:0;padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3) calc(var(--spacing-base)*2) calc(var(--spacing-base)*3)}.iXXJlk08gFDeCvsTTlNQ.is-error{background-color:var(--jp-white)}.iXXJlk08gFDeCvsTTlNQ .components-notice__content{align-items:flex-start;display:flex;flex-direction:column;margin:0;padding:12px 4px}.iXXJlk08gFDeCvsTTlNQ .is-link{color:var(--jp-black);font-size:16px;font-weight:600}.iXXJlk08gFDeCvsTTlNQ .components-notice__dismiss{align-self:center}.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk,.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk:active,.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk:hover,.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk:visited{align-items:center;background:#000;border-radius:var(--jp-border-radius);color:var(--jp-white);cursor:pointer;font-size:16px;font-weight:600;justify-content:center;letter-spacing:-.01em;line-height:24px;margin-left:calc(var(--spacing-base)*2 + 24px);margin-top:24px;padding:8px 24px;text-decoration:none}.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk,.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk:active,.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk:hover,.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk:visited{margin-left:0;margin-top:0;white-space:nowrap}.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .components-notice__content{align-items:center;flex-direction:row}.e6hHy8BZ7ZKPSXbIC0UG{margin-bottom:25px}.jXz8LnXNzMDdtHqkG0sZ{display:flex;flex-grow:1;margin-right:var(--spacing-base)}.jXz8LnXNzMDdtHqkG0sZ>svg{align-self:flex-start;flex-shrink:0}.jXz8LnXNzMDdtHqkG0sZ .jp-components-spinner,.jXz8LnXNzMDdtHqkG0sZ>svg{margin-right:calc(var(--spacing-base)*2)}*,._fUXxnSp5pagKBp9gSN7 *{box-sizing:border-box} \ 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 213fe8eb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.js +++ /dev/null @@ -1,43 +0,0 @@ -/*! For license information please see index.js.LICENSE.txt */ -!function(){var e={9487:function(e,t,n){"use strict";n.d(t,{X:function(){return c}});const a={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 c(e){return a[e]||{symbol:"$",grouping:",",decimal:".",precision:2}}},8899:function(e,t,n){"use strict";n.d(t,{LR:function(){return r}});var a=n(9487),c=n(2003);function r(e,t,n={}){const r=(0,a.X)(t);if(!r||isNaN(e))return null;const{decimal:i,grouping:o,precision:l,symbol:s}={...r,...n},u=e<0?"-":"",p=Math.abs(e),m=Math.floor(p);return{sign:u,symbol:s,integer:(0,c.Z)(p,l,i,o).split(i)[0],fraction:l>0?(0,c.Z)(p-m,l,i,o).slice(1):""}}},2003:function(e,t,n){"use strict";function a(e,t=0,n=".",a=","){const c=(e+"").replace(/[^0-9+\-Ee.]/g,""),r=isFinite(+c)?+c:0,i=isFinite(+t)?Math.abs(t):0,o=(i?function(e,t){const n=Math.pow(10,t);return""+(Math.round(e*n)/n).toFixed(t)}(r,i):""+Math.round(r)).split(".");return o[0].length>3&&(o[0]=o[0].replace(/\B(?=(?:\d{3})+(?!\d))/g,a)),(o[1]||"").length{"%%"!==e&&(a++,"%c"===e&&(c=a))})),t.splice(c,0,n)},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;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&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$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=n(1741)(t);const{formatters:a}=e.exports;a.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},1741:function(e,t,n){e.exports=function(e){function t(e){let n,c,r,i=null;function o(...e){if(!o.enabled)return;const a=o,c=Number(new Date),r=c-(n||c);a.diff=r,a.prev=n,a.curr=c,n=c,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let i=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((n,c)=>{if("%%"===n)return"%";i++;const r=t.formatters[c];if("function"==typeof r){const t=e[i];n=r.call(a,t),e.splice(i,1),i--}return n})),t.formatArgs.call(a,e);(a.log||t.log).apply(a,e)}return o.namespace=e,o.useColors=t.useColors(),o.color=t.selectColor(e),o.extend=a,o.destroy=t.destroy,Object.defineProperty(o,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==i?i:(c!==t.namespaces&&(c=t.namespaces,r=t.enabled(e)),r),set:e=>{i=e}}),"function"==typeof t.init&&t.init(o),o}function a(e,n){const a=t(this.namespace+(void 0===n?":":n)+e);return a.log=this.log,a}function c(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return t.debug=t,t.default=t,t.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},t.disable=function(){const e=[...t.names.map(c),...t.skips.map(c).map((e=>"-"+e))].join(",");return t.enable(""),e},t.enable=function(e){let n;t.save(e),t.namespaces=e,t.names=[],t.skips=[];const a=("string"==typeof e?e:"").split(/[\s,]+/),c=a.length;for(n=0;n{t[n]=e[n]})),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let n=0;for(let t=0;t1&&void 0!==arguments[1]?arguments[1]:{},n=e.split(/\r\n|[\n\v\f\r\x85]/),a=e.match(/\r\n|[\n\v\f\r\x85]/g)||[],c=[],r=0;function i(){var e={};for(c.push(e);r=0&&(t.hash=e.substr(n),e=e.substr(0,n));var a=e.indexOf("?");a>=0&&(t.search=e.substr(a),e=e.substr(0,a)),e&&(t.pathname=e)}return t}},1494:function(e,t){"use strict";t.Z={"admin-page":"sexr0jUxC1jVixdKiDnC",background:"vKQ11sLeAM45M04P1ccj"}},281:function(e,t){"use strict";t.Z={"section-hero":"vMa4i_Dza2t5Zi_Bw9Nf"}},3466:function(e,t){"use strict";t.Z={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"}},1489:function(e,t){"use strict";t.Z={cut:"msOlyh2T7D6uhbM6AROg",icon:"cPN7USVqSBpxUswfDtUZ",cta:"EmnJAyEzzn1QpA8HtypY",iconContainer:"vV7YZikAz0oHYsuvtxMq",description:"T1YaMupeZmBIpXZHY9EZ"}},5785:function(){},1275:function(){},5612:function(e,t){"use strict";t.Z={"star-icon":"cuoSlhSNrqf1dozY22Xb",jetpack:"lAIiifeLMmZAPlQ9n9ZR","checkmark-icon":"JLquNpQVlysAamuh5lJO",socialIcon:"cbOwD8Y4tFjwimmtchQI",facebook:"aHOlEBGD5EA8NKRw3xTw",twitter:"af4Y_zItXvLAOEoSDPSv",linkedin:"f68aqF3XSD1OBvXR1get",tumblr:"xFI0dt3UiXRlRQdqPWkx",google:"q7JEoyymveP6kF747M43",mastodon:"DKOBOTVmTLbh26gUH_73"}},9054:function(){},3247:function(e,t){"use strict";t.Z={sm:"(max-width: 599px)",md:"(min-width: 600px) and (max-width: 959px)",lg:"(min-width: 960px)"}},3080:function(e,t){"use strict";t.Z={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"}},8730:function(e,t){"use strict";t.Z={sm:"(max-width: 599px)",md:"(min-width: 600px) and (max-width: 959px)",lg:"(min-width: 960px)",container:"SqdhUZkXCRuIpErj1B3z",fluid:"OZC_9a1LhpWF9dv15Gdh"}},7703:function(e,t){"use strict";t.Z={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"}},9929:function(e,t){"use strict";t.Z={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"}},9184:function(e,t){"use strict";t.Z={container:"dovianZYLKhnbnh9I06o","price-container":"lljtQMhW7lq5tE5SDJEf",price:"dhFQXpZfMwVI8vuYHnwC","is-not-off-price":"eD7hzxFmdtG_MgmBtl_k",footer:"C64ZjjUAqJC1T2Sa7apS",legend:"UpZDGew6Ay1hPoP6eI7b","promo-label":"NubApIV1vQCRUNprfm6b",symbol:"TDiiPbuW1Z0_05u_pvcK"}},1683:function(){},7920:function(){},3280:function(e,t){"use strict";t.Z={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"}},3591:function(e,t){"use strict";t.Z={global:"_fUXxnSp5pagKBp9gSN7"}},9836:function(e,t){"use strict";t.Z={heading:"urouayitSUT8zW0V3p_0",notice:"iXXJlk08gFDeCvsTTlNQ",button:"MWqRqr7q6fgvLxitcWYk","bigger-than-medium":"YLcXAoc82nypTPaKSAcd",error:"e6hHy8BZ7ZKPSXbIC0UG",message:"jXz8LnXNzMDdtHqkG0sZ"}},3900:function(e,t){"use strict";t.Z={navigation:"vvXnRXxrU1kP1KsdSr4J",badge:"aDCTkUFaJEeZzYYE6qv5"}},9993:function(e,t){"use strict";t.Z={container:"EU0Rvu4PDqVtnCAmbgHg"}},4424:function(e,t){"use strict";t.Z={loading:"kdsaL7c4bpTwf_A4fIUT",loading__message:"b0eN3as5AgxQW7EAkarg"}},3064:function(e,t){"use strict";t.Z={footer:"_Wc3apZobag_9Ag_THTb"}},9137:function(e,t){"use strict";t.Z={"diff-viewer":"LumryWNddoF092fZgN2O","diff-viewer__filename":"NFMwU3H5k2qArZe2TTp9","diff-viewer__file":"G5W9M8qfo3sGl2OIbwg9","diff-viewer__line-numbers":"Bx4RDCUR316fm_jgGS8N","diff-viewer__lines":"GhN0JvAyRQI3SnVWp2Ot"}},3932:function(e,t){"use strict";t.Z={"footer-checkbox":"uQlXhcfYn9tbnK27_Gct","standalone-mode-section":"e5YHJiYcvfgdEEJsS_YM","share-data-section":"PO9zDOaSkcv_RqpfZF_v"}},8452:function(e,t){"use strict";t.Z={status:"gTWkHo5lqwE_OCesAhBx",active:"JeLxNe31ii68Utrr2xr6",spinner:"V6B8ltQ7TH3UKzUC_qy1","firewall-subheading":"C9hcvYAbgHPhN2Tl22xg","brute-force-protection-subheading":"XkbIpr2gzB4XEhHgzkY4","firewall-subheading__content":"BfcZn0_X33Ajdd1Gl18G","icon-popover":"rBmVJIeTNpd0RJWaRGuJ","upgrade-button":"jVq5444f1Xh6nNkz0Qe_","firewall-header":"amF9cOnMiv2nHbkMXQiQ","stat-card-wrapper":"FodE_7RbLD8zeBSd6eVR","popover-text":"twyPhW_K164HITnDrwEg","loading-text":"tbcd9xc_TjcFdokOt3F_","firewall-heading":"pnoqLV3l30xuvj2hLlJc"}},4854:function(e,t){"use strict";t.Z={container:"DM4b8iQ0ewvRYdIPxvZ8","toggle-section":"bW6ZuNzJBYU5PVPktE2S","toggle-section__control":"di3wjXHrX1rk_H6rlxKM","toggle-section__content":"IrzHnNkRvORtyCL0yiWa","toggle-section__title":"sU82bpLEYPC9n_CFAKoz","toggle-section--disabled":"ZZc0LldcbJpcftqCe43T","toggle-section__details":"T17WOOJI7XHN7KRmYaCe","automatic-rules-stats":"typbjN2keZ97hj2TmuMC","automatic-rules-stats__version":"UUXAN8VTAZY0h8t9rCHG","automatic-rules-stats__last-updated":"eFjcadLMEXY5O61vsTrx","automatic-rules-stats__failed-install":"Tr5uYvclUiwlC5kuGk7E","manual-rules-stats":"zPZcNgYx2X5778nHHtlH","manual-rules-stats__no-rules":"lNtkRXnB1z_kYB28MUWq","manual-rules-stats__block-list-count":"JgH5ykcLynEgqXYurT78","manual-rules-stats__allow-list-count":"xlWW0IoKZwTZt1Ti0tcQ","upgrade-trigger-section":"zhBcgCUGgyC7PvWk8ewB","manual-rules-section":"mah_f2OWxZ3Vqt_jRFdR","go-back-button":"Ax2SmW57c0U5xOTjZuAA",badge:"xGZeYQr0_nPJTFmd8pW4",popover:"RYTIt8kwLbKcUbWOfG4g",popover__header:"BqXge2rIUP0a_74yvYbr",popover__button:"Lr10UUCcSLF3T_0QqoPr",popover__footer:"th_VukMuODIOVLC7oJo6"}},5823:function(e,t){"use strict";t.Z={list:"sQkG5Cu80gPaeFj3L_wa",footer:"oIl6GCMeUnzE0inXbuj9"}},7279:function(e,t){"use strict";t.Z={list:"RP2MVoGqaCFXPKZhhxQ1",footer:"YpEs8b7KE7fzVuXUbOEb"}},1234:function(e,t){"use strict";t.Z={"form-toggle":"IunwKwdvL271DxBIniPb","form-toggle__switch":"svA9WxEcOByd5S2fZonA","is-compact":"wOd7DeP76v1fczKfah5n"}},9122:function(e,t){"use strict";t.Z={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"}},6983:function(e,t){"use strict";t.Z={threat:"EqpwvErHtRi_WQkJKgi1",threat__icon:"EicvN1QaJu5OJLzdUN5A",threat__summary:"b7ynAmUwGlxK_vxyIN0y",threat__summary__label:"uSV9HYRxjL4S6zIZDlqP",threat__summary__title:"XpW8Mvw_XFEbqxUdw155",threat__severity:"Fkj60BmQ5sUo9zHcJwVv",footer:"XLzPr74ad3osCq9kxy2q"}},2951:function(e,t){"use strict";t.Z={"protect-header":"UL3B1tQ854mN7r6taB61","get-started-button":"IG56Hw7ZR_7rKVsM78qw"}},8735:function(e,t){"use strict";t.Z={"marked-lines":"xpPHTch5ul0xuZaUoTNa","marked-lines__marked-line":"AMOpkL9LURkyTK8316cw","marked-lines__line-numbers":"i0_0xMrNWoak1brIaDQq","marked-lines__line-number":"C9fLawPLkMNSZthfwxj6","marked-lines__lines":"ogixgg8fRGekmYGtevh1","marked-lines__line":"jYPCgKMDRKfT3vnx0mdG","marked-lines__mark":"UEQ1NqkrwNmaQR7qdEK3"}},9980:function(e,t){"use strict";t.Z={modal:"WtVEv641JBaLl929sZq2",modal__window:"G0aPt7WmA1rkUE0wcTno",modal__close:"VkrhWjfEIlIwYEumycbP",modal__close__icon:"yFzeV4cmWRbZKk5tIyEw"}},513:function(e,t){"use strict";t.Z={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","navigation-dropdown-open":"t5TwI3d3FnCJvFBlkmm5","navigation-dropdown-closed":"kSa6ERuVPsCMPXugb030"}},8212:function(e,t){"use strict";t.Z={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"}},7324:function(e,t){"use strict";t.Z={accordion:"sfXsfklfkeSRtE9ivQwF","accordion-item":"ozRrKPlj1QFGUyd3oVke","accordion-header":"PyvnSHQuuUkZvVsArigy","accordion-header-label":"u9Xod5s8bCRNj9MR1Drl","accordion-header-label-icon":"IbeyulkpO9kjYJ4OkYUD","accordion-header-description":"KiCgmjHm2f0JDU3cMsgf","accordion-header-button":"kJ8t3FAtd5VAYjk31SfA","accordion-body":"JP0IJZcYRohfgntEozjm","accordion-body-close":"y7c6zi2wjEnbW3F29fmP","accordion-body-open":"wQWiN_J0SqgduvadyGnm","icon-check":"v1fUFCBPmd6miSCf_ehK"}},6067:function(e,t){"use strict";t.Z={"progress-bar":"vzMlFr1AXWqefpRrb976","progress-bar__wrapper":"gYSOMa4xxLXmsNzvFPkW","progress-bar__bar":"hNJWdt5qmZkWYAH_vjIp","progress-bar__percent":"DHMUfGyHbl5BgD5vjxVz"}},8383:function(e,t){"use strict";t.Z={"product-section":"Clxt94RgGnDrhORZZyPr","info-section":"K2OG1vK5PSOYDWKtqKKG"}},61:function(e,t){"use strict";t.Z={"main-content":"A6a9HOtaZnLUleNgxQrX","loading-content":"CGT5fOs6LDTFHWCAgIiT",illustration:"RFKxbzQ8N58qEyVO0yzW","connection-error-col":"SvMuuouOkDt2sE0PAn_D"}},8131:function(e,t){"use strict";t.Z={"threat-severity-badge":"JiJhrZaThvWCpM2AfGen","is-critical":"_7SGksgOpcPbHfPPpQTV","is-high":"pGNquShR54adQ61sx3lP","is-low":"IM5kkexAfwGLM6zz0Exd"}},8911:function(e,t){"use strict";t.Z={mark:"jNlU3vgp4xEGwmX5aTyK",list:"gE8s4nh3f7iGIBrFeyCT"}},6561:function(e,t){"use strict";t.Z={summary:"ZMBDiTLzs27F012iOsMK",summary__title:"zI2DKzqRc1MhF6aq5eHt",summary__icon:"iHgPFku9KaLz8FIQV1Qw",summary__notice:"xuIO_ubyDN6IGJ67NTlx","summary__scan-button":"ctq2nQkzIfSoMkldF9t9"}},5714:function(e,t){"use strict";t.Z={tabs:"lyrXe0pA852TUmyekDb5",tab:"KgEeDTKgTC5ZjzYlbTqN","tab--active":"Lv4WoNVkeJntqvUyG4dX"}},8063:function(e,t){"use strict";t.Z={textarea:"rigH8UdiDrmmSLQMUurD",label:"V8FDM08CpcwQs4UwN2nI"}},9971:function(e,t){"use strict";t.Z={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"}},9709:function(e,t){"use strict";t.Z={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-button":"r4Id5qht2FD68jCAH2Cl","accordion-heading":"ZSZPabDoB8MVVPttP0tu","manual-scan":"iJ_biSBRDribuNKX0Zuw"}},541:function(e,t){"use strict";t.Z={footer:"uUEJGMrSV3XoBwX5xEwA"}},1155:function(){},3171:function(e){var t=1e3,n=60*t,a=60*n,c=24*a,r=7*c,i=365.25*c;function o(e,t,n,a){var c=t>=1.5*n;return Math.round(e/n)+" "+a+(c?"s":"")}e.exports=function(e,l){l=l||{};var s=typeof e;if("string"===s&&e.length>0)return function(e){if((e=String(e)).length>100)return;var o=/^(-?(?:\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(!o)return;var l=parseFloat(o[1]);switch((o[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return l*i;case"weeks":case"week":case"w":return l*r;case"days":case"day":case"d":return l*c;case"hours":case"hour":case"hrs":case"hr":case"h":return l*a;case"minutes":case"minute":case"mins":case"min":case"m":return l*n;case"seconds":case"second":case"secs":case"sec":case"s":return l*t;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return l;default:return}}(e);if("number"===s&&isFinite(e))return l.long?function(e){var r=Math.abs(e);if(r>=c)return o(e,r,c,"day");if(r>=a)return o(e,r,a,"hour");if(r>=n)return o(e,r,n,"minute");if(r>=t)return o(e,r,t,"second");return e+" ms"}(e):function(e){var r=Math.abs(e);if(r>=c)return Math.round(e/c)+"d";if(r>=a)return Math.round(e/a)+"h";if(r>=n)return Math.round(e/n)+"m";if(r>=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))}},469:function(e,t,n){"use strict";var a=n(758);function c(){}function r(){}r.resetWarningCache=c,e.exports=function(){function e(e,t,n,c,r,i){if(i!==a){var o=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 o.name="Invariant Violation",o}}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:r,resetWarningCache:c};return n.PropTypes=n,n}},5162:function(e,t,n){e.exports=n(469)()},758:function(e){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},554:function(e,t,n){"use strict";n.d(t,{OL:function(){return m},UT:function(){return u}});var a=n(9196),c=n(5250),r=n(5439);function i(){return i=Object.assign||function(e){for(var t=1;t=0||(c[n]=e[n]);return c}const l=["onClick","reloadDocument","replace","state","target","to"],s=["aria-current","caseSensitive","className","end","style","to","children"];function u(e){let{basename:t,children:n,window:i}=e,o=(0,a.useRef)();null==o.current&&(o.current=(0,c.q_)({window:i}));let l=o.current,[s,u]=(0,a.useState)({action:l.action,location:l.location});return(0,a.useLayoutEffect)((()=>l.listen(u)),[l]),(0,a.createElement)(r.F0,{basename:t,children:n,location:s.location,navigationType:s.action,navigator:l})}const p=(0,a.forwardRef)((function(e,t){let{onClick:n,reloadDocument:s,replace:u=!1,state:p,target:m,to:d}=e,h=o(e,l),g=(0,r.oQ)(d),f=function(e,t){let{target:n,replace:i,state:o}=void 0===t?{}:t,l=(0,r.s0)(),s=(0,r.TH)(),u=(0,r.WU)(e);return(0,a.useCallback)((t=>{if(!(0!==t.button||n&&"_self"!==n||function(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}(t))){t.preventDefault();let n=!!i||(0,c.Ep)(s)===(0,c.Ep)(u);l(e,{replace:n,state:o})}}),[s,l,u,i,o,n,e])}(d,{replace:u,state:p,target:m});return(0,a.createElement)("a",i({},h,{href:g,onClick:function(e){n&&n(e),e.defaultPrevented||s||f(e)},ref:t,target:m}))}));const m=(0,a.forwardRef)((function(e,t){let{"aria-current":n="page",caseSensitive:c=!1,className:l="",end:u=!1,style:m,to:d,children:h}=e,g=o(e,s),f=(0,r.TH)(),v=(0,r.WU)(d),E=f.pathname,b=v.pathname;c||(E=E.toLowerCase(),b=b.toLowerCase());let k,y=E===b||!u&&E.startsWith(b)&&"/"===E.charAt(b.length),Z=y?n:void 0;k="function"==typeof l?l({isActive:y}):[l,y?"active":null].filter(Boolean).join(" ");let C="function"==typeof m?m({isActive:y}):m;return(0,a.createElement)(p,i({},g,{"aria-current":Z,className:k,ref:t,style:C,to:d}),"function"==typeof h?h({isActive:y}):h)}))},5439:function(e,t,n){"use strict";n.d(t,{AW:function(){return u},F0:function(){return p},Fg:function(){return s},TH:function(){return g},WU:function(){return v},Z5:function(){return m},oQ:function(){return d},s0:function(){return f}});var a=n(9196),c=n(5250);function r(e,t){if(!e)throw new Error(t)}const i=(0,a.createContext)(null);const o=(0,a.createContext)(null);const l=(0,a.createContext)({outlet:null,matches:[]});function s(e){let{to:t,replace:n,state:c}=e;h()||r(!1);let i=f();return(0,a.useEffect)((()=>{i(t,{replace:n,state:c})})),null}function u(e){r(!1)}function p(e){let{basename:t="/",children:n=null,location:l,navigationType:s=c.aU.Pop,navigator:u,static:p=!1}=e;h()&&r(!1);let m=T(t),d=(0,a.useMemo)((()=>({basename:m,navigator:u,static:p})),[m,u,p]);"string"==typeof l&&(l=(0,c.cP)(l));let{pathname:g="/",search:f="",hash:v="",state:E=null,key:b="default"}=l,k=(0,a.useMemo)((()=>{let e=I(g,m);return null==e?null:{pathname:e,search:f,hash:v,state:E,key:b}}),[m,g,f,v,E,b]);return null==k?null:(0,a.createElement)(i.Provider,{value:d},(0,a.createElement)(o.Provider,{children:n,value:{location:k,navigationType:s}}))}function m(e){let{children:t,location:n}=e;return function(e,t){h()||r(!1);let{matches:n}=(0,a.useContext)(l),i=n[n.length-1],o=i?i.params:{},s=(i&&i.pathname,i?i.pathnameBase:"/");i&&i.route;0;let u,p=g();if(t){var m;let e="string"==typeof t?(0,c.cP)(t):t;"/"===s||(null==(m=e.pathname)?void 0:m.startsWith(s))||r(!1),u=e}else u=p;let d=u.pathname||"/",f="/"===s?d:d.slice(s.length)||"/",v=function(e,t,n){void 0===n&&(n="/");let a="string"==typeof t?(0,c.cP)(t):t,r=I(a.pathname||"/",n);if(null==r)return null;let i=b(e);!function(e){e.sort(((e,t)=>e.score!==t.score?t.score-e.score:function(e,t){let n=e.length===t.length&&e.slice(0,-1).every(((e,n)=>e===t[n]));return n?e[e.length-1]-t[t.length-1]:0}(e.routesMeta.map((e=>e.childrenIndex)),t.routesMeta.map((e=>e.childrenIndex)))))}(i);let o=null;for(let e=0;null==o&&eObject.assign({},e,{params:Object.assign({},o,e.params),pathname:M([s,e.pathname]),pathnameBase:"/"===e.pathnameBase?s:M([s,e.pathnameBase])}))),n)}(E(t),n)}function d(e){h()||r(!1);let{basename:t,navigator:n}=(0,a.useContext)(i),{hash:o,pathname:l,search:s}=v(e),u=l;if("/"!==t){let n=function(e){return""===e||""===e.pathname?"/":"string"==typeof e?(0,c.cP)(e).pathname:e.pathname}(e),a=null!=n&&n.endsWith("/");u="/"===l?t+(a?"/":""):M([t,l])}return n.createHref({pathname:u,search:s,hash:o})}function h(){return null!=(0,a.useContext)(o)}function g(){return h()||r(!1),(0,a.useContext)(o).location}function f(){h()||r(!1);let{basename:e,navigator:t}=(0,a.useContext)(i),{matches:n}=(0,a.useContext)(l),{pathname:c}=g(),o=JSON.stringify(n.map((e=>e.pathnameBase))),s=(0,a.useRef)(!1);return(0,a.useEffect)((()=>{s.current=!0})),(0,a.useCallback)((function(n,a){if(void 0===a&&(a={}),!s.current)return;if("number"==typeof n)return void t.go(n);let r=x(n,JSON.parse(o),c);"/"!==e&&(r.pathname=M([e,r.pathname])),(a.replace?t.replace:t.push)(r,a.state)}),[e,t,o,c])}function v(e){let{matches:t}=(0,a.useContext)(l),{pathname:n}=g(),c=JSON.stringify(t.map((e=>e.pathnameBase)));return(0,a.useMemo)((()=>x(e,JSON.parse(c),n)),[e,c,n])}function E(e){let t=[];return a.Children.forEach(e,(e=>{if(!(0,a.isValidElement)(e))return;if(e.type===a.Fragment)return void t.push.apply(t,E(e.props.children));e.type!==u&&r(!1);let n={caseSensitive:e.props.caseSensitive,element:e.props.element,index:e.props.index,path:e.props.path};e.props.children&&(n.children=E(e.props.children)),t.push(n)})),t}function b(e,t,n,a){return void 0===t&&(t=[]),void 0===n&&(n=[]),void 0===a&&(a=""),e.forEach(((e,c)=>{let i={relativePath:e.path||"",caseSensitive:!0===e.caseSensitive,childrenIndex:c,route:e};i.relativePath.startsWith("/")&&(i.relativePath.startsWith(a)||r(!1),i.relativePath=i.relativePath.slice(a.length));let o=M([a,i.relativePath]),l=n.concat(i);e.children&&e.children.length>0&&(!0===e.index&&r(!1),b(e.children,t,l,o)),(null!=e.path||e.index)&&t.push({path:o,score:j(o,e.index),routesMeta:l})})),t}const k=/^:\w+$/,y=3,Z=2,C=1,_=10,w=-2,R=e=>"*"===e;function j(e,t){let n=e.split("/"),a=n.length;return n.some(R)&&(a+=w),t&&(a+=Z),n.filter((e=>!R(e))).reduce(((e,t)=>e+(k.test(t)?y:""===t?C:_)),a)}function N(e,t){let{routesMeta:n}=e,a={},c="/",r=[];for(let e=0;e(0,a.createElement)(l.Provider,{children:void 0!==c.route.element?c.route.element:n,value:{outlet:n,matches:t.concat(e.slice(0,r+1))}})),null)}function P(e,t){"string"==typeof e&&(e={path:e,caseSensitive:!1,end:!0});let[n,a]=function(e,t,n){void 0===t&&(t=!1);void 0===n&&(n=!0);let a=[],c="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^$?{}|()[\]]/g,"\\$&").replace(/:(\w+)/g,((e,t)=>(a.push(t),"([^\\/]+)")));e.endsWith("*")?(a.push("*"),c+="*"===e||"/*"===e?"(.*)$":"(?:\\/(.+)|\\/*)$"):c+=n?"\\/*$":"(?:(?=[.~-]|%[0-9A-F]{2})|\\b|\\/|$)";let r=new RegExp(c,t?void 0:"i");return[r,a]}(e.path,e.caseSensitive,e.end),c=t.match(n);if(!c)return null;let r=c[0],i=r.replace(/(.)\/+$/,"$1"),o=c.slice(1);return{params:a.reduce(((e,t,n)=>{if("*"===t){let e=o[n]||"";i=r.slice(0,r.length-e.length).replace(/(.)\/+$/,"$1")}return e[t]=function(e,t){try{return decodeURIComponent(e)}catch(t){return e}}(o[n]||""),e}),{}),pathname:r,pathnameBase:i,pattern:e}}function x(e,t,n){let a,r="string"==typeof e?(0,c.cP)(e):e,i=""===e||""===r.pathname?"/":r.pathname;if(null==i)a=n;else{let e=t.length-1;if(i.startsWith("..")){let t=i.split("/");for(;".."===t[0];)t.shift(),e-=1;r.pathname=t.join("/")}a=e>=0?t[e]:"/"}let o=function(e,t){void 0===t&&(t="/");let{pathname:n,search:a="",hash:r=""}="string"==typeof e?(0,c.cP)(e):e,i=n?n.startsWith("/")?n:function(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach((e=>{".."===e?n.length>1&&n.pop():"."!==e&&n.push(e)})),n.length>1?n.join("/"):"/"}(n,t):t;return{pathname:i,search:L(a),hash:z(r)}}(r,a);return i&&"/"!==i&&i.endsWith("/")&&!o.pathname.endsWith("/")&&(o.pathname+="/"),o}function I(e,t){if("/"===t)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=e.charAt(t.length);return n&&"/"!==n?null:e.slice(t.length)||"/"}const M=e=>e.join("/").replace(/\/\/+/g,"/"),T=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),L=e=>e&&"?"!==e?e.startsWith("?")?e:"?"+e:"",z=e=>e&&"#"!==e?e.startsWith("#")?e:"#"+e:""},6975:function(e,t,n){"use strict";var a=n(951);const c=n.n(a)()("dops:analytics");let r,i;window._tkq=window._tkq||[],window.ga=window.ga||function(){(window.ga.q=window.ga.q||[]).push(arguments)},window.ga.l=+new Date;const o={initialize:function(e,t,n){o.setUser(e,t),o.setSuperProps(n),o.identifyUser()},setGoogleAnalyticsEnabled:function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;this.googleAnalyticsEnabled=e,this.googleAnalyticsKey=t},setMcAnalyticsEnabled:function(e){this.mcAnalyticsEnabled=e},setUser:function(e,t){i={ID:e,username:t}},setSuperProps:function(e){r=e},assignSuperProps:function(e){r=Object.assign(r||{},e)},mc:{bumpStat:function(e,t){const n=function(e,t){let n="";if("object"==typeof e){for(const t in e)n+="&x_"+encodeURIComponent(t)+"="+encodeURIComponent(e[t]);c("Bumping stats %o",e)}else n="&x_"+encodeURIComponent(e)+"="+encodeURIComponent(t),c('Bumping stat "%s" in group "%s"',t,e);return n}(e,t);o.mcAnalyticsEnabled&&((new Image).src=document.location.protocol+"//pixel.wp.com/g.gif?v=wpcom-no-pv"+n+"&t="+Math.random())},bumpStatWithPageView:function(e,t){const n=function(e,t){let n="";if("object"==typeof e){for(const t in e)n+="&"+encodeURIComponent(t)+"="+encodeURIComponent(e[t]);c("Built stats %o",e)}else n="&"+encodeURIComponent(e)+"="+encodeURIComponent(t),c('Built stat "%s" in group "%s"',t,e);return n}(e,t);o.mcAnalyticsEnabled&&((new Image).src=document.location.protocol+"//pixel.wp.com/g.gif?v=wpcom"+n+"&t="+Math.random())}},pageView:{record:function(e,t){o.tracks.recordPageView(e),o.ga.recordPageView(e,t)}},purchase:{record:function(e,t,n,a,c,r,i){o.ga.recordPurchase(e,t,n,a,c,r,i)}},tracks:{recordEvent:function(e,t){t=t||{},0===e.indexOf("akismet_")||0===e.indexOf("jetpack_")?(r&&(c("- Super Props: %o",r),t=Object.assign(t,r)),c('Record event "%s" called with props %s',e,JSON.stringify(t)),window._tkq.push(["recordEvent",e,t])):c('- Event name must be prefixed by "akismet_" or "jetpack_"')},recordJetpackClick:function(e){const t="object"==typeof e?e:{target:e};o.tracks.recordEvent("jetpack_wpa_click",t)},recordPageView:function(e){o.tracks.recordEvent("akismet_page_view",{path:e})},setOptOut:function(e){c("Pushing setOptOut: %o",e),window._tkq.push(["setOptOut",e])}},ga:{initialized:!1,initialize:function(){let e={};o.ga.initialized||(i&&(e={userId:"u-"+i.ID}),window.ga("create",this.googleAnalyticsKey,"auto",e),o.ga.initialized=!0)},recordPageView:function(e,t){o.ga.initialize(),c("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,n,a){o.ga.initialize();let r="Recording Event ~ [Category: "+e+"] [Action: "+t+"]";void 0!==n&&(r+=" [Option Label: "+n+"]"),void 0!==a&&(r+=" [Option Value: "+a+"]"),c(r),this.googleAnalyticsEnabled&&window.ga("send","event",e,t,n,a)},recordPurchase:function(e,t,n,a,c,r,i){window.ga("require","ecommerce"),window.ga("ecommerce:addTransaction",{id:e,revenue:a,currency:i}),window.ga("ecommerce:addItem",{id:e,name:t,sku:n,price:c,quantity:r}),window.ga("ecommerce:send")}},identifyUser:function(){i&&window._tkq.push(["identifyUser",i.ID,i.username])},setProperties:function(e){window._tkq.push(["setProperties",e])},clearedIdentity:function(){window._tkq.push(["clearIdentity"])}};t.Z=o},4743:function(e,t,n){"use strict";var a=n(1132),c=n(6483);function r(e){class t extends Error{constructor(){super(...arguments),this.name=e}}return t}const i=r("JsonParseError"),o=r("JsonParseAfterRedirectError"),l=r("Api404Error"),s=r("Api404AfterRedirectError"),u=r("FetchNetworkError");const p=new function(e,t){let n=e,r=e,i={"X-WP-Nonce":t},o={credentials:"same-origin",headers:i},l={method:"post",credentials:"same-origin",headers:Object.assign({},i,{"Content-type":"application/json"})},s=function(e){const t=e.split("?"),n=t.length>1?t[1]:"",a=n.length?n.split("&"):[];return a.push("_cacheBuster="+(new Date).getTime()),t[0]+"?"+a.join("&")};const u={setApiRoot(e){n=e},setWpcomOriginApiUrl(e){r=e},setApiNonce(e){i={"X-WP-Nonce":e},o={credentials:"same-origin",headers:i},l={method:"post",credentials:"same-origin",headers:Object.assign({},i,{"Content-type":"application/json"})}},setCacheBusterCallback:e=>{s=e},registerSite:(e,t)=>{const c={registration_nonce:e,no_iframe:!0};return(0,a.jetpackConfigHas)("consumer_slug")&&(c.plugin_slug=(0,a.jetpackConfigGet)("consumer_slug")),null!==t&&(c.redirect_uri=t),h(`${n}jetpack/v4/connection/register`,l,{body:JSON.stringify(c)}).then(m).then(d)},fetchAuthorizationUrl:e=>p((0,c.addQueryArgs)(`${n}jetpack/v4/connection/authorize_url`,{no_iframe:"1",redirect_uri:e}),o).then(m).then(d),fetchSiteConnectionData:()=>p(`${n}jetpack/v4/connection/data`,o).then(d),fetchSiteConnectionStatus:()=>p(`${n}jetpack/v4/connection`,o).then(d),fetchSiteConnectionTest:()=>p(`${n}jetpack/v4/connection/test`,o).then(m).then(d),fetchUserConnectionData:()=>p(`${n}jetpack/v4/connection/data`,o).then(d),fetchUserTrackingSettings:()=>p(`${n}jetpack/v4/tracking/settings`,o).then(m).then(d),updateUserTrackingSettings:e=>h(`${n}jetpack/v4/tracking/settings`,l,{body:JSON.stringify(e)}).then(m).then(d),disconnectSite:()=>h(`${n}jetpack/v4/connection`,l,{body:JSON.stringify({isActive:!1})}).then(m).then(d),fetchConnectUrl:()=>p(`${n}jetpack/v4/connection/url`,o).then(m).then(d),unlinkUser:()=>h(`${n}jetpack/v4/connection/user`,l,{body:JSON.stringify({linked:!1})}).then(m).then(d),reconnect:()=>h(`${n}jetpack/v4/connection/reconnect`,l).then(m).then(d),fetchConnectedPlugins:()=>p(`${n}jetpack/v4/connection/plugins`,o).then(m).then(d),setHasSeenWCConnectionModal:()=>h(`${n}jetpack/v4/seen-wc-connection-modal`,l).then(m).then(d),fetchModules:()=>p(`${n}jetpack/v4/module/all`,o).then(m).then(d),fetchModule:e=>p(`${n}jetpack/v4/module/${e}`,o).then(m).then(d),activateModule:e=>h(`${n}jetpack/v4/module/${e}/active`,l,{body:JSON.stringify({active:!0})}).then(m).then(d),deactivateModule:e=>h(`${n}jetpack/v4/module/${e}/active`,l,{body:JSON.stringify({active:!1})}),updateModuleOptions:(e,t)=>h(`${n}jetpack/v4/module/${e}`,l,{body:JSON.stringify(t)}).then(m).then(d),updateSettings:e=>h(`${n}jetpack/v4/settings`,l,{body:JSON.stringify(e)}).then(m).then(d),getProtectCount:()=>p(`${n}jetpack/v4/module/protect/data`,o).then(m).then(d),resetOptions:e=>h(`${n}jetpack/v4/options/${e}`,l,{body:JSON.stringify({reset:!0})}).then(m).then(d),activateVaultPress:()=>h(`${n}jetpack/v4/plugins`,l,{body:JSON.stringify({slug:"vaultpress",status:"active"})}).then(m).then(d),getVaultPressData:()=>p(`${n}jetpack/v4/module/vaultpress/data`,o).then(m).then(d),installPlugin:(e,t)=>{const a={slug:e,status:"active"};return t&&(a.source=t),h(`${n}jetpack/v4/plugins`,l,{body:JSON.stringify(a)}).then(m).then(d)},activateAkismet:()=>h(`${n}jetpack/v4/plugins`,l,{body:JSON.stringify({slug:"akismet",status:"active"})}).then(m).then(d),getAkismetData:()=>p(`${n}jetpack/v4/module/akismet/data`,o).then(m).then(d),checkAkismetKey:()=>p(`${n}jetpack/v4/module/akismet/key/check`,o).then(m).then(d),checkAkismetKeyTyped:e=>h(`${n}jetpack/v4/module/akismet/key/check`,l,{body:JSON.stringify({api_key:e})}).then(m).then(d),fetchStatsData:e=>p(function(e){let t=`${n}jetpack/v4/module/stats/data`;-1!==t.indexOf("?")?t+=`&range=${encodeURIComponent(e)}`:t+=`?range=${encodeURIComponent(e)}`;return t}(e),o).then(m).then(d).then(f),getPluginUpdates:()=>p(`${n}jetpack/v4/updates/plugins`,o).then(m).then(d),getPlans:()=>p(`${n}jetpack/v4/plans`,o).then(m).then(d),fetchSettings:()=>p(`${n}jetpack/v4/settings`,o).then(m).then(d),updateSetting:e=>h(`${n}jetpack/v4/settings`,l,{body:JSON.stringify(e)}).then(m).then(d),fetchSiteData:()=>p(`${n}jetpack/v4/site`,o).then(m).then(d).then((e=>JSON.parse(e.data))),fetchSiteFeatures:()=>p(`${n}jetpack/v4/site/features`,o).then(m).then(d).then((e=>JSON.parse(e.data))),fetchSiteProducts:()=>p(`${n}jetpack/v4/site/products`,o).then(m).then(d),fetchSitePurchases:()=>p(`${n}jetpack/v4/site/purchases`,o).then(m).then(d).then((e=>JSON.parse(e.data))),fetchSiteBenefits:()=>p(`${n}jetpack/v4/site/benefits`,o).then(m).then(d).then((e=>JSON.parse(e.data))),fetchSiteDiscount:()=>p(`${n}jetpack/v4/site/discount`,o).then(m).then(d).then((e=>e.data)),fetchSetupQuestionnaire:()=>p(`${n}jetpack/v4/setup/questionnaire`,o).then(m).then(d),fetchRecommendationsData:()=>p(`${n}jetpack/v4/recommendations/data`,o).then(m).then(d),fetchRecommendationsProductSuggestions:()=>p(`${n}jetpack/v4/recommendations/product-suggestions`,o).then(m).then(d),fetchRecommendationsUpsell:()=>p(`${n}jetpack/v4/recommendations/upsell`,o).then(m).then(d),fetchRecommendationsConditional:()=>p(`${n}jetpack/v4/recommendations/conditional`,o).then(m).then(d),saveRecommendationsData:e=>h(`${n}jetpack/v4/recommendations/data`,l,{body:JSON.stringify({data:e})}).then(m),fetchProducts:()=>p(`${n}jetpack/v4/products`,o).then(m).then(d),fetchRewindStatus:()=>p(`${n}jetpack/v4/rewind`,o).then(m).then(d).then((e=>JSON.parse(e.data))),fetchScanStatus:()=>p(`${n}jetpack/v4/scan`,o).then(m).then(d).then((e=>JSON.parse(e.data))),dismissJetpackNotice:e=>h(`${n}jetpack/v4/notice/${e}`,l,{body:JSON.stringify({dismissed:!0})}).then(m).then(d),fetchPluginsData:()=>p(`${n}jetpack/v4/plugins`,o).then(m).then(d),fetchIntroOffers:()=>p(`${n}jetpack/v4/intro-offers`,o).then(m).then(d),fetchVerifySiteGoogleStatus:e=>p(null!==e?`${n}jetpack/v4/verify-site/google/${e}`:`${n}jetpack/v4/verify-site/google`,o).then(m).then(d),verifySiteGoogle:e=>h(`${n}jetpack/v4/verify-site/google`,l,{body:JSON.stringify({keyring_id:e})}).then(m).then(d),submitSurvey:e=>h(`${n}jetpack/v4/marketing/survey`,l,{body:JSON.stringify(e)}).then(m).then(d),saveSetupQuestionnaire:e=>h(`${n}jetpack/v4/setup/questionnaire`,l,{body:JSON.stringify(e)}).then(m).then(d),updateLicensingError:e=>h(`${n}jetpack/v4/licensing/error`,l,{body:JSON.stringify(e)}).then(m).then(d),updateLicenseKey:e=>h(`${n}jetpack/v4/licensing/set-license`,l,{body:JSON.stringify({license:e})}).then(m).then(d),getUserLicensesCounts:()=>p(`${n}jetpack/v4/licensing/user/counts`,o).then(m).then(d),getUserLicenses:()=>p(`${n}jetpack/v4/licensing/user/licenses`,o).then(m).then(d),updateLicensingActivationNoticeDismiss:e=>h(`${n}jetpack/v4/licensing/user/activation-notice-dismiss`,l,{body:JSON.stringify({last_detached_count:e})}).then(m).then(d),updateRecommendationsStep:e=>h(`${n}jetpack/v4/recommendations/step`,l,{body:JSON.stringify({step:e})}).then(m),confirmIDCSafeMode:()=>h(`${n}jetpack/v4/identity-crisis/confirm-safe-mode`,l).then(m),startIDCFresh:e=>h(`${n}jetpack/v4/identity-crisis/start-fresh`,l,{body:JSON.stringify({redirect_uri:e})}).then(m).then(d),migrateIDC:()=>h(`${n}jetpack/v4/identity-crisis/migrate`,l).then(m),attachLicenses:e=>h(`${n}jetpack/v4/licensing/attach-licenses`,l,{body:JSON.stringify({licenses:e})}).then(m).then(d),fetchSearchPlanInfo:()=>p(`${r}jetpack/v4/search/plan`,o).then(m).then(d),fetchSearchSettings:()=>p(`${r}jetpack/v4/search/settings`,o).then(m).then(d),updateSearchSettings:e=>h(`${r}jetpack/v4/search/settings`,l,{body:JSON.stringify(e)}).then(m).then(d),fetchSearchStats:()=>p(`${r}jetpack/v4/search/stats`,o).then(m).then(d),fetchWafSettings:()=>p(`${n}jetpack/v4/waf`,o).then(m).then(d),updateWafSettings:e=>h(`${n}jetpack/v4/waf`,l,{body:JSON.stringify(e)}).then(m).then(d),fetchWordAdsSettings:()=>p(`${n}jetpack/v4/wordads/settings`,o).then(m).then(d),updateWordAdsSettings:e=>h(`${n}jetpack/v4/wordads/settings`,l,{body:JSON.stringify(e)}),fetchSearchPricing:()=>p(`${r}jetpack/v4/search/pricing`,o).then(m).then(d),fetchMigrationStatus:()=>p(`${n}jetpack/v4/migration/status`,o).then(m).then(d)};function p(e,t){return fetch(s(e),t)}function h(e,t,n){return fetch(e,Object.assign({},t,n)).catch(g)}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 m(e){return e.status>=200&&e.status<300?e:404===e.status?new Promise((()=>{throw e.redirected?new s(e.redirected):new l})):e.json().catch((e=>h(e))).then((t=>{const n=new Error(`${t.message} (Status ${e.status})`);throw n.response=t,n.name="ApiError",n}))}function d(e){return e.json().catch((t=>h(t,e.redirected,e.url)))}function h(e,t,n){throw t?new o(n):new i}function g(){throw new u}t.ZP=p},9105:function(e,t,n){"use strict";var a=n(5736),c=n(5235),r=n.n(c),i=n(8237),o=n(8868),l=n(3846),s=n(3363),u=n(1494);const __=a.__;t.Z=e=>{let{children:t,moduleName:n=__("Jetpack","jetpack-protect"),moduleNameHref:a,a8cLogoHref:c,showHeader:p=!0,showFooter:m=!0,showBackground:d=!0,header:h}=e;const g=r()(u.Z["admin-page"],{[u.Z.background]:d});return React.createElement("div",{className:g},p&&React.createElement(s.Z,{horizontalSpacing:5},React.createElement(l.Z,null,h||React.createElement(o.Z,null))),React.createElement(s.Z,{fluid:!0,horizontalSpacing:0},React.createElement(l.Z,null,t)),m&&React.createElement(s.Z,{horizontalSpacing:5},React.createElement(l.Z,null,React.createElement(i.Z,{moduleName:n,a8cLogoHref:c,moduleNameHref:a}))))}},216:function(e,t,n){"use strict";var a=n(9196),c=n.n(a),r=n(281);t.Z=e=>{let{children:t}=e;return c().createElement("div",{className:r.Z["section-hero"]},t)}},7525:function(e,t,n){"use strict";var a=n(2674),c=n.n(a),r=n(5736),i=n(5235),o=n.n(i),l=n(9196),s=n.n(l);const __=r.__;t.Z=e=>{let{title:t=__("An Automattic Airline","jetpack-protect"),height:n=7,className:a,...r}=e;return s().createElement("svg",c()({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:n,className:o()("jp-automattic-byline-logo",a)},r),s().createElement("desc",{id:"jp-automattic-byline-logo-title"},t),s().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"}),s().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"}),s().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"}))}},526:function(e,t,n){"use strict";var a=n(2674),c=n.n(a),r=n(5609),i=n(1074),o=n(5381),l=n(5235),s=n.n(l),u=n(9196),p=n.n(u),m=n(3466);const d=(0,u.forwardRef)(((e,t)=>{const{children:n,variant:a="primary",size:l="normal",weight:u="bold",icon:d,iconSize:h,disabled:g,isDestructive:f,isLoading:v,isExternalLink:E,className:b,text:k,fullWidth:y,...Z}=e,C=s()(m.Z.button,b,{[m.Z.normal]:"normal"===l,[m.Z.small]:"small"===l,[m.Z.icon]:Boolean(d),[m.Z.loading]:v,[m.Z.regular]:"regular"===u,[m.Z["full-width"]]:y,[m.Z["is-icon-button"]]:Boolean(d)&&!n});Z.ref=t;const _="normal"===l?20:16,w=E&&p().createElement(i.Z,{size:_,icon:o.Z,className:m.Z["external-icon"]}),R=E?"_blank":void 0,j=n?.[0]&&null!==n[0]&&"components-tooltip"!==n?.[0]?.props?.className;return p().createElement(r.Button,c()({target:R,variant:a,className:s()(C,{"has-text":!!d&&j}),icon:E?void 0:d,iconSize:h,disabled:g,"aria-disabled":g,isDestructive:f,text:k},Z),v&&p().createElement(r.Spinner,null),p().createElement("span",null,n),w)}));t.Z=d},857:function(e,t,n){"use strict";var a=n(1074),c=n(495),r=n(5235),i=n.n(r),o=n(9665),l=n(5106),s=n(1489);t.Z=e=>{let{description:t,cta:n,onClick:r,href:u,openInNewTab:p=!1,className:m,tooltipText:d=""}=e;const h=void 0!==u?"a":"button",g="a"===h?{href:u,...p&&{target:"_blank"}}:{onClick:r};return React.createElement("div",{className:i()(s.Z.cut,m)},React.createElement("div",null,React.createElement(l.ZP,{className:s.Z.description},t),d&&React.createElement(o.Z,{className:s.Z.iconContainer,iconSize:16,offset:4},React.createElement(l.ZP,{variant:"body-small"},d)),React.createElement(h,g,React.createElement(l.ZP,{className:s.Z.cta},n))),React.createElement(a.Z,{icon:c.Z,className:s.Z.icon,size:30}))}},7172:function(e,t,n){"use strict";var a=n(17),c=n.n(a),r=n(5736),i=n(5235),o=n.n(i),l=n(9196);n(5785);const __=r.__;class s extends l.Component{needsOffset(e,t){return["gridicons-arrow-left","gridicons-arrow-right","gridicons-calendar","gridicons-cart","gridicons-folder","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-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-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-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-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-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"}))}}render(){const{size:e=24,className:t=""}=this.props,n=this.props.height||e,a=this.props.width||e,c=this.props.style||{height:n,width:a},r="gridicons-"+this.props.icon,i=o()("gridicon",r,t,{"needs-offset":this.needsOffset(r,e)}),l=this.getSVGDescription(r);return React.createElement("svg",{className:i,focusable:this.props.focusable,height:n,onClick:this.props.onClick,style:c,viewBox:"0 0 24 24",width:a,xmlns:"http://www.w3.org/2000/svg","aria-hidden":this.props["aria-hidden"]},l?React.createElement("desc",null,l):null,this.renderIcon(r))}}c()(s,"defaultProps",{"aria-hidden":"false",focusable:"true"}),t.Z=s},9665:function(e,t,n){"use strict";var a=n(5609),c=n(5235),r=n.n(c),i=n(9196),o=n.n(i),l=n(526),s=n(7172);n(1275);const u=e=>({"top-end":"top left",top:"top center","top-start":"top right","bottom-end":"bottom left",bottom:"bottom center","bottom-start":"bottom right"}[e]);t.Z=e=>{let{className:t="",iconClassName:n="",placement:c="bottom-end",animate:p=!0,iconCode:m="info-outline",iconSize:d=18,offset:h=10,title:g,children:f,popoverAnchorStyle:v="icon",forceShow:E=!1}=e;const[b,k]=(0,i.useState)(!1),y=(0,i.useCallback)((()=>k(!0)),[k]),Z=(0,i.useCallback)((()=>k(!1)),[k]),C={position:u(c),placement:c,animate:p,noArrow:!1,resize:!1,flip:!1,offset:h,focusOnMount:"container",onClose:Z,className:"icon-tooltip-container"},_="wrapper"===v,w=r()("icon-tooltip-wrapper",t),R={left:_?0:-(62-d/2)+"px"},j=_&&E;return o().createElement("div",{className:w,"data-testid":"icon-tooltip_wrapper"},!_&&o().createElement(l.Z,{variant:"link",onClick:y},o().createElement(s.Z,{className:n,icon:m,size:d})),o().createElement("div",{className:"icon-tooltip-helper",style:R},(j||b)&&o().createElement(a.Popover,C,o().createElement("div",null,g&&o().createElement("div",{className:"icon-tooltip-title"},g),o().createElement("div",{className:"icon-tooltip-content"},f)))))}},3396:function(e,t,n){"use strict";n.d(t,{VS:function(){return m}});var a=n(2674),c=n.n(a),r=n(5609),i=n(5235),o=n.n(i),l=n(5612);const s=e=>{let{className:t,size:n=24,viewBox:a="0 0 24 24",opacity:i=1,color:s="#2C3338",children:u}=e;const p={className:o()(l.Z.iconWrapper,t),width:n,height:n,viewBox:a,opacity:i,fill:void 0};return s&&(p.fill=s),React.createElement(r.SVG,c()({},p,{fillRule:"evenodd",clipRule:"evenodd",xmlns:"http://www.w3.org/2000/svg"}),React.createElement(r.G,{opacity:i},u))},u=e=>{let{className:t,fill:n="none",size:a,children:c}=e;return React.createElement(s,{className:o()(l.Z.socialIcon,t),size:a,color:n},c)},p={...{"anti-spam":e=>{let{opacity:t=1,size:n,color:a}=e;return React.createElement(s,{size:n,opacity:t,color:a},React.createElement(r.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(r.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(r.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(r.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:e=>{let{opacity:t=1,size:n,color:a}=e;return React.createElement(s,{size:n,opacity:t,color:a},React.createElement(r.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:e=>{let{opacity:t=1,size:n,color:a}=e;return React.createElement(s,{size:n,opacity:t,color:a},React.createElement(r.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:e=>{let{opacity:t=1,size:n,color:a}=e;return React.createElement(s,{size:n,opacity:t,color:a},React.createElement(r.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:e=>{let{opacity:t=1,size:n,color:a}=e;return React.createElement(s,{size:n,opacity:t,color:a},React.createElement(r.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:e=>{let{opacity:t=1,size:n,className:a,color:c}=e;return React.createElement(s,{className:a,size:n,opacity:t,color:c},React.createElement(r.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(r.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:e=>{let{opacity:t=1,size:n,color:a}=e;return React.createElement(s,{size:n,opacity:t,color:a},React.createElement(r.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:e=>{let{opacity:t=1,size:n,color:a}=e;return React.createElement(s,{size:n,opacity:t,color:a},React.createElement(r.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:e=>{let{opacity:t=1,size:n,color:a}=e;return React.createElement(s,{size:n,opacity:t,color:a},React.createElement(r.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:e=>{let{size:t,className:n=l.Z["star-icon"],color:a}=e;return React.createElement(s,{className:n,size:t,color:a},React.createElement(r.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:e=>{let{opacity:t=1,size:n,color:a}=e;return React.createElement(s,{size:n,opacity:t,color:a},React.createElement(r.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:e=>{let{size:t,className:n=l.Z.jetpack,color:a}=e;return React.createElement(s,{className:n,size:t,color:a,viewBox:"0 0 32 32"},React.createElement(r.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(r.Polygon,{fill:"#fff",points:"15,19 7,19 15,3"}),React.createElement(r.Polygon,{fill:"#fff",points:"17,29 17,13 25,13"}))}},...{facebook:e=>{let{fill:t,size:n,className:a}=e;return React.createElement(u,{fill:t,size:n,className:o()(l.Z.facebook,a)},React.createElement(r.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.9c1.1,0,2.2,0.2,2.2,0.2v2.5h-1.3 c-1.2,0-1.6,0.8-1.6,1.6V12h2.8l-0.4,2.9h-2.3v7C18.3,21.1,22,17,22,12C22,6.5,17.5,2,12,2z"}))},twitter:e=>{let{fill:t,size:n,className:a}=e;return React.createElement(u,{fill:t,size:n,className:o()(l.Z.twitter,a)},React.createElement(r.Path,{d:"M19,3H5C3.895,3,3,3.895,3,5v14c0,1.105,0.895,2,2,2h14c1.105,0,2-0.895,2-2V5C21,3.895,20.105,3,19,3z M16.466,9.71 c0.004,0.099,0.007,0.198,0.007,0.298c0,3.045-2.318,6.556-6.556,6.556c-1.301,0-2.512-0.381-3.532-1.035 c0.18,0.021,0.364,0.032,0.55,0.032c1.079,0,2.073-0.368,2.862-0.986c-1.008-0.019-1.859-0.685-2.152-1.6 c0.141,0.027,0.285,0.041,0.433,0.041c0.21,0,0.414-0.028,0.607-0.081c-1.054-0.212-1.848-1.143-1.848-2.259 c0-0.01,0-0.019,0-0.029c0.311,0.173,0.666,0.276,1.044,0.288c-0.618-0.413-1.025-1.118-1.025-1.918 c0-0.422,0.114-0.818,0.312-1.158c1.136,1.394,2.834,2.311,4.749,2.407c-0.039-0.169-0.06-0.344-0.06-0.525 c0-1.272,1.032-2.304,2.304-2.304c0.663,0,1.261,0.28,1.682,0.728c0.525-0.103,1.018-0.295,1.463-0.559 c-0.172,0.538-0.537,0.99-1.013,1.275c0.466-0.056,0.91-0.18,1.323-0.363C17.306,8.979,16.916,9.385,16.466,9.71z"}))},linkedin:e=>{let{fill:t,size:n,className:a}=e;return React.createElement(u,{fill:t,size:n,className:o()(l.Z.linkedin,a)},React.createElement(r.Path,{d:"M19.7 3H4.3C3.582 3 3 3.582 3 4.3v15.4c0 .718.582 1.3 1.3 1.3h15.4c.718 0 1.3-.582 1.3-1.3V4.3c0-.718-.582-1.3-1.3-1.3zM8.34 18.338H5.666v-8.59H8.34v8.59zM7.003 8.574c-.857 0-1.55-.694-1.55-1.548 0-.855.692-1.548 1.55-1.548.854 0 1.547.694 1.547 1.548 0 .855-.692 1.548-1.546 1.548zm11.335 9.764h-2.67V14.16c0-.995-.017-2.277-1.387-2.277-1.39 0-1.6 1.086-1.6 2.206v4.248h-2.668v-8.59h2.56v1.174h.036c.357-.675 1.228-1.387 2.527-1.387 2.703 0 3.203 1.78 3.203 4.092v4.71z"}))},tumblr:e=>{let{fill:t,size:n,className:a}=e;return React.createElement(u,{fill:t,size:n,className:o()(l.Z.tumblr,a)},React.createElement(r.Path,{d:"M19 3H5c-1.105 0-2 .895-2 2v14c0 1.105.895 2 2 2h14c1.105 0 2-.895 2-2V5c0-1.105-.895-2-2-2zm-5.57 14.265c-2.445.042-3.37-1.742-3.37-2.998V10.6H8.922V9.15c1.703-.615 2.113-2.15 2.21-3.026.006-.06.053-.084.08-.084h1.645V8.9h2.246v1.7H12.85v3.495c.008.476.182 1.13 1.08 1.107.3-.008.698-.094.907-.194l.54 1.6c-.205.297-1.12.642-1.946.657z"}))},google:e=>{let{fill:t,size:n,className:a}=e;return React.createElement(u,{fill:t,size:n,className:o()(l.Z.google,a)},React.createElement(r.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.05h-9.36z"}))},mastodon:e=>{let{fill:t,size:n,className:a}=e;return React.createElement(u,{fill:t,size:n,className:o()(l.Z.mastodon,a)},React.createElement(r.Path,{d:"M 19.997205,6.2868955 C 19.729197,4.3162778 17.992912,2.7633017 15.93468,2.4623753 15.587434,2.4115195 14.271759,2.2264681 11.224008,2.2264681 h -0.02277 c -3.0485688,0 -3.7026204,0.1850577 -4.0498676,0.2359072 C 5.1504449,2.7549655 3.3231548,4.1503966 2.879815,6.1443318 2.6665754,7.1263038 2.6438193,8.2149794 2.6834329,9.2136207 c 0.056471,1.4321143 0.067433,2.8617113 0.1989115,4.2879943 0.090908,0.947406 0.2494696,1.887266 0.4745239,2.812521 0.4214237,1.708868 2.1273496,3.130966 3.7987144,3.71116 1.7894479,0.605052 3.7138403,0.705478 5.5577463,0.290088 0.202828,-0.04667 0.403445,-0.100873 0.601781,-0.162549 0.447558,-0.140863 0.972662,-0.298434 1.358683,-0.575188 0.0052,-0.004 0.0097,-0.0089 0.01266,-0.01471 0.0031,-0.0056 0.0047,-0.01218 0.005,-0.01866 v -1.382076 c -9.4e-5,-0.006 -0.0016,-0.01202 -0.0043,-0.01754 -0.0027,-0.0054 -0.0067,-0.01028 -0.01155,-0.01392 -0.0049,-0.0038 -0.01044,-0.0063 -0.01648,-0.0078 -0.006,-0.0013 -0.01218,-0.0013 -0.01825,7.1e-5 -1.181368,0.279106 -2.391962,0.419012 -3.606552,0.416801 -2.0902554,0 -2.6524392,-0.981126 -2.8134375,-1.3896 -0.1293933,-0.353009 -0.2115739,-0.721231 -0.2444221,-1.095331 -3.29e-4,-0.0063 8.463e-4,-0.0125 0.00348,-0.01832 0.00253,-0.0056 0.00649,-0.01077 0.011389,-0.01471 0.0049,-0.004 0.010755,-0.0068 0.016957,-0.0081 0.00617,-0.0014 0.012655,-0.0012 0.018808,3.52e-4 1.1616831,0.277201 2.3525266,0.417106 3.5475526,0.416801 0.287408,0 0.573966,0 0.861395,-0.0074 1.201893,-0.03335 2.468685,-0.0942 3.6512,-0.322606 0.02952,-0.0058 0.059,-0.01091 0.0843,-0.01833 1.865209,-0.354279 3.640245,-1.466278 3.820617,-4.282163 0.0068,-0.110869 0.0236,-1.161191 0.0236,-1.276219 8.46e-4,-0.390958 0.127273,-2.7733487 -0.01856,-4.2371335 z m -2.87074,7.0263315 H 15.165179 V 8.5617567 c 0,-1.0003116 -0.421434,-1.5104614 -1.278618,-1.5104614 -0.942305,0 -1.414292,0.6035217 -1.414292,1.7955379 V 11.44764 H 10.522764 V 8.8468332 c 0,-1.1920162 -0.472832,-1.7955379 -1.4151372,-1.7955379 -0.8521293,0 -1.2777701,0.5101498 -1.2786179,1.5104614 V 13.313227 H 5.8693944 V 8.4175496 c 0,-1.0003133 0.2582014,-1.7949986 0.7745804,-2.3840846 0.5326766,-0.587672 1.2314038,-0.8894211 2.0986981,-0.8894211 1.003817,0 1.7623841,0.3817657 2.2680911,1.1445204 l 0.488023,0.8102521 0.488846,-0.8102521 c 0.505705,-0.7627547 1.264275,-1.1445204 2.26642,-1.1445204 0.866449,0 1.565152,0.3017491 2.099521,0.8894211 0.516404,0.5885211 0.774583,1.3832066 0.774583,2.3840846 z"}))}}};function m(e){return p[e]?p[e]:null}},8237:function(e,t,n){"use strict";var a=n(2674),c=n.n(a),r=n(5736),i=n(5235),o=n.n(i),l=n(9196),s=n.n(l),u=n(7525),p=(n(9054),n(8868));const __=r.__;t.Z=e=>{let{a8cLogoHref:t="https://automattic.com",moduleName:n=__("Jetpack","jetpack-protect"),className:a,moduleNameHref:r="https://jetpack.com",...i}=e;return s().createElement("div",c()({className:o()("jp-dashboard-footer",a)},i),s().createElement("div",{className:"jp-dashboard-footer__footer-left"},s().createElement(p.Z,{logoColor:"#000",showText:!1,height:16,className:"jp-dashboard-footer__jetpack-symbol","aria-label":__("Jetpack logo","jetpack-protect")}),s().createElement("span",{className:"jp-dashboard-footer__module-name"},r?s().createElement("a",{href:r,"aria-label":n},n):n)),s().createElement("div",{className:"jp-dashboard-footer__footer-right"},s().createElement("a",{href:t,"aria-label":__("An Automattic Airline","jetpack-protect")},s().createElement(u.Z,null))))}},8868:function(e,t,n){"use strict";var a=n(2674),c=n.n(a),r=n(5736),i=n(5235),o=n.n(i),l=n(9196),s=n.n(l);const __=r.__;t.Z=e=>{let{logoColor:t="#069e08",showText:n=!0,className:a,height:r=32,...i}=e;const l=n?"0 0 118 32":"0 0 32 32";return s().createElement("svg",c()({xmlns:"http://www.w3.org/2000/svg",x:"0px",y:"0px",viewBox:l,className:o()("jetpack-logo",a),"aria-labelledby":"jetpack-logo-title",height:r},i),s().createElement("desc",{id:"jetpack-logo-title"},__("Jetpack Logo","jetpack-protect")),s().createElement("path",{fill:t,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"}),n&&s().createElement(s().Fragment,null,s().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"}),s().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"}),s().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"}),s().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"}),s().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"}),s().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"}),s().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"})))}},3846:function(e,t,n){"use strict";var a=n(5235),c=n.n(a),r=n(3080);const i=Number(r.Z.smCols),o=Number(r.Z.mdCols),l=Number(r.Z.lgCols);t.Z=e=>{const{children:t,className:n}=e,a=Math.min(i,"number"==typeof e.sm?e.sm:i),s=Math.min(i,"object"==typeof e.sm?e.sm.start:0),u=Math.min(i,"object"==typeof e.sm?e.sm.end:0),p=Math.min(o,"number"==typeof e.md?e.md:o),m=Math.min(o,"object"==typeof e.md?e.md.start:0),d=Math.min(o,"object"==typeof e.md?e.md.end:0),h=Math.min(l,"number"==typeof e.lg?e.lg:l),g=Math.min(l,"object"==typeof e.lg?e.lg.start:0),f=Math.min(l,"object"==typeof e.lg?e.lg.end:0),v=c()(n,{[r.Z[`col-sm-${a}`]]:!(s&&u),[r.Z[`col-sm-${s}-start`]]:s>0,[r.Z[`col-sm-${u}-end`]]:u>0,[r.Z[`col-md-${p}`]]:!(m&&d),[r.Z[`col-md-${m}-start`]]:m>0,[r.Z[`col-md-${d}-end`]]:d>0,[r.Z[`col-lg-${h}`]]:!(g&&f),[r.Z[`col-lg-${g}-start`]]:g>0,[r.Z[`col-lg-${f}-end`]]:f>0});return React.createElement("div",{className:v},t)}},3363:function(e,t,n){"use strict";var a=n(5235),c=n.n(a),r=n(9196),i=n(8730);t.Z=e=>{let{children:t,fluid:n=!1,className:a,horizontalGap:o=1,horizontalSpacing:l=1}=e;const s=(0,r.useMemo)((()=>{const e=`calc( var(--horizontal-spacing) * ${l} )`;return{paddingTop:e,paddingBottom:e,rowGap:`calc( var(--horizontal-spacing) * ${o} )`}}),[o,l]),u=c()(a,i.Z.container,{[i.Z.fluid]:n});return React.createElement("div",{className:u,style:s},t)}},2054:function(e,t,n){"use strict";var a=n(4333),c=n(3247);const r=["sm","md","lg"];t.Z=(e,t)=>{const n=Array.isArray(e)?e:[e],i=Array.isArray(t)?t:[t],[o,l,s]=r,u={sm:(0,a.useMediaQuery)(c.Z[o]),md:(0,a.useMediaQuery)(c.Z[l]),lg:(0,a.useMediaQuery)(c.Z[s])};return n.map(((e,t)=>{const n=i[t];return n?((e,t,n)=>{const a=r.indexOf(e),c=a+1,i=t.includes("=");let o=[];return t.startsWith("<")&&(o=r.slice(0,i?c:a)),t.startsWith(">")&&(o=r.slice(i?a:c)),o?.length?o.some((e=>n[e])):n[e]})(e,n,u):u[e]}))}},1342:function(e,t,n){"use strict";var a=n(797),c=n(496),r=n(9201),i=n(1074),o=n(9517),l=n(5235),s=n.n(l),u=n(9196),p=n.n(u),m=n(7703);const d=e=>{switch(e){case"error":case"warning":default:return a.Z;case"info":return c.Z;case"success":return r.Z}},h=e=>{let{level:t,title:n,children:a,actions:c,hideCloseButton:r,onClose:l}=e;const u=s()(m.Z.container,m.Z[`is-${t}`]);return p().createElement("div",{className:u},p().createElement("div",{className:m.Z["icon-wrapper"]},p().createElement(i.Z,{icon:d(t),className:m.Z.icon})),p().createElement("div",{className:m.Z["main-content"]},p().createElement("div",{className:m.Z.title},n),a,c&&c.length>0&&p().createElement("div",{className:m.Z["action-bar"]},c.map(((e,t)=>p().createElement("div",{key:t,className:m.Z.action},e))))),!r&&p().createElement("button",{"aria-label":"close",className:m.Z["close-button"],onClick:l},p().createElement(i.Z,{icon:o.Z})))};h.defaultProps={level:"info",hideCloseButton:!1},t.Z=h},9608:function(e,t,n){"use strict";n.d(t,{NE:function(){return y},kF:function(){return k},oK:function(){return Z}});var a=n(5736),c=n(1074),r=n(9201),i=n(6163),o=n(5235),l=n.n(o),s=n(9196),u=n.n(s),p=n(9665),m=n(2054),d=n(7325),h=n(5106),g=n(9929);const __=a.__,f=__("Included","jetpack-protect"),v=__("Not included","jetpack-protect"),E=__("Coming soon","jetpack-protect"),b=(0,s.createContext)(void 0),k=e=>{let{isIncluded:t=!1,isComingSoon:n=!1,index:o=0,label:d=null,tooltipInfo:k,tooltipTitle:y,tooltipClassName:Z=""}=e;const[C]=(0,m.Z)("lg"),_=(0,s.useContext)(b)[o],w=n||t,R=_.name,j=_.tooltipInfo,N=_.tooltipTitle,S=k||!C&&j,P=((e,t,n)=>e?{lg:E, -// translators: Name of the current feature -default:(0,a.sprintf)(__("%s coming soon","jetpack-protect"),n)}:{lg:t?f:v,default:t?n:(0,a.sprintf)(/* translators: Name of the current feature */ -__("%s not included","jetpack-protect"),n)})(n,t,R),x=C?P.lg:P.default;return u().createElement("div",{className:l()(g.Z.item,g.Z.value)},u().createElement(c.Z,{className:l()(g.Z.icon,w?g.Z["icon-check"]:g.Z["icon-cross"]),size:32,icon:w?r.Z:i.Z}),u().createElement(h.ZP,{variant:"body-small"},d||x),S&&u().createElement(p.Z,{title:y||N,iconClassName:g.Z["popover-icon"],className:l()(g.Z.popover,Z),placement:"bottom-end",iconSize:14,offset:4},u().createElement(h.ZP,{variant:"body-small"},k||j)))},y=e=>{let{children:t}=e;return u().createElement("div",{className:g.Z.header},t)},Z=e=>{let{primary:t=!1,children:n}=e,a=0;return u().createElement("div",{className:l()(g.Z.card,{[g.Z["is-primary"]]:t})},s.Children.map(n,(e=>{const t=e;return t.type===k?(a++,(0,s.cloneElement)(t,{index:a-1})):t})))};t.ZP=e=>{let{title:t,items:n,children:a,showIntroOfferDisclaimer:c=!1}=e;const[r]=(0,m.Z)("lg");return u().createElement(b.Provider,{value:n},u().createElement("div",{className:l()(g.Z.container,{[g.Z["is-viewport-large"]]:r}),style:{"--rows":n.length+1,"--columns":s.Children.toArray(a).length+1}},u().createElement("div",{className:g.Z.table},u().createElement(h.ZP,{variant:"headline-small"},t),r&&n.map(((e,t)=>u().createElement("div",{className:l()(g.Z.item,{[g.Z["last-feature"]]:t===n.length-1}),key:t},u().createElement(h.ZP,{variant:"body-small"},u().createElement("strong",null,e.name)),e.tooltipInfo&&u().createElement(p.Z,{title:e.tooltipTitle,iconClassName:g.Z["popover-icon"],className:g.Z.popover,placement:"bottom-end",iconSize:14,offset:4},u().createElement(h.ZP,{variant:"body-small"},e.tooltipInfo))))),a)),u().createElement("div",{className:g.Z["tos-container"]},u().createElement("div",{className:g.Z.tos},c&&u().createElement(h.ZP,{variant:"body-small"},__("Reduced pricing is a limited offer for the first year and renews at regular price.","jetpack-protect")),u().createElement(d.Z,{multipleButtons:!0}))))}},5347:function(e,t,n){"use strict";var a=n(5736),c=n(5235),r=n.n(c),i=n(5106),o=n(3789),l=n(9184);const __=a.__;t.Z=e=>{let{price:t,offPrice:n,currency:a="",showNotOffPrice:c=!0,hideDiscountLabel:s=!0,promoLabel:u="",legend:p=__("/month, paid yearly","jetpack-protect"),isNotConvenientPrice:m=!1,hidePriceFraction:d=!1,children:h}=e;if(null==t&&null==n||!a)return null;c=c&&null!=n;const g="number"==typeof t&&"number"==typeof n?Math.floor((t-n)/t*100):0,f=!s&&g&&g>0?g+__("% off","jetpack-protect"):null;return React.createElement(React.Fragment,null,React.createElement("div",{className:l.Z.container},React.createElement("div",{className:r()(l.Z["price-container"],"product-price_container")},React.createElement(o.t,{value:n??t,currency:a,isOff:!m,hidePriceFraction:d}),c&&React.createElement(o.t,{value:t,currency:a,isOff:!1,hidePriceFraction:d}))),React.createElement("div",{className:l.Z.footer},h||React.createElement(i.ZP,{className:r()(l.Z.legend,"product-price_legend")},p),u&&React.createElement(i.ZP,{className:r()(l.Z["promo-label"],"product-price_promo_label")},u),f&&React.createElement(i.ZP,{className:r()(l.Z["promo-label"],"product-price_promo_label")},f)))}},3789:function(e,t,n){"use strict";n.d(t,{t:function(){return l}});var a=n(8899),c=n(5235),r=n.n(c),i=n(5106),o=n(9184);const l=e=>{let{value:t,currency:n,isOff:c,hidePriceFraction:l}=e;const s=r()(o.Z.price,"product-price_price",{[o.Z["is-not-off-price"]]:!c}),{symbol:u,integer:p,fraction:m}=(0,a.LR)(t,n),d=!l||!m.endsWith("00");return React.createElement(i.ZP,{className:s,variant:"headline-medium",component:"p"},React.createElement(i.ZP,{className:o.Z.symbol,component:"sup",variant:"title-medium"},u),p,d&&React.createElement(i.ZP,{component:"sup",variant:"body-small","data-testid":"PriceFraction"},React.createElement("strong",null,m)))}},5033:function(e,t,n){"use strict";var a=n(5162),c=n.n(a),r=n(9196),i=n.n(r);n(1683);const o=e=>{const t=e.className+" jp-components-spinner",n={width:e.size,height:e.size,fontSize:e.size,borderTopColor:e.color},a={borderTopColor:e.color,borderRightColor:e.color};return i().createElement("div",{className:t},i().createElement("div",{className:"jp-components-spinner__outer",style:n},i().createElement("div",{className:"jp-components-spinner__inner",style:a})))};o.propTypes={color:c().string,className:c().string,size:c().number},o.defaultProps={color:"#FFFFFF",className:"",size:20},t.Z=o},7325:function(e,t,n){"use strict";var a=n(9307),c=n(5736),r=n(5235),i=n.n(r),o=n(6895),l=n(5106);n(7920);const __=c.__,s=()=>(0,a.createInterpolateElement)(__("By clicking the buttons above, you agree to our Terms of Service and to share details with WordPress.com.","jetpack-protect"),{tosLink:React.createElement(p,{slug:"wpcom-tos"}),shareDetailsLink:React.createElement(p,{slug:"jetpack-support-what-data-does-jetpack-sync"})}),u=e=>{let{agreeButtonLabel:t}=e;return(0,a.createInterpolateElement)((0,c.sprintf)(/* translators: %s is a button label */ -__("By clicking the %s button, you agree to our Terms of Service and to share details with WordPress.com.","jetpack-protect"),t),{strong:React.createElement("strong",null),tosLink:React.createElement(p,{slug:"wpcom-tos"}),shareDetailsLink:React.createElement(p,{slug:"jetpack-support-what-data-does-jetpack-sync"})})},p=e=>{let{slug:t,children:n}=e;return React.createElement("a",{className:"terms-of-service__link",href:(0,o.Z)(t),rel:"noopener noreferrer",target:"_blank"},n)};t.Z=e=>{let{className:t,multipleButtons:n,agreeButtonLabel:a}=e;return React.createElement(l.ZP,{className:i()(t,"terms-of-service")},n?React.createElement(s,null):React.createElement(u,{agreeButtonLabel:a}))}},6017:function(e,t,n){"use strict";n.d(t,{h:function(){return a},s:function(){return c}});const a={"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"},c=["mt","mr","mb","ml","mx","my","m","pt","pr","pb","pl","px","py","p"]},5106:function(e,t,n){"use strict";n.d(t,{Dx:function(){return d},H3:function(){return m}});var a=n(2674),c=n.n(a),r=n(5235),i=n.n(r),o=n(9196),l=n.n(o),s=n(6017),u=n(3280);const p=(0,o.forwardRef)(((e,t)=>{let{variant:n="body",children:a,component:r,className:p,...m}=e;const d=r||s.h[n]||"span",h=(0,o.useMemo)((()=>s.s.reduce(((e,t)=>(void 0!==m[t]&&(e+=u.Z[`${t}-${m[t]}`]+" ",delete m[t]),e)),"")),[m]);return m.ref=t,l().createElement(d,c()({className:i()(u.Z.reset,u.Z[n],p,h)},m),a)}));t.ZP=p;const m=e=>{let{children:t,weight:n="bold",...a}=e;const r="headline-small"+("bold"===n?"":`-${n}`);return l().createElement(p,c()({variant:r,mb:3},a),t)},d=e=>{let{children:t,size:n="medium",...a}=e;return l().createElement(p,c()({variant:`title-${n}`,mb:1},a),t)}},8275:function(e,t,n){"use strict";var a=n(9196),c=n.n(a),r=n(3591);const i={"--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)"},o={"--jp-black":"#000000","--jp-black-80":"#2c3338","--jp-white":"#ffffff","--jp-white-off":"#f9f9f6","--jp-gray":"#dcdcde","--jp-gray-0":"#F6F7F7","--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 )"},l={"--jp-border-radius":"4px","--jp-menu-border-height":"1px","--jp-underline-thickness":"2px"},s={"--spacing-base":"8px"},u={},p=(e,t,n)=>{const a={...i,...o,...l,...s};for(const t in a)e.style.setProperty(t,a[t]);n&&e.classList.add(r.Z.global),t&&(u[t]={provided:!0,root:e})};t.ZP=e=>{let{children:t=null,targetDom:n,id:r,withGlobalStyles:i=!0}=e;const o=(0,a.useRef)(),l=u?.[r]?.provided;return(0,a.useLayoutEffect)((()=>{if(!l)return n?p(n,r,i):void(o?.current&&p(o.current,r,i))}),[n,o,l,r,i]),n?t:c().createElement("div",{ref:o},t)}},4153:function(e,t,n){"use strict";function a(e,t,n,a){const c=new URL("https://wordpress.com/checkout/"),r=new URL(`${c}${t}/${e}`);return r.searchParams.set("redirect_to",n),a||r.searchParams.set("unlinked","1"),r.searchParams.set("site",t),r.toString()}n.d(t,{Z:function(){return a}})},6895:function(e,t,n){"use strict";function a(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const n={};let a;if("undefined"!=typeof window&&(a=window.Initial_State?.calypsoEnv),0===e.search("https://")){const t=new URL(e);e=`https://${t.host}${t.pathname}`,n.url=encodeURIComponent(e)}else n.source=encodeURIComponent(e);Object.keys(t).map((e=>{n[e]=encodeURIComponent(t[e])})),!Object.keys(n).includes("site")&&"undefined"!=typeof jetpack_redirects&&jetpack_redirects.hasOwnProperty("currentSiteRawUrl")&&(n.site=jetpack_redirects.currentSiteRawUrl),a&&(n.calypso_env=a);return"https://jetpack.com/redirect/?"+Object.keys(n).map((e=>e+"="+n[e])).join("&")}n.d(t,{Z:function(){return a}})},1132:function(e,t,n){let a={};try{a=n(6436)}catch{console.error("jetpackConfig is missing in your webpack config file. See @automattic/jetpack-config"),a={missingConfig:!0}}const c=e=>a.hasOwnProperty(e);e.exports={jetpackConfigHas:c,jetpackConfigGet:e=>{if(!c(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 a[e]}}},6186:function(e,t,n){"use strict";var a=n(2054),c=n(5033),r=n(5609),i=n(5736),o=n(5162),l=n.n(o),s=n(9196),u=n.n(s),p=n(9836);const __=i.__,m=e=>{const{message:t,isRestoringConnection:n,restoreConnectionCallback:o,restoreConnectionError:l}=e,[s]=(0,a.Z)(["md"],[">"]),m=p.Z.notice+(s?" "+p.Z["bigger-than-medium"]:""),d=u().createElement(r.Icon,{icon:u().createElement(r.SVG,{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},u().createElement(r.Path,{d:"M11.7815 4.93772C11.8767 4.76626 12.1233 4.76626 12.2185 4.93772L20.519 19.8786C20.6116 20.0452 20.4911 20.25 20.3005 20.25H3.69951C3.50889 20.25 3.3884 20.0452 3.48098 19.8786L11.7815 4.93772Z",stroke:"#D63638",strokeWidth:"1.5"}),u().createElement(r.Path,{d:"M13 10H11V15H13V10Z",fill:"#D63638"}),u().createElement(r.Path,{d:"M13 16H11V18H13V16Z",fill:"#D63638"}))});if(!t)return null;if(n)return u().createElement(r.Notice,{status:"error",isDismissible:!1,className:m},u().createElement("div",{className:p.Z.message},u().createElement(c.Z,{color:"#B32D2E",size:24}),__("Reconnecting Jetpack","jetpack-protect")));const h=l?u().createElement(r.Notice,{status:"error",isDismissible:!1,className:m+" "+p.Z.error},u().createElement("div",{className:p.Z.message},d,(0,i.sprintf)(/* translators: placeholder is the error. */ -__("There was an error reconnecting Jetpack. Error: %s","jetpack-protect"),l))):null;return u().createElement(u().Fragment,null,h,u().createElement(r.Notice,{status:"error",isDismissible:!1,className:m},u().createElement("div",{className:p.Z.message},d,t),o&&u().createElement("a",{onClick:o,onKeyDown:o,className:p.Z.button,href:"#"},__("Restore Connection","jetpack-protect"))))};m.propTypes={message:l().string.isRequired,restoreConnectionCallback:l().func,isRestoringConnection:l().bool,restoreConnectionError:l().string},t.Z=m},1294:function(e,t,n){"use strict";var a=n(4743),c=n(9818),r=n(9196),i=n(428);const o=window?.JP_CONNECTION_INITIAL_STATE?window.JP_CONNECTION_INITIAL_STATE:{};t.Z=function(){let{registrationNonce:e=o.registrationNonce,apiRoot:t=o.apiRoot,apiNonce:n=o.apiNonce,redirectUri:l,autoTrigger:s,from:u,skipUserConnection:p}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const{registerSite:m,connectUser:d,refreshConnectedPlugins:h}=(0,c.useDispatch)(i.t),g=(0,c.useSelect)((e=>e(i.t).getRegistrationError())),{siteIsRegistering:f,userIsConnecting:v,userConnectionData:E,connectedPlugins:b,connectionErrors:k,isRegistered:y,isUserConnected:Z,hasConnectedOwner:C}=(0,c.useSelect)((e=>({siteIsRegistering:e(i.t).getSiteIsRegistering(),userIsConnecting:e(i.t).getUserIsConnecting(),userConnectionData:e(i.t).getUserConnectionData(),connectedPlugins:e(i.t).getConnectedPlugins(),connectionErrors:e(i.t).getConnectionErrors(),...e(i.t).getConnectionStatus()}))),_=()=>p?l?(window.location=l,Promise.resolve(l)):Promise.resolve():d({from:u,redirectUri:l}),w=t=>(t&&t.preventDefault(),y?_():m({registrationNonce:e,redirectUri:l}).then((()=>_())));return(0,r.useEffect)((()=>{a.ZP.setApiRoot(t),a.ZP.setApiNonce(n)}),[t,n]),(0,r.useEffect)((()=>{!s||f||v||w()}),[]),{handleRegisterSite:w,handleConnectUser:_,refreshConnectedPlugins:h,isRegistered:y,isUserConnected:Z,siteIsRegistering:f,userIsConnecting:v,registrationError:g,userConnectionData:E,hasConnectedOwner:C,connectedPlugins:b,connectionErrors:k}}},3329:function(e,t,n){"use strict";n.d(t,{Z:function(){return i},h:function(){return o}});var a=n(6186),c=n(1294),r=n(1045);function i(){const{connectionErrors:e}=(0,c.Z)({}),t=Object.values(e).shift(),n=t&&Object.values(t).length&&Object.values(t).shift().error_message;return{hasConnectionError:Boolean(n),connectionErrorMessage:n}}const o=()=>{const{hasConnectionError:e,connectionErrorMessage:t}=i(),{restoreConnection:n,isRestoringConnection:c,restoreConnectionError:o}=(0,r.Z)();return e?React.createElement(a.Z,{isRestoringConnection:c,restoreConnectionError:o,restoreConnectionCallback:n,message:t}):null}},8258:function(e,t,n){"use strict";n.d(t,{Z:function(){return f}});var a=n(4743),c=n(4153),r=n(9818),i=n(951),o=n.n(i),l=n(9196),s=n(1294),u=n(428);const p=o()("jetpack:connection:useProductCheckoutWorkflow"),{registrationNonce:m,apiRoot:d,apiNonce:h,siteSuffix:g}=window?.JP_CONNECTION_INITIAL_STATE?window.JP_CONNECTION_INITIAL_STATE:{};function f(){let{productSlug:e,redirectUrl:t,siteSuffix:n=g,siteProductAvailabilityHandler:i=null,from:o}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};p("productSlug is %s",e),p("redirectUrl is %s",t),p("siteSuffix is %s",n),p("from is %s",o);const[f,v]=(0,l.useState)(!1),{registerSite:E}=(0,r.useDispatch)(u.t),{isUserConnected:b,isRegistered:k,handleConnectUser:y}=(0,s.Z)({redirectUri:t,from:o}),Z=(0,c.Z)(e,n,t,b);p("checkoutProductUrl is %s",Z),p("isUserConnected is %s",b);const C=()=>Promise.resolve(i&&i()).then((e=>{if(e)return p("handleAfterRegistration: Site has a product associated"),y();p("handleAfterRegistration: Site does not have a product associated. Redirecting to checkout %s",Z),window.location.href=Z}));return(0,l.useEffect)((()=>{a.ZP.setApiRoot(d),a.ZP.setApiNonce(h)}),[]),{run:e=>{if(e&&e.preventDefault(),v(!0),k)return C();E({registrationNonce:m,redirectUri:t}).then(C)},isRegistered:k,hasCheckoutStarted:f}}},1045:function(e,t,n){"use strict";n.d(t,{Z:function(){return s}});var a=n(4743),c=n(9818),r=n(9196),i=n(428);const{apiRoot:o,apiNonce:l}=window?.JP_CONNECTION_INITIAL_STATE?window.JP_CONNECTION_INITIAL_STATE:{};function s(){const[e,t]=(0,r.useState)(!1),[n,s]=(0,r.useState)(null),{disconnectUserSuccess:u}=(0,c.useDispatch)(i.t),p="/wp-admin/admin.php?page=my-jetpack#/connection";return(0,r.useEffect)((()=>{a.ZP.setApiRoot(o),a.ZP.setApiNonce(l)}),[]),{restoreConnection:function(){let e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return t(!0),s(null),a.ZP.reconnect().then((t=>("in_progress"===t.status?(u(),e&&(window.location.href=p)):window.location.reload(),t))).catch((e=>{throw s(e),t(!1),e}))},isRestoringConnection:e,restoreConnectionError:n}}},7523:function(e,t,n){"use strict";n.d(t,{LI:function(){return r},N4:function(){return o},Qo:function(){return d},T1:function(){return s},TS:function(){return p},ZP:function(){return C},b5:function(){return g},i6:function(){return c},qV:function(){return l},r7:function(){return i},wQ:function(){return h}});var a=n(4743);const c="SET_CONNECTION_STATUS",r="SET_CONNECTION_STATUS_IS_FETCHING",i="SET_SITE_IS_REGISTERING",o="SET_USER_IS_CONNECTING",l="SET_REGISTRATION_ERROR",s="CLEAR_REGISTRATION_ERROR",u="REGISTER_SITE",p="SET_AUTHORIZATION_URL",m="CONNECT_USER",d="DISCONNECT_USER_SUCCESS",h="SET_CONNECTED_PLUGINS",g="SET_CONNECTION_ERRORS",f=e=>({type:c,connectionStatus:e}),v=e=>({type:i,isRegistering:e}),E=e=>({type:o,isConnecting:e}),b=e=>({type:l,registrationError:e}),k=()=>({type:s}),y=e=>({type:p,authorizationUrl:e}),Z=e=>({type:h,connectedPlugins:e});const C={setConnectionStatus:f,setConnectionStatusIsFetching:e=>({type:r,isFetching:e}),fetchConnectionStatus:()=>({type:"FETCH_CONNECTION_STATUS"}),fetchAuthorizationUrl:e=>({type:"FETCH_AUTHORIZATION_URL",redirectUri:e}),setSiteIsRegistering:v,setUserIsConnecting:E,setRegistrationError:b,clearRegistrationError:k,setAuthorizationUrl:y,registerSite:function(e){let{registrationNonce:t,redirectUri:n}=e;return function*(){yield k(),yield v(!0);try{const e=yield{type:u,registrationNonce:t,redirectUri:n};return yield f({isRegistered:!0}),yield y(e.authorizeUrl),yield v(!1),Promise.resolve(e)}catch(e){return yield b(e),yield v(!1),Promise.reject(e)}}()},connectUser:function(){let{from:e,redirectFunc:t,redirectUri:n}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return function*(){yield E(!0),yield{type:m,from:e,redirectFunc:t,redirectUri:n}}()},disconnectUserSuccess:()=>({type:d}),setConnectedPlugins:Z,refreshConnectedPlugins:()=>async e=>{let{dispatch:t}=e;return await new Promise((e=>a.ZP.fetchConnectedPlugins().then((n=>{t(Z(n)),e(n)}))))},setConnectionErrors:e=>({type:g,connectionErrors:e})}},1432:function(e,t,n){"use strict";var a=n(4743),c=n(9818),r=n(7057);const i=(0,c.createRegistryControl)((e=>{let{resolveSelect:t}=e;return function(){let{from:e,redirectFunc:n,redirectUri:a}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return new Promise(((c,i)=>{t(r.Z).getAuthorizationUrl(a).then((t=>{const a=n||(e=>window.location.assign(e)),r=new URL(t);e&&r.searchParams.set("from",encodeURIComponent(e));const i=r.toString();a(i),c(i)})).catch((e=>{i(e)}))}))}}));t.Z={FETCH_AUTHORIZATION_URL:e=>{let{redirectUri:t}=e;return a.ZP.fetchAuthorizationUrl(t)},REGISTER_SITE:e=>{let{registrationNonce:t,redirectUri:n}=e;return a.ZP.registerSite(t,n)},CONNECT_USER:i}},1479:function(e,t,n){"use strict";var a=n(9818),c=n(7523);const r=(0,a.combineReducers)({connectionStatus:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case c.i6:return{...e,...t.connectionStatus};case c.Qo:return{...e,isUserConnected:!1}}return e},connectionStatusIsFetching:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;return t.type===c.LI?t.isFetching:e},siteIsRegistering:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;return t.type===c.r7?t.isRegistering:e},userIsConnecting:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;return t.type===c.N4?t.isConnecting:e},registrationError:(e,t)=>{switch(t.type){case c.T1:return!1;case c.qV:return t.registrationError;default:return e}},authorizationUrl:(e,t)=>t.type===c.TS?t.authorizationUrl:e,userConnectionData:(e,t)=>(t.type,e),connectedPlugins:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return t.type===c.wQ?t.connectedPlugins:e},connectionErrors:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return t.type===c.b5?t.connectionErrors:e}});t.Z=r},7728:function(e,t,n){"use strict";var a=n(9818),c=n(7523),r=n(7057);const i={getAuthorizationUrl:{isFulfilled:function(e){const t=Boolean(e.authorizationUrl);for(var n=arguments.length,c=new Array(n>1?n-1:0),i=1;ie.connectionStatus||{},getConnectionStatusIsFetching:()=>!1,getSiteIsRegistering:e=>e.siteIsRegistering||!1,getUserIsConnecting:e=>e.userIsConnecting||!1,getRegistrationError:e=>e.registrationError||!1,getAuthorizationUrl:e=>e.authorizationUrl||!1,getUserConnectionData:e=>e.userConnectionData||!1,getConnectedPlugins:e=>e.connectedPlugins||[],getConnectionErrors:e=>e.connectionErrors||[],getWpcomUser:e=>e?.userConnectionData?.currentUser?.wpcomUser,getBlogId:e=>e?.userConnectionData?.currentUser?.blogId}};t.Z=n},3535:function(e,t,n){"use strict";var a=n(17),c=n.n(a),r=n(9818);class i{static mayBeInit(e,t){null===i.store&&(i.store=(0,r.createReduxStore)(e,t),(0,r.register)(i.store))}}c()(i,"store",null),t.Z=i},7057:function(e,t){"use strict";t.Z="jetpack-connection"},428:function(e,t,n){"use strict";n.d(t,{t:function(){return s.Z}});var a=n(7523),c=n(1432),r=n(1479),i=n(7728),o=n(2725),l=n(3535),s=n(7057);const u=window.JP_CONNECTION_INITIAL_STATE;u||console.error("Jetpack Connection package: Initial state is missing. Check documentation to see how to use the Connection composer package to set up the initial state."),l.Z.mayBeInit(s.Z,{__experimentalUseThunks:!0,reducer:r.Z,actions:a.ZP,selectors:o.Z,resolvers:i.Z,controls:c.Z,initialState:u||{}})},1827:function(e,t,n){"use strict";var a=n(6989),c=n.n(a),r=n(4769),i=n.n(r);const o={fetchWaf:()=>c()({path:"jetpack-protect/v1/waf",method:"GET"}).then(i()),toggleWaf:()=>c()({method:"POST",path:"jetpack-protect/v1/toggle-waf"}),updateWaf:e=>c()({method:"POST",path:"jetpack/v4/waf",data:e}),wafSeen:()=>c()({path:"jetpack-protect/v1/waf-seen",method:"POST"}),wafUpgradeSeen:()=>c()({path:"jetpack-protect/v1/waf-upgrade-seen",method:"POST"})};t.Z=o},7267:function(e,t,n){"use strict";var a=n(9105),c=n(3363),r=n(8258),i=n(6989),o=n.n(i),l=n(9818),s=n(5736),u=n(6483),p=n(9196),m=n.n(p),d=n(3898),h=n(8963),g=n(4633),f=n(6402),v=n(8266),E=n(3324),b=n(3900),k=n(2770);const __=s.__;t.Z=e=>{let{children:t}=e;(0,k.Z)();const{isSupported:n,isSeen:i}=(0,h.Z)(),{refreshPlan:s,startScanOptimistically:y,refreshStatus:Z}=(0,l.useDispatch)(g.t),{adminUrl:C}=window.jetpackProtectInitialState||{},{run:_,isRegistered:w,hasCheckoutStarted:R}=(0,r.Z)({productSlug:d.o,redirectUrl:(0,u.addQueryArgs)(C,{checkPlan:!0}),siteProductAvailabilityHandler:async()=>o()({path:"jetpack-protect/v1/check-plan",method:"GET"}).then((e=>e))});return(0,p.useEffect)((()=>{(0,u.getQueryArg)(window.location.search,"checkPlan")&&(y(),setTimeout((()=>{s(),Z(!0)}),5e3))}),[s,Z,y]),!w||R?m().createElement(f.Z,{onScanAdd:_}):m().createElement(a.Z,{moduleName:__("Jetpack Protect","jetpack-protect"),header:m().createElement(v.Z,null)},m().createElement(c.Z,{horizontalSpacing:0},m().createElement(E.Z,{className:b.Z.navigation},m().createElement(E.O,{link:"/",label:__("Scan","jetpack-protect")}),n&&m().createElement(E.O,{link:"/firewall",label:m().createElement(m().Fragment,null,__("Firewall","jetpack-protect"),!1===i&&m().createElement("span",{className:b.Z.badge},__("New","jetpack-protect")))}))),t)}},2770:function(e,t,n){"use strict";var a=n(1294),c=n(9818),r=n(9196),i=n(4633);t.Z=()=>{const{isRegistered:e}=(0,a.Z)(),{refreshStatus:t}=(0,c.useDispatch)(i.t),n=(0,c.useSelect)((e=>e(i.t).getStatus()));(0,r.useEffect)((()=>{e&&!n.status&&t()}),[e])}},4948:function(e,t,n){"use strict";n.d(t,{Z:function(){return o}});var a=n(5609),c=n(9196),r=n.n(c),i=n(9993);function o(e){let{className:t,color:n="#D63638"}=e;return r().createElement("div",{className:i.Z.container},r().createElement(a.SVG,{className:t,width:"127",height:"136",viewBox:"0 0 127 136",fill:"none",xmlns:"http://www.w3.org/2000/svg"},r().createElement(a.G,{filter:"url(#filter0_d_2716_19567)"},r().createElement(a.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M63.4061 36L86.8123 46.4057V61.9177C86.8123 75.141 78.1289 87.6611 65.8844 91.6107C64.2754 92.1298 62.5369 92.1297 60.9279 91.6107C48.6834 87.6611 40 75.141 40 61.9177V46.4057L63.4061 36Z",fill:n}),r().createElement(a.Rect,{x:"59.8953",y:"72.1666",width:"7.02184",height:"7",rx:"3.5",fill:"white"}),r().createElement(a.Path,{d:"M59.9619 51.0626C59.9258 50.4868 60.383 50 60.9599 50H65.8524C66.4293 50 66.8866 50.4868 66.8505 51.0626L65.8056 67.7292C65.7725 68.2562 65.3355 68.6667 64.8075 68.6667H62.0048C61.4769 68.6667 61.0398 68.2562 61.0068 67.7292L59.9619 51.0626Z",fill:"white"})),r().createElement("defs",null,r().createElement("filter",{id:"filter0_d_2716_19567",x:"0",y:"0",width:"126.812",height:"136",filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},r().createElement("feFlood",{floodOpacity:"0",result:"BackgroundImageFix"}),r().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"}),r().createElement("feOffset",{dy:"4"}),r().createElement("feGaussianBlur",{stdDeviation:"20"}),r().createElement("feComposite",{in2:"hardAlpha",operator:"out"}),r().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"}),r().createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_2716_19567"}),r().createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_2716_19567",result:"shape"})))))}},9974:function(e,t,n){"use strict";var a=n(5033),c=n(9818),r=n(5736),i=n(4633),o=n(9886),l=n(4424);const __=r.__;t.Z=e=>{let{children:t}=e;const{checkCredentials:n}=(0,c.useDispatch)(i.t),{credentials:r,credentialsIsFetching:s}=(0,c.useSelect)((e=>({credentials:e(i.t).getCredentials(),credentialsIsFetching:e(i.t).getCredentialsIsFetching()})));return r||s||n(),r?0===r.length?React.createElement(o.Z,null):t:React.createElement("div",{className:l.Z.loading},React.createElement(a.Z,{color:"black",style:{color:"black",marginTop:0,marginLeft:0}}),React.createElement("p",{className:l.Z.loading__message},__("Checking credentials…","jetpack-protect")))}},9886:function(e,t,n){"use strict";var a=n(5106),c=n(526),r=n(6895),i=n(9818),o=n(5736),l=n(9196),s=n(4633),u=n(291),p=n(3064);const __=o.__;t.Z=()=>{const{setModal:e}=(0,i.useDispatch)(s.t),{siteSuffix:t}=window.jetpackProtectInitialState,{checkCredentials:n}=(0,i.useDispatch)(s.t),o=(0,i.useSelect)((e=>e(s.t).getCredentials()));return(0,l.useEffect)((()=>{const e=setInterval((()=>{o&&0!==o.length||n()}),3e3);return()=>clearInterval(e)}),[n,o]),React.createElement(React.Fragment,null,React.createElement(a.ZP,{variant:"title-medium",mb:2},__("Site credentials needed","jetpack-protect")),React.createElement(u.Z,{type:"info",message:__("Before Jetpack Protect can auto-fix threats on your site, it needs your server credentials.","jetpack-protect")}),React.createElement(a.ZP,{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(a.ZP,{mb:3},__("Once you’ve entered server credentials, Jetpack Protect will be fixing the selected threats.","jetpack-protect")),React.createElement("div",{className:p.Z.footer},React.createElement(c.Z,{variant:"secondary",onClick:t=>{t.preventDefault(),e({type:null})}},__("Not now","jetpack-protect")),React.createElement(c.Z,{isExternalLink:!0,weight:"regular",href:(0,r.Z)("jetpack-settings-security-credentials",{site:t})},__("Enter server credentials","jetpack-protect"))))}},7127:function(e,t,n){"use strict";var a=n(7470),c=n(9196),r=n(9137);const i=e=>{const t=e.lastIndexOf("/");return t>-1?[e.slice(0,t),e.slice(t)]:["",e]};t.C=e=>{let{diff:t}=e;return React.createElement("div",{className:r.Z["diff-viewer"]},(0,a.G)(t).map(((e,t)=>React.createElement(c.Fragment,{key:t},React.createElement("div",{key:`file-${t}`,className:r.Z["diff-viewer__filename"]},(e=>{let{oldFileName:t,newFileName:n}=e;const a="a"===t[0]&&"/"===t[1]&&"b"===n[0]&&"/"===n[1],[o,l]=a?[t.slice(2),n.slice(2)]:[t,n];if(o===l){const[e,t]=i(o);return React.createElement(c.Fragment,null,e&&React.createElement("span",{className:r.Z["diff-viewer__path-prefix"]},e),React.createElement("span",{className:r.Z["diff-viewer__path"]},t))}const s=Math.max(o.length,l.length);for(let e=0,t=0;e{let n=0;return e.lines.map(((a,c)=>React.createElement("div",{key:`${t}-${c}`},"+"===a[0]?" ":e.oldStart+n++)))}))),React.createElement("div",{key:"right-numbers",className:r.Z["diff-viewer__line-numbers"]},e.hunks.map(((e,t)=>{let n=0;return e.lines.map(((a,c)=>React.createElement("div",{key:`${t}-${c}`},"-"===a[0]?" ":e.newStart+n++)))}))),React.createElement("div",{className:r.Z["diff-viewer__lines"]},e.hunks.map(((e,t)=>e.lines.map(((e,n)=>{const a=e.slice(1).replace(/^\s*$/," "),c=`${t}-${n}`;switch(e[0]){case" ":return React.createElement("div",{key:c},a);case"-":return React.createElement("del",{key:c},a);case"+":return React.createElement("ins",{key:c},a)}}))))))))))}},8431:function(e,t,n){"use strict";var a=n(5106),c=n(526),r=n(216),i=n(5609),o=n(9818),l=n(9307),s=n(5736),u=n(9196),p=n(3898),m=n(8963),d=n(4633),h=n(9909),g=n(3932);const __=s.__,f=()=>{const{setModal:e}=(0,o.useDispatch)(d.t);return React.createElement("div",{className:g.Z["standalone-mode-section"]},React.createElement(a.Dx,null,__("Standalone mode","jetpack-protect")),React.createElement(a.ZP,{mb:2},__("Learn how you can execute the firewall before WordPress initializes. This mode offers the most protection.","jetpack-protect")),React.createElement(c.Z,{variant:"link",isExternalLink:!0,weight:"regular",onClick:t=>{t.preventDefault(),e({type:"STANDALONE_MODE"})}},__("Learn more","jetpack-protect")))},v=()=>{const{config:e,isUpdating:t,toggleShareData:n}=(0,m.Z)(),{jetpackWafShareData:c}=e||{},{setNotice:r}=(0,o.useDispatch)(d.t),[s,h]=(0,u.useState)({jetpack_waf_share_data:c}),f=(0,u.useCallback)((()=>{h({...s,jetpack_waf_share_data:!s.jetpack_waf_share_data}),n().then((()=>r({type:"success",duration:5e3,dismissable:!0,message:__("Changes saved.","jetpack-protect")}))).catch((()=>{r({type:"error",dismissable:!0,message:(0,l.createInterpolateElement)(__("An error ocurred. Please try again or contact support.","jetpack-protect"),{supportLink:React.createElement(i.ExternalLink,{href:p.K})})})}))}),[s,n,r]);return(0,u.useEffect)((()=>{h({jetpack_waf_share_data:c})}),[c]),React.createElement("div",{className:g.Z["share-data-section"]},React.createElement(a.Dx,{mb:2},__(" Share data with Jetpack","jetpack-protect")),React.createElement("div",{className:g.Z["footer-checkbox"]},React.createElement(i.CheckboxControl,{checked:Boolean(s.jetpack_waf_share_data),onChange:f,disabled:t}),React.createElement(a.ZP,null,__("Allow Jetpack to collect data to improve firewall protection and rules. Collected data is also used to display advanced usage metrics.","jetpack-protect"))))};t.Z=()=>{const{isEnabled:e}=(0,m.Z)();return React.createElement(r.Z,null,React.createElement(h.Z,{main:React.createElement(f,null),secondary:e&&React.createElement(v,null),preserveSecondaryOnMobile:!0}))}},2651:function(e,t,n){"use strict";var a=n(526),c=n(5106),r=n(216),i=n(3363),o=n(3846),l=n(8258),s=n(5609),u=n(5736),p=n(1074),m=n(1646),d=n(5235),h=n.n(d),g=n(9196),f=n.n(g),v=n(3898),E=n(6477),b=n(5773),k=n(8963),y=n(8452);const __=u.__,Z=()=>{const{adminUrl:e}=window.jetpackProtectInitialState||{},t=e+"#/firewall",{config:{automaticRulesAvailable:n}}=(0,k.Z)(),{run:c}=(0,l.Z)({productSlug:v.o,redirectUrl:t}),{recordEventHandler:r}=(0,E.Z)(),i=r("jetpack_protect_waf_header_get_scan_link_click",c);return f().createElement(a.Z,{className:y.Z["upgrade-button"],onClick:i},n?__("Upgrade to update automatic rules","jetpack-protect",0):__("Upgrade to enable automatic rules","jetpack-protect"))},C=e=>{let{children:t=__("The free version of the firewall does not receive updates to automatic firewall rules.","jetpack-protect")}=e;const[n,a]=(0,g.useState)(!1),r=(0,g.useCallback)((()=>{a(!0)}),[]),i=(0,g.useCallback)((()=>{a(!1)}),[]);return f().createElement("div",{className:y.Z["icon-popover"],onMouseLeave:i,onMouseEnter:r,onClick:r,onFocus:r,onBlur:i,role:"presentation"},f().createElement(p.Z,{icon:m.Z}),n&&f().createElement(s.Popover,{noArrow:!1,offset:5},f().createElement(c.ZP,{className:y.Z["popover-text"],variant:"body-small"},t)))},_=e=>{let{className:t,text:n="",popover:a=!1,children:r}=e;return f().createElement("div",{className:y.Z["firewall-subheading__content"]},f().createElement(c.ZP,{className:y.Z[t],weight:600},n),a&&f().createElement(C,{children:r}))},w=e=>{let{hasRequiredPlan:t,automaticRulesAvailable:n,jetpackWafIpList:a,jetpackWafAutomaticRules:c,bruteForceProtectionIsEnabled:r}=e;const i=c&&a,o=c&&!a,l=!c&&a,s=!c&&!a;return f().createElement(f().Fragment,null,f().createElement("div",{className:y.Z["firewall-subheading"]},r&&f().createElement(_,{className:"brute-force-protection-subheading",text:__("Brute force protection is active.","jetpack-protect")}),s&&f().createElement(_,{text:__("There are no firewall rules applied.","jetpack-protect")}),o&&f().createElement(_,{text:__("Only automatic rules apply.","jetpack-protect"),popover:!t}),l&&f().createElement(_,{text:__("Only manual rules apply.","jetpack-protect"),popover:!t&&!n,children:__("The free version of the firewall only allows for use of manual rules.","jetpack-protect")}),i&&f().createElement(_,{text:__("All firewall rules apply.","jetpack-protect"),popover:!t})),!t&&f().createElement(Z,null))},R=e=>{let{status:t,hasRequiredPlan:n,automaticRulesEnabled:a,automaticRulesAvailable:l,jetpackWafIpList:u,jetpackWafAutomaticRules:p,bruteForceProtectionIsEnabled:m}=e;return f().createElement(r.Z,null,f().createElement(i.Z,{className:y.Z["firewall-header"],horizontalSpacing:7,horizontalGap:0},f().createElement(o.Z,null,"on"===t&&f().createElement(f().Fragment,null,f().createElement(c.ZP,{className:h()(y.Z.status,y.Z.active),variant:"label"},__("Active","jetpack-protect")),f().createElement(c.H3,{className:y.Z["firewall-heading"],mb:1,mt:2},a?__("Automatic firewall is on","jetpack-protect"):__("Firewall is on","jetpack-protect",0)),f().createElement(w,{jetpackWafIpList:u,jetpackWafAutomaticRules:p,bruteForceProtectionIsEnabled:m,hasRequiredPlan:n,automaticRulesAvailable:l})),"off"===t&&f().createElement(f().Fragment,null,f().createElement(c.ZP,{className:y.Z.status,variant:"label"},__("Inactive","jetpack-protect")),f().createElement(c.H3,{className:y.Z["firewall-heading"],mb:2,mt:2},l?__("Automatic firewall is off","jetpack-protect"):__("Firewall is off","jetpack-protect",0)),f().createElement(w,{jetpackWafIpList:u,jetpackWafAutomaticRules:p,bruteForceProtectionIsEnabled:m,hasRequiredPlan:n,automaticRulesAvailable:l})),"loading"===t&&f().createElement(f().Fragment,null,f().createElement(s.Spinner,{className:y.Z.spinner}),f().createElement(c.H3,{className:y.Z["firewall-heading"],mb:2,mt:2},__("Automatic firewall is being set up","jetpack-protect")),f().createElement(c.ZP,{className:y.Z["loading-text"],weight:600},__("Please wait…","jetpack-protect")))),f().createElement(o.Z,null,f().createElement("div",{className:y.Z["stat-card-wrapper"]}))))};t.Z=()=>{const{config:{jetpackWafAutomaticRules:e,jetpackWafIpList:t,automaticRulesAvailable:n,bruteForceProtection:a},isToggling:c}=(0,k.Z)(),{hasRequiredPlan:r}=(0,b.Z)(),i=e||t||a?"on":"off";return f().createElement(R,{status:c?"loading":i,hasRequiredPlan:r,automaticRulesEnabled:e,automaticRulesAvailable:n,jetpackWafIpList:t,jetpackWafAutomaticRules:e,bruteForceProtectionIsEnabled:a})}},5975:function(e,t,n){"use strict";var a=n(2674),c=n.n(a),r=n(2054),i=n(1342),o=n(5106),l=n(526),s=n(857),u=n(3363),p=n(3846),m=n(8258),d=n(5609),h=n(9818),g=n(9307),f=n(5736),v=n(1074),E=n(6163),b=n(3259),k=n(6292),y=n.n(k),Z=n(9196),C=n(5439),_=n(1827),w=n(3898),R=n(6477),j=n(5773),N=n(8963),S=n(4633),P=n(7267),x=n(8431),I=n(2651),M=n(5678),T=n(291),L=n(9265),z=n(4854);const __=f.__,_n=f._n,A=window?.jetpackProtectInitialState?.adminUrl,F=5e3;t.Z=()=>{const[e]=(0,r.Z)(["sm","lg"],[null,"<"]),t=(0,h.useSelect)((e=>e(S.t).getNotice())),{setWafIsSeen:n,setWafUpgradeIsSeen:a,setNotice:k}=(0,h.useDispatch)(S.t),{config:{jetpackWafAutomaticRules:V,jetpackWafIpList:O,jetpackWafIpBlockList:D,jetpackWafIpAllowList:H,automaticRulesAvailable:U,bruteForceProtection:B},isEnabled:W,isSeen:J,upgradeIsSeen:G,displayUpgradeBadge:$,isSupported:q,isUpdating:K,stats:X,toggleAutomaticRules:Q,toggleManualRules:Y,toggleBruteForceProtection:ee,toggleWaf:te,updateConfig:ne}=(0,N.Z)(),{ipAllowListCount:ae,ipBlockListCount:ce,rulesVersion:re,automaticRulesLastUpdated:ie}=X,{hasRequiredPlan:oe}=(0,j.Z)(),{run:le}=(0,m.Z)({productSlug:w.o,redirectUrl:`${A}#/firewall`}),{recordEventHandler:se,recordEvent:ue}=(0,R.Z)(),pe=W&&(oe||U),[me,de]=(0,Z.useState)(!1),[he,ge]=(0,Z.useState)({jetpack_waf_automatic_rules:V,jetpack_waf_ip_list:O,jetpack_waf_ip_block_list:D,jetpack_waf_ip_allow_list:H,brute_force_protection:B}),[fe,ve]=(0,Z.useState)(!1),[Ee,be]=(0,Z.useState)(!1),ke=(0,Z.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!1}}),[]),ye=(0,Z.useCallback)((e=>{const t=ke(e)||__("An error occurred.","jetpack-protect"),n=(0,g.createInterpolateElement)(__("Please try again or contact support.","jetpack-protect"),{supportLink:React.createElement(d.ExternalLink,{href:w.K})});k({type:"error",message:React.createElement(React.Fragment,null,t," ",n)})}),[ke,k]),Ze=se("jetpack_protect_waf_page_get_scan_link_click",le),Ce=(0,Z.useCallback)((()=>{ve(!0),ne(he).then((()=>k({type:"success",duration:F,message:__("Changes saved.","jetpack-protect")}))).catch(ye).finally((()=>ve(!1)))}),[ne,he,ye,k]),_e=(0,Z.useCallback)((e=>{const{value:t,id:n}=e.target;ge({...he,[n]:t})}),[he]),we=(0,Z.useCallback)((()=>{ve(!0);const e=!he.jetpack_waf_automatic_rules;ge({...he,jetpack_waf_automatic_rules:e}),Q().then((()=>{de(!1),k({type:"success",duration:F,message:e?__("Automatic rules are enabled.","jetpack-protect"):__("Automatic rules are disabled.","jetpack-protect",0)}),ue(e?"jetpack_protect_automatic_rules_enabled":"jetpack_protect_automatic_rules_disabled")})).then((()=>{G||(a(!0),_.Z.wafUpgradeSeen())})).catch((e=>{de(!0),ye(e)})).finally((()=>ve(!1)))}),[he,Q,k,ue,G,a,ye]),Re=(0,Z.useCallback)((()=>{ve(!0);const e=!he.brute_force_protection;ge({...he,brute_force_protection:e}),ee().then((()=>{k({type:"success",duration:F,message:e?__("Brute force protection is enabled.","jetpack-protect"):__("Brute force protection is disabled.","jetpack-protect",0)}),ue(e?"jetpack_protect_brute_force_protection_enabled":"jetpack_protect_brute_force_protection_disabled")})).catch(ye).finally((()=>ve(!1)))}),[he,ee,ye,k,ue]),je=(0,Z.useCallback)((()=>{const e=!he.jetpack_waf_ip_list;ve(!0),ge({...he,jetpack_waf_ip_list:e}),Y().then((()=>{k({type:"success",duration:F,message:e?__("Manual rules are active.","jetpack-protect"):__("Manual rules are disabled.","jetpack-protect",0)}),ue(e?"jetpack_protect_manual_rules_enabled":"jetpack_protect_manual_rules_disabled")})).catch(ye).finally((()=>ve(!1)))}),[he,Y,ye,k,ue]),Ne=(0,Z.useCallback)((()=>{be(!Ee)}),[Ee,be]),Se=(0,Z.useCallback)((()=>{a(!0),_.Z.wafUpgradeSeen()}),[a]);(0,Z.useEffect)((()=>{K||ge({jetpack_waf_automatic_rules:V,jetpack_waf_ip_list:O,jetpack_waf_ip_block_list:D,jetpack_waf_ip_allow_list:H,brute_force_protection:B})}),[O,D,H,V,B,K]),(0,Z.useEffect)((()=>{J||(n(!0),_.Z.wafSeen())}),[J,n]),(0,R.Z)({pageViewEventName:"protect_waf",pageViewEventProperties:{has_plan:oe}});const Pe=React.createElement(i.Z,{level:"error",title:"Jetpack Firewall is currently disabled.",children:React.createElement(o.ZP,null,__("Re-enable the Firewall to continue.","jetpack-protect")),actions:[React.createElement(l.Z,{variant:"link",onClick:te,isLoading:K,disabled:K},__("Enable Firewall","jetpack-protect"))],hideCloseButton:!0}),xe=React.createElement("div",{className:z.Z["toggle-wrapper"]},React.createElement("div",{className:`${z.Z["toggle-section"]} ${pe?"":z.Z["toggle-section--disabled"]}`},React.createElement("div",{className:z.Z["toggle-section__control"]},React.createElement(M.Z,{checked:!!pe&&he.jetpack_waf_automatic_rules,onChange:we,disabled:!W||fe||!pe}),oe&&!1===G&&React.createElement(d.Popover,{noArrow:!1,offset:8,position:"top right"},React.createElement("div",{className:z.Z.popover},React.createElement("div",{className:z.Z.popover__header},React.createElement(o.ZP,{className:z.Z.popover__title,variant:"title-small"},__("Thanks for upgrading!","jetpack-protect")),React.createElement(l.Z,{className:z.Z.popover__button,variant:"icon"},React.createElement(v.Z,{onClick:Se,icon:E.Z,size:24,"aria-label":__("Close Window","jetpack-protect")}))),React.createElement(o.ZP,{className:z.Z.popover__description,variant:"body",mt:2,mb:3},__("Turn on Jetpack Firewall to automatically protect your site with the latest security rules.","jetpack-protect")),React.createElement("div",{className:z.Z.popover__footer},React.createElement(l.Z,{onClick:Se},__("Got it","jetpack-protect")))))),React.createElement("div",{className:z.Z["toggle-section__content"]},React.createElement("div",{className:z.Z["toggle-section__title"]},React.createElement(o.ZP,{variant:"title-medium",mb:2},__("Enable automatic rules","jetpack-protect")),!e&&oe&&$&&React.createElement("span",{className:z.Z.badge},__("NOW AVAILABLE","jetpack-protect"))),React.createElement(o.ZP,null,__("Protect your site against untrusted traffic sources with automatic security rules.","jetpack-protect")),React.createElement("div",{className:z.Z["toggle-section__details"]},V&&!me&&React.createElement("div",{className:z.Z["automatic-rules-stats"]},re&&React.createElement(o.ZP,{className:z.Z["automatic-rules-stats__version"],variant:"body-small"},(0,f.sprintf)( -// translators: placeholder is the latest rules version i.e. "v2.0". -__("Automatic security rules v%s installed.","jetpack-protect"),re)),ie&&React.createElement(o.ZP,{className:z.Z["automatic-rules-stats__last-updated"],variant:"body-small"},(0,f.sprintf)( -// translators: placeholder is the date latest rules were updated i.e. "September 23, 2022". -__("Last updated on %s.","jetpack-protect"),y().unix(ie).format("MMMM D, YYYY")))),me&&React.createElement(React.Fragment,null,React.createElement(o.ZP,{className:z.Z["automatic-rules-stats__failed-install"],variant:"body-small",mt:2},__("Failed to update automatic rules.","jetpack-protect")," ",ke(me)),React.createElement(l.Z,{variant:"link",href:w.K},React.createElement(o.ZP,{variant:"body-small"},__("Contact support","jetpack-protect"))))))),!oe&&React.createElement("div",{className:z.Z["upgrade-trigger-section"]},React.createElement(s.Z,{className:z.Z["upgrade-trigger"],description:pe?__("Your site is not receiving the latest updates to automatic rules","jetpack-protect",0):__("Setup automatic rules with one click","jetpack-protect"),cta:pe?__("Upgrade to keep your site secure with up-to-date firewall rules","jetpack-protect",0):__("Upgrade to enable automatic rules","jetpack-protect"),onClick:Ze})),React.createElement("div",{className:z.Z["toggle-section"]},React.createElement("div",{className:z.Z["toggle-section__control"]},React.createElement(M.Z,{id:"brute_force_protection",checked:he.brute_force_protection,onChange:Re,disabled:fe})),React.createElement("div",{className:z.Z["toggle-section__content"]},React.createElement(o.ZP,{variant:"title-medium",mb:2},__("Enable brute force protection","jetpack-protect")),React.createElement(o.ZP,null,__("Prevent bots and hackers from attempting to log in to your website with common username and password combinations.","jetpack-protect")))),React.createElement("div",{className:`${z.Z["toggle-section"]} ${W?"":z.Z["toggle-section--disabled"]}`},React.createElement("div",{className:z.Z["toggle-section__control"]},React.createElement(M.Z,{id:"jetpack_waf_ip_list",checked:W&&he.jetpack_waf_ip_list,onChange:je,disabled:fe||!W})),React.createElement("div",{className:z.Z["toggle-section__content"]},React.createElement(o.ZP,{variant:"title-medium",mb:2},__("Enable manual rules","jetpack-protect")),React.createElement(o.ZP,null,__("Allows you to add manual rules to block or allow traffic from specific IPs.","jetpack-protect")),O&&React.createElement("div",{className:z.Z["toggle-section__details"]},React.createElement("div",{className:z.Z["manual-rules-stats"]},0===ae&&0===ce&&React.createElement(o.ZP,{className:z.Z["manual-rules-stats__no-rules"],variant:"body-small",mt:2},__("No manual rules are being applied.","jetpack-protect")),ce>0&&React.createElement(o.ZP,{className:z.Z["manual-rules-stats__block-list-count"],variant:"body-small",mt:2},(0,f.sprintf)( -// translators: placeholder is a number of blocked IP addresses i.e. "5 IPs are being blocked". -_n("%s IP is being blocked. ","%s IPs are being blocked. ",ce,"jetpack-protect"),1===ce?"One":ce)),ae>0&&React.createElement(o.ZP,{className:z.Z["manual-rules-stats__allow-list-count"],variant:"body-small",mt:2},(0,f.sprintf)( -// translators: placeholder is a number of allowed IP addresses i.e. "5 IPs are being allowed". -_n("%s IP is being allowed.","%s IPs are being allowed.",ae,"jetpack-protect"),1===ae?"One":ae))),React.createElement(l.Z,{variant:"link",disabled:!W},React.createElement(o.ZP,{variant:"body-small",onClick:Ne},__("Edit manual rules","jetpack-protect"))))))),Ie=React.createElement("div",null,React.createElement(l.Z,{className:z.Z["go-back-button"],variant:"icon",icon:b.Z,onClick:Ne},React.createElement(o.ZP,null,__("Go back","jetpack-protect"))),React.createElement(o.ZP,{variant:"title-medium",mt:4,mb:2},__("Manual rules","jetpack-protect")),React.createElement(o.ZP,{mb:4},__("Add manual rules for what IP traffic the Jetpack Firewall and brute force protection should block or allow.","jetpack-protect")),React.createElement("div",{className:z.Z["manual-rules-section"]},React.createElement(L.Z,{id:"jetpack_waf_ip_block_list",label:__("Blocked IP addresses","jetpack-protect"),placeholder:__("Example:","jetpack-protect")+"\n12.12.12.1\n12.12.12.2",rows:3,value:he.jetpack_waf_ip_block_list,onChange:_e,disabled:fe})),React.createElement("div",{className:z.Z["manual-rules-section"]},React.createElement(L.Z,{id:"jetpack_waf_ip_allow_list",label:__("Always allowed IP addresses","jetpack-protect"),placeholder:__("Example:","jetpack-protect")+"\n12.12.12.1\n12.12.12.2",rows:3,value:he.jetpack_waf_ip_allow_list,onChange:_e,disabled:fe})),React.createElement(l.Z,{onClick:Ce,isLoading:fe,disabled:fe},__("Save changes","jetpack-protect")));return q?React.createElement(P.Z,null,t.message&&React.createElement(T.Z,c()({floating:!0,dismissable:!0},t)),React.createElement(I.Z,null),React.createElement(u.Z,{className:z.Z.container,horizontalSpacing:8,horizontalGap:4},!W&&React.createElement(p.Z,null,Pe," "),React.createElement(p.Z,null,Ee?Ie:xe)),React.createElement(x.Z,null)):React.createElement(C.Fg,{replace:!0,to:"/"})}},8840:function(e,t,n){"use strict";var a=n(5106),c=n(526),r=n(9818),i=n(5736),o=n(9196),l=n(4633),s=n(9974),u=n(8891),p=n(2854),m=n(5823);const __=i.__;t.Z=e=>{let{threatList:t=[]}=e;const{setModal:n,fixThreats:i}=(0,r.useDispatch)(l.t),{threatsUpdating:d}=(0,r.useSelect)((e=>e(l.t).getThreatsUpdating())),[h,g]=(0,o.useState)(t.map((e=>{let{id:t}=e;return t}))),f=(0,o.useCallback)(((e,t)=>{g(e?h.push(t.id):h.filter((e=>e!==t.id)))}),[h]);return React.createElement(p.Z,null,React.createElement(s.Z,null,React.createElement(a.ZP,{variant:"title-medium",mb:2},__("Fix all threats","jetpack-protect")),React.createElement(a.ZP,{mb:3},__("Jetpack will be fixing the selected threats:","jetpack-protect")),React.createElement("div",{className:m.Z.list},t.map((e=>React.createElement(u.Z,{key:e.id,threat:e,fixAllDialog:!0,onCheckFix:f})))),React.createElement("div",{className:m.Z.footer},React.createElement(c.Z,{variant:"secondary",onClick:e=>{e.preventDefault(),n({type:null})}},__("Cancel","jetpack-protect")),React.createElement(c.Z,{isLoading:Boolean(d)&&d[h[0]],onClick:async e=>{e.preventDefault(),i(h,(()=>{n({type:null})}))}},__("Fix all threats","jetpack-protect")))))}},1593:function(e,t,n){"use strict";var a=n(5106),c=n(526),r=n(9818),i=n(5736),o=n(4633),l=n(9974),s=n(8891),u=n(2854),p=n(7279);const __=i.__;t.Z=e=>{let{id:t,fixable:n,label:i,icon:m,severity:d}=e;const{setModal:h,fixThreats:g}=(0,r.useDispatch)(o.t),f=(0,r.useSelect)((e=>e(o.t).getThreatsUpdating()));return React.createElement(u.Z,null,React.createElement(l.Z,null,React.createElement(a.ZP,{variant:"title-medium",mb:2},__("Fix Threat","jetpack-protect")),React.createElement(a.ZP,{mb:3},__("Jetpack will be fixing the selected threat:","jetpack-protect")),React.createElement("div",{className:p.Z.list},React.createElement(s.Z,{threat:{id:t,fixable:n,label:i,icon:m,severity:d},fixAllDialog:!1})),React.createElement("div",{className:p.Z.footer},React.createElement(c.Z,{variant:"secondary",onClick:e=>{e.preventDefault(),h({type:null})}},__("Cancel","jetpack-protect")),React.createElement(c.Z,{isLoading:Boolean(f&&f[t]),onClick:async e=>{e.preventDefault(),g([t],(()=>{h({type:null})}))}},__("Fix threat","jetpack-protect")))))}},5678:function(e,t,n){"use strict";var a=n(9196),c=n(1234);t.Z=e=>{let{ariaLabel:t,checked:n=!1,className:r="",disabled:i=!1,id:o,onChange:l=(()=>{}),onKeyDown:s=(()=>{}),switchClassNames:u="",toggling:p}=e;const m=(0,a.useCallback)((e=>{i||l(e)}),[i,l]),d=(0,a.useCallback)((e=>{i||("Enter"!==e.key&&" "!==e.key||(e.preventDefault(),l(e)),s(e))}),[i,l,s]);return React.createElement(React.Fragment,null,React.createElement("div",null,React.createElement("input",{className:`${c.Z["form-toggle"]} ${r} ${p?c.Z["is-toggling"]:""}`,type:"checkbox",checked:n,readOnly:!0,disabled:i}),React.createElement("span",{className:`${c.Z["form-toggle__switch"]} ${u}`,disabled:i,id:o,onClick:m,onKeyDown:d,role:"checkbox","aria-checked":n,"aria-label":t,tabIndex:i?-1:0})))}},3584:function(e,t,n){"use strict";n.d(t,{U:function(){return d}});var a=n(5106),c=n(1074),r=n(7489),i=n(2229),o=n(5235),l=n.n(o),s=n(9196),u=n.n(s),p=n(9122);const m=u().createContext(),d=e=>{let{id:t,title:n,label:o,icon:d,children:h,onOpen:g}=e;const f=(0,s.useContext)(m),v=f?.open===t,E=f?.setOpen,b=l()(p.Z["accordion-body"],{[p.Z["accordion-body-open"]]:v,[p.Z["accordion-body-close"]]:!v}),k=(0,s.useCallback)((()=>{v||g?.(),E((e=>e===t?null:t))}),[v,g,E,t]);return u().createElement("div",{className:p.Z["accordion-item"]},u().createElement("button",{className:p.Z["accordion-header"],onClick:k},u().createElement("div",null,u().createElement(a.ZP,{className:p.Z["accordion-header-label"],mb:1},u().createElement(c.Z,{icon:d,className:p.Z["accordion-header-label-icon"]}),o),u().createElement(a.ZP,{className:p.Z["accordion-header-description"],variant:v?"title-small":"body"},n)),u().createElement("div",{className:p.Z["accordion-header-button"]},u().createElement(c.Z,{icon:v?r.Z:i.Z,size:38}))),u().createElement("div",{className:b,"aria-hidden":v?"false":"true"},h))};t.Z=e=>{let{children:t}=e;const[n,a]=(0,s.useState)();return u().createElement(m.Provider,{value:{open:n,setOpen:a}},u().createElement("div",{className:p.Z.accordion},t))}},3116:function(e,t,n){"use strict";var a=n(6895),c=n(5106),r=n(526),i=n(9818),o=n(9307),l=n(5736),s=n(1074),u=n(4633),p=n(2251),m=n(2854),d=n(6983);const __=l.__;t.Z=e=>{let{id:t,title:n,label:l,icon:h,severity:g}=e;const{setModal:f,ignoreThreat:v}=(0,i.useDispatch)(u.t),E=(0,i.useSelect)((e=>e(u.t).getThreatsUpdating())),b=(0,a.Z)("jetpack-protect-codeable-referral");return React.createElement(m.Z,null,React.createElement(c.ZP,{variant:"title-medium",mb:2},__("Do you really want to ignore this threat?","jetpack-protect")),React.createElement(c.ZP,{mb:3},__("Jetpack will ignore the threat:","jetpack-protect")),React.createElement("div",{className:d.Z.threat},React.createElement(s.Z,{icon:h,className:d.Z.threat__icon}),React.createElement("div",{className:d.Z.threat__summary},React.createElement(c.ZP,{className:d.Z.threat__summary__label,mb:1},l),React.createElement(c.ZP,{className:d.Z.threat__summary__title},n)),React.createElement("div",{className:d.Z.threat__severity},React.createElement(p.Z,{severity:g}))),React.createElement(c.ZP,{mb:4},(0,o.createInterpolateElement)(__("By ignoring this threat you confirm that you have reviewed the detected code and assume the risks of keeping a potentially malicious or vulnerable file on your site. If you are unsure please request an estimate with Codeable.","jetpack-protect"),{codeableLink:React.createElement(r.Z,{variant:"link",isExternalLink:!0,href:b})})),React.createElement("div",{className:d.Z.footer},React.createElement(r.Z,{variant:"secondary",onClick:e=>{e.preventDefault(),f({type:null})}},__("Cancel","jetpack-protect")),React.createElement(r.Z,{isDestructive:!0,isLoading:Boolean(E&&E[t]),onClick:async e=>{e.preventDefault(),v(t,(()=>{f({type:null})}))}},__("Ignore threat","jetpack-protect"))))}},6402:function(e,t,n){"use strict";var a=n(9105),c=n(5106),r=n(216),i=n(3363),o=n(3846),l=n(9307),s=n(5736),u=n(9196),p=n.n(u),m=n(6477),d=n(8266),h=n(9401),g=n(2951);const __=s.__;t.Z=e=>{let{onScanAdd:t}=e;return(0,m.Z)({pageViewEventName:"protect_interstitial"}),p().createElement(a.Z,{moduleName:__("Jetpack Protect","jetpack-protect"),header:p().createElement("div",{className:g.Z["protect-header"]},p().createElement(d.Z,null),p().createElement(c.ZP,{variant:"body-small"},(0,l.createInterpolateElement)(__("Already have an existing plan or license key? Click here to get started","jetpack-protect"),{a:p().createElement("a",{href:"admin.php?page=my-jetpack#/add-license"})})))},p().createElement(r.Z,null,p().createElement(i.Z,{horizontalSpacing:3,horizontalGap:3},p().createElement(o.Z,{sm:4,md:8,lg:12},p().createElement(h.Z,{onScanAdd:t})))))}},8266:function(e,t,n){"use strict";n.d(t,{Z:function(){return i}});var a=n(5609),c=n(9196),r=n.n(c);function i(e){let{iconColor:t="#069E08",color:n="#000"}=e;return r().createElement(a.SVG,{fillRule:"evenodd",clipRule:"evenodd",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 245 41",width:245},r().createElement(a.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",fill:n}),r().createElement(a.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",fill:n}),r().createElement(a.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",fill:n}),r().createElement(a.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",fill:n}),r().createElement(a.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",fill:n}),r().createElement(a.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",fill:n}),r().createElement(a.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",fill:n}),r().createElement(a.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:t}),r().createElement(a.Path,{d:"M21.104 16.7295V36.2209L31.1571 16.7295H21.104Z",fill:"white"}),r().createElement(a.Path,{d:"M19.0701 23.4444V3.99023L9.05566 23.4444H19.0701Z",fill:"white"}),r().createElement(a.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",fill:n}),r().createElement(a.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",fill:n}),r().createElement(a.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",fill:n}),r().createElement(a.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",fill:n}),r().createElement(a.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",fill:n}),r().createElement(a.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",fill:n}),r().createElement(a.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",fill:n}))}},4257:function(e,t,n){"use strict";var a=n(8735);const c=e=>React.createElement("mark",{key:e,className:a.Z["marked-lines__mark"]},e);t.Z=e=>{let{context:t}=e;const{marks:n,...r}=t;return React.createElement("div",{className:a.Z["marked-lines"]},React.createElement("div",{className:a.Z["marked-lines__line-numbers"]},Object.keys(r).map((e=>{const t=n.hasOwnProperty(e);return React.createElement("div",{key:e,className:`${a.Z["marked-lines__line-number"]} ${t?a.Z["marked-lines__marked-line"]:""}`},e)}))),React.createElement("div",{className:a.Z["marked-lines__lines"]},Object.keys(r).map((e=>{const t=r[e]||" ",i=n.hasOwnProperty(e);return React.createElement("div",{key:e,className:`${a.Z["marked-lines__line"]} ${i?a.Z["marked-lines__marked-line"]:""} `},React.createElement(React.Fragment,null,i?((e,t)=>{const[n,a]=e.reduce(((e,n)=>{let[a,r]=e,[i,o]=n;const l=t.slice(i,o);return[[...a,...i>r?[t.slice(r,i),c(l)]:[c(l)]],o]}),[[],0]);return a{const e=(0,a.useSelect)((e=>e(o.t).getModalType())),t=(0,a.useSelect)((e=>e(o.t).getModalProps())),{setModal:n}=(0,a.useDispatch)(o.t);if(!e)return null;const c=h[e];return React.createElement("div",{className:d.Z.modal},React.createElement("div",{className:d.Z.modal__window},React.createElement("button",{onClick:e=>{e.preventDefault(),n({type:null})},className:d.Z.modal__close,title:__("Close Modal Window","jetpack-protect")},React.createElement(r.Z,{icon:i.Z,size:24,className:d.Z.modal__close__icon,"aria-label":__("Close Modal Window","jetpack-protect")})),React.createElement(c,t)))}},5167:function(e,t,n){"use strict";var a=n(5106),c=n(5609),r=n(5736),i=n(1074),o=n(496),l=n(9201),s=n(5162),u=n.n(s),p=n(9196),m=n.n(p),d=n(513);const __=r.__,h=e=>{let{count:t,checked:n}=e;const{popoverText:r,badgeElement:s}=((e,t)=>t?0===e?{popoverText:__("No known threats found to affect this version","jetpack-protect"),badgeElement:m().createElement(i.Z,{icon:l.Z,size:28,className:d.Z["navigation-item-check-badge"]})}:{popoverText:null,badgeElement:m().createElement(a.ZP,{variant:"body-extra-small",className:d.Z["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:m().createElement(i.Z,{icon:o.Z,size:28,className:d.Z["navigation-item-info-badge"]})})(t,n),[u,h]=(0,p.useState)(!1),g=(0,p.useCallback)((()=>{h(!0)}),[]),f=(0,p.useCallback)((()=>{h(!1)}),[]);return m().createElement("div",{onMouseLeave:r?f:null,onMouseEnter:r?g:null,onClick:r?g:null,onFocus:r?g:null,onBlur:r?f:null,role:"presentation"},s,u&&m().createElement(c.Popover,{noArrow:!1},m().createElement(a.ZP,{variant:"body-small",className:d.Z["popover-text"]},r)))};h.propTypes={count:u().number,checked:u().bool},t.Z=h},2328:function(e,t,n){"use strict";var a=n(526),c=n(5736),r=n(9196),i=n.n(r),o=n(2389),l=n(513),s=n(246);const __=c.__;t.Z=e=>{let{icon:t,label:n,children:u}=e;const[p,m]=(0,r.useState)(!0),{mode:d}=(0,r.useContext)(s.k),h=Array.isArray(u)&&u?.length>=8&&"list"===d,g=h&&p?u.slice(0,8):u,f=h?u?.length-8:0,v=(0,r.useCallback)((()=>{m((e=>!e))}),[]);return i().createElement("li",{tabIndex:-1,role:"menuitem",className:l.Z["navigation-group"]},i().createElement(o.Z,{icon:t,className:l.Z["navigation-group-label"]},n),i().createElement("div",{className:l.Z["navigation-group-list"]},i().createElement("ul",{className:l.Z["navigation-group-content"]},g),h&&i().createElement("div",{className:l.Z["navigation-group-truncate"]},i().createElement(a.Z,{variant:"link",onClick:v},p?(0,c.sprintf)(/* translators: %s: Number of hide items */ -__("Show %s more","jetpack-protect"),f):(0,c.sprintf)(/* translators: %s: Number of hide items */ -__("Hide %s items","jetpack-protect"),f)))))}},5338:function(e,t,n){"use strict";n.d(t,{Dx:function(){return h.Z},KB:function(){return d.Z}});var a=n(5106),c=n(5609),r=n(5736),i=n(1074),o=n(7489),l=n(2229),s=n(5235),u=n.n(s),p=n(9196),m=n.n(p),d=n(2328),h=n(6119),g=n(513),f=n(246);const __=r.__,v=e=>{let{children:t}=e;return m().createElement("ul",{className:g.Z.navigation,role:"menu"},t)},E=e=>{let{children:t,data:n}=e;const r=(0,p.useRef)(),[s,d]=(0,p.useState)(!1),h=n?.items?.find((e=>e?.id===n?.selectedItem))??{label:__("See all results","jetpack-protect")},{label:f,icon:v}=h,E=(0,p.useCallback)((()=>{d((e=>!e))}),[]);return m().createElement("button",{className:g.Z["navigation-dropdown-button"],onClick:E,ref:r},m().createElement("div",{className:g.Z["navigation-dropdown-label"]},v&&m().createElement(i.Z,{icon:v,className:g.Z["navigation-dropdown-icon"]}),m().createElement(a.ZP,null,f)),m().createElement(i.Z,{icon:s?o.Z:l.Z,size:32}),m().createElement(c.Popover,{position:"bottom center",anchorRef:r?.current,className:u()({[g.Z["navigation-dropdown-open"]]:s,[g.Z["navigation-dropdown-closed"]]:!s})},m().createElement("div",{style:{width:r?.current?.getBoundingClientRect?.()?.width}},t)))};t.ZP=e=>{let{children:t,selected:n,onSelect:a,mode:c="list"}=e;const r=(0,f.Z)({selected:n,onSelect:a}),i=(e=>{switch(e){case"list":default:return v;case"dropdown":return E}})(c);return m().createElement(f.k.Provider,{value:{...r,mode:c}},m().createElement(i,{data:r},t))}},6119:function(e,t,n){"use strict";var a=n(5235),c=n.n(a),r=n(9196),i=n.n(r),o=n(5167),l=n(2389),s=n(513),u=n(246);t.Z=e=>{let{id:t,label:n,icon:a,badge:p,disabled:m,onClick:d,onKeyDown:h,onFocus:g,checked:f}=e;const v=(0,r.useContext)(u.k),E=v?.selectedItem===t,b=v?.registerItem,k=v?.registerRef,y=v?.handleClickItem,Z=v?.handleKeyDownItem,C=v?.handleFocusItem,_=c()(s.Z["navigation-item"],{[s.Z.clickable]:!m,[s.Z.selected]:E}),w=(0,r.useCallback)((e=>{d?.(e),y?.(t)}),[y,t,d]),R=(0,r.useCallback)((e=>{h?.(e),Z?.(e)}),[Z,h]),j=(0,r.useCallback)((e=>{k(e,t)}),[k,t]),N=(0,r.useCallback)((e=>{g?.(e),C?.(t)}),[C,t,g]);return(0,r.useEffect)((()=>{b({id:t,disabled:m,label:n,icon:a})}),[]),i().createElement("li",{className:_,onClick:m?null:w,onKeyDown:R,onFocus:m?null:N,role:"menuitem",tabIndex:m?-1:0,ref:j},i().createElement(l.Z,{icon:a},n),i().createElement(o.Z,{count:p,checked:f}))}},2389:function(e,t,n){"use strict";var a=n(5106),c=n(1074),r=n(5235),i=n.n(r),o=n(5162),l=n.n(o),s=n(9196),u=n.n(s),p=n(513);const m=e=>{let{icon:t,children:n,className:r}=e;return u().createElement(a.ZP,{className:i()(p.Z["navigation-item-label"],r)},t&&u().createElement(c.Z,{icon:t,className:p.Z["navigation-item-icon"],size:28}),u().createElement("span",{className:p.Z["navigation-item-label-content"]},n))};m.propTypes={icon:l().node,children:l().node.isRequired},t.Z=m},246:function(e,t,n){"use strict";n.d(t,{k:function(){return c}});var a=n(9196);const c=n.n(a)().createContext();t.Z=e=>{let{selected:t,onSelect:n}=e;const[c,r]=(0,a.useState)([]),[i,o]=(0,a.useState)([]),[l,s]=(0,a.useState)(),u=(e,t)=>{const n=e-1,a=n<0?t:n,r=c[a];return r?.disabled?u(a,t):r},p=(e,t)=>{const n=e+1,a=n>t?0:n,r=c[a];return r?.disabled?p(a,t):r};return{selectedItem:t,handleClickItem:e=>{n(e)},handleKeyDownItem:e=>{const a=e?.code,r=c.findIndex((e=>e?.id===t)),o=c.length-1;let s;if("ArrowUp"===a){s=u(r,o)?.id}else if("ArrowDown"===a){s=p(r,o)?.id}else"Enter"!==a&&"Space"!==a||!l||(s=l);if(s){i[s]?.focus(),n(s)}},handleFocusItem:e=>{s(e)},registerRef:(e,t)=>{o((n=>!n[t]&&e?{...n,[t]:e}:n))},registerItem:e=>{r((t=>{const n=[...t],a=e?.id,c=n.findIndex((e=>e?.id===a));return c>=0?n[c]=e:n.push(e),n}))},items:c}}},291:function(e,t,n){"use strict";var a=n(9818),c=n(5736),r=n(9201),i=n(797),o=n(496),l=n(1074),s=n(9517),u=n(9196),p=n(4633),m=n(8212);const __=c.__;t.Z=e=>{let{dismissable:t=!1,duration:n=null,floating:c=!1,message:d,type:h="success"}=e;const{clearNotice:g}=(0,a.useDispatch)(p.t);let f;switch(h){case"success":f=r.Z;break;case"error":f=i.Z;break;default:f=o.Z}const v=(0,u.useCallback)((()=>{g()}),[g]);return(0,u.useEffect)((()=>{let e;return n&&(e=setTimeout(g,n)),()=>clearTimeout(e)}),[g,n,d]),React.createElement("div",{className:`${m.Z.notice} ${m.Z[`notice--${h}`]} ${c?m.Z["notice--floating"]:""}`},React.createElement("div",{className:m.Z.notice__icon},React.createElement(l.Z,{icon:f})),React.createElement("div",{className:m.Z.notice__message},d),t&&React.createElement("button",{className:m.Z.notice__close,"aria-label":__("Dismiss notice.","jetpack-protect"),onClick:v},React.createElement(l.Z,{icon:s.Z})))}},289:function(e,t,n){"use strict";n.d(t,{c:function(){return k}});var a=n(2054),c=n(5106),r=n(5033),i=n(9818),o=n(5736),l=n(1074),s=n(9201),u=n(7489),p=n(2229),m=n(5235),d=n.n(m),h=n(9196),g=n.n(h),f=n(4633),v=n(2251),E=n(7324);const __=o.__,b=g().createContext(),k=e=>{let{id:t,title:n,label:o,icon:m,fixable:k,severity:y,children:Z,onOpen:C}=e;const _=(0,h.useContext)(b),w=_?.open===t,R=_?.setOpen,j=(0,i.useSelect)((e=>e(f.t).getThreatsAreFixing())),N=d()(E.Z["accordion-body"],{[E.Z["accordion-body-open"]]:w,[E.Z["accordion-body-close"]]:!w}),S=(0,h.useCallback)((()=>{w||C?.(),R((e=>e===t?null:t))}),[w,C,R,t]),[P]=(0,a.Z)(["sm","lg"],[null,"<"]);return g().createElement("div",{className:E.Z["accordion-item"]},g().createElement("button",{className:E.Z["accordion-header"],onClick:S},g().createElement("div",null,g().createElement(c.ZP,{className:E.Z["accordion-header-label"],mb:1},g().createElement(l.Z,{icon:m,className:E.Z["accordion-header-label-icon"]}),o),g().createElement(c.ZP,{className:E.Z["accordion-header-description"],variant:w?"title-small":"body"},n)),g().createElement("div",null,g().createElement(v.Z,{severity:y})),g().createElement("div",null,k&&g().createElement(g().Fragment,null,j.indexOf(t)>=0?g().createElement(r.Z,{color:"black"}):g().createElement(l.Z,{icon:s.Z,className:E.Z["icon-check"],size:28}),P&&g().createElement("span",null,__("Auto-fix","jetpack-protect")))),g().createElement("div",{className:E.Z["accordion-header-button"]},g().createElement(l.Z,{icon:w?u.Z:p.Z,size:38}))),g().createElement("div",{className:N,"aria-hidden":w?"false":"true"},Z))};t.Z=e=>{let{children:t}=e;const[n,a]=(0,h.useState)();return g().createElement(b.Provider,{value:{open:n,setOpen:a}},g().createElement("div",{className:E.Z.accordion},t))}},9401:function(e,t,n){"use strict";var a=n(9608),c=n(5347),r=n(526),i=n(1294),o=n(9818),l=n(5736),s=n(9196),u=n.n(s),p=n(6477),m=n(5773),d=n(8963),h=n(4633);const __=l.__;t.Z=e=>{let{onScanAdd:t}=e;const{handleRegisterSite:n,registrationError:l}=(0,i.Z)({skipUserConnection:!0}),{refreshPlan:g,refreshStatus:f}=(0,o.useDispatch)(h.t),[v,E]=(0,s.useState)(!1),[b,k]=(0,s.useState)(!1),{jetpackScan:y}=(0,m.Z)(),{refreshWaf:Z}=(0,d.Z)(),{pricingForUi:C}=y,{introductoryOffer:_,currencyCode:w="USD"}=C,R=C.cost?Math.ceil(C.cost/12*100)/100:null,j=_?.costPerInterval?Math.ceil(_.costPerInterval/12*100)/100:null,{recordEvent:N,recordEventHandler:S}=(0,p.Z)(),P=S("jetpack_protect_pricing_table_get_scan_link_click",(()=>{k(!0),t()})),x=(0,s.useCallback)((()=>{N("jetpack_protect_connected_product_activated"),E(!0),n().then((()=>E(!1))).then((()=>{g(),Z(),f(!0)}))}),[n,N,Z,g,f]),I={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 u().createElement(u().Fragment,null,u().createElement(a.ZP,I,u().createElement(a.oK,{primary:!0},u().createElement(a.NE,null,u().createElement(c.Z,{price:R,offPrice:j,leyend:__("/month, billed yearly","jetpack-protect"),currency:w,hideDiscountLabel:!1}),u().createElement(r.Z,{fullWidth:!0,onClick:P,isLoading:b,disabled:v||b},__("Get Jetpack Protect","jetpack-protect"))),u().createElement(a.kF,{isIncluded:!0,label:u().createElement("strong",null,__("Line by line malware scanning","jetpack-protect"))}),u().createElement(a.kF,{isIncluded:!0,label:u().createElement("strong",null,__("Plus on-demand manual scans","jetpack-protect"))}),u().createElement(a.kF,{isIncluded:!0,label:u().createElement("strong",null,__("Automatic protection and rule updates","jetpack-protect"))}),u().createElement(a.kF,{isIncluded:!0}),u().createElement(a.kF,{isIncluded:!0}),u().createElement(a.kF,{isIncluded:!0}),u().createElement(a.kF,{isIncluded:!0}),u().createElement(a.kF,{isIncluded:!0})),u().createElement(a.oK,null,u().createElement(a.NE,null,u().createElement(c.Z,{price:0,leyend:__("Free forever","jetpack-protect"),currency:w,hidePriceFraction:!0}),u().createElement(r.Z,{fullWidth:!0,variant:"secondary",onClick:x,isLoading:v,disabled:v||b,error:l?__("An error occurred. Please try again.","jetpack-protect"):null},__("Start for free","jetpack-protect"))),u().createElement(a.kF,{isIncluded:!0,label:__("Check items against database","jetpack-protect")}),u().createElement(a.kF,{isIncluded:!0}),u().createElement(a.kF,{isIncluded:!0,label:__("Manual rules only","jetpack-protect")}),u().createElement(a.kF,{isIncluded:!0}),u().createElement(a.kF,{isIncluded:!1}),u().createElement(a.kF,{isIncluded:!1}),u().createElement(a.kF,{isIncluded:!1}),u().createElement(a.kF,{isIncluded:!1}))))}},1233:function(e,t,n){"use strict";var a=n(5235),c=n.n(a),r=n(6067);t.Z=e=>{let{className:t,total:n=100,value:a}=e;if(null==a)return null;const i=Math.min(Math.round(a/n*100),100),o={width:`${i}%`};return React.createElement("div",{className:c()(t,r.Z["progress-bar"])},React.createElement("div",{className:r.Z["progress-bar__wrapper"]},React.createElement("div",{"aria-valuemax":n,"aria-valuemin":0,"aria-valuenow":Math.min(a,n),className:r.Z["progress-bar__bar"],role:"progressbar",style:o})),React.createElement("p",{className:r.Z["progress-bar__percent"]},`${i}%`))}},5800:function(e,t,n){"use strict";var a=n(6895),c=n(5106),r=n(526),i=n(857),o=n(8258),l=n(5736),s=n(9196),u=n.n(s),p=n(3898),m=n(6477),d=n(5773),h=n(9909),g=n(8383);const __=l.__,f=()=>{const{adminUrl:e,siteSuffix:t}=window.jetpackProtectInitialState||{},{run:n}=(0,o.Z)({productSlug:p.o,redirectUrl:e}),{recordEventHandler:l}=(0,m.Z)(),s=l("jetpack_protect_footer_get_scan_link_click",n),{hasRequiredPlan:h}=(0,d.Z)();if(h){const e=(0,a.Z)("jetpack-scan-dash",{site:t});return u().createElement("div",{className:g.Z["product-section"]},u().createElement(c.Dx,null,__("Get access to our Cloud","jetpack-protect")),u().createElement(c.ZP,{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")),u().createElement(r.Z,{variant:"secondary",weight:"regular",href:e},__("Go to Cloud","jetpack-protect")))}return u().createElement("div",{className:g.Z["product-section"]},u().createElement(c.Dx,null,__("Advanced scan results","jetpack-protect")),u().createElement(c.ZP,{mb:3},__("Upgrade Jetpack Protect to get advanced scan tools, including one-click fixes for most threats and malware scanning.","jetpack-protect")),u().createElement(i.Z,{description:__("Looking for advanced scan results and one-click fixes?","jetpack-protect"),cta:__("Upgrade Jetpack Protect now","jetpack-protect"),onClick:s}))},v=()=>{const{hasRequiredPlan:e}=(0,d.Z)();if(e){const e=(0,a.Z)("protect-footer-learn-more-scan");return u().createElement("div",{className:g.Z["info-section"]},u().createElement(c.Dx,null,__("Line-by-line scanning","jetpack-protect")),u().createElement(c.ZP,{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"),u().createElement(r.Z,{variant:"link",target:"_blank",weight:"regular",href:e},__("Learn more","jetpack-protect"))))}const t=(0,a.Z)("jetpack-protect-footer-learn-more");return u().createElement("div",{className:g.Z["info-section"]},u().createElement(c.Dx,null,__("Over 22,000 listed vulnerabilities","jetpack-protect")),u().createElement(c.ZP,{mb:3},__("Every day we check your plugin, theme, and WordPress versions against our 22,000 listed vulnerabilities powered by WPScan, an Automattic brand.","jetpack-protect")),u().createElement(r.Z,{variant:"link",isExternalLink:!0,href:t,weight:"regular"},__("Learn more","jetpack-protect")))};t.Z=()=>u().createElement(h.Z,{main:u().createElement(f,null),secondary:u().createElement(v,null),preserveSecondaryOnMobile:!0})},8686:function(e,t,n){"use strict";var a=n(216),c=n(3363),r=n(3846),i=n(5106),o=n(3329),l=n(5609),s=n(9818),u=n(5736),p=n(9196),m=n.n(p),d=n(6477),h=n(5773),g=n(4633),f=n(7267),v=n(4948),E=n(1233),b=n(5800),k=n(9909),y=n(4910),Z=n(5207),C=n(5983),_=n(61),w=n(8264),R=n(6165);const __=u.__;t.Z=()=>{const{lastChecked:e,currentStatus:t,errorCode:n,errorMessage:u,hasRequiredPlan:j}=(0,h.Z)(),{hasConnectionError:N}=(0,o.Z)(),{refreshStatus:S}=(0,s.useDispatch)(g.t),{statusIsFetching:P,scanIsUnavailable:x,status:I}=(0,s.useSelect)((e=>({statusIsFetching:e(g.t).getStatusIsFetching(),scanIsUnavailable:e(g.t).getScanIsUnavailable(),status:e(g.t).getStatus()}))),{currentProgress:M}=I;let T;if(T="error"===t||x?"error":e?"active":"in_progress",(0,R.Z)(),(0,w.Z)(),(0,p.useEffect)((()=>{P||"unavailable"!==I.status||x||S(!0)}),[P,I.status,S,x]),(0,d.Z)({pageViewEventName:"protect_admin",pageViewEventProperties:{check_status:T,has_plan:j}}),"error"===t||x){let e=u?`${u} (${n}).`:__("We are having problems scanning your site.","jetpack-protect");return e+=" "+__("Try again in a few minutes.","jetpack-protect"),m().createElement(f.Z,null,m().createElement(a.Z,null,m().createElement(c.Z,{horizontalSpacing:0},N&&m().createElement(r.Z,{className:_.Z["connection-error-col"]},m().createElement(o.h,null)),m().createElement(r.Z,null,m().createElement("div",{id:"jp-admin-notices",className:"my-jetpack-jitm-card"}))),m().createElement(k.Z,{main:m().createElement("div",{className:_.Z["main-content"]},m().createElement(v.Z,{className:_.Z["alert-icon-wrapper"]}),m().createElement(i.H3,null,__("We’re having problems scanning your site","jetpack-protect")),m().createElement(i.ZP,null,e)),secondary:m().createElement("div",{className:_.Z.illustration},m().createElement("img",{src:C,alt:""})),preserveSecondaryOnMobile:!1})),m().createElement(b.Z,null))}return["scheduled","scanning","optimistically_scanning"].indexOf(I.status)>=0||!e?m().createElement(f.Z,null,m().createElement(a.Z,null,m().createElement(c.Z,{horizontalSpacing:0},N&&m().createElement(r.Z,{className:_.Z["connection-error-col"]},m().createElement(o.h,null)),m().createElement(r.Z,null,m().createElement("div",{id:"jp-admin-notices",className:"my-jetpack-jitm-card"}))),m().createElement(k.Z,{main:m().createElement("div",{className:_.Z["main-content"]},m().createElement(c.Z,{horizontalSpacing:3,horizontalGap:7},m().createElement(r.Z,{className:_.Z["loading-content"]},m().createElement(l.Spinner,{style:{color:"black",marginTop:0,marginLeft:0}}),m().createElement("span",null,__("Scanning your site…","jetpack-protect"))),m().createElement(r.Z,null,m().createElement(i.H3,null,__("Your results will be ready soon","jetpack-protect")),null!==M&&M>=0&&m().createElement(E.Z,{value:M}),m().createElement(i.ZP,null,__("We are scanning for security threats from our more than 22,000 listed vulnerabilities, powered by WPScan. This could take a minute or two.","jetpack-protect"))))),secondary:m().createElement("div",{className:_.Z.illustration},m().createElement("img",{src:C,alt:""})),preserveSecondaryOnMobile:!1})),m().createElement(b.Z,null)):m().createElement(f.Z,null,m().createElement(a.Z,null,m().createElement(c.Z,{horizontalSpacing:0},N&&m().createElement(r.Z,{className:_.Z["connection-error-col"]},m().createElement(o.h,null)),m().createElement(r.Z,null,m().createElement("div",{id:"jp-admin-notices",className:"my-jetpack-jitm-card"}))),m().createElement(c.Z,{horizontalSpacing:3,horizontalGap:7},m().createElement(r.Z,null,m().createElement(y.Z,null)),m().createElement(r.Z,null,m().createElement(Z.Z,null)))),m().createElement(b.Z,null))}},8264:function(e,t,n){"use strict";var a=n(9818),c=n(9196),r=n(4633);t.Z=()=>{const{checkCredentials:e}=(0,a.useDispatch)(r.t),t=(0,a.useSelect)((e=>e(r.t).getCredentials()));(0,c.useEffect)((()=>{t||e()}),[e,t])}},6165:function(e,t,n){"use strict";var a=n(6989),c=n.n(a),r=n(9818),i=n(4769),o=n.n(i),l=n(9196),s=n(6477),u=n(4633);t.Z=()=>{const{recordEvent:e}=(0,s.Z)(),t=(0,r.useSelect)((e=>e(u.t).getStatus())),{setStatus:n,setStatusProgress:a,setStatusIsFetching:i,setScanIsUnavailable:p}=(0,r.useDispatch)(u.t);(0,l.useEffect)((()=>{let r;const l=e=>["scheduled","scanning"].indexOf(e)>=0,s=(e,t)=>!t&&"idle"===e,u=()=>new Promise(((e,t)=>{c()({path:"jetpack-protect/v1/status?hard_refresh=true",method:"GET"}).then((n=>{if(n?.error)throw n?.error_message;if(l(n?.status)||s(n?.status,n?.last_checked))return a(n?.current_progress),void(r=setTimeout((()=>{u().then((t=>e(t))).catch((e=>t(e)))}),1e4));e(n)})).catch((()=>{setTimeout((()=>{u().then((t=>e(t))).catch((e=>t(e)))}),5e3)}))}));if(l(t?.status)||s(t?.status,t?.lastChecked))return r=setTimeout((()=>{i(!0),u().then((t=>{p("unavailable"===t.status),n(o()(t)),e("jetpack_protect_scan_completed",{scan_status:t.status})})).finally((()=>{i(!1)}))}),1e4),()=>clearTimeout(r)}),[t?.status,t?.lastChecked,p,n,a,i,e])}},9909:function(e,t,n){"use strict";var a=n(2054),c=n(3363),r=n(3846),i=n(9196),o=n.n(i);t.Z=e=>{let{main:t,secondary:n,preserveSecondaryOnMobile:i=!1}=e;const[l,s]=(0,a.Z)(["sm","lg"]),u=!i&&l;return o().createElement(c.Z,{horizontalSpacing:0,horizontalGap:0,fluid:!1},!u&&o().createElement(o().Fragment,null,o().createElement(r.Z,{sm:12,md:4,lg:6},t),s&&o().createElement(r.Z,{lg:1}),o().createElement(r.Z,{sm:12,md:4,lg:5},n)),u&&o().createElement(r.Z,null,t))}},2251:function(e,t,n){"use strict";var a=n(5736),c=n(8131);const __=a.__,r=e=>e>=5?"is-critical":e>=3&&e<5?"is-high":"is-low";t.Z=e=>{let{severity:t}=e;return React.createElement("div",{className:`${c.Z["threat-severity-badge"]} ${c.Z[r(t)]}`},(e=>{const t=__("Critical","jetpack-protect"),n=__("High","jetpack-protect"),a=__("Low","jetpack-protect");return e>=5?t:e>=3&&e<5?n:a})(t))}},8959:function(e,t,n){"use strict";var a=n(5106),c=n(9307),r=n(5736),i=n(8911);const __=r.__;t.Z=()=>React.createElement(React.Fragment,null,React.createElement(a.ZP,{variant:"title-medium-semi-bold",mb:2},__("Enhanced protection","jetpack-protect")),React.createElement(a.ZP,{mb:2},__("Learn how you can execute Jetpack Firewall before WordPress initializes. This mode offers the most protection.","jetpack-protect")),React.createElement("ul",{className:i.Z.list},React.createElement("li",{className:i.Z["list-item"]},React.createElement(a.ZP,{variant:"body-small"},(0,c.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:i.Z.mark})}))),React.createElement("li",{className:i.Z["list-item"]},React.createElement(a.ZP,{variant:"body-small"},__("Don't forget to undo this action when Firewall is turned off, or when you uninstall Jetpack.","jetpack-protect")))))},4910:function(e,t,n){"use strict";var a=n(3396),c=n(3363),r=n(3846),i=n(5106),o=n(526),l=n(9818),s=n(9771),u=n(5736),p=n(9196),m=n.n(p),d=n(5773),h=n(4633),g=n(291),f=n(6561);const __=u.__;t.Z=()=>{const{numThreats:e,lastChecked:t,hasRequiredPlan:n}=(0,d.Z)(),p=(0,l.useSelect)((e=>e(h.t).getNotice())),v=(0,l.useSelect)((e=>e(h.t).getScanIsEnqueuing())),{scan:E}=(0,l.useDispatch)(h.t),b=(0,a.VS)("protect");return m().createElement(c.Z,{fluid:!0},m().createElement(r.Z,null,m().createElement("div",{className:f.Z.summary},m().createElement("div",null,m().createElement(i.Dx,{size:"small",className:f.Z.summary__title},m().createElement(b,{size:32,className:f.Z.summary__icon}),(0,u.sprintf)(/* translators: %s: Latest check date */ -__("Latest results as of %s","jetpack-protect"),(0,s.dateI18n)("F jS",t))),e>0&&m().createElement(i.ZP,{variant:"headline-small",component:"h1"},(0,u.sprintf)(/* translators: %s: Total number of threats */ -__("%1$s %2$s found","jetpack-protect"),e,1===e?"threat":"threats"))),m().createElement("div",{className:f.Z.summary__notice},p&&p.message&&m().createElement(g.Z,p)),n&&0===e&&m().createElement(o.Z,{variant:"secondary",className:f.Z["summary__scan-button"],isLoading:v,onClick:e=>{e.preventDefault(),E()}},__("Scan now","jetpack-protect")))))}},3324:function(e,t,n){"use strict";n.d(t,{O:function(){return r}});var a=n(554),c=n(5714);const r=e=>{let{label:t,link:n}=e;return React.createElement(a.OL,{to:n,className:e=>{let{isActive:t}=e;return t?`${c.Z.tab} ${c.Z["tab--active"]}`:c.Z.tab}},t)};t.Z=e=>{let{children:t,className:n=""}=e;return React.createElement("nav",{className:`${c.Z.tabs} ${n}`},t)}},9265:function(e,t,n){"use strict";var a=n(8063);t.Z=e=>{let{disabled:t=!1,id:n,label:c="",placeholder:r="",rows:i=3,value:o="",onChange:l=(()=>{})}=e;return React.createElement("div",null,Boolean(c)&&React.createElement("label",{className:a.Z.label,htmlFor:n},c),React.createElement("textarea",{className:a.Z.textarea,disabled:t,placeholder:r,rows:i,id:n,name:n,onChange:l,value:o||""}))}},8891:function(e,t,n){"use strict";n.d(t,{Z:function(){return p}});var a=n(5106),c=n(5736),r=n(1074),i=n(9196),o=n.n(i),l=n(2251),s=n(9971);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 p(e){let{threat:t,fixAllDialog:n,onCheckFix:c}=e;const[p,m]=(0,i.useState)(!0),d=(0,i.useCallback)((e=>{m(e.target.checked),c(e.target.checked,t)}),[c,t]);return o().createElement(o().Fragment,null,o().createElement("div",{className:s.Z.threat},o().createElement(r.Z,{icon:t.icon,className:s.Z.threat__icon}),o().createElement("div",{className:s.Z.threat__summary},o().createElement(a.ZP,{className:s.Z.threat__summary__label,mb:1},t.label),o().createElement(a.ZP,{className:s.Z.threat__summary__title},u(t.fixable))),o().createElement("div",{className:s.Z.threat__severity},o().createElement(l.Z,{severity:t.severity})),n&&o().createElement("div",{className:s.Z.threat__checkbox},o().createElement("input",{type:"checkbox",checked:p,onChange:d,value:t.id}))))}},5658:function(e,t,n){"use strict";var a=n(5106),c=n(9307),r=n(5736),i=n(9196),o=n(5773),l=n(9709);const __=r.__,_n=r._n,s=()=>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"}));t.Z=()=>{const{lastChecked:e}=(0,o.Z)(),t=(0,i.useMemo)((()=>e?(e=>{const t=new Date,n=6e4*t.getTimezoneOffset(),a=Math.floor((new Date(t.getTime()+n).getTime()-e)/1e3);let c=a/31536e3;return c>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(c),"jetpack-protect"),Math.floor(c)):(c=a/2592e3,c>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(c),"jetpack-protect"),Math.floor(c)):(c=a/86400,c>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(c),"jetpack-protect"),Math.floor(c)):(c=a/3600,c>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(c),"jetpack-protect"),Math.floor(c)):(c=a/60,c>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(c),"jetpack-protect"),Math.floor(c)):__("a few seconds ago","jetpack-protect")))))})(Date.parse(e)):null),[e]);return React.createElement("div",{className:l.Z.empty},React.createElement(s,null),React.createElement(a.H3,{weight:"bold",mt:8},__("Don't worry about a thing","jetpack-protect")),React.createElement(a.ZP,null,(0,c.createInterpolateElement)((0,r.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"),t),{strong:React.createElement("strong",null)})))}},2831:function(e,t,n){"use strict";var a=n(526),c=n(5106),r=n(857),i=n(8258),o=n(5736),l=n(9196),s=n.n(l),u=n(3898),p=n(6477),m=n(3584),d=n(9709);const __=o.__,h=e=>{let{description:t,filename:n,fixedIn:h,icon:g,id:f,name:v,source:E,table:b,title:k,type:y,version:Z}=e;const{adminUrl:C}=window.jetpackProtectInitialState||{},{run:_}=(0,i.Z)({productSlug:u.o,redirectUrl:C}),{recordEventHandler:w}=(0,p.Z)(),R=w("jetpack_protect_threat_list_get_scan_link_click",_),j=E?s().createElement(a.Z,{variant:"link",isExternalLink:!0,weight:"regular",href:E},__("See more technical details of this threat","jetpack-protect")):null,N=(0,l.useCallback)((()=>v&&Z?`${v} (${Z})`:n?n.split("/").pop():b||void 0),[n,v,b,Z]);return s().createElement(m.U,{id:f,label:N(),title:k,icon:g,onOpen:(0,l.useCallback)((()=>{["core","plugin","theme"].includes(y)&&w(`jetpack_protect_${y}_threat_open`)}),[w,y])},t&&s().createElement("div",{className:d.Z["threat-section"]},s().createElement(c.ZP,{variant:"title-small",mb:2},__("What is the problem?","jetpack-protect")),s().createElement(c.ZP,{mb:2},t),j),h&&s().createElement("div",{className:d.Z["threat-section"]},s().createElement(c.ZP,{variant:"title-small",mb:2},__("How to fix it?","jetpack-protect")),s().createElement(c.ZP,{mb:2},/* translators: Translates to Update to. %1$s: Name. %2$s: Fixed version */ -(0,o.sprintf)(__("Update to %1$s %2$s","jetpack-protect"),v,h)),s().createElement(r.Z,{description:__("Looking for advanced scan results and one-click fixes?","jetpack-protect"),cta:__("Upgrade Jetpack Protect now","jetpack-protect"),onClick:R,className:d.Z["threat-item-cta"]})),!t&&s().createElement("div",{className:d.Z["threat-section"]},j))};t.Z=e=>{let{list:t}=e;return s().createElement(m.Z,null,t.map((e=>{let{description:t,fixedIn:n,icon:a,id:c,name:r,source:i,table:o,title:l,type:u,version:p}=e;return s().createElement(h,{description:t,fixedIn:n,icon:a,id:c,key:c,name:r,source:i,table:o,title:l,type:u,version:p})})))}},5207:function(e,t,n){"use strict";var a=n(3363),c=n(3846),r=n(5106),i=n(526),o=n(9818),l=n(5736),s=n(9196),u=n.n(s),p=n(5773),m=n(4633),d=n(5658),h=n(2831),g=n(4289),f=n(1400),v=n(9709),E=n(7930);const __=l.__;t.Z=()=>{const{hasRequiredPlan:e}=(0,p.Z)(),{item:t,list:n,selected:b,setSelected:k}=(0,E.Z)(),y=n.filter((e=>e.fixable)),{setModal:Z}=(0,o.useDispatch)(m.t),{scan:C}=(0,o.useDispatch)(m.t),_=(0,o.useSelect)((e=>e(m.t).getScanIsEnqueuing())),w=(0,s.useCallback)((()=>{switch(b){case"all":return 1===n.length?__("All threats","jetpack-protect"):(0,l.sprintf)(/* translators: placeholder is the amount of threats found on the site. */ -__("All %s threats","jetpack-protect"),n.length);case"files":return(0,l.sprintf)(/* translators: placeholder is the amount of file threats found on the site. */ -__("%1$s file %2$s","jetpack-protect"),n.length,1===n.length?"threat":"threats");case"database":return(0,l.sprintf)(/* translators: placeholder is the amount of database threats found on the site. */ -__("%1$s database %2$s","jetpack-protect"),n.length,1===n.length?"threat":"threats");default:return(0,l.sprintf)(/* translators: Translates to Update to. %1$s: Name. %2$s: Fixed version */ -__("%1$s %2$s in your %3$s %4$s","jetpack-protect"),n.length,1===n.length?"threat":"threats",t?.name,t?.version)}}),[b,n,t]);return u().createElement(a.Z,{fluid:!0,horizontalSpacing:0,horizontalGap:3},u().createElement(c.Z,{lg:4},u().createElement(g.Z,{selected:b,onSelect:k})),u().createElement(c.Z,{lg:8},n?.length>0?u().createElement(u().Fragment,null,u().createElement("div",{className:v.Z["list-header"]},u().createElement(r.Dx,{className:v.Z["list-title"]},w()),e&&u().createElement(u().Fragment,null,y.length>0&&u().createElement(i.Z,{variant:"primary",className:v.Z["list-header-button"],onClick:(R=y,e=>{e.preventDefault(),Z({type:"FIX_ALL_THREATS",props:{threatList:R}})})},/* translators: Translates to Auto fix all. $s: Number of fixable threats. */ -(0,l.sprintf)(__("Auto fix all (%s)","jetpack-protect"),y.length)),u().createElement(i.Z,{variant:"secondary",className:v.Z["list-header-button"],isLoading:_,onClick:e=>{e.preventDefault(),C()}},__("Scan now","jetpack-protect")))),e?u().createElement(f.Z,{list:n}):u().createElement(h.Z,{list:n})):u().createElement(d.Z,null)));var R}},4289:function(e,t,n){"use strict";var a=n(2054),c=n(5736),r=n(797),i=n(2817),o=n(7663),l=n(8960),s=n(4160),u=n(6376),p=n(9196),m=n(6477),d=n(5773),h=n(5338);const __=c.__;t.Z=e=>{let{selected:t,onSelect:n}=e;const{plugins:c,themes:g,numThreats:f,numCoreThreats:v,numFilesThreats:E,numDatabaseThreats:b,hasRequiredPlan:k}=(0,d.Z)(),{recordEvent:y}=(0,m.Z)(),[Z]=(0,a.Z)("lg","<"),C=(0,p.useCallback)((()=>{y("jetpack_protect_navigation_all_click")}),[y]),_=(0,p.useCallback)((()=>{y("jetpack_protect_navigation_core_click")}),[y]),w=(0,p.useCallback)((()=>{y("jetpack_protect_navigation_plugin_click")}),[y]),R=(0,p.useCallback)((()=>{y("jetpack_protect_navigation_theme_click")}),[y]),j=(0,p.useCallback)((()=>{y("jetpack_protect_navigation_file_click")}),[y]),N=(0,p.useCallback)((()=>{y("jetpack_protect_navigation_database_click")}),[y]);return React.createElement(h.ZP,{selected:t,onSelect:n,mode:Z?"dropdown":"list"},React.createElement(h.Dx,{initial:!0,id:"all",label:__("All threats","jetpack-protect"),icon:r.Z,badge:f,disabled:f<=0,onClick:C,checked:!0}),React.createElement(h.Dx,{id:"wordpress",label:__("WordPress","jetpack-protect"),icon:i.Z,badge:v,disabled:v<=0,onClick:_,checked:!0}),React.createElement(h.KB,{label:__("Plugins","jetpack-protect"),icon:o.Z},c.map((e=>{let{name:t,threats:n,checked:a}=e;return React.createElement(h.Dx,{key:t,id:t,label:t,checked:a,badge:n?.length,disabled:n?.length<=0,onClick:w})}))),React.createElement(h.KB,{label:__("Themes","jetpack-protect"),icon:l.Z},g.map((e=>{let{name:t,threats:n,checked:a}=e;return React.createElement(h.Dx,{key:t,id:t,label:t,checked:a,badge:n?.length,disabled:n?.length<=0,onClick:R})}))),k&&React.createElement(React.Fragment,null,React.createElement(h.Dx,{id:"files",label:__("Files","jetpack-protect"),icon:s.Z,badge:E,disabled:E<=0,onClick:j,checked:!0}),React.createElement(h.Dx,{id:"database",label:__("Database","jetpack-protect"),icon:u.Z,badge:b,disabled:b<=0,onClick:N,checked:!0})))}},1400:function(e,t,n){"use strict";var a=n(526),c=n(5106),r=n(2054),i=n(9818),o=n(9307),l=n(5736),s=n(9196),u=n.n(s),p=n(6477),m=n(4633),d=n(7127),h=n(4257),g=n(289),f=n(9709);const __=l.__,v=e=>{let{context:t,description:n,diff:r,filename:o,fixedIn:v,icon:E,fixable:b,id:k,label:y,name:Z,source:C,title:_,type:w,severity:R}=e;const{setModal:j}=(0,i.useDispatch)(m.t),{recordEvent:N}=(0,p.Z)(),S=C?u().createElement(a.Z,{variant:"link",isExternalLink:!0,weight:"regular",href:C},__("See more technical details of this threat","jetpack-protect")):null;return u().createElement(g.c,{id:k,label:y,title:_,icon:E,fixable:b,severity:R,onOpen:(0,s.useCallback)((()=>{["core","plugin","theme","file","database"].includes(w)&&N(`jetpack_protect_${w}_threat_open`)}),[N,w])},n&&u().createElement("div",{className:f.Z["threat-section"]},u().createElement(c.ZP,{variant:"title-small",mb:2},__("What is the problem?","jetpack-protect")),u().createElement(c.ZP,{mb:2},n),S),(o||t||r)&&u().createElement(c.ZP,{variant:"title-small",mb:2},__("The technical details","jetpack-protect")),o&&u().createElement(u().Fragment,null,u().createElement(c.ZP,{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:f.Z["threat-filename"]},o)),t&&u().createElement(h.Z,{context:t}),r&&u().createElement(d.C,{diff:r}),v&&u().createElement("div",{className:f.Z["threat-section"]},u().createElement(c.ZP,{variant:"title-small",mb:2},__("How to fix it?","jetpack-protect")),u().createElement(c.ZP,{mb:2},/* translators: Translates to Update to. %1$s: Name. %2$s: Fixed version */ -(0,l.sprintf)(__("Update to %1$s %2$s","jetpack-protect"),Z,v))),!n&&u().createElement("div",{className:f.Z["threat-section"]},S),u().createElement("div",{className:f.Z["threat-footer"]},u().createElement(a.Z,{isDestructive:!0,variant:"secondary",onClick:e=>{e.preventDefault(),j({type:"IGNORE_THREAT",props:{id:k,label:y,title:_,icon:E,severity:R}})}},__("Ignore threat","jetpack-protect")),b&&u().createElement(a.Z,{onClick:e=>{e.preventDefault(),j({type:"FIX_THREAT",props:{id:k,label:y,title:_,icon:E,severity:R,fixable:b}})}},__("Fix threat","jetpack-protect"))))};t.Z=e=>{let{list:t}=e;const{scan:n}=(0,i.useDispatch)(m.t),l=(0,o.createInterpolateElement)(__("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"),{manualScanLink:u().createElement(a.Z,{variant:"link",onClick:e=>{e.preventDefault(),n()}})}),[s]=(0,r.Z)(["sm","lg"],[null,"<"]),p=e=>e.name&&e.version?`${e.name} (${e.version})`:e.filename?e.filename.split("/").pop():e.table?e.table:void 0;return t=t.map((e=>({label:p(e),...e}))),u().createElement(u().Fragment,null,!s&&u().createElement("div",{className:f.Z["accordion-heading"]},u().createElement("span",null,__("Details","jetpack-protect")),u().createElement("span",null,__("Severity","jetpack-protect")),u().createElement("span",null,__("Auto-fix","jetpack-protect")),u().createElement("span",null)),u().createElement(g.Z,null,t.map((e=>{let{context:t,description:n,diff:a,filename:c,fixedIn:r,icon:i,fixable:o,id:l,label:s,name:p,severity:m,source:d,table:h,title:g,type:f,version:E}=e;return u().createElement(v,{context:t,description:n,diff:a,filename:c,fixedIn:r,icon:i,fixable:o,id:l,key:l,label:s,name:p,severity:m,source:d,table:h,title:g,type:f,version:E})}))),u().createElement(c.ZP,{className:f.Z["manual-scan"],variant:"body-small"},l))}},7930:function(e,t,n){"use strict";var a=n(2817),c=n(7663),r=n(8960),i=n(4160),o=n(6376),l=n(9196),s=n(5773);const u=(e,t)=>Array.isArray(e)?e.map((e=>u(e,t))).flat():e?.threats?.map((n=>({...n,...e,icon:t}))),p=e=>{let{core:t,plugins:n,themes:l,files:s,database:p}=e;return[...u(t,a.Z),...u(n,c.Z),...u(l,r.Z),...u(s,i.Z),...u(p,o.Z)]};t.Z=()=>{const{plugins:e,themes:t,core:n,files:m,database:d}=(0,s.Z)();let h=p({core:n,plugins:e,themes:t,files:m,database:d}),g={};const[f,v]=(0,l.useState)(h.length?"all":null);switch(f){case"all":h=p({core:n,plugins:e,themes:t,files:m,database:d});break;case"wordpress":h=u(n,a.Z),g=n;break;case"files":h=u(m,i.Z),g=m;break;case"database":h=u(d,o.Z),g=d}const E=e.find((e=>e?.name===f));E&&(h=u(E,c.Z),g=E);const b=t.find((e=>e?.name===f));return b&&(h=u(b,r.Z),g=b),{item:g,list:h,selected:f,setSelected:v}}},2854:function(e,t,n){"use strict";var a=n(1294),c=n(8227);t.Z=e=>{let{children:t}=e;const{isUserConnected:n,hasConnectedOwner:r}=(0,a.Z)();return n&&r?t:React.createElement(c.Z,null)}},8227:function(e,t,n){"use strict";var a=n(5106),c=n(526),r=n(1294),i=n(9818),o=n(5736),l=n(4633),s=n(291),u=n(541);const __=o.__;t.Z=()=>{const{setModal:e}=(0,i.useDispatch)(l.t),{userIsConnecting:t,handleConnectUser:n}=(0,r.Z)({redirectUri:"admin.php?page=jetpack-protect"});return React.createElement(React.Fragment,null,React.createElement(a.ZP,{variant:"title-medium",mb:2},__("User connection needed","jetpack-protect")),React.createElement(s.Z,{type:"info",message:__("Before Jetpack Protect can ignore and auto-fix threats on your site, a user connection is needed.","jetpack-protect")}),React.createElement(a.ZP,{mb:3},__("A user connection provides Jetpack Protect the access necessary to perform these tasks.","jetpack-protect")),React.createElement(a.ZP,{mb:3},__("Once you’ve secured a user connection, all Jetpack Protect features will be available for use.","jetpack-protect")),React.createElement("div",{className:u.Z.footer},React.createElement(c.Z,{variant:"secondary",onClick:t=>{t.preventDefault(),e({type:null})}},__("Not now","jetpack-protect")),React.createElement(c.Z,{isExternalLink:!0,weight:"regular",isLoading:t,onClick:n},__("Connect your user account","jetpack-protect"))))}},3898:function(e,t,n){"use strict";n.d(t,{K:function(){return a},o:function(){return c}});const a="https://wordpress.org/support/plugin/jetpack-protect/",c="jetpack_scan"},6477:function(e,t,n){"use strict";var a=n(6975),c=n(1294),r=n(9196);t.Z=function(){let{pageViewEventName:e,pageViewNamespace:t="jetpack",pageViewSuffix:n="page_view",pageViewEventProperties:i={}}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const{isUserConnected:o,isRegistered:l,userConnectionData:s}=(0,c.Z)(),{login:u,ID:p}=s.currentUser?.wpcomUser||{},{tracks:m}=a.Z,{recordEvent:d}=m,h=(0,r.useCallback)((async(e,t)=>{d(e,t)}),[d]),g=(0,r.useCallback)((function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:()=>{};return n="function"==typeof t?t:n,t="function"==typeof t?{}:t,()=>h(e,t).then(n)}),[h]);(0,r.useEffect)((()=>{o&&p&&u&&a.Z.initialize(p,u)}),[o,p,u]);const f=e?`${t}_${e}_${n}`:null;return(0,r.useEffect)((()=>{l&&f&&d(f,i)}),[]),{recordEvent:h,recordEventHandler:g}}},5773:function(e,t,n){"use strict";n.d(t,{Z:function(){return i}});var a=n(9818),c=n(9196),r=n(4633);function i(){const{statusIsFetching:e,status:t,jetpackScan:n,hasRequiredPlan:i}=(0,a.useSelect)((e=>({statusIsFetching:e(r.t).getStatusIsFetching(),status:e(r.t).getStatus(),jetpackScan:e(r.t).getJetpackScan(),hasRequiredPlan:e(r.t).hasRequiredPlan()})));let o="error";!0===e?o="loading":t.status&&(o=t.status);const l=(0,c.useMemo)((()=>t.core?.threats?.length||0),[t.core]),s=(0,c.useMemo)((()=>(t.plugins||[]).reduce(((e,t)=>e+t.threats.length),0)),[t.plugins]),u=(0,c.useMemo)((()=>(t.themes||[]).reduce(((e,t)=>e+t.threats.length),0)),[t.themes]),p=(0,c.useMemo)((()=>t.files?.length||0),[t.files]),m=(0,c.useMemo)((()=>t.database?.length||0),[t.database]);return{numThreats:l+s+u+p+m,numCoreThreats:l,numPluginsThreats:s,numThemesThreats:u,numFilesThreats:p,numDatabaseThreats:m,lastChecked:t.lastChecked||null,errorCode:t.errorCode||null,errorMessage:t.errorMessage||null,core:t.core||{},plugins:t.plugins||[],themes:t.themes||[],files:{threats:t.files||[]},database:{threats:t.database||[]},currentStatus:o,hasUncheckedItems:t.hasUncheckedItems,jetpackScan:n,hasRequiredPlan:i}}},8963:function(e,t,n){"use strict";var a=n(9818),c=n(9196),r=n(1827),i=n(4633);t.Z=()=>{const{setWafConfig:e,setWafStats:t,setWafIsEnabled:n,setWafIsUpdating:o,setWafIsToggling:l}=(0,a.useDispatch)(i.t),s=(0,a.useSelect)((e=>e(i.t).getWaf())),u=(0,c.useCallback)((()=>(o(!0),r.Z.fetchWaf().then((a=>{n(a?.isEnabled),e(a?.config),t(a?.stats)})).finally((()=>o(!1))))),[e,t,n,o]),p=(0,c.useCallback)((()=>(s.isEnabled||l(!0),o(!0),r.Z.toggleWaf().then(u).finally((()=>{l(!1),o(!1)})))),[u,s.isEnabled,l,o]),m=(0,c.useCallback)((()=>s.isEnabled?Promise.resolve():p()),[p,s.isEnabled]),d=(0,c.useCallback)((()=>(o(!0),m().then((()=>r.Z.updateWaf({jetpack_waf_automatic_rules:!s.config.jetpackWafAutomaticRules}))).then(u).finally((()=>o(!1))))),[m,u,o,s.config.jetpackWafAutomaticRules]),h=(0,c.useCallback)((()=>(o(!0),m().then((()=>r.Z.updateWaf({jetpack_waf_ip_list:!s.config.jetpackWafIpList}))).then(u).finally((()=>o(!1))))),[m,u,o,s.config.jetpackWafIpList]),g=(0,c.useCallback)((()=>(o(!0),m().then((()=>r.Z.updateWaf({brute_force_protection:!s.config.bruteForceProtection}))).then(u).finally((()=>o(!1))))),[m,u,o,s.config.bruteForceProtection]),f=(0,c.useCallback)((()=>(o(!0),m().then((()=>r.Z.updateWaf({jetpack_waf_share_data:!s.config.jetpackWafShareData}))).then(u).finally((()=>o(!1))))),[m,u,o,s.config.jetpackWafShareData]),v=(0,c.useCallback)((e=>(o(!0),m().then((()=>r.Z.updateWaf(e))).then(u).finally((()=>o(!1))))),[m,u,o]);return(0,c.useEffect)((()=>{void 0!==s.config||s.isFetching||u()}),[s.config,s.isFetching,o,u]),{...s,refreshWaf:u,toggleWaf:p,toggleAutomaticRules:d,toggleManualRules:h,toggleBruteForceProtection:g,toggleShareData:f,updateConfig:v}}},5230:function(e,t,n){"use strict";n.d(t,{BZ:function(){return y},Gk:function(){return d},Oc:function(){return S},Ot:function(){return N},PF:function(){return P},P_:function(){return E},RR:function(){return f},Rj:function(){return R},U2:function(){return v},VF:function(){return C},Xm:function(){return k},Y2:function(){return m},ZP:function(){return $},_N:function(){return l},d0:function(){return u},dG:function(){return _},eG:function(){return h},hI:function(){return g},i0:function(){return Z},jA:function(){return s},kd:function(){return j},l:function(){return I},o9:function(){return p},r0:function(){return w},tu:function(){return b},y:function(){return x}});var a=n(6989),c=n.n(a),r=n(5736),i=n(4769),o=n.n(i);const _n=r._n,__=r.__,l="SET_CREDENTIALS_STATE_IS_FETCHING",s="SET_CREDENTIALS_STATE",u="SET_STATUS",p="SET_STATUS_PROGRESS",m="START_SCAN_OPTIMISTICALLY",d="SET_STATUS_IS_FETCHING",h="SET_SCAN_IS_UNAVAILABLE",g="SET_SCAN_IS_ENQUEUING",f="SET_INSTALLED_PLUGINS",v="SET_INSTALLED_THEMES",E="SET_WP_VERSION",b="SET_JETPACK_SCAN",k="SET_THREAT_IS_UPDATING",y="SET_THREATS_ARE_FIXING",Z="SET_MODAL",C="SET_NOTICE",_="CLEAR_NOTICE",w="SET_HAS_REQUIRED_PLAN",R="SET_WAF_IS_SEEN",j="SET_WAF_UPGRADE_IS_SEEN",N="SET_WAF_IS_ENABLED",S="SET_WAF_IS_UPDATING",P="SET_WAF_IS_TOGGLING",x="SET_WAF_CONFIG",I="SET_WAF_STATS",M=e=>({type:u,status:e}),T=()=>({type:m}),L=e=>c()({path:"jetpack-protect/v1/status"+(e?"?hard_refresh=true":""),method:"GET"}),z=function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return async t=>{let{dispatch:n}=t;return n(O(!0)),await new Promise(((t,a)=>L(e).then(A).then((e=>{n(D("unavailable"===e.status)),n(M(o()(e))),t(e)})).catch((e=>{a(e)})).finally((()=>{n(O(!1))}))))}},A=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return new Promise(((n,a)=>{"unavailable"===e.status&&t<3?L(!0).then((e=>{setTimeout((()=>{A(e,t+1).then((e=>n(e))).catch((e=>a(e)))}),5e3)})).catch(a):n(e)}))},F=e=>({type:l,isFetching:e}),V=e=>({type:s,credentials:e}),O=e=>({type:d,status:e}),D=e=>({type:h,status:e}),H=e=>({type:g,isEnqueuing:e}),U=(e,t)=>({type:k,payload:{threatId:e,isUpdating:t}}),B=e=>({type:y,threatIds:e}),W=e=>async t=>{let{dispatch:n}=t;const a=e.reduce(((e,t)=>`${e}threat_ids[]=${t}&`),"jetpack-protect/v1/fix-threats-status?");return n(B(e)),await c()({path:a,method:"GET"}).then((async t=>{const a=Object.values(t.threats);if(a.filter((e=>"in_progress"===e.status)).length>0)return await new Promise((()=>{setTimeout((()=>{n(W(e))}),1e3)}));if(!a.filter((e=>"fixed"===e.status)).length===e.length)throw"Not all threats could be fixed."})).then((()=>{n(z()),n(J({type:"success",message:(0,r.sprintf)( -// translators: placeholder is the number amount of fixed threats. -_n("%s threat was fixed successfully","%s threats were fixed successfully",e.length,"jetpack-protect"),e.length)}))})).catch((()=>{n(J({type:"error",message:__("Not all threats could be fixed. Please contact our support.","jetpack-protect")}))})).finally((()=>{n(B([]))}))},J=e=>({type:C,payload:e}),G=e=>({type:w,hasRequiredPlan:e}),$={checkCredentials:()=>async e=>{let{dispatch:t}=e;return await new Promise(((e,n)=>(t(F(!0)),c()({path:"jetpack-protect/v1/check-credentials",method:"POST"}).then((n=>{t(V(n)),e(n)})).catch((e=>{n(e)})).finally((()=>{t(F(!1))})))))},setCredentials:V,setCredentialsIsFetching:F,setStatus:M,setStatusProgress:e=>({type:p,currentProgress:e}),startScanOptimistically:T,refreshStatus:z,setStatusIsFetching:O,setScanIsEnqueuing:H,setInstalledPlugins:e=>({type:f,plugins:e}),setInstalledThemes:e=>({type:v,themes:e}),setwpVersion:e=>({type:E,version:e}),setJetpackScan:e=>({type:b,scan:e}),ignoreThreat:function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:()=>{};return async n=>{let{dispatch:a}=n;return a(U(e,!0)),await new Promise((()=>c()({path:`jetpack-protect/v1/ignore-threat?threat_id=${e}`,method:"POST"}).then((()=>a(z()))).then((()=>a(J({type:"success",message:__("Threat ignored","jetpack-protect")})))).catch((()=>a(J({type:"error",message:__("An error ocurred ignoring the threat.","jetpack-protect")})))).finally((()=>{a(U(e,!1)),t()}))))}},setModal:e=>({type:Z,payload:e}),setNotice:J,clearNotice:()=>({type:_}),fixThreats:function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:()=>{};return async n=>{let{dispatch:a}=n;return e.forEach((e=>{a(U(e,!0))})),await new Promise((()=>c()({path:`jetpack-protect/v1/fix-threats?threat_ids=${e}`,method:"POST",data:{threatIds:e}}).then((()=>a(J({type:"success",message:__("We're hard at work fixing this threat in the background. Please check back shortly.","jetpack-protect")})))).then((()=>{setTimeout((()=>a(W(e))),1e3)})).catch((()=>a(J({type:"error",message:__("Error fixing threats. Please contact support.","jetpack-protect")})))).finally((()=>{e.forEach((e=>{a(U(e,!1))})),t()}))))}},scan:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:()=>{};return async t=>{let{dispatch:n}=t;return n(H(!0)),await new Promise((()=>c()({path:"jetpack-protect/v1/scan",method:"POST"}).then((()=>{n(T()),setTimeout((()=>n(z(!0))),5e3)})).catch((()=>n(J({type:"error",message:__("An error ocurred enqueuing the scan","jetpack-protect")})))).finally((()=>{n(H(!1)),e()}))))}},setThreatsAreFixing:B,refreshPlan:()=>e=>{let{dispatch:t}=e;c()({path:"jetpack-protect/v1/check-plan",method:"GET"}).then((e=>t(G(e))))},setHasRequiredPlan:G,setScanIsUnavailable:D,setWafIsEnabled:e=>({type:N,isEnabled:e}),setWafIsSeen:e=>({type:R,isSeen:e}),setWafUpgradeIsSeen:e=>({type:j,upgradeIsSeen:e}),setWafIsUpdating:e=>({type:S,isUpdating:e}),setWafIsToggling:e=>({type:P,isToggling:e}),setWafConfig:e=>({type:x,config:e}),setWafStats:e=>({type:I,stats:e})}},3638:function(e,t,n){"use strict";var a=n(9818),c=n(5230);const r={isSupported:null,isSeen:!1,upgradeIsSeen:!1,isEnabled:!1,isUpdating:!1,isToggling:!1,config:void 0,stats:void 0},i=(0,a.combineReducers)({credentials:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1?arguments[1]:void 0;return t.type===c.jA?t.credentials:e},credentialsIsFetching:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;return t.type===c._N?t.isFetching:e},status:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case c.d0:return t.status;case c.o9:return{...e,currentProgress:t.currentProgress};case c.Y2:return{...e,currentProgress:0,status:"optimistically_scanning"}}return e},statusIsFetching:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;return t.type===c.Gk?t.status:e},scanIsUnavailable:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;return t.type===c.eG?t.status:e},scanIsEnqueuing:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;return t.type===c.hI?t.isEnqueuing:e},installedPlugins:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return t.type===c.RR?t.plugins:e},installedThemes:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return t.type===c.U2?t.themes:e},wpVersion:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return t.type===c.P_?t.version:e},jetpackScan:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return t.type===c.tu?t.scan:e},threatsUpdating:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return t.type===c.Xm?{...e,[t.payload.threatId]:t.payload.isUpdating}:e},modal:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return t.type===c.i0?{...e,...t.payload}:e},notice:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case c.VF:return{...e,...t.payload};case c.dG:return{}}return e},setThreatsFixing:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1?arguments[1]:void 0;return t.type===c.BZ?t.threatIds:e},hasRequiredPlan:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;return t.type===c.r0?t.hasRequiredPlan:e},waf:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:r,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case c.Rj:return{...e,isSeen:t.isSeen};case c.kd:return{...e,upgradeIsSeen:t.upgradeIsSeen};case c.Ot:return{...e,isEnabled:t.isEnabled};case c.y:return{...e,config:t.config};case c.l:return{...e,stats:t.stats};case c.Oc:return{...e,isUpdating:t.isUpdating};case c.PF:return{...e,isToggling:t.isToggling}}return e}});t.Z=i},1056:function(e,t,n){"use strict";var a=n(6989),c=n.n(a),r=n(5230);const i={getJetpackScan:{isFulfilled:e=>Object.keys(e?.jetpackScan).length>0,fulfill:()=>async e=>{let{dispatch:t}=e;const n=await c()({path:"/my-jetpack/v1/site/products/scan",method:"GET"});t(r.ZP.setJetpackScan(n))}}};t.Z=i},6850:function(e,t){"use strict";t.Z={getCredentials:e=>e.credentials||null,getCredentialsIsFetching:e=>e.credentialsIsFetching||!1,getInstalledPlugins:e=>e.installedPlugins||{},getInstalledThemes:e=>e.installedThemes||{},getStatus:e=>e.status||{},getStatusIsFetching:e=>e.statusIsFetching||!1,getScanIsUnavailable:e=>e.scanIsUnavailable||!1,getScanIsEnqueuing:e=>e.scanIsEnqueuing||!1,getWpVersion:e=>e.wpVersion||"",getJetpackScan:e=>e.jetpackScan||{},getThreatsUpdating:e=>e.threatsUpdating||{},getModalType:e=>e.modal?.type||null,getModalProps:e=>e.modal?.props||{},getNotice:e=>e.notice||null,getThreatsAreFixing:e=>e.threatsAreFixing||[],hasRequiredPlan:e=>e.hasRequiredPlan||!1,getWaf:e=>e.waf}},5217:function(e,t,n){"use strict";var a=n(17),c=n.n(a),r=n(9818);class i{static mayBeInit(e,t){null===i.store&&(i.store=(0,r.createReduxStore)(e,t),(0,r.register)(i.store))}}c()(i,"store",null),t.Z=i},4633:function(e,t,n){"use strict";n.d(t,{N:function(){return p},t:function(){return u}});var a=n(4769),c=n.n(a),r=n(5230),i=n(3638),o=n(1056),l=n(6850),s=n(5217);const u="jetpack-protect";function p(){s.Z.mayBeInit(u,{__experimentalUseThunks:!0,reducer:i.Z,actions:r.ZP,selectors:l.Z,resolvers:o.Z,initialState:c()(window.jetpackProtectInitialState)||{}})}},5983:function(e,t,n){"use strict";e.exports=n.p+"images/in-progress-db145d62b5ef09c05ad7.png"},6436:function(e){"use strict";if(void 0==={consumer_slug:"jetpack-protect"}){var t=new Error('Cannot find module \'{"consumer_slug":"jetpack-protect"}\'');throw t.code="MODULE_NOT_FOUND",t}e.exports={consumer_slug:"jetpack-protect"}},9196:function(e){"use strict";e.exports=window.React},6292:function(e){"use strict";e.exports=window.moment},6989:function(e){"use strict";e.exports=window.wp.apiFetch},5609:function(e){"use strict";e.exports=window.wp.components},4333:function(e){"use strict";e.exports=window.wp.compose},9818:function(e){"use strict";e.exports=window.wp.data},9771:function(e){"use strict";e.exports=window.wp.date},9307:function(e){"use strict";e.exports=window.wp.element},5736:function(e){"use strict";e.exports=window.wp.i18n},444:function(e){"use strict";e.exports=window.wp.primitives},6483:function(e){"use strict";e.exports=window.wp.url},17:function(e,t,n){var a=n(6930);e.exports=function(e,t,n){return(t=a(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.__esModule=!0,e.exports.default=e.exports},2674:function(e){function t(){return e.exports=t=Object.assign?Object.assign.bind():function(e){for(var t=1;twindow.scrollTo(0,0)),[e]),null}(0,u.N)(),function(){const n=document.getElementById("jetpack-protect-root");if(null===n)return;const a=c().createElement(e.ZP,null,c().createElement(i.UT,null,c().createElement(p,null),c().createElement(r.Z5,null,c().createElement(r.AW,{path:"/",element:c().createElement(s.Z,null)}),c().createElement(r.AW,{path:"/firewall",element:c().createElement(o.Z,null)}))),c().createElement(l.Z,null));t.createRoot?t.createRoot(n).render(a):t.render(a,n)}()}()}(); \ 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 77b8fe88..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.js.LICENSE.txt +++ /dev/null @@ -1,35 +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 - */ - -/*! - Copyright (c) 2018 Jed Watson. - Licensed under the MIT License (MIT), see - http://jedwatson.github.io/classnames -*/ - -/** - * React Router DOM v6.2.2 - * - * 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.2.2 - * - * 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 c5721523..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.rtl.css +++ /dev/null @@ -1 +0,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{fill:var(--jp-gray);flex-shrink:0;margin:0 var(--spacing-base)}.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)}.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)}: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-10:#f2cf75;--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-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}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{grid-gap:24px;display:grid;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 .components-popover__content{border:1px solid var(--jp-gray);border-radius:4px;outline:none;padding:24px;white-space:normal;width:304px}.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-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}.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.5px;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.5px 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)}.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)}.terms-of-service{color:var(--jp-black);font-size:var(--font-body)}.terms-of-service .terms-of-service__link{color:var(--jp-green-50)}.dovianZYLKhnbnh9I06o{align-items:flex-start;display:flex;flex-wrap:wrap;justify-content:flex-end}.lljtQMhW7lq5tE5SDJEf{flex-basis:0;flex-grow:2}.dhFQXpZfMwVI8vuYHnwC{align-items:flex-start;display:inline-flex;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}.UL3B1tQ854mN7r6taB61{align-items:center;display:flex;flex-wrap:wrap;justify-content:space-between}.IG56Hw7ZR_7rKVsM78qw:focus:not(:disabled){box-shadow:none}.sexr0jUxC1jVixdKiDnC{margin-right:-20px}@media(max-width:782px){.sexr0jUxC1jVixdKiDnC{margin-right:-10px}}.sexr0jUxC1jVixdKiDnC.vKQ11sLeAM45M04P1ccj{background-color:var(--jp-white)}.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}}.jp-dashboard-footer{align-items:center;color:#000;display:flex;flex-flow:row wrap;justify-content:space-between;max-width:1128px;width:100%}.jp-dashboard-footer a,.jp-dashboard-footer a:hover,.jp-dashboard-footer a:visited{color:#000;text-decoration:none}.jp-dashboard-footer__jetpack-symbol,.jp-dashboard-footer__module-name{display:inline-block;vertical-align:middle}.jp-dashboard-footer__module-name{font-size:12px;font-weight:600;margin-right:5px}.vMa4i_Dza2t5Zi_Bw9Nf{background:var(--jp-white-off)}.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)}.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}.uQlXhcfYn9tbnK27_Gct{align-items:center;display:flex}.uQlXhcfYn9tbnK27_Gct input[type=checkbox]:checked{background:var(--jp-green-40);border-color:var(--jp-green-40)}.uQlXhcfYn9tbnK27_Gct input[type=checkbox]:indeterminate{background:var(--jp-green-40);border-color:var(--jp-green-40)}.uQlXhcfYn9tbnK27_Gct input[type=checkbox]:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px var(--jp-green-40)}.PO9zDOaSkcv_RqpfZF_v,.e5YHJiYcvfgdEEJsS_YM{margin-bottom:calc(var(--spacing-base)*7);margin-top:calc(var(--spacing-base)*7)}@media(max-width:599px){.PO9zDOaSkcv_RqpfZF_v{margin-top:0}}.gTWkHo5lqwE_OCesAhBx{color:var(--jp-gray-50)}.gTWkHo5lqwE_OCesAhBx:before{background:var(--jp-gray-50);border-radius:50%;content:"";display:inline-block;height:8px;margin-left:var(--spacing-base);width:8px}.gTWkHo5lqwE_OCesAhBx.JeLxNe31ii68Utrr2xr6{color:var(--jp-green-40)}.gTWkHo5lqwE_OCesAhBx.JeLxNe31ii68Utrr2xr6:before{background:var(--jp-green-40)}svg.V6B8ltQ7TH3UKzUC_qy1{color:var(--jp-black);height:32px;margin:0;width:32px}.C9hcvYAbgHPhN2Tl22xg{align-items:center;display:flex;flex-wrap:wrap;justify-content:flex-start}.C9hcvYAbgHPhN2Tl22xg .XkbIpr2gzB4XEhHgzkY4{margin-left:calc(var(--spacing-base)/2)}.BfcZn0_X33Ajdd1Gl18G{display:flex}.BfcZn0_X33Ajdd1Gl18G>.rBmVJIeTNpd0RJWaRGuJ{fill:var(--jp-gray-20);display:flex;margin-right:calc(var(--spacing-base)/2)}.jVq5444f1Xh6nNkz0Qe_{margin-top:calc(var(--spacing-base)*4)}.amF9cOnMiv2nHbkMXQiQ{align-items:center;display:flex;flex-wrap:wrap;justify-content:space-between}.FodE_7RbLD8zeBSd6eVR{display:flex;flex-wrap:wrap;margin-right:auto}.FodE_7RbLD8zeBSd6eVR>:first-child{margin-left:calc(var(--spacing-base)*3)}.twyPhW_K164HITnDrwEg{padding:calc(var(--spacing-base)*2);width:250px}.tbcd9xc_TjcFdokOt3F_{font-size:18px}@media(max-width:599px){.pnoqLV3l30xuvj2hLlJc{width:90%}.FodE_7RbLD8zeBSd6eVR{margin-top:calc(var(--spacing-base)*3)}.FodE_7RbLD8zeBSd6eVR>:first-child{margin-bottom:var(--spacing-base);margin-left:0}}.IunwKwdvL271DxBIniPb[type=checkbox]{display:none}.svA9WxEcOByd5S2fZonA{border:2px solid var(--jp-black);border-radius:100px;box-sizing:border-box;cursor:pointer;display:inline-block;height:24px;outline:0;padding:2px;position:relative;transition:all .4s ease,box-shadow 0s;vertical-align:middle;width:48px}.svA9WxEcOByd5S2fZonA:after{background:var(--jp-black);border-radius:50%;content:"";display:block;height:16px;position:relative;right:0;transition:all .2s ease;width:16px}.IunwKwdvL271DxBIniPb:checked+.svA9WxEcOByd5S2fZonA:after{right:22px}.IunwKwdvL271DxBIniPb:checked:disabled+.svA9WxEcOByd5S2fZonA{background-color:var(--jp-black);border-color:var(--jp-black)}.IunwKwdvL271DxBIniPb:checked:disabled+.svA9WxEcOByd5S2fZonA:after{background-color:var(--jp-white)}.IunwKwdvL271DxBIniPb:checked:not(:disabled)+.svA9WxEcOByd5S2fZonA{background-color:var(--jp-green);border-color:var(--jp-green)}.IunwKwdvL271DxBIniPb:checked:not(:disabled)+.svA9WxEcOByd5S2fZonA:after{background-color:var(--jp-white)}.IunwKwdvL271DxBIniPb:disabled+span.svA9WxEcOByd5S2fZonA{cursor:default;opacity:.25}.IunwKwdvL271DxBIniPb.wOd7DeP76v1fczKfah5n+.svA9WxEcOByd5S2fZonA{border-radius:8px;height:16px;width:24px}.IunwKwdvL271DxBIniPb.wOd7DeP76v1fczKfah5n+.svA9WxEcOByd5S2fZonA:after{height:12px;width:12px}.IunwKwdvL271DxBIniPb.wOd7DeP76v1fczKfah5n:checked+.svA9WxEcOByd5S2fZonA:after{right:8px}._aiMxmJRAw5jRPbZFX57{background-color:var(--jp-gray-90);border-radius:var(--jp-border-radius);color:var(--jp-white);display:flex;overflow:hidden}._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{fill:var(--jp-white);align-items:center;background-color:var(--jp-yellow-30);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:transparent;border:none;cursor:pointer;display:flex;justify-content:center;padding:calc(var(--spacing-base)*1.5)}.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:calc(var(--spacing-base)*2)}.DM4b8iQ0ewvRYdIPxvZ8{max-width:calc(744px + var(--spacing-base)*6);width:100%}.bW6ZuNzJBYU5PVPktE2S{display:flex}.bW6ZuNzJBYU5PVPktE2S:not(:first-child){margin-top:calc(var(--spacing-base)*7)}.di3wjXHrX1rk_H6rlxKM{margin-left:calc(var(--spacing-base)*2);padding-top:calc(var(--spacing-base)/2)}@media(min-width:600px){.di3wjXHrX1rk_H6rlxKM{margin-left:calc(var(--spacing-base)*5)}}.IrzHnNkRvORtyCL0yiWa{width:100%}.sU82bpLEYPC9n_CFAKoz{align-items:center;display:flex}.ZZc0LldcbJpcftqCe43T .IrzHnNkRvORtyCL0yiWa{opacity:.5}.T17WOOJI7XHN7KRmYaCe>:last-child{margin-top:calc(var(--spacing-base)*2)}@media(min-width:600px){.T17WOOJI7XHN7KRmYaCe{display:flex;justify-content:space-between}}.typbjN2keZ97hj2TmuMC{display:flex;flex-wrap:wrap;margin-top:calc(var(--spacing-base)*2)}.UUXAN8VTAZY0h8t9rCHG{color:var(--jp-green-50);margin-left:calc(var(--spacing-base)/2)}.eFjcadLMEXY5O61vsTrx{color:var(--jp-gray-50)}.Tr5uYvclUiwlC5kuGk7E{color:var(--jp-red-50)}.zPZcNgYx2X5778nHHtlH{display:flex;flex-wrap:wrap}.lNtkRXnB1z_kYB28MUWq{color:var(--jp-gray-50)}.JgH5ykcLynEgqXYurT78{margin-left:calc(var(--spacing-base)/2)}.JgH5ykcLynEgqXYurT78,.xlWW0IoKZwTZt1Ti0tcQ{color:var(--jp-green-50)}.zhBcgCUGgyC7PvWk8ewB{margin-top:calc(var(--spacing-base)*3)}@media(min-width:600px){.zhBcgCUGgyC7PvWk8ewB{padding-right:calc(var(--spacing-base)*11)}}.mah_f2OWxZ3Vqt_jRFdR{margin-bottom:calc(var(--spacing-base)*4)}.Ax2SmW57c0U5xOTjZuAA{margin:calc(var(--spacing-base)*-1) calc(var(--spacing-base)*-2)}.xGZeYQr0_nPJTFmd8pW4{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)}.RYTIt8kwLbKcUbWOfG4g{padding:calc(var(--spacing-base)*3);width:304px}.BqXge2rIUP0a_74yvYbr{display:flex;justify-content:space-between}.Lr10UUCcSLF3T_0QqoPr{margin:calc(var(--spacing-base)*-1) calc(var(--spacing-base)*-3)}.Lr10UUCcSLF3T_0QqoPr:focus,.Lr10UUCcSLF3T_0QqoPr:focus:not(:disabled){box-shadow:none}.th_VukMuODIOVLC7oJo6{display:flex;justify-content:flex-end}.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{margin-left:20px}.FGpSkMCiIHQjszcV0dbn,.KoWZcCwhW13xvkEb0QON{height:calc(var(--spacing-base)*3);width:calc(var(--spacing-base)*3)}.KoWZcCwhW13xvkEb0QON{background-color:transparent;border:none;cursor:pointer;outline:none}@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;margin-top:20px}.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)}.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);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}._Wc3apZobag_9Ag_THTb{display:flex;justify-content:space-between}.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 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%}.JiJhrZaThvWCpM2AfGen{border-radius:32px;flex-shrink:0;font-size:12px;font-style:normal;font-weight:600;line-height:16px;padding:calc(var(--spacing-base)/2);position:relative;text-align:center;width:60px}._7SGksgOpcPbHfPPpQTV{background:var(--jp-red-5);color:var(--jp-red-60)}.pGNquShR54adQ61sx3lP{background:var(--jp-yellow-5);color:var(--jp-yellow-60)}.IM5kkexAfwGLM6zz0Exd{background:var(--jp-gray-0);color:var(--jp-gray-50)}.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)}.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)}.WtVEv641JBaLl929sZq2{align-items:flex-start;background-color:rgba(0,0,0,.25);bottom:0;display:flex;justify-content:center;left:0;padding-top:calc(var(--spacing-base)*12 + 2px);position:fixed;right:0;top:0;z-index:999999}.G0aPt7WmA1rkUE0wcTno{background:var(--jp-white);border:1px solid var(--jp-gray);border-radius:calc(var(--jp-border-radius)*2);box-shadow:0 8px 20px rgba(0,0,0,.25);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}.EU0Rvu4PDqVtnCAmbgHg{height:56px;margin-bottom:calc(var(--spacing-base)*8);width:48px}.EU0Rvu4PDqVtnCAmbgHg>svg{position:relative;right:-40px;top:-36px}.vzMlFr1AXWqefpRrb976{align-items:center;display:flex;justify-content:space-between;margin-bottom:calc(var(--spacing-base)*3)}.gYSOMa4xxLXmsNzvFPkW{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)}.Clxt94RgGnDrhORZZyPr,.K2OG1vK5PSOYDWKtqKKG{margin-top:calc(var(--spacing-base)*7)}.ZMBDiTLzs27F012iOsMK>:first-child{flex:1}@media(min-width:960px){.ZMBDiTLzs27F012iOsMK{align-items:center;display:flex}}.zI2DKzqRc1MhF6aq5eHt{align-items:center;color:var(--jp-black);display:flex}.iHgPFku9KaLz8FIQV1Qw{margin-left:var(--spacing-base);margin-right:-4px}.xuIO_ubyDN6IGJ67NTlx{margin-top:calc(var(--spacing-base)*3)}@media(min-width:960px){.xuIO_ubyDN6IGJ67NTlx{margin-top:0}}.ctq2nQkzIfSoMkldF9t9{margin-top:calc(var(--spacing-base)*2);width:100%}@media(min-width:960px){.ctq2nQkzIfSoMkldF9t9{margin-right:calc(var(--spacing-base)*2);margin-top:0;width:auto}}.cuoSlhSNrqf1dozY22Xb{fill:#000}.JLquNpQVlysAamuh5lJO,.lAIiifeLMmZAPlQ9n9ZR{fill:var(--jp-green-primary)}.cbOwD8Y4tFjwimmtchQI{fill:#757575}.cbOwD8Y4tFjwimmtchQI.aHOlEBGD5EA8NKRw3xTw{fill:var(--color-facebook);border-radius:50%!important}.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)}.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}.r4Id5qht2FD68jCAH2Cl{margin-right: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)}.ZSZPabDoB8MVVPttP0tu{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%}.ZSZPabDoB8MVVPttP0tu>span:first-child{grid-column:1/7}.ZSZPabDoB8MVVPttP0tu>span:not(:first-child){text-align:center}.iJ_biSBRDribuNKX0Zuw{margin:calc(var(--spacing-base)*4) calc(var(--spacing-base)*8);text-align:center}.iJ_biSBRDribuNKX0Zuw>button span{color:var(--jp-gray-70);font-size:var(--font-body-small);font-weight:400}.iJ_biSBRDribuNKX0Zuw button:hover:not(:disabled){text-decoration-line:none}.iJ_biSBRDribuNKX0Zuw button:focus:not(:disabled){box-shadow:none}@media(max-width:599px){.uym7dGHhp6ifjF57yOAO{margin-bottom:calc(var(--spacing-base)*3)}.e_2eFTR8RyHwmfeqJL4F{display:none}.r4Id5qht2FD68jCAH2Cl{flex:1}.r4Id5qht2FD68jCAH2Cl:first-of-type{margin-right:0}.pkw2LnOTd8VvQ3oT8sXQ{justify-content:center}.pkw2LnOTd8VvQ3oT8sXQ>*{width:50%}}.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 rgba(0,0,0,.08);margin:0;padding:var(--spacing-base) 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)}.t5TwI3d3FnCJvFBlkmm5{display:block}.kSa6ERuVPsCMPXugb030{display:none}.LumryWNddoF092fZgN2O{font-size:var(--font-body);line-height:1.5}.NFMwU3H5k2qArZe2TTp9{background-color:var(--jp-gray-10);font-weight:600;padding:calc(var(--spacing-base)/2) var(--spacing-base)}.G5W9M8qfo3sGl2OIbwg9{background-color:var(--jp-gray-0);display:flex;flex-direction:row;font-family:Courier\ 10 Pitch,Courier,monospace;overflow-x:scroll;white-space:pre}.Bx4RDCUR316fm_jgGS8N{background-color:var(--jp-gray-10);color:var(--jp-gray-50);display:flex;flex-direction:column;padding:0 var(--spacing-base);text-align:left}.GhN0JvAyRQI3SnVWp2Ot{display:flex;flex-direction:column;flex-grow:1;overflow-x:visible}.GhN0JvAyRQI3SnVWp2Ot del,.GhN0JvAyRQI3SnVWp2Ot div,.GhN0JvAyRQI3SnVWp2Ot ins{padding:0 var(--spacing-base);text-decoration:none}.GhN0JvAyRQI3SnVWp2Ot del{background-color:var(--jp-red-0);color:var(--jp-red-60)}.GhN0JvAyRQI3SnVWp2Ot ins{background-color:var(--jp-green-5);color:var(--jp-green-60)}.xpPHTch5ul0xuZaUoTNa{background-color:var(--jp-gray-0);display:flex;flex-direction:row;font-family:monospace;overflow-x:scroll;padding:0}.AMOpkL9LURkyTK8316cw{background-color:var(--jp-red-0)}.i0_0xMrNWoak1brIaDQq{display:flex;flex-direction:column;text-align:left}.C9fLawPLkMNSZthfwxj6{background-color:var(--jp-gray-10);color:var(--font-body);padding:0 calc(var(--spacing-base)/2)}.C9fLawPLkMNSZthfwxj6.AMOpkL9LURkyTK8316cw{background-color:var(--jp-red-50);color:var(--jp-white)}.ogixgg8fRGekmYGtevh1{display:flex;flex:1;flex-direction:column;overflow-x:visible;white-space:pre}.jYPCgKMDRKfT3vnx0mdG{padding-right:var(--spacing-base)}.UEQ1NqkrwNmaQR7qdEK3{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)}.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;margin-bottom:var(--spacing-base);margin-right:calc(var(--spacing-base)*4)}.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)}@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}}.A6a9HOtaZnLUleNgxQrX{padding:calc(var(--spacing-base)*7) 0}.CGT5fOs6LDTFHWCAgIiT,.RFKxbzQ8N58qEyVO0yzW{align-items:center;display:flex}.RFKxbzQ8N58qEyVO0yzW{height:100%}.RFKxbzQ8N58qEyVO0yzW img{object-fit:cover;width:100%}.SvMuuouOkDt2sE0PAn_D{margin-top:calc(var(--spacing-base)*3 + 1px)}.urouayitSUT8zW0V3p_0{margin-bottom:0}.iXXJlk08gFDeCvsTTlNQ{border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius);border-right:6px solid var(--jp-red-50);box-shadow:0 4px 8px rgba(0,0,0,.03),0 1px 2px rgba(0,0,0,.06);box-sizing:border-box;color:var(--jp-gray-80);font-size:16px;line-height:22px;margin:0;padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3) calc(var(--spacing-base)*2) calc(var(--spacing-base)*3)}.iXXJlk08gFDeCvsTTlNQ.is-error{background-color:var(--jp-white)}.iXXJlk08gFDeCvsTTlNQ .components-notice__content{align-items:flex-start;display:flex;flex-direction:column;margin:0;padding:12px 4px}.iXXJlk08gFDeCvsTTlNQ .is-link{color:var(--jp-black);font-size:16px;font-weight:600}.iXXJlk08gFDeCvsTTlNQ .components-notice__dismiss{align-self:center}.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk,.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk:active,.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk:hover,.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk:visited{align-items:center;background:#000;border-radius:var(--jp-border-radius);color:var(--jp-white);cursor:pointer;font-size:16px;font-weight:600;justify-content:center;letter-spacing:-.01em;line-height:24px;margin-right:calc(var(--spacing-base)*2 + 24px);margin-top:24px;padding:8px 24px;text-decoration:none}.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk,.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk:active,.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk:hover,.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk:visited{margin-right:0;margin-top:0;white-space:nowrap}.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .components-notice__content{align-items:center;flex-direction:row}.e6hHy8BZ7ZKPSXbIC0UG{margin-bottom:25px}.jXz8LnXNzMDdtHqkG0sZ{display:flex;flex-grow:1;margin-left:var(--spacing-base)}.jXz8LnXNzMDdtHqkG0sZ>svg{align-self:flex-start;flex-shrink:0}.jXz8LnXNzMDdtHqkG0sZ .jp-components-spinner,.jXz8LnXNzMDdtHqkG0sZ>svg{margin-left:calc(var(--spacing-base)*2)}*,._fUXxnSp5pagKBp9gSN7 *{box-sizing:border-box} \ 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 4186b8af..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/composer.json +++ /dev/null @@ -1,76 +0,0 @@ -{ - "name": "automattic/jetpack-protect", - "description": "Social plugin", - "type": "wordpress-plugin", - "license": "GPL-2.0-or-later", - "require": { - "ext-json": "*", - "automattic/jetpack-assets": "^1.17.34", - "automattic/jetpack-admin-ui": "^0.2.19", - "automattic/jetpack-autoloader": "^2.11.18", - "automattic/jetpack-composer-plugin": "^1.1.10", - "automattic/jetpack-config": "^1.15.1", - "automattic/jetpack-identity-crisis": "^0.8.40", - "automattic/jetpack-my-jetpack": "^2.9.1", - "automattic/jetpack-plugins-installer": "^0.2.3", - "automattic/jetpack-sync": "^1.47.4", - "automattic/jetpack-transport-helper": "^0.1.4", - "automattic/jetpack-plans": "^0.2.10", - "automattic/jetpack-waf": "^0.11.4", - "automattic/jetpack-status": "^1.17.0" - }, - "require-dev": { - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/wordbless": "0.4.2" - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "test-php": [ - "@composer phpunit" - ], - "build-development": [ - "pnpm run build" - ], - "build-production": [ - "pnpm run build-production-concurrently" - ], - "watch": [ - "Composer\\Config::disableProcessTimeout", - "pnpm run watch" - ], - "post-install-cmd": "WorDBless\\Composer\\InstallDropin::copy", - "post-update-cmd": "WorDBless\\Composer\\InstallDropin::copy" - }, - "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ⓥ1_4_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 9578dffb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack-protect.php +++ /dev/null @@ -1,123 +0,0 @@ - -
        -

        - 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' - ); - ?> -

        -
        - ' . __( '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 9fa97652..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/CHANGELOG.md +++ /dev/null @@ -1,146 +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). - -## [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 - -[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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 b499ae4c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/composer.json +++ /dev/null @@ -1,39 +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": {}, - "require-dev": { - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "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": "1.4.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 73a1fcf8..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', - 'rand' => md5( wp_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 ee74202c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/CHANGELOG.md +++ /dev/null @@ -1,127 +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.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.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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 423f4d69..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/composer.json +++ /dev/null @@ -1,52 +0,0 @@ -{ - "name": "automattic/jetpack-admin-ui", - "description": "Generic Jetpack wp-admin UI elements", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": {}, - "require-dev": { - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/jetpack-logo": "^1.6.1", - "automattic/wordbless": "dev-master" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "test-php": [ - "@composer phpunit" - ], - "post-install-cmd": "WorDBless\\Composer\\InstallDropin::copy", - "post-update-cmd": "WorDBless\\Composer\\InstallDropin::copy" - }, - "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.2.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 319db852..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/src/class-admin-menu.php +++ /dev/null @@ -1,202 +0,0 @@ -get_base64_logo() - : 'dashicons-admin-plugins'; - - if ( ! $jetpack_plugin_present ) { - add_menu_page( - 'Jetpack', - 'Jetpack', - 'read', - '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']; - return $position_a - $position_b; - } - ); - - 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. - * - * @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; - } - - /** - * 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 0072154a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/CHANGELOG.md +++ /dev/null @@ -1,382 +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). - -## [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 - -[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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 1c8becda..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/actions.php +++ /dev/null @@ -1,19 +0,0 @@ - 1, - 'function' => array( Automattic\Jetpack\Assets::class, 'wp_default_scripts_hook' ), - ); -} 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 5488269e..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' => 'e69db286c9c94bd98790'); 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 22d2b90a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/build/i18n-loader.js +++ /dev/null @@ -1 +0,0 @@ -!function(){var e={356:function(e){e.exports=function(e){function n(t){if(r[t])return r[t].exports;var o=r[t]={i:t,l:!1,exports:{}};return e[t].call(o.exports,o,o.exports,n),o.l=!0,o.exports}var r={};return n.m=e,n.c=r,n.i=function(e){return e},n.d=function(e,r,t){n.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:t})},n.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(r,"a",r),r},n.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},n.p="",n(n.s=1)}([function(e,n,r){"use strict";function t(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(e,n){for(var r=0;r>>32-o)+r&4294967295}},{key:"ff",value:function(n,r,t,o,a,i,f){return e.cmn(r&t|~r&o,n,r,a,i,f)}},{key:"gg",value:function(n,r,t,o,a,i,f){return e.cmn(r&o|t&~o,n,r,a,i,f)}},{key:"hh",value:function(n,r,t,o,a,i,f){return e.cmn(r^t^o,n,r,a,i,f)}},{key:"ii",value:function(n,r,t,o,a,i,f){return e.cmn(t^(r|~o),n,r,a,i,f)}},{key:"md51",value:function(n){for(var r=n.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<=r;i+=64)e.md5cycle(t,e.md5blk(n.substring(i-64,i)));for(n=n.substring(i-64),i=0,a=n.length;i>2]|=n.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*r,e.md5cycle(t,o),t}},{key:"md5blk",value:function(e){for(var n=[],r=0;r<64;r+=4)n[r>>2]=e.charCodeAt(r)+(e.charCodeAt(r+1)<<8)+(e.charCodeAt(r+2)<<16)+(e.charCodeAt(r+3)<<24);return n}},{key:"rhex",value:function(n){var r="";return r+=e.hexArray[n>>4&15]+e.hexArray[n>>0&15],r+=e.hexArray[n>>12&15]+e.hexArray[n>>8&15],(r+=e.hexArray[n>>20&15]+e.hexArray[n>>16&15])+(e.hexArray[n>>28&15]+e.hexArray[n>>24&15])}},{key:"hex",value:function(n){for(var r=n.length,t=0;tObject.prototype.hasOwnProperty.call(e,n);e.exports={state:{baseUrl:null,locale:null,domainMap:{},domainPaths:{}},async downloadI18n(e,n,r){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,n)?f.domainPaths[n]:"";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,n)?f.domainMap[n]:a[r]+n,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,n)?d.locale_data[n]:d.locale_data.messages;p[""].domain=n,t.setLocaleData(p,n)}}},736:function(e){"use strict";e.exports=window.wp.i18n}},n={};var r=function r(t){var o=n[t];if(void 0!==o)return o.exports;var a=n[t]={exports:{}};return e[t].call(a.exports,a,a.exports,r),a.exports}(618);(window.wp=window.wp||{}).jpI18nLoader=r}(); \ 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 19fbb26c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/composer.json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "name": "automattic/jetpack-assets", - "description": "Asset management utilities for Jetpack ecosystem packages", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "automattic/jetpack-constants": "^1.6.21" - }, - "require-dev": { - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2", - "wikimedia/testing-access-wrapper": "^1.0 || ^2.0" - }, - "autoload": { - "files": [ - "actions.php" - ], - "classmap": [ - "src/" - ] - }, - "scripts": { - "build-development": [ - "pnpm run build" - ], - "build-production": [ - "pnpm run build-production" - ], - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "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": "1.17.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 f78f3635..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/src/class-assets.php +++ /dev/null @@ -1,738 +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(); - self::$instance->init_hooks(); - } - - return self::$instance; - } - - /** - * Initalize the hooks as needed. - */ - private function init_hooks() { - /* - * Load some scripts asynchronously. - */ - add_filter( 'script_loader_tag', array( $this, 'script_add_async' ), 10, 2 ); - } - - /** - * A public method for adding the async script. - * - * @param string $script_handle Script handle. - */ - public function add_async_script( $script_handle ) { - $this->defer_script_handles[] = $script_handle; - } - - /** - * Add an async attribute to scripts that can be loaded deferred. - * https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script - * - * @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 76e360c8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-error-handler.php +++ /dev/null @@ -1,730 +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', - ); - - /** - * 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' ) ); - - $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_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': - 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. - if ( count( $stored_errors[ $error_code ] ) > 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'] ) || empty( $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 ) { - $parsed_token = explode( ':', wp_unslash( $token ) ); - - if ( isset( $parsed_token[2] ) && ctype_digit( $parsed_token[2] ) ) { - $user_id = $parsed_token[2]; - } else { - $user_id = 'invalid'; - } - - 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 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 emtpy 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; - } - - ?> - - '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 83785d37..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-heartbeat.php +++ /dev/null @@ -1,253 +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' ) ); - } - } - - /** - * 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 ) ); - } - } - -} 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 88d03c5b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-initial-state.php +++ /dev/null @@ -1,58 +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' => ( new Status() )->get_site_suffix(), - 'connectionErrors' => Error_Handler::get_instance()->get_verified_errors(), - ); - } - - /** - * Render the initial state into a JavaScript variable. - * - * @return string - */ - public static function render() { - if ( self::$rendered ) { - return null; - } - self::$rendered = true; - return 'var JP_CONNECTION_INITIAL_STATE=JSON.parse(decodeURIComponent("' . rawurlencode( wp_json_encode( self::get_data() ) ) . '"));'; - } - -} 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 9254dc43..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-manager.php +++ /dev/null @@ -1,2512 +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( - $_GET, // phpcs:ignore WordPress.Security.NonceVerification.Recommended - $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' ) ); - } - - add_action( 'rest_api_init', array( $manager, 'initialize_rest_api_registration_connector' ) ); - - ( 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 ); - - // 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(); - } - - /** - * Sets up the XMLRPC request handlers. - * - * @since 1.25.0 Deprecate $is_active param. - * - * @param array $request_params incoming request parameters. - * @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( - $request_params, - $has_connected_owner, - $is_signed, - \Jetpack_XMLRPC_Server $xmlrpc_server = null - ) { - add_filter( 'xmlrpc_blog_options', array( $this, 'xmlrpc_options' ), 1000, 2 ); - - if ( - ! isset( $request_params['for'] ) - || 'jetpack' !== $request_params['for'] - ) { - return false; - } - - // Alternate XML-RPC, via ?for=jetpack&jetpack=comms. - if ( - isset( $request_params['jetpack'] ) - && 'comms' === $request_params['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. - @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. - */ - 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; - } - - /** - * 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 ( 0 === strpos( $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 - if ( isset( $_POST['_jetpack_is_multipart'] ) ) { - $post_data = $_POST; - $file_hashes = array(); - foreach ( $post_data as $post_data_key => $post_data_value ) { - if ( 0 !== strpos( $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() { - $has_blog_id = (bool) \Jetpack_Options::get_option( 'id' ); - $has_blog_token = (bool) $this->get_tokens()->get_access_token(); - return $has_blog_id && $has_blog_token; - } - - /** - * 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 ); - } - - 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(); - } - - /** - * 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; - } - - // 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' ); - } - } - } - - 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' ) { - 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'] = $this->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 ); - - $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; - } - 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; - } - - $earliest_registered_users = get_users( - array( - 'role' => 'administrator', - 'orderby' => 'user_registered', - 'order' => 'ASC', - 'fields' => array( '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; - } - - /** - * 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 ); - $this->delete_all_connection_tokens( 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. - * - * @param WP_User $user (optional) defaults to the current logged in user. - * @param String $redirect (optional) a redirect URL to use instead of the default. - * @return string Connect URL. - */ - public function get_authorization_url( $user = null, $redirect = null ) { - 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(), - ) - ); - - $body = $this->apply_activation_source_to_args( urlencode_deep( $body ) ); - - $api_url = $this->api_url( 'authorize' ); - - return add_query_arg( $body, $api_url ); - } - - /** - * 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(); - - /** - * Fires when 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', - '127.0.0.1', - '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; - } - - 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 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. - * - * @return int|WP_Error - */ - public static function get_site_id() { - $is_wpcom = ( defined( 'IS_WPCOM' ) && IS_WPCOM ); - $site_id = $is_wpcom ? get_current_blog_id() : \Jetpack_Options::get_option( 'id' ); - if ( ! $site_id ) { - return new \WP_Error( - 'unavailable_site_id', - __( 'Sorry, something is wrong with your Jetpack connection.', 'jetpack-connection' ), - 403 - ); - } - return (int) $site_id; - } -} 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 a3bfaed2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-nonce-handler.php +++ /dev/null @@ -1,213 +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 ( ! count( $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 7d77c808..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-package-version-tracker.php +++ /dev/null @@ -1,112 +0,0 @@ - $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: - * - 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_option( $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 ); - } - } - -} 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 2b746816..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 @@ -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 10b5c7b9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-plugin.php +++ /dev/null @@ -1,122 +0,0 @@ -slug = $slug; - } - - /** - * 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 ) ); - } - - /** - * Add the plugin to the set of disconnected ones. - * - * @deprecated since 1.39.0. - * - * @return bool - */ - public function disable() { - return true; - } - - /** - * Remove the plugin from the set of disconnected ones. - * - * @deprecated since 1.39.0. - * - * @return bool - */ - public function enable() { - return true; - } - - /** - * Whether this plugin is allowed to use the connection. - * - * @deprecated since 11.0 - * @return bool - */ - public function is_enabled() { - return true; - } -} 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 c5a89f53..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-rest-authentication.php +++ /dev/null @@ -1,220 +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; - } -} 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 9c0a2246..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-rest-connector.php +++ /dev/null @@ -1,850 +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', - ) - ); - - // 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, - ), - ), - ) - ); - - // 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', - ), - 'registration_nonce' => array( - 'description' => __( 'The registration nonce', 'jetpack-connection' ), - 'type' => 'string', - 'required' => true, - ), - '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', - ), - ), - ) - ); - - 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; - } - - /** - * 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->is_staging_site(), - '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 - * - * @return bool|WP_Error True if user is able to disconnect the site. - */ - public static function disconnect_site_permission_check() { - if ( current_user_can( 'jetpack_disconnect' ) ) { - return true; - } - - return new WP_Error( - 'invalid_user_permission_jetpack_disconnect', - 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, 64, 'mm', '', array( 'force_display' => true ) ), - 'permissions' => array( - 'connect' => current_user_can( 'jetpack_connect' ), - 'connect_user' => current_user_can( 'jetpack_connect_user' ), - 'disconnect' => current_user_can( 'jetpack_disconnect' ), - ), - ); - - /** - * 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, - ); - - 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'], $_GET['timestamp'], $_GET['url'], $_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 partially or fully reconnect the website to WP.com. - * - * @since 1.7.0 - * @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 ( ! wp_verify_nonce( $request->get_param( 'registration_nonce' ), 'jetpack-registration-nonce' ) ) { - return new WP_Error( 'invalid_nonce', __( 'Unable to verify your request.', 'jetpack-connection' ), array( 'status' => 403 ) ); - } - - 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; - - if ( class_exists( 'Jetpack' ) ) { - $authorize_url = \Jetpack::build_authorize_url( $redirect_uri ); - } else { - $authorize_url = $this->connection->get_authorization_url( null, $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 ) - ); - } - - /** - * 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() ) ); - } -} 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 1d41c4e4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-secrets.php +++ /dev/null @@ -1,281 +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 ); - - $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 711480bb..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 c94d4fb5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-terms-of-service.php +++ /dev/null @@ -1,112 +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.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-tokens.php deleted file mode 100644 index 98a01d9b..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 = join( - "\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 join( ' ', $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 1ff9f06c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-tracking.php +++ /dev/null @@ -1,318 +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' ), - ); - - $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 && $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 ); - update_user_meta( $user_id, 'jetpack_tracks_wpcom_id', $wpcom_user_data['ID'] ); - - return array( - '_ut' => 'wpcom:user_id', - '_ui' => $wpcom_user_data['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 2b1b149d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-urls.php +++ /dev/null @@ -1,187 +0,0 @@ -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'], - ) - ); - } -} 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 8d57421b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-webhooks.php +++ /dev/null @@ -1,211 +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; - case 'authorize_redirect': - $this->handle_authorize_redirect(); - $this->do_exit(); - break; - // 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 ); - $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. - */ - protected function do_exit() { - exit; - } - - /** - * 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 { - $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 f27090c9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-async-call.php +++ /dev/null @@ -1,105 +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 ) ); - } - - 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, true ); - - 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 c3d786d8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-connector.php +++ /dev/null @@ -1,83 +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/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 @@ -connection = $connection; - } - - /** - * Handle the webhook - * - * This method implements what's in Jetpack::admin_page_load when the Jetpack plugin is not present - */ - 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; - } - - // 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; - } 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; - } - - $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; - } - - /** - * Create the Jetpack authorization URL. Copied from Jetpack class. - * - * @param bool|string $redirect URL to redirect to. - * - * @todo Update default value for redirect since the called function expects a string. - * - * @return mixed|void - */ - public function build_authorize_url( $redirect = false ) { - - 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 ); - - remove_filter( 'jetpack_connect_request_body', array( __CLASS__, 'filter_connect_request_body' ) ); - remove_filter( 'jetpack_connect_redirect_url', array( __CLASS__, 'filter_connect_redirect_url' ) ); - - /** - * This filter is documented in plugins/jetpack/class-jetpack.php - */ - return apply_filters( 'jetpack_build_authorize_url', $url ); - } - - /** - * Filters the redirection URL that is used for connect requests. The redirect - * URL should return the user back to the Jetpack console. - * Copied from Jetpack class. - * - * @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=jetpack' ) ); - $redirect = $redirect - ? wp_validate_redirect( esc_url_raw( $redirect ), $jetpack_admin_page ) - : $jetpack_admin_page; - - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( isset( $_REQUEST['is_multisite'] ) ) { - $redirect = Jetpack_Network::init()->get_url( 'network_admin_page' ); - } - - return $redirect; - } - - /** - * Filters the connection URL parameter array. - * Copied from Jetpack class. - * - * @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 = self::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. - * - * @since 1.37.1 - * - * @return string Calypso environment - */ - public static function get_calypso_env() { - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( isset( $_GET['calypso_env'] ) ) { - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - return sanitize_key( $_GET['calypso_env'] ); - } - - if ( getenv( 'CALYPSO_ENV' ) ) { - return sanitize_key( getenv( 'CALYPSO_ENV' ) ); - } - - if ( defined( 'CALYPSO_ENV' ) && CALYPSO_ENV ) { - return sanitize_key( CALYPSO_ENV ); - } - - return ''; - } -} 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 0320469d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/CHANGELOG.md +++ /dev/null @@ -1,184 +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). - -## [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 - -[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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 7bc57adf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/composer.json +++ /dev/null @@ -1,40 +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": {}, - "require-dev": { - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "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": "1.6.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 eaad50be..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 @@ - -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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 7a806dca..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/composer.json +++ /dev/null @@ -1,39 +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": {}, - "require-dev": { - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "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": "1.4.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 684e568c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/src/class-device-detection.php +++ /dev/null @@ -1,219 +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 = '' ) { - $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(), - ); - - $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 ); - } - 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 d7a99de8..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,1568 +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 ( $this->is_chrome_for_iOS() ) { // Keep this check before the safari rule. - return 'chrome-for-ios'; - } elseif ( $this->is_iphone_or_ipod( 'iphone-safari' ) ) { - return 'iphone'; - } elseif ( $this->is_ipad( 'ipad-safari' ) ) { - return 'ipad'; - } elseif ( $this->is_android_tablet() ) { // Keep this check before the android rule. - return 'android_tablet'; - } elseif ( $this->is_android() ) { - return 'android'; - } elseif ( $this->is_blackberry_10() ) { - return 'blackberry_10'; - } elseif ( $this->is_blackbeberry() ) { - return 'blackberry'; - } elseif ( $this->is_WindowsPhone7() ) { - return 'win7'; - } elseif ( $this->is_windows_phone_8() ) { - return 'winphone8'; - } elseif ( $this->is_opera_mini() ) { - return 'opera-mini'; - } elseif ( $this->is_opera_mini_dumb() ) { - return 'opera-mini-dumb'; - } elseif ( $this->is_opera_mobile() ) { - return 'opera-mobi'; - } elseif ( $this->is_blackberry_tablet() ) { - return 'blackberry_tablet'; - } elseif ( $this->is_kindle_fire() ) { - return 'kindle-fire'; - } elseif ( $this->is_PalmWebOS() ) { - return 'webos'; - } elseif ( $this->is_S60_OSSBrowser() ) { - return 'series60'; - } elseif ( $this->is_firefox_os() ) { - return 'firefoxOS'; - } elseif ( $this->is_firefox_mobile() ) { - return 'firefox_mobile'; - } elseif ( $this->is_MaemoTablet() ) { - return 'maemo'; - } elseif ( $this->is_MeeGo() ) { - return 'meego'; - } elseif ( $this->is_TouchPad() ) { - return 'hp_tablet'; - } elseif ( $this->is_facebook_for_iphone() ) { - return 'facebook-for-iphone'; - } elseif ( $this->is_facebook_for_ipad() ) { - return 'facebook-for-ipad'; - } elseif ( $this->is_twitter_for_iphone() ) { - return 'twitter-for-iphone'; - } elseif ( $this->is_twitter_for_ipad() ) { - return 'twitter-for-ipad'; - } elseif ( $this->is_wordpress_for_ios() ) { - return 'ios-app'; - } elseif ( $this->is_iphone_or_ipod( 'iphone-not-safari' ) ) { - return 'iphone-unknown'; - } elseif ( $this->is_ipad( 'ipad-not-safari' ) ) { - return 'ipad-unknown'; - } elseif ( $this->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 Name of the platform, false otherwise. - */ - public function get_platform() { - if ( isset( $this->platform ) ) { - return $this->platform; - } - - 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 ( $this->is_android_tablet() ) { - $this->platform = self::PLATFORM_ANDROID_TABLET; - } else { - $this->platform = self::PLATFORM_ANDROID; - } - } elseif ( $this->is_kindle_fire() ) { - $this->platform = self::PLATFORM_ANDROID_TABLET; - } elseif ( $this->is_blackberry_10() ) { - $this->platform = self::PLATFORM_BLACKBERRY_10; - } elseif ( strpos( $this->useragent, 'blackberry' ) !== false ) { - $this->platform = self::PLATFORM_BLACKBERRY; - } elseif ( $this->is_blackberry_tablet() ) { - $this->platform = self::PLATFORM_BLACKBERRY; - } elseif ( $this->is_symbian_platform() ) { - $this->platform = self::PLATFORM_SYMBIAN; - } elseif ( $this->is_symbian_s40_platform() ) { - $this->platform = self::PLATFORM_SYMBIAN_S40; - } elseif ( $this->is_J2ME_platform() ) { - $this->platform = self::PLATFORM_J2ME_MIDP; - } elseif ( $this->is_firefox_os() ) { - $this->platform = self::PLATFORM_FIREFOX_OS; - } else { - $this->platform = false; - } - - return $this->platform; - } - - /** - * 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 ( $this->is_android() ) { - $this->matched_agent = 'android'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( $this->is_windows_phone_8() ) { - $this->matched_agent = 'winphone8'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( $this->is_WindowsPhone7() ) { - $this->matched_agent = 'win7'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( $this->is_blackberry_10() ) { - $this->matched_agent = 'blackberry-10'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( $this->is_blackbeberry() && 'blackberry-webkit' === $this->detect_blackberry_browser_version() ) { - $this->matched_agent = 'blackberry-webkit'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( $this->is_blackberry_tablet() ) { - $this->matched_agent = 'blackberry_tablet'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( $this->is_PalmWebOS() ) { - $this->matched_agent = 'webos'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( $this->is_TouchPad() ) { - $this->matched_agent = 'hp_tablet'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( $this->is_firefox_os() ) { - $this->matched_agent = 'firefoxOS'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( $this->is_firefox_mobile() ) { - $this->matched_agent = 'fennec'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( $this->is_opera_mobile() ) { - $this->matched_agent = 'opera-mobi'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( $this->is_MaemoTablet() ) { - $this->matched_agent = 'maemo'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( $this->is_MeeGo() ) { - $this->matched_agent = 'meego'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( $this->is_kindle_touch() ) { - $this->matched_agent = 'kindle-touch'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( $this->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 ( $this->is_S60_OSSBrowser() ) { - $this->matched_agent = 'series60'; - $this->isTierIphone = false; - $this->isTierRichCss = true; - $this->isTierGenericMobile = false; - } elseif ( $this->is_opera_mini() ) { - $this->matched_agent = 'opera-mini'; - $this->isTierIphone = false; - $this->isTierRichCss = true; - $this->isTierGenericMobile = false; - } elseif ( $this->is_blackbeberry() ) { - $detectedDevice = $this->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 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 ); - } - - /** - * 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', - ); - - 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-identity-crisis/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/SECURITY.md deleted file mode 100644 index b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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-identity-crisis/build/index.asset.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/build/index.asset.php deleted file mode 100644 index 2e8c7097..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/build/index.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('react', 'wp-components', 'wp-compose', 'wp-data', 'wp-element', 'wp-i18n', 'wp-polyfill', 'wp-url'), 'version' => 'fb59dccf666add58f6fb'); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/build/index.css b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/build/index.css deleted file mode 100644 index 1d966e8d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/build/index.css +++ /dev/null @@ -1 +0,0 @@ -#wpadminbar #wp-admin-bar-jetpack-idc{margin-right:5px}#wpadminbar #wp-admin-bar-jetpack-idc .jp-idc-admin-bar{border-radius:2px;color:#efeff0;font-size:14px;font-weight:500;line-height:20px;padding:6px 8px}#wpadminbar #wp-admin-bar-jetpack-idc.hide{display:none}#wpadminbar #wp-admin-bar-jetpack-idc .dashicons{font-family:dashicons;margin-top:-6px}#wpadminbar #wp-admin-bar-jetpack-idc .dashicons:before{font-size:18px}#wpadminbar #wp-admin-bar-jetpack-idc .ab-item{background:#e68b28;padding:0}#jp-identity-crisis-container .jp-idc__idc-screen{margin-bottom:40px;margin-top:40px}#jp-identity-crisis-container.notice{background:none;border:none}.jp-idc__idc-screen{background:#fff;border-left:4px solid #e68b28;border-radius:4px;box-shadow:0 0 40px rgba(0,0,0,.04);box-sizing:border-box;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;margin:0 auto;max-width:1128px;padding:10px}.jp-idc__idc-screen.jp-idc__idc-screen__success{border-color:#069e08}@media(min-width:600px){.jp-idc__idc-screen{padding:48px}}.jp-idc__idc-screen .jp-idc__idc-screen__header{align-items:center;display:flex}.jp-idc__idc-screen .jp-idc__idc-screen__header .jp-idc__idc-screen__logo-image{max-height:100px;max-width:100px}.jp-idc__idc-screen .jp-idc__idc-screen__header .jp-idc__idc-screen__logo-label{font-size:14px;line-height:22px;margin:-7px 0 0 8px}.jp-idc__idc-screen h2{font-size:24px;font-weight:600;line-height:28px;margin:32px 0 0}.jp-idc__idc-screen h3{font-size:20px;font-weight:600;line-height:28px;margin:24px 0 0}.jp-idc__idc-screen p{color:#2c3338;font-size:16px;line-height:24px;margin:16px 0 0;max-width:710px}.jp-idc__idc-screen a{color:#2c3338}.jp-idc__idc-screen .jp-idc__idc-screen__cards{align-items:center;display:flex;flex-direction:column;flex-wrap:wrap}@media only screen and (min-width:1403px){.jp-idc__idc-screen .jp-idc__idc-screen__cards{align-items:normal;flex-direction:row}}.jp-idc__idc-screen .jp-idc__idc-screen__cards .jp-idc__idc-screen__cards-separator{align-self:center;color:#23282d;font-size:20px;font-weight:600;line-height:28px;margin:0 24px}.jp-idc__idc-screen .jp-idc__idc-screen__cards .jp-idc__idc-screen__card-action-base{border:1px solid #c3c4c7;border-radius:4px;box-sizing:border-box;display:flex;flex-direction:column;justify-content:space-between;margin:24px 0;max-width:100%;padding:10px;width:480px}@media(min-width:600px){.jp-idc__idc-screen .jp-idc__idc-screen__cards .jp-idc__idc-screen__card-action-base{padding:24px}}.jp-idc__idc-screen .jp-idc__idc-screen__cards .jp-idc__idc-screen__card-action-base h4{font-size:20px;font-weight:400;line-height:28px;margin:0 0 8px}.jp-idc__idc-screen .jp-idc__idc-screen__cards .jp-idc__idc-screen__card-action-base p{margin:0 0 24px}.jp-idc__idc-screen .jp-idc__idc-screen__cards .jp-idc__idc-screen__card-action-base .jp-idc__idc-screen__card-action-sitename{background:#f9f9f6;border-radius:33px;box-sizing:border-box;color:#2c3338;font-size:16px;font-weight:700;line-height:24px;overflow-wrap:anywhere;padding:16px;text-align:center;width:100%}.jp-idc__idc-screen .jp-idc__idc-screen__cards .jp-idc__idc-screen__card-action-base .jp-idc__idc-screen__card-action-separator{display:block;margin:12px auto}.jp-idc__idc-screen .jp-idc__idc-screen__cards .jp-idc__idc-screen__card-action-base .jp-idc__idc-screen__card-action-button{padding:8px 24px;width:100%}.jp-idc__idc-screen .jp-idc__idc-screen__card-action-button{background:#000;border-radius:4px;color:#fff;font-size:16px;font-weight:600;height:auto;justify-content:center;line-height:24px;margin-top:24px;min-height:40px;padding:8px}.jp-idc__idc-screen .jp-idc__idc-screen__card-action-button-migrated{margin-top:64px;width:141px}.jp-idc__idc-screen .jp-idc__idc-screen__card-migrated{align-items:center;display:flex;flex-direction:column;flex-wrap:wrap;margin-top:24px;width:100%}.jp-idc__idc-screen .jp-idc__idc-screen__card-migrated .jp-idc__idc-screen__card-migrated-hostname{border:1px solid #c3c4c7;border-radius:4px;color:#2c3338;flex-grow:1;font-size:16px;font-weight:700;line-height:24px;padding:24px;width:100%}.jp-idc__idc-screen .jp-idc__idc-screen__card-migrated .jp-idc__idc-screen__card-migrated-separator-wide{display:none}.jp-idc__idc-screen .jp-idc__idc-screen__card-migrated .jp-idc__idc-screen__card-migrated-separator{display:block}.jp-idc__idc-screen .jp-idc__idc-screen__card-migrated .jp-idc__idc-screen__card-migrated-separator,.jp-idc__idc-screen .jp-idc__idc-screen__card-migrated .jp-idc__idc-screen__card-migrated-separator-wide{margin:28px}@media only screen and (min-width:1400px){.jp-idc__idc-screen .jp-idc__idc-screen__card-migrated{flex-direction:row;width:auto}.jp-idc__idc-screen .jp-idc__idc-screen__card-migrated .jp-idc__idc-screen__card-migrated-separator{display:none}.jp-idc__idc-screen .jp-idc__idc-screen__card-migrated .jp-idc__idc-screen__card-migrated-separator-wide{display:block}.jp-idc__idc-screen .jp-idc__idc-screen__card-migrated .jp-idc__idc-screen__card-migrated-hostname{width:auto}}@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%}: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-10:#f2cf75;--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-menu-border-height:1px;--jp-underline-thickness:2px}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{grid-gap:24px;display:grid;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}.jp-idc__idc-screen .jp-idc__error-message{align-items:center;color:var(--jp-red);display:flex;flex-direction:row;justify-content:center;margin:15px 0}.jp-idc__idc-screen .jp-idc__error-message .error-gridicon{fill:var(--jp-red);margin-right:8px}.jp-idc__idc-screen .jp-idc__error-message a,.jp-idc__idc-screen .jp-idc__error-message span{color:var(--jp-red);font-size:var(--font-body)}.jp-idc__idc-screen .jp-idc__safe-mode .jp-idc__error-message{margin-top:5px}.jp-idc__idc-screen .jp-idc__idc-screen__cards.jp-idc__idc-screen__cards-error .jp-idc__idc-screen__card-action-base{padding-bottom:75px}.jp-idc__idc-screen .jp-idc__idc-screen__cards.jp-idc__idc-screen__cards-error .jp-idc__idc-screen__card-action-base.jp-idc__idc-screen__card-action-error{padding-bottom:5px}.jp-idc__idc-screen .jp-idc__idc-screen__cards.jp-idc__idc-screen__cards-error .jp-idc__idc-screen__card-action-base .jp-idc__error-message{height:40px}.jp-idc__idc-screen .jp-idc__safe-mode{text-align:center}.jp-idc__idc-screen .jp-idc__safe-mode .jp-idc__safe-mode__staying-safe{display:flex;justify-content:center;padding:6px}.jp-idc__idc-screen .jp-idc__safe-mode .jp-idc__safe-mode__staying-safe .jp-components-spinner{margin:0 10px}.jp-idc__idc-screen .jp-idc__safe-mode,.jp-idc__idc-screen .jp-idc__safe-mode button{color:#2c3338;font-size:16px;line-height:24px}.jp-idc__idc-screen .jp-idc__safe-mode button{padding:0;text-decoration:underline} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/build/index.js b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/build/index.js deleted file mode 100644 index 7d3b8547..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/build/index.js +++ /dev/null @@ -1,5 +0,0 @@ -/*! For license information please see index.js.LICENSE.txt */ -!function(){var e={5235:function(e,t){var n;!function(){"use strict";var r={}.hasOwnProperty;function s(){for(var e=[],t=0;t{"%%"!==e&&(r++,"%c"===e&&(s=r))})),t.splice(s,0,n)},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;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&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$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=n(1741)(t);const{formatters:r}=e.exports;r.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},1741:function(e,t,n){e.exports=function(e){function t(e){let n,s,i,o=null;function a(...e){if(!a.enabled)return;const r=a,s=Number(new Date),i=s-(n||s);r.diff=i,r.prev=n,r.curr=s,n=s,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let o=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((n,s)=>{if("%%"===n)return"%";o++;const i=t.formatters[s];if("function"==typeof i){const t=e[o];n=i.call(r,t),e.splice(o,1),o--}return n})),t.formatArgs.call(r,e);(r.log||t.log).apply(r,e)}return a.namespace=e,a.useColors=t.useColors(),a.color=t.selectColor(e),a.extend=r,a.destroy=t.destroy,Object.defineProperty(a,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==o?o:(s!==t.namespaces&&(s=t.namespaces,i=t.enabled(e)),i),set:e=>{o=e}}),"function"==typeof t.init&&t.init(a),a}function r(e,n){const r=t(this.namespace+(void 0===n?":":n)+e);return r.log=this.log,r}function s(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return t.debug=t,t.default=t,t.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},t.disable=function(){const e=[...t.names.map(s),...t.skips.map(s).map((e=>"-"+e))].join(",");return t.enable(""),e},t.enable=function(e){let n;t.save(e),t.namespaces=e,t.names=[],t.skips=[];const r=("string"==typeof e?e:"").split(/[\s,]+/),s=r.length;for(n=0;n{t[n]=e[n]})),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let n=0;for(let t=0;t=1.5*n;return Math.round(e/n)+" "+r+(s?"s":"")}e.exports=function(e,c){c=c||{};var l=typeof e;if("string"===l&&e.length>0)return function(e){if((e=String(e)).length>100)return;var a=/^(-?(?:\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(!a)return;var c=parseFloat(a[1]);switch((a[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return c*o;case"weeks":case"week":case"w":return c*i;case"days":case"day":case"d":return c*s;case"hours":case"hour":case"hrs":case"hr":case"h":return c*r;case"minutes":case"minute":case"mins":case"min":case"m":return c*n;case"seconds":case"second":case"secs":case"sec":case"s":return c*t;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return c;default:return}}(e);if("number"===l&&isFinite(e))return c.long?function(e){var i=Math.abs(e);if(i>=s)return a(e,i,s,"day");if(i>=r)return a(e,i,r,"hour");if(i>=n)return a(e,i,n,"minute");if(i>=t)return a(e,i,t,"second");return e+" ms"}(e):function(e){var i=Math.abs(e);if(i>=s)return Math.round(e/s)+"d";if(i>=r)return Math.round(e/r)+"h";if(i>=n)return Math.round(e/n)+"m";if(i>=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))}},469:function(e,t,n){"use strict";var r=n(758);function s(){}function i(){}i.resetWarningCache=s,e.exports=function(){function e(e,t,n,s,i,o){if(o!==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:s};return n.PropTypes=n,n}},5162:function(e,t,n){e.exports=n(469)()},758:function(e){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},6975:function(e,t,n){"use strict";var r=n(951);const s=n.n(r)()("dops:analytics");let i,o;window._tkq=window._tkq||[],window.ga=window.ga||function(){(window.ga.q=window.ga.q||[]).push(arguments)},window.ga.l=+new Date;const a={initialize:function(e,t,n){a.setUser(e,t),a.setSuperProps(n),a.identifyUser()},setGoogleAnalyticsEnabled:function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;this.googleAnalyticsEnabled=e,this.googleAnalyticsKey=t},setMcAnalyticsEnabled:function(e){this.mcAnalyticsEnabled=e},setUser:function(e,t){o={ID:e,username:t}},setSuperProps:function(e){i=e},assignSuperProps:function(e){i=Object.assign(i||{},e)},mc:{bumpStat:function(e,t){const n=function(e,t){let n="";if("object"==typeof e){for(const t in e)n+="&x_"+encodeURIComponent(t)+"="+encodeURIComponent(e[t]);s("Bumping stats %o",e)}else n="&x_"+encodeURIComponent(e)+"="+encodeURIComponent(t),s('Bumping stat "%s" in group "%s"',t,e);return n}(e,t);a.mcAnalyticsEnabled&&((new Image).src=document.location.protocol+"//pixel.wp.com/g.gif?v=wpcom-no-pv"+n+"&t="+Math.random())},bumpStatWithPageView:function(e,t){const n=function(e,t){let n="";if("object"==typeof e){for(const t in e)n+="&"+encodeURIComponent(t)+"="+encodeURIComponent(e[t]);s("Built stats %o",e)}else n="&"+encodeURIComponent(e)+"="+encodeURIComponent(t),s('Built stat "%s" in group "%s"',t,e);return n}(e,t);a.mcAnalyticsEnabled&&((new Image).src=document.location.protocol+"//pixel.wp.com/g.gif?v=wpcom"+n+"&t="+Math.random())}},pageView:{record:function(e,t){a.tracks.recordPageView(e),a.ga.recordPageView(e,t)}},purchase:{record:function(e,t,n,r,s,i,o){a.ga.recordPurchase(e,t,n,r,s,i,o)}},tracks:{recordEvent:function(e,t){t=t||{},0===e.indexOf("akismet_")||0===e.indexOf("jetpack_")?(i&&(s("- Super Props: %o",i),t=Object.assign(t,i)),s('Record event "%s" called with props %s',e,JSON.stringify(t)),window._tkq.push(["recordEvent",e,t])):s('- Event name must be prefixed by "akismet_" or "jetpack_"')},recordJetpackClick:function(e){const t="object"==typeof e?e:{target:e};a.tracks.recordEvent("jetpack_wpa_click",t)},recordPageView:function(e){a.tracks.recordEvent("akismet_page_view",{path:e})},setOptOut:function(e){s("Pushing setOptOut: %o",e),window._tkq.push(["setOptOut",e])}},ga:{initialized:!1,initialize:function(){let e={};a.ga.initialized||(o&&(e={userId:"u-"+o.ID}),window.ga("create",this.googleAnalyticsKey,"auto",e),a.ga.initialized=!0)},recordPageView:function(e,t){a.ga.initialize(),s("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,n,r){a.ga.initialize();let i="Recording Event ~ [Category: "+e+"] [Action: "+t+"]";void 0!==n&&(i+=" [Option Label: "+n+"]"),void 0!==r&&(i+=" [Option Value: "+r+"]"),s(i),this.googleAnalyticsEnabled&&window.ga("send","event",e,t,n,r)},recordPurchase:function(e,t,n,r,s,i,o){window.ga("require","ecommerce"),window.ga("ecommerce:addTransaction",{id:e,revenue:r,currency:o}),window.ga("ecommerce:addItem",{id:e,name:t,sku:n,price:s,quantity:i}),window.ga("ecommerce:send")}},identifyUser:function(){o&&window._tkq.push(["identifyUser",o.ID,o.username])},setProperties:function(e){window._tkq.push(["setProperties",e])},clearedIdentity:function(){window._tkq.push(["clearIdentity"])}};t.Z=a},4743:function(e,t,n){"use strict";var r=n(1132),s=n(6483);function i(e){class t extends Error{constructor(){super(...arguments),this.name=e}}return t}const o=i("JsonParseError"),a=i("JsonParseAfterRedirectError"),c=i("Api404Error"),l=i("Api404AfterRedirectError"),u=i("FetchNetworkError");const d=new function(e,t){let n=e,i=e,o={"X-WP-Nonce":t},a={credentials:"same-origin",headers:o},c={method:"post",credentials:"same-origin",headers:Object.assign({},o,{"Content-type":"application/json"})},l=function(e){const t=e.split("?"),n=t.length>1?t[1]:"",r=n.length?n.split("&"):[];return r.push("_cacheBuster="+(new Date).getTime()),t[0]+"?"+r.join("&")};const u={setApiRoot(e){n=e},setWpcomOriginApiUrl(e){i=e},setApiNonce(e){o={"X-WP-Nonce":e},a={credentials:"same-origin",headers:o},c={method:"post",credentials:"same-origin",headers:Object.assign({},o,{"Content-type":"application/json"})}},setCacheBusterCallback:e=>{l=e},registerSite:(e,t)=>{const s={registration_nonce:e,no_iframe:!0};return(0,r.jetpackConfigHas)("consumer_slug")&&(s.plugin_slug=(0,r.jetpackConfigGet)("consumer_slug")),null!==t&&(s.redirect_uri=t),h(`${n}jetpack/v4/connection/register`,c,{body:JSON.stringify(s)}).then(p).then(m)},fetchAuthorizationUrl:e=>d((0,s.addQueryArgs)(`${n}jetpack/v4/connection/authorize_url`,{no_iframe:"1",redirect_uri:e}),a).then(p).then(m),fetchSiteConnectionData:()=>d(`${n}jetpack/v4/connection/data`,a).then(m),fetchSiteConnectionStatus:()=>d(`${n}jetpack/v4/connection`,a).then(m),fetchSiteConnectionTest:()=>d(`${n}jetpack/v4/connection/test`,a).then(p).then(m),fetchUserConnectionData:()=>d(`${n}jetpack/v4/connection/data`,a).then(m),fetchUserTrackingSettings:()=>d(`${n}jetpack/v4/tracking/settings`,a).then(p).then(m),updateUserTrackingSettings:e=>h(`${n}jetpack/v4/tracking/settings`,c,{body:JSON.stringify(e)}).then(p).then(m),disconnectSite:()=>h(`${n}jetpack/v4/connection`,c,{body:JSON.stringify({isActive:!1})}).then(p).then(m),fetchConnectUrl:()=>d(`${n}jetpack/v4/connection/url`,a).then(p).then(m),unlinkUser:()=>h(`${n}jetpack/v4/connection/user`,c,{body:JSON.stringify({linked:!1})}).then(p).then(m),reconnect:()=>h(`${n}jetpack/v4/connection/reconnect`,c).then(p).then(m),fetchConnectedPlugins:()=>d(`${n}jetpack/v4/connection/plugins`,a).then(p).then(m),setHasSeenWCConnectionModal:()=>h(`${n}jetpack/v4/seen-wc-connection-modal`,c).then(p).then(m),fetchModules:()=>d(`${n}jetpack/v4/module/all`,a).then(p).then(m),fetchModule:e=>d(`${n}jetpack/v4/module/${e}`,a).then(p).then(m),activateModule:e=>h(`${n}jetpack/v4/module/${e}/active`,c,{body:JSON.stringify({active:!0})}).then(p).then(m),deactivateModule:e=>h(`${n}jetpack/v4/module/${e}/active`,c,{body:JSON.stringify({active:!1})}),updateModuleOptions:(e,t)=>h(`${n}jetpack/v4/module/${e}`,c,{body:JSON.stringify(t)}).then(p).then(m),updateSettings:e=>h(`${n}jetpack/v4/settings`,c,{body:JSON.stringify(e)}).then(p).then(m),getProtectCount:()=>d(`${n}jetpack/v4/module/protect/data`,a).then(p).then(m),resetOptions:e=>h(`${n}jetpack/v4/options/${e}`,c,{body:JSON.stringify({reset:!0})}).then(p).then(m),activateVaultPress:()=>h(`${n}jetpack/v4/plugins`,c,{body:JSON.stringify({slug:"vaultpress",status:"active"})}).then(p).then(m),getVaultPressData:()=>d(`${n}jetpack/v4/module/vaultpress/data`,a).then(p).then(m),installPlugin:(e,t)=>{const r={slug:e,status:"active"};return t&&(r.source=t),h(`${n}jetpack/v4/plugins`,c,{body:JSON.stringify(r)}).then(p).then(m)},activateAkismet:()=>h(`${n}jetpack/v4/plugins`,c,{body:JSON.stringify({slug:"akismet",status:"active"})}).then(p).then(m),getAkismetData:()=>d(`${n}jetpack/v4/module/akismet/data`,a).then(p).then(m),checkAkismetKey:()=>d(`${n}jetpack/v4/module/akismet/key/check`,a).then(p).then(m),checkAkismetKeyTyped:e=>h(`${n}jetpack/v4/module/akismet/key/check`,c,{body:JSON.stringify({api_key:e})}).then(p).then(m),fetchStatsData:e=>d(function(e){let t=`${n}jetpack/v4/module/stats/data`;-1!==t.indexOf("?")?t+=`&range=${encodeURIComponent(e)}`:t+=`?range=${encodeURIComponent(e)}`;return t}(e),a).then(p).then(m).then(f),getPluginUpdates:()=>d(`${n}jetpack/v4/updates/plugins`,a).then(p).then(m),getPlans:()=>d(`${n}jetpack/v4/plans`,a).then(p).then(m),fetchSettings:()=>d(`${n}jetpack/v4/settings`,a).then(p).then(m),updateSetting:e=>h(`${n}jetpack/v4/settings`,c,{body:JSON.stringify(e)}).then(p).then(m),fetchSiteData:()=>d(`${n}jetpack/v4/site`,a).then(p).then(m).then((e=>JSON.parse(e.data))),fetchSiteFeatures:()=>d(`${n}jetpack/v4/site/features`,a).then(p).then(m).then((e=>JSON.parse(e.data))),fetchSiteProducts:()=>d(`${n}jetpack/v4/site/products`,a).then(p).then(m),fetchSitePurchases:()=>d(`${n}jetpack/v4/site/purchases`,a).then(p).then(m).then((e=>JSON.parse(e.data))),fetchSiteBenefits:()=>d(`${n}jetpack/v4/site/benefits`,a).then(p).then(m).then((e=>JSON.parse(e.data))),fetchSiteDiscount:()=>d(`${n}jetpack/v4/site/discount`,a).then(p).then(m).then((e=>e.data)),fetchSetupQuestionnaire:()=>d(`${n}jetpack/v4/setup/questionnaire`,a).then(p).then(m),fetchRecommendationsData:()=>d(`${n}jetpack/v4/recommendations/data`,a).then(p).then(m),fetchRecommendationsProductSuggestions:()=>d(`${n}jetpack/v4/recommendations/product-suggestions`,a).then(p).then(m),fetchRecommendationsUpsell:()=>d(`${n}jetpack/v4/recommendations/upsell`,a).then(p).then(m),fetchRecommendationsConditional:()=>d(`${n}jetpack/v4/recommendations/conditional`,a).then(p).then(m),saveRecommendationsData:e=>h(`${n}jetpack/v4/recommendations/data`,c,{body:JSON.stringify({data:e})}).then(p),fetchProducts:()=>d(`${n}jetpack/v4/products`,a).then(p).then(m),fetchRewindStatus:()=>d(`${n}jetpack/v4/rewind`,a).then(p).then(m).then((e=>JSON.parse(e.data))),fetchScanStatus:()=>d(`${n}jetpack/v4/scan`,a).then(p).then(m).then((e=>JSON.parse(e.data))),dismissJetpackNotice:e=>h(`${n}jetpack/v4/notice/${e}`,c,{body:JSON.stringify({dismissed:!0})}).then(p).then(m),fetchPluginsData:()=>d(`${n}jetpack/v4/plugins`,a).then(p).then(m),fetchIntroOffers:()=>d(`${n}jetpack/v4/intro-offers`,a).then(p).then(m),fetchVerifySiteGoogleStatus:e=>d(null!==e?`${n}jetpack/v4/verify-site/google/${e}`:`${n}jetpack/v4/verify-site/google`,a).then(p).then(m),verifySiteGoogle:e=>h(`${n}jetpack/v4/verify-site/google`,c,{body:JSON.stringify({keyring_id:e})}).then(p).then(m),submitSurvey:e=>h(`${n}jetpack/v4/marketing/survey`,c,{body:JSON.stringify(e)}).then(p).then(m),saveSetupQuestionnaire:e=>h(`${n}jetpack/v4/setup/questionnaire`,c,{body:JSON.stringify(e)}).then(p).then(m),updateLicensingError:e=>h(`${n}jetpack/v4/licensing/error`,c,{body:JSON.stringify(e)}).then(p).then(m),updateLicenseKey:e=>h(`${n}jetpack/v4/licensing/set-license`,c,{body:JSON.stringify({license:e})}).then(p).then(m),getUserLicensesCounts:()=>d(`${n}jetpack/v4/licensing/user/counts`,a).then(p).then(m),getUserLicenses:()=>d(`${n}jetpack/v4/licensing/user/licenses`,a).then(p).then(m),updateLicensingActivationNoticeDismiss:e=>h(`${n}jetpack/v4/licensing/user/activation-notice-dismiss`,c,{body:JSON.stringify({last_detached_count:e})}).then(p).then(m),updateRecommendationsStep:e=>h(`${n}jetpack/v4/recommendations/step`,c,{body:JSON.stringify({step:e})}).then(p),confirmIDCSafeMode:()=>h(`${n}jetpack/v4/identity-crisis/confirm-safe-mode`,c).then(p),startIDCFresh:e=>h(`${n}jetpack/v4/identity-crisis/start-fresh`,c,{body:JSON.stringify({redirect_uri:e})}).then(p).then(m),migrateIDC:()=>h(`${n}jetpack/v4/identity-crisis/migrate`,c).then(p),attachLicenses:e=>h(`${n}jetpack/v4/licensing/attach-licenses`,c,{body:JSON.stringify({licenses:e})}).then(p).then(m),fetchSearchPlanInfo:()=>d(`${i}jetpack/v4/search/plan`,a).then(p).then(m),fetchSearchSettings:()=>d(`${i}jetpack/v4/search/settings`,a).then(p).then(m),updateSearchSettings:e=>h(`${i}jetpack/v4/search/settings`,c,{body:JSON.stringify(e)}).then(p).then(m),fetchSearchStats:()=>d(`${i}jetpack/v4/search/stats`,a).then(p).then(m),fetchWafSettings:()=>d(`${n}jetpack/v4/waf`,a).then(p).then(m),updateWafSettings:e=>h(`${n}jetpack/v4/waf`,c,{body:JSON.stringify(e)}).then(p).then(m),fetchWordAdsSettings:()=>d(`${n}jetpack/v4/wordads/settings`,a).then(p).then(m),updateWordAdsSettings:e=>h(`${n}jetpack/v4/wordads/settings`,c,{body:JSON.stringify(e)}),fetchSearchPricing:()=>d(`${i}jetpack/v4/search/pricing`,a).then(p).then(m),fetchMigrationStatus:()=>d(`${n}jetpack/v4/migration/status`,a).then(p).then(m)};function d(e,t){return fetch(l(e),t)}function h(e,t,n){return fetch(e,Object.assign({},t,n)).catch(g)}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 p(e){return e.status>=200&&e.status<300?e:404===e.status?new Promise((()=>{throw e.redirected?new l(e.redirected):new c})):e.json().catch((e=>h(e))).then((t=>{const n=new Error(`${t.message} (Status ${e.status})`);throw n.response=t,n.name="ApiError",n}))}function m(e){return e.json().catch((t=>h(t,e.redirected,e.url)))}function h(e,t,n){throw t?new a(n):new o}function g(){throw new u}t.ZP=d},8868:function(e,t,n){"use strict";var r=n(2674),s=n.n(r),i=n(5736),o=n(5235),a=n.n(o),c=n(9196),l=n.n(c);const __=i.__;t.Z=e=>{let{logoColor:t="#069e08",showText:n=!0,className:r,height:i=32,...o}=e;const c=n?"0 0 118 32":"0 0 32 32";return l().createElement("svg",s()({xmlns:"http://www.w3.org/2000/svg",x:"0px",y:"0px",viewBox:c,className:a()("jetpack-logo",r),"aria-labelledby":"jetpack-logo-title",height:i},o),l().createElement("desc",{id:"jetpack-logo-title"},__("Jetpack Logo","jetpack-idc")),l().createElement("path",{fill:t,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"}),n&&l().createElement(l().Fragment,null,l().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"}),l().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"}),l().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"}),l().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"}),l().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"}),l().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"}),l().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"})))}},5033:function(e,t,n){"use strict";var r=n(5162),s=n.n(r),i=n(9196),o=n.n(i);n(1683);const a=e=>{const t=e.className+" jp-components-spinner",n={width:e.size,height:e.size,fontSize:e.size,borderTopColor:e.color},r={borderTopColor:e.color,borderRightColor:e.color};return o().createElement("div",{className:t},o().createElement("div",{className:"jp-components-spinner__outer",style:n},o().createElement("div",{className:"jp-components-spinner__inner",style:r})))};a.propTypes={color:s().string,className:s().string,size:s().number},a.defaultProps={color:"#FFFFFF",className:"",size:20},t.Z=a},6895:function(e,t,n){"use strict";function r(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const n={};let r;if("undefined"!=typeof window&&(r=window.Initial_State?.calypsoEnv),0===e.search("https://")){const t=new URL(e);e=`https://${t.host}${t.pathname}`,n.url=encodeURIComponent(e)}else n.source=encodeURIComponent(e);Object.keys(t).map((e=>{n[e]=encodeURIComponent(t[e])})),!Object.keys(n).includes("site")&&"undefined"!=typeof jetpack_redirects&&jetpack_redirects.hasOwnProperty("currentSiteRawUrl")&&(n.site=jetpack_redirects.currentSiteRawUrl),r&&(n.calypso_env=r);return"https://jetpack.com/redirect/?"+Object.keys(n).map((e=>e+"="+n[e])).join("&")}n.d(t,{Z:function(){return r}})},1132:function(e,t,n){let r={};try{r=n(8510)}catch{console.error("jetpackConfig is missing in your webpack config file. See @automattic/jetpack-config"),r={missingConfig:!0}}const s=e=>r.hasOwnProperty(e);e.exports={jetpackConfigHas:s,jetpackConfigGet:e=>{if(!s(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]}}},9477:function(e,t,n){"use strict";var r=n(6895),s=n(5033),i=n(5609),o=n(9818),a=n(9307),c=n(5736),l=n(5162),u=n.n(l),d=n(9196),p=n.n(d),m=n(2678),h=n(7144),g=n(2115),f=n(6637);const __=c.__,y=e=>{const{isStartingFresh:t,startFreshCallback:n,customContent:l,hasError:u}=e,d=(0,g.Z)(e.wpcomHomeUrl),h=(0,g.Z)(e.currentUrl),y=(0,o.useSelect)((e=>e(m.t).getIsActionInProgress()),[]),k=l.startFreshButtonLabel||__("Create a fresh connection","jetpack-idc");return p().createElement("div",{className:"jp-idc__idc-screen__card-action-base"+(u?" jp-idc__idc-screen__card-action-error":"")},p().createElement("div",{className:"jp-idc__idc-screen__card-action-top"},p().createElement("h4",null,l.startFreshCardTitle?(0,a.createInterpolateElement)(l.startFreshCardTitle,{em:p().createElement("em",null)}):__("Treat each site as independent sites","jetpack-idc")),p().createElement("p",null,(0,a.createInterpolateElement)(l.startFreshCardBodyText||(0,c.sprintf)(/* translators: %1$s: The current site domain name. %2$s: The original site domain name. */ -__("%1$s settings, stats, and subscribers will start fresh. %2$s will keep its data as is.","jetpack-idc"),h,d),{hostname:p().createElement("strong",null),em:p().createElement("em",null),strong:p().createElement("strong",null)}))),p().createElement("div",{className:"jp-idc__idc-screen__card-action-bottom"},p().createElement("div",{className:"jp-idc__idc-screen__card-action-sitename"},d),p().createElement(i.Dashicon,{icon:"minus",className:"jp-idc__idc-screen__card-action-separator"}),p().createElement("div",{className:"jp-idc__idc-screen__card-action-sitename"},h),p().createElement(i.Button,{className:"jp-idc__idc-screen__card-action-button",label:k,onClick:n,disabled:y},t?p().createElement(s.Z,null):k),u&&(v=l.supportURL,p().createElement(f.Z,null,(0,a.createInterpolateElement)(__("Could not create the connection. Retry or find out more here.","jetpack-idc"),{a:p().createElement("a",{href:v||(0,r.Z)("jetpack-support-safe-mode"),rel:"noopener noreferrer",target:"_blank"})})))));var v};y.propTypes={wpcomHomeUrl:u().string.isRequired,currentUrl:u().string.isRequired,isStartingFresh:u().bool.isRequired,startFreshCallback:u().func.isRequired,customContent:u().shape(h.Z),hasError:u().bool.isRequired},y.defaultProps={isStartingFresh:!1,startFreshCallback:()=>{},customContent:{},hasError:!1},t.Z=y},6596:function(e,t,n){"use strict";var r=n(6895),s=n(5033),i=n(5609),o=n(9818),a=n(9307),c=n(5736),l=n(5162),u=n.n(l),d=n(9196),p=n.n(d),m=n(2678),h=n(7144),g=n(2115),f=n(6637);const __=c.__,y=e=>{const t=(0,g.Z)(e.wpcomHomeUrl),n=(0,g.Z)(e.currentUrl),l=(0,o.useSelect)((e=>e(m.t).getIsActionInProgress()),[]),{isMigrating:u,migrateCallback:d,customContent:h,hasError:y}=e,k=h.migrateButtonLabel||__("Move your settings","jetpack-idc");return p().createElement("div",{className:"jp-idc__idc-screen__card-action-base"+(y?" jp-idc__idc-screen__card-action-error":"")},p().createElement("div",{className:"jp-idc__idc-screen__card-action-top"},p().createElement("h4",null,h.migrateCardTitle?(0,a.createInterpolateElement)(h.migrateCardTitle,{em:p().createElement("em",null)}):__("Move Jetpack data","jetpack-idc")),p().createElement("p",null,(0,a.createInterpolateElement)(h.migrateCardBodyText||(0,c.sprintf)(/* translators: %1$s: The current site domain name. %2$s: The original site domain name. */ -__("Move all your settings, stats and subscribers to your other URL, %1$s. %2$s will be disconnected from Jetpack.","jetpack-idc"),n,t),{hostname:p().createElement("strong",null),em:p().createElement("em",null),strong:p().createElement("strong",null)}))),p().createElement("div",{className:"jp-idc__idc-screen__card-action-bottom"},p().createElement("div",{className:"jp-idc__idc-screen__card-action-sitename"},t),p().createElement(i.Dashicon,{icon:"arrow-down-alt",className:"jp-idc__idc-screen__card-action-separator"}),p().createElement("div",{className:"jp-idc__idc-screen__card-action-sitename"},n),p().createElement(i.Button,{className:"jp-idc__idc-screen__card-action-button",label:k,onClick:d,disabled:l},u?p().createElement(s.Z,null):k),y&&(v=h.supportURL,p().createElement(f.Z,null,(0,a.createInterpolateElement)(__("Could not move your settings. Retry or find out more here.","jetpack-idc"),{a:p().createElement("a",{href:v||(0,r.Z)("jetpack-support-safe-mode"),rel:"noopener noreferrer",target:"_blank"})})))));var v};y.propTypes={wpcomHomeUrl:u().string.isRequired,currentUrl:u().string.isRequired,isMigrating:u().bool.isRequired,migrateCallback:u().func.isRequired,customContent:u().shape(h.Z),hasError:u().bool.isRequired},y.defaultProps={isMigrating:!1,migrateCallback:()=>{},customContent:{},hasError:!1},t.Z=y},5489:function(e,t,n){"use strict";var r=n(9196),s=n.n(r);t.Z=()=>s().createElement("svg",{className:"error-gridicon",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",height:24},s().createElement("rect",{x:"0",fill:"none",width:"24",height:"24"}),s().createElement("g",null,s().createElement("path",{d:"M12 4c4.411 0 8 3.589 8 8s-3.589 8-8 8-8-3.589-8-8 3.589-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-2-2h2l.5-6h-3l.5 6z"})))},6637:function(e,t,n){"use strict";var r=n(9196),s=n.n(r),i=n(5489);n(6611);t.Z=e=>{const{children:t}=e;return s().createElement("div",{className:"jp-idc__error-message"},s().createElement(i.Z,null),s().createElement("span",null,t))}},7381:function(e,t,n){"use strict";var r=n(4743),s=n(9818),i=n(5162),o=n.n(i),a=n(9196),c=n.n(a),l=n(970),u=n(1272),d=n(3105),p=n(2678),m=n(7144),h=n(6521),g=n(567);const f=e=>{const{logo:t,customContent:n,wpcomHomeUrl:i,currentUrl:o,apiNonce:m,apiRoot:f,redirectUri:y,tracksUserData:k,tracksEventData:v,isAdmin:C,possibleDynamicSiteUrlDetected:_}=e,[b,E]=(0,a.useState)(!1),w=(0,s.useSelect)((e=>e(p.t).getErrorType()),[]),{isMigrating:j,migrateCallback:S}=(0,l.Z)((0,a.useCallback)((()=>{E(!0)}),[E])),{isStartingFresh:F,startFreshCallback:I}=(0,d.Z)(y),{isFinishingMigration:U,finishMigrationCallback:R}=(0,u.Z)();return(0,a.useEffect)((()=>{r.ZP.setApiRoot(f),r.ZP.setApiNonce(m),(0,h.M)(v,k),v&&(v.hasOwnProperty("isAdmin")&&v.isAdmin?(0,h.Z)("notice_view"):(0,h.Z)("non_admin_notice_view",{page:!!v.hasOwnProperty("currentScreen")&&v.currentScreen}))}),[f,m,k,v]),c().createElement(g.Z,{logo:t,customContent:n,wpcomHomeUrl:i,currentUrl:o,redirectUri:y,isMigrating:j,migrateCallback:S,isMigrated:b,finishMigrationCallback:R,isFinishingMigration:U,isStartingFresh:F,startFreshCallback:I,isAdmin:C,hasStaySafeError:"safe-mode"===w,hasFreshError:"start-fresh"===w,hasMigrateError:"migrate"===w,possibleDynamicSiteUrlDetected:_})};f.propTypes={logo:o().object,customContent:o().shape(m.Z),wpcomHomeUrl:o().string.isRequired,currentUrl:o().string.isRequired,redirectUri:o().string.isRequired,apiRoot:o().string.isRequired,apiNonce:o().string.isRequired,tracksUserData:o().object,tracksEventData:o().object,isAdmin:o().bool.isRequired,possibleDynamicSiteUrlDetected:o().bool},f.defaultProps={customContent:{}},t.Z=f},5533:function(e,t,n){"use strict";var r=n(6895),s=n(9307),i=n(5736),o=n(5162),a=n.n(o),c=n(9196),l=n.n(c),u=n(7144),d=n(9477),p=n(6596),m=n(2533);const __=i.__,h=e=>{const{wpcomHomeUrl:t,currentUrl:n,isMigrating:i,migrateCallback:o,isStartingFresh:a,startFreshCallback:c,customContent:u,hasMigrateError:h,hasFreshError:g,hasStaySafeError:f,possibleDynamicSiteUrlDetected:y}=e;return l().createElement(l().Fragment,null,l().createElement("h2",null,u.mainTitle?(0,s.createInterpolateElement)(u.mainTitle,{em:l().createElement("em",null)}):__("Safe Mode has been activated","jetpack-idc")),l().createElement("p",null,(0,s.createInterpolateElement)(u.mainBodyText||__("Your site is in Safe Mode because you have 2 Jetpack-powered sites that appear to be duplicates. 2 sites that are telling Jetpack they’re the same site. Learn more about safe mode.","jetpack-idc"),{safeModeLink:l().createElement("a",{href:u.supportURL||(0,r.Z)("jetpack-support-safe-mode"),rel:"noopener noreferrer",target:"_blank"}),em:l().createElement("em",null),strong:l().createElement("strong",null)})),y&&l().createElement("p",null,(0,s.createInterpolateElement)(u.dynamicSiteUrlText||__("Notice: It appears that your 'wp-config.php' file might be using dynamic site URL values. Dynamic site URLs could cause Jetpack to enter Safe Mode. Learn how to set a static site URL.","jetpack-idc"),{dynamicSiteUrlSupportLink:l().createElement("a",{href:u.dynamicSiteUrlSupportLink||(0,r.Z)("jetpack-idcscreen-dynamic-site-urls"),rel:"noopener noreferrer",target:"_blank"}),em:l().createElement("em",null),strong:l().createElement("strong",null)})),l().createElement("h3",null,__("Please select an option","jetpack-idc")),l().createElement("div",{className:"jp-idc__idc-screen__cards"+(h||g?" jp-idc__idc-screen__cards-error":"")},l().createElement(p.Z,{wpcomHomeUrl:t,currentUrl:n,isMigrating:i,migrateCallback:o,customContent:u,hasError:h}),l().createElement("div",{className:"jp-idc__idc-screen__cards-separator"},"or"),l().createElement(d.Z,{wpcomHomeUrl:t,currentUrl:n,isStartingFresh:a,startFreshCallback:c,customContent:u,hasError:g})),l().createElement(m.Z,{hasError:f,customContent:u}))};h.propTypes={wpcomHomeUrl:a().string.isRequired,currentUrl:a().string.isRequired,isMigrating:a().bool.isRequired,migrateCallback:a().func,isStartingFresh:a().bool.isRequired,startFreshCallback:a().func,customContent:a().shape(u.Z),hasMigrateError:a().bool.isRequired,hasFreshError:a().bool.isRequired,hasStaySafeError:a().bool.isRequired,possibleDynamicSiteUrlDetected:a().bool},h.defaultProps={isMigrating:!1,isStartingFresh:!1,customContent:{},hasMigrateError:!1,hasFreshError:!1,hasStaySafeError:!1,possibleDynamicSiteUrlDetected:!1},t.Z=h},1052:function(e,t,n){"use strict";var r=n(5033),s=n(5609),i=n(9307),o=n(5736),a=n(5162),c=n.n(a),l=n(9196),u=n.n(l),d=n(7144),p=n(2115);const __=o.__,m=e=>{const{finishCallback:t,isFinishing:n,customContent:a}=e,c=(0,p.Z)(e.wpcomHomeUrl),l=(0,p.Z)(e.currentUrl),d=__("Got it, thanks","jetpack-idc");return u().createElement(u().Fragment,null,u().createElement("h2",null,a.migratedTitle?(0,i.createInterpolateElement)(a.migratedTitle,{em:u().createElement("em",null)}):__("Your Jetpack settings have migrated successfully","jetpack-idc")),u().createElement("p",null,(0,i.createInterpolateElement)(a.migratedBodyText||(0,o.sprintf)(/* translators: %1$s: The current site domain name. */ -__("Safe Mode has been switched off for %1$s website and Jetpack is fully functional.","jetpack-idc"),l),{hostname:u().createElement("strong",null),em:u().createElement("em",null),strong:u().createElement("strong",null)})),u().createElement("div",{className:"jp-idc__idc-screen__card-migrated"},u().createElement("div",{className:"jp-idc__idc-screen__card-migrated-hostname"},c),u().createElement(s.Dashicon,{icon:"arrow-down-alt",className:"jp-idc__idc-screen__card-migrated-separator"}),u().createElement(s.Dashicon,{icon:"arrow-right-alt",className:"jp-idc__idc-screen__card-migrated-separator-wide"}),u().createElement("div",{className:"jp-idc__idc-screen__card-migrated-hostname"},l)),u().createElement(s.Button,{className:"jp-idc__idc-screen__card-action-button jp-idc__idc-screen__card-action-button-migrated",onClick:t,label:d},n?u().createElement(r.Z,null):d))};m.propTypes={wpcomHomeUrl:c().string.isRequired,currentUrl:c().string.isRequired,finishCallback:c().func,isFinishing:c().bool.isRequired,customContent:c().shape(d.Z)},m.defaultProps={finishCallback:()=>{},isFinishing:!1,customContent:{}},t.Z=m},1064:function(e,t,n){"use strict";var r=n(6895),s=n(9307),i=n(5736),o=n(5162),a=n.n(o),c=n(9196),l=n.n(c),u=n(7144);const __=i.__,d=e=>{const{customContent:t}=e;return l().createElement(l().Fragment,null,l().createElement("h2",null,t.nonAdminTitle?(0,s.createInterpolateElement)(t.nonAdminTitle,{em:l().createElement("em",null)}):__("Safe Mode has been activated","jetpack-idc")),l().createElement("p",null,(0,s.createInterpolateElement)(t.nonAdminBodyText||__("This site is in Safe Mode because there are 2 Jetpack-powered sites that appear to be duplicates. 2 sites that are telling Jetpack they’re the same site. Learn more about safe mode.","jetpack-idc"),{safeModeLink:l().createElement("a",{href:t.supportURL||(0,r.Z)("jetpack-support-safe-mode"),rel:"noopener noreferrer",target:"_blank"}),em:l().createElement("em",null),strong:l().createElement("strong",null)})),t.nonAdminBodyText?"":l().createElement("p",null,__("An administrator of this site can take Jetpack out of Safe Mode.","jetpack-idc")))};d.propTypes={customContent:a().shape(u.Z)},d.defaultProps={customContent:{}},t.Z=d},567:function(e,t,n){"use strict";var r=n(8868),s=n(9307),i=n(5736),o=n(5162),a=n.n(o),c=n(9196),l=n.n(c),u=n(7144),d=n(5533),p=n(1052),m=n(1064);n(7724);const __=i.__,h=e=>{const{logo:t,customContent:n,wpcomHomeUrl:r,currentUrl:i,redirectUri:o,isMigrating:a,migrateCallback:c,isMigrated:u,finishMigrationCallback:h,isFinishingMigration:g,isStartingFresh:f,startFreshCallback:y,isAdmin:k,hasMigrateError:v,hasFreshError:C,hasStaySafeError:_,possibleDynamicSiteUrlDetected:b}=e,E=k?"":l().createElement(m.Z,{customContent:n});let w="";return k&&(w=u?l().createElement(p.Z,{wpcomHomeUrl:r,currentUrl:i,finishCallback:h,isFinishing:g,customContent:n}):l().createElement(d.Z,{wpcomHomeUrl:r,currentUrl:i,redirectUri:o,customContent:n,isMigrating:a,migrateCallback:c,isStartingFresh:f,startFreshCallback:y,hasMigrateError:v,hasFreshError:C,hasStaySafeError:_,possibleDynamicSiteUrlDetected:b})),l().createElement("div",{className:"jp-idc__idc-screen"+(u?" jp-idc__idc-screen__success":"")},l().createElement("div",{className:"jp-idc__idc-screen__header"},l().createElement("div",{className:"jp-idc__idc-screen__logo"},((e,t)=>"string"==typeof e||e instanceof String?l().createElement("img",{src:e,alt:t,className:"jp-idc__idc-screen__logo-image"}):e)(t,n.logoAlt||"")),l().createElement("div",{className:"jp-idc__idc-screen__logo-label"},n.headerText?(0,s.createInterpolateElement)(n.headerText,{em:l().createElement("em",null),strong:l().createElement("strong",null)}):__("Safe Mode","jetpack-idc"))),E,w)};h.propTypes={logo:a().object.isRequired,customContent:a().shape(u.Z),wpcomHomeUrl:a().string.isRequired,currentUrl:a().string.isRequired,redirectUri:a().string.isRequired,isMigrating:a().bool.isRequired,migrateCallback:a().func,isMigrated:a().bool.isRequired,finishMigrationCallback:a().func,isFinishingMigration:a().bool.isRequired,isStartingFresh:a().bool.isRequired,startFreshCallback:a().func,isAdmin:a().bool.isRequired,hasMigrateError:a().bool.isRequired,hasFreshError:a().bool.isRequired,hasStaySafeError:a().bool.isRequired,possibleDynamicSiteUrlDetected:a().bool},h.defaultProps={logo:l().createElement(r.Z,{height:24}),isMigrated:!1,isFinishingMigration:!1,isMigrating:!1,isStartingFresh:!1,customContent:{},hasMigrateError:!1,hasFreshError:!1,hasStaySafeError:!1,possibleDynamicSiteUrlDetected:!1},t.Z=h},2533:function(e,t,n){"use strict";var r=n(4743),s=n(5033),i=n(6895),o=n(5609),a=n(4333),c=n(9818),l=n(9307),u=n(5736),d=n(6483),p=n(5162),m=n.n(p),h=n(9196),g=n.n(h),f=n(2678),y=n(7144),k=n(6521),v=n(6637);n(310);const __=u.__,C=e=>{const{isActionInProgress:t,setIsActionInProgress:n,setErrorType:a,clearErrorType:c,hasError:u,customContent:p}=e,[m,f]=(0,h.useState)(!1),y=(0,h.useCallback)((()=>{t||(f(!0),n(!0),c(),(0,k.Z)("confirm_safe_mode"),r.ZP.confirmIDCSafeMode().then((()=>{window.location.href=(0,d.removeQueryArgs)(window.location.href,"jetpack_idc_clear_confirmation","_wpnonce")})).catch((e=>{throw n(!1),f(!1),a("safe-mode"),e})))}),[t,n,a,c]);return g().createElement("div",{className:"jp-idc__safe-mode"},m?g().createElement("div",{className:"jp-idc__safe-mode__staying-safe"},g().createElement(s.Z,{color:"black"}),g().createElement("span",null,__("Finishing setting up Safe mode…","jetpack-idc"))):(_=y,b=t,(0,l.createInterpolateElement)(__("Or decide later and stay in ","jetpack-idc"),{button:g().createElement(o.Button,{label:__("Safe mode","jetpack-idc"),variant:"link",onClick:_,disabled:b})})),u&&(C=p.supportURL,g().createElement(v.Z,null,(0,l.createInterpolateElement)(__("Could not stay in safe mode. Retry or find out more here.","jetpack-idc"),{a:g().createElement("a",{href:C||(0,i.Z)("jetpack-support-safe-mode"),rel:"noopener noreferrer",target:"_blank"})}))));var C,_,b};C.propTypes={isActionInProgress:m().bool,setIsActionInProgress:m().func.isRequired,setErrorType:m().func.isRequired,clearErrorType:m().func.isRequired,hasError:m().bool.isRequired,customContent:m().shape(y.Z)},C.defaultProps={hasError:!1},t.Z=(0,a.compose)([(0,c.withSelect)((e=>({isActionInProgress:e(f.t).getIsActionInProgress()}))),(0,c.withDispatch)((e=>({setIsActionInProgress:e(f.t).setIsActionInProgress,setErrorType:e(f.t).setErrorType,clearErrorType:e(f.t).clearErrorType})))])(C)},1272:function(e,t,n){"use strict";var r=n(9196);t.Z=()=>{const[e,t]=(0,r.useState)(!1),n=(0,r.useCallback)((()=>{e||(t(!0),window.location.reload())}),[e,t]);return{isFinishingMigration:e,finishMigrationCallback:n}}},970:function(e,t,n){"use strict";var r=n(4743),s=n(9818),i=n(9196),o=n(2678),a=n(6521);t.Z=e=>{const[t,n]=(0,i.useState)(!1),c=(0,s.useSelect)((e=>e(o.t).getIsActionInProgress()),[]),{setIsActionInProgress:l,setErrorType:u,clearErrorType:d}=(0,s.useDispatch)(o.t);return{isMigrating:t,migrateCallback:(0,i.useCallback)((()=>{c||((0,a.Z)("migrate"),l(!0),n(!0),d(),r.ZP.migrateIDC().then((()=>{n(!1),e&&"[object Function]"==={}.toString.call(e)&&e()})).catch((e=>{throw l(!1),n(!1),u("migrate"),e})))}),[n,e,c,l,u,d])}}},3105:function(e,t,n){"use strict";var r=n(4743),s=n(9818),i=n(9196),o=n(2678),a=n(6521);t.Z=e=>{const[t,n]=(0,i.useState)(!1),c=(0,s.useSelect)((e=>e(o.t).getIsActionInProgress()),[]),{setIsActionInProgress:l,setErrorType:u,clearErrorType:d}=(0,s.useDispatch)(o.t);return{isStartingFresh:t,startFreshCallback:(0,i.useCallback)((()=>{c||((0,a.Z)("start_fresh"),l(!0),n(!0),d(),r.ZP.startIDCFresh(e).then((e=>{window.location.href=e+"&from=idc-notice"})).catch((e=>{throw l(!1),n(!1),u("start-fresh"),e})))}),[n,c,l,e,u,d])}}},136:function(e,t,n){"use strict";n.d(t,{ZP:function(){return o},hG:function(){return r},jk:function(){return i},vC:function(){return s}});const r="SET_IS_ACTION_IN_PROGRESS",s="SET_ERROR_TYPE",i="CLEAR_ERROR_TYPE",o={setIsActionInProgress:e=>({type:r,isInProgress:e}),setErrorType:e=>({type:s,errorType:e}),clearErrorType:()=>({type:i})}},7773:function(e,t,n){"use strict";var r=n(9818),s=n(136);const i=(0,r.combineReducers)({isActionInProgress:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;return t.type===s.hG?t.isInProgress:e},errorType:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case s.vC:return t.errorType;case s.jk:return null}return e}});t.Z=i},9416:function(e,t){"use strict";t.Z={getIsActionInProgress:e=>e.isActionInProgress||!1,getErrorType:e=>e.errorType||null}},5943:function(e,t,n){"use strict";var r=n(17),s=n.n(r),i=n(9818);class o{static mayBeInit(e,t){null===o.store&&(o.store=(0,i.createReduxStore)(e,t),(0,i.register)(o.store))}}s()(o,"store",null),t.Z=o},2678:function(e,t,n){"use strict";n.d(t,{t:function(){return a}});var r=n(136),s=n(7773),i=n(9416),o=n(5943);const a="jetpack-idc";o.Z.mayBeInit(a,{reducer:s.Z,actions:r.ZP,selectors:i.Z})},7144:function(e,t,n){"use strict";var r=n(5162),s=n.n(r);t.Z={headerText:s().string,logoAlt:s().string,mainTitle:s().string,mainBodyText:s().string,migratedTitle:s().string,migratedBodyText:s().string,migrateCardTitle:s().string,migrateButtonLabel:s().string,migrateCardBodyText:s().string,startFreshCardTitle:s().string,startFreshCardBodyText:s().string,startFreshButtonLabel:s().string,nonAdminTitle:s().string,nonAdminBodyText:s().string,supportURL:s().string}},2115:function(e,t){"use strict";t.Z=e=>/^https?:\/\//.test(e)?new URL(e).hostname:e.replace(/\/$/,"")},6521:function(e,t,n){"use strict";n.d(t,{M:function(){return s},Z:function(){return i}});var r=n(6975);function s(e,t){t&&t.hasOwnProperty("userid")&&t.hasOwnProperty("username")&&r.Z.initialize(t.userid,t.username),e&&(e.hasOwnProperty("blogID")&&r.Z.assignSuperProps({blog_id:e.blogID}),e.hasOwnProperty("platform")&&r.Z.assignSuperProps({platform:e.platform})),r.Z.setMcAnalyticsEnabled(!0)}function i(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};void 0!==t&&"object"==typeof t||(t={}),e&&e.length&&void 0!==r.Z&&r.Z.tracks&&r.Z.mc&&(e=0!==(e=e.replace(/-/g,"_")).indexOf("jetpack_idc_")?"jetpack_idc_"+e:e,r.Z.tracks.recordEvent(e,t),e=(e=e.replace("jetpack_idc_","")).replace(/_/g,"-"),r.Z.mc.bumpStat("jetpack-idc",e))}},8510:function(e){"use strict";if(void 0==={consumer_slug:"identity_crisis"}){var t=new Error('Cannot find module \'{"consumer_slug":"identity_crisis"}\'');throw t.code="MODULE_NOT_FOUND",t}e.exports={consumer_slug:"identity_crisis"}},9196:function(e){"use strict";e.exports=window.React},5609:function(e){"use strict";e.exports=window.wp.components},4333:function(e){"use strict";e.exports=window.wp.compose},9818:function(e){"use strict";e.exports=window.wp.data},9307:function(e){"use strict";e.exports=window.wp.element},5736:function(e){"use strict";e.exports=window.wp.i18n},6483:function(e){"use strict";e.exports=window.wp.url},17:function(e,t,n){var r=n(6930);e.exports=function(e,t,n){return(t=r(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.__esModule=!0,e.exports.default=e.exports},2674:function(e){function t(){return e.exports=t=Object.assign?Object.assign.bind():function(e){for(var t=1;t - ); - if ( WPElement.createRoot ) { - WPElement.createRoot( container ).render( component ); - } else { - WPElement.render( component, container ); - } - } -} - -render(); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/src/_inc/style.scss b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/src/_inc/style.scss deleted file mode 100644 index 14f09db9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/src/_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-identity-crisis/src/class-identity-crisis.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/src/class-identity-crisis.php deleted file mode 100644 index 46ab3c6a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/src/class-identity-crisis.php +++ /dev/null @@ -1,1289 +0,0 @@ -disconnect_site( true ); - } else { - $connection->disconnect_site( false ); - } - - // 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(); - } - - /** - * Gets the link to the support document used to explain Safe Mode to users. - * - * @return string - */ - public static function get_safe_mod_doc_url() { - return Redirect::get_url( 'jetpack-support-safe-mode' ); - } - - /** - * 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], $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, $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'], $_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; - } - - $query_args = array( - 'home' => Urls::home_url(), - 'siteurl' => Urls::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; - } - - return add_query_arg( $query_args, $url ); - } - - /** - * Non-admins current screen check. - * - * @param object $current_screen Current screen. - * - * @return null - * @deprecated 0.5.0 Use `@automattic/jetpack-idc` instead. - */ - public function non_admins_current_screen_check( $current_screen ) { - _deprecated_function( __METHOD__, '0.5.0' ); - - self::$current_screen = $current_screen; - if ( isset( $current_screen->id ) && 'toplevel_page_jetpack' === $current_screen->id ) { - return null; - } - - return null; - } - - /** - * 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-idc' ); - - $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 ) ) { - return false; - } - - 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; - } - - /** - * Prepare URL for display. - * - * @param string $url URL to display. - * - * @return string - */ - public static function prepare_url_for_display( $url ) { - return untrailingslashit( self::normalize_url_protocol_agnostic( $url ) ); - } - - /** - * 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'] - ) { - $is_valid = false; - // 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; - } - - /** - * 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-idc' ), - $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; - } - - return $returned_values; - } - - /** - * Returns the value of the jetpack_sync_idc_optin filter, or constant. - * If set to true, the site will be put into staging mode. - * - * @return bool - * @since 0.2.0 - * @since-jetpack 4.3.2 - * @deprecated 0.2.6 Use should_handle_idc() - * @see Automattic\Jetpack\Identity_Crisis::should_handle_idc - */ - public static function sync_idc_optin() { - _deprecated_function( __METHOD__, '0.2.6', 'Automattic\\Jetpack\\Identity_Crisis::should_handle_idc' ); - return self::should_handle_idc(); - } - - /** - * 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 and the - * legacy jetpack_sync_idc_optin 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' ); - } elseif ( Constants::is_defined( 'JETPACK_SYNC_IDC_OPTIN' ) ) { - // Check the legacy constant. This constant should be considered deprecated as of version 0.2.6. - $default = Constants::get_constant( 'JETPACK_SYNC_IDC_OPTIN' ); - } else { - $default = ! Constants::is_defined( 'SUNRISE' ) && ! is_multisite(); - } - - // Add a callback which uses the legacy filter 'jetpack_sync_idc_optin'. - add_filter( 'jetpack_should_handle_idc', array( __CLASS__, 'legacy_jetpack_sync_idc_optin_filter' ) ); - - /** - * 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 ); - } - - /** - * Returns the value for the deprecated filter, 'jetpack_sync_idc_optin'. That filter has been replaced with the - * 'jetpack_should_handle_idc' filter. - * - * @since 0.2.6 - * - * @param bool $default Whether the site is opted in to IDC mitigation. - */ - public static function legacy_jetpack_sync_idc_optin_filter( $default ) { - /** - * 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_SYNC_IDC_OPTIN constant if set. - * - * @param bool $default Whether the site is opted in to IDC mitigation. - * - * @since 0.2.0 - * @since-jetpack 4.3.2 - * @deprecated 0.2.6 Use jetpack_should_handle_idc - */ - return (bool) apply_filters_deprecated( 'jetpack_sync_idc_optin', array( $default ), '0.2.6', 'jetpack_should_handle_idc' ); - } - - /** - * Does the current admin page have help tabs? - * - * @return bool - * @deprecated 0.5.0 Use `@automattic/jetpack-idc` instead. - */ - public function admin_page_has_help_tabs() { - _deprecated_function( __METHOD__, '0.5.0' ); - - if ( ! function_exists( 'get_current_screen' ) ) { - return false; - } - - $current_screen = get_current_screen(); - $tabs = $current_screen->get_help_tabs(); - - return ! empty( $tabs ); - } - - /** - * Renders the non-admin IDC notice. - * - * @return void - * @deprecated 0.5.0 Use `@automattic/jetpack-idc` instead. - */ - public function display_non_admin_idc_notice() { - _deprecated_function( __METHOD__, '0.5.0' ); - - $classes = 'jp-idc-notice inline is-non-admin notice notice-warning'; - if ( isset( self::$current_screen ) && 'toplevel_page_jetpack' !== self::$current_screen->id ) { - $classes .= ' is-dismissible'; - } - - if ( $this->admin_page_has_help_tabs() ) { - $classes .= ' has-help-tabs'; - } - ?> - -
        - render_notice_header(); ?> - -
        - admin_page_has_help_tabs() ) { - $classes .= ' has-help-tabs'; - } - ?> -
        - render_notice_header(); ?> - render_notice_first_step(); ?> - render_notice_second_step(); ?> -
        - - - - - - - - - - - Safe mode because we noticed this is an exact copy of %3$s.', 'jetpack-idc' ), - esc_url( self::get_safe_mod_doc_url() ), - esc_url( self::$wpcom_home_url ), - self::prepare_url_for_display( esc_url_raw( self::$wpcom_home_url ) ) - ), - array( 'a' => array( 'href' => array() ) ) - ); - - /** - * Allows overriding of the default header text in the first step of the Safe Mode notice. - * - * @param string $html The HTML to be displayed. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - return apply_filters( 'jetpack_idc_first_step_header_lead', $html ); - } - - /** - * Returns the first step header explanation. - * - * @return string - */ - public function get_first_step_header_explanation() { - $html = wp_kses( - sprintf( - /* translators: %s: Safe mode docs URL. */ - __( 'Please confirm Safe Mode or fix the Jetpack connection. Select one of the options below or learn more about Safe Mode.', 'jetpack-idc' ), - esc_url( self::get_safe_mod_doc_url() ) - ), - array( 'a' => array( 'href' => array() ) ) - ); - - /** - * Allows overriding of the default header explanation text in the first step of the Safe Mode notice. - * - * @param string $html The HTML to be displayed. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - return apply_filters( 'jetpack_idc_first_step_header_explanation', $html ); - } - - /** - * Returns the confirm safe mode explanation. - * - * @return string - */ - public function get_confirm_safe_mode_action_explanation() { - $html = wp_kses( - sprintf( - /* translators: %s: Site URL. */ - __( 'Is this website a temporary duplicate of %2$s for the purposes of testing, staging or development? If so, we recommend keeping it in Safe Mode.', 'jetpack-idc' ), - esc_url( untrailingslashit( self::$wpcom_home_url ) ), - self::prepare_url_for_display( esc_url( self::$wpcom_home_url ) ) - ), - array( 'a' => array( 'href' => array() ) ) - ); - - /** - * Allows overriding of the default text used to explain the confirm safe mode action. - * - * @param string $html The HTML to be displayed. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - return apply_filters( 'jetpack_idc_confirm_safe_mode_explanation', $html ); - } - - /** - * Returns the confirm safe mode button text. - * - * @return string - */ - public function get_confirm_safe_mode_button_text() { - $string = esc_html__( 'Confirm Safe Mode', 'jetpack-idc' ); - - /** - * Allows overriding of the default text used for the confirm safe mode action button. - * - * @param string $string The string to be displayed. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - return apply_filters( 'jetpack_idc_confirm_safe_mode_button_text', $string ); - } - - /** - * Returns the first step fix connection action explanation. - * - * @return string - */ - public function get_first_step_fix_connection_action_explanation() { - $html = wp_kses( - sprintf( - /* translators: %s: Site URL. */ - __( 'If this is a separate and new website, or the new home of %2$s, we recommend turning Safe Mode off, and re-establishing your connection to WordPress.com.', 'jetpack-idc' ), - esc_url( untrailingslashit( self::$wpcom_home_url ) ), - self::prepare_url_for_display( esc_url( self::$wpcom_home_url ) ) - ), - array( 'a' => array( 'href' => array() ) ) - ); - - /** - * Allows overriding of the default text used to explain the fix Jetpack connection action. - * - * @param string $html The HTML to be displayed. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - return apply_filters( 'jetpack_idc_first_fix_connection_explanation', $html ); - } - - /** - * Returns the first step fix connection button text. - * - * @return string - */ - public function get_first_step_fix_connection_button_text() { - $string = esc_html__( "Fix Jetpack's Connection", 'jetpack-idc' ); - - /** - * Allows overriding of the default text used for the fix Jetpack connection action button. - * - * @param string $string The string to be displayed. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - return apply_filters( 'jetpack_idc_first_step_fix_connection_button_text', $string ); - } - - /** - * Returns the second step header lead. - * - * @return string - */ - public function get_second_step_header_lead() { - $string = sprintf( - /* translators: %s: Site URL. */ - esc_html__( 'Is %1$s the new home of %2$s?', 'jetpack-idc' ), - untrailingslashit( self::normalize_url_protocol_agnostic( get_home_url() ) ), - untrailingslashit( self::normalize_url_protocol_agnostic( esc_url_raw( self::$wpcom_home_url ) ) ) - ); - - /** - * Allows overriding of the default header text in the second step of the Safe Mode notice. - * - * @param string $html The HTML to be displayed. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - return apply_filters( 'jetpack_idc_second_step_header_lead', $string ); - } - - /** - * Returns the site action explanation. - * - * @return string - */ - public function get_migrate_site_action_explanation() { - $html = wp_kses( - sprintf( - /* translators: %s: Site URL. */ - __( 'Yes. %2$s is replacing %4$s. I would like to migrate my stats and subscribers from %4$s to %2$s.', 'jetpack-idc' ), - esc_url( get_home_url() ), - self::prepare_url_for_display( get_home_url() ), - esc_url( self::$wpcom_home_url ), - untrailingslashit( self::normalize_url_protocol_agnostic( esc_url_raw( self::$wpcom_home_url ) ) ) - ), - array( 'a' => array( 'href' => array() ) ) - ); - - /** - * Allows overriding of the default text for explaining the migrate site action. - * - * @param string $html The HTML to be displayed. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - return apply_filters( 'jetpack_idc_migrate_site_explanation', $html ); - } - - /** - * Returns the migrate site button text. - * - * @return string - */ - public function get_migrate_site_button_text() { - $string = esc_html__( 'Migrate Stats & Subscribers', 'jetpack-idc' ); - - /** - * Allows overriding of the default text used for the migrate site action button. - * - * @param string $string The string to be displayed. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - return apply_filters( 'jetpack_idc_migrate_site_button_text', $string ); - } - - /** - * Returns the start fresh explanation. - * - * @return string - */ - public function get_start_fresh_action_explanation() { - $html = wp_kses( - sprintf( - /* translators: %s: Site URL. */ - __( 'No. %2$s is a new and different website that\'s separate from %4$s. It requires a new connection to WordPress.com for new stats and subscribers.', 'jetpack-idc' ), - esc_url( get_home_url() ), - self::prepare_url_for_display( get_home_url() ), - esc_url( self::$wpcom_home_url ), - untrailingslashit( self::normalize_url_protocol_agnostic( esc_url_raw( self::$wpcom_home_url ) ) ) - ), - array( 'a' => array( 'href' => array() ) ) - ); - - /** - * Allows overriding of the default text for explaining the start fresh action. - * - * @param string $html The HTML to be displayed. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - return apply_filters( 'jetpack_idc_start_fresh_explanation', $html ); - } - - /** - * Returns the start fresh button text. - * - * @return string - */ - public function get_start_fresh_button_text() { - $string = esc_html__( 'Start Fresh & Create New Connection', 'jetpack-idc' ); - - /** - * Allows overriding of the default text used for the start fresh action button. - * - * @param string $string The string to be displayed. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - return apply_filters( 'jetpack_idc_start_fresh_button_text', $string ); - } - - /** - * Returns the unsure prompt text. - * - * @return string - */ - public function get_unsure_prompt() { - $html = wp_kses( - sprintf( - /* translators: %s: Safe mode docs URL. */ - __( 'Unsure what to do? Read more about Jetpack Safe Mode', 'jetpack-idc' ), - esc_url( self::get_safe_mod_doc_url() ) - ), - array( 'a' => array( 'href' => array() ) ) - ); - - /** - * Allows overriding of the default text using in the "Unsure what to do?" prompt. - * - * @param string $html The HTML to be displayed. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - return apply_filters( 'jetpack_idc_unsure_prompt', $html ); - } - - /** - * Returns the non-admin notice text. - * - * @return string - * @deprecated 0.5.0 Use `@automattic/jetpack-idc` instead. - */ - public function get_non_admin_notice_text() { - _deprecated_function( __METHOD__, '0.5.0' ); - - $html = wp_kses( - sprintf( - /* translators: %s: Safe mode docs URL. */ - __( 'Jetpack has been placed into Safe Mode. Learn more about Safe Mode.', 'jetpack-idc' ), - esc_url( self::get_safe_mod_doc_url() ) - ), - array( 'a' => array( 'href' => array() ) ) - ); - - /** - * Allows overriding of the default text that is displayed to non-admin on the Jetpack admin page. - * - * @param string $html The HTML to be displayed. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - return apply_filters( 'jetpack_idc_non_admin_notice_text', $html ); - } - - /** - * Returns the non-admin contact admin text. - * - * @return string - * @deprecated 0.5.0 Use `@automattic/jetpack-idc` instead. - */ - public function get_non_admin_contact_admin_text() { - _deprecated_function( __METHOD__, '0.5.0' ); - - $string = esc_html__( 'An administrator of this site can take Jetpack out of Safe Mode.', 'jetpack-idc' ); - - /** - * Allows overriding of the default text that is displayed to non-admins prompting them to contact an admin. - * - * @param string $string The string to be displayed. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - return apply_filters( 'jetpack_idc_non_admin_contact_admin_text', $string ); - } - - /** - * 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; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/src/class-rest-endpoints.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/src/class-rest-endpoints.php deleted file mode 100644 index d3197e46..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/src/class-rest-endpoints.php +++ /dev/null @@ -1,187 +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-idc' ), - 'type' => 'string', - ), - ), - ) - ); - } - - /** - * 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-idc' ), - 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-idc' ), - 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-idc' ), - 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-idc' - ); - - return new WP_Error( 'invalid_user_permission_identity_crisis', $error_msg, array( 'status' => rest_authorization_required_code() ) ); - } - -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/src/class-ui.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/src/class-ui.php deleted file mode 100644 index 0b0a31e4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-identity-crisis/src/class-ui.php +++ /dev/null @@ -1,193 +0,0 @@ - true, - 'textdomain' => 'jetpack-idc', - ) - ); - 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, - ); - } - - /** - * 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 ? 1 : -1; - } - ); - - $consumer_chosen = null; - $consumer_url_length = 0; - - foreach ( $consumers as $consumer ) { - if ( empty( $consumer['admin_page'] ) || ! is_string( $consumer['admin_page'] ) ) { - continue; - } - - if ( isset( $_SERVER['REQUEST_URI'] ) && 0 === strpos( 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'] ); - } - } - - 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-ip/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/CHANGELOG.md deleted file mode 100644 index 3a987c9c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/CHANGELOG.md +++ /dev/null @@ -1,23 +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.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.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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 45cf2864..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/composer.json +++ /dev/null @@ -1,44 +0,0 @@ -{ - "name": "automattic/jetpack-ip", - "description": "Utilities for working with IP addresses.", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": {}, - "require-dev": { - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "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.1.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 7b92ba78..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/src/class-utils.php +++ /dev/null @@ -1,246 +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. - 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; - } - - /** - * Uses inet_pton if available to convert an IP address to a binary string. - * If inet_pton is not available, ip2long will convert the address to an integer. - * Returns false if an invalid IP address is given. - * - * NOTE: ip2long will return false for any ipv6 address. servers that do not support - * inet_pton will not support ipv6 - * - * @param mixed $ip IP address. - * @return int|string|bool - */ - public static function convert_ip_address( $ip ) { - if ( function_exists( 'inet_pton' ) ) { - return inet_pton( $ip ); - } - return ip2long( $ip ); - } - - /** - * Checks that a given IP address is within a given low - high range. - * Servers that support inet_pton will use that function to convert the ip to number, - * while other servers will use ip2long. - * - * NOTE: servers that do not support inet_pton cannot support ipv6. - * - * @param mixed $ip IP. - * @param mixed $range_low Range Low. - * @param mixed $range_high Range High. - * @return Bool - */ - public static function ip_address_is_in_range( $ip, $range_low, $range_high ) { - // The inet_pton will give us binary string of an ipv4 or ipv6. - // We can then use strcmp to see if the address is in range. - if ( function_exists( 'inet_pton' ) ) { - $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; - } - // The ip2long will give us an integer of an ipv4 address only. it will produce FALSE for ipv6. - } else { - $ip_num = ip2long( $ip ); - $ip_low = ip2long( $range_low ); - $ip_high = ip2long( $range_high ); - if ( $ip_num && $ip_low && $ip_high && $ip_num >= $ip_low && $ip_num <= $ip_high ) { - return true; - } - } - return false; - } - - /** - * Extracts IP addresses from a given string. - * - * We allow for both, one IP per line or comma-; semicolon; or whitespace-separated lists. This also validates the IP addresses - * and only returns the ones that look valid. IP ranges using the "-" character are also supported. - * - * @param string $ips List of ips - example: "8.8.8.8\n4.4.4.4,2.2.2.2;1.1.1.1 9.9.9.9,5555.5555.5555.5555,1.1.1.10-1.1.1.20". - * @return array List of valid IP addresses. - example based on input example: array('8.8.8.8', '4.4.4.4', '2.2.2.2', '1.1.1.1', '9.9.9.9', '1.1.1.10-1.1.1.20') - */ - public static function get_ip_addresses_from_string( $ips ) { - $ips = (string) $ips; - $ips = preg_split( '/[\s,;]/', $ips ); - - $result = array(); - - foreach ( $ips as $ip ) { - // Validate both IP values from the 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 the low and high IP addresses of a range. - * - * NOTE: servers that do not support inet_pton cannot support ipv6. - * - * @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 ( ! filter_var( $range_low, FILTER_VALIDATE_IP ) || ! filter_var( $range_high, FILTER_VALIDATE_IP ) ) { - return false; - } - - // Validate that the $range_low is lower or equal to $range_high. - if ( function_exists( 'inet_pton' ) ) { - // The inet_pton will give us binary string of an ipv4 or ipv6. - // We can then use strcmp to see if the address is in range. - $ip_low = inet_pton( $range_low ); - $ip_high = inet_pton( $range_high ); - if ( false === $ip_low || false === $ip_high ) { - return false; - } - if ( strcmp( $ip_low, $ip_high ) > 0 ) { - return false; - } - } else { - // The ip2long will give us an integer of an ipv4 address only. it will produce FALSE for ipv6. - $ip_low = ip2long( $range_low ); - $ip_high = ip2long( $range_high ); - if ( false === $ip_low || false === $ip_high ) { - return false; - } - if ( $ip_low > $ip_high ) { - return false; - } - } - - return true; - } - -} 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 cbdf993d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/CHANGELOG.md +++ /dev/null @@ -1,678 +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). - -## [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 - -[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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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-165b2f00927a762c8cf4.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/images/background-165b2f00927a762c8cf4.png deleted file mode 100644 index c2d50e1b..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/images/background-165b2f00927a762c8cf4.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 cc667d80..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-polyfill'), 'version' => 'ef911dd8f37f702652eb'); 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 ed102882..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: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.hidden{display:none}.jitm-card{background-color:#fff;background-image:url(images/background-165b2f00927a762c8cf4.png);background-position:100%;background-repeat:no-repeat;border:1px solid #fff;border-radius:2px;box-shadow:0 1px 4px rgba(0,0,0,.16);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:0;margin-right:0}#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{fill:#069e08;height:2rem;width:2rem}.jitm-banner__icon-plan .jp-emblem .jitm-jp-logo{fill:inherit;height:inherit;width:2.5rem}@media(min-width:481px){.jitm-banner__icon-plan{align-items:center}}.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 0a82f88b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/index.js +++ /dev/null @@ -1 +0,0 @@ -!function(){"use strict";var t,e={567:function(t){t.exports=window.jQuery}},a={};function n(t){var i=a[t];if(void 0!==i)return i.exports;var c=a[t]={exports:{}};return e[t](c,c.exports,n),c.exports}n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,{a:e}),e},n.d=function(t,e){for(var a in e)n.o(e,a)&&!n.o(t,a)&&Object.defineProperty(t,a,{enumerable:!0,get:e[a]})},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},t=n(567),n.n(t)()(document).ready((function(t){var e={default:function(e){var a='
        ';if(a+='
        ',a+='
        '+e.content.icon+"
        ",a+='
        ',a+='
        '+e.content.message+"
        ",e.content.description&&""!==e.content.description){if(a+='
        '+e.content.description,e.content.list.length>0){a+='
        "}if(a+="
        ",a+="
        ",a+='
        ',e.activate_module&&(a+='"),e.CTA.message){var c="jitm-button is-compact jptracks";e.CTA.primary&&null===e.activate_module&&(c+=" is-primary");var o=e.CTA.ajax_action;a+='
        ',a+='"+e.CTA.message+"",a+="
        "}return a+="
        ",e.is_dismissible&&(a+=''),t(a+="
        ")}},a=function(){t(".jetpack-jitm-message").each((function(){var a=t(this),n=a.data("message-path"),i=a.data("query"),c=a.data("redirect"),o=location.hash;o=o.replace(/#\//,"_"),n.includes("jetpack_page_my-jetpack")?n=n.replace("jetpack_page_my-jetpack","jetpack_page_my-jetpack"+o):"_dashboard"!==o&&(n=n.replace("toplevel_page_jetpack","toplevel_page_jetpack"+o));var r=!!t(".jetpack-logo__masthead").length;t.get(window.jitm_config.api_root+"jetpack/v4/jitm",{message_path:n,query:i,full_jp_logo_exists:r,_wpnonce:a.data("nonce")}).then((function(n){"object"==typeof n&&n[1]&&(n=[n[1]]),0!==n.length&&n[0].content&&function(a,n,i){var c;(c=n.template)&&e[c]||(c="default"),n.url=n.url+"&redirect="+i;var o,r=e[c](n);r.find(".jitm-banner__dismiss").on("click",(o=r,function(e){e.preventDefault(),o.hide(),t.ajax({url:window.jitm_config.api_root+"jetpack/v4/jitm",method:"POST",beforeSend:function(t){t.setRequestHeader("X-WP-Nonce",window.jitm_config.nonce)},data:{id:n.id,feature_class:n.feature_class}})})),t("#jp-admin-notices").length>0?(a.innerHTML=r,t("#jp-admin-notices").find(".jitm-card")&&t(".jitm-card").replaceWith(r),r.prependTo(t("#jp-admin-notices"))):a.replaceWith(r),r.find("#jitm-banner__activate a").on("click",(function(){var e=t(this);if(e.attr("disabled"))return!1;t.ajax({url:window.jitm_config.api_root+"jetpack/v4/module/"+e.data("module")+"/active",method:"POST",beforeSend:function(e){e.setRequestHeader("X-WP-Nonce",a.data("nonce")),t("#jitm-banner__activate a").text(window.jitm_config.activating_module_text),t("#jitm-banner__activate a").attr("disabled",!0)}}).done((function(){t("#jitm-banner__activate a").text(window.jitm_config.activated_module_text),t("#jitm-banner__activate a").attr("disabled",!0),setTimeout((function(){r.fadeOut("slow")}),2e3)}))})),r.find(".jitm-button[data-ajax-action]").on("click",(function(e){e.preventDefault();var n=t(this);return n.attr("disabled",!0),t.post(window.ajaxurl,{action:n.data("ajax-action"),_nonce:a.data("ajax-nonce")}).done((function(){r.fadeOut("slow")})).fail((function(){n.attr("disabled",!1)})),!1}))}(a,n[0],c)}))}))};a(),t(window).on("hashchange",(function(t){const e=t.originalEvent.newURL;if(e.indexOf("jetpack#/")>=0||e.indexOf("my-jetpack")>=0){var n=document.querySelector(".jitm-card");n&&n.remove(),a()}}))}))}(); \ 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 d8e4247d..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: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.hidden{display:none}.jitm-card{background-color:#fff;background-image:url(images/background-165b2f00927a762c8cf4.png);background-position:0;background-repeat:no-repeat;border:1px solid #fff;border-radius:2px;box-shadow:0 1px 4px rgba(0,0,0,.16);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:0;margin-left:0}#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{fill:#069e08;height:2rem;width:2rem}.jitm-banner__icon-plan .jp-emblem .jitm-jp-logo{fill:inherit;height:inherit;width:2.5rem}@media(min-width:481px){.jitm-banner__icon-plan{align-items:center}}.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 9a217104..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/composer.json +++ /dev/null @@ -1,60 +0,0 @@ -{ - "name": "automattic/jetpack-jitm", - "description": "Just in time messages for Jetpack", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "automattic/jetpack-a8c-mc-stats": "^1.4.19", - "automattic/jetpack-assets": "^1.17.34", - "automattic/jetpack-connection": "^1.51.4", - "automattic/jetpack-device-detection": "^1.4.24", - "automattic/jetpack-logo": "^1.5.22", - "automattic/jetpack-partner": "^1.7.22", - "automattic/jetpack-redirect": "^1.7.24", - "automattic/jetpack-status": "^1.16.3" - }, - "require-dev": { - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2" - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "build-production": [ - "pnpm run build-production" - ], - "build-development": [ - "pnpm run build" - ], - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "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": "2.3.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 b33fe606..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-jitm.php +++ /dev/null @@ -1,312 +0,0 @@ -register(); - } - - /** - * Pre/Post Connection JITM factory metod - * - * @return Post_Connection_JITM|Pre_Connection_JITM JITM instance. - */ - public static function get_instance() { - if ( ( new Connection_Manager() )->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' ) ); - } - } - - /** - * Function to enqueue jitm css and js - */ - public function jitm_enqueue_files() { - if ( $this->is_gutenberg_page() ) { - return; - } - - Assets::register_script( - 'jetpack-jitm', - '../build/index.js', - __FILE__, - array( - 'in_footer' => true, - 'dependencies' => array( 'jquery' ), - ) - ); - Assets::enqueue_script( 'jetpack-jitm' ); - 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' ), - 'nonce' => wp_create_nonce( 'wp_rest' ), - ) - ); - } - - /** - * Is the current page a block editor page? - * - * @since 1.1.0 - * @since-jetpack 8.0.0 - */ - public function is_gutenberg_page() { - $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; - } - - // do not display on Gutenberg pages. - if ( $this->is_gutenberg_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 - ?> -
        - ' . ( ( $full_jp_logo_exists ) ? $jetpack_logo->get_jp_emblem() : $jetpack_logo->get_jp_emblem_larger() ) . ''; - break; - case 'woocommerce': - $content_icon = ''; - 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; - } -} 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 4ff2eb76..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-post-connection-jitm.php +++ /dev/null @@ -1,416 +0,0 @@ -tracking = new Tracking(); - } - - /** - * A special filter for WooCommerce, to set a message based on local state. - * - * @param string $content The current message. - * - * @return array 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 - * - * @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( $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, - ) - ); - - $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 ); - - $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 6a779873..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-pre-connection-jitm.php +++ /dev/null @@ -1,171 +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 ) { - 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 ce8338ea..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-rest-api-endpoints.php +++ /dev/null @@ -1,91 +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(); - } - - return $jitm->get_messages( $request['message_path'], urldecode_deep( $request['query'] ), 'true' === $request['full_jp_logo_exists'] ? true : false ); - } - - /** - * 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 f9670ad5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/css/jetpack-admin-jitm.scss +++ /dev/null @@ -1,478 +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-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; - } - - &: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; - } - } - &.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; - background-image: url( "../images/background.png" ); - background-repeat: no-repeat; - background-position: right center; - 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: 0; - } -} - -// 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__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 c2d50e1b..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 11d9fbf4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/CHANGELOG.md +++ /dev/null @@ -1,297 +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). - -## [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 - -[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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 24999814..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/composer.json +++ /dev/null @@ -1,50 +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": { - "automattic/jetpack-connection": "^1.51.7" - }, - "require-dev": { - "automattic/wordbless": "@dev", - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "post-install-cmd": "WorDBless\\Composer\\InstallDropin::copy", - "post-update-cmd": "WorDBless\\Composer\\InstallDropin::copy", - "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": "1.8.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 39e40d23..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/src/class-endpoints.php +++ /dev/null @@ -1,447 +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 13982d71..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 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; - } - ); - } - - 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; - } - } -} 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 b968c069..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/CHANGELOG.md +++ /dev/null @@ -1,188 +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). - -## [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 - -[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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 3fc88421..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/composer.json +++ /dev/null @@ -1,39 +0,0 @@ -{ - "name": "automattic/jetpack-logo", - "description": "A logo for Jetpack", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": {}, - "require-dev": { - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "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": "1.6.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 05622de3..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 = <<<'EOSVG' - -EOSVG; - -/** - * 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 d6cd221e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/CHANGELOG.md +++ /dev/null @@ -1,870 +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). - -## [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 - -[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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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-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-a54137485af36fdffe9c.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/boost-a54137485af36fdffe9c.png deleted file mode 100644 index dd818e46..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/boost-a54137485af36fdffe9c.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/connect-f27775ac15cf885713c2.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/connect-f27775ac15cf885713c2.png deleted file mode 100644 index 66f8710a..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/connect-f27775ac15cf885713c2.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-7e7684ae2c40327d8fed.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/crm-7e7684ae2c40327d8fed.png deleted file mode 100644 index cfec3eed..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/crm-7e7684ae2c40327d8fed.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/disconnect-confirm-dc9fe8f5c68cfd1320e0.jpg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/disconnect-confirm-dc9fe8f5c68cfd1320e0.jpg deleted file mode 100644 index 13f5651c..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/disconnect-confirm-dc9fe8f5c68cfd1320e0.jpg and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/disconnect-thanks-5873bfac56a9bd7322cd.jpg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/disconnect-thanks-5873bfac56a9bd7322cd.jpg deleted file mode 100644 index a191ec9e..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/disconnect-thanks-5873bfac56a9bd7322cd.jpg 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/extras-26daf36507504c96d066.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/extras-26daf36507504c96d066.png deleted file mode 100644 index d4d49627..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/extras-26daf36507504c96d066.png and /dev/null differ 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/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-license-activation-with-lock-7b01c1a4cf56de799cd7.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-license-activation-with-lock-7b01c1a4cf56de799cd7.png deleted file mode 100644 index ea421dc0..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-7b01c1a4cf56de799cd7.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-cad524ede4e793cc0ece.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-license-activation-with-success-cad524ede4e793cc0ece.png deleted file mode 100644 index a2562d9b..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-cad524ede4e793cc0ece.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/search-f9756bd9c926d905fe70.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/search-f9756bd9c926d905fe70.png deleted file mode 100644 index 0f77309b..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/search-f9756bd9c926d905fe70.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-9591093a9a238cc48a35.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/videopress-9591093a9a238cc48a35.png deleted file mode 100644 index 9a8f1dfb..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/videopress-9591093a9a238cc48a35.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 17448b06..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('react', 'wp-api-fetch', 'wp-components', 'wp-compose', 'wp-data', 'wp-date', 'wp-element', 'wp-i18n', 'wp-polyfill', 'wp-primitives', 'wp-url'), 'version' => '9fc14b80f5a467303947'); 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 eb4beab9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.css +++ /dev/null @@ -1 +0,0 @@ -#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 .jetpack-logo{height:40px}#my-jetpack-container .jp-dashboard-footer__jetpack-symbol{height:16px}#wpbody-content>.notice{display:none}#wpwrap{background-color:var(--jp-white-off)}.pIsYsXFAJ9KX2VrS5rmY{--actions-size:28px;--status-size:8px;background:var(--jp-white);border-radius:var(--jp-border-radius);box-shadow:0 0 40px rgba(0,0,0,.08);box-shadow:0 0 0 1px var(--jp-gray-10) inset;display:flex;flex-direction:column;height:100%;padding:calc(var(--spacing-base)*3)}.pIsYsXFAJ9KX2VrS5rmY.YXHdD0VsFjiTsVRLrrx9{background:none;background-color:var(--jp-white-off);color:var(--jp-black-80);text-decoration:none}.pIsYsXFAJ9KX2VrS5rmY.YXHdD0VsFjiTsVRLrrx9:hover{background-color:var(--jp-white)}.pIsYsXFAJ9KX2VrS5rmY.YXHdD0VsFjiTsVRLrrx9:focus{background-color:var(--jp-white);box-shadow:0 0 0 1.5px var(--jp-black);outline:3px solid transparent}.pIsYsXFAJ9KX2VrS5rmY.Pp9cMIaESLYelLOX3tkI{box-shadow:0 0 0 1.5px var(--jp-red-60)}.w56ueQLYexqzTybA7015{align-items:center;display:flex;justify-content:space-between;margin-bottom:var(--spacing-base);width:100%}.gmPKCDKZcfQt9WieTyKS{flex-grow:1}.fDBaV7I4yUO6w5AWVEtr{align-items:center;display:flex;flex-wrap:wrap;justify-content:space-between;margin-top:calc(var(--spacing-base)*2);min-height:var(--actions-size);width:100%}.f5VJYwuJmjxH8PVxEbbv{align-items:center;display:flex;height:var(--actions-size);margin-left:var(--spacing-base);white-space:nowrap}.f5VJYwuJmjxH8PVxEbbv:before{border-radius:50%;content:"";display:inline-block;height:var(--status-size);margin-right:var(--spacing-base);width:var(--status-size)}.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.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}}.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.5px;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.5px 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)}.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)}._fUXxnSp5pagKBp9gSN7 *{box-sizing:border-box}.jErCC9oKHSM15BxzFyQK{margin-bottom:0}.oVoYbwbFB6U2o90Njusk{border:1px solid var(--jp-gray);border-left:6px solid var(--jp-red-50);border-radius:var(--jp-border-radius);box-shadow:0 4px 8px rgba(0,0,0,.03),0 1px 2px rgba(0,0,0,.06);color:var(--jp-gray-80);font-size:16px;line-height:22px;margin:0;padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3) calc(var(--spacing-base)*2) calc(var(--spacing-base)*3)}.oVoYbwbFB6U2o90Njusk.is-error{background-color:var(--jp-white)}.oVoYbwbFB6U2o90Njusk .components-notice__content{align-items:flex-start;display:flex;flex-direction:column;margin:0;padding:12px 4px}.oVoYbwbFB6U2o90Njusk .is-link{color:var(--jp-black);font-size:16px;font-weight:600}.oVoYbwbFB6U2o90Njusk .components-notice__dismiss{align-self:center}.oVoYbwbFB6U2o90Njusk .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:calc(var(--spacing-base)*2 + 24px);margin-top:24px;padding:8px 24px;text-decoration:none}.oVoYbwbFB6U2o90Njusk.Snc8NEmDelsbhlH4285s .components-notice__action{margin-left:0;margin-top:0;white-space:nowrap}.oVoYbwbFB6U2o90Njusk.Snc8NEmDelsbhlH4285s .components-notice__content{align-items:center;flex-direction:row}.wBVXH4OTNwLHPRpN4nsq{display:flex;flex-grow:1;margin-right:var(--spacing-base)}.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}.urouayitSUT8zW0V3p_0{margin-bottom:0}.iXXJlk08gFDeCvsTTlNQ{border:1px solid var(--jp-gray);border-left:6px solid var(--jp-red-50);border-radius:var(--jp-border-radius);box-shadow:0 4px 8px rgba(0,0,0,.03),0 1px 2px rgba(0,0,0,.06);box-sizing:border-box;color:var(--jp-gray-80);font-size:16px;line-height:22px;margin:0;padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3) calc(var(--spacing-base)*2) calc(var(--spacing-base)*3)}.iXXJlk08gFDeCvsTTlNQ.is-error{background-color:var(--jp-white)}.iXXJlk08gFDeCvsTTlNQ .components-notice__content{align-items:flex-start;display:flex;flex-direction:column;margin:0;padding:12px 4px}.iXXJlk08gFDeCvsTTlNQ .is-link{color:var(--jp-black);font-size:16px;font-weight:600}.iXXJlk08gFDeCvsTTlNQ .components-notice__dismiss{align-self:center}.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk,.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk:active,.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk:hover,.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk:visited{align-items:center;background:#000;border-radius:var(--jp-border-radius);color:var(--jp-white);cursor:pointer;font-size:16px;font-weight:600;justify-content:center;letter-spacing:-.01em;line-height:24px;margin-left:calc(var(--spacing-base)*2 + 24px);margin-top:24px;padding:8px 24px;text-decoration:none}.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk,.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk:active,.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk:hover,.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk:visited{margin-left:0;margin-top:0;white-space:nowrap}.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .components-notice__content{align-items:center;flex-direction:row}.e6hHy8BZ7ZKPSXbIC0UG{margin-bottom:25px}.jXz8LnXNzMDdtHqkG0sZ{display:flex;flex-grow:1;margin-right:var(--spacing-base)}.jXz8LnXNzMDdtHqkG0sZ>svg{align-self:flex-start;flex-shrink:0}.jXz8LnXNzMDdtHqkG0sZ .jp-components-spinner,.jXz8LnXNzMDdtHqkG0sZ>svg{margin-right:calc(var(--spacing-base)*2)}@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%}.sexr0jUxC1jVixdKiDnC{margin-left:-20px}@media(max-width:782px){.sexr0jUxC1jVixdKiDnC{margin-left:-10px}}.sexr0jUxC1jVixdKiDnC.vKQ11sLeAM45M04P1ccj{background-color:var(--jp-white)}.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}}.jp-dashboard-footer{align-items:center;color:#000;display:flex;flex-flow:row wrap;justify-content:space-between;max-width:1128px;width:100%}.jp-dashboard-footer a,.jp-dashboard-footer a:hover,.jp-dashboard-footer a:visited{color:#000;text-decoration:none}.jp-dashboard-footer__jetpack-symbol,.jp-dashboard-footer__module-name{display:inline-block;vertical-align:middle}.jp-dashboard-footer__module-name{font-size:12px;font-weight:600;margin-left:5px}.vMa4i_Dza2t5Zi_Bw9Nf{background:var(--jp-white-off)}.cuoSlhSNrqf1dozY22Xb{fill:#000}.JLquNpQVlysAamuh5lJO,.lAIiifeLMmZAPlQ9n9ZR{fill:var(--jp-green-primary)}.cbOwD8Y4tFjwimmtchQI{fill:#757575}.cbOwD8Y4tFjwimmtchQI.aHOlEBGD5EA8NKRw3xTw{fill:var(--color-facebook);border-radius:50%!important}.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)}.cAbGtJDGgLubucBnz7vM{background-color:var(--jp-white)}.wiobThfXJCuhGNrbFIT6 a,.wiobThfXJCuhGNrbFIT6 a:active,.wiobThfXJCuhGNrbFIT6 a:hover{color:var(--jp-black)}.VgAxgahF9bC2M__FiIgV{display:flex;margin-bottom:calc(var(--spacing-base)*3)}.dbRwkMLqcMF67njPoAF7{margin-right:8px}.Doju0RxvvN9JS12mf489{line-height:calc(var(--spacing-base)*3);margin:0 0 var(--spacing-base) 0}.yWUvvF4WJLNDSpMgBMfm{align-items:center;display:flex;flex-wrap:wrap;margin:0 auto;max-width:1128px}.ka1fVHj2HOkHjhdoEFOZ{grid-gap:24px;display:grid;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}.components-popover:not(.is-without-arrow):before{border-color:var(--jp-gray)}.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}.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}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .MdTRfQ3eo5qZKChZlzNj{width:32px}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .PbEpL02SEH9VNAlbKCfV{width:30px}.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 .rq8YRaj9OyUUXJUHiUgI{border-color:var(--jp-red)}.kezuOHNvu9vdvlJ86Fwg .YZ7FNKEm9qpvQ4ZkbAz5{transform:rotate(180deg)}.kezuOHNvu9vdvlJ86Fwg .oH9tzGE80LnB6Og69RFz{margin-bottom:var(--spacing-base)}.kezuOHNvu9vdvlJ86Fwg .oH9tzGE80LnB6Og69RFz,.kezuOHNvu9vdvlJ86Fwg .xXVEWvQllVsFGmJY8WEp{align-items:center;display:flex;gap:var(--spacing-base)}.kezuOHNvu9vdvlJ86Fwg .xXVEWvQllVsFGmJY8WEp.J0GIu2rNR7rXocQTyd8p{fill:var(--jp-red);color:var(--jp-red)}.jp-connection__manage-dialog{--spacing-base:8px;border-radius:3px;margin:auto;width:1200px}.jp-connection__manage-dialog__content{align-items:center;background:var(--jp-white-off);display:flex;flex-direction:column;justify-content:center;padding:80px;text-align:center}.jp-connection__manage-dialog__content h1{font-size:var(--font-title-large);font-weight:700;line-height:1.2;margin:0}.jp-connection__manage-dialog__large-text{font-size:1.25rem;font-weight:600;margin-bottom:calc(var(--spacing-base)*4);margin-top:calc(var(--spacing-base)*3);max-width:60%}.jp-connection__manage-dialog__actions{align-items:center;background:var(--jp-white);border-top:1px solid var(--jp-gray);bottom:0;box-sizing:border-box;margin:0!important;max-width:1200px!important;padding:calc(var(--spacing-base)*4) calc(var(--spacing-base)*5);position:sticky}.jp-connection__manage-dialog__link{color:var(--jp-black)}.jp-connection__manage-dialog__link:hover{color:var(--jp-black);text-decoration-thickness:var(--jp-underline-thickness)}.jp-connection__manage-dialog__link:focus{color:var(--jp-black)}.jp-connection__manage-dialog__button-wrap button{float:right}.jp-connection__manage-dialog__action-card{background-color:var(--jp-white);border:none;border-radius:3px;box-shadow:0 0 15px var(--jp-gray-off);margin:var(--spacing-base) auto;max-width:100%;padding:1rem 2rem;text-align:left;width:750px}.jp-connection__manage-dialog__action-card__card-headline{font-size:var(--font-body);font-weight:600;line-height:calc(var(--spacing-base)*3);text-decoration:none}.jp-connection__manage-dialog__action-card__icon{float:right}.jp-connection__manage-dialog__action-card .transfer{fill:var(--jp-black);color:var(--jp-black)}.jp-connection__manage-dialog__action-card .disconnect{fill:var(--jp-red);color:var(--jp-red)}.jp-connection__manage-dialog .components-modal__header{display:none}.jp-connection__manage-dialog .components-modal__content{margin:0;padding:0}.jp-connection__disconnect-dialog h1{font-size:var(--font-title-small);font-weight:600;line-height:1.2;margin-top:0}.jp-connection__disconnect-dialog h2{font-size:var(--font-title-small);font-weight:400;line-height:1.2;margin:0}.jp-connection__disconnect-dialog p{font-size:var(--font-body);margin-top:0}.jp-connection__disconnect-dialog p.jp-connection__disconnect-dialog__large-text,.jp-connection__disconnect-dialog__large-text{font-size:1.25rem}.jp-connection__disconnect-dialog .jp-connection__disconnect-dialog__link,.jp-connection__disconnect-dialog__link{color:var(--jp-black);font-size:var(--font-body);font:inherit;height:auto;padding:0;text-decoration:underline}.jp-connection__disconnect-dialog .jp-connection__disconnect-dialog__link:hover,.jp-connection__disconnect-dialog__link:hover{color:var(--jp-black);text-decoration-thickness:var(--jp-underline-thickness)}.jp-connection__disconnect-dialog .jp-connection__disconnect-dialog__link:focus,.jp-connection__disconnect-dialog__link:focus{box-shadow:none!important;color:var(--jp-black)}.jp-connection__disconnect-dialog .jp-connection__disconnect-dialog__link--bold,.jp-connection__disconnect-dialog__link--bold{font-weight:700}.jp-connection__disconnect-dialog .components-button{border-radius:4px;font-size:var(--font-body-small);height:40px}.jp-connection__disconnect-dialog .components-modal__content{display:flex;flex-direction:column;flex-grow:1;margin:0;padding:0}.jp-connection__disconnect-dialog .components-modal__content:before,.jp-connection__disconnect-dialog .components-modal__header{display:none}.jp-connection__disconnect-dialog .jp-row{align-items:center;width:calc(100% - 48px)}.jp-connection__disconnect-dialog__content{align-items:center;background:var(--jp-white-off);border-radius:4px;display:flex;flex-direction:column;flex-grow:1;justify-content:center;margin:0;padding:2rem 1rem;text-align:center}.jp-connection__disconnect-dialog__actions{background:var(--jp-white);border-top:1px solid var(--jp-gray);bottom:0;padding:2rem 0;position:sticky}.jp-connection__disconnect-dialog__actions p{margin-bottom:0}.jp-connection__disconnect-dialog__actions:before{background:linear-gradient(to bottom,transparent,var(--jp-white-off));bottom:calc(100% + 1px);content:"";display:block;height:80px;left:0;position:absolute;width:100%}.jp-connection__disconnect-dialog__btn-dismiss,.jp-connection__disconnect-dialog__btn-dismiss.components-button{background:var(--jp-black)!important;margin-right:10px}.jp-connection__disconnect-dialog__btn-disconnect{background:var(--jp-red)!important}.jp-connection__disconnect-dialog__btn-back-to-wp{background:var(--jp-black)!important}.jp-connection__disconnect-dialog__button-wrap{text-align:left}@media(min-width:960px){.jp-connection__disconnect-dialog__button-wrap{text-align:center}}.jp-connection__disconnect-dialog__error{color:var(--jp-red)}.jp-connection__disconnect-dialog__survey{margin-bottom:1.5rem;max-width:100%}.jp-connection__disconnect-dialog__step-copy{margin:0 auto;max-width:800px}.jp-connection__disconnect-dialog__step-copy--narrow{max-width:600px}@media(max-height:900px){.jp-connection__disconnect-dialog__content .jp-components__decorative-card{display:none}}@media(min-width:600px){.jp-connection__disconnect-dialog,.jp-connection__disconnect-dialog.components-modal__frame{max-width:calc(100% - 32px);width:100%}.jp-connection__disconnect-dialog__actions,.jp-connection__disconnect-dialog__content{padding:2rem}}@media(min-width:960px){.jp-connection__disconnect-dialog,.jp-connection__disconnect-dialog.components-modal__frame{display:flex;flex-direction:column;height:900px;width:1200px}.jp-connection__disconnect-dialog h1{font-size:var(--font-title-large)}.jp-connection__disconnect-dialog p.jp-connection__disconnect-dialog__large-text,.jp-connection__disconnect-dialog__large-text{font-size:1.5rem}.jp-connection__disconnect-dialog__content{padding:80px}.jp-connection__disconnect-dialog__actions{padding:2rem 3rem}.jp-row{margin-left:0}}.jp-connection__disconnect-card{background-color:var(--jp-white);border:none;border-radius:3px;box-shadow:0 0 15px var(--jp-gray-off);margin:0 auto 1rem;max-width:100%;padding:1rem 2rem;text-align:left;width:800px}.jp-connection__disconnect-card__group{margin-bottom:1rem;max-width:100%}.jp-connection__disconnect-card__card-content{display:block;font-size:.875rem}@media only screen and (min-width:782px){.jp-connection__disconnect-card__card-content{align-items:center;display:flex;justify-content:space-between}}.jp-connection__disconnect-card .jp-connection__disconnect-card__card-headline,.jp-connection__disconnect-card__card-headline{flex-shrink:0;font-size:1.25rem;font-weight:600;margin-bottom:0;margin-top:0}@media only screen and (min-width:782px){.jp-connection__disconnect-card .jp-connection__disconnect-card__card-headline,.jp-connection__disconnect-card__card-headline{font-size:1.5rem;margin-right:1.5rem}}@media only screen and (max-width:782px){.jp-connection__disconnect-card .jp-connection__disconnect-card__card-headline+.jp-disconnect-card__card-stat-block,.jp-connection__disconnect-card__card-headline+.jp-disconnect-card__card-stat-block{margin-top:.5rem}}.jp-connection__disconnect-card__card-stat-block{align-items:baseline;display:flex;flex-grow:1}@media only screen and (min-width:782px){.jp-connection__disconnect-card__card-stat-block{flex-direction:row-reverse}}.jp-connection__disconnect-card__card-description{flex-grow:1}@media only screen and (min-width:782px){.jp-connection__disconnect-card__card-description{text-align:right}}.jp-connection__disconnect-card__card-stat{font-size:1rem;font-weight:600;margin-right:.5rem}@media only screen and (min-width:782px){.jp-connection__disconnect-card__card-stat{font-size:1.5rem;margin-left:1rem;margin-right:0}}.jp-components__decorative-card{border-radius:8px;box-shadow:0 0 15px var(--jp-gray);display:flex;height:280px;margin:0 auto 3rem;max-width:100%;overflow:hidden;position:relative;width:360px}.jp-components__decorative-card__content,.jp-components__decorative-card__image{width:50%}.jp-components__decorative-card__image{background:var(--jp-gray);background-size:cover;position:relative}.jp-components__decorative-card__image:before{background-image:url('data:image/svg+xml;uf8,');content:"";display:block;height:8px;left:24px;position:absolute;top:24px;width:38px}.jp-components__decorative-card__content{background:#fff;padding:2rem}.jp-components__decorative-card__icon-container{background:var(--jp-red);border-radius:50px;height:80px;left:50%;position:absolute;top:50%;transform:translate(-50%,-50%);width:80px}.jp-components__decorative-card__icon{background-position:50%,50%;background-repeat:no-repeat;height:40px;left:50%;position:absolute;top:50%;transform:translate(-50%,-50%);width:40px}.jp-components__decorative-card__icon--unlink{background-image:url('data:image/svg+xml;uf8, ')}.jp-components__decorative-card__lines,.jp-components__decorative-card__lines:after,.jp-components__decorative-card__lines:before{background:#e9eff5;border-radius:6px;display:block;height:12px;position:relative;width:100%}.jp-components__decorative-card__lines:after,.jp-components__decorative-card__lines:before{content:"";top:calc(100% + 16px)}.jp-components__decorative-card__lines:after{top:calc(100% + 32px);width:75%}.jp-components__decorative-card--vertical{flex-direction:column}.jp-components__decorative-card--vertical .jp-components__decorative-card__content,.jp-components__decorative-card--vertical .jp-components__decorative-card__image{height:50%;width:100%}.jp-components__decorative-card--vertical .jp-components__decorative-card__lines{margin-left:auto;margin-right:auto;max-width:135px}.jp-components__decorative-card--vertical .jp-components__decorative-card__lines:after,.jp-components__decorative-card--vertical .jp-components__decorative-card__lines:before{margin-left:auto;margin-right:auto}.jp-connect__disconnect-survey-card{border:2px solid transparent;border-radius:4px;box-shadow:0 0 15px var(--jp-gray-off);margin-left:auto;margin-right:auto;max-width:100%;padding:1rem;position:relative;text-align:left;width:800px}.jp-connect__disconnect-survey-card--selected{background:var(--jp-gray-off);border-color:var(--jp-black)}.jp-connect__disconnect-survey-card:after{border-right:2px solid var(--jp-black);border-top:2px solid var(--jp-black);content:"";display:block;height:5px;position:absolute;right:1.5rem;top:50%;transform:translateY(-50%) rotate(45deg);width:5px}.jp-connect__disconnect-survey-card:hover{cursor:pointer}.jp-connect__disconnect-survey-card:focus:not(.jp-disconnect-survey-card--selected),.jp-connect__disconnect-survey-card:hover:not(.jp-disconnect-survey-card--selected){border-color:var(--jp-black-80)}.jp-connect__disconnect-survey-card__answer{align-items:center;display:flex;font-weight:700;margin:0}input.jp-connect__disconnect-survey-card__input{-webkit-appearance:none;background-color:transparent;border:none;color:var(--jp-black-80);flex-grow:1;max-width:calc(100% - 40px);padding-right:40px}.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:16px;width:60%}._RT41NE3LU4R0ubcij2y{align-items:center;display:flex}.cFGWJeRiGHjAr8D7CWJW{margin-right:8px;max-width:110px}.Iz3l7a05TP6HK9S92TIL{width:16px}.lmQ0wFmnk4kKkGVjokPA{height:18px;margin-left:8px}.AoIs8wD92wKR8RpQj6Uc{align-items:center;display:inline-flex}.rV_5QyvhDnsVjCX4pb0h{--gray-90:#1e1e1e;fill:var(--gray-90);width:24px}.MO1jDNY8VPqeNS9xL8jE{align-items:center;display:flex;text-decoration:none}.jp-connection__connect-screen{--spacing-base:8px}.jp-connection__connect-screen__loading{display:none}.jp-connection__connect-screen .terms-of-service{margin-bottom:calc(var(--spacing-base)*3);margin-top:calc(var(--spacing-base)*4);max-width:360px}.jp-connection__connect-screen .terms-of-service a{text-decoration:underline}.jp-connection__connect-screen .jp-action-button{margin-top:40px}.jp-connection__connect-screen .jp-action-button--button{border-radius:4px;font-weight:600}.jp-connection__connect-screen .jp-action-button button{max-width:100%}.jp-connection__connect-screen .jp-action-button button:disabled{color:hsla(0,0%,100%,.4)}@media(max-width:782px){.jp-connection__connect-screen .jp-action-button button{max-width:none;width:100%}}.jp-connection__connect-screen__footer{margin-top:32px}.jp-connection__connect-screen-layout{background:var(--jp-white);border-radius:4px;box-shadow:0 0 40px rgba(0,0,0,.08)}.jp-connection__connect-screen-layout__loading{display:none}.jp-connection__connect-screen-layout__left,.jp-connection__connect-screen-layout__right{box-sizing:border-box}.jp-connection__connect-screen-layout__left{padding:calc(var(--spacing-base)*3)}@media(min-width:600px){.jp-connection__connect-screen-layout__left{padding:64px 96px}}.jp-connection__connect-screen-layout__left .jetpack-logo{margin-bottom:24px}.jp-connection__connect-screen-layout__left h2{color:var(--jp-black);font-size:36px;font-style:normal;font-weight:700;line-height:40px;margin-bottom:0;margin-top:32px}.jp-connection__connect-screen-layout__left h3{color:var(--jp-black);font-size:24px;font-style:normal;font-weight:500;line-height:32px;margin-bottom:0;margin-top:32px}.jp-connection__connect-screen-layout__left li,.jp-connection__connect-screen-layout__left p{font-size:16px;font-style:normal;font-weight:400;line-height:24px}.jp-connection__connect-screen-layout__left p{color:#101517;margin:16px 0}.jp-connection__connect-screen-layout__left a{color:var(--jp-black);font-size:var(--font-body);font:inherit;height:auto;padding:0;text-decoration:underline}.jp-connection__connect-screen-layout__left a:hover{color:var(--jp-black);text-decoration-thickness:var(--jp-underline-thickness)}.jp-connection__connect-screen-layout__left a:focus{box-shadow:none!important;color:var(--jp-black)}.jp-connection__connect-screen-layout__left ul{list-style-type:none;padding:0}.jp-connection__connect-screen-layout__left ul li{background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAMAAABg3Am1AAAANlBMVEVHcEwFnwUInggGnggGnggHnAcAnwUFnQcAnwcGnwkFnQgGnQgFnwcGnQYFnQcFnAcGnQkDnwdhiL0pAAAAEnRSTlMAMF//f2Aw7yBQ3+9gcIBgcED+HDbkAAAAZklEQVR4Ae3LNwICARDDQC0+cv7/Y8mwV9odSfWIcf/+VegnGkIvDaGXKvTTn/Gz+Uf5xTL0K1XotS7fs5H6GHvvaO8d7c3j7rdgHne/A/PYt/cO+R42oYdN6OEQetiFHo4A//6dAXqtBEkmtWutAAAAAElFTkSuQmCC) no-repeat;background-size:24px;color:var(--jp-black);margin-bottom:9px;padding-left:30px}.jp-connection__connect-screen-layout__right{padding:64px 0}.jp-connection__connect-screen-layout__right img{max-width:100%}.jp-connection__connect-screen-layout__two-columns{display:flex;flex-wrap:wrap}.jp-connection__connect-screen-layout__two-columns .jp-connection__connect-screen-layout__left{flex-basis:100%;flex-grow:1}@media(min-width:1080px){.jp-connection__connect-screen-layout__two-columns .jp-connection__connect-screen-layout__left{flex-basis:52%}}.jp-connection__connect-screen-layout__two-columns .jp-connection__connect-screen-layout__right{background:#f9f9f6;display:none;flex-basis:47%;flex-grow:1}@media(min-width:1080px){.jp-connection__connect-screen-layout__two-columns .jp-connection__connect-screen-layout__right{display:block}}.terms-of-service{color:var(--jp-black);font-size:var(--font-body)}.terms-of-service .terms-of-service__link{color:var(--jp-green-50)}.TcCZnGE6mad8Dvz9pCZi{background:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjQiIGhlaWdodD0iMjQiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTEyIDIwYTggOCAwIDEgMCAwLTE2IDggOCAwIDAgMCAwIDE2WiIgc3Ryb2tlPSIjRDYzNjM5IiBzdHJva2Utd2lkdGg9IjEuNSIvPjxwYXRoIGQ9Ik0xMyA3aC0ydjZoMlY3Wk0xMyAxNWgtMnYyaDJ2LTJaIiBmaWxsPSIjRDYzNjM5Ii8+PC9zdmc+) no-repeat 0 0;color:var(--jp-red);line-height:25px;padding-left:25px}._mn6o2Dtm5pfFWc8_A1K{--spacing-base:8px;min-width:264px}.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%}.YcYvLvdvWrb1EUZoVsE8{display:flex;flex-wrap:wrap;gap:calc(var(--horizontal-spacing)*2);justify-content:space-between}.uGTTsKoIOoZdYhk6uPnl{white-space:nowrap}.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}.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)}.sEcLfpWjo0GF7QrxD3Lt{margin-top:calc(var(--spacing-base)*2)}.xgv3jRkeF39aEQELCwru{align-items:flex-end;color:var(--jp-text-color);display:flex;flex-wrap:wrap}.twlleZ5Ehq4bB7CvKVSW{position:relative}.twlleZ5Ehq4bB7CvKVSW:first-child{margin-right:calc(var(--spacing-base)*2)}.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)}.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)}.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{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{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{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-error{align-items:flex-start;color:var(--jp-red);display:flex;flex-direction:row;max-width:500px}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-error svg{fill:var(--jp-red);margin-right:4px;min-width:24px}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-error span{font-size:var(--font-body)}.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%}.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-wrap{align-items:center;display:flex;flex-wrap:wrap;margin:0 auto;max-width:1128px}.jp-row{grid-gap:24px;display:grid;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}.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}}: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-10:#f2cf75;--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-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}body{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;margin:0;min-height:100%;padding:0}.EiaNctK1_P9pPqOeiaSI{align-items:center;display:flex;flex-wrap:wrap;margin:0 auto;max-width:1128px}.ogHZg_sJCljylz3VJfsf{grid-gap:24px;display:grid;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{fill:#fff;transition:fill 2s ease .5s}.gfM_DIJrVbRhmKdAphIm.pnwbCuWbV0PNQr1LFpRh .zfJfONxRAw0fHjXUS7LN path.FCnyb_xCK7DhJ63p6TEd{fill:#000;transition:fill 2s ease .5s}}@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{container-type:inline-size;align-items:flex-end;bottom:5%;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)}}.jp-license-activation-screen{border-radius:4px;box-shadow:0 4px 24px 0 #00000026;display:flex;flex-direction:column;min-height:540px;overflow:hidden}@media screen and (min-width:780px){.jp-license-activation-screen{flex-direction:row}} \ 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 45ac6f5a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.js +++ /dev/null @@ -1,20 +0,0 @@ -/*! For license information please see index.js.LICENSE.txt */ -(()=>{var e={9487:(e,t,n)=>{"use strict";n.d(t,{X:()=>a});const c={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 a(e){return c[e]||{symbol:"$",grouping:",",decimal:".",precision:2}}},8899:(e,t,n)=>{"use strict";n.d(t,{LR:()=>r});var c=n(9487),a=n(2003);function r(e,t,n={}){const r=(0,c.X)(t);if(!r||isNaN(e))return null;const{decimal:o,grouping:s,precision:i,symbol:l}={...r,...n},p=e<0?"-":"",u=Math.abs(e),d=Math.floor(u);return{sign:p,symbol:l,integer:(0,a.Z)(u,i,o,s).split(o)[0],fraction:i>0?(0,a.Z)(u-d,i,o,s).slice(1):""}}},2003:(e,t,n)=>{"use strict";function c(e,t=0,n=".",c=","){const a=(e+"").replace(/[^0-9+\-Ee.]/g,""),r=isFinite(+a)?+a:0,o=isFinite(+t)?Math.abs(t):0,s=(o?function(e,t){const n=Math.pow(10,t);return""+(Math.round(e*n)/n).toFixed(t)}(r,o):""+Math.round(r)).split(".");return s[0].length>3&&(s[0]=s[0].replace(/\B(?=(?:\d{3})+(?!\d))/g,c)),(s[1]||"").lengthc})},3170:(e,t,n)=>{"use strict";function c(){return c=Object.assign?Object.assign.bind():function(e){for(var t=1;tu,RQ:()=>U,WK:()=>M,Zn:()=>P,Zq:()=>L,aU:()=>a,cP:()=>d,fp:()=>y,kG:()=>s,pC:()=>I,q_:()=>o}),function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"}(a||(a={}));const r="popstate";function o(e){return void 0===e&&(e={}),g((function(e,t){let{pathname:n="/",search:c="",hash:a=""}=d(e.location.hash.substr(1));return p("",{pathname:n,search:c,hash:a},t.state&&t.state.usr||null,t.state&&t.state.key||"default")}),(function(e,t){let n=e.document.querySelector("base"),c="";if(n&&n.getAttribute("href")){let t=e.location.href,n=t.indexOf("#");c=-1===n?t:t.slice(0,n)}return c+"#"+("string"==typeof t?t:u(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 l(e){return{usr:e.state,key:e.key}}function p(e,t,n,a){return void 0===n&&(n=null),c({pathname:"string"==typeof e?e:e.pathname,search:"",hash:""},"string"==typeof t?d(t):t,{state:n,key:t&&t.key||a||Math.random().toString(36).substr(2,8)})}function u(e){let{pathname:t="/",search:n="",hash:c=""}=e;return n&&"?"!==n&&(t+="?"===n.charAt(0)?n:"?"+n),c&&"#"!==c&&(t+="#"===c.charAt(0)?c:"#"+c),t}function d(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let c=e.indexOf("?");c>=0&&(t.search=e.substr(c),e=e.substr(0,c)),e&&(t.pathname=e)}return t}function m(e){let t="undefined"!=typeof window&&void 0!==window.location&&"null"!==window.location.origin?window.location.origin:window.location.href,n="string"==typeof e?e:u(e);return s(t,"No window.location.(origin|href) available to create URL for href: "+n),new URL(n,t)}function g(e,t,n,c){void 0===c&&(c={});let{window:o=document.defaultView,v5Compat:s=!1}=c,i=o.history,d=a.Pop,g=null;function h(){d=a.Pop,g&&g({action:d,location:y.location})}let y={get action(){return d},get location(){return e(o,i)},listen(e){if(g)throw new Error("A history only accepts one active listener");return o.addEventListener(r,h),g=e,()=>{o.removeEventListener(r,h),g=null}},createHref:e=>t(o,e),encodeLocation(e){let t=m("string"==typeof e?e:u(e));return{pathname:t.pathname,search:t.search,hash:t.hash}},push:function(e,t){d=a.Push;let c=p(y.location,e,t);n&&n(c,e);let r=l(c),u=y.createHref(c);try{i.pushState(r,"",u)}catch(e){o.location.assign(u)}s&&g&&g({action:d,location:y.location})},replace:function(e,t){d=a.Replace;let c=p(y.location,e,t);n&&n(c,e);let r=l(c),o=y.createHref(c);i.replaceState(r,"",o),s&&g&&g({action:d,location:y.location})},go:e=>i.go(e)};return y}var h;function y(e,t,n){void 0===n&&(n="/");let c=P(("string"==typeof t?d(t):t).pathname||"/",n);if(null==c)return null;let a=f(e);!function(e){e.sort(((e,t)=>e.score!==t.score?t.score-e.score:function(e,t){let n=e.length===t.length&&e.slice(0,-1).every(((e,n)=>e===t[n]));return n?e[e.length-1]-t[t.length-1]:0}(e.routesMeta.map((e=>e.childrenIndex)),t.routesMeta.map((e=>e.childrenIndex)))))}(a);let r=null;for(let e=0;null==r&&e{let o={relativePath:void 0===r?e.path||"":r,caseSensitive:!0===e.caseSensitive,childrenIndex:a,route:e};o.relativePath.startsWith("/")&&(s(o.relativePath.startsWith(c),'Absolute route path "'+o.relativePath+'" nested under path "'+c+'" is not valid. An absolute child route path must start with the combined path of all its parent routes.'),o.relativePath=o.relativePath.slice(c.length));let i=U([c,o.relativePath]),l=n.concat(o);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+'".'),f(e.children,t,l,i)),(null!=e.path||e.index)&&t.push({path:i,score:Z(i,e.index),routesMeta:l})};return e.forEach(((e,t)=>{var n;if(""!==e.path&&null!=(n=e.path)&&n.includes("?"))for(let n of k(e.path))a(e,t,n);else a(e,t)})),t}function k(e){let t=e.split("/");if(0===t.length)return[];let[n,...c]=t,a=n.endsWith("?"),r=n.replace(/\?$/,"");if(0===c.length)return a?[r,""]:[r];let o=k(c.join("/")),s=[];return s.push(...o.map((e=>""===e?r:[r,e].join("/")))),a&&s.push(...o),s.map((t=>e.startsWith("/")&&""===t?"/":t))}!function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"}(h||(h={}));const v=/^:\w+$/,E=3,b=2,j=1,_=10,C=-2,w=e=>"*"===e;function Z(e,t){let n=e.split("/"),c=n.length;return n.some(w)&&(c+=C),t&&(c+=b),n.filter((e=>!w(e))).reduce(((e,t)=>e+(v.test(t)?E:""===t?j:_)),c)}function N(e,t){let{routesMeta:n}=e,c={},a="/",r=[];for(let e=0;e(c.push(t),"/([^\\/]+)")));e.endsWith("*")?(c.push("*"),a+="*"===e||"/*"===e?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?a+="\\/*$":""!==e&&"/"!==e&&(a+="(?:(?=\\/|$))");let r=new RegExp(a,t?void 0:"i");return[r,c]}(e.path,e.caseSensitive,e.end),a=t.match(n);if(!a)return null;let r=a[0],o=r.replace(/(.)\/+$/,"$1"),s=a.slice(1);return{params:c.reduce(((e,t,n)=>{if("*"===t){let e=s[n]||"";o=r.slice(0,r.length-e.length).replace(/(.)\/+$/,"$1")}return e[t]=function(e,t){try{return decodeURIComponent(e)}catch(n){return x(!1,'The value for the URL param "'+t+'" will not be decoded because the string "'+e+'" is a malformed URL segment. This is probably due to a bad percent encoding ('+n+")."),e}}(s[n]||"",t),e}),{}),pathname:r,pathnameBase:o,pattern:e}}function R(e){try{return decodeURI(e)}catch(t){return x(!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 P(e,t){if("/"===t)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,c=e.charAt(n);return c&&"/"!==c?null:e.slice(n)||"/"}function x(e,t){if(!e){"undefined"!=typeof console&&console.warn(t);try{throw new Error(t)}catch(e){}}}function A(e,t,n,c){return"Cannot include a '"+e+"' character in a manually specified `to."+t+"` field ["+JSON.stringify(c)+"]. Please separate it out to the `to."+n+'` 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 I(e,t,n,a){let r;void 0===a&&(a=!1),"string"==typeof e?r=d(e):(r=c({},e),s(!r.pathname||!r.pathname.includes("?"),A("?","pathname","search",r)),s(!r.pathname||!r.pathname.includes("#"),A("#","pathname","hash",r)),s(!r.search||!r.search.includes("#"),A("#","search","hash",r)));let o,i=""===e||""===r.pathname,l=i?"/":r.pathname;if(a||null==l)o=n;else{let e=t.length-1;if(l.startsWith("..")){let t=l.split("/");for(;".."===t[0];)t.shift(),e-=1;r.pathname=t.join("/")}o=e>=0?t[e]:"/"}let p=function(e,t){void 0===t&&(t="/");let{pathname:n,search:c="",hash:a=""}="string"==typeof e?d(e):e,r=n?n.startsWith("/")?n:function(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach((e=>{".."===e?n.length>1&&n.pop():"."!==e&&n.push(e)})),n.length>1?n.join("/"):"/"}(n,t):t;return{pathname:r,search:O(c),hash:F(a)}}(r,o),u=l&&"/"!==l&&l.endsWith("/"),m=(i||"."===l)&&n.endsWith("/");return p.pathname.endsWith("/")||!u&&!m||(p.pathname+="/"),p}const U=e=>e.join("/").replace(/\/\/+/g,"/"),T=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),O=e=>e&&"?"!==e?e.startsWith("?")?e:"?"+e:"",F=e=>e&&"#"!==e?e.startsWith("#")?e:"#"+e:"";class D extends Error{}class z{constructor(e,t,n,c){void 0===c&&(c=!1),this.status=e,this.statusText=t||"",this.internal=c,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}}function M(e){return e instanceof z}const V=["post","put","patch","delete"],B=(new Set(V),["get",...V]);new Set(B),new Set([301,302,303,307,308]),new Set([307,308]),"undefined"!=typeof window&&void 0!==window.document&&window.document.createElement},1074:(e,t,n)=>{"use strict";n.d(t,{Z:()=>a});var c=n(9307);const a=function(e){let{icon:t,size:n=24,...a}=e;return(0,c.cloneElement)(t,{width:n,height:n,...a})}},3259:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9307),a=n(444);const r=(0,c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,c.createElement)(a.Path,{d:"M20 11.2H6.8l3.7-3.7-1-1L3.9 12l5.6 5.5 1-1-3.7-3.7H20z"}))},9201:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9307),a=n(444);const r=(0,c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,c.createElement)(a.Path,{d:"M16.7 7.1l-6.3 8.5-3.3-2.5-.9 1.2 4.5 3.4L17.9 8z"}))},6936:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9307),a=n(444);const r=(0,c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,c.createElement)(a.Path,{d:"M10.6 6L9.4 7l4.6 5-4.6 5 1.2 1 5.4-6z"}))},9517:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9307),a=n(444);const r=(0,c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,c.createElement)(a.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"}))},5381:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9307),a=n(444);const r=(0,c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,c.createElement)(a.Path,{d:"M18.2 17c0 .7-.6 1.2-1.2 1.2H7c-.7 0-1.2-.6-1.2-1.2V7c0-.7.6-1.2 1.2-1.2h3.2V4.2H7C5.5 4.2 4.2 5.5 4.2 7v10c0 1.5 1.2 2.8 2.8 2.8h10c1.5 0 2.8-1.2 2.8-2.8v-3.6h-1.5V17zM14.9 3v1.5h3.7l-6.4 6.4 1.1 1.1 6.4-6.4v3.7h1.5V3h-6.3z"}))},496:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9307),a=n(444);const r=(0,c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,c.createElement)(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"}))},1908:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9307),a=n(444);const r=(0,c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,c.createElement)(a.Path,{d:"M18 11.2h-5.2V6h-1.6v5.2H6v1.6h5.2V18h1.6v-5.2H18z"}))},797:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9307),a=n(444);const r=(0,c.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24"},(0,c.createElement)(a.Path,{d:"M10 2c4.42 0 8 3.58 8 8s-3.58 8-8 8-8-3.58-8-8 3.58-8 8-8zm1.13 9.38l.35-6.46H8.52l.35 6.46h2.26zm-.09 3.36c.24-.23.37-.55.37-.96 0-.42-.12-.74-.36-.97s-.59-.35-1.06-.35-.82.12-1.07.35-.37.55-.37.97c0 .41.13.73.38.96.26.23.61.34 1.06.34s.8-.11 1.05-.34z"}))},5235:(e,t)=>{var n;!function(){"use strict";var c={}.hasOwnProperty;function a(){for(var e=[],t=0;t{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 n="color: "+this.color;t.splice(1,0,n,"color: inherit");let c=0,a=0;t[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(c++,"%c"===e&&(a=c))})),t.splice(a,0,n)},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;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&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$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=n(1741)(t);const{formatters:c}=e.exports;c.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},1741:(e,t,n)=>{e.exports=function(e){function t(e){let n,a,r,o=null;function s(...e){if(!s.enabled)return;const c=s,a=Number(new Date),r=a-(n||a);c.diff=r,c.prev=n,c.curr=a,n=a,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let o=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((n,a)=>{if("%%"===n)return"%";o++;const r=t.formatters[a];if("function"==typeof r){const t=e[o];n=r.call(c,t),e.splice(o,1),o--}return n})),t.formatArgs.call(c,e);(c.log||t.log).apply(c,e)}return s.namespace=e,s.useColors=t.useColors(),s.color=t.selectColor(e),s.extend=c,s.destroy=t.destroy,Object.defineProperty(s,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==o?o:(a!==t.namespaces&&(a=t.namespaces,r=t.enabled(e)),r),set:e=>{o=e}}),"function"==typeof t.init&&t.init(s),s}function c(e,n){const c=t(this.namespace+(void 0===n?":":n)+e);return c.log=this.log,c}function a(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return t.debug=t,t.default=t,t.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},t.disable=function(){const e=[...t.names.map(a),...t.skips.map(a).map((e=>"-"+e))].join(",");return t.enable(""),e},t.enable=function(e){let n;t.save(e),t.namespaces=e,t.names=[],t.skips=[];const c=("string"==typeof e?e:"").split(/[\s,]+/),a=c.length;for(n=0;n{t[n]=e[n]})),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let n=0;for(let t=0;t{"use strict";n.d(t,{Z:()=>c});const c={error:"TcCZnGE6mad8Dvz9pCZi",button:"_mn6o2Dtm5pfFWc8_A1K"}},1494:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={"admin-page":"sexr0jUxC1jVixdKiDnC",background:"vKQ11sLeAM45M04P1ccj"}},511:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={section:"cAbGtJDGgLubucBnz7vM"}},281:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={"section-hero":"vMa4i_Dza2t5Zi_Bw9Nf"}},9171:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={container:"demNsMJjhi7BLY7xhjU5","icon-wrapper":"QiUjdjJSkqh6nH7YMG5A","is-error":"Q080AHcq29J2fc68Hhk5",icon:"hYWbIwhppukXmGnsiT9H","is-warning":"JjHuxWly0HI9C60gorbq","is-info":"Cm8ZFHi3mngl4cj9Gatx","is-success":"ytGBsU015p3LGwOPwFDx"}},3466:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={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"}},2404:()=>{},5612:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={"star-icon":"cuoSlhSNrqf1dozY22Xb",jetpack:"lAIiifeLMmZAPlQ9n9ZR","checkmark-icon":"JLquNpQVlysAamuh5lJO",socialIcon:"cbOwD8Y4tFjwimmtchQI",facebook:"aHOlEBGD5EA8NKRw3xTw",twitter:"af4Y_zItXvLAOEoSDPSv",linkedin:"f68aqF3XSD1OBvXR1get",tumblr:"xFI0dt3UiXRlRQdqPWkx",google:"q7JEoyymveP6kF747M43",mastodon:"DKOBOTVmTLbh26gUH_73"}},9054:()=>{},3247:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={sm:"(max-width: 599px)",md:"(min-width: 600px) and (max-width: 959px)",lg:"(min-width: 960px)"}},3080:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={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"}},8730:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={sm:"(max-width: 599px)",md:"(min-width: 600px) and (max-width: 959px)",lg:"(min-width: 960px)",container:"SqdhUZkXCRuIpErj1B3z",fluid:"OZC_9a1LhpWF9dv15Gdh"}},1683:()=>{},7920:()=>{},3280:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={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"}},3591:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={global:"_fUXxnSp5pagKBp9gSN7"}},1510:()=>{},9610:()=>{},9836:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={heading:"urouayitSUT8zW0V3p_0",notice:"iXXJlk08gFDeCvsTTlNQ",button:"MWqRqr7q6fgvLxitcWYk","bigger-than-medium":"YLcXAoc82nypTPaKSAcd",error:"e6hHy8BZ7ZKPSXbIC0UG",message:"jXz8LnXNzMDdtHqkG0sZ"}},4220:()=>{},287:()=>{},9823:()=>{},7664:()=>{},1008:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={"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"}},6234:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={icon:"rV_5QyvhDnsVjCX4pb0h",link:"MO1jDNY8VPqeNS9xL8jE"}},8578:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={"relative-col":"zvd4dCB_bBDiXJKKDqXm","close-link":"ly4o9lSswAGHFXqGUEIO","account-description":"u64Go3kwEZ7MD9eji0H1","account-images":"_RT41NE3LU4R0ubcij2y",wordpress:"cFGWJeRiGHjAr8D7CWJW",google:"Iz3l7a05TP6HK9S92TIL",apple:"lmQ0wFmnk4kKkGVjokPA","all-features":"AoIs8wD92wKR8RpQj6Uc"}},6322:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={"connection-status-card":"kezuOHNvu9vdvlJ86Fwg",status:"qJizORs2q_CVCj9L6XLe","avatar-wrapper":"VmtuLc2xRqmsO6cK8qjF",cloud:"MdTRfQ3eo5qZKChZlzNj",jetpack:"PbEpL02SEH9VNAlbKCfV",avatar:"TD4AUM9gcTVAB6JHB5ZR",line:"yjl73qv0VWoPP8IhGreh",disconnected:"rq8YRaj9OyUUXJUHiUgI",info:"YZ7FNKEm9qpvQ4ZkbAz5","list-item":"oH9tzGE80LnB6Og69RFz","list-item-text":"xXVEWvQllVsFGmJY8WEp",error:"J0GIu2rNR7rXocQTyd8p"}},197:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={icon:"hdasSNj9k3Sc5PwXK4uE",link:"eWN8Hj0SBRDq1F48n_Fg"}},1854:()=>{},4416:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={"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"}},1017:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={heading:"jErCC9oKHSM15BxzFyQK",notice:"oVoYbwbFB6U2o90Njusk","bigger-than-medium":"Snc8NEmDelsbhlH4285s",message:"wBVXH4OTNwLHPRpN4nsq",nofill:"F1qvEnFfHs5nz3zFZUOV"}},6891:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={container:"wiobThfXJCuhGNrbFIT6","expire-date":"VgAxgahF9bC2M__FiIgV","expire-date--with-icon":"dbRwkMLqcMF67njPoAF7","actions-list-item":"Doju0RxvvN9JS12mf489"}},9720:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={container:"pIsYsXFAJ9KX2VrS5rmY","is-link":"YXHdD0VsFjiTsVRLrrx9","has-error":"Pp9cMIaESLYelLOX3tkI",name:"w56ueQLYexqzTybA7015",description:"gmPKCDKZcfQt9WieTyKS",actions:"fDBaV7I4yUO6w5AWVEtr",status:"f5VJYwuJmjxH8PVxEbbv",active:"ry3pxoGtmQ0ZeSwp7F_3",inactive:"LZzE3EG7m3CDR46wwwEr",error:"Vx_jpT02r8W6NfsRSB02","is-fetching":"PdsJCfyyjSgrNDheF2qi","blink-animation":"dWP7ypkVXudMbAa38W5Z"}},8429:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={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",disclaimers:"sEcLfpWjo0GF7QrxD3Lt","price-container":"xgv3jRkeF39aEQELCwru",price:"twlleZ5Ehq4bB7CvKVSW","is-old":"Qg4rPEvXsqmod1s_31d8","price-description":"ApsgxIornVy_3KnciVeJ","supporting-info":"NMxcZL17aEP7v81uG3zD"}},1287:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={container:"SWwV4Pw6OZ5vU3PqPXmr",imageContainer:"r7tUofa9Z3A5ziKVR1H7","product-interstitial__header":"YcYvLvdvWrb1EUZoVsE8","product-interstitial__license-activation-link":"uGTTsKoIOoZdYhk6uPnl"}},5878:()=>{},3171:e=>{var t=1e3,n=60*t,c=60*n,a=24*c,r=7*a,o=365.25*a;function s(e,t,n,c){var a=t>=1.5*n;return Math.round(e/n)+" "+c+(a?"s":"")}e.exports=function(e,i){i=i||{};var l=typeof e;if("string"===l&&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*o;case"weeks":case"week":case"w":return i*r;case"days":case"day":case"d":return i*a;case"hours":case"hour":case"hrs":case"hr":case"h":return i*c;case"minutes":case"minute":case"mins":case"min":case"m":return i*n;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"===l&&isFinite(e))return i.long?function(e){var r=Math.abs(e);if(r>=a)return s(e,r,a,"day");if(r>=c)return s(e,r,c,"hour");if(r>=n)return s(e,r,n,"minute");if(r>=t)return s(e,r,t,"second");return e+" ms"}(e):function(e){var r=Math.abs(e);if(r>=a)return Math.round(e/a)+"d";if(r>=c)return Math.round(e/c)+"h";if(r>=n)return Math.round(e/n)+"m";if(r>=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))}},7556:(e,t,n)=>{"use strict";var c=n(3713);function a(){}function r(){}r.resetWarningCache=a,e.exports=function(){function e(e,t,n,a,r,o){if(o!==c){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 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:r,resetWarningCache:a};return n.PropTypes=n,n}},5844:(e,t,n)=>{e.exports=n(7556)()},3713:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},469:(e,t,n)=>{"use strict";var c=n(758);function a(){}function r(){}r.resetWarningCache=a,e.exports=function(){function e(e,t,n,a,r,o){if(o!==c){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 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:r,resetWarningCache:a};return n.PropTypes=n,n}},5162:(e,t,n)=>{e.exports=n(469)()},758:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},9997:(e,t,n)=>{"use strict";n.d(t,{UT:()=>p,lr:()=>g,rU:()=>u});var c=n(9196),a=n(6417),r=n(3170);function o(){return o=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(a[n]=e[n]);return a}function i(e){return void 0===e&&(e=""),new URLSearchParams("string"==typeof e||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce(((t,n)=>{let c=e[n];return t.concat(Array.isArray(c)?c.map((e=>[n,e])):[[n,c]])}),[]))}const l=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset"];function p(e){let{basename:t,children:n,window:o}=e,s=c.useRef();null==s.current&&(s.current=(0,r.q_)({window:o,v5Compat:!0}));let i=s.current,[l,p]=c.useState({action:i.action,location:i.location});return c.useLayoutEffect((()=>i.listen(p)),[i]),c.createElement(a.F0,{basename:t,children:n,location:l.location,navigationType:l.action,navigator:i})}const u=c.forwardRef((function(e,t){let{onClick:n,relative:i,reloadDocument:p,replace:u,state:d,target:m,to:g,preventScrollReset:h}=e,y=s(e,l),f=(0,a.oQ)(g,{relative:i}),k=function(e,t){let{target:n,replace:o,state:s,preventScrollReset:i,relative:l}=void 0===t?{}:t,p=(0,a.s0)(),u=(0,a.TH)(),d=(0,a.WU)(e,{relative:l});return c.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,n)){t.preventDefault();let n=void 0!==o?o:(0,r.Ep)(u)===(0,r.Ep)(d);p(e,{replace:n,state:s,preventScrollReset:i,relative:l})}}),[u,p,d,o,s,n,e,i,l])}(g,{replace:u,state:d,target:m,preventScrollReset:h,relative:i});return c.createElement("a",o({},y,{href:f,onClick:p?n:function(e){n&&n(e),e.defaultPrevented||k(e)},ref:t,target:m}))}));var d,m;function g(e){let t=c.useRef(i(e)),n=(0,a.TH)(),r=c.useMemo((()=>function(e,t){let n=i(e);for(let e of t.keys())n.has(e)||t.getAll(e).forEach((t=>{n.append(e,t)}));return n}(n.search,t.current)),[n.search]),o=(0,a.s0)(),s=c.useCallback(((e,t)=>{const n=i("function"==typeof e?e(r):e);o("?"+n,t)}),[o,r]);return[r,s]}(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmitImpl="useSubmitImpl",e.UseFetcher="useFetcher"})(d||(d={})),function(e){e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"}(m||(m={}))},6417:(e,t,n)=>{"use strict";n.d(t,{AW:()=>A,F0:()=>L,TH:()=>b,WU:()=>_,Z5:()=>I,oQ:()=>v,s0:()=>j});var c=n(3170),a=n(9196);function r(){return r=Object.assign?Object.assign.bind():function(e){for(var t=1;t{a.value=c,a.getSnapshot=t,u(a)&&r({inst:a})}),[e,c,t]),i((()=>{u(a)&&r({inst:a});return e((()=>{u(a)&&r({inst:a})}))}),[e]),p(c),c};"useSyncExternalStore"in a&&a.useSyncExternalStore;const m=a.createContext(null);const g=a.createContext(null);const h=a.createContext(null);const y=a.createContext(null);const f=a.createContext({outlet:null,matches:[]});const k=a.createContext(null);function v(e,t){let{relative:n}=void 0===t?{}:t;E()||(0,c.kG)(!1);let{basename:r,navigator:o}=a.useContext(h),{hash:s,pathname:i,search:l}=_(e,{relative:n}),p=i;return"/"!==r&&(p="/"===i?r:(0,c.RQ)([r,i])),o.createHref({pathname:p,search:l,hash:s})}function E(){return null!=a.useContext(y)}function b(){return E()||(0,c.kG)(!1),a.useContext(y).location}function j(){E()||(0,c.kG)(!1);let{basename:e,navigator:t}=a.useContext(h),{matches:n}=a.useContext(f),{pathname:r}=b(),o=JSON.stringify((0,c.Zq)(n).map((e=>e.pathnameBase))),s=a.useRef(!1);return a.useEffect((()=>{s.current=!0})),a.useCallback((function(n,a){if(void 0===a&&(a={}),!s.current)return;if("number"==typeof n)return void t.go(n);let i=(0,c.pC)(n,JSON.parse(o),r,"path"===a.relative);"/"!==e&&(i.pathname="/"===i.pathname?e:(0,c.RQ)([e,i.pathname])),(a.replace?t.replace:t.push)(i,a.state,a)}),[e,t,o,r])}function _(e,t){let{relative:n}=void 0===t?{}:t,{matches:r}=a.useContext(f),{pathname:o}=b(),s=JSON.stringify((0,c.Zq)(r).map((e=>e.pathnameBase)));return a.useMemo((()=>(0,c.pC)(e,JSON.parse(s),o,"path"===n)),[e,s,o,n])}function C(){let e=function(){var e;let t=a.useContext(k),n=P(R.UseRouteError),c=x(R.UseRouteError);if(t)return t;return null==(e=n.errors)?void 0:e[c]}(),t=(0,c.WK)(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,r="rgba(200,200,200, 0.5)",o={padding:"0.5rem",backgroundColor:r},s={padding:"2px 4px",backgroundColor:r};return a.createElement(a.Fragment,null,a.createElement("h2",null,"Unhandled Thrown Error!"),a.createElement("h3",{style:{fontStyle:"italic"}},t),n?a.createElement("pre",{style:o},n):null,a.createElement("p",null,"💿 Hey developer 👋"),a.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",a.createElement("code",{style:s},"errorElement")," props on ",a.createElement("code",{style:s},"")))}class w extends a.Component{constructor(e){super(e),this.state={location:e.location,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location?{error:e.error,location:e.location}:{error:e.error||t.error,location:t.location}}componentDidCatch(e,t){console.error("React Router caught the following error during render",e,t)}render(){return this.state.error?a.createElement(f.Provider,{value:this.props.routeContext},a.createElement(k.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function Z(e){let{routeContext:t,match:n,children:c}=e,r=a.useContext(m);return r&&r.static&&r.staticContext&&n.route.errorElement&&(r.staticContext._deepestRenderedBoundaryId=n.route.id),a.createElement(f.Provider,{value:t},c)}function N(e,t,n){if(void 0===t&&(t=[]),null==e){if(null==n||!n.errors)return null;e=n.matches}let r=e,o=null==n?void 0:n.errors;if(null!=o){let e=r.findIndex((e=>e.route.id&&(null==o?void 0:o[e.route.id])));e>=0||(0,c.kG)(!1),r=r.slice(0,Math.min(r.length,e+1))}return r.reduceRight(((e,c,s)=>{let i=c.route.id?null==o?void 0:o[c.route.id]:null,l=n?c.route.errorElement||a.createElement(C,null):null,p=t.concat(r.slice(0,s+1)),u=()=>a.createElement(Z,{match:c,routeContext:{outlet:e,matches:p}},i?l:void 0!==c.route.element?c.route.element:e);return n&&(c.route.errorElement||0===s)?a.createElement(w,{location:n.location,component:l,error:i,children:u(),routeContext:{outlet:null,matches:p}}):u()}),null)}var S,R;function P(e){let t=a.useContext(g);return t||(0,c.kG)(!1),t}function x(e){let t=function(e){let t=a.useContext(f);return t||(0,c.kG)(!1),t}(),n=t.matches[t.matches.length-1];return n.route.id||(0,c.kG)(!1),n.route.id}!function(e){e.UseRevalidator="useRevalidator"}(S||(S={})),function(e){e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator"}(R||(R={}));function A(e){(0,c.kG)(!1)}function L(e){let{basename:t="/",children:n=null,location:r,navigationType:o=c.aU.Pop,navigator:s,static:i=!1}=e;E()&&(0,c.kG)(!1);let l=t.replace(/^\/*/,"/"),p=a.useMemo((()=>({basename:l,navigator:s,static:i})),[l,s,i]);"string"==typeof r&&(r=(0,c.cP)(r));let{pathname:u="/",search:d="",hash:m="",state:g=null,key:f="default"}=r,k=a.useMemo((()=>{let e=(0,c.Zn)(u,l);return null==e?null:{pathname:e,search:d,hash:m,state:g,key:f}}),[l,u,d,m,g,f]);return null==k?null:a.createElement(h.Provider,{value:p},a.createElement(y.Provider,{children:n,value:{location:k,navigationType:o}}))}function I(e){let{children:t,location:n}=e,o=a.useContext(m);return function(e,t){E()||(0,c.kG)(!1);let{navigator:n}=a.useContext(h),o=a.useContext(g),{matches:s}=a.useContext(f),i=s[s.length-1],l=i?i.params:{},p=(i&&i.pathname,i?i.pathnameBase:"/");i&&i.route;let u,d=b();if(t){var m;let e="string"==typeof t?(0,c.cP)(t):t;"/"===p||(null==(m=e.pathname)?void 0:m.startsWith(p))||(0,c.kG)(!1),u=e}else u=d;let k=u.pathname||"/",v="/"===p?k:k.slice(p.length)||"/",j=(0,c.fp)(e,{pathname:v}),_=N(j&&j.map((e=>Object.assign({},e,{params:Object.assign({},l,e.params),pathname:(0,c.RQ)([p,n.encodeLocation?n.encodeLocation(e.pathname).pathname:e.pathname]),pathnameBase:"/"===e.pathnameBase?p:(0,c.RQ)([p,n.encodeLocation?n.encodeLocation(e.pathnameBase).pathname:e.pathnameBase])}))),s,o||void 0);return t&&_?a.createElement(y.Provider,{value:{location:r({pathname:"/",search:"",hash:"",state:null,key:"default"},u),navigationType:c.aU.Pop}},_):_}(o&&!t?o.router.routes:O(t),n)}var U;!function(e){e[e.pending=0]="pending",e[e.success=1]="success",e[e.error=2]="error"}(U||(U={}));new Promise((()=>{}));class T extends a.Component{constructor(e){super(e),this.state={error:null}}static getDerivedStateFromError(e){return{error:e}}componentDidCatch(e,t){console.error(" caught the following error during render",e,t)}render(){let{children:e,errorElement:t,resolve:n}=this.props,c=null,a=U.pending;if(n instanceof Promise)if(this.state.error){U.error;let e=this.state.error;Promise.reject().catch((()=>{})),Object.defineProperty(c,"_tracked",{get:()=>!0}),Object.defineProperty(c,"_error",{get:()=>e})}else n._tracked?(n,void 0!==c._error?U.error:void 0!==c._data?U.success:U.pending):(U.pending,Object.defineProperty(n,"_tracked",{get:()=>!0}),n.then((e=>Object.defineProperty(n,"_data",{get:()=>e})),(e=>Object.defineProperty(n,"_error",{get:()=>e}))));else U.success,Promise.resolve(),Object.defineProperty(c,"_tracked",{get:()=>!0}),Object.defineProperty(c,"_data",{get:()=>n});if(a===U.error&&c._error instanceof AbortedDeferredError)throw neverSettledPromise;if(a===U.error&&!t)throw c._error;if(a===U.error)return React.createElement(AwaitContext.Provider,{value:c,children:t});if(a===U.success)return React.createElement(AwaitContext.Provider,{value:c,children:e});throw c}}function O(e,t){void 0===t&&(t=[]);let n=[];return a.Children.forEach(e,((e,r)=>{if(!a.isValidElement(e))return;if(e.type===a.Fragment)return void n.push.apply(n,O(e.props.children,t));e.type!==A&&(0,c.kG)(!1),e.props.index&&e.props.children&&(0,c.kG)(!1);let o=[...t,r],s={id:e.props.id||o.join("-"),caseSensitive:e.props.caseSensitive,element:e.props.element,index:e.props.index,path:e.props.path,loader:e.props.loader,action:e.props.action,errorElement:e.props.errorElement,hasErrorBoundary:null!=e.props.errorElement,shouldRevalidate:e.props.shouldRevalidate,handle:e.props.handle};e.props.children&&(s.children=O(e.props.children,o)),n.push(s)})),n}},6975:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});var c=n(951);const a=n.n(c)()("dops:analytics");let r,o;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,n){s.setUser(e,t),s.setSuperProps(n),s.identifyUser()},setGoogleAnalyticsEnabled:function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;this.googleAnalyticsEnabled=e,this.googleAnalyticsKey=t},setMcAnalyticsEnabled:function(e){this.mcAnalyticsEnabled=e},setUser:function(e,t){o={ID:e,username:t}},setSuperProps:function(e){r=e},assignSuperProps:function(e){r=Object.assign(r||{},e)},mc:{bumpStat:function(e,t){const n=function(e,t){let n="";if("object"==typeof e){for(const t in e)n+="&x_"+encodeURIComponent(t)+"="+encodeURIComponent(e[t]);a("Bumping stats %o",e)}else n="&x_"+encodeURIComponent(e)+"="+encodeURIComponent(t),a('Bumping stat "%s" in group "%s"',t,e);return n}(e,t);s.mcAnalyticsEnabled&&((new Image).src=document.location.protocol+"//pixel.wp.com/g.gif?v=wpcom-no-pv"+n+"&t="+Math.random())},bumpStatWithPageView:function(e,t){const n=function(e,t){let n="";if("object"==typeof e){for(const t in e)n+="&"+encodeURIComponent(t)+"="+encodeURIComponent(e[t]);a("Built stats %o",e)}else n="&"+encodeURIComponent(e)+"="+encodeURIComponent(t),a('Built stat "%s" in group "%s"',t,e);return n}(e,t);s.mcAnalyticsEnabled&&((new Image).src=document.location.protocol+"//pixel.wp.com/g.gif?v=wpcom"+n+"&t="+Math.random())}},pageView:{record:function(e,t){s.tracks.recordPageView(e),s.ga.recordPageView(e,t)}},purchase:{record:function(e,t,n,c,a,r,o){s.ga.recordPurchase(e,t,n,c,a,r,o)}},tracks:{recordEvent:function(e,t){t=t||{},0===e.indexOf("akismet_")||0===e.indexOf("jetpack_")?(r&&(a("- Super Props: %o",r),t=Object.assign(t,r)),a('Record event "%s" called with props %s',e,JSON.stringify(t)),window._tkq.push(["recordEvent",e,t])):a('- 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){a("Pushing setOptOut: %o",e),window._tkq.push(["setOptOut",e])}},ga:{initialized:!1,initialize:function(){let e={};s.ga.initialized||(o&&(e={userId:"u-"+o.ID}),window.ga("create",this.googleAnalyticsKey,"auto",e),s.ga.initialized=!0)},recordPageView:function(e,t){s.ga.initialize(),a("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,n,c){s.ga.initialize();let r="Recording Event ~ [Category: "+e+"] [Action: "+t+"]";void 0!==n&&(r+=" [Option Label: "+n+"]"),void 0!==c&&(r+=" [Option Value: "+c+"]"),a(r),this.googleAnalyticsEnabled&&window.ga("send","event",e,t,n,c)},recordPurchase:function(e,t,n,c,a,r,o){window.ga("require","ecommerce"),window.ga("ecommerce:addTransaction",{id:e,revenue:c,currency:o}),window.ga("ecommerce:addItem",{id:e,name:t,sku:n,price:a,quantity:r}),window.ga("ecommerce:send")}},identifyUser:function(){o&&window._tkq.push(["identifyUser",o.ID,o.username])},setProperties:function(e){window._tkq.push(["setProperties",e])},clearedIdentity:function(){window._tkq.push(["clearIdentity"])}},i=s},4743:(e,t,n)=>{"use strict";n.d(t,{ZP:()=>u});var c=n(1132),a=n(6483);function r(e){class t extends Error{constructor(){super(...arguments),this.name=e}}return t}const o=r("JsonParseError"),s=r("JsonParseAfterRedirectError"),i=r("Api404Error"),l=r("Api404AfterRedirectError"),p=r("FetchNetworkError");const u=new function(e,t){let n=e,r=e,o={"X-WP-Nonce":t},s={credentials:"same-origin",headers:o},i={method:"post",credentials:"same-origin",headers:Object.assign({},o,{"Content-type":"application/json"})},l=function(e){const t=e.split("?"),n=t.length>1?t[1]:"",c=n.length?n.split("&"):[];return c.push("_cacheBuster="+(new Date).getTime()),t[0]+"?"+c.join("&")};const p={setApiRoot(e){n=e},setWpcomOriginApiUrl(e){r=e},setApiNonce(e){o={"X-WP-Nonce":e},s={credentials:"same-origin",headers:o},i={method:"post",credentials:"same-origin",headers:Object.assign({},o,{"Content-type":"application/json"})}},setCacheBusterCallback:e=>{l=e},registerSite:(e,t)=>{const a={registration_nonce:e,no_iframe:!0};return(0,c.jetpackConfigHas)("consumer_slug")&&(a.plugin_slug=(0,c.jetpackConfigGet)("consumer_slug")),null!==t&&(a.redirect_uri=t),g(`${n}jetpack/v4/connection/register`,i,{body:JSON.stringify(a)}).then(d).then(m)},fetchAuthorizationUrl:e=>u((0,a.addQueryArgs)(`${n}jetpack/v4/connection/authorize_url`,{no_iframe:"1",redirect_uri:e}),s).then(d).then(m),fetchSiteConnectionData:()=>u(`${n}jetpack/v4/connection/data`,s).then(m),fetchSiteConnectionStatus:()=>u(`${n}jetpack/v4/connection`,s).then(m),fetchSiteConnectionTest:()=>u(`${n}jetpack/v4/connection/test`,s).then(d).then(m),fetchUserConnectionData:()=>u(`${n}jetpack/v4/connection/data`,s).then(m),fetchUserTrackingSettings:()=>u(`${n}jetpack/v4/tracking/settings`,s).then(d).then(m),updateUserTrackingSettings:e=>g(`${n}jetpack/v4/tracking/settings`,i,{body:JSON.stringify(e)}).then(d).then(m),disconnectSite:()=>g(`${n}jetpack/v4/connection`,i,{body:JSON.stringify({isActive:!1})}).then(d).then(m),fetchConnectUrl:()=>u(`${n}jetpack/v4/connection/url`,s).then(d).then(m),unlinkUser:()=>g(`${n}jetpack/v4/connection/user`,i,{body:JSON.stringify({linked:!1})}).then(d).then(m),reconnect:()=>g(`${n}jetpack/v4/connection/reconnect`,i).then(d).then(m),fetchConnectedPlugins:()=>u(`${n}jetpack/v4/connection/plugins`,s).then(d).then(m),setHasSeenWCConnectionModal:()=>g(`${n}jetpack/v4/seen-wc-connection-modal`,i).then(d).then(m),fetchModules:()=>u(`${n}jetpack/v4/module/all`,s).then(d).then(m),fetchModule:e=>u(`${n}jetpack/v4/module/${e}`,s).then(d).then(m),activateModule:e=>g(`${n}jetpack/v4/module/${e}/active`,i,{body:JSON.stringify({active:!0})}).then(d).then(m),deactivateModule:e=>g(`${n}jetpack/v4/module/${e}/active`,i,{body:JSON.stringify({active:!1})}),updateModuleOptions:(e,t)=>g(`${n}jetpack/v4/module/${e}`,i,{body:JSON.stringify(t)}).then(d).then(m),updateSettings:e=>g(`${n}jetpack/v4/settings`,i,{body:JSON.stringify(e)}).then(d).then(m),getProtectCount:()=>u(`${n}jetpack/v4/module/protect/data`,s).then(d).then(m),resetOptions:e=>g(`${n}jetpack/v4/options/${e}`,i,{body:JSON.stringify({reset:!0})}).then(d).then(m),activateVaultPress:()=>g(`${n}jetpack/v4/plugins`,i,{body:JSON.stringify({slug:"vaultpress",status:"active"})}).then(d).then(m),getVaultPressData:()=>u(`${n}jetpack/v4/module/vaultpress/data`,s).then(d).then(m),installPlugin:(e,t)=>{const c={slug:e,status:"active"};return t&&(c.source=t),g(`${n}jetpack/v4/plugins`,i,{body:JSON.stringify(c)}).then(d).then(m)},activateAkismet:()=>g(`${n}jetpack/v4/plugins`,i,{body:JSON.stringify({slug:"akismet",status:"active"})}).then(d).then(m),getAkismetData:()=>u(`${n}jetpack/v4/module/akismet/data`,s).then(d).then(m),checkAkismetKey:()=>u(`${n}jetpack/v4/module/akismet/key/check`,s).then(d).then(m),checkAkismetKeyTyped:e=>g(`${n}jetpack/v4/module/akismet/key/check`,i,{body:JSON.stringify({api_key:e})}).then(d).then(m),fetchStatsData:e=>u(function(e){let t=`${n}jetpack/v4/module/stats/data`;-1!==t.indexOf("?")?t+=`&range=${encodeURIComponent(e)}`:t+=`?range=${encodeURIComponent(e)}`;return t}(e),s).then(d).then(m).then(y),getPluginUpdates:()=>u(`${n}jetpack/v4/updates/plugins`,s).then(d).then(m),getPlans:()=>u(`${n}jetpack/v4/plans`,s).then(d).then(m),fetchSettings:()=>u(`${n}jetpack/v4/settings`,s).then(d).then(m),updateSetting:e=>g(`${n}jetpack/v4/settings`,i,{body:JSON.stringify(e)}).then(d).then(m),fetchSiteData:()=>u(`${n}jetpack/v4/site`,s).then(d).then(m).then((e=>JSON.parse(e.data))),fetchSiteFeatures:()=>u(`${n}jetpack/v4/site/features`,s).then(d).then(m).then((e=>JSON.parse(e.data))),fetchSiteProducts:()=>u(`${n}jetpack/v4/site/products`,s).then(d).then(m),fetchSitePurchases:()=>u(`${n}jetpack/v4/site/purchases`,s).then(d).then(m).then((e=>JSON.parse(e.data))),fetchSiteBenefits:()=>u(`${n}jetpack/v4/site/benefits`,s).then(d).then(m).then((e=>JSON.parse(e.data))),fetchSiteDiscount:()=>u(`${n}jetpack/v4/site/discount`,s).then(d).then(m).then((e=>e.data)),fetchSetupQuestionnaire:()=>u(`${n}jetpack/v4/setup/questionnaire`,s).then(d).then(m),fetchRecommendationsData:()=>u(`${n}jetpack/v4/recommendations/data`,s).then(d).then(m),fetchRecommendationsProductSuggestions:()=>u(`${n}jetpack/v4/recommendations/product-suggestions`,s).then(d).then(m),fetchRecommendationsUpsell:()=>u(`${n}jetpack/v4/recommendations/upsell`,s).then(d).then(m),fetchRecommendationsConditional:()=>u(`${n}jetpack/v4/recommendations/conditional`,s).then(d).then(m),saveRecommendationsData:e=>g(`${n}jetpack/v4/recommendations/data`,i,{body:JSON.stringify({data:e})}).then(d),fetchProducts:()=>u(`${n}jetpack/v4/products`,s).then(d).then(m),fetchRewindStatus:()=>u(`${n}jetpack/v4/rewind`,s).then(d).then(m).then((e=>JSON.parse(e.data))),fetchScanStatus:()=>u(`${n}jetpack/v4/scan`,s).then(d).then(m).then((e=>JSON.parse(e.data))),dismissJetpackNotice:e=>g(`${n}jetpack/v4/notice/${e}`,i,{body:JSON.stringify({dismissed:!0})}).then(d).then(m),fetchPluginsData:()=>u(`${n}jetpack/v4/plugins`,s).then(d).then(m),fetchIntroOffers:()=>u(`${n}jetpack/v4/intro-offers`,s).then(d).then(m),fetchVerifySiteGoogleStatus:e=>u(null!==e?`${n}jetpack/v4/verify-site/google/${e}`:`${n}jetpack/v4/verify-site/google`,s).then(d).then(m),verifySiteGoogle:e=>g(`${n}jetpack/v4/verify-site/google`,i,{body:JSON.stringify({keyring_id:e})}).then(d).then(m),submitSurvey:e=>g(`${n}jetpack/v4/marketing/survey`,i,{body:JSON.stringify(e)}).then(d).then(m),saveSetupQuestionnaire:e=>g(`${n}jetpack/v4/setup/questionnaire`,i,{body:JSON.stringify(e)}).then(d).then(m),updateLicensingError:e=>g(`${n}jetpack/v4/licensing/error`,i,{body:JSON.stringify(e)}).then(d).then(m),updateLicenseKey:e=>g(`${n}jetpack/v4/licensing/set-license`,i,{body:JSON.stringify({license:e})}).then(d).then(m),getUserLicensesCounts:()=>u(`${n}jetpack/v4/licensing/user/counts`,s).then(d).then(m),getUserLicenses:()=>u(`${n}jetpack/v4/licensing/user/licenses`,s).then(d).then(m),updateLicensingActivationNoticeDismiss:e=>g(`${n}jetpack/v4/licensing/user/activation-notice-dismiss`,i,{body:JSON.stringify({last_detached_count:e})}).then(d).then(m),updateRecommendationsStep:e=>g(`${n}jetpack/v4/recommendations/step`,i,{body:JSON.stringify({step:e})}).then(d),confirmIDCSafeMode:()=>g(`${n}jetpack/v4/identity-crisis/confirm-safe-mode`,i).then(d),startIDCFresh:e=>g(`${n}jetpack/v4/identity-crisis/start-fresh`,i,{body:JSON.stringify({redirect_uri:e})}).then(d).then(m),migrateIDC:()=>g(`${n}jetpack/v4/identity-crisis/migrate`,i).then(d),attachLicenses:e=>g(`${n}jetpack/v4/licensing/attach-licenses`,i,{body:JSON.stringify({licenses:e})}).then(d).then(m),fetchSearchPlanInfo:()=>u(`${r}jetpack/v4/search/plan`,s).then(d).then(m),fetchSearchSettings:()=>u(`${r}jetpack/v4/search/settings`,s).then(d).then(m),updateSearchSettings:e=>g(`${r}jetpack/v4/search/settings`,i,{body:JSON.stringify(e)}).then(d).then(m),fetchSearchStats:()=>u(`${r}jetpack/v4/search/stats`,s).then(d).then(m),fetchWafSettings:()=>u(`${n}jetpack/v4/waf`,s).then(d).then(m),updateWafSettings:e=>g(`${n}jetpack/v4/waf`,i,{body:JSON.stringify(e)}).then(d).then(m),fetchWordAdsSettings:()=>u(`${n}jetpack/v4/wordads/settings`,s).then(d).then(m),updateWordAdsSettings:e=>g(`${n}jetpack/v4/wordads/settings`,i,{body:JSON.stringify(e)}),fetchSearchPricing:()=>u(`${r}jetpack/v4/search/pricing`,s).then(d).then(m),fetchMigrationStatus:()=>u(`${n}jetpack/v4/migration/status`,s).then(d).then(m)};function u(e,t){return fetch(l(e),t)}function g(e,t,n){return fetch(e,Object.assign({},t,n)).catch(h)}function y(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,p)};function d(e){return e.status>=200&&e.status<300?e:404===e.status?new Promise((()=>{throw e.redirected?new l(e.redirected):new i})):e.json().catch((e=>g(e))).then((t=>{const n=new Error(`${t.message} (Status ${e.status})`);throw n.response=t,n.name="ApiError",n}))}function m(e){return e.json().catch((t=>g(t,e.redirected,e.url)))}function g(e,t,n){throw t?new s(n):new o}function h(){throw new p}},7121:(e,t,n)=>{"use strict";n.d(t,{Z:()=>g});var c=n(5609),a=n(5736),r=n(5235),o=n.n(r),s=n(5162),i=n.n(s),l=n(9196),p=n.n(l),u=n(526),d=n(2289);const __=a.__,m=e=>{const{label:t,onClick:n,isLoading:a,displayError:r,errorMessage:s}=e;return p().createElement(p().Fragment,null,p().createElement(u.Z,{className:o()(d.Z.button,"jp-action-button--button"),label:t,onClick:n,variant:"primary",disabled:a},a?p().createElement(c.Spinner,null):t),r&&p().createElement("p",{className:o()(d.Z.error,"jp-action-button__error")},s))};m.propTypes={label:i().string.isRequired,onClick:i().func,isLoading:i().bool,displayError:i().bool,errorMessage:i().string},m.defaultProps={isLoading:!1,displayError:!1,errorMessage:__("An error occurred. Please try again.","jetpack-my-jetpack")};const g=m},9105:(e,t,n)=>{"use strict";n.d(t,{Z:()=>u});var c=n(5736),a=n(5235),r=n.n(a),o=n(8237),s=n(8868),i=n(3846),l=n(3363),p=n(1494);const __=c.__,u=e=>{let{children:t,moduleName:n=__("Jetpack","jetpack-my-jetpack"),moduleNameHref:c,a8cLogoHref:a,showHeader:u=!0,showFooter:d=!0,showBackground:m=!0,header:g}=e;const h=r()(p.Z["admin-page"],{[p.Z.background]:m});return React.createElement("div",{className:h},u&&React.createElement(l.Z,{horizontalSpacing:5},React.createElement(i.Z,null,g||React.createElement(s.Z,null))),React.createElement(l.Z,{fluid:!0,horizontalSpacing:0},React.createElement(i.Z,null,t)),d&&React.createElement(l.Z,{horizontalSpacing:5},React.createElement(i.Z,null,React.createElement(o.Z,{moduleName:n,a8cLogoHref:a,moduleNameHref:c}))))}},6579:(e,t,n)=>{"use strict";n.d(t,{Z:()=>o});var c=n(9196),a=n.n(c),r=n(511);const o=e=>{let{children:t}=e;return a().createElement("div",{className:r.Z.section},t)}},216:(e,t,n)=>{"use strict";n.d(t,{Z:()=>o});var c=n(9196),a=n.n(c),r=n(281);const o=e=>{let{children:t}=e;return a().createElement("div",{className:r.Z["section-hero"]},t)}},4972:(e,t,n)=>{"use strict";n.d(t,{Z:()=>g});var c=n(797),a=n(496),r=n(9201),o=n(1074),s=n(5235),i=n.n(s),l=n(9196),p=n.n(l),u=n(9171);const d=e=>{switch(e){case"error":case"warning":default:return c.Z;case"info":return a.Z;case"success":return r.Z}},m=e=>{let{level:t,children:n,showIcon:c}=e;const a=i()(u.Z.container,u.Z[`is-${t}`]);return p().createElement("div",{className:a},c&&p().createElement("div",{className:u.Z["icon-wrapper"]},p().createElement(o.Z,{icon:d(t),className:u.Z.icon})),p().createElement("div",null,n))};m.defaultProps={level:"warning",showIcon:!0};const g=m},7525:(e,t,n)=>{"use strict";n.d(t,{Z:()=>p});var c=n(2674),a=n.n(c),r=n(5736),o=n(5235),s=n.n(o),i=n(9196),l=n.n(i);const __=r.__,p=e=>{let{title:t=__("An Automattic Airline","jetpack-my-jetpack"),height:n=7,className:c,...r}=e;return l().createElement("svg",a()({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:n,className:s()("jp-automattic-byline-logo",c)},r),l().createElement("desc",{id:"jp-automattic-byline-logo-title"},t),l().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"}),l().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"}),l().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"}))}},526:(e,t,n)=>{"use strict";n.d(t,{Z:()=>m});var c=n(2674),a=n.n(c),r=n(5609),o=n(1074),s=n(5381),i=n(5235),l=n.n(i),p=n(9196),u=n.n(p),d=n(3466);const m=(0,p.forwardRef)(((e,t)=>{const{children:n,variant:c="primary",size:i="normal",weight:p="bold",icon:m,iconSize:g,disabled:h,isDestructive:y,isLoading:f,isExternalLink:k,className:v,text:E,fullWidth:b,...j}=e,_=l()(d.Z.button,v,{[d.Z.normal]:"normal"===i,[d.Z.small]:"small"===i,[d.Z.icon]:Boolean(m),[d.Z.loading]:f,[d.Z.regular]:"regular"===p,[d.Z["full-width"]]:b,[d.Z["is-icon-button"]]:Boolean(m)&&!n});j.ref=t;const C="normal"===i?20:16,w=k&&u().createElement(o.Z,{size:C,icon:s.Z,className:d.Z["external-icon"]}),Z=k?"_blank":void 0,N=n?.[0]&&null!==n[0]&&"components-tooltip"!==n?.[0]?.props?.className;return u().createElement(r.Button,a()({target:Z,variant:c,className:l()(_,{"has-text":!!m&&N}),icon:k?void 0:m,iconSize:g,disabled:h,"aria-disabled":h,isDestructive:y,text:E},j),f&&u().createElement(r.Spinner,null),u().createElement("span",null,n),w)}))},9026:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});n(2404);const c=e=>{let{format:t="horizontal",icon:n,imageUrl:c}=e;return React.createElement("div",{className:"jp-components__decorative-card "+(t?"jp-components__decorative-card--"+t:"")},React.createElement("div",{className:"jp-components__decorative-card__image",style:{backgroundImage:c?`url( ${c} )`:""}}),React.createElement("div",{className:"jp-components__decorative-card__content"},React.createElement("div",{className:"jp-components__decorative-card__lines"})),n?React.createElement("div",{className:"jp-components__decorative-card__icon-container"},React.createElement("span",{className:"jp-components__decorative-card__icon jp-components__decorative-card__icon--"+n})):null)}},3396:(e,t,n)=>{"use strict";n.d(t,{KM:()=>u,VS:()=>h,_1:()=>d,r7:()=>p});var c=n(2674),a=n.n(c),r=n(5609),o=n(5235),s=n.n(o),i=n(5612);const l=e=>{let{className:t,size:n=24,viewBox:c="0 0 24 24",opacity:o=1,color:l="#2C3338",children:p}=e;const u={className:s()(i.Z.iconWrapper,t),width:n,height:n,viewBox:c,opacity:o,fill:void 0};return l&&(u.fill=l),React.createElement(r.SVG,a()({},u,{fillRule:"evenodd",clipRule:"evenodd",xmlns:"http://www.w3.org/2000/svg"}),React.createElement(r.G,{opacity:o},p))},p=e=>{let{size:t,className:n=i.Z["star-icon"],color:c}=e;return React.createElement(l,{className:n,size:t,color:c},React.createElement(r.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=e=>{let{size:t,className:n=i.Z["checkmark-icon"],color:c}=e;return React.createElement(l,{className:n,size:t,color:c},React.createElement(r.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=e=>{let{size:t,className:n=i.Z.jetpack,color:c}=e;return React.createElement(l,{className:n,size:t,color:c,viewBox:"0 0 32 32"},React.createElement(r.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(r.Polygon,{fill:"#fff",points:"15,19 7,19 15,3"}),React.createElement(r.Polygon,{fill:"#fff",points:"17,29 17,13 25,13"}))},m=e=>{let{className:t,fill:n="none",size:c,children:a}=e;return React.createElement(l,{className:s()(i.Z.socialIcon,t),size:c,color:n},a)},g={...{"anti-spam":e=>{let{opacity:t=1,size:n,color:c}=e;return React.createElement(l,{size:n,opacity:t,color:c},React.createElement(r.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(r.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(r.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(r.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:e=>{let{opacity:t=1,size:n,color:c}=e;return React.createElement(l,{size:n,opacity:t,color:c},React.createElement(r.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:e=>{let{opacity:t=1,size:n,color:c}=e;return React.createElement(l,{size:n,opacity:t,color:c},React.createElement(r.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:e=>{let{opacity:t=1,size:n,color:c}=e;return React.createElement(l,{size:n,opacity:t,color:c},React.createElement(r.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:e=>{let{opacity:t=1,size:n,color:c}=e;return React.createElement(l,{size:n,opacity:t,color:c},React.createElement(r.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:e=>{let{opacity:t=1,size:n,className:c,color:a}=e;return React.createElement(l,{className:c,size:n,opacity:t,color:a},React.createElement(r.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(r.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:e=>{let{opacity:t=1,size:n,color:c}=e;return React.createElement(l,{size:n,opacity:t,color:c},React.createElement(r.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:e=>{let{opacity:t=1,size:n,color:c}=e;return React.createElement(l,{size:n,opacity:t,color:c},React.createElement(r.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:e=>{let{opacity:t=1,size:n,color:c}=e;return React.createElement(l,{size:n,opacity:t,color:c},React.createElement(r.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:p,videopress:e=>{let{opacity:t=1,size:n,color:c}=e;return React.createElement(l,{size:n,opacity:t,color:c},React.createElement(r.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},...{facebook:e=>{let{fill:t,size:n,className:c}=e;return React.createElement(m,{fill:t,size:n,className:s()(i.Z.facebook,c)},React.createElement(r.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.9c1.1,0,2.2,0.2,2.2,0.2v2.5h-1.3 c-1.2,0-1.6,0.8-1.6,1.6V12h2.8l-0.4,2.9h-2.3v7C18.3,21.1,22,17,22,12C22,6.5,17.5,2,12,2z"}))},twitter:e=>{let{fill:t,size:n,className:c}=e;return React.createElement(m,{fill:t,size:n,className:s()(i.Z.twitter,c)},React.createElement(r.Path,{d:"M19,3H5C3.895,3,3,3.895,3,5v14c0,1.105,0.895,2,2,2h14c1.105,0,2-0.895,2-2V5C21,3.895,20.105,3,19,3z M16.466,9.71 c0.004,0.099,0.007,0.198,0.007,0.298c0,3.045-2.318,6.556-6.556,6.556c-1.301,0-2.512-0.381-3.532-1.035 c0.18,0.021,0.364,0.032,0.55,0.032c1.079,0,2.073-0.368,2.862-0.986c-1.008-0.019-1.859-0.685-2.152-1.6 c0.141,0.027,0.285,0.041,0.433,0.041c0.21,0,0.414-0.028,0.607-0.081c-1.054-0.212-1.848-1.143-1.848-2.259 c0-0.01,0-0.019,0-0.029c0.311,0.173,0.666,0.276,1.044,0.288c-0.618-0.413-1.025-1.118-1.025-1.918 c0-0.422,0.114-0.818,0.312-1.158c1.136,1.394,2.834,2.311,4.749,2.407c-0.039-0.169-0.06-0.344-0.06-0.525 c0-1.272,1.032-2.304,2.304-2.304c0.663,0,1.261,0.28,1.682,0.728c0.525-0.103,1.018-0.295,1.463-0.559 c-0.172,0.538-0.537,0.99-1.013,1.275c0.466-0.056,0.91-0.18,1.323-0.363C17.306,8.979,16.916,9.385,16.466,9.71z"}))},linkedin:e=>{let{fill:t,size:n,className:c}=e;return React.createElement(m,{fill:t,size:n,className:s()(i.Z.linkedin,c)},React.createElement(r.Path,{d:"M19.7 3H4.3C3.582 3 3 3.582 3 4.3v15.4c0 .718.582 1.3 1.3 1.3h15.4c.718 0 1.3-.582 1.3-1.3V4.3c0-.718-.582-1.3-1.3-1.3zM8.34 18.338H5.666v-8.59H8.34v8.59zM7.003 8.574c-.857 0-1.55-.694-1.55-1.548 0-.855.692-1.548 1.55-1.548.854 0 1.547.694 1.547 1.548 0 .855-.692 1.548-1.546 1.548zm11.335 9.764h-2.67V14.16c0-.995-.017-2.277-1.387-2.277-1.39 0-1.6 1.086-1.6 2.206v4.248h-2.668v-8.59h2.56v1.174h.036c.357-.675 1.228-1.387 2.527-1.387 2.703 0 3.203 1.78 3.203 4.092v4.71z"}))},tumblr:e=>{let{fill:t,size:n,className:c}=e;return React.createElement(m,{fill:t,size:n,className:s()(i.Z.tumblr,c)},React.createElement(r.Path,{d:"M19 3H5c-1.105 0-2 .895-2 2v14c0 1.105.895 2 2 2h14c1.105 0 2-.895 2-2V5c0-1.105-.895-2-2-2zm-5.57 14.265c-2.445.042-3.37-1.742-3.37-2.998V10.6H8.922V9.15c1.703-.615 2.113-2.15 2.21-3.026.006-.06.053-.084.08-.084h1.645V8.9h2.246v1.7H12.85v3.495c.008.476.182 1.13 1.08 1.107.3-.008.698-.094.907-.194l.54 1.6c-.205.297-1.12.642-1.946.657z"}))},google:e=>{let{fill:t,size:n,className:c}=e;return React.createElement(m,{fill:t,size:n,className:s()(i.Z.google,c)},React.createElement(r.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.05h-9.36z"}))},mastodon:e=>{let{fill:t,size:n,className:c}=e;return React.createElement(m,{fill:t,size:n,className:s()(i.Z.mastodon,c)},React.createElement(r.Path,{d:"M 19.997205,6.2868955 C 19.729197,4.3162778 17.992912,2.7633017 15.93468,2.4623753 15.587434,2.4115195 14.271759,2.2264681 11.224008,2.2264681 h -0.02277 c -3.0485688,0 -3.7026204,0.1850577 -4.0498676,0.2359072 C 5.1504449,2.7549655 3.3231548,4.1503966 2.879815,6.1443318 2.6665754,7.1263038 2.6438193,8.2149794 2.6834329,9.2136207 c 0.056471,1.4321143 0.067433,2.8617113 0.1989115,4.2879943 0.090908,0.947406 0.2494696,1.887266 0.4745239,2.812521 0.4214237,1.708868 2.1273496,3.130966 3.7987144,3.71116 1.7894479,0.605052 3.7138403,0.705478 5.5577463,0.290088 0.202828,-0.04667 0.403445,-0.100873 0.601781,-0.162549 0.447558,-0.140863 0.972662,-0.298434 1.358683,-0.575188 0.0052,-0.004 0.0097,-0.0089 0.01266,-0.01471 0.0031,-0.0056 0.0047,-0.01218 0.005,-0.01866 v -1.382076 c -9.4e-5,-0.006 -0.0016,-0.01202 -0.0043,-0.01754 -0.0027,-0.0054 -0.0067,-0.01028 -0.01155,-0.01392 -0.0049,-0.0038 -0.01044,-0.0063 -0.01648,-0.0078 -0.006,-0.0013 -0.01218,-0.0013 -0.01825,7.1e-5 -1.181368,0.279106 -2.391962,0.419012 -3.606552,0.416801 -2.0902554,0 -2.6524392,-0.981126 -2.8134375,-1.3896 -0.1293933,-0.353009 -0.2115739,-0.721231 -0.2444221,-1.095331 -3.29e-4,-0.0063 8.463e-4,-0.0125 0.00348,-0.01832 0.00253,-0.0056 0.00649,-0.01077 0.011389,-0.01471 0.0049,-0.004 0.010755,-0.0068 0.016957,-0.0081 0.00617,-0.0014 0.012655,-0.0012 0.018808,3.52e-4 1.1616831,0.277201 2.3525266,0.417106 3.5475526,0.416801 0.287408,0 0.573966,0 0.861395,-0.0074 1.201893,-0.03335 2.468685,-0.0942 3.6512,-0.322606 0.02952,-0.0058 0.059,-0.01091 0.0843,-0.01833 1.865209,-0.354279 3.640245,-1.466278 3.820617,-4.282163 0.0068,-0.110869 0.0236,-1.161191 0.0236,-1.276219 8.46e-4,-0.390958 0.127273,-2.7733487 -0.01856,-4.2371335 z m -2.87074,7.0263315 H 15.165179 V 8.5617567 c 0,-1.0003116 -0.421434,-1.5104614 -1.278618,-1.5104614 -0.942305,0 -1.414292,0.6035217 -1.414292,1.7955379 V 11.44764 H 10.522764 V 8.8468332 c 0,-1.1920162 -0.472832,-1.7955379 -1.4151372,-1.7955379 -0.8521293,0 -1.2777701,0.5101498 -1.2786179,1.5104614 V 13.313227 H 5.8693944 V 8.4175496 c 0,-1.0003133 0.2582014,-1.7949986 0.7745804,-2.3840846 0.5326766,-0.587672 1.2314038,-0.8894211 2.0986981,-0.8894211 1.003817,0 1.7623841,0.3817657 2.2680911,1.1445204 l 0.488023,0.8102521 0.488846,-0.8102521 c 0.505705,-0.7627547 1.264275,-1.1445204 2.26642,-1.1445204 0.866449,0 1.565152,0.3017491 2.099521,0.8894211 0.516404,0.5885211 0.774583,1.3832066 0.774583,2.3840846 z"}))}}};function h(e){return g[e]?g[e]:null}},8237:(e,t,n)=>{"use strict";n.d(t,{Z:()=>d});var c=n(2674),a=n.n(c),r=n(5736),o=n(5235),s=n.n(o),i=n(9196),l=n.n(i),p=n(7525),u=(n(9054),n(8868));const __=r.__,d=e=>{let{a8cLogoHref:t="https://automattic.com",moduleName:n=__("Jetpack","jetpack-my-jetpack"),className:c,moduleNameHref:r="https://jetpack.com",...o}=e;return l().createElement("div",a()({className:s()("jp-dashboard-footer",c)},o),l().createElement("div",{className:"jp-dashboard-footer__footer-left"},l().createElement(u.Z,{logoColor:"#000",showText:!1,height:16,className:"jp-dashboard-footer__jetpack-symbol","aria-label":__("Jetpack logo","jetpack-my-jetpack")}),l().createElement("span",{className:"jp-dashboard-footer__module-name"},r?l().createElement("a",{href:r,"aria-label":n},n):n)),l().createElement("div",{className:"jp-dashboard-footer__footer-right"},l().createElement("a",{href:t,"aria-label":__("An Automattic Airline","jetpack-my-jetpack")},l().createElement(p.Z,null))))}},8868:(e,t,n)=>{"use strict";n.d(t,{Z:()=>p});var c=n(2674),a=n.n(c),r=n(5736),o=n(5235),s=n.n(o),i=n(9196),l=n.n(i);const __=r.__,p=e=>{let{logoColor:t="#069e08",showText:n=!0,className:c,height:r=32,...o}=e;const i=n?"0 0 118 32":"0 0 32 32";return l().createElement("svg",a()({xmlns:"http://www.w3.org/2000/svg",x:"0px",y:"0px",viewBox:i,className:s()("jetpack-logo",c),"aria-labelledby":"jetpack-logo-title",height:r},o),l().createElement("desc",{id:"jetpack-logo-title"},__("Jetpack Logo","jetpack-my-jetpack")),l().createElement("path",{fill:t,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"}),n&&l().createElement(l().Fragment,null,l().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"}),l().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"}),l().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"}),l().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"}),l().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"}),l().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"}),l().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"})))}},3846:(e,t,n)=>{"use strict";n.d(t,{Z:()=>l});var c=n(5235),a=n.n(c),r=n(3080);const o=Number(r.Z.smCols),s=Number(r.Z.mdCols),i=Number(r.Z.lgCols),l=e=>{const{children:t,className:n}=e,c=Math.min(o,"number"==typeof e.sm?e.sm:o),l=Math.min(o,"object"==typeof e.sm?e.sm.start:0),p=Math.min(o,"object"==typeof e.sm?e.sm.end:0),u=Math.min(s,"number"==typeof e.md?e.md:s),d=Math.min(s,"object"==typeof e.md?e.md.start:0),m=Math.min(s,"object"==typeof e.md?e.md.end:0),g=Math.min(i,"number"==typeof e.lg?e.lg:i),h=Math.min(i,"object"==typeof e.lg?e.lg.start:0),y=Math.min(i,"object"==typeof e.lg?e.lg.end:0),f=a()(n,{[r.Z[`col-sm-${c}`]]:!(l&&p),[r.Z[`col-sm-${l}-start`]]:l>0,[r.Z[`col-sm-${p}-end`]]:p>0,[r.Z[`col-md-${u}`]]:!(d&&m),[r.Z[`col-md-${d}-start`]]:d>0,[r.Z[`col-md-${m}-end`]]:m>0,[r.Z[`col-lg-${g}`]]:!(h&&y),[r.Z[`col-lg-${h}-start`]]:h>0,[r.Z[`col-lg-${y}-end`]]:y>0});return React.createElement("div",{className:f},t)}},3363:(e,t,n)=>{"use strict";n.d(t,{Z:()=>s});var c=n(5235),a=n.n(c),r=n(9196),o=n(8730);const s=e=>{let{children:t,fluid:n=!1,className:c,horizontalGap:s=1,horizontalSpacing:i=1}=e;const l=(0,r.useMemo)((()=>{const e=`calc( var(--horizontal-spacing) * ${i} )`;return{paddingTop:e,paddingBottom:e,rowGap:`calc( var(--horizontal-spacing) * ${s} )`}}),[s,i]),p=a()(c,o.Z.container,{[o.Z.fluid]:n});return React.createElement("div",{className:p,style:l},t)}},2054:(e,t,n)=>{"use strict";n.d(t,{Z:()=>o});var c=n(4333),a=n(3247);const r=["sm","md","lg"],o=(e,t)=>{const n=Array.isArray(e)?e:[e],o=Array.isArray(t)?t:[t],[s,i,l]=r,p={sm:(0,c.useMediaQuery)(a.Z[s]),md:(0,c.useMediaQuery)(a.Z[i]),lg:(0,c.useMediaQuery)(a.Z[l])};return n.map(((e,t)=>{const n=o[t];return n?((e,t,n)=>{const c=r.indexOf(e),a=c+1,o=t.includes("=");let s=[];return t.startsWith("<")&&(s=r.slice(0,o?a:c)),t.startsWith(">")&&(s=r.slice(o?c:a)),s?.length?s.some((e=>n[e])):n[e]})(e,n,p):p[e]}))}},5033:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});var c=n(5162),a=n.n(c),r=n(9196),o=n.n(r);n(1683);const s=e=>{const t=e.className+" jp-components-spinner",n={width:e.size,height:e.size,fontSize:e.size,borderTopColor:e.color},c={borderTopColor:e.color,borderRightColor:e.color};return o().createElement("div",{className:t},o().createElement("div",{className:"jp-components-spinner__outer",style:n},o().createElement("div",{className:"jp-components-spinner__inner",style:c})))};s.propTypes={color:a().string,className:a().string,size:a().number},s.defaultProps={color:"#FFFFFF",className:"",size:20};const i=s},7325:(e,t,n)=>{"use strict";n.d(t,{Z:()=>d});var c=n(9307),a=n(5736),r=n(5235),o=n.n(r),s=n(6895),i=n(5106);n(7920);const __=a.__,l=()=>(0,c.createInterpolateElement)(__("By clicking the buttons above, you agree to our Terms of Service and to share details with WordPress.com.","jetpack-my-jetpack"),{tosLink:React.createElement(u,{slug:"wpcom-tos"}),shareDetailsLink:React.createElement(u,{slug:"jetpack-support-what-data-does-jetpack-sync"})}),p=e=>{let{agreeButtonLabel:t}=e;return(0,c.createInterpolateElement)((0,a.sprintf)(/* translators: %s is a button label */ -__("By clicking the %s button, you agree to our Terms of Service and to share details with WordPress.com.","jetpack-my-jetpack"),t),{strong:React.createElement("strong",null),tosLink:React.createElement(u,{slug:"wpcom-tos"}),shareDetailsLink:React.createElement(u,{slug:"jetpack-support-what-data-does-jetpack-sync"})})},u=e=>{let{slug:t,children:n}=e;return React.createElement("a",{className:"terms-of-service__link",href:(0,s.Z)(t),rel:"noopener noreferrer",target:"_blank"},n)},d=e=>{let{className:t,multipleButtons:n,agreeButtonLabel:c}=e;return React.createElement(i.ZP,{className:o()(t,"terms-of-service")},n?React.createElement(l,null):React.createElement(p,{agreeButtonLabel:c}))}},6017:(e,t,n)=>{"use strict";n.d(t,{h:()=>c,s:()=>a});const c={"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"},a=["mt","mr","mb","ml","mx","my","m","pt","pr","pb","pl","px","py","p"]},5106:(e,t,n)=>{"use strict";n.d(t,{Dx:()=>g,H3:()=>m,ZP:()=>d});var c=n(2674),a=n.n(c),r=n(5235),o=n.n(r),s=n(9196),i=n.n(s),l=n(6017),p=n(3280);const u=(0,s.forwardRef)(((e,t)=>{let{variant:n="body",children:c,component:r,className:u,...d}=e;const m=r||l.h[n]||"span",g=(0,s.useMemo)((()=>l.s.reduce(((e,t)=>(void 0!==d[t]&&(e+=p.Z[`${t}-${d[t]}`]+" ",delete d[t]),e)),"")),[d]);return d.ref=t,i().createElement(m,a()({className:o()(p.Z.reset,p.Z[n],u,g)},d),c)})),d=u,m=e=>{let{children:t,weight:n="bold",...c}=e;const r="headline-small"+("bold"===n?"":`-${n}`);return i().createElement(u,a()({variant:r,mb:3},c),t)},g=e=>{let{children:t,size:n="medium",...c}=e;return i().createElement(u,a()({variant:`title-${n}`,mb:1},c),t)}},8275:(e,t,n)=>{"use strict";n.d(t,{ZP:()=>d});var c=n(9196),a=n.n(c),r=n(3591);const o={"--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-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"},l={"--spacing-base":"8px"},p={},u=(e,t,n)=>{const c={...o,...s,...i,...l};for(const t in c)e.style.setProperty(t,c[t]);n&&e.classList.add(r.Z.global),t&&(p[t]={provided:!0,root:e})},d=e=>{let{children:t=null,targetDom:n,id:r,withGlobalStyles:o=!0}=e;const s=(0,c.useRef)(),i=p?.[r]?.provided;return(0,c.useLayoutEffect)((()=>{if(!i)return n?u(n,r,o):void(s?.current&&u(s.current,r,o))}),[n,s,i,r,o]),n?t:a().createElement("div",{ref:s},t)}},5905:(e,t,n)=>{"use strict";n.d(t,{O:()=>c});const c="d729d42c-b547-4750-a6f6-8b30534a5f12"},4164:(e,t,n)=>{"use strict";n.d(t,{Z:()=>s});var c=n(9196),a=n(8709),r=n(7328),o=n(4318);const s=()=>{const{isWithinAvailableChatTimes:e,isWithinAvailableChatDays:t}=r.Z;return(0,c.useMemo)((()=>{const n=new Date;return(0,a.X)().startsWith("en")&&t(n)&&e(n)}),[t,e])?React.createElement(o.Z,null):null}},7328:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c={isWithinAvailableChatDays:e=>{const t=e.getUTCDay();return![0,6].includes(t)},isWithinAvailableChatTimes:e=>{const t=e.getUTCHours();return t>=9&&t<19}}},4318:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9196),a=n(5905);const r=()=>((0,c.useEffect)((()=>{const e=document.createElement("script"),t=document.getElementById("zendesk-chat-container");e.src="https://static.zdassets.com/ekr/snippet.js?key="+encodeURIComponent(a.O),e.type="text/javascript",e.id="ze-snippet",t&&t.appendChild(e)}),[]),React.createElement("div",{"data-testid":"zendesk-chat-container",id:"zendesk-chat-container"}))},8709:(e,t,n)=>{"use strict";n.d(t,{X:()=>r});var c=n(9771);const a=c.getSettings||c.__experimentalGetSettings,r=()=>{const{l10n:{locale:e}}=a();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"}},4153:(e,t,n)=>{"use strict";function c(e,t,n,c){const a=new URL("https://wordpress.com/checkout/"),r=new URL(`${a}${t}/${e}`);return r.searchParams.set("redirect_to",n),c||r.searchParams.set("unlinked","1"),r.searchParams.set("site",t),r.toString()}n.d(t,{Z:()=>c})},6895:(e,t,n)=>{"use strict";function c(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const n={};let c;if("undefined"!=typeof window&&(c=window.Initial_State?.calypsoEnv),0===e.search("https://")){const t=new URL(e);e=`https://${t.host}${t.pathname}`,n.url=encodeURIComponent(e)}else n.source=encodeURIComponent(e);Object.keys(t).map((e=>{n[e]=encodeURIComponent(t[e])})),!Object.keys(n).includes("site")&&"undefined"!=typeof jetpack_redirects&&jetpack_redirects.hasOwnProperty("currentSiteRawUrl")&&(n.site=jetpack_redirects.currentSiteRawUrl),c&&(n.calypso_env=c);return"https://jetpack.com/redirect/?"+Object.keys(n).map((e=>e+"="+n[e])).join("&")}n.d(t,{Z:()=>c})},1132:(e,t,n)=>{let c={};try{c=n(4462)}catch{console.error("jetpackConfig is missing in your webpack config file. See @automattic/jetpack-config"),c={missingConfig:!0}}const a=e=>c.hasOwnProperty(e);e.exports={jetpackConfigHas:a,jetpackConfigGet:e=>{if(!a(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 c[e]}}},9312:(e,t,n)=>{"use strict";n.d(t,{Z:()=>u});var c=n(5736),a=n(5162),r=n.n(a),o=n(9196),s=n.n(o),i=n(1294),l=n(1624);const __=c.__,p=e=>{let{title:t,buttonLabel:n,apiRoot:c,apiNonce:a,registrationNonce:r,from:o,redirectUri:p,images:u,children:d,assetBaseUrl:m,footer:g,skipUserConnection:h}=e;const{handleRegisterSite:y,isRegistered:f,isUserConnected:k,siteIsRegistering:v,userIsConnecting:E,registrationError:b}=(0,i.Z)({registrationNonce:r,redirectUri:p,apiRoot:c,apiNonce:a,from:o,skipUserConnection:h}),j=!f||!k,_=Boolean(b),C=v||E;return s().createElement(l.Z,{title:t,images:u,assetBaseUrl:m,showConnectButton:j,buttonLabel:n,handleButtonClick:y,displayButtonError:_,buttonIsLoading:C,footer:g},d)};p.propTypes={title:r().string,buttonLabel:r().string,apiRoot:r().string.isRequired,apiNonce:r().string.isRequired,registrationNonce:r().string.isRequired,from:r().string,redirectUri:r().string.isRequired,images:r().arrayOf(r().string),assetBaseUrl:r().string,skipUserConnection:r().bool},p.defaultProps={title:__("Over 5 million WordPress sites are faster and more secure","jetpack-my-jetpack"),buttonLabel:__("Set up Jetpack","jetpack-my-jetpack"),images:[],redirectUri:null,skipUserConnection:!1};const u=p},1624:(e,t,n)=>{"use strict";n.d(t,{Z:()=>u});var c=n(7325),a=n(7121),r=n(5162),o=n.n(r),s=n(9196),i=n.n(s),l=n(8524);n(1510);const p=e=>{const{title:t,images:n,children:r,assetBaseUrl:o,isLoading:s,showConnectButton:p,buttonLabel:u,handleButtonClick:d,displayButtonError:m,buttonIsLoading:g,footer:h}=e;return i().createElement(l.Z,{title:t,assetBaseUrl:o,images:n,className:"jp-connection__connect-screen"+(s?" jp-connection__connect-screen__loading":"")},i().createElement("div",{className:"jp-connection__connect-screen__content"},r,p&&i().createElement(i().Fragment,null,i().createElement("div",{className:"jp-connection__connect-screen__tos"},i().createElement(c.Z,{agreeButtonLabel:u})),i().createElement(a.Z,{label:u,onClick:d,displayError:m,isLoading:g})),h&&i().createElement("div",{className:"jp-connection__connect-screen__footer"},h)))};p.propTypes={title:o().string,images:o().arrayOf(o().string),assetBaseUrl:o().string,isLoading:o().bool,showConnectButton:o().bool,buttonLabel:o().string.isRequired,handleButtonClick:o().func,displayButtonError:o().bool,buttonIsLoading:o().bool,footer:o().node},p.defaultProps={showConnectButton:!0,isLoading:!1,buttonIsLoading:!1,displayButtonError:!1,handleButtonClick:()=>{},footer:null};const u=p},2458:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});var c=n(5162),a=n.n(c),r=n(9196),o=n.n(r);const s=e=>{const{images:t,assetBaseUrl:n}=e;if(!t.length)return null;const c=t.map(((e,t)=>o().createElement(o().Fragment,{key:t},o().createElement("img",{src:n+e,alt:""}))));return o().createElement("div",{className:"jp-connection__connect-screen__image-slider"},c)};s.propTypes={images:a().arrayOf(a().string).isRequired,assetBaseUrl:a().string},s.defaultProps={assetBaseUrl:""};const i=s},8524:(e,t,n)=>{"use strict";n.d(t,{Z:()=>p});var c=n(8868),a=n(5162),r=n.n(a),o=n(9196),s=n.n(o),i=n(2458);n(9610);const l=e=>{const{title:t,children:n,className:a,assetBaseUrl:r,images:o,logo:l}=e,p=o?.length;return s().createElement("div",{className:"jp-connection__connect-screen-layout"+(p?" jp-connection__connect-screen-layout__two-columns":"")+(a?" "+a:"")},s().createElement("div",{className:"jp-connection__connect-screen-layout__left"},l||s().createElement(c.Z,null),s().createElement("h2",null,t),n),p?s().createElement("div",{className:"jp-connection__connect-screen-layout__right"},s().createElement(i.Z,{images:o,assetBaseUrl:r})):null)};l.propTypes={title:r().string,className:r().string,images:r().arrayOf(r().string),assetBaseUrl:r().string,logo:r().element};const p=l},7879:(e,t,n)=>{"use strict";n.d(t,{Z:()=>p});var c=n(5736),a=n(5162),r=n.n(a),o=n(9196),s=n.n(o),i=n(4322);const __=c.__,l=e=>{const{connectedPlugins:t,disconnectingPlugin:n}=e,c=(0,o.useMemo)((()=>{if(t){return Object.keys(t).map((e=>Object.assign({slug:e},t[e]))).filter((e=>n!==e.slug))}return[]}),[t,n]);return t&&c.length>0?s().createElement(s().Fragment,null,s().createElement("div",{className:"jp-connection__disconnect-dialog__step-copy"},s().createElement("p",{className:"jp-connection__disconnect-dialog__large-text"},__("Jetpack is powering other plugins on your site. If you disconnect, these plugins will no longer work.","jetpack-my-jetpack"))),s().createElement("div",{className:"jp-connection__disconnect-card__group"},c.map((e=>s().createElement(i.Z,{title:e.name,key:e.slug}))))):null};l.propTypes={connectedPlugins:r().array,disconnectingPlugin:r().string};const p=l},6186:(e,t,n)=>{"use strict";n.d(t,{Z:()=>m});var c=n(2054),a=n(5033),r=n(5609),o=n(5736),s=n(5162),i=n.n(s),l=n(9196),p=n.n(l),u=n(9836);const __=o.__,d=e=>{const{message:t,isRestoringConnection:n,restoreConnectionCallback:s,restoreConnectionError:i}=e,[l]=(0,c.Z)(["md"],[">"]),d=u.Z.notice+(l?" "+u.Z["bigger-than-medium"]:""),m=p().createElement(r.Icon,{icon:p().createElement(r.SVG,{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},p().createElement(r.Path,{d:"M11.7815 4.93772C11.8767 4.76626 12.1233 4.76626 12.2185 4.93772L20.519 19.8786C20.6116 20.0452 20.4911 20.25 20.3005 20.25H3.69951C3.50889 20.25 3.3884 20.0452 3.48098 19.8786L11.7815 4.93772Z",stroke:"#D63638",strokeWidth:"1.5"}),p().createElement(r.Path,{d:"M13 10H11V15H13V10Z",fill:"#D63638"}),p().createElement(r.Path,{d:"M13 16H11V18H13V16Z",fill:"#D63638"}))});if(!t)return null;if(n)return p().createElement(r.Notice,{status:"error",isDismissible:!1,className:d},p().createElement("div",{className:u.Z.message},p().createElement(a.Z,{color:"#B32D2E",size:24}),__("Reconnecting Jetpack","jetpack-my-jetpack")));const g=i?p().createElement(r.Notice,{status:"error",isDismissible:!1,className:d+" "+u.Z.error},p().createElement("div",{className:u.Z.message},m,(0,o.sprintf)(/* translators: placeholder is the error. */ -__("There was an error reconnecting Jetpack. Error: %s","jetpack-my-jetpack"),i))):null;return p().createElement(p().Fragment,null,g,p().createElement(r.Notice,{status:"error",isDismissible:!1,className:d},p().createElement("div",{className:u.Z.message},m,t),s&&p().createElement("a",{onClick:s,onKeyDown:s,className:u.Z.button,href:"#"},__("Restore Connection","jetpack-my-jetpack"))))};d.propTypes={message:i().string.isRequired,restoreConnectionCallback:i().func,isRestoringConnection:i().bool,restoreConnectionError:i().string};const m=d},4322:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});var c=n(5162),a=n.n(c),r=n(9196),o=n.n(r);n(4220);const s=e=>{const{title:t,value:n,description:c}=e;return o().createElement("div",{className:"jp-connection__disconnect-card card"},o().createElement("div",{className:"jp-connection__disconnect-card__card-content"},o().createElement("p",{className:"jp-connection__disconnect-card__card-headline"},t),(n||c)&&o().createElement("div",{className:"jp-connection__disconnect-card__card-stat-block"},o().createElement("span",{className:"jp-connection__disconnect-card__card-stat"},n),o().createElement("div",{className:"jp-connection__disconnect-card__card-description"},c))))};s.propTypes={title:a().string,value:a().oneOfType([a().string,a().number]),description:a().string};const i=s},6168:(e,t,n)=>{"use strict";n.d(t,{Z:()=>f});var c=n(6975),a=n(4743),r=n(1132),o=n(5609),s=n(5736),i=n(5162),l=n.n(i),p=n(9196),u=n.n(p),d=(n(287),n(9015)),m=n(5995),g=n(1702),h=n(1166);const __=s.__,y=e=>{const[t,n]=(0,p.useState)(!1),[s,i]=(0,p.useState)(!1),[l,y]=(0,p.useState)(!1),[f,k]=(0,p.useState)(!1),[v,E]=(0,p.useState)(!1),[b,j]=(0,p.useState)(!1),{apiRoot:_,apiNonce:C,connectedPlugins:w,title:Z,pluginScreenDisconnectCallback:N,onDisconnected:S,onError:R,disconnectStepComponent:P,context:x,connectedUser:A,connectedSiteId:L,isOpen:I,onClose:U}=e;let T="";(0,r.jetpackConfigHas)("consumer_slug")&&(T=(0,r.jetpackConfigGet)("consumer_slug"));const O=(0,p.useMemo)((()=>({context:x,plugin:T})),[x,T]);(0,p.useEffect)((()=>{a.ZP.setApiRoot(_),a.ZP.setApiNonce(C)}),[_,C]),(0,p.useEffect)((()=>{A&&A.ID&&A.login&&c.Z.initialize(A.ID,A.login)}),[A,A.ID,A.login]),(0,p.useEffect)((()=>{I&&c.Z.tracks.recordEvent("jetpack_disconnect_dialog_open",O)}),[I,O]),(0,p.useEffect)((()=>{I&&(s?!s||f||v?f&&!v?c.Z.tracks.recordEvent("jetpack_disconnect_dialog_step",Object.assign({},{step:"survey"},O)):v&&c.Z.tracks.recordEvent("jetpack_disconnect_dialog_step",Object.assign({},{step:"thank_you"},O)):c.Z.tracks.recordEvent("jetpack_disconnect_dialog_step",Object.assign({},{step:"disconnect_confirm"},O)):c.Z.tracks.recordEvent("jetpack_disconnect_dialog_step",Object.assign({},{step:"disconnect"},O)))}),[I,s,f,v,O]);const F=(0,p.useCallback)((()=>{a.ZP.disconnectSite().then((()=>{n(!1),i(!0)})).catch((e=>{n(!1),y(e),R&&R(e)}))}),[n,i,y,R]),D=(0,p.useCallback)(((e,t)=>{j(!0),fetch("https://public-api.wordpress.com/wpcom/v2/marketing/feedback-survey",{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify(e)}).then((e=>e.json())).then((e=>{if(!0!==e.success)throw new Error("Survey endpoint returned error code "+e.code);c.Z.tracks.recordEvent("jetpack_disconnect_survey_submit",t),E(!0),j(!1)})).catch((e=>{c.Z.tracks.recordEvent("jetpack_disconnect_survey_error",Object.assign({},{error:e.message},t)),E(!0),j(!1)}))}),[j,E]),z=(0,p.useCallback)((e=>{e&&e.preventDefault(),y(!1),n(!0),"plugins"!==x?F():N&&N(e)}),[y,n,N,x,F]),M=(0,p.useCallback)((e=>c.Z.tracks.recordEvent(e,O)),[O]),V=(0,p.useCallback)((()=>!(!A.ID||!L)),[A,L]),B=(0,p.useCallback)(((e,t,n)=>{if(n&&n.preventDefault(),!V())return void E(!0);const c={site_id:L,user_id:A.ID,survey_id:"jetpack-plugin-disconnect",survey_responses:{"why-cancel":{response:e,text:t||null}}},a=Object.assign({},O,{disconnect_reason:e});D(c,a)}),[D,E,V,L,A,O]),J=(0,p.useCallback)((e=>{e&&e.preventDefault(),S&&S(),U()}),[S,U]),H=(0,p.useCallback)((e=>{e&&e.preventDefault(),k(!0)}),[k]);return u().createElement(u().Fragment,null,I&&u().createElement(o.Modal,{title:"",contentLabel:Z,aria:{labelledby:"jp-connection__disconnect-dialog__heading"},onRequestClose:U,shouldCloseOnClickOutside:!1,shouldCloseOnEsc:!1,isDismissible:!1,className:"jp-connection__disconnect-dialog"+(s?" jp-connection__disconnect-dialog__success":"")},s?!s||f||v?f&&!v?u().createElement(g.Z,{isSubmittingFeedback:b,onFeedBackProvided:B,onExit:J}):v?u().createElement(h.Z,{onExit:J}):void 0:u().createElement(m.Z,{canProvideFeedback:V(),onProvideFeedback:H,onExit:J}):u().createElement(d.Z,{title:Z,connectedPlugins:w,disconnectStepComponent:P,isDisconnecting:t,closeModal:U,onDisconnect:z,disconnectError:l,context:x,disconnectingPlugin:T,trackModalClick:M})))};y.propTypes={apiRoot:l().string.isRequired,apiNonce:l().string.isRequired,title:l().string,onDisconnected:l().func,onError:l().func,context:l().string,connectedPlugins:l().oneOfType([l().array,l().object]),pluginScreenDisconnectCallback:l().func,disconnectStepComponent:l().element,connectedUser:l().object,connectedSiteId:l().number,isOpen:l().bool,onClose:l().func},y.defaultProps={title:__("Are you sure you want to disconnect?","jetpack-my-jetpack"),context:"jetpack-dashboard",connectedUser:{}};const f=y},5995:(e,t,n)=>{"use strict";n.d(t,{Z:()=>m});var c=n(9026),a=n(5609),r=n(9307),o=n(5736),s=n(5162),i=n.n(s),l=n(9196),p=n.n(l),u=n(2042);const __=o.__,d=e=>{const{onExit:t,canProvideFeedback:n,onProvideFeedback:o}=e;return p().createElement("div",{className:"jp-connection__disconnect-dialog__content"},p().createElement(c.Z,{icon:"unlink",imageUrl:u}),p().createElement("div",{className:"jp-connection__disconnect-dialog__step-copy jp-connection__disconnect-dialog__step-copy--narrow"},p().createElement("h1",null,(0,r.createInterpolateElement)(__("Jetpack has been
        successfully disconnected.","jetpack-my-jetpack"),{br:p().createElement("br",null)})),n&&p().createElement(p().Fragment,null,p().createElement("p",null,__("We’re sorry to see you go. Here at Jetpack, we’re always striving to provide the best experience for our customers. Please take our short survey (2 minutes, promise).","jetpack-my-jetpack")),p().createElement("p",null,p().createElement(a.Button,{variant:"primary",onClick:o,className:"jp-connection__disconnect-dialog__btn-back-to-wp"},__("Help us improve","jetpack-my-jetpack"))),p().createElement("a",{className:"jp-connection__disconnect-dialog__link jp-connection__disconnect-dialog__link--bold",href:"#",onClick:t},__("No thank you","jetpack-my-jetpack"))),!n&&p().createElement(p().Fragment,null,p().createElement("p",null,p().createElement(a.Button,{variant:"primary",onClick:t,className:"jp-connection__disconnect-dialog__btn-back-to-wp"},__("Back to my website","jetpack-my-jetpack"))))))};d.propTypes={onExit:i().func,onProvideFeedback:i().func,canProvideFeedback:i().bool};const m=d},9015:(e,t,n)=>{"use strict";n.d(t,{Z:()=>m});var c=n(6895),a=n(5609),r=n(9307),o=n(5736),s=n(5162),i=n.n(s),l=n(9196),p=n.n(l),u=n(7879);const __=o.__,d=e=>{const{title:t,isDisconnecting:n,onDisconnect:o,disconnectError:s,disconnectStepComponent:i,connectedPlugins:d,disconnectingPlugin:m,closeModal:g,context:h,trackModalClick:y}=e,f=(0,l.useCallback)((()=>y("jetpack_disconnect_dialog_click_learn_about")),[y]),k=(0,l.useCallback)((()=>y("jetpack_disconnect_dialog_click_support")),[y]),v=(0,l.useCallback)((()=>{y("jetpack_disconnect_dialog_click_stay_connected"),g()}),[y,g]),E=(0,l.useCallback)((e=>{y("jetpack_disconnect_dialog_click_disconnect"),o(e)}),[y,o]),b=(0,l.useCallback)((e=>{"Escape"!==e.key||n||v()}),[v,n]);(0,l.useEffect)((()=>(document.addEventListener("keydown",b,!1),()=>{document.removeEventListener("keydown",b,!1)})),[]);return p().createElement(p().Fragment,null,p().createElement("div",{className:"jp-connection__disconnect-dialog__content"},p().createElement("h1",{id:"jp-connection__disconnect-dialog__heading"},t),p().createElement(u.Z,{connectedPlugins:d,disconnectingPlugin:m}),i,(()=>{if(!(d&&Object.keys(d).filter((e=>e!==m)).length)&&!i)return p().createElement("div",{className:"jp-connection__disconnect-dialog__step-copy"},p().createElement("p",{className:"jp-connection__disconnect-dialog__large-text"},__("Jetpack is currently powering multiple products on your site.","jetpack-my-jetpack"),p().createElement("br",null),__("Once you disconnect Jetpack, these will no longer work.","jetpack-my-jetpack")))})()),p().createElement("div",{className:"jp-connection__disconnect-dialog__actions"},p().createElement("div",{className:"jp-row"},p().createElement("div",{className:"lg-col-span-8 md-col-span-9 sm-col-span-4"},p().createElement("p",null,(0,r.createInterpolateElement)(__("Need help? Learn more about the Jetpack connection or contact Jetpack support.","jetpack-my-jetpack"),{strong:p().createElement("strong",null),jpConnectionInfoLink:p().createElement(a.ExternalLink,{href:(0,c.Z)("why-the-wordpress-com-connection-is-important-for-jetpack"),className:"jp-connection__disconnect-dialog__link",onClick:f}),jpSupportLink:p().createElement(a.ExternalLink,{href:(0,c.Z)("jetpack-support"),className:"jp-connection__disconnect-dialog__link",onClick:k})}))),p().createElement("div",{className:"jp-connection__disconnect-dialog__button-wrap lg-col-span-4 md-col-span-7 sm-col-span-4"},p().createElement(a.Button,{variant:"primary",disabled:n,onClick:v,className:"jp-connection__disconnect-dialog__btn-dismiss"},"plugins"===h?__("Cancel","jetpack-my-jetpack"):__("Stay connected","jetpack-my-jetpack",0)),(()=>{let e=__("Disconnect","jetpack-my-jetpack");return n?e=__("Disconnecting…","jetpack-my-jetpack"):"plugins"===h&&(e=__("Deactivate","jetpack-my-jetpack")),p().createElement(a.Button,{variant:"primary",disabled:n,onClick:E,className:"jp-connection__disconnect-dialog__btn-disconnect"},e)})())),s&&p().createElement("p",{className:"jp-connection__disconnect-dialog__error"},s)))};d.propTypes={title:i().string,isDisconnecting:i().bool,onDisconnect:i().func,disconnectError:i().bool,disconnectStepComponent:i().element,connectedPlugins:i().array,disconnectingPlugin:i().string,closeModal:i().func,context:i().string,trackModalClick:i().func};const m=d},1702:(e,t,n)=>{"use strict";n.d(t,{Z:()=>p});var c=n(5736),a=n(5162),r=n.n(a),o=n(9196),s=n.n(o),i=(n(9823),n(6336));const __=c.__,l=e=>{const{onExit:t,onFeedBackProvided:n,isSubmittingFeedback:c}=e;return s().createElement("div",{className:"jp-connection__disconnect-dialog__content"},s().createElement("h1",null,__("Before you go, help us improve Jetpack","jetpack-my-jetpack")),s().createElement("p",{className:"jp-connection__disconnect-dialog__large-text"},__("Let us know what didn‘t work for you","jetpack-my-jetpack")),s().createElement(i.Z,{onSubmit:n,isSubmittingFeedback:c}),s().createElement("a",{className:"jp-connection__disconnect-dialog__link jp-connection__disconnect-dialog__link--bold",href:"#",onClick:t},__("Skip for now","jetpack-my-jetpack")))};l.PropTypes={onExit:r().func,onFeedBackProvided:r().func,isSubmittingFeedback:r().bool};const p=l},1166:(e,t,n)=>{"use strict";n.d(t,{Z:()=>m});var c=n(9026),a=n(5609),r=n(9307),o=n(5736),s=n(5162),i=n.n(s),l=n(9196),p=n.n(l),u=n(724);const __=o.__,d=e=>{const{onExit:t}=e;return p().createElement("div",{className:"jp-connection__disconnect-dialog__content"},p().createElement(c.Z,{format:"vertical",imageUrl:u}),p().createElement("div",{className:"jp-connection__disconnect-dialog__copy"},p().createElement("h1",null,__("Thank you!","jetpack-my-jetpack")),p().createElement("p",{className:"jp-connection__disconnect-dialog__large-text"},(0,r.createInterpolateElement)(__("Your answer has been submitted.
        Thanks for your input on how we can improve Jetpack.","jetpack-my-jetpack"),{br:p().createElement("br",null)})),p().createElement(a.Button,{variant:"primary",onClick:t,className:"jp-connection__disconnect-dialog__btn-back-to-wp"},__("Back to my website","jetpack-my-jetpack"))))};d.PropTypes={onExit:i().func,assetBaseUrl:i().string};const m=d},6336:(e,t,n)=>{"use strict";n.d(t,{Z:()=>u});var c=n(5609),a=n(5736),r=n(5162),o=n.n(r),s=n(9196),i=n.n(s),l=n(4372);const __=a.__,p=e=>{const{onSubmit:t,isSubmittingFeedback:n}=e,[a,r]=(0,s.useState)(),[o,p]=(0,s.useState)(),u=[{id:"troubleshooting",answerText:__("Troubleshooting - I'll be reconnecting afterwards.","jetpack-my-jetpack")},{id:"not-working",answerText:__("I can't get it to work.","jetpack-my-jetpack")},{id:"slowed-down-site",answerText:__("It slowed down my site.","jetpack-my-jetpack")},{id:"buggy",answerText:__("It's buggy.","jetpack-my-jetpack")},{id:"what-does-it-do",answerText:__("I don't know what it does.","jetpack-my-jetpack")}],d="another-reason",m=(0,s.useCallback)((()=>{t(a,a===d?o:"")}),[t,d,o,a]),g=(0,s.useCallback)((e=>{const t=e.target.value;e.stopPropagation(),p(t)}),[p]),h=e=>e===a?"jp-connect__disconnect-survey-card--selected":"",y=(0,s.useCallback)(((e,t)=>{switch(t.key){case"Enter":case"Space":case"Spacebar":case" ":r(e)}}),[r]);return i().createElement(i().Fragment,null,i().createElement("div",{className:"jp-connection__disconnect-dialog__survey"},u.map((e=>i().createElement(l.Z,{id:e.id,onClick:r,onKeyDown:y,className:"card jp-connect__disconnect-survey-card "+h(e.id)},i().createElement("p",{className:"jp-connect__disconnect-survey-card__answer"},e.answerText)))),i().createElement(l.Z,{id:d,onClick:r,onKeyDown:y,className:"card jp-connect__disconnect-survey-card "+h(d)},i().createElement("p",{className:"jp-connect__disconnect-survey-card__answer"},__("Other:","jetpack-my-jetpack")," ",i().createElement("input",{placeholder:__("share your experience","jetpack-my-jetpack"),className:"jp-connect__disconnect-survey-card__input",type:"text",value:o,onChange:g,maxLength:1e3})))),i().createElement("p",null,i().createElement(c.Button,{disabled:!a||n,variant:"primary",onClick:m,className:"jp-connection__disconnect-dialog__btn-back-to-wp"},n?__("Submitting…","jetpack-my-jetpack"):__("Submit Feedback","jetpack-my-jetpack",0))))};p.PropTypes={onSubmit:o().func,isSubmittingFeedback:o().bool};const u=p},4372:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9196),a=n.n(c);n(9823);const r=e=>{const{id:t,onClick:n,onKeyDown:r,children:o,className:s}=e,i=(0,c.useCallback)((()=>{n(t)}),[t,n]),l=(0,c.useCallback)((e=>{r(t,e)}),[t,r]);return a().createElement("div",{tabIndex:"0",role:"button",onClick:i,onKeyDown:l,className:"card jp-connect__disconnect-survey-card "+s},o)}},8137:(e,t,n)=>{"use strict";n.d(t,{Z:()=>j});var c=n(5106),a=n(6895),r=n(526),o=n(5609),s=n(9307),i=n(5736),l=n(1074),p=n(6936),u=n(5381),d=n(5235),m=n.n(d),g=n(5162),h=n.n(g),y=n(9196),f=n.n(y),k=n(6168);n(7664);const __=i.__,v=e=>{const{title:t,apiRoot:n,apiNonce:r,connectedPlugins:s,onDisconnected:i,context:l,connectedUser:p,connectedSiteId:u,isOpen:d,onClose:m}=e,[g,h]=(0,y.useState)(!1),v=(0,y.useCallback)((e=>{e&&e.preventDefault(),h(!0)}),[h]),j=(0,y.useCallback)((e=>{e&&e.preventDefault(),h(!1)}),[h]);return f().createElement(f().Fragment,null,d&&f().createElement(f().Fragment,null,f().createElement(o.Modal,{title:"",contentLabel:t,aria:{labelledby:"jp-connection__manage-dialog__heading"},shouldCloseOnClickOutside:!1,shouldCloseOnEsc:!1,isDismissible:!1,className:"jp-connection__manage-dialog"},f().createElement("div",{className:"jp-connection__manage-dialog__content"},f().createElement("h1",{id:"jp-connection__manage-dialog__heading"},t),f().createElement(c.ZP,{className:"jp-connection__manage-dialog__large-text"},__("At least one user must be connected for your Jetpack products to work properly.","jetpack-my-jetpack")),f().createElement(E,{title:__("Transfer ownership to another admin","jetpack-my-jetpack"),link:(0,a.Z)("calypso-settings-manage-connection",{site:window?.myJetpackInitialState?.siteSuffix}),key:"transfer",action:"transfer"}),f().createElement(E,{title:__("Disconnect Jetpack","jetpack-my-jetpack"),onClick:v,key:"disconnect",action:"disconnect"})),f().createElement(b,{onClose:m})),f().createElement(k.Z,{apiRoot:n,apiNonce:r,onDisconnected:i,connectedPlugins:s,connectedSiteId:u,connectedUser:p,isOpen:g,onClose:j,context:l})))},E=e=>{let{title:t,onClick:n=(()=>null),link:c="#",action:a}=e;return f().createElement("div",{className:"jp-connection__manage-dialog__action-card card"},f().createElement("div",{className:"jp-connection__manage-dialog__action-card__card-content"},f().createElement("a",{href:c,className:m()("jp-connection__manage-dialog__action-card__card-headline",a),onClick:n},t,f().createElement(l.Z,{icon:"disconnect"===a?p.Z:u.Z,className:"jp-connection__manage-dialog__action-card__icon"}))))},b=e=>{let{onClose:t}=e;return f().createElement("div",{className:"jp-row jp-connection__manage-dialog__actions"},f().createElement("div",{className:"jp-connection__manage-dialog__text-wrap lg-col-span-9 md-col-span-7 sm-col-span-3"},f().createElement(c.ZP,null,(0,s.createInterpolateElement)(__("Need help? Learn more about the Jetpack connection or contact Jetpack support","jetpack-my-jetpack"),{strong:f().createElement("strong",null),connectionInfoLink:f().createElement(o.ExternalLink,{href:(0,a.Z)("why-the-wordpress-com-connection-is-important-for-jetpack"),className:"jp-connection__manage-dialog__link"}),supportLink:f().createElement(o.ExternalLink,{href:(0,a.Z)("jetpack-support"),className:"jp-connection__manage-dialog__link"})}))),f().createElement("div",{className:"jp-connection__manage-dialog__button-wrap lg-col-span-3 md-col-span-1 sm-col-span-1"},f().createElement(r.Z,{weight:"regular",variant:"secondary",onClick:t,className:"jp-connection__manage-dialog__btn-dismiss"},__("Cancel","jetpack-my-jetpack"))))};v.propTypes={title:h().string,apiRoot:h().string.isRequired,apiNonce:h().string.isRequired,connectedPlugins:h().oneOfType([h().array,h().object]),onDisconnected:h().func,context:h().string,connectedUser:h().object,connectedSiteId:h().number,isOpen:h().bool,onClose:h().func},v.defaultProps={title:__("Manage your Jetpack connection","jetpack-my-jetpack"),isOpen:!1,context:"jetpack-dashboard",connectedUser:{}};const j=v},1294:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});var c=n(4743),a=n(9818),r=n(9196),o=n(428);const s=window?.JP_CONNECTION_INITIAL_STATE?window.JP_CONNECTION_INITIAL_STATE:{},i=function(){let{registrationNonce:e=s.registrationNonce,apiRoot:t=s.apiRoot,apiNonce:n=s.apiNonce,redirectUri:i,autoTrigger:l,from:p,skipUserConnection:u}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const{registerSite:d,connectUser:m,refreshConnectedPlugins:g}=(0,a.useDispatch)(o.t),h=(0,a.useSelect)((e=>e(o.t).getRegistrationError())),{siteIsRegistering:y,userIsConnecting:f,userConnectionData:k,connectedPlugins:v,connectionErrors:E,isRegistered:b,isUserConnected:j,hasConnectedOwner:_}=(0,a.useSelect)((e=>({siteIsRegistering:e(o.t).getSiteIsRegistering(),userIsConnecting:e(o.t).getUserIsConnecting(),userConnectionData:e(o.t).getUserConnectionData(),connectedPlugins:e(o.t).getConnectedPlugins(),connectionErrors:e(o.t).getConnectionErrors(),...e(o.t).getConnectionStatus()}))),C=()=>u?i?(window.location=i,Promise.resolve(i)):Promise.resolve():m({from:p,redirectUri:i}),w=t=>(t&&t.preventDefault(),b?C():d({registrationNonce:e,redirectUri:i}).then((()=>C())));return(0,r.useEffect)((()=>{c.ZP.setApiRoot(t),c.ZP.setApiNonce(n)}),[t,n]),(0,r.useEffect)((()=>{!l||y||f||w()}),[]),{handleRegisterSite:w,handleConnectUser:C,refreshConnectedPlugins:g,isRegistered:b,isUserConnected:j,siteIsRegistering:y,userIsConnecting:f,registrationError:h,userConnectionData:k,hasConnectedOwner:_,connectedPlugins:v,connectionErrors:E}}},3329:(e,t,n)=>{"use strict";n.d(t,{Z:()=>o,h:()=>s});var c=n(6186),a=n(1294),r=n(1045);function o(){const{connectionErrors:e}=(0,a.Z)({}),t=Object.values(e).shift(),n=t&&Object.values(t).length&&Object.values(t).shift().error_message;return{hasConnectionError:Boolean(n),connectionErrorMessage:n}}const s=()=>{const{hasConnectionError:e,connectionErrorMessage:t}=o(),{restoreConnection:n,isRestoringConnection:a,restoreConnectionError:s}=(0,r.Z)();return e?React.createElement(c.Z,{isRestoringConnection:a,restoreConnectionError:s,restoreConnectionCallback:n,message:t}):null}},8258:(e,t,n)=>{"use strict";n.d(t,{Z:()=>y});var c=n(4743),a=n(4153),r=n(9818),o=n(951),s=n.n(o),i=n(9196),l=n(1294),p=n(428);const u=s()("jetpack:connection:useProductCheckoutWorkflow"),{registrationNonce:d,apiRoot:m,apiNonce:g,siteSuffix:h}=window?.JP_CONNECTION_INITIAL_STATE?window.JP_CONNECTION_INITIAL_STATE:{};function y(){let{productSlug:e,redirectUrl:t,siteSuffix:n=h,siteProductAvailabilityHandler:o=null,from:s}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};u("productSlug is %s",e),u("redirectUrl is %s",t),u("siteSuffix is %s",n),u("from is %s",s);const[y,f]=(0,i.useState)(!1),{registerSite:k}=(0,r.useDispatch)(p.t),{isUserConnected:v,isRegistered:E,handleConnectUser:b}=(0,l.Z)({redirectUri:t,from:s}),j=(0,a.Z)(e,n,t,v);u("checkoutProductUrl is %s",j),u("isUserConnected is %s",v);const _=()=>Promise.resolve(o&&o()).then((e=>{if(e)return u("handleAfterRegistration: Site has a product associated"),b();u("handleAfterRegistration: Site does not have a product associated. Redirecting to checkout %s",j),window.location.href=j}));return(0,i.useEffect)((()=>{c.ZP.setApiRoot(m),c.ZP.setApiNonce(g)}),[]),{run:e=>{if(e&&e.preventDefault(),f(!0),E)return _();k({registrationNonce:d,redirectUri:t}).then(_)},isRegistered:E,hasCheckoutStarted:y}}},1045:(e,t,n)=>{"use strict";n.d(t,{Z:()=>l});var c=n(4743),a=n(9818),r=n(9196),o=n(428);const{apiRoot:s,apiNonce:i}=window?.JP_CONNECTION_INITIAL_STATE?window.JP_CONNECTION_INITIAL_STATE:{};function l(){const[e,t]=(0,r.useState)(!1),[n,l]=(0,r.useState)(null),{disconnectUserSuccess:p}=(0,a.useDispatch)(o.t),u="/wp-admin/admin.php?page=my-jetpack#/connection";return(0,r.useEffect)((()=>{c.ZP.setApiRoot(s),c.ZP.setApiNonce(i)}),[]),{restoreConnection:function(){let e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return t(!0),l(null),c.ZP.reconnect().then((t=>("in_progress"===t.status?(p(),e&&(window.location.href=u)):window.location.reload(),t))).catch((e=>{throw l(e),t(!1),e}))},isRestoringConnection:e,restoreConnectionError:n}}},7523:(e,t,n)=>{"use strict";n.d(t,{LI:()=>r,N4:()=>s,Qo:()=>m,T1:()=>l,TS:()=>u,ZP:()=>_,b5:()=>h,i6:()=>a,qV:()=>i,r7:()=>o,wQ:()=>g});var c=n(4743);const a="SET_CONNECTION_STATUS",r="SET_CONNECTION_STATUS_IS_FETCHING",o="SET_SITE_IS_REGISTERING",s="SET_USER_IS_CONNECTING",i="SET_REGISTRATION_ERROR",l="CLEAR_REGISTRATION_ERROR",p="REGISTER_SITE",u="SET_AUTHORIZATION_URL",d="CONNECT_USER",m="DISCONNECT_USER_SUCCESS",g="SET_CONNECTED_PLUGINS",h="SET_CONNECTION_ERRORS",y=e=>({type:a,connectionStatus:e}),f=e=>({type:o,isRegistering:e}),k=e=>({type:s,isConnecting:e}),v=e=>({type:i,registrationError:e}),E=()=>({type:l}),b=e=>({type:u,authorizationUrl:e}),j=e=>({type:g,connectedPlugins:e});const _={setConnectionStatus:y,setConnectionStatusIsFetching:e=>({type:r,isFetching:e}),fetchConnectionStatus:()=>({type:"FETCH_CONNECTION_STATUS"}),fetchAuthorizationUrl:e=>({type:"FETCH_AUTHORIZATION_URL",redirectUri:e}),setSiteIsRegistering:f,setUserIsConnecting:k,setRegistrationError:v,clearRegistrationError:E,setAuthorizationUrl:b,registerSite:function(e){let{registrationNonce:t,redirectUri:n}=e;return function*(){yield E(),yield f(!0);try{const e=yield{type:p,registrationNonce:t,redirectUri:n};return yield y({isRegistered:!0}),yield b(e.authorizeUrl),yield f(!1),Promise.resolve(e)}catch(e){return yield v(e),yield f(!1),Promise.reject(e)}}()},connectUser:function(){let{from:e,redirectFunc:t,redirectUri:n}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return function*(){yield k(!0),yield{type:d,from:e,redirectFunc:t,redirectUri:n}}()},disconnectUserSuccess:()=>({type:m}),setConnectedPlugins:j,refreshConnectedPlugins:()=>async e=>{let{dispatch:t}=e;return await new Promise((e=>c.ZP.fetchConnectedPlugins().then((n=>{t(j(n)),e(n)}))))},setConnectionErrors:e=>({type:h,connectionErrors:e})}},1432:(e,t,n)=>{"use strict";n.d(t,{Z:()=>o});var c=n(4743),a=n(9818),r=n(7057);const o={FETCH_AUTHORIZATION_URL:e=>{let{redirectUri:t}=e;return c.ZP.fetchAuthorizationUrl(t)},REGISTER_SITE:e=>{let{registrationNonce:t,redirectUri:n}=e;return c.ZP.registerSite(t,n)},CONNECT_USER:(0,a.createRegistryControl)((e=>{let{resolveSelect:t}=e;return function(){let{from:e,redirectFunc:n,redirectUri:c}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return new Promise(((a,o)=>{t(r.Z).getAuthorizationUrl(c).then((t=>{const c=n||(e=>window.location.assign(e)),r=new URL(t);e&&r.searchParams.set("from",encodeURIComponent(e));const o=r.toString();c(o),a(o)})).catch((e=>{o(e)}))}))}}))}},1479:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9818),a=n(7523);const r=(0,c.combineReducers)({connectionStatus:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case a.i6:return{...e,...t.connectionStatus};case a.Qo:return{...e,isUserConnected:!1}}return e},connectionStatusIsFetching:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;return t.type===a.LI?t.isFetching:e},siteIsRegistering:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;return t.type===a.r7?t.isRegistering:e},userIsConnecting:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1?arguments[1]:void 0;return t.type===a.N4?t.isConnecting:e},registrationError:(e,t)=>{switch(t.type){case a.T1:return!1;case a.qV:return t.registrationError;default:return e}},authorizationUrl:(e,t)=>t.type===a.TS?t.authorizationUrl:e,userConnectionData:(e,t)=>(t.type,e),connectedPlugins:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return t.type===a.wQ?t.connectedPlugins:e},connectionErrors:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return t.type===a.b5?t.connectionErrors:e}})},7728:(e,t,n)=>{"use strict";n.d(t,{Z:()=>o});var c=n(9818),a=n(7523),r=n(7057);const o={...{getAuthorizationUrl:{isFulfilled:function(e){const t=Boolean(e.authorizationUrl);for(var n=arguments.length,a=new Array(n>1?n-1:0),o=1;o{"use strict";n.d(t,{Z:()=>c});const c={...{getConnectionStatus:e=>e.connectionStatus||{},getConnectionStatusIsFetching:()=>!1,getSiteIsRegistering:e=>e.siteIsRegistering||!1,getUserIsConnecting:e=>e.userIsConnecting||!1,getRegistrationError:e=>e.registrationError||!1,getAuthorizationUrl:e=>e.authorizationUrl||!1,getUserConnectionData:e=>e.userConnectionData||!1,getConnectedPlugins:e=>e.connectedPlugins||[],getConnectionErrors:e=>e.connectionErrors||[],getWpcomUser:e=>e?.userConnectionData?.currentUser?.wpcomUser,getBlogId:e=>e?.userConnectionData?.currentUser?.blogId}}},3535:(e,t,n)=>{"use strict";n.d(t,{Z:()=>s});var c=n(17),a=n.n(c),r=n(9818);class o{static mayBeInit(e,t){null===o.store&&(o.store=(0,r.createReduxStore)(e,t),(0,r.register)(o.store))}}a()(o,"store",null);const s=o},7057:(e,t,n)=>{"use strict";n.d(t,{Z:()=>c});const c="jetpack-connection"},428:(e,t,n)=>{"use strict";n.d(t,{t:()=>l.Z});var c=n(7523),a=n(1432),r=n(1479),o=n(7728),s=n(2725),i=n(3535),l=n(7057);const p=window.JP_CONNECTION_INITIAL_STATE;p||console.error("Jetpack Connection package: Initial state is missing. Check documentation to see how to use the Connection composer package to set up the initial state."),i.Z.mayBeInit(l.Z,{__experimentalUseThunks:!0,reducer:r.Z,actions:c.ZP,selectors:s.Z,resolvers:o.Z,controls:a.Z,initialState:p||{}})},8728:(e,t,n)=>{"use strict";n.d(t,{Z:()=>k});var c=n(6975),a=n(8868),r=n(5033),o=n(5609),s=n(9307),i=n(5736),l=n(1074),p=n(797),u=n(5844),d=n.n(u),m=n(9196),g=n.n(m);const __=i.__,h=e=>{const{className:t,disabled:n,onChange:c,value:a}=e;return g().createElement(o.TextControl,{className:t,label:__("License key","jetpack-my-jetpack"),value:a,onChange:c,disabled:n})},y=e=>{const{className:t,availableLicenses:n,disabled:c,onChange:a,value:r}=e,[s,l]=(0,m.useState)(""),p=null===n,u=(0,m.useMemo)((()=>p?[{label:__("Fetching available licenses…","jetpack-my-jetpack"),value:""}]:[...n.map((e=>{let{product:t,license_key:n}=e;return{label:(0,i.sprintf)(/* translators: placeholder is the product name and license key */ -__("%1$s - %2$s","jetpack-my-jetpack"),t,n),value:n}})),{label:__("I want to add a license key manually","jetpack-my-jetpack"),value:""}]),[n,p]);(0,m.useEffect)((()=>{l(u?.length?u[0].value:"")}),[u]);const d=(0,m.useCallback)((e=>{l(e),a(e)}),[a]);return g().createElement(g().Fragment,null,g().createElement(o.SelectControl,{className:t,disabled:c,label:__("Select a license key","jetpack-my-jetpack"),value:s,options:u,onChange:d}),!p&&!s&&g().createElement(o.TextControl,{className:t,label:__("Input a license key","jetpack-my-jetpack"),value:r,onChange:a,disabled:c}))},f=e=>{const{activateLicense:t,availableLicenses:n,fetchingAvailableLicenses:i,isActivating:u,license:d,licenseError:f,onLicenseChange:k}=e,v=null!=f;(0,m.useEffect)((()=>{c.Z.tracks.recordEvent("jetpack_wpa_license_key_activation_view")}),[]);const E=v?"jp-license-activation-screen-controls--license-field-with-error":"jp-license-activation-screen-controls--license-field",b=n&&n.length;return g().createElement("div",{className:"jp-license-activation-screen-controls"},g().createElement("div",{className:"jp-license-activation-screen-controls--content"},g().createElement(a.Z,{showText:!1,height:48}),g().createElement("h1",null,__("Add a license key","jetpack-my-jetpack")),g().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:g().createElement("strong",null)})),i||b?g().createElement(y,{className:E,disabled:i||u,onChange:k,availableLicenses:i?null:n,value:d}):g().createElement(h,{className:E,disabled:u,onChange:k,value:d}),v&&g().createElement("div",{className:"jp-license-activation-screen-controls--license-field-error"},g().createElement(l.Z,{icon:p.Z}),g().createElement("span",null,f))),g().createElement("div",null,g().createElement(o.Button,{className:"jp-license-activation-screen-controls--button",onClick:t,disabled:!d},u?g().createElement(r.Z,null):__("Activate","jetpack-my-jetpack"))))};f.propTypes={activateLicense:d().func.isRequired,availableLicenses:d().array,fetchingAvailableLicenses:d().bool,isActivating:d().bool.isRequired,license:d().string.isRequired,licenseError:d().string,onLicenseChange:d().func.isRequired,siteUrl:d().string.isRequired};const k=f},8781:(e,t,n)=>{"use strict";n.d(t,{Z:()=>u});var c=n(6895),a=n(9307),r=n(5736),o=n(5844),s=n.n(o),i=n(9196),l=n.n(i);const __=r.__,p=e=>{const{imageUrl:t,showSupportLink:n=!1}=e;return l().createElement("div",{className:"jp-license-activation-screen-illustration"},l().createElement("div",{className:"jp-license-activation-screen-illustration--wrapper"},l().createElement("img",{className:"jp-license-activation-screen-illustration--img",src:t,alt:""})),n&&l().createElement("p",{className:"jp-license-activation-screen-illustration--support-link"},(0,a.createInterpolateElement)(__("Do you need help? Contact us.","jetpack-my-jetpack"),{a:l().createElement("a",{href:(0,c.Z)("jetpack-support-license-activation")})})))};p.propTypes={imageUrl:s().string.isRequired,showSupportLink:s().bool};const u=p},7554:(e,t,n)=>{"use strict";n.d(t,{Z:()=>d});var c=n(8868),a=n(5844),r=n.n(a),o=n(9196),s=n.n(o),i=n(3157),l=n(8288),p=n(4172);const u=e=>{const{productId:t,siteRawUrl:n,siteAdminUrl:a,currentRecommendationsStep:r}=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(c.Z,{showText:!1,height:48})),s().createElement(l.Z,{siteRawUrl:n,productId:t}),s().createElement("div",{className:"jp-license-activation-screen-success-info--buttons"},s().createElement(i.c,{currentRecommendationsStep:r,siteAdminUrl:a,siteRawUrl:n}),s().createElement(p.o,{siteRawUrl:n,productId:t})))};u.propTypes={siteRawUrl:r().string,productId:r().number,siteAdminUrl:r().string,currentRecommendationsStep:r().string};const d=u},3157:(e,t,n)=>{"use strict";n.d(t,{c:()=>p});var c=n(6895),a=n(5609),r=n(5736),o=n(5844),s=n.n(o),i=n(9196),l=n.n(i);const __=r.__,p=e=>{const{currentRecommendationsStep:t,siteAdminUrl:n,siteRawUrl:r}=e;return"not-started"===t?l().createElement(a.Button,{className:"jp-license-activation-screen-success-info--button",href:n+"admin.php?page=jetpack#/recommendations"},__("Configure my site","jetpack-my-jetpack")):l().createElement(a.Button,{className:"jp-license-activation-screen-success-info--button",href:(0,c.Z)("license-activation-view-my-plans",{site:r})},__("View my plans","jetpack-my-jetpack"))};p.propTypes={siteAdminUrl:s().string.isRequired,currentRecommendationsStep:s().string,siteRawUrl:s().string.isRequired}},4172:(e,t,n)=>{"use strict";n.d(t,{o:()=>u});var c=n(6895),a=n(5609),r=n(5736),o=n(5844),s=n.n(o),i=n(9196),l=n.n(i),p=n(9430);const __=r.__,u=e=>{const{productId:t,siteRawUrl:n}=e,r={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 scan results","jetpack-my-jetpack"),redirectSource:"jetpack-license-activation-success-scan"},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,p.F)(t)];return l().createElement(l().Fragment,null,r&&l().createElement(a.ExternalLink,{className:"jp-license-activation-screen-success-info--external-link",href:(0,c.Z)(r.redirectSource,{site:n})},r.text))};u.propTypes={siteRawUrl:s().string,productId:s().number}},468:(e,t,n)=>{"use strict";n.d(t,{Z:()=>k});var c=n(6975),a=n(4743),r=n(9307),o=n(5736),s=n(5844),i=n.n(s),l=n(9196),p=n.n(l),u=n(8728),d=n(8781),m=n(7554),g=n(9644),h=n(8702),y=n(1160);const __=o.__,f=e=>{const{availableLicenses:t=[],currentRecommendationsStep:n,fetchingAvailableLicenses:o=!1,onActivationSuccess:s=(()=>null),siteAdminUrl:i,siteRawUrl:f,startingLicense:k,displayName:v=""}=e,[E,b]=(0,l.useState)(k??""),[j,_]=(0,l.useState)(null),[C,w]=(0,l.useState)(!1),[Z,N]=(0,l.useState)(null);(0,l.useEffect)((()=>{t&&t[0]&&b(t[0].license_key)}),[t]);const S=(0,l.useCallback)((()=>C?Promise.resolve():E.length<1?(_(__("This is not a valid license key. Please try again.","jetpack-my-jetpack")),Promise.resolve()):(_(null),w(!0),c.Z.tracks.recordJetpackClick({target:"license_activation_button"}),a.ZP.attachLicenses([E]).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);N(t),s(t),c.Z.tracks.recordEvent("jetpack_wpa_license_activation_success")})).catch((e=>{c.Z.tracks.recordEvent("jetpack_wpa_license_activation_error");"invalid_permission_manage_user_licenses"===e.response?.code?_((0,r.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:p().createElement("a",{href:"admin.php?page=my-jetpack#/connection?returnTo=add-license"})})):_(e.message)})).finally((()=>{w(!1)})))),[C,E,s]);return null!==Z&&E.startsWith("jetpack-golden-token")?p().createElement(g.Z,{tokenRedeemed:!0,displayName:v}):null!==Z?p().createElement("div",{className:"jp-license-activation-screen"},p().createElement(m.Z,{siteRawUrl:f,productId:Z,siteAdminUrl:i,currentRecommendationsStep:n}),p().createElement(d.Z,{imageUrl:y,showSupportLink:!1})):p().createElement("div",{className:"jp-license-activation-screen"},p().createElement(u.Z,{availableLicenses:t,activateLicense:S,fetchingAvailableLicenses:o,isActivating:C,license:E,licenseError:j,onLicenseChange:b,siteUrl:f}),p().createElement(d.Z,{imageUrl:h,showSupportLink:!0}))};f.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 k=f},9644:(e,t,n)=>{"use strict";n.d(t,{Z:()=>k});var c=n(3396),a=n(3363),r=n(3846),o=n(8868),s=n(526),i=n(5609),l=n(5736),p=n(5235),u=n.n(p),d=n(5844),m=n.n(d),g=n(9196),h=n.n(g),y=n(1008);const __=l.__,_x=l._x;function f(e){let{redeemClick:t,displayName:n,onModalClose:p,tokenRedeemed:d}=e;const[m,f]=(0,g.useState)(!1),k=(0,g.useRef)(null);(0,g.useEffect)((()=>{setTimeout((()=>{k?.current?.play()}),500)}),[k]);const v=(0,c.VS)("scan"),E=(0,c.VS)("backup"),b=(0,g.useCallback)((e=>{t?.(e),f(!0),k.current.play()}),[k,t]),j=(0,g.useCallback)((()=>{m&&k.current.play()}),[m]),_=u()(y.Z.modal,{[y.Z.animating]:m});return h().createElement("div",null,h().createElement(i.Modal,{className:_,onRequestClose:p,isDismissible:!1,__experimentalHideHeader:!0},h().createElement(a.Z,{horizontalSpacing:3,horizontalGap:3},h().createElement(r.Z,null,h().createElement(o.Z,{className:y.Z["jetpack-logo"]}),h().createElement("div",{className:y.Z["video-wrap"],onClick:j,role:"presentation"},h().createElement("video",{ref:k,src:"https://videos.files.wordpress.com/oSlNIBQO/jetpack-golden-token.mp4",muted:"muted"})),h().createElement("div",{className:y.Z["content-wrap"]},h().createElement("div",{className:y.Z["content-wrap-text"]},n.length>0&&h().createElement("p",{className:y.Z["hi-user"]},(0,l.sprintf)(/* Translators: %s is the user's display name. */ -__("Hey, %s","jetpack-my-jetpack"),n)),h().createElement("h2",{className:y.Z.headline},__("You have been gifted a Jetpack Gold Token.","jetpack-my-jetpack")),h().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"))),h().createElement(s.Z,{variant:"primary",weight:"regular",onClick:b,className:y.Z.button},d&&__("Awesome!","jetpack-my-jetpack"),!d&&__("Redeem your token","jetpack-my-jetpack"))),h().createElement("div",{className:`${y.Z["powers-wrap"]} ${y.Z["content-wrap"]}`},h().createElement("div",{className:y.Z["content-wrap-text"]},h().createElement("h2",{className:y.Z.headline},__("Super powers are ready!","jetpack-my-jetpack")),h().createElement("p",{className:y.Z.paragraph},__("Your Jetpack Gold Token provides a lifetime license for this website and includes the following products:","jetpack-my-jetpack"))),h().createElement("div",{className:y.Z["jetpack-products"]},h().createElement("div",null,h().createElement(E,null),h().createElement("h3",null,__("VaultPress Backup","jetpack-my-jetpack")),h().createElement("p",null,__("Save every change and get back online quickly with one‑click restores.","jetpack-my-jetpack"))),h().createElement("div",null,h().createElement(v,null),h().createElement("h3",null,_x("Scan","Plugin name (noun).","jetpack-my-jetpack")),h().createElement("p",null,__("Automated scanning and one‑click fixes to keep your site ahead of security threats.","jetpack-my-jetpack")))),h().createElement(s.Z,{variant:"primary",weight:"regular",onClick:b,href:window?.myJetpackInitialState?.myJetpackUrl,className:y.Z.button},__("Explore your new powers","jetpack-my-jetpack")))))))}f.defaultProps={tokenRedeemed:!1,onModalClose:e=>{document.referrer.includes(window.location.host)?(e.preventDefault(),history.back()):(e.preventDefault(),window.location.href=window?.myJetpackInitialState?.myJetpackUrl)}},f.propTypes={redeemClick:m().func,tokenRedeemed:m().bool,displayName:m().string,onModalClose:m().func};const k=f},3281:(e,t,n)=>{"use strict";n.d(t,{H:()=>a.Z,I:()=>c.Z});var c=n(468),a=n(9644)},1899:(e,t,n)=>{"use strict";n.d(t,{Z:()=>g});var c=n(4743),a=n(9105),r=n(3363),o=n(3846),s=n(1294),i=n(3281),l=n(9196),p=n.n(l),u=n(2199),d=n(4106),m=n(5626);function g(){(0,l.useEffect)((()=>{const{apiRoot:e,apiNonce:t}=window?.myJetpackRest||{};c.ZP.setApiRoot(e),c.ZP.setApiNonce(t)}),[]);const{recordEvent:e}=(0,u.Z)(),{availableLicenses:t,fetchingAvailableLicenses:n}=(0,d.Z)(),{userConnectionData:g}=(0,s.Z)(),h=g?.currentUser?.wpcomUser?.display_name||g?.currentUser?.wpcomUser?.login||g?.currentUser?.username,y=(0,l.useCallback)((t=>{e("jetpack_myjetpack_license_activation_back_link_click"),document.referrer.includes(window.location.host)&&(t.preventDefault(),history.back())}),[e]);return p().createElement(a.Z,{showHeader:!1,showBackground:!1},p().createElement(r.Z,{horizontalSpacing:3,horizontalGap:3},p().createElement(o.Z,null,p().createElement(m.Z,{onClick:y})),p().createElement(o.Z,null,p().createElement(i.I,{currentRecommendationsStep:null,availableLicenses:t,fetchingAvailableLicenses:n,onActivationSuccess:void 0,siteAdminUrl:window?.myJetpackInitialState?.adminUrl,siteRawUrl:window?.myJetpackInitialState?.siteSuffix,displayName:h}))))}},3890:(e,t,n)=>{"use strict";n.d(t,{Z:()=>u});var c=n(1074),a=n(9517),r=n(5235),o=n.n(r),s=n(9196),i=n.n(s),l=n(9997),p=n(6234);const u=e=>{let{className:t}=e;return i().createElement(l.rU,{to:"/",className:o()(p.Z.link,t)},i().createElement(c.Z,{icon:a.Z,className:p.Z.icon}))}},5745:(e,t,n)=>{"use strict";n.d(t,{Z:()=>m});var c=n(3396),a=n(1294),r=n(5162),o=n.n(r),s=n(9196),i=n.n(s),l=n(3345),p=n(3703),u=n(2728);const d=e=>{let{admin:t,slug:n}=e;const{isRegistered:r,isUserConnected:o}=(0,a.Z)(),{detail:d,status:m,activate:g,deactivate:h,isFetching:y}=(0,p.i)(n),{name:f,description:k,manageUrl:v,requiresUserConnection:E}=d,b=(0,l.Z)("/connection"),j=(0,l.Z)(`add-${n}`),_=(0,s.useCallback)((()=>{window.location=v}),[v]),C=(0,s.useCallback)((()=>{r&&o||!E?g():b()}),[g,r,o,E,b]),w=(0,c.VS)(n);return i().createElement(u.Z,{name:f,description:k,status:m,icon:i().createElement(w,{opacity:.4}),admin:t,isFetching:y,onDeactivate:h,slug:n,onActivate:C,onAdd:j,onManage:_,onFixConnection:b})};d.propTypes={admin:o().bool.isRequired,slug:o().string.isRequired};const m=d},9841:(e,t,n)=>{"use strict";n.d(t,{Z:()=>_});var c=n(9105),a=n(3363),r=n(3846),o=n(6895),s=n(9312),i=n(5736),l=n(1074),p=n(5381),u=n(9196),d=n.n(u),m=n(9997),g=n(1689),h=n(3890),y=n(5242),f=n(6790),k=n(184),v=n(8578),E=n(4403);const __=i.__,b=()=>d().createElement(d().Fragment,null,d().createElement("div",{className:v.Z["account-description"]},__("You can use your existing account on any of these services:","jetpack-my-jetpack")),d().createElement("span",{className:v.Z["account-images"]},d().createElement("img",{src:E,className:v.Z.wordpress,alt:__("Wordpress Logo","jetpack-my-jetpack")}),d().createElement("img",{src:k,className:v.Z.google,alt:__("Google Logo","jetpack-my-jetpack")}),d().createElement("img",{src:y,className:v.Z.apple,alt:__("Apple Logo","jetpack-my-jetpack")}))),j=()=>{const[e]=(0,m.lr)(),t=e.get("returnTo");return t?`admin.php?page=my-jetpack#/${t}`:"admin.php?page=my-jetpack"},_=()=>{const{apiRoot:e,apiNonce:t}=(0,g.Z)(),n=j();return d().createElement(c.Z,{showHeader:!1,showBackground:!1},d().createElement(a.Z,{horizontalSpacing:8,horizontalGap:0},d().createElement(r.Z,{className:v.Z["relative-col"]},d().createElement(h.Z,{className:v.Z["close-link"]})),d().createElement(r.Z,null,d().createElement(s.Z,{title:__("Unlock all the amazing features of Jetpack by connecting now","jetpack-my-jetpack"),buttonLabel:__("Connect your user account","jetpack-my-jetpack"),apiRoot:e,apiNonce:t,images:[f],footer:d().createElement(b,null),from:"my-jetpack",redirectUri:n},d().createElement("ul",null,d().createElement("li",null,__("Receive instant downtime alerts","jetpack-my-jetpack")),d().createElement("li",null,__("Automatically share your content on social media","jetpack-my-jetpack")),d().createElement("li",null,__("Let your subscribers know when you post","jetpack-my-jetpack")),d().createElement("li",null,__("Receive notifications about new likes and comments","jetpack-my-jetpack")),d().createElement("li",null,__("Let visitors share your content on social media","jetpack-my-jetpack")),d().createElement("li",null,__("And more!","jetpack-my-jetpack")," ",d().createElement("a",{href:(0,o.Z)("jetpack-features"),target:"_blank",className:v.Z["all-features"],rel:"noreferrer"},__("See all Jetpack features","jetpack-my-jetpack"),d().createElement(l.Z,{icon:p.Z}))))))))}},247:(e,t,n)=>{"use strict";n.d(t,{Z:()=>Z});var c=n(5106),a=n(526),r=n(6895),o=n(1294),s=n(428),i=n(8137),l=n(9818),p=n(5736),u=n(1074),d=n(496),m=n(9201),g=n(5235),h=n.n(g),y=n(5162),f=n.n(y),k=n(9196),v=n.n(k),E=n(8489),b=n(3815),j=n(9182),_=n(6322);const __=p.__,C=e=>{let{text:t,actionText:n,onClick:r,status:o}=e;return v().createElement("div",{className:_.Z["list-item"]},v().createElement(c.ZP,{className:h()(_.Z["list-item-text"],{[_.Z.error]:"error"===o})},v().createElement(u.Z,{icon:"error"===o?d.Z:m.Z,className:h()({[_.Z.info]:"error"===o})}),t),n&&v().createElement(a.Z,{variant:"link",weight:"regular",onClick:r},n))},w=e=>{const{apiRoot:t,apiNonce:n,redirectUri:u,title:d,connectionInfoText:m,onDisconnected:g,connectedPlugins:y,connectedSiteId:f,context:w,onConnectUser:Z}=e,{isRegistered:N,isUserConnected:S,userConnectionData:R}=(0,o.Z)({apiRoot:t,apiNonce:n,redirectUri:u}),[P,x]=(0,k.useState)(!1),{setConnectionStatus:A,setUserIsConnecting:L}=(0,l.useDispatch)(s.t),I=Z||L,U=R.currentUser?.wpcomUser?.avatar,T=(0,k.useCallback)((e=>{e&&e.preventDefault(),x(!0)}),[x]),O=(0,k.useCallback)((e=>{e&&e.preventDefault(),x(!1)}),[x]),F=(0,k.useCallback)((e=>{e&&e.preventDefault(),A({isActive:!1,isRegistered:!1,isUserConnected:!1}),g?.()}),[g,A]);return v().createElement("div",{className:_.Z["connection-status-card"]},v().createElement(c.H3,null,d),v().createElement(c.ZP,{variant:"body",mb:3},`${m} `,v().createElement(a.Z,{href:(0,r.Z)("why-the-wordpress-com-connection-is-important-for-jetpack"),variant:"link",weight:"regular",isExternalLink:!0},__("Learn more about connections","jetpack-my-jetpack"))),v().createElement("div",{className:_.Z.status},v().createElement("img",{src:E,alt:"",className:_.Z.cloud}),v().createElement("div",{className:h()(_.Z.line,{[_.Z.disconnected]:!N||!S})}),v().createElement("div",{className:_.Z["avatar-wrapper"]},v().createElement("img",{src:j,alt:"",className:_.Z.jetpack}),v().createElement("img",{src:S&&U?U:b,alt:"",className:_.Z.avatar}))),v().createElement("div",null,N?v().createElement(v().Fragment,null,v().createElement(C,{onClick:T,text:__("Site connected.","jetpack-my-jetpack"),actionText:S&&R.currentUser?.isMaster?__("Manage","jetpack-my-jetpack"):null}),S&&v().createElement(C,{onClick:T,actionText:__("Manage","jetpack-my-jetpack"),text:(0,p.sprintf)(/* translators: first placeholder is user name, second is either the (Owner) string or an empty string */ -__("Connected as %1$s%2$s.","jetpack-my-jetpack"),R.currentUser?.wpcomUser?.display_name,R.currentUser?.isMaster?__(" (Owner)","jetpack-my-jetpack"):"")}),S&&!R.currentUser?.isMaster&&v().createElement(C,{text:(0,p.sprintf)(/* translators: placeholder is the username of the Jetpack connection owner */ -__("Also connected: %s (Owner).","jetpack-my-jetpack"),R.connectionOwner)}),!S&&v().createElement(C,{onClick:I,text:__("You’re not connected.","jetpack-my-jetpack"),actionText:__("Connect","jetpack-my-jetpack"),status:"error"})):v().createElement(C,{onClick:I,text:__("Jetpack is not connected.","jetpack-my-jetpack"),actionText:__("Connect","jetpack-my-jetpack"),status:"error"})),v().createElement(i.Z,{apiRoot:t,apiNonce:n,onDisconnected:F,connectedPlugins:y,connectedSiteId:f,connectedUser:R,isOpen:P,onClose:O,context:w}))};w.propTypes={apiRoot:f().string.isRequired,apiNonce:f().string.isRequired,redirectUri:f().string,connectedPlugins:f().array,connectedSiteId:f().number,title:f().string,connectionInfoText:f().string,onDisconnected:f().func,context:f().string,onConnectUser:f().func,requiresUserConnection:f().bool},w.defaultProps={title:__("Connection","jetpack-my-jetpack"),connectionInfoText:__("Jetpack connects your site and user account to the WordPress.com cloud to provide more powerful features.","jetpack-my-jetpack"),redirectUri:null,onConnectUser:null,requiresUserConnection:!0};const Z=w},5784:(e,t,n)=>{"use strict";n.d(t,{Z:()=>p});var c=n(9818),a=n(9196),r=n.n(a),o=n(1689),s=n(3345),i=n(7493),l=n(247);function p(){const{apiRoot:e,apiNonce:t,topJetpackMenuItemUrl:n,connectedPlugins:a}=(0,o.Z)(),p=(0,s.Z)("/connection"),u=(0,c.useSelect)((e=>e(i.t).getProductsThatRequiresUserConnection()));return r().createElement(l.Z,{apiRoot:e,apiNonce:t,redirectUri:n,onConnectUser:p,connectedPlugins:a,requiresUserConnection:u.length>0,onDisconnected:()=>document?.location?.reload(!0)})}},5626:(e,t,n)=>{"use strict";n.d(t,{Z:()=>u});var c=n(5736),a=n(1074),r=n(3259),o=n(9196),s=n.n(o),i=n(9997),l=n(197);const __=c.__;function p(e){let{onClick:t}=e;return s().createElement(i.rU,{to:"/",className:l.Z.link,onClick:t},s().createElement(a.Z,{icon:r.Z,className:l.Z.icon}),__("Go back","jetpack-my-jetpack"))}p.defaultProps={onClick:()=>{}};const u=p},8607:(e,t,n)=>{"use strict";n.d(t,{r:()=>d});var c=n(526),a=n(3396),r=n(5609),o=n(9771),s=n(5736),i=n(5235),l=n.n(i),p=n(9196),u=n(4416);n(1854);const __=s.__;function d(e){let{productName:t,giftedDate:n}=e;const[i,d]=(0,p.useState)(!1),m=(0,p.useCallback)((()=>d(!0)),[d]),g={position:"top center",placement:"top",animate:!0,noArrow:!1,resize:!1,flip:!1,offset:6,focusOnMount:"container",onClose:(0,p.useCallback)((()=>d(!1)),[d]),className:u.Z.container},h=l()(u.Z.wrapper,"golden-token-icon-tooltip");return React.createElement("div",{className:h},React.createElement(c.Z,{variant:"link",onClick:m},React.createElement(a._1,{className:u.Z.logo})),React.createElement("div",{className:u.Z.helper},i&&React.createElement(r.Popover,g,React.createElement("div",null,React.createElement("div",{className:u.Z.title},t),React.createElement("div",{className:u.Z.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"),t,(0,o.dateI18n)("F j, Y",n)))))))}},8966:(e,t,n)=>{"use strict";n.d(t,{Z:()=>N});var c=n(2674),a=n.n(c),r=n(2054),o=n(9105),s=n(216),i=n(3363),l=n(3846),p=n(5106),u=n(6579),d=n(4164),m=n(3329),g=n(5609),h=n(5736),y=n(496),f=n(9196),k=n.n(f),v=n(2199),E=n(5371),b=n(5031),j=n(5784),_=n(6800),C=n(5943),w=n(1017);const __=h.__,Z=e=>{let{message:t,options:n,clean:c}=e;const[o]=(0,r.Z)(["md"],[">"]),s={error:k().createElement(g.SVG,{className:w.Z.nofill,width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},k().createElement(g.Path,{d:"M11.7815 4.93772C11.8767 4.76626 12.1233 4.76626 12.2185 4.93772L20.519 19.8786C20.6116 20.0452 20.4911 20.25 20.3005 20.25H3.69951C3.50889 20.25 3.3884 20.0452 3.48098 19.8786L11.7815 4.93772Z",stroke:"#D63638",strokeWidth:"1.5"}),k().createElement(g.Path,{d:"M13 10H11V15H13V10Z",fill:"#D63638"}),k().createElement(g.Path,{d:"M13 16H11V18H13V16Z",fill:"#D63638"})),info:y.Z};return k().createElement(g.Notice,a()({isDismissible:!1},n,{onRemove:c,className:w.Z.notice+(o?" "+w.Z["bigger-than-medium"]:"")}),k().createElement("div",{className:w.Z.message},s?.[n.status]&&k().createElement(g.Icon,{icon:s[n.status]}),t))};function N(){(0,E.Z)();const{message:e,options:t,clean:n}=(0,b.Z)(),{hasConnectionError:c}=(0,m.Z)(),{recordEvent:a}=(0,v.Z)();return(0,f.useEffect)((()=>{a("jetpack_myjetpack_page_view")}),[a]),k().createElement(o.Z,null,k().createElement(s.Z,null,k().createElement(i.Z,{horizontalSpacing:0},k().createElement(l.Z,null,k().createElement("div",{id:"jp-admin-notices",className:"my-jetpack-jitm-card"}))),k().createElement(i.Z,{horizontalSpacing:5,horizontalGap:e?3:6},k().createElement(l.Z,{sm:4,md:7,lg:6},k().createElement(p.ZP,{variant:"headline-small"},__("Manage your Jetpack products","jetpack-my-jetpack"))),c&&k().createElement(l.Z,null,k().createElement(m.h,null)),e&&k().createElement(l.Z,null,k().createElement(Z,{message:e,options:t,clean:n})),k().createElement(l.Z,null,k().createElement(C.Z,null)))),k().createElement(u.Z,null,k().createElement(i.Z,{horizontalSpacing:8},k().createElement(l.Z,{sm:2,md:4,lg:6},k().createElement(_.Z,null)),k().createElement(l.Z,{sm:2,md:4,lg:6},k().createElement(j.Z,null)))),k().createElement(d.Z,null))}},6800:(e,t,n)=>{"use strict";n.d(t,{Z:()=>b});var c=n(5106),a=n(526),r=n(5736),o=n(9196),s=n.n(o),i=n(2199),l=n(1689),p=n(3345),u=n(1750),d=n(8295),m=n(7258),g=n(6986),h=n(8607),y=n(6891);const __=r.__,_n=r._n;function f(e){let{purchase:t={}}=e;const{product_name:n}=t;return s().createElement(s().Fragment,null,s().createElement(c.Dx,null,n),s().createElement(k,t))}function k(e){const{expiry_message:t,product_name:n,subscribed_date:a}=e;return(0,g.h)(e)?s().createElement(c.ZP,{variant:"body",className:y.Z["expire-date"]},s().createElement("span",{className:y.Z["expire-date--with-icon"]},__("Never Expires","jetpack-my-jetpack")),s().createElement(h.r,{productName:n,giftedDate:a})):s().createElement(c.ZP,{variant:"body",className:y.Z["expire-date"]},t)}function v(e){let{purchases:t}=e;return s().createElement(s().Fragment,null,s().createElement(c.H3,null,t.length<=1?__("Your plan","jetpack-my-jetpack"):__("Your plans","jetpack-my-jetpack")),0===t.length&&s().createElement(c.ZP,{variant:"body"},__("Want to power up your Jetpack?","jetpack-my-jetpack")))}function E(e){let{purchases:t}=e;const{recordEvent:n}=(0,i.Z)(),{isUserConnected:c}=(0,l.Z)();let r=__("Purchase a plan","jetpack-my-jetpack");t.length>=1&&(r=_n("Manage your plan","Manage your plans",t.length,"jetpack-my-jetpack"));const u=(0,o.useCallback)((()=>{const e=t.length?"jetpack_myjetpack_plans_manage_click":"jetpack_myjetpack_plans_purchase_click";n(e)}),[t,n]),g=(0,p.Z)("/connection"),h=(0,o.useCallback)((()=>{n("jetpack_myjetpack_activate_license_click"),c||g()}),[g,c,n]);let f=__("Activate a license","jetpack-my-jetpack");return c||(f=__("Activate a license (requires a user connection)","jetpack-my-jetpack")),s().createElement("ul",null,s().createElement("li",{className:y.Z["actions-list-item"]},s().createElement(a.Z,{onClick:u,href:t.length?(0,d.Z)():(0,m.Z)(),weight:"regular",variant:"link",isExternalLink:!0},r)),window?.myJetpackInitialState?.loadAddLicenseScreen&&s().createElement("li",{className:y.Z["actions-list-item"]},s().createElement(a.Z,{onClick:h,href:c?`${window?.myJetpackInitialState?.adminUrl}admin.php?page=my-jetpack#/add-license`:void 0,variant:"link",weight:"regular"},f)))}function b(){const{purchases:e}=(0,u.Z)();return s().createElement("div",{className:y.Z.container},s().createElement(v,{purchases:e}),s().createElement("div",{className:y.Z.purchasesSection},e.map((e=>s().createElement(f,{key:`purchase-${e.product_name}`,purchase:e})))),s().createElement(E,{purchases:e}))}},2728:(e,t,n)=>{"use strict";n.d(t,{N:()=>y,Z:()=>E});var c=n(2674),a=n.n(c),r=n(526),o=n(5106),s=n(5736),i=n(5235),l=n.n(i),p=n(5162),u=n.n(p),d=n(9196),m=n.n(d),g=n(2199),h=n(9720);const __=s.__,y={ACTIVE:"active",INACTIVE:"inactive",ERROR:"error",ABSENT:"plugin_absent",NEEDS_PURCHASE:"needs_purchase",NEEDS_PURCHASE_OR_FREE:"needs_purchase_or_free"},f={[y.ACTIVE]:__("Active","jetpack-my-jetpack"),[y.INACTIVE]:__("Inactive","jetpack-my-jetpack"),[y.NEEDS_PURCHASE]:__("Inactive","jetpack-my-jetpack"),[y.NEEDS_PURCHASE_OR_FREE]:__("Inactive","jetpack-my-jetpack"),[y.ERROR]:__("Error","jetpack-my-jetpack")},k=e=>{let{status:t,admin:n,name:c,onActivate:o,onManage:i,onFixConnection:l,isFetching:p,className:u,onAdd:d}=e;if(!n)return m().createElement(r.Z,a()({},g,{size:"small",variant:"link",weight:"regular"}),/* translators: placeholder is product name. */ -(0,s.sprintf)(__("Learn about %s","jetpack-my-jetpack"),c));const g={variant:p?void 0:"primary",disabled:p,className:u};switch(t){case y.ABSENT:return m().createElement(r.Z,a()({},g,{size:"small",variant:"link",weight:"regular"}),/* translators: placeholder is product name. */ -(0,s.sprintf)(__("Add %s","jetpack-my-jetpack"),c));case y.NEEDS_PURCHASE:return m().createElement(r.Z,a()({},g,{size:"small",weight:"regular",onClick:d}),__("Purchase","jetpack-my-jetpack"));case y.NEEDS_PURCHASE_OR_FREE:return m().createElement(r.Z,a()({},g,{size:"small",weight:"regular",onClick:d}),__("Start for free","jetpack-my-jetpack"));case y.ACTIVE:return m().createElement(r.Z,a()({},g,{size:"small",weight:"regular",variant:"secondary",onClick:i}),__("Manage","jetpack-my-jetpack"));case y.ERROR:return m().createElement(r.Z,a()({},g,{size:"small",weight:"regular",onClick:l}),__("Fix connection","jetpack-my-jetpack"));case y.INACTIVE:return m().createElement(r.Z,a()({},g,{size:"small",weight:"regular",variant:"secondary",onClick:o}),__("Activate","jetpack-my-jetpack"));default:return null}},v=e=>{const{name:t,description:n,icon:c,status:r,onActivate:s,onAdd:i,onFixConnection:p,onManage:u,isFetching:v,slug:E}=e,b=r===y.ACTIVE,j=r===y.ERROR,_=r===y.INACTIVE,C=r===y.ABSENT,w=r===y.NEEDS_PURCHASE||r===y.NEEDS_PURCHASE_OR_FREE,Z=f[r],N=l()(h.Z.container,{[h.Z.plugin_absent]:C,[h.Z["is-purchase-required"]]:w,[h.Z["is-link"]]:C,[h.Z["has-error"]]:j}),S=l()(h.Z.status,{[h.Z.active]:b,[h.Z.inactive]:_||w,[h.Z.error]:j,[h.Z["is-fetching"]]:v}),{recordEvent:R}=(0,g.Z)(),P=(0,d.useCallback)((()=>{R("jetpack_myjetpack_product_card_activate_click",{product:E}),s()}),[E,s,R]),x=(0,d.useCallback)((e=>{e?.preventDefault&&e.preventDefault(),R("jetpack_myjetpack_product_card_add_click",{product:E}),i()}),[E,i,R]),A=(0,d.useCallback)((()=>{R("jetpack_myjetpack_product_card_manage_click",{product:E}),u()}),[E,u,R]),L=(0,d.useCallback)((()=>{R("jetpack_myjetpack_product_card_fixconnection_click",{product:E}),p()}),[E,p,R]),I=C?e=>{let{children:t,...n}=e;return m().createElement("a",a()({},n,{href:"#",onClick:x}),t)}:e=>{let{children:t,...n}=e;return m().createElement("div",n,t)};return m().createElement(I,{className:N},m().createElement("div",{className:h.Z.name},m().createElement(o.ZP,{variant:"title-medium"},t),c),m().createElement(o.ZP,{variant:"body-small",className:h.Z.description},n),m().createElement("div",{className:h.Z.actions},m().createElement(k,a()({},e,{onActivate:P,onFixConnection:L,onManage:A,className:h.Z.button})),!C&&m().createElement(o.ZP,{variant:"label",className:S},Z)))};v.propTypes={name:u().string.isRequired,description:u().string.isRequired,icon:u().element,admin:u().bool.isRequired,isFetching:u().bool,onManage:u().func,onFixConnection:u().func,onActivate:u().func,onAdd:u().func,slug:u().string.isRequired,status:u().oneOf([y.ACTIVE,y.INACTIVE,y.ERROR,y.ABSENT,y.NEEDS_PURCHASE,y.NEEDS_PURCHASE_OR_FREE]).isRequired},v.defaultProps={icon:null,isFetching:!1,onManage:()=>{},onFixConnection:()=>{},onActivate:()=>{},onAdd:()=>{}};const E=v},1640:(e,t,n)=>{"use strict";n.d(t,{Z:()=>l});var c=n(5162),a=n.n(c),r=n(9196),o=n.n(r),s=n(5745);const i=e=>{let{admin:t}=e;return o().createElement(s.Z,{admin:t,slug:"anti-spam"})};i.propTypes={admin:a().bool.isRequired};const l=i},401:(e,t,n)=>{"use strict";n.d(t,{Z:()=>l});var c=n(5162),a=n.n(c),r=n(9196),o=n.n(r),s=n(5745);const i=e=>{let{admin:t}=e;return o().createElement(s.Z,{admin:t,slug:"backup"})};i.propTypes={admin:a().bool.isRequired};const l=i},4074:(e,t,n)=>{"use strict";n.d(t,{Z:()=>l});var c=n(5162),a=n.n(c),r=n(9196),o=n.n(r),s=n(5745);const i=e=>{let{admin:t}=e;return o().createElement(s.Z,{admin:t,slug:"boost"})};i.propTypes={admin:a().bool.isRequired};const l=i},5996:(e,t,n)=>{"use strict";n.d(t,{Z:()=>l});var c=n(5162),a=n.n(c),r=n(9196),o=n.n(r),s=n(5745);const i=e=>{let{admin:t}=e;return o().createElement(s.Z,{admin:t,slug:"crm"})};i.propTypes={admin:a().bool.isRequired};const l=i},717:(e,t,n)=>{"use strict";n.d(t,{Z:()=>l});var c=n(5162),a=n.n(c),r=n(9196),o=n.n(r),s=n(5745);const i=e=>{let{admin:t}=e;return o().createElement(s.Z,{admin:t,slug:"extras"})};i.propTypes={admin:a().bool.isRequired};const l=i},5943:(e,t,n)=>{"use strict";n.d(t,{Z:()=>y});var c=n(3363),a=n(3846),r=n(9196),o=n.n(r),s=n(1640),i=n(401),l=n(4074),p=n(5996),u=n(717),d=n(5440),m=n(687),g=n(419),h=n(9894);const y=()=>o().createElement(c.Z,{fluid:!0,horizontalSpacing:0,horizontalGap:3},o().createElement(a.Z,{sm:4,md:4,lg:4},o().createElement(i.Z,{admin:!0})),o().createElement(a.Z,{sm:4,md:4,lg:4},o().createElement(d.Z,{admin:!0})),o().createElement(a.Z,{sm:4,md:4,lg:4},o().createElement(s.Z,{admin:!0})),o().createElement(a.Z,{sm:4,md:4,lg:4},o().createElement(l.Z,{admin:!0})),o().createElement(a.Z,{sm:4,md:4,lg:4},o().createElement(m.Z,{admin:!0})),o().createElement(a.Z,{sm:4,md:4,lg:4},o().createElement(h.Z,{admin:!0})),o().createElement(a.Z,{sm:4,md:4,lg:4},o().createElement(p.Z,{admin:!0})),o().createElement(a.Z,{sm:4,md:4,lg:4},o().createElement(g.Z,{admin:!0})),o().createElement(a.Z,{sm:4,md:4,lg:4},o().createElement(u.Z,{admin:!0})))},5440:(e,t,n)=>{"use strict";n.d(t,{Z:()=>u});var c=n(9818),a=n(5162),r=n.n(a),o=n(9196),s=n.n(o),i=n(7493),l=n(5745);const p=e=>{let{admin:t}=e;const n=(0,c.useSelect)((e=>e(i.t).hasStandalonePluginInstalled()));return s().createElement(l.Z,{admin:t,slug:n?"protect":"scan"})};p.propTypes={admin:r().bool.isRequired};const u=p},687:(e,t,n)=>{"use strict";n.d(t,{Z:()=>l});var c=n(5162),a=n.n(c),r=n(9196),o=n.n(r),s=n(5745);const i=e=>{let{admin:t}=e;return o().createElement(s.Z,{admin:t,slug:"search"})};i.propTypes={admin:a().bool.isRequired};const l=i},419:(e,t,n)=>{"use strict";n.d(t,{Z:()=>l});var c=n(5162),a=n.n(c),r=n(9196),o=n.n(r),s=n(5745);const i=e=>{let{admin:t}=e;return o().createElement(s.Z,{admin:t,slug:"social"})};i.propTypes={admin:a().bool.isRequired};const l=i},9894:(e,t,n)=>{"use strict";n.d(t,{Z:()=>l});var c=n(5162),a=n.n(c),r=n(9196),o=n.n(r),s=n(5745);const i=e=>{let{admin:t}=e;return o().createElement(s.Z,{admin:t,slug:"videopress"})};i.propTypes={admin:a().bool.isRequired};const l=i},2667:(e,t,n)=>{"use strict";n.d(t,{Z:()=>l});var c=n(5609),a=n(5162),r=n.n(a),o=n(9196),s=n.n(o);const i=e=>{let{children:t,className:n,href:a,isLoading:r,onClick:o,isPrimary:i,disabled:l}=e;return s().createElement(c.Button,{onClick:o,className:n,href:a,variant:i?"primary":"secondary",disabled:r||l},r?s().createElement(c.Spinner,null):t)};i.propTypes={className:r().string,isLoading:r().bool,isPrimary:r().bool,disabled:r().bool},i.defaultProps={isLoading:!1,isPrimary:!0,disabled:!1};const l=i},968:(e,t,n)=>{"use strict";n.d(t,{Z:()=>_});var c=n(8899),a=n(5106),r=n(3396),o=n(4972),s=n(8258),i=n(5609),l=n(5736),p=n(1074),u=n(1908),d=n(9201),m=n(5235),g=n.n(m),h=n(9196),y=n.n(h),f=n(2199),k=n(3703),v=n(2667),E=n(8429);const __=l.__;function b(e){let{value:t,currency:n,isOld:r}=e;if(!t||!n)return null;const o=(0,c.LR)(t,n),s=g()(E.Z.price,{[E.Z["is-old"]]:r});return y().createElement(a.ZP,{className:s,variant:"headline-medium",component:"p"},y().createElement(a.ZP,{component:"sup",variant:"title-medium"},o.symbol),o.integer,y().createElement(a.ZP,{component:"sup",variant:"title-medium"},o.fraction))}const j=e=>{let{slug:t,onClick:n,trackButtonClick:c,className:m,supportingInfo:j}=e;const{fileSystemWriteAccess:_,siteSuffix:C,myJetpackUrl:w}=window?.myJetpackInitialState??{},{detail:Z,isFetching:N}=(0,k.i)(t),{title:S,longDescription:R,features:P,disclaimers:x,pricingForUi:A,isBundle:L,supportedProducts:I,hasRequiredPlan:U,status:T,pluginSlug:O}=Z,F="plugin_absent"===T&&"no"===_,{isFree:D,trialAvailable:z,fullPricePerMonth:M,currencyCode:V,discountPricePerMonth:B,wpcomProductSlug:J,wpcomFreeProductSlug:H,introductoryOffer:q}=A,{recordEvent:G}=(0,f.Z)(),W=!D&&!U,{run:$,hasCheckoutStarted:K}=(0,s.Z)({productSlug:J,redirectUrl:w,siteSuffix:C,from:"my-jetpack"}),{run:Q,hasCheckoutStarted:X}=(0,s.Z)({productSlug:H,redirectUrl:w,siteSuffix:C,from:"my-jetpack"}),Y=L?I.join("_plus_").split("_").map(((e,t)=>{if("plus"===e)return y().createElement(p.Z,{className:E.Z["plus-icon"],key:`icon-plugs${t}`,icon:u.Z,size:14});const n=(0,r.VS)(e);return y().createElement(n,{key:e,size:24})})):null,ee="month"===q?.intervalUnit&&1===q?.intervalCount?(0,l.sprintf)( -// translators: %s is the monthly price for a product -__("trial for the first month, then $%s /month, billed yearly","jetpack-my-jetpack"),M):__("/month, paid yearly","jetpack-my-jetpack",0),te=(0,h.useCallback)((()=>{c(),n?.($)}),[n,c,$]),ne=(0,h.useCallback)((()=>{c(H),n?.(Q)}),[n,c,Q,H]),ce=(0,h.useCallback)((e=>{G("jetpack_myjetpack_product_card_disclaimer_click",{id:e,product:t})}),[t,G]);function ae(e){let{slug:t}=e;const n=(0,r.VS)(t);return n?y().createElement("div",{className:E.Z["product-icon"]},y().createElement(n,null)):null}return y().createElement("div",{className:g()(E.Z.card,m,{[E.Z["is-bundle-card"]]:L})},L&&y().createElement("div",{className:E.Z["card-header"]},y().createElement(r.r7,{className:E.Z["product-bundle-icon"],size:16}),y().createElement(a.ZP,{variant:"label"},__("Popular upgrade","jetpack-my-jetpack"))),y().createElement("div",{className:E.Z.container},L&&y().createElement("div",{className:E.Z["product-bundle-icons"]},Y),y().createElement(ae,{slug:t}),y().createElement(a.H3,null,S),y().createElement(a.ZP,{mb:3},R),y().createElement("ul",{className:E.Z.features},P.map(((e,t)=>y().createElement(a.ZP,{component:"li",key:`feature-${t}`,variant:"body"},y().createElement(p.Z,{icon:d.Z,size:24}),e)))),W&&y().createElement(y().Fragment,null,y().createElement("div",{className:E.Z["price-container"]},B0&&y().createElement("div",{className:E.Z.disclaimers},x.map(((e,t)=>{const{text:n,link_text:c=null,url:r=null}=e;return y().createElement(a.ZP,{key:`disclaimer-${t}`,component:"p",variant:"body-small"},`${n} `,r&&c&&y().createElement(i.ExternalLink,{onClick:()=>ce(t),href:r,target:"_blank",rel:"noopener noreferrer"},c))}))),L&&U&&y().createElement("div",{className:E.Z["product-has-required-plan"]},y().createElement(r.KM,{size:36}),y().createElement(a.ZP,null,__("Active on your site","jetpack-my-jetpack"))),j&&y().createElement(a.ZP,{className:E.Z["supporting-info"],variant:"body-extra-small"},j)))};j.defaultProps={trackButtonClick:()=>{}};const _=j},8093:(e,t,n)=>{"use strict";n.d(t,{B$:()=>S,Jw:()=>I,Q5:()=>x,WJ:()=>N,Yi:()=>R,jO:()=>P,q:()=>w,qA:()=>Z,uw:()=>L,y$:()=>A});var c=n(9105),a=n(3363),r=n(3846),o=n(5106),s=n(9818),i=n(9307),l=n(5736),p=n(9196),u=n.n(p),d=n(2199),m=n(3345),g=n(3703),h=n(7493),y=n(5626),f=n(968),k=n(5610),v=n(4763),E=n(2605),b=n(720),j=n(1287),_=n(1439);const __=l.__;function C(e){let{bundle:t,installsPlugin:n=!1,slug:l,supportingInfo:k,children:v=null}=e;const{activate:E,detail:b}=(0,g.i)(l),{isUpgradableByBundle:_}=b,{recordEvent:C}=(0,d.Z)();(0,p.useEffect)((()=>{C("jetpack_myjetpack_product_interstitial_view",{product:l})}),[C,l]);const w=(0,p.useCallback)((function(){C("jetpack_myjetpack_product_interstitial_add_link_click",{product:(arguments.length>0&&void 0!==arguments[0]?arguments[0]:null)??l})}),[C,l]),Z=(0,p.useCallback)((()=>{C("jetpack_myjetpack_product_interstitial_add_link_click",{product:t})}),[C,t]),N=(0,m.Z)("/"),S=(0,p.useCallback)((e=>{(t?Promise.resolve():E()).finally((()=>{const n=(0,s.select)(h.t).getProduct(l);if(t)return void e?.();const c=n?.postActivationUrl,a=n?.hasRequiredPlan,r=n?.pricingForUi?.isFree;if(!c)return!r&&!a?void e?.():N();window.location.href=c}))}),[N,E,t,l]),R=(0,p.useCallback)((e=>{l&&C("jetpack_myjetpack_product_interstitial_back_link_click",{product:l}),document.referrer.includes(window.location.host)&&(e.preventDefault(),history.back())}),[C,l]);return u().createElement(c.Z,{showHeader:!1,showBackground:!1},u().createElement(a.Z,{horizontalSpacing:3,horizontalGap:3},u().createElement(r.Z,{className:j.Z["product-interstitial__header"]},u().createElement(y.Z,{onClick:R}),u().createElement(o.ZP,{variant:"body-small"},(0,i.createInterpolateElement)(__("Already have an existing plan or license key? Click here to get started","jetpack-my-jetpack"),{a:u().createElement("a",{className:j.Z["product-interstitial__license-activation-link"],href:"admin.php?page=my-jetpack#/add-license"})}))),u().createElement(r.Z,null,u().createElement(a.Z,{className:_?null:j.Z.container,horizontalSpacing:0,horizontalGap:0,fluid:!0},u().createElement(r.Z,{sm:4,md:4,lg:7},u().createElement(f.Z,{slug:l,trackButtonClick:w,onClick:n?S:void 0,className:_?j.Z.container:null,supportingInfo:k})),u().createElement(r.Z,{sm:4,md:4,lg:5,className:j.Z.imageContainer},t?u().createElement(f.Z,{slug:t,trackButtonClick:Z,onClick:S,className:_?j.Z.container:null}):v)))))}function w(){return u().createElement(C,{slug:"anti-spam",installsPlugin:!0,bundle:"security"})}function Z(){return u().createElement(C,{slug:"backup",installsPlugin:!0,bundle:"security"})}function N(){return u().createElement(C,{slug:"boost",installsPlugin:!0},u().createElement("img",{src:k,alt:"Boost"}))}function S(){return u().createElement(C,{slug:"crm",installsPlugin:!0},u().createElement("img",{src:v,alt:"CRM"}))}function R(){return u().createElement(C,{slug:"extras",installsPlugin:!0},u().createElement("img",{src:E,alt:"Extras"}))}function P(){return u().createElement(C,{slug:"protect",installsPlugin:!0,bundle:"security"})}function x(){return u().createElement(C,{slug:"scan",installsPlugin:!0,bundle:"security"})}function A(){return u().createElement(C,{slug:"social",installsPlugin:!0})}function L(){const{detail:e}=(0,g.i)("search");return u().createElement(C,{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")},u().createElement("img",{src:b,alt:"Search"}))}function I(){return u().createElement(C,{slug:"videopress",installsPlugin:!0},u().createElement("img",{src:_,alt:"VideoPress"}))}},673:(e,t,n)=>{"use strict";n.d(t,{Z:()=>p});var c=n(1294),a=n(3281),r=n(5736),o=n(9196),s=n.n(o),i=n(1750),l=n(6986);const __=r.__;function p(){const{userConnectionData:e}=(0,c.Z)(),t=e?.currentUser?.wpcomUser?.display_name||e?.currentUser?.wpcomUser?.login||e?.currentUser?.username,{isFetchingPurchases:n,purchases:r}=(0,i.Z)(),o=(0,l.o)(r);return n?s().createElement(s().Fragment,null,__("Checking gold status…","jetpack-my-jetpack")):s().createElement(s().Fragment,null,s().createElement(a.H,{tokenRedeemed:o,displayName:t}))}},8565:(e,t,n)=>{"use strict";n.d(t,{f6:()=>a,w6:()=>c});const c="my-jetpack-my-plans-manage",a="my-jetpack-my-plans-purchase"},2199:(e,t,n)=>{"use strict";n.d(t,{Z:()=>o});var c=n(6975),a=n(9196),r=n(1689);const o=()=>{const{isUserConnected:e,connectedPlugins:t,userConnectionData:n={}}=(0,r.Z)(),{login:o,ID:s}=n.currentUser?.wpcomUser||{};(0,a.useEffect)((()=>{e&&s&&o&&c.Z.initialize(s,o)}),[s,e,o]);const i=Object.keys(t||{}).sort().join(",").replaceAll("jetpack-",""),{clearedIdentity:l,ga:p,mc:u,pageView:d,purchase:m,setGoogleAnalyticsEnabled:g,setMcAnalyticsEnabled:h,setProperties:y,tracks:f}=c.Z;return{clearedIdentity:l,ga:p,mc:u,pageView:d,purchase:m,recordEvent:(0,a.useCallback)(((e,t)=>{f.recordEvent(e,{...t,version:window?.myJetpackInitialState?.myJetpackVersion,referring_plugins:i})}),[]),setGoogleAnalyticsEnabled:g,setMcAnalyticsEnabled:h,setProperties:y,tracks:f}}},4106:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9818),a=n(7493);function r(){return{availableLicenses:(0,c.useSelect)((e=>e(a.t).getAvailableLicenses())),fetchingAvailableLicenses:(0,c.useSelect)((e=>e(a.t).isFetchingAvailableLicenses()))}}},5371:(e,t,n)=>{"use strict";n.d(t,{Z:()=>l});var c=n(9818),a=n(5736),r=n(9196),o=n(7493),s=n(1689),i=n(3345);const __=a.__;function l(){const e=(0,i.Z)("/connection"),{setGlobalNotice:t}=(0,c.useDispatch)(o.t),n=(0,c.useSelect)((e=>e(o.t).getProductsThatRequiresUserConnection())),{isSiteConnected:l,hasConnectedOwner:p}=(0,s.Z)(),u=!p&&n.length>0,d=(0,a.sprintf)(/* translators: placeholder is product name. */ -__("Jetpack %s needs a user connection to WordPress.com to be able to work.","jetpack-my-jetpack"),n[0]),m=n.length>1?__("Some products need a user connection to WordPress.com to be able to work.","jetpack-my-jetpack"):d,g=__("Some products need a connection to WordPress.com to be able to work.","jetpack-my-jetpack");(0,r.useEffect)((()=>{l?u&&t(m,{status:"error",actions:[{label:__("Connect your user account to fix this","jetpack-my-jetpack"),onClick:e,noDefaultClasses:!0}]}):t(g,{status:"warning",actions:[{label:__("Connect your site to fix this","jetpack-my-jetpack"),onClick:e,variant:"link",noDefaultClasses:!0}]})}),[l,g,m,u,e,t])}},1689:(e,t,n)=>{"use strict";n.d(t,{Z:()=>a});var c=n(1294);function a(){const{apiRoot:e,apiNonce:t}=myJetpackRest,{topJetpackMenuItemUrl:n}=myJetpackInitialState,a=(0,c.Z)({apiRoot:e,apiNonce:t}),r=a.isRegistered;return{apiNonce:t,apiRoot:e,...a,isSiteConnected:r,topJetpackMenuItemUrl:n}}},3345:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9196),a=n(6417);function r(e){const t=(0,a.s0)();return(0,c.useCallback)((()=>t(e)),[t,e])}},5031:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9818),a=n(7493);function r(){const e=(0,c.useDispatch)(),{message:t,options:n}=(0,c.useSelect)((e=>e(a.t).getGlobalNotice()));return{message:t,options:n||{},clean:()=>e(a.t).cleanGlobalNotice()}}},3703:(e,t,n)=>{"use strict";n.d(t,{i:()=>r});var c=n(9818),a=n(7493);function r(e){const{activateProduct:t,deactivateProduct:n}=(0,c.useDispatch)(a.t),r=(0,c.useSelect)((t=>t(a.t).getProduct(e)));return{activate:()=>t(e),deactivate:()=>n(e),productsList:(0,c.useSelect)((e=>e(a.t).getProducts())),detail:r,isActive:"active"===r.status,isFetching:(0,c.useSelect)((t=>t(a.t).isFetching(e))),status:r.status}}},1750:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9818),a=n(7493);function r(){const{purchases:e,isFetchingPurchases:t}=(0,c.useSelect)((e=>{const{getPurchases:t,isRequestingPurchases:n}=e(a.t);return{purchases:t(),isFetchingPurchases:n()}}));return{purchases:e,isFetchingPurchases:t}}},9274:(e,t,n)=>{"use strict";n.d(t,{GH:()=>u,Np:()=>d,RT:()=>i,ZP:()=>C,d1:()=>f,dE:()=>h,dI:()=>g,dq:()=>y,fE:()=>k,ny:()=>l,vv:()=>m,z8:()=>p});var c=n(428),a=n(6989),r=n.n(a),o=n(5736),s=n(2086);const __=o.__,i="SET_PURCHASES_IS_FETCHING",l="FETCH_PURCHASES",p="SET_PURCHASES",u="SET_AVAILABLE_LICENSES_IS_FETCHING",d="SET_AVAILABLE_LICENSES",m="SET_IS_FETCHING_PRODUCT",g="SET_PRODUCT",h="SET_PRODUCT_REQUEST_ERROR",y="SET_PRODUCT_STATUS",f="SET_GLOBAL_NOTICE",k="CLEAN_GLOBAL_NOTICE",v=e=>({type:g,product:e}),E=(e,t)=>({type:h,productId:e,error:t}),b=(e,t)=>({type:"SET_GLOBAL_NOTICE",message:e,options:t});function j(e,t){return{type:m,productId:e,isFetching:t}}const _={setProduct:v,activateProduct:e=>async t=>await function(e,t,n){let{select:a,dispatch:i,registry:l}=n;return new Promise(((n,p)=>{if(!a.isValidProduct(e)){const t=__("Invalid product name","jetpack-my-jetpack"),n=new Error(t);return i(E(e,n)),i(b(t,{status:"error",isDismissible:!0})),void p(n)}const u=t.activate?"POST":"DELETE";return i(j(e,!0)),r()({path:`${s.Jk}/${e}`,method:u}).then((t=>{i(j(e,!1)),i(v(t)),l.dispatch(c.t).refreshConnectedPlugins(),n(t?.status)})).catch((t=>{const{name:n}=a.getProduct(e),c=(0,o.sprintf)( -// translators: %$1s: Jetpack Product name -__("Failed to activate %1$s. Please try again","jetpack-my-jetpack"),n);i(j(e,!1)),i(E(e,t)),i(b(c,{status:"error",isDismissible:!0})),p(t)}))}))}(e,{activate:!0},t),setIsFetchingProduct:j,setRequestProductError:E,setProductStatus:(e,t)=>({type:y,productId:e,status:t})},C={setPurchasesIsFetching:e=>({type:i,isFetching:e}),fetchPurchases:()=>({type:l}),setPurchases:e=>({type:p,purchases:e}),setAvailableLicensesIsFetching:e=>({type:u,isFetching:e}),fetchAvailableLicenses:()=>({type:"FETCH_AVAILABLE_LICENSES"}),setAvailableLicenses:e=>({type:d,availableLicenses:e}),...{setGlobalNotice:b,cleanGlobalNotice:()=>({type:"CLEAN_GLOBAL_NOTICE"})},..._}},2086:(e,t,n)=>{"use strict";n.d(t,{Jk:()=>r,LQ:()=>a,iB:()=>o});const c="my-jetpack/v1",a=`${c}/site/purchases`,r=`${c}/site/products`,o=["scan"]},9462:(e,t,n)=>{"use strict";n.d(t,{Z:()=>s});var c=n(6989),a=n.n(c),r=n(9274),o=n(2086);const s={[r.ny]:function(){return new Promise(((e,t)=>{a()({path:o.LQ}).then(e).catch(t)}))}}},925:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(9818),a=n(9274);const r=(0,c.combineReducers)({products:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case a.vv:{const{productId:n,isFetching:c}=t;return{...e,isFetching:{...e.isFetching,[n]:c},errors:{...e.errors,[n]:c?void 0:e.errors[n]}}}case a.dq:{const{productId:n,status:c}=t;return{...e,items:{...e.items,[n]:{...e.items[n],status:c}}}}case a.dI:{const{product:n}=t,{slug:c}=n;return{...e,items:{...e.items,[c]:n}}}case a.dE:{const{productId:n,error:c}=t;return{...e,errors:{...e.errors,[n]:c}}}default:return e}},purchases:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case a.RT:return{...e,isFetching:t.isFetching};case a.z8:return{...e,items:t?.purchases||[]};default:return e}},availableLicenses:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case a.GH:return{...e,isFetching:t.isFetching};case a.Np:return{...e,items:t?.availableLicenses||[]};default:return e}},notices:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{global:{}},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case a.d1:{const{message:n,options:c}=t;return{...e,global:{message:n,options:c}}}case a.fE:return{...e,global:{}};default:return e}},plugins:function(){return arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}}})},9844:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});var c=n(4743),a=n(6989),r=n.n(a),o=n(5736),s=n(2086);const __=o.__,i={...{getProduct:{isFulfilled:(e,t)=>(e?.products?.items||{}).hasOwnProperty(t)&&!s.iB.includes(t),fulfill:e=>async t=>{let{dispatch:n}=t;try{n.setIsFetchingProduct(e,!0);const t=await r()({path:`${s.Jk}/${e}`});return n.setProduct(t),n.setIsFetchingProduct(e,!1),Promise.resolve()}catch(t){if(n.setIsFetchingProduct(e,!1),t?.code&&t?.message)return n.setRequestProductError(e,t),Promise.reject(t);throw new Error(t)}}},getPurchases:()=>async e=>{let{dispatch:t}=e;t.setPurchasesIsFetching(!0);try{t.setPurchases(await r()({path:s.LQ})),t.setPurchasesIsFetching(!1)}catch(e){t.setPurchasesIsFetching(!1),"not_connected"!==e.code&&t.setGlobalNotice(__("There was an error fetching your purchases information. Check your site connectivity and try again.","jetpack-my-jetpack"),{status:"error"})}},getAvailableLicenses:()=>async e=>{let{dispatch:t}=e;t.setAvailableLicensesIsFetching(!0);try{const{apiRoot:e,apiNonce:n}=window?.myJetpackRest||{};c.ZP.setApiRoot(e),c.ZP.setApiNonce(n);const a=await c.ZP.getUserLicenses();a&&a.items?t.setAvailableLicenses(a.items.filter((e=>{let{attached_at:t}=e;return null===t}))):t.setAvailableLicenses([])}catch(e){t.setAvailableLicenses([])}finally{t.setAvailableLicensesIsFetching(!1)}}}}},6896:(e,t,n)=>{"use strict";n.d(t,{ZP:()=>s});var c=n(2728),a=n(6782);const r=e=>e.products?.items||{},o=e=>Object.keys(r(e)),s={...{getProducts:r,getProductNames:o,getProduct:(e,t)=>{const n=r(e)?.[t]||{},c=(0,a.N)(n,!0);return c.pricingForUi=(0,a.N)(c.pricingForUi||{},!0),c.pricingForUi.introductoryOffer=c.pricingForUi.isIntroductoryOffer?(0,a.N)(c.pricingForUi.introductoryOffer,!0):null,c.features=c.features||[],c.supportedProducts=c.supportedProducts||[],c.pricingForUi.fullPricePerMonth=Math.ceil(c.pricingForUi.fullPrice/12*100)/100,c.pricingForUi.discountPricePerMonth=Math.ceil(c.pricingForUi.discountPrice/12*100)/100,c},isValidProduct:(e,t)=>o(e).includes(t),isFetching:(e,t)=>e.products?.isFetching?.[t]||!1,getProductsThatRequiresUserConnection:e=>{const t=r(e);return Object.keys(t).reduce(((e,n)=>{const a=t[n];return a?.requires_user_connection&&(a?.status===c.N.ACTIVE||a?.status===c.N.ERROR)&&e.push(a?.name),e}),[])}},getPurchases:e=>e.purchases?.items||[],isRequestingPurchases:e=>e.purchases?.isFetching||!1,getAvailableLicenses:e=>e.availableLicenses?.items||[],isFetchingAvailableLicenses:e=>e.availableLicenses?.isFetching||!1,getGlobalNotice:e=>e.notices?.global,...{hasStandalonePluginInstalled:e=>Object.values(e.plugins).filter((e=>["jetpack-backup","jetpack-boost","jetpack-protect","jetpack-search","jetpack-social","jetpack-videopress"].indexOf(e.TextDomain)>=0)).length>0}}},1214:(e,t,n)=>{"use strict";n.d(t,{Z:()=>s});var c=n(17),a=n.n(c),r=n(9818);class o{static mayBeInit(e,t){null===o.store&&(o.store=(0,r.createReduxStore)(e,t),(0,r.register)(o.store))}}a()(o,"store",null);const s=o},7493:(e,t,n)=>{"use strict";n.d(t,{N:()=>p,t:()=>l});var c=n(9274),a=n(9462),r=n(925),o=n(9844),s=n(6896),i=n(1214);const l="my-jetpack";function p(){i.Z.mayBeInit(l,{__experimentalUseThunks:!0,reducer:r.Z,actions:c.ZP,selectors:s.ZP,resolvers:o.Z,controls:a.Z,initialState:window.myJetpackInitialState||{}})}},8295:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(6895),a=n(8565);function r(){const e=window?.myJetpackInitialState?.siteSuffix;return(0,c.Z)(a.w6,{site:e})}},7258:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var c=n(6895),a=n(8565);function r(){const e=window?.myJetpackInitialState?.siteSuffix;return(0,c.Z)(a.f6,{site:e})}},6986:(e,t,n)=>{"use strict";function c(e){let{partner_slug:t}=e;return!!t&&"goldenticket"===t}function a(e){return!!Array.isArray(e)&&e.filter((e=>c(e))).length>0}n.d(t,{h:()=>c,o:()=>a})},6782:(e,t,n)=>{"use strict";function c(e){return e.replace(/([-_][a-z])/gi,(e=>e.toUpperCase().replace("_","")))}function a(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const n=Object.assign({},e);for(const e in n)n.hasOwnProperty(e)&&-1!==e.indexOf("_")&&(n[c(e)]=n[e],t&&delete n[e]);return n}n.d(t,{N:()=>a})},2042:(e,t,n)=>{"use strict";e.exports=n.p+"images/disconnect-confirm-dc9fe8f5c68cfd1320e0.jpg"},724:(e,t,n)=>{"use strict";e.exports=n.p+"images/disconnect-thanks-5873bfac56a9bd7322cd.jpg"},8702:(e,t,n)=>{"use strict";e.exports=n.p+"images/jetpack-license-activation-with-lock-7b01c1a4cf56de799cd7.png"},1160:(e,t,n)=>{"use strict";e.exports=n.p+"images/jetpack-license-activation-with-success-cad524ede4e793cc0ece.png"},5242:(e,t,n)=>{"use strict";e.exports=n.p+"images/apple-92dacafad84e79708a74.svg"},6790:(e,t,n)=>{"use strict";e.exports=n.p+"images/connect-f27775ac15cf885713c2.png"},184:(e,t,n)=>{"use strict";e.exports=n.p+"images/google-dec2a429bf1d8e83f9ad.svg"},4403:(e,t,n)=>{"use strict";e.exports=n.p+"images/wordpress-1fc3e0ba6c52e9707900.svg"},8489:(e,t,n)=>{"use strict";e.exports=n.p+"images/cloud-81ac85ba680343200f54.svg"},3815:(e,t,n)=>{"use strict";e.exports=n.p+"images/empty-avatar-fea23feddfa99b07c2e8.svg"},9182:(e,t,n)=>{"use strict";e.exports=n.p+"images/jetpack-9de1caef5eb5c22da5d6.svg"},5610:(e,t,n)=>{"use strict";e.exports=n.p+"images/boost-a54137485af36fdffe9c.png"},4763:(e,t,n)=>{"use strict";e.exports=n.p+"images/crm-7e7684ae2c40327d8fed.png"},2605:(e,t,n)=>{"use strict";e.exports=n.p+"images/extras-26daf36507504c96d066.png"},720:(e,t,n)=>{"use strict";e.exports=n.p+"images/search-f9756bd9c926d905fe70.png"},1439:(e,t,n)=>{"use strict";e.exports=n.p+"images/videopress-9591093a9a238cc48a35.png"},4462:e=>{"use strict";if(void 0==={consumer_slug:"my_jetpack"}){var t=new Error('Cannot find module \'{"consumer_slug":"my_jetpack"}\'');throw t.code="MODULE_NOT_FOUND",t}e.exports={consumer_slug:"my_jetpack"}},9196:e=>{"use strict";e.exports=window.React},6989:e=>{"use strict";e.exports=window.wp.apiFetch},5609:e=>{"use strict";e.exports=window.wp.components},4333:e=>{"use strict";e.exports=window.wp.compose},9818:e=>{"use strict";e.exports=window.wp.data},9771:e=>{"use strict";e.exports=window.wp.date},9307:e=>{"use strict";e.exports=window.wp.element},5736:e=>{"use strict";e.exports=window.wp.i18n},444:e=>{"use strict";e.exports=window.wp.primitives},6483:e=>{"use strict";e.exports=window.wp.url},17:(e,t,n)=>{var c=n(6930);e.exports=function(e,t,n){return(t=c(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.__esModule=!0,e.exports.default=e.exports},2674:e=>{function t(){return e.exports=t=Object.assign?Object.assign.bind():function(e){for(var t=1;t{var c=n(3522).default;e.exports=function(e,t){if("object"!==c(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var a=n.call(e,t||"default");if("object"!==c(a))return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)},e.exports.__esModule=!0,e.exports.default=e.exports},6930:(e,t,n)=>{var c=n(3522).default,a=n(5061);e.exports=function(e){var t=a(e,"string");return"symbol"===c(t)?t:String(t)},e.exports.__esModule=!0,e.exports.default=e.exports},3522:e=>{function t(n){return e.exports=t="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},e.exports.__esModule=!0,e.exports.default=e.exports,t(n)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},8288:(e,t,n)=>{"use strict";n.d(t,{Z:()=>l});var c=n(9307),a=n(5736),r=n(5844),o=n(9196),s=n(9430);const __=a.__,i=e=>{const{productId:t,siteRawUrl:n}=e,a=`https://cloud.jetpack.com/landing/${n}`,r=(0,s.F)(t),i={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,c.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:o.createElement("a",{href:a})})},jetpack_complete:{title:__("Jetpack Complete is active!","jetpack-my-jetpack"),text:(0,c.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:o.createElement("a",{href:a})})},jetpack_scan:{title:__("Jetpack Scan is active!","jetpack-my-jetpack"),text:(0,c.createInterpolateElement)(__("You can see your security scans on cloud.jetpack.com.","jetpack-my-jetpack"),{a:o.createElement("a",{href:a})})},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,c.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:o.createElement("a",{href:a})})},jetpack_videopress:{title:__("Jetpack VideoPress is active!","jetpack-my-jetpack"),text:__("Experience high-quality, ad-free video built specifically for WordPress.","jetpack-my-jetpack")},default:{title:__("Your product is active!","jetpack-my-jetpack"),text:__("You're all set!","jetpack-my-jetpack")}};return o.createElement("div",{className:"jp-license-activation-screen-success-info--product-details"},o.createElement("h1",null,i[r].title," ",String.fromCodePoint(127881)),o.createElement("p",null,i[r].text))};i.propTypes={dashboardUrl:r.string,productId:r.number};const l=i},9430:(e,t,n)=>{"use strict";n.d(t,{F:()=>a});const c={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]};function a(e){return Object.keys(c).find((t=>c[t].includes(e)))||"default"}}},t={};function n(c){var a=t[c];if(void 0!==a)return a.exports;var r=t[c]={exports:{}};return e[c](r,r.exports,n),r.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 c in t)n.o(t,c)&&!n.o(e,c)&&Object.defineProperty(e,c,{enumerable:!0,get:t[c]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{var e;n.g.importScripts&&(e=n.g.location+"");var t=n.g.document;if(!e&&t&&(t.currentScript&&(e=t.currentScript.src),!e)){var c=t.getElementsByTagName("script");c.length&&(e=c[c.length-1].src)}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),n.p=e})(),(()=>{"use strict";var e=n(8275),t=n(9307),c=n(9196),a=n.n(c),r=n(6417),o=n(9997),s=n(1899),i=n(9841),l=n(8966),p=n(8093),u=n(673),d=n(7493);n(5878);function m(){const e=(0,r.TH)();return(0,c.useEffect)((()=>window.scrollTo(0,0)),[e]),null}(0,d.N)();const g=()=>a().createElement(e.ZP,null,a().createElement(o.UT,null,a().createElement(m,null),a().createElement(r.Z5,null,a().createElement(r.AW,{path:"/",element:a().createElement(l.Z,null)}),a().createElement(r.AW,{path:"/connection",element:a().createElement(i.Z,null)}),a().createElement(r.AW,{path:"/add-anti-spam",element:a().createElement(p.q,null)}),a().createElement(r.AW,{path:"/add-backup",element:a().createElement(p.qA,null)}),a().createElement(r.AW,{path:"/add-boost",element:a().createElement(p.WJ,null)}),a().createElement(r.AW,{path:"/add-crm",element:a().createElement(p.B$,null)}),a().createElement(r.AW,{path:"/add-extras",element:a().createElement(p.Yi,null)}),a().createElement(r.AW,{path:"/add-protect",element:a().createElement(p.jO,null)}),a().createElement(r.AW,{path:"/add-scan",element:a().createElement(p.Q5,null)}),a().createElement(r.AW,{path:"/add-social",element:a().createElement(p.y$,null)}),a().createElement(r.AW,{path:"/add-search",element:a().createElement(p.uw,null)}),a().createElement(r.AW,{path:"/add-videopress",element:a().createElement(p.Jw,null)}),window?.myJetpackInitialState?.loadAddLicenseScreen&&a().createElement(r.AW,{path:"/add-license",element:a().createElement(s.Z,null)}),a().createElement(r.AW,{path:"/redeem-token",element:a().createElement(u.Z,null)}))));!function(){const e=document.getElementById("my-jetpack-container");null!==e&&(t.createRoot?t.createRoot(e).render(a().createElement(g,null)):t.render(a().createElement(g,null),e))}()})()})(); \ 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 b954283e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.js.LICENSE.txt +++ /dev/null @@ -1,46 +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 - */ - -/*! - Copyright (c) 2018 Jed Watson. - Licensed under the MIT License (MIT), see - http://jedwatson.github.io/classnames -*/ - -/** - * @remix-run/router v1.2.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 DOM v6.6.2 - * - * 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.6.2 - * - * 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 082a7994..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 @@ -#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 .jetpack-logo{height:40px}#my-jetpack-container .jp-dashboard-footer__jetpack-symbol{height:16px}#wpbody-content>.notice{display:none}#wpwrap{background-color:var(--jp-white-off)}.pIsYsXFAJ9KX2VrS5rmY{--actions-size:28px;--status-size:8px;background:var(--jp-white);border-radius:var(--jp-border-radius);box-shadow:0 0 40px rgba(0,0,0,.08);box-shadow:0 0 0 1px var(--jp-gray-10) inset;display:flex;flex-direction:column;height:100%;padding:calc(var(--spacing-base)*3)}.pIsYsXFAJ9KX2VrS5rmY.YXHdD0VsFjiTsVRLrrx9{background:none;background-color:var(--jp-white-off);color:var(--jp-black-80);text-decoration:none}.pIsYsXFAJ9KX2VrS5rmY.YXHdD0VsFjiTsVRLrrx9:hover{background-color:var(--jp-white)}.pIsYsXFAJ9KX2VrS5rmY.YXHdD0VsFjiTsVRLrrx9:focus{background-color:var(--jp-white);box-shadow:0 0 0 1.5px var(--jp-black);outline:3px solid transparent}.pIsYsXFAJ9KX2VrS5rmY.Pp9cMIaESLYelLOX3tkI{box-shadow:0 0 0 1.5px var(--jp-red-60)}.w56ueQLYexqzTybA7015{align-items:center;display:flex;justify-content:space-between;margin-bottom:var(--spacing-base);width:100%}.gmPKCDKZcfQt9WieTyKS{flex-grow:1}.fDBaV7I4yUO6w5AWVEtr{align-items:center;display:flex;flex-wrap:wrap;justify-content:space-between;margin-top:calc(var(--spacing-base)*2);min-height:var(--actions-size);width:100%}.f5VJYwuJmjxH8PVxEbbv{align-items:center;display:flex;height:var(--actions-size);margin-right:var(--spacing-base);white-space:nowrap}.f5VJYwuJmjxH8PVxEbbv:before{border-radius:50%;content:"";display:inline-block;height:var(--status-size);margin-left:var(--spacing-base);width:var(--status-size)}.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.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}}.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.5px;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.5px 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)}.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)}._fUXxnSp5pagKBp9gSN7 *{box-sizing:border-box}.jErCC9oKHSM15BxzFyQK{margin-bottom:0}.oVoYbwbFB6U2o90Njusk{border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius);border-right:6px solid var(--jp-red-50);box-shadow:0 4px 8px rgba(0,0,0,.03),0 1px 2px rgba(0,0,0,.06);color:var(--jp-gray-80);font-size:16px;line-height:22px;margin:0;padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3) calc(var(--spacing-base)*2) calc(var(--spacing-base)*3)}.oVoYbwbFB6U2o90Njusk.is-error{background-color:var(--jp-white)}.oVoYbwbFB6U2o90Njusk .components-notice__content{align-items:flex-start;display:flex;flex-direction:column;margin:0;padding:12px 4px}.oVoYbwbFB6U2o90Njusk .is-link{color:var(--jp-black);font-size:16px;font-weight:600}.oVoYbwbFB6U2o90Njusk .components-notice__dismiss{align-self:center}.oVoYbwbFB6U2o90Njusk .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:calc(var(--spacing-base)*2 + 24px);margin-top:24px;padding:8px 24px;text-decoration:none}.oVoYbwbFB6U2o90Njusk.Snc8NEmDelsbhlH4285s .components-notice__action{margin-right:0;margin-top:0;white-space:nowrap}.oVoYbwbFB6U2o90Njusk.Snc8NEmDelsbhlH4285s .components-notice__content{align-items:center;flex-direction:row}.wBVXH4OTNwLHPRpN4nsq{display:flex;flex-grow:1;margin-left:var(--spacing-base)}.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}.urouayitSUT8zW0V3p_0{margin-bottom:0}.iXXJlk08gFDeCvsTTlNQ{border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius);border-right:6px solid var(--jp-red-50);box-shadow:0 4px 8px rgba(0,0,0,.03),0 1px 2px rgba(0,0,0,.06);box-sizing:border-box;color:var(--jp-gray-80);font-size:16px;line-height:22px;margin:0;padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3) calc(var(--spacing-base)*2) calc(var(--spacing-base)*3)}.iXXJlk08gFDeCvsTTlNQ.is-error{background-color:var(--jp-white)}.iXXJlk08gFDeCvsTTlNQ .components-notice__content{align-items:flex-start;display:flex;flex-direction:column;margin:0;padding:12px 4px}.iXXJlk08gFDeCvsTTlNQ .is-link{color:var(--jp-black);font-size:16px;font-weight:600}.iXXJlk08gFDeCvsTTlNQ .components-notice__dismiss{align-self:center}.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk,.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk:active,.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk:hover,.iXXJlk08gFDeCvsTTlNQ .MWqRqr7q6fgvLxitcWYk:visited{align-items:center;background:#000;border-radius:var(--jp-border-radius);color:var(--jp-white);cursor:pointer;font-size:16px;font-weight:600;justify-content:center;letter-spacing:-.01em;line-height:24px;margin-right:calc(var(--spacing-base)*2 + 24px);margin-top:24px;padding:8px 24px;text-decoration:none}.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk,.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk:active,.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk:hover,.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .MWqRqr7q6fgvLxitcWYk:visited{margin-right:0;margin-top:0;white-space:nowrap}.iXXJlk08gFDeCvsTTlNQ.YLcXAoc82nypTPaKSAcd .components-notice__content{align-items:center;flex-direction:row}.e6hHy8BZ7ZKPSXbIC0UG{margin-bottom:25px}.jXz8LnXNzMDdtHqkG0sZ{display:flex;flex-grow:1;margin-left:var(--spacing-base)}.jXz8LnXNzMDdtHqkG0sZ>svg{align-self:flex-start;flex-shrink:0}.jXz8LnXNzMDdtHqkG0sZ .jp-components-spinner,.jXz8LnXNzMDdtHqkG0sZ>svg{margin-left:calc(var(--spacing-base)*2)}@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%}.sexr0jUxC1jVixdKiDnC{margin-right:-20px}@media(max-width:782px){.sexr0jUxC1jVixdKiDnC{margin-right:-10px}}.sexr0jUxC1jVixdKiDnC.vKQ11sLeAM45M04P1ccj{background-color:var(--jp-white)}.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}}.jp-dashboard-footer{align-items:center;color:#000;display:flex;flex-flow:row wrap;justify-content:space-between;max-width:1128px;width:100%}.jp-dashboard-footer a,.jp-dashboard-footer a:hover,.jp-dashboard-footer a:visited{color:#000;text-decoration:none}.jp-dashboard-footer__jetpack-symbol,.jp-dashboard-footer__module-name{display:inline-block;vertical-align:middle}.jp-dashboard-footer__module-name{font-size:12px;font-weight:600;margin-right:5px}.vMa4i_Dza2t5Zi_Bw9Nf{background:var(--jp-white-off)}.cuoSlhSNrqf1dozY22Xb{fill:#000}.JLquNpQVlysAamuh5lJO,.lAIiifeLMmZAPlQ9n9ZR{fill:var(--jp-green-primary)}.cbOwD8Y4tFjwimmtchQI{fill:#757575}.cbOwD8Y4tFjwimmtchQI.aHOlEBGD5EA8NKRw3xTw{fill:var(--color-facebook);border-radius:50%!important}.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)}.cAbGtJDGgLubucBnz7vM{background-color:var(--jp-white)}.wiobThfXJCuhGNrbFIT6 a,.wiobThfXJCuhGNrbFIT6 a:active,.wiobThfXJCuhGNrbFIT6 a:hover{color:var(--jp-black)}.VgAxgahF9bC2M__FiIgV{display:flex;margin-bottom:calc(var(--spacing-base)*3)}.dbRwkMLqcMF67njPoAF7{margin-left:8px}.Doju0RxvvN9JS12mf489{line-height:calc(var(--spacing-base)*3);margin:0 0 var(--spacing-base) 0}.yWUvvF4WJLNDSpMgBMfm{align-items:center;display:flex;flex-wrap:wrap;margin:0 auto;max-width:1128px}.ka1fVHj2HOkHjhdoEFOZ{grid-gap:24px;display:grid;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}.components-popover:not(.is-without-arrow):before{border-color:var(--jp-gray)}.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}.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}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .MdTRfQ3eo5qZKChZlzNj{width:32px}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .PbEpL02SEH9VNAlbKCfV{width:30px}.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 .rq8YRaj9OyUUXJUHiUgI{border-color:var(--jp-red)}.kezuOHNvu9vdvlJ86Fwg .YZ7FNKEm9qpvQ4ZkbAz5{transform:rotate(-180deg)}.kezuOHNvu9vdvlJ86Fwg .oH9tzGE80LnB6Og69RFz{margin-bottom:var(--spacing-base)}.kezuOHNvu9vdvlJ86Fwg .oH9tzGE80LnB6Og69RFz,.kezuOHNvu9vdvlJ86Fwg .xXVEWvQllVsFGmJY8WEp{align-items:center;display:flex;gap:var(--spacing-base)}.kezuOHNvu9vdvlJ86Fwg .xXVEWvQllVsFGmJY8WEp.J0GIu2rNR7rXocQTyd8p{fill:var(--jp-red);color:var(--jp-red)}.jp-connection__manage-dialog{--spacing-base:8px;border-radius:3px;margin:auto;width:1200px}.jp-connection__manage-dialog__content{align-items:center;background:var(--jp-white-off);display:flex;flex-direction:column;justify-content:center;padding:80px;text-align:center}.jp-connection__manage-dialog__content h1{font-size:var(--font-title-large);font-weight:700;line-height:1.2;margin:0}.jp-connection__manage-dialog__large-text{font-size:1.25rem;font-weight:600;margin-bottom:calc(var(--spacing-base)*4);margin-top:calc(var(--spacing-base)*3);max-width:60%}.jp-connection__manage-dialog__actions{align-items:center;background:var(--jp-white);border-top:1px solid var(--jp-gray);bottom:0;box-sizing:border-box;margin:0!important;max-width:1200px!important;padding:calc(var(--spacing-base)*4) calc(var(--spacing-base)*5);position:sticky}.jp-connection__manage-dialog__link{color:var(--jp-black)}.jp-connection__manage-dialog__link:hover{color:var(--jp-black);text-decoration-thickness:var(--jp-underline-thickness)}.jp-connection__manage-dialog__link:focus{color:var(--jp-black)}.jp-connection__manage-dialog__button-wrap button{float:left}.jp-connection__manage-dialog__action-card{background-color:var(--jp-white);border:none;border-radius:3px;box-shadow:0 0 15px var(--jp-gray-off);margin:var(--spacing-base) auto;max-width:100%;padding:1rem 2rem;text-align:right;width:750px}.jp-connection__manage-dialog__action-card__card-headline{font-size:var(--font-body);font-weight:600;line-height:calc(var(--spacing-base)*3);text-decoration:none}.jp-connection__manage-dialog__action-card__icon{float:left}.jp-connection__manage-dialog__action-card .transfer{fill:var(--jp-black);color:var(--jp-black)}.jp-connection__manage-dialog__action-card .disconnect{fill:var(--jp-red);color:var(--jp-red)}.jp-connection__manage-dialog .components-modal__header{display:none}.jp-connection__manage-dialog .components-modal__content{margin:0;padding:0}.jp-connection__disconnect-dialog h1{font-size:var(--font-title-small);font-weight:600;line-height:1.2;margin-top:0}.jp-connection__disconnect-dialog h2{font-size:var(--font-title-small);font-weight:400;line-height:1.2;margin:0}.jp-connection__disconnect-dialog p{font-size:var(--font-body);margin-top:0}.jp-connection__disconnect-dialog p.jp-connection__disconnect-dialog__large-text,.jp-connection__disconnect-dialog__large-text{font-size:1.25rem}.jp-connection__disconnect-dialog .jp-connection__disconnect-dialog__link,.jp-connection__disconnect-dialog__link{color:var(--jp-black);font-size:var(--font-body);font:inherit;height:auto;padding:0;text-decoration:underline}.jp-connection__disconnect-dialog .jp-connection__disconnect-dialog__link:hover,.jp-connection__disconnect-dialog__link:hover{color:var(--jp-black);text-decoration-thickness:var(--jp-underline-thickness)}.jp-connection__disconnect-dialog .jp-connection__disconnect-dialog__link:focus,.jp-connection__disconnect-dialog__link:focus{box-shadow:none!important;color:var(--jp-black)}.jp-connection__disconnect-dialog .jp-connection__disconnect-dialog__link--bold,.jp-connection__disconnect-dialog__link--bold{font-weight:700}.jp-connection__disconnect-dialog .components-button{border-radius:4px;font-size:var(--font-body-small);height:40px}.jp-connection__disconnect-dialog .components-modal__content{display:flex;flex-direction:column;flex-grow:1;margin:0;padding:0}.jp-connection__disconnect-dialog .components-modal__content:before,.jp-connection__disconnect-dialog .components-modal__header{display:none}.jp-connection__disconnect-dialog .jp-row{align-items:center;width:calc(100% - 48px)}.jp-connection__disconnect-dialog__content{align-items:center;background:var(--jp-white-off);border-radius:4px;display:flex;flex-direction:column;flex-grow:1;justify-content:center;margin:0;padding:2rem 1rem;text-align:center}.jp-connection__disconnect-dialog__actions{background:var(--jp-white);border-top:1px solid var(--jp-gray);bottom:0;padding:2rem 0;position:sticky}.jp-connection__disconnect-dialog__actions p{margin-bottom:0}.jp-connection__disconnect-dialog__actions:before{background:linear-gradient(to bottom,transparent,var(--jp-white-off));bottom:calc(100% + 1px);content:"";display:block;height:80px;position:absolute;right:0;width:100%}.jp-connection__disconnect-dialog__btn-dismiss,.jp-connection__disconnect-dialog__btn-dismiss.components-button{background:var(--jp-black)!important;margin-left:10px}.jp-connection__disconnect-dialog__btn-disconnect{background:var(--jp-red)!important}.jp-connection__disconnect-dialog__btn-back-to-wp{background:var(--jp-black)!important}.jp-connection__disconnect-dialog__button-wrap{text-align:right}@media(min-width:960px){.jp-connection__disconnect-dialog__button-wrap{text-align:center}}.jp-connection__disconnect-dialog__error{color:var(--jp-red)}.jp-connection__disconnect-dialog__survey{margin-bottom:1.5rem;max-width:100%}.jp-connection__disconnect-dialog__step-copy{margin:0 auto;max-width:800px}.jp-connection__disconnect-dialog__step-copy--narrow{max-width:600px}@media(max-height:900px){.jp-connection__disconnect-dialog__content .jp-components__decorative-card{display:none}}@media(min-width:600px){.jp-connection__disconnect-dialog,.jp-connection__disconnect-dialog.components-modal__frame{max-width:calc(100% - 32px);width:100%}.jp-connection__disconnect-dialog__actions,.jp-connection__disconnect-dialog__content{padding:2rem}}@media(min-width:960px){.jp-connection__disconnect-dialog,.jp-connection__disconnect-dialog.components-modal__frame{display:flex;flex-direction:column;height:900px;width:1200px}.jp-connection__disconnect-dialog h1{font-size:var(--font-title-large)}.jp-connection__disconnect-dialog p.jp-connection__disconnect-dialog__large-text,.jp-connection__disconnect-dialog__large-text{font-size:1.5rem}.jp-connection__disconnect-dialog__content{padding:80px}.jp-connection__disconnect-dialog__actions{padding:2rem 3rem}.jp-row{margin-right:0}}.jp-connection__disconnect-card{background-color:var(--jp-white);border:none;border-radius:3px;box-shadow:0 0 15px var(--jp-gray-off);margin:0 auto 1rem;max-width:100%;padding:1rem 2rem;text-align:right;width:800px}.jp-connection__disconnect-card__group{margin-bottom:1rem;max-width:100%}.jp-connection__disconnect-card__card-content{display:block;font-size:.875rem}@media only screen and (min-width:782px){.jp-connection__disconnect-card__card-content{align-items:center;display:flex;justify-content:space-between}}.jp-connection__disconnect-card .jp-connection__disconnect-card__card-headline,.jp-connection__disconnect-card__card-headline{flex-shrink:0;font-size:1.25rem;font-weight:600;margin-bottom:0;margin-top:0}@media only screen and (min-width:782px){.jp-connection__disconnect-card .jp-connection__disconnect-card__card-headline,.jp-connection__disconnect-card__card-headline{font-size:1.5rem;margin-left:1.5rem}}@media only screen and (max-width:782px){.jp-connection__disconnect-card .jp-connection__disconnect-card__card-headline+.jp-disconnect-card__card-stat-block,.jp-connection__disconnect-card__card-headline+.jp-disconnect-card__card-stat-block{margin-top:.5rem}}.jp-connection__disconnect-card__card-stat-block{align-items:baseline;display:flex;flex-grow:1}@media only screen and (min-width:782px){.jp-connection__disconnect-card__card-stat-block{flex-direction:row-reverse}}.jp-connection__disconnect-card__card-description{flex-grow:1}@media only screen and (min-width:782px){.jp-connection__disconnect-card__card-description{text-align:left}}.jp-connection__disconnect-card__card-stat{font-size:1rem;font-weight:600;margin-left:.5rem}@media only screen and (min-width:782px){.jp-connection__disconnect-card__card-stat{font-size:1.5rem;margin-left:0;margin-right:1rem}}.jp-components__decorative-card{border-radius:8px;box-shadow:0 0 15px var(--jp-gray);display:flex;height:280px;margin:0 auto 3rem;max-width:100%;overflow:hidden;position:relative;width:360px}.jp-components__decorative-card__content,.jp-components__decorative-card__image{width:50%}.jp-components__decorative-card__image{background:var(--jp-gray);background-size:cover;position:relative}.jp-components__decorative-card__image:before{background-image:url('data:image/svg+xml;uf8,');content:"";display:block;height:8px;position:absolute;right:24px;top:24px;width:38px}.jp-components__decorative-card__content{background:#fff;padding:2rem}.jp-components__decorative-card__icon-container{background:var(--jp-red);border-radius:50px;height:80px;position:absolute;right:50%;top:50%;transform:translate(50%,-50%);width:80px}.jp-components__decorative-card__icon{background-position:50%,50%;background-repeat:no-repeat;height:40px;position:absolute;right:50%;top:50%;transform:translate(50%,-50%);width:40px}.jp-components__decorative-card__icon--unlink{background-image:url('data:image/svg+xml;uf8, ')}.jp-components__decorative-card__lines,.jp-components__decorative-card__lines:after,.jp-components__decorative-card__lines:before{background:#e9eff5;border-radius:6px;display:block;height:12px;position:relative;width:100%}.jp-components__decorative-card__lines:after,.jp-components__decorative-card__lines:before{content:"";top:calc(100% + 16px)}.jp-components__decorative-card__lines:after{top:calc(100% + 32px);width:75%}.jp-components__decorative-card--vertical{flex-direction:column}.jp-components__decorative-card--vertical .jp-components__decorative-card__content,.jp-components__decorative-card--vertical .jp-components__decorative-card__image{height:50%;width:100%}.jp-components__decorative-card--vertical .jp-components__decorative-card__lines{margin-left:auto;margin-right:auto;max-width:135px}.jp-components__decorative-card--vertical .jp-components__decorative-card__lines:after,.jp-components__decorative-card--vertical .jp-components__decorative-card__lines:before{margin-left:auto;margin-right:auto}.jp-connect__disconnect-survey-card{border:2px solid transparent;border-radius:4px;box-shadow:0 0 15px var(--jp-gray-off);margin-left:auto;margin-right:auto;max-width:100%;padding:1rem;position:relative;text-align:right;width:800px}.jp-connect__disconnect-survey-card--selected{background:var(--jp-gray-off);border-color:var(--jp-black)}.jp-connect__disconnect-survey-card:after{border-left:2px solid var(--jp-black);border-top:2px solid var(--jp-black);content:"";display:block;height:5px;left:1.5rem;position:absolute;top:50%;transform:translateY(-50%) rotate(-45deg);width:5px}.jp-connect__disconnect-survey-card:hover{cursor:pointer}.jp-connect__disconnect-survey-card:focus:not(.jp-disconnect-survey-card--selected),.jp-connect__disconnect-survey-card:hover:not(.jp-disconnect-survey-card--selected){border-color:var(--jp-black-80)}.jp-connect__disconnect-survey-card__answer{align-items:center;display:flex;font-weight:700;margin:0}input.jp-connect__disconnect-survey-card__input{-webkit-appearance:none;background-color:transparent;border:none;color:var(--jp-black-80);flex-grow:1;max-width:calc(100% - 40px);padding-left:40px}.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:16px;width:60%}._RT41NE3LU4R0ubcij2y{align-items:center;display:flex}.cFGWJeRiGHjAr8D7CWJW{margin-left:8px;max-width:110px}.Iz3l7a05TP6HK9S92TIL{width:16px}.lmQ0wFmnk4kKkGVjokPA{height:18px;margin-right:8px}.AoIs8wD92wKR8RpQj6Uc{align-items:center;display:inline-flex}.rV_5QyvhDnsVjCX4pb0h{--gray-90:#1e1e1e;fill:var(--gray-90);width:24px}.MO1jDNY8VPqeNS9xL8jE{align-items:center;display:flex;text-decoration:none}.jp-connection__connect-screen{--spacing-base:8px}.jp-connection__connect-screen__loading{display:none}.jp-connection__connect-screen .terms-of-service{margin-bottom:calc(var(--spacing-base)*3);margin-top:calc(var(--spacing-base)*4);max-width:360px}.jp-connection__connect-screen .terms-of-service a{text-decoration:underline}.jp-connection__connect-screen .jp-action-button{margin-top:40px}.jp-connection__connect-screen .jp-action-button--button{border-radius:4px;font-weight:600}.jp-connection__connect-screen .jp-action-button button{max-width:100%}.jp-connection__connect-screen .jp-action-button button:disabled{color:hsla(0,0%,100%,.4)}@media(max-width:782px){.jp-connection__connect-screen .jp-action-button button{max-width:none;width:100%}}.jp-connection__connect-screen__footer{margin-top:32px}.jp-connection__connect-screen-layout{background:var(--jp-white);border-radius:4px;box-shadow:0 0 40px rgba(0,0,0,.08)}.jp-connection__connect-screen-layout__loading{display:none}.jp-connection__connect-screen-layout__left,.jp-connection__connect-screen-layout__right{box-sizing:border-box}.jp-connection__connect-screen-layout__left{padding:calc(var(--spacing-base)*3)}@media(min-width:600px){.jp-connection__connect-screen-layout__left{padding:64px 96px}}.jp-connection__connect-screen-layout__left .jetpack-logo{margin-bottom:24px}.jp-connection__connect-screen-layout__left h2{color:var(--jp-black);font-size:36px;font-style:normal;font-weight:700;line-height:40px;margin-bottom:0;margin-top:32px}.jp-connection__connect-screen-layout__left h3{color:var(--jp-black);font-size:24px;font-style:normal;font-weight:500;line-height:32px;margin-bottom:0;margin-top:32px}.jp-connection__connect-screen-layout__left li,.jp-connection__connect-screen-layout__left p{font-size:16px;font-style:normal;font-weight:400;line-height:24px}.jp-connection__connect-screen-layout__left p{color:#101517;margin:16px 0}.jp-connection__connect-screen-layout__left a{color:var(--jp-black);font-size:var(--font-body);font:inherit;height:auto;padding:0;text-decoration:underline}.jp-connection__connect-screen-layout__left a:hover{color:var(--jp-black);text-decoration-thickness:var(--jp-underline-thickness)}.jp-connection__connect-screen-layout__left a:focus{box-shadow:none!important;color:var(--jp-black)}.jp-connection__connect-screen-layout__left ul{list-style-type:none;padding:0}.jp-connection__connect-screen-layout__left ul li{background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAMAAABg3Am1AAAANlBMVEVHcEwFnwUInggGnggGnggHnAcAnwUFnQcAnwcGnwkFnQgGnQgFnwcGnQYFnQcFnAcGnQkDnwdhiL0pAAAAEnRSTlMAMF//f2Aw7yBQ3+9gcIBgcED+HDbkAAAAZklEQVR4Ae3LNwICARDDQC0+cv7/Y8mwV9odSfWIcf/+VegnGkIvDaGXKvTTn/Gz+Uf5xTL0K1XotS7fs5H6GHvvaO8d7c3j7rdgHne/A/PYt/cO+R42oYdN6OEQetiFHo4A//6dAXqtBEkmtWutAAAAAElFTkSuQmCC) no-repeat;background-size:24px;color:var(--jp-black);margin-bottom:9px;padding-right:30px}.jp-connection__connect-screen-layout__right{padding:64px 0}.jp-connection__connect-screen-layout__right img{max-width:100%}.jp-connection__connect-screen-layout__two-columns{display:flex;flex-wrap:wrap}.jp-connection__connect-screen-layout__two-columns .jp-connection__connect-screen-layout__left{flex-basis:100%;flex-grow:1}@media(min-width:1080px){.jp-connection__connect-screen-layout__two-columns .jp-connection__connect-screen-layout__left{flex-basis:52%}}.jp-connection__connect-screen-layout__two-columns .jp-connection__connect-screen-layout__right{background:#f9f9f6;display:none;flex-basis:47%;flex-grow:1}@media(min-width:1080px){.jp-connection__connect-screen-layout__two-columns .jp-connection__connect-screen-layout__right{display:block}}.terms-of-service{color:var(--jp-black);font-size:var(--font-body)}.terms-of-service .terms-of-service__link{color:var(--jp-green-50)}.TcCZnGE6mad8Dvz9pCZi{background:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjQiIGhlaWdodD0iMjQiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTEyIDIwYTggOCAwIDEgMCAwLTE2IDggOCAwIDAgMCAwIDE2WiIgc3Ryb2tlPSIjRDYzNjM5IiBzdHJva2Utd2lkdGg9IjEuNSIvPjxwYXRoIGQ9Ik0xMyA3aC0ydjZoMlY3Wk0xMyAxNWgtMnYyaDJ2LTJaIiBmaWxsPSIjRDYzNjM5Ii8+PC9zdmc+) no-repeat 100% 0;color:var(--jp-red);line-height:25px;padding-right:25px}._mn6o2Dtm5pfFWc8_A1K{--spacing-base:8px;min-width:264px}.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%}.YcYvLvdvWrb1EUZoVsE8{display:flex;flex-wrap:wrap;gap:calc(var(--horizontal-spacing)*2);justify-content:space-between}.uGTTsKoIOoZdYhk6uPnl{white-space:nowrap}.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}.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)}.sEcLfpWjo0GF7QrxD3Lt{margin-top:calc(var(--spacing-base)*2)}.xgv3jRkeF39aEQELCwru{align-items:flex-end;color:var(--jp-text-color);display:flex;flex-wrap:wrap}.twlleZ5Ehq4bB7CvKVSW{position:relative}.twlleZ5Ehq4bB7CvKVSW:first-child{margin-left:calc(var(--spacing-base)*2)}.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)}.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)}.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{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{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{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-error{align-items:flex-start;color:var(--jp-red);display:flex;flex-direction:row;max-width:500px}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-error svg{fill:var(--jp-red);margin-left:4px;min-width:24px}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-error span{font-size:var(--font-body)}.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%}.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-wrap{align-items:center;display:flex;flex-wrap:wrap;margin:0 auto;max-width:1128px}.jp-row{grid-gap:24px;display:grid;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}.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}}: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-10:#f2cf75;--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-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}body{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;margin:0;min-height:100%;padding:0}.EiaNctK1_P9pPqOeiaSI{align-items:center;display:flex;flex-wrap:wrap;margin:0 auto;max-width:1128px}.ogHZg_sJCljylz3VJfsf{grid-gap:24px;display:grid;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{fill:#fff;transition:fill 2s ease .5s}.gfM_DIJrVbRhmKdAphIm.pnwbCuWbV0PNQr1LFpRh .zfJfONxRAw0fHjXUS7LN path.FCnyb_xCK7DhJ63p6TEd{fill:#000;transition:fill 2s ease .5s}}@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{container-type:inline-size;align-items:flex-end;bottom:5%;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)}}.jp-license-activation-screen{border-radius:4px;box-shadow:0 4px 24px 0 #00000026;display:flex;flex-direction:column;min-height:540px;overflow:hidden}@media screen and (min-width:780px){.jp-license-activation-screen{flex-direction:row}} \ 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 059c98bb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/composer.json +++ /dev/null @@ -1,76 +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": { - "automattic/jetpack-admin-ui": "^0.2.17", - "automattic/jetpack-assets": "^1.17.34", - "automattic/jetpack-connection": "^1.51.4", - "automattic/jetpack-jitm": "^2.3.4", - "automattic/jetpack-licensing": "^1.8.1", - "automattic/jetpack-plugins-installer": "^0.2.3", - "automattic/jetpack-redirect": "^1.7.24", - "automattic/jetpack-constants": "^1.6.21" - }, - "require-dev": { - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/wordbless": "@dev", - "automattic/jetpack-videopress": "^0.13.4-alpha" - }, - "autoload": { - "classmap": [ - "src/", - "src/products" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "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" - ], - "post-install-cmd": "WorDBless\\Composer\\InstallDropin::copy", - "post-update-cmd": "WorDBless\\Composer\\InstallDropin::copy" - }, - "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": "2.9.x-dev" - }, - "version-constants": { - "::PACKAGE_VERSION": "src/class-initializer.php" - } - }, - "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/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 2e10cc31..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-initializer.php +++ /dev/null @@ -1,314 +0,0 @@ -initialize(); - } - - // Add custom WP REST API endoints. - add_action( 'rest_api_init', array( __CLASS__, 'register_rest_endpoints' ) ); - - $page_suffix = Admin_Menu::add_menu( - __( 'My Jetpack', 'jetpack-my-jetpack' ), - __( 'My Jetpack', 'jetpack-my-jetpack' ), - 'manage_options', - 'my-jetpack', - array( __CLASS__, 'admin_page' ), - 999 - ); - - add_action( 'load-' . $page_suffix, array( __CLASS__, 'admin_init' ) ); - - // Sets up JITMS. - JITM::configure(); - - /** - * 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 - ); - } - - /** - * Callback for the load my jetpack page hook. - * - * @return void - */ - public static function admin_init() { - 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() { - Assets::register_script( - 'my_jetpack_main_app', - '../build/index.js', - __FILE__, - array( - 'enqueue' => true, - 'in_footer' => true, - 'textdomain' => 'jetpack-my-jetpack', - ) - ); - wp_localize_script( - 'my_jetpack_main_app', - 'myJetpackInitialState', - array( - 'products' => array( - 'items' => Products::get_products(), - ), - 'purchases' => array( - 'items' => array(), - ), - 'plugins' => Plugins_Installer::get_plugins(), - 'myJetpackUrl' => admin_url( 'admin.php?page=my-jetpack' ), - 'topJetpackMenuItemUrl' => Admin_Menu::get_top_level_menu_item_url(), - 'siteSuffix' => ( new Status() )->get_site_suffix(), - 'myJetpackVersion' => self::PACKAGE_VERSION, - 'fileSystemWriteAccess' => self::has_file_system_write_access(), - 'loadAddLicenseScreen' => self::is_licensing_ui_enabled(), - 'adminUrl' => esc_url( admin_url() ), - ) - ); - - wp_localize_script( - 'my_jetpack_main_app', - 'myJetpackRest', - array( - 'apiRoot' => esc_url_raw( rest_url() ), - 'apiNonce' => wp_create_nonce( 'wp_rest' ), - ) - ); - - // Connection Initial State. - wp_add_inline_script( 'my_jetpack_main_app', Connection_Initial_State::render(), 'before' ); - - // Required for Analytics. - if ( self::can_use_analytics() ) { - Tracking::register_tracks_functions_scripts( true ); - } - } - - /** - * 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(); - - register_rest_route( - 'my-jetpack/v1', - 'site', - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_site', - '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; - } - - /** - * 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 ); - } - - /** - * 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, 200 ); - } - - /** - * Returns true if the site has file write access to the plugins folder, false otherwise. - * - * @return bool - **/ - 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; - } - -} 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 96c074f5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-products.php +++ /dev/null @@ -1,182 +0,0 @@ - Products\Anti_Spam::class, - 'backup' => Products\Backup::class, - 'boost' => Products\Boost::class, - 'crm' => Products\Crm::class, - 'extras' => Products\Extras::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, - ); - - /** - * 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; - } - - /** - * Product data - * - * @return array Jetpack products on the site and their availability. - */ - public static function get_products() { - $products = array(); - foreach ( self::get_products_classes() as $class ) { - $product_slug = $class::$slug; - $products[ $product_slug ] = $class::get_info(); - } - return $products; - } - - /** - * 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' => array( 'active', 'inactive', 'plugin_absent', 'needs_purchase', 'needs_purchase_or_free', 'error' ), - ), - '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', // we use videopress here to add the plugin action to the Jetpack plugin itself - ); - 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-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 a0300a84..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-products.php +++ /dev/null @@ -1,208 +0,0 @@ - \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_products', - 'permission_callback' => __CLASS__ . '::permissions_callback', - ), - 'schema' => array( $this, 'get_products_schema' ), - ) - ); - - $product_arg = array( - 'description' => __( 'Product slug', 'jetpack-my-jetpack' ), - 'type' => 'string', - 'enum' => Products::get_products_slugs(), - 'required' => true, - 'validate_callback' => __CLASS__ . '::check_product_argument', - ); - - register_rest_route( - 'my-jetpack/v1', - 'site/products/(?P[a-z\-]+)', - array( - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_product', - 'permission_callback' => __CLASS__ . '::permissions_callback', - 'args' => array( - 'product' => $product_arg, - ), - ), - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::activate_product', - 'permission_callback' => __CLASS__ . '::edit_permissions_callback', - 'args' => array( - 'product' => $product_arg, - ), - ), - array( - 'methods' => \WP_REST_Server::DELETABLE, - 'callback' => __CLASS__ . '::deactivate_product', - 'permission_callback' => __CLASS__ . '::edit_permissions_callback', - 'args' => array( - 'product' => $product_arg, - ), - ), - ) - ); - } - - /** - * 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 Product arguments. - * - * @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_product_argument( $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 ) - ); - } - - return true; - } - - /** - * Site products endpoint. - * - * @return array of site products list. - */ - public static function get_products() { - $response = Products::get_products(); - return rest_ensure_response( $response, 200 ); - } - - /** - * Site single product endpoint. - * - * @param \WP_REST_Request $request The request object. - * @return array of site products list. - */ - public static function get_product( $request ) { - $product_slug = $request->get_param( 'product' ); - return rest_ensure_response( Products::get_product( $product_slug ), 200 ); - } - - /** - * 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 a product - * - * @param \WP_REST_Request $request The request object. - * @return \WP_REST_Response - */ - public static function activate_product( $request ) { - $product_slug = $request->get_param( 'product' ); - $product = Products::get_product( $product_slug ); - if ( ! isset( $product['class'] ) ) { - return new \WP_Error( - 'not_implemented', - esc_html__( 'The product class handler is not implemented', 'jetpack-my-jetpack' ), - 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; - } - - return rest_ensure_response( Products::get_product( $product_slug ), 200 ); - } - - /** - * Callback for deactivating a product - * - * @param \WP_REST_Request $request The request object. - * @return \WP_REST_Response - */ - public static function deactivate_product( $request ) { - $product_slug = $request->get_param( 'product' ); - $product = Products::get_product( $product_slug ); - if ( ! isset( $product['class'] ) ) { - return new \WP_Error( - 'not_implemented', - esc_html__( 'The product class handler is not implemented', 'jetpack-my-jetpack' ), - 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_product( $product_slug ), 200 ); - } - -} 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 fde97b75..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-purchases.php +++ /dev/null @@ -1,76 +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( 'manage_options' ); - } - - /** - * Site purchases endpoint. - * - * @return array 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, 200 ); - } -} 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 26bc422c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-wpcom-products.php +++ /dev/null @@ -1,229 +0,0 @@ -get_ip( true ); - $headers = array( - 'X-Forwarded-For' => $ip, - ); - - // If has a blog id, use connected endpoint. - - if ( $blog_id ) { - $endpoint = sprintf( '/sites/%d/products/?_locale=%s&type=jetpack', $blog_id, get_user_locale() ); - - $wpcom_request = Client::wpcom_json_api_request_as_blog( - $endpoint, - '1.1', - array( - 'method' => 'GET', - 'headers' => $headers, - ) - ); - } else { - $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 { - return 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 ) - ); - } - } - - /** - * 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() ); - 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; - } - $cache_date = get_user_meta( get_current_user_id(), self::CACHE_DATE_META_NAME, true ); - return time() - (int) $cache_date > ( 7 * 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. - * - * @return ?Object The product details if found - */ - public static function get_product( $product_slug ) { - $products = self::get_products(); - 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, - ); - - return self::populate_with_discount( $product, $pricing, $discount_price ); - } - - /** - * Populate the pricing array with the discount information. - * - * @param {object} $product - The product object. - * @param {object} $pricing - The pricing array. - * @param {float} $price - The price to be discounted. - * @return {object} 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; - } -} 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 583f52e4..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,138 +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' ); - } - - /** - * 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 6dfd6116..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-backup.php +++ /dev/null @@ -1,214 +0,0 @@ - _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 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() ) - ); - } - - /** - * 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 ) ) { - return new WP_Error( 'rewind_state_fetch_failed' ); - } - - $body = wp_remote_retrieve_body( $response ); - $status = json_decode( $body ); - return $status; - } - - /** - * Checks whether the current plan (or purchases) of the site already supports the product - * - * @return boolean - */ - public static function has_required_plan() { - $rewind_data = static::get_state_from_wpcom(); - if ( is_wp_error( $rewind_data ) ) { - return false; - } - return is_object( $rewind_data ) && isset( $rewind_data->state ) && 'unavailable' !== $rewind_data->state; - } - - /** - * Return product bundles list - * that supports the product. - * - * @return boolean|array Products bundle list. - */ - public static function is_upgradable_by_bundle() { - return array( 'security' ); - } - - /** - * 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() { - if ( static::is_plugin_active() ) { - return admin_url( 'admin.php?page=jetpack-backup' ); - } - } - - /** - * Checks whether the Product is active - * - * @return boolean - */ - public static function is_active() { - return parent::is_active() && static::has_required_plan(); - } -} 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 7c159eb4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-boost.php +++ /dev/null @@ -1,117 +0,0 @@ - true, - 'is_free' => true, - ); - } - - /** - * 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' ); - } -} 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 9fce5f92..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-crm.php +++ /dev/null @@ -1,124 +0,0 @@ - true, - 'is_free' => true, - ); - } - - /** - * 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' ); - } -} 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 ec35be1d..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-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 3b5d2758..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,132 +0,0 @@ -is_active( static::$module_name ); - } - return true; - } - - /** - * Checks whether the Product is active - * - * @return boolean - */ - public static function is_active() { - return parent::is_active() && static::is_module_active(); - } - - /** - * Activates the plugin - * - * @return null|WP_Error Null on success, WP_Error on invalid file. - */ - public static function activate_plugin() { - /* - * Activate self-installed plugin if it's installed. - */ - if ( parent::is_plugin_installed() ) { - return activate_plugin( static::get_installed_plugin_filename() ); - } - - /* - * Otherwise, activate Jetpack plugin. - */ - if ( static::is_jetpack_plugin_installed() ) { - return activate_plugin( static::get_installed_plugin_filename( 'jetpack' ) ); - } - - return new WP_Error( 'plugin_not_found', __( 'Activation failed. Plugin is not installed', 'jetpack-my-jetpack' ) ); - } - - /** - * Activates the product. If the Hybrid product has declared a jetpack module name, let's try to activate it if Jetpack plugin is active - * - * @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 ) { - - if ( is_wp_error( $product_activation ) ) { - // If we failed to install the stand-alone plugin because the package was not found, let's try and install Jetpack plugin instead. - // This might happen, for example, while the stand-alone plugin was not released to the WP.org repository yet. - if ( 'no_package' === $product_activation->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 ) ) { - if ( ! static::has_required_plan() ) { - // translators: %s is the product name. e.g. Jetpack Search. - return new WP_Error( 'not_supported', sprintf( __( 'Your plan does not support %s.', 'jetpack-my-jetpack' ), static::get_title() ) ); - } - $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; - } - -} 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 444f26b8..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,134 +0,0 @@ - static::$slug, - 'plugin_slug' => static::$plugin_slug, - 'name' => static::get_name(), - 'title' => static::get_title(), - 'description' => static::get_description(), - 'long_description' => static::get_long_description(), - 'features' => static::get_features(), - 'disclaimers' => static::get_disclaimers(), - 'status' => static::get_status(), - 'pricing_for_ui' => static::get_pricing_for_ui(), - 'is_bundle' => static::is_bundle_product(), - 'is_upgradable_by_bundle' => static::is_upgradable_by_bundle(), - 'supported_products' => static::get_supported_products(), - 'wpcom_product_slug' => static::get_wpcom_product_slug(), - 'requires_user_connection' => static::$requires_user_connection, - 'has_required_plan' => static::has_required_plan(), - 'manage_url' => static::get_manage_url(), - 'post_activation_url' => static::get_post_activation_url(), - 'class' => get_called_class(), - ); - } - - /** - * Get the internationalized product name - * - * @return string - */ - abstract public static function get_name(); - - /** - * Get the internationalized 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 internationalized features list - * - * @return array - */ - abstract public static function get_features(); - - /** - * Get the product pricing - * - * @return array - */ - abstract public static function get_pricing_for_ui(); - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - abstract public static function get_manage_url(); - - /** - * 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 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(); - } - - /** - * Checks whether the current plan (or purchases) of the site already supports the product - * - * Returns true if it supports. Return false if a purchase is still required. - * - * Free products will always return true. - * - * @return boolean - */ - public static function has_required_plan() { - return true; - } - - /** - * 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 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(); - } - - /** - * Undocumented function - * - * @return string - */ - public static function get_status() { - - if ( ! static::is_plugin_installed() ) { - $status = 'plugin_absent'; - } elseif ( static::is_active() ) { - $status = 'active'; - // We only consider missing user connection an error when the Product is active. - if ( static::$requires_user_connection && ! ( new Connection_Manager() )->has_connected_owner() ) { - $status = 'error'; - } elseif ( ! static::has_required_plan() ) { // We need needs_purchase here as well because some products we consider active without the required plan. - if ( static::has_trial_support() ) { - $status = 'needs_purchase_or_free'; - } else { - $status = 'needs_purchase'; - } - } - } elseif ( ! static::has_required_plan() ) { - if ( static::has_trial_support() ) { - $status = 'needs_purchase_or_free'; - } else { - $status = 'needs_purchase'; - } - } else { - $status = 'inactive'; - } - return $status; - } - - /** - * Checks whether the Product is active - * - * @return boolean - */ - public static function is_active() { - return static::is_plugin_active() && static::has_required_plan(); - } - - /** - * 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' ) ); - } - - /** - * 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; - } - - if ( ! static::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 ); - } - - /** - * Extend the plugin action links. - */ - public static function extend_plugin_action_links() { - - $filenames = static::get_plugin_filename(); - if ( ! is_array( $filenames ) ) { - $filenames = array( $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 ); - } - } - } - -} 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 a4cca50a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-protect.php +++ /dev/null @@ -1,119 +0,0 @@ - true, - 'is_free' => true, - ); - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return admin_url( 'admin.php?page=jetpack-protect' ); - } -} 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 0ab5eae6..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'; - } - - /** - * Hits the wpcom api to check scan 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/scan', $site_id ) . '?force=wpcom', '2', array( 'timeout' => 2 ), null, 'wpcom' ); - - if ( 200 !== wp_remote_retrieve_response_code( $response ) ) { - return new WP_Error( 'scan_state_fetch_failed' ); - } - - $body = wp_remote_retrieve_body( $response ); - $status = json_decode( $body ); - return $status; - } - - /** - * Checks whether the current plan (or purchases) of the site already supports the product - * - * @return boolean - */ - public static function has_required_plan() { - $scan_data = static::get_state_from_wpcom(); - if ( is_wp_error( $scan_data ) ) { - return false; - } - return is_object( $scan_data ) && isset( $scan_data->state ) && 'unavailable' !== $scan_data->state; - } - - /** - * 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() && static::has_required_plan(); - } - - /** - * 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; - } - - /** - * Return product bundles list - * that supports the product. - * - * @return boolean|array Products bundle list. - */ - public static function is_upgradable_by_bundle() { - return array( 'security' ); - } - - /** - * 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' ); - } -} 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 8d363a3b..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,150 +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. - */ - 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; - } - - $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 0bc1319b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-search.php +++ /dev/null @@ -1,324 +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 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_purchase_or_free` when status is `needs_purchase`. - */ - 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(); - - if ( isset( $pricings[ $record_count ] ) ) { - return $pricings[ $record_count ]; - } - - if ( defined( 'IS_WPCOM' ) && IS_WPCOM ) { - // For simple sites fetch the response directly. - $response = Client::wpcom_json_api_request_as_blog( - sprintf( '/jetpack-search/pricing?record_count=%1$d&locale=%2$s', $record_count, get_user_locale() ), - '2', - array( 'timeout' => 5 ), - null, - 'wpcom' - ); - } else { - // For non-simple sites we have to use the wp_remote_get, as connection might not be available. - $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 ]; - } - - /** - * Hits the wpcom api to check Search status. - * - * @todo Maybe add caching. - * - * @return Object|WP_Error - */ - private static function get_state_from_wpcom() { - static $status = null; - - if ( $status !== null ) { - return $status; - } - - $blog_id = Jetpack_Options::get_option( 'id' ); - - $response = Client::wpcom_json_api_request_as_blog( - '/sites/' . $blog_id . '/jetpack-search/plan', - '2', - array( 'timeout' => 5 ), - null, - 'wpcom' - ); - - if ( is_wp_error( $response ) || 200 !== wp_remote_retrieve_response_code( $response ) ) { - return new WP_Error( 'search_state_fetch_failed' ); - } - - $body = wp_remote_retrieve_body( $response ); - $status = json_decode( $body ); - return $status; - } - - /** - * 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(); - } - - /** - * Checks whether the current plan of the site already supports the product - * - * Returns true if it supports. Return false if a purchase is still required. - * - * Free products will always return true. - * - * @return boolean - */ - public static function has_required_plan() { - $search_state = static::get_state_from_wpcom(); - return ! empty( $search_state->supports_search ) || ! empty( $search_state->supports_instant_search ); - } - - /** - * 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' ); - } - -} 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 9f8ef881..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-security.php +++ /dev/null @@ -1,246 +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_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(); - } - - /** - * Hits the wpcom api to check scan 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/purchases', $site_id ), - '1.1', - array( - 'method' => 'GET', - ) - ); - if ( 200 !== wp_remote_retrieve_response_code( $response ) ) { - return new WP_Error( 'purchases_state_fetch_failed' ); - } - - $body = wp_remote_retrieve_body( $response ); - $status = json_decode( $body ); - return $status; - } - - /** - * Checks whether the current plan (or purchases) of the site already supports the product - * - * @return boolean - */ - public static function has_required_plan() { - $purchases_data = static::get_state_from_wpcom(); - if ( is_wp_error( $purchases_data ) ) { - return false; - } - if ( is_array( $purchases_data ) && ! empty( $purchases_data ) ) { - foreach ( $purchases_data as $purchase ) { - if ( - 0 === strpos( $purchase->product_slug, 'jetpack_security' ) || - 0 === strpos( $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-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 c8add202..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-social.php +++ /dev/null @@ -1,133 +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_social'; - } - - /** - * Get the URL where the user manages the product - * - * @return string - */ - public static function get_manage_url() { - if ( static::is_plugin_active() ) { - return admin_url( 'admin.php?page=jetpack-social' ); - } - } -} 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 3fe08372..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-videopress.php +++ /dev/null @@ -1,151 +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_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(); - } - } - -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-partner/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-partner/CHANGELOG.md deleted file mode 100644 index 9e69497a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-partner/CHANGELOG.md +++ /dev/null @@ -1,264 +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). - -## [1.7.23] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [1.7.22] - 2023-02-20 -### Changed -- Minor internal updates. - -## [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-10-25 -### Changed -- Updated package dependencies. [#26705] - -## [1.7.17] - 2022-09-20 -### Changed -- Updated package dependencies. - -## [1.7.16] - 2022-09-08 -### Changed -- Updated package dependencies. - -## [1.7.15] - 2022-08-29 -### Changed -- Updated package dependencies. - -## [1.7.14] - 2022-08-23 -### Changed -- Updated package dependencies. [#25628] - -## [1.7.13] - 2022-08-03 -### Changed -- Updated package dependencies. [#25300, #25315] - -## [1.7.12] - 2022-07-26 -### Changed -- Updated package dependencies. [#25158] - -## [1.7.11] - 2022-06-21 -### Changed -- Renaming master to trunk. [#24661] - -## [1.7.10] - 2022-06-14 -### Changed -- Updated package dependencies. [#24529] - -## [1.7.9] - 2022-05-18 -### Fixed -- Fix new PHPCS sniffs. [#24366] - -## [1.7.8] - 2022-05-04 -### Changed -- Updated package dependencies. [#24095] - -### Deprecated -- Moved the options class into Connection. [#24095] - -## [1.7.7] - 2022-04-26 -### Changed -- Updated package dependencies. - -## [1.7.6] - 2022-04-19 -### Changed -- PHPCS: Fix `WordPress.Security.ValidatedSanitizedInput` - -## [1.7.5] - 2022-04-12 -### Changed -- Updated package dependencies. - -## [1.7.4] - 2022-04-06 -### Changed -- Updated package dependencies. - -## [1.7.3] - 2022-03-29 -### Changed -- Microperformance: Use === null instead of is_null - -## [1.7.2] - 2022-03-02 -### Changed -- Updated package dependencies. - -## [1.7.1] - 2022-02-22 -### Changed -- Updated package dependencies. - -## [1.7.0] - 2022-02-16 -### Added -- Added the ability to specify a partner logo for each supported partner -- Remotely check if partner coupon looks valid - -## [1.6.4] - 2022-01-25 -### Changed -- Updated package dependencies. - -## [1.6.3] - 2022-01-18 -### Changed -- Updated package dependencies. - -## [1.6.2] - 2022-01-04 -### Changed -- Switch to pcov for code coverage. -- Updated package dependencies - -## [1.6.1] - 2021-12-14 -### Changed -- Updated package dependencies. - -## [1.6.0] - 2021-11-30 -### Added -- Addde partner coupon logic - -## [1.5.7] - 2021-11-23 -### Changed -- Updated package dependencies - -## [1.5.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.5.5] - 2021-10-19 -### Changed -- Updated package dependencies. - -## [1.5.4] - 2021-10-12 -### Changed -- Updated package dependencies - -## [1.5.3] - 2021-09-28 -### Changed -- Updated package dependencies. - -## [1.5.2] - 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. - -## [1.5.1] - 2021-05-25 -### Changed -- Updated package dependencies. - -## [1.5.0] - 2021-04-27 -### Added -- Adds segmentation "from" parameter to the registration flow - -## [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-29 - -- Update dependency brain/monkey to v2.5.0 -- Updated PHPCS: Packages and Debugger - -## [1.3.0] - 2020-08-25 - -- Update Authorize URL iframe to include affiliate code -- Packages: Update filenames after #16810 -- 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 -- Update README.md on partner package - -## [1.0.1] - 2020-01-27 - -- Pin dependency brain/monkey to 2.4.0 - -## 1.0.0 - 2019-12-16 - -- Add partner subsidiary id to upgrade URLs. - -[1.7.23]: https://github.com/Automattic/jetpack-partner/compare/v1.7.22...v1.7.23 -[1.7.22]: https://github.com/Automattic/jetpack-partner/compare/v1.7.21...v1.7.22 -[1.7.21]: https://github.com/Automattic/jetpack-partner/compare/v1.7.20...v1.7.21 -[1.7.20]: https://github.com/Automattic/jetpack-partner/compare/v1.7.19...v1.7.20 -[1.7.19]: https://github.com/Automattic/jetpack-partner/compare/v1.7.18...v1.7.19 -[1.7.18]: https://github.com/Automattic/jetpack-partner/compare/v1.7.17...v1.7.18 -[1.7.17]: https://github.com/Automattic/jetpack-partner/compare/v1.7.16...v1.7.17 -[1.7.16]: https://github.com/Automattic/jetpack-partner/compare/v1.7.15...v1.7.16 -[1.7.15]: https://github.com/Automattic/jetpack-partner/compare/v1.7.14...v1.7.15 -[1.7.14]: https://github.com/Automattic/jetpack-partner/compare/v1.7.13...v1.7.14 -[1.7.13]: https://github.com/Automattic/jetpack-partner/compare/v1.7.12...v1.7.13 -[1.7.12]: https://github.com/Automattic/jetpack-partner/compare/v1.7.11...v1.7.12 -[1.7.11]: https://github.com/Automattic/jetpack-partner/compare/v1.7.10...v1.7.11 -[1.7.10]: https://github.com/Automattic/jetpack-partner/compare/v1.7.9...v1.7.10 -[1.7.9]: https://github.com/Automattic/jetpack-partner/compare/v1.7.8...v1.7.9 -[1.7.8]: https://github.com/Automattic/jetpack-partner/compare/v1.7.7...v1.7.8 -[1.7.7]: https://github.com/Automattic/jetpack-partner/compare/v1.7.6...v1.7.7 -[1.7.6]: https://github.com/Automattic/jetpack-partner/compare/v1.7.5...v1.7.6 -[1.7.5]: https://github.com/Automattic/jetpack-partner/compare/v1.7.4...v1.7.5 -[1.7.4]: https://github.com/Automattic/jetpack-partner/compare/v1.7.3...v1.7.4 -[1.7.3]: https://github.com/Automattic/jetpack-partner/compare/v1.7.2...v1.7.3 -[1.7.2]: https://github.com/Automattic/jetpack-partner/compare/v1.7.1...v1.7.2 -[1.7.1]: https://github.com/Automattic/jetpack-partner/compare/v1.7.0...v1.7.1 -[1.7.0]: https://github.com/Automattic/jetpack-partner/compare/v1.6.4...v1.7.0 -[1.6.4]: https://github.com/Automattic/jetpack-partner/compare/v1.6.3...v1.6.4 -[1.6.3]: https://github.com/Automattic/jetpack-partner/compare/v1.6.2...v1.6.3 -[1.6.2]: https://github.com/Automattic/jetpack-partner/compare/v1.6.1...v1.6.2 -[1.6.1]: https://github.com/Automattic/jetpack-partner/compare/v1.6.0...v1.6.1 -[1.6.0]: https://github.com/Automattic/jetpack-partner/compare/v1.5.7...v1.6.0 -[1.5.7]: https://github.com/Automattic/jetpack-partner/compare/v1.5.6...v1.5.7 -[1.5.6]: https://github.com/Automattic/jetpack-partner/compare/v1.5.5...v1.5.6 -[1.5.5]: https://github.com/Automattic/jetpack-partner/compare/v1.5.4...v1.5.5 -[1.5.4]: https://github.com/Automattic/jetpack-partner/compare/v1.5.3...v1.5.4 -[1.5.3]: https://github.com/Automattic/jetpack-partner/compare/v1.5.2...v1.5.3 -[1.5.2]: https://github.com/Automattic/jetpack-partner/compare/v1.5.1...v1.5.2 -[1.5.1]: https://github.com/Automattic/jetpack-partner/compare/v1.5.0...v1.5.1 -[1.5.0]: https://github.com/Automattic/jetpack-partner/compare/v1.4.3...v1.5.0 -[1.4.3]: https://github.com/Automattic/jetpack-partner/compare/v1.4.2...v1.4.3 -[1.4.2]: https://github.com/Automattic/jetpack-partner/compare/v1.4.1...v1.4.2 -[1.4.1]: https://github.com/Automattic/jetpack-partner/compare/v1.4.0...v1.4.1 -[1.4.0]: https://github.com/Automattic/jetpack-partner/compare/v1.3.1...v1.4.0 -[1.3.1]: https://github.com/Automattic/jetpack-partner/compare/v1.3.0...v1.3.1 -[1.3.0]: https://github.com/Automattic/jetpack-partner/compare/v1.2.0...v1.3.0 -[1.2.0]: https://github.com/Automattic/jetpack-partner/compare/v1.1.0...v1.2.0 -[1.1.0]: https://github.com/Automattic/jetpack-partner/compare/v1.0.1...v1.1.0 -[1.0.1]: https://github.com/Automattic/jetpack-partner/compare/v1.0.0...v1.0.1 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-partner/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-partner/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-partner/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-partner/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-partner/SECURITY.md deleted file mode 100644 index b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-partner/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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-partner/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-partner/composer.json deleted file mode 100644 index 5caacc08..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-partner/composer.json +++ /dev/null @@ -1,51 +0,0 @@ -{ - "name": "automattic/jetpack-partner", - "description": "Support functions for Jetpack hosting partners.", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "automattic/jetpack-connection": "^1.51.7", - "automattic/jetpack-status": "^1.16.4" - }, - "require-dev": { - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/wordbless": "@dev" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "post-install-cmd": "WorDBless\\Composer\\InstallDropin::copy", - "post-update-cmd": "WorDBless\\Composer\\InstallDropin::copy", - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-partner", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-partner/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "1.7.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-partner/src/class-partner-coupon.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-partner/src/class-partner-coupon.php deleted file mode 100644 index c664e9e8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-partner/src/class-partner-coupon.php +++ /dev/null @@ -1,464 +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 1.6.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 1.6.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-partner/src/class-partner.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-partner/src/class-partner.php deleted file mode 100644 index 2d70c521..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-partner/src/class-partner.php +++ /dev/null @@ -1,199 +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. - * - * @param array $params The parameters array. - * - * @return array - * @since 1.5.0 - */ - 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. - * - * @param array $params The parameters array. - * - * @return array - * @since 1.5.0 - */ - 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. - * - * @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. - * @since 1.0.0 - */ - 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 - * - * @param string $type The partner code. - * @return array - * @since 1.5.0 - */ - 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. - * - * @param string $type This can be either 'affiliate' or 'subsidiary'. Returns empty string when code is unknown. - * - * @return string The partner code. - * @since 1.0.0 - */ - public function get_partner_code( $type ) { - switch ( $type ) { - case self::AFFILIATE_CODE: - /** - * Allow to filter the affiliate code. - * - * @param string $affiliate_code The affiliate code, blank by default. - * - * @since 1.0.0 - * @since-jetpack 6.9.0 - */ - return apply_filters( 'jetpack_affiliate_code', get_option( 'jetpack_affiliate_code', '' ) ); - case self::SUBSIDIARY_CODE: - /** - * Allow to filter the partner subsidiary id. - * - * @param string $subsidiary_id The partner subsidiary id, blank by default. - * - * @since 1.0.0 - */ - 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-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 fd9fd790..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/CHANGELOG.md +++ /dev/null @@ -1,128 +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.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.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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 305f4f12..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/composer.json +++ /dev/null @@ -1,48 +0,0 @@ -{ - "name": "automattic/jetpack-password-checker", - "description": "Password Checker.", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": {}, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/wordbless": "@dev", - "yoast/phpunit-polyfills": "1.0.4" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "test-php": [ - "@composer phpunit" - ], - "post-install-cmd": "WorDBless\\Composer\\InstallDropin::copy", - "post-update-cmd": "WorDBless\\Composer\\InstallDropin::copy" - }, - "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.2.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 2cd55356..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/CHANGELOG.md +++ /dev/null @@ -1,58 +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.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.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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 2c4f7476..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/composer.json +++ /dev/null @@ -1,39 +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": { - "automattic/jetpack-a8c-mc-stats": "^1.4.19" - }, - "require-dev": { - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2" - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "branch-alias": { - "dev-trunk": "0.2.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 ae129c59..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,155 +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 4ebf4a83..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/src/class-plugins-installer.php +++ /dev/null @@ -1,291 +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 = $upgrader->skin->get_main_error_code(); - $message = $upgrader->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 $next-version$ - * - * @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 $next-version$ - * - * @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. - * - * @param string $plugin Plugin file path to check. - * @return bool - */ - public static 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-redirect/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/CHANGELOG.md deleted file mode 100644 index 74167861..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/CHANGELOG.md +++ /dev/null @@ -1,221 +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). - -## [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 - -[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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 65b22bab..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/composer.json +++ /dev/null @@ -1,42 +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": { - "automattic/jetpack-status": "^1.16.4" - }, - "require-dev": { - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "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": "1.7.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 da5979b3..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 ( 0 === strpos( $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 0c3c1335..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/CHANGELOG.md +++ /dev/null @@ -1,180 +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). - -## [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 - -[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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 a8a6864e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/composer.json +++ /dev/null @@ -1,40 +0,0 @@ -{ - "name": "automattic/jetpack-roles", - "description": "Utilities, related with user roles and capabilities.", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": {}, - "require-dev": { - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "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": "1.4.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 c29f6e06..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/CHANGELOG.md +++ /dev/null @@ -1,310 +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). - -## [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 - -[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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 a8b1733f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/composer.json +++ /dev/null @@ -1,43 +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": { - "automattic/jetpack-constants": "^1.6.22" - }, - "require-dev": { - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/jetpack-ip": "^0.1.2" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "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": "1.17.x-dev" - } - } -} 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 9ca54593..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-cache.php +++ /dev/null @@ -1,55 +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 342f1759..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-errors.php +++ /dev/null @@ -1,43 +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; - } -} 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 955697f9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-modules.php +++ /dev/null @@ -1,596 +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'] ) && 'jetpack' === substr( $_GET['page'], 0, 7 ); // 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. - */ - public function get_active() { - $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. - if ( ! in_array( 'protect', $active, true ) && is_multisite() && get_site_option( 'jetpack_protect_active' ) ) { - $active[] = 'protect'; - } - - // 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() && ! $status->is_onboarding() ) { - 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', join( ',', $deactivated ) ); - wp_safe_redirect( add_query_arg( 'jetpack_restate', 1 ) ); - exit; - } - } - } - - // 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 ( class_exists( 'Jetpack_Plan' ) && ! \Jetpack_Plan::supports( $module ) ) { - return false; - } - - // Check the file for fatal errors, a la wp-admin/plugins.php::activate. - $errors = new Errors(); - $state->state( 'module', $module ); - $state->state( 'error', 'module_activation_failed' ); // we'll override this later if the plugin can be included without fatal error. - $errors->catch_errors( true ); - - 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(); - $errors->catch_errors( false ); - } 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; - } - 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 $success bool 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 a3313c66..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-paths.php +++ /dev/null @@ -1,28 +0,0 @@ - 'jetpack' ) ); - $url = add_query_arg( $args, admin_url( 'admin.php' ) ); - return $url; - } -} 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 96a5a11b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-status.php +++ /dev/null @@ -1,412 +0,0 @@ -is_offline_mode(). - * - * @return bool Whether Jetpack's offline mode is active. - */ - public function is_development_mode() { - _deprecated_function( __FUNCTION__, '1.3.0', 'Automattic\Jetpack\Status->is_offline_mode' ); - return $this->is_offline_mode(); - } - - /** - * Is Jetpack in offline mode? - * - * This was formerly called "Development Mode", but sites "in development" aren't always offline/localhost. - * - * @since 1.3.0 - * - * @return bool Whether Jetpack's offline mode is active. - */ - public function is_offline_mode() { - $cached = Cache::get( 'is_offline_mode' ); - if ( null !== $cached ) { - return $cached; - } - - $offline_mode = false; - - if ( defined( '\\JETPACK_DEV_DEBUG' ) ) { - $offline_mode = constant( '\\JETPACK_DEV_DEBUG' ); - } elseif ( defined( '\\WP_LOCAL_DEV' ) ) { - $offline_mode = constant( '\\WP_LOCAL_DEV' ); - } elseif ( $this->is_local_site() ) { - $offline_mode = true; - } - - /** - * Filters Jetpack's offline mode. - * - * @see https://jetpack.com/support/development-mode/ - * @todo Update documentation ^^. - * - * @since 1.1.1 - * @since-jetpack 2.2.1 - * @deprecated 1.3.0 - * - * @param bool $offline_mode Is Jetpack's offline mode active. - */ - $offline_mode = (bool) apply_filters_deprecated( 'jetpack_development_mode', array( $offline_mode ), '1.3.0', 'jetpack_offline_mode' ); - - /** - * Filters Jetpack's offline mode. - * - * @see https://jetpack.com/support/development-mode/ - * @todo Update documentation ^^. - * - * @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; - } - - /** - * Is Jetpack in "No User test mode"? - * - * This will make Jetpack act as if there were no connected users, but only a site connection (aka blog token) - * - * @since 1.6.0 - * @deprecated 1.7.5 Since this version, Jetpack connection is considered active after registration, making no_user_testing_mode obsolete. - * - * @return bool Whether Jetpack's No User Testing Mode is active. - */ - public function is_no_user_testing_mode() { - _deprecated_function( __METHOD__, '1.7.5' ); - return true; - } - - /** - * 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. - $is_local = $site_url && false === strpos( $site_url, '.' ); - - // @todo Remove function_exists when the package has a documented minimum WP version. - // Use Core's environment check, if available. Added in 5.5.0 / 5.5.1 (for `local` return value). - if ( function_exists( 'wp_get_environment_type' ) && '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. - ); - - 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. - * - * @todo Add IDC detection to a package. - * - * @return bool - */ - public function is_staging_site() { - $cached = Cache::get( 'is_staging_site' ); - if ( null !== $cached ) { - return $cached; - } - - // @todo Remove function_exists when the package has a documented minimum WP version. - // 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 = function_exists( 'wp_get_environment_type' ) && ! 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. - '#\.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; - } - - /** - * 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 - * - * @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 d80d891d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-visitor.php +++ /dev/null @@ -1,44 +0,0 @@ - 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 - -[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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 75a89ebf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/composer.json +++ /dev/null @@ -1,56 +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": { - "automattic/jetpack-connection": "^1.51.3", - "automattic/jetpack-constants": "^1.6.21", - "automattic/jetpack-identity-crisis": "^0.8.40", - "automattic/jetpack-password-checker": "^0.2.12", - "automattic/jetpack-ip": "^0.1.1", - "automattic/jetpack-roles": "^1.4.22", - "automattic/jetpack-status": "^1.16.3" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "yoast/phpunit-polyfills": "1.0.4", - "automattic/wordbless": "@dev" - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "test-php": [ - "@composer phpunit" - ], - "post-install-cmd": "WorDBless\\Composer\\InstallDropin::copy", - "post-update-cmd": "WorDBless\\Composer\\InstallDropin::copy" - }, - "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": "1.47.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-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 c1711af3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-actions.php +++ /dev/null @@ -1,1074 +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 - * - * @return bool - */ - public static function should_initialize_sender() { - - // 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. - */ - if ( 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; - } - - if ( ( new Status() )->is_staging_site() ) { - return false; - } - - $connection = new Jetpack_Connection(); - if ( ! $connection->is_connected() ) { - if ( ! doing_action( 'jetpack_site_registered' ) ) { - 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() )->is_staging_site() ) { - $debug['debug_details']['is_staging_site'] = 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 request. - * - * @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', - ); - - $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 ); - - $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 ); - - // Adhere to Retry-After headers. - $retry_after = $rpc->get_response_header( 'Retry-After' ); - if ( false !== $retry_after ) { - if ( (int) $retry_after > 0 ) { - update_option( self::RETRY_AFTER_PREFIX . $queue_id, microtime( true ) + (int) $retry_after, 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. - $dedicated_sync_header = $rpc->get_response_header( 'Jetpack-Dedicated-Sync' ); - if ( false !== $dedicated_sync_header ) { - Dedicated_Sender::maybe_change_dedicated_sync_status_from_wpcom_header( $dedicated_sync_header ); - } - - if ( ! $result ) { - if ( false === $retry_after ) { - // 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. - $error = $rpc->get_jetpack_error(); - $error->add_data( $rpc->get_last_response() ); - $error_log[ (string) microtime( true ) ] = $error; - // Update the error log. - update_option( self::ERROR_LOG_PREFIX . $queue_id, $error_log ); - - // return request error. - return $rpc->get_jetpack_error(); - } - - $response = $rpc->getResponse(); - - // 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' ) - ); - } - - // 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' ); - 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 ); - } - - /** - * 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' ); - 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. - * @return bool True if full sync was successfully started. - */ - public static function do_full_sync( $modules = null ) { - if ( ! self::sync_allowed() ) { - return false; - } - - $full_sync_module = Modules::get_module( 'full-sync' ); - - if ( ! $full_sync_module ) { - return false; - } - - self::initialize_listener(); - - $full_sync_module->start( $modules ); - - 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' ) ); - } - - /** - * 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; - } - - /** - * 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' ); - $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 ) && false === strpos( get_class( $sync_module ), '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 ); - - // 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(); - } - } -} 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 b1a4cb83..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-data-settings.php +++ /dev/null @@ -1,416 +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', - ), - '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' ), - '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', - /** - * Connection related options - */ - 'jetpack_connection_active_plugins', - /** - * Generic site options - */ - 'blog_charset', - 'blog_public', - 'blogdescription', - 'blogname', - 'permalink_structure', - 'stylesheet', - 'time_format', - 'timezone_string', - ), - ); - - 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 5b49c57e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-dedicated-sender.php +++ /dev/null @@ -1,411 +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(); - - // Only check if we're failing to send events if the queue lag is longer than the threshold. - if ( $queue_lag > $queue_send_time_threshold ) { - /** - * Check if Dedicated Sync is healthy and revert to Default Sync if such case is detected. - */ - $last_successful_queue_send_time = get_option( Actions::LAST_SUCCESS_PREFIX . $queue->id, null ); - - if ( $last_successful_queue_send_time === null ) { - /** - * No successful sync sending completed. This might be either a "new" sync site or a site that's totally stuck. - */ - self::on_dedicated_sync_lag_not_sending_threshold_reached(); - - return new WP_Error( 'dedicated_sync_not_sending', 'Dedicated Sync is not successfully sending events' ); - } else { - /** - * We have recorded a successful sending of events. Let's see if that is not too long ago in the past. - */ - $time_since_last_succesful_send = time() - $last_successful_queue_send_time; - - if ( $time_since_last_succesful_send > $queue_send_time_threshold ) { - // We haven't successfully sent stuff in more than 30 minutes. Revert to Default Sync - self::on_dedicated_sync_lag_not_sending_threshold_reached(); - - return new WP_Error( 'dedicated_sync_not_sending', 'Dedicated Sync is not successfully sending events' ); - } - } - } - - /** - * 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' ); - } - - $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 ); - - $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' ); - } - - $current_lock_value = \Jetpack_Options::get_raw_option( self::DEDICATED_SYNC_REQUEST_LOCK_OPTION_NAME, null ); - - // If this is the flow that has the lock, let's release it so we can spawn other requests afterwards - 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 $$next_version$$ - * - * @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 ef2ce369..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-defaults.php +++ /dev/null @@ -1,1299 +0,0 @@ - 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' ), - ); - - /** - * 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_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', - ); - - /** - * 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_page_template', - '_wp_trash_meta_comments_status', - '_wpas_feature_enabled', - '_wpas_is_tweetstorm', - '_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', - ); - - /** - * 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-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( - 'comments' => 1, - 'constants' => 1, - 'functions' => 1, - 'options' => 1, - 'posts' => 1, - 'term_relationships' => 1, - 'terms' => 1, - 'themes' => 1, - 'updates' => 1, - 'users' => 1, - ); - - /** - * 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, - ), - ); - - /** - * Default for enabling dedicated Sync flow. - * - * @var int Bool-ish. Default 0. - */ - public static $default_dedicated_sync_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 1a5d9c7d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-functions.php +++ /dev/null @@ -1,674 +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 callable $callable Function 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. - * - * @return bool Theme is a Full Site Editing theme. - */ - public static function get_is_fse_theme() { - return function_exists( 'gutenberg_is_fse_theme' ) && gutenberg_is_fse_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 array|obj $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 $$next_version$$ - * - * @return array - */ - public static function get_active_modules() { - return ( new Jetpack_Modules() )->get_active(); - } -} 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 2aa2465c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-health.php +++ /dev/null @@ -1,189 +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 ecc33a94..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,93 +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 ) { - return $this->json_unserialize( gzinflate( base64_decode( $input ) ) ); // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_decode - } - - /** - * Serialize JSON - * - * @see https://gist.github.com/muhqu/820694 - * - * @param string $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 41f8aaf8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-listener.php +++ /dev/null @@ -1,483 +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. - */ - 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. - */ - 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'], $_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 b3998c90..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-main.php +++ /dev/null @@ -1,114 +0,0 @@ -uninstall(); - } - - /** - * 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 993ebef5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-modules.php +++ /dev/null @@ -1,160 +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 ) { - 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_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' ) ) { - 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 3450d5a5..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 c6fdca1d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-queue.php +++ /dev/null @@ -1,758 +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 ); - } - - /** - * Add a single item to the queue. - * - * @param object $item Event object to add to queue. - */ - public function add( $item ) { - global $wpdb; - $added = false; - - // If empty, don't add. - if ( empty( $item ) ) { - return; - } - - // 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; - } - - // This basically tries to add the option until enough time has elapsed that - // it has a unique (microtime-based) option key. - while ( ! $added ) { - $rows_added = $wpdb->query( - $wpdb->prepare( - "INSERT INTO $wpdb->options (option_name, option_value, autoload) VALUES (%s, %s,%s)", - $this->get_next_data_row_option_name(), - $item, - 'no' - ) - ); - $added = ( 0 !== $rows_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 ) { - global $wpdb; - $base_option_name = $this->get_next_data_row_option_name(); - - $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( $base_option_name . '-' . $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 . join( ',', $rows ) ); // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - - 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 microtime $now The current time in microtime. - * - * @return float|int|mixed|null - */ - public function lag( $now = null ) { - global $wpdb; - - $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->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->id . '-(\d+\.\d+)-/', $first_item_name, $matches ) ) { - return $now - (float) $matches[1]; - } else { - return 0; - } - } - - /** - * Resets the queue. - */ - public function reset() { - global $wpdb; - $this->delete_checkout_id(); - $wpdb->query( - $wpdb->prepare( - "DELETE FROM $wpdb->options WHERE option_name LIKE %s", - "jpsq_{$this->id}-%" - ) - ); - } - - /** - * Return the size of the queue. - * - * @return int - */ - public function size() { - global $wpdb; - - return (int) $wpdb->get_var( - $wpdb->prepare( - "SELECT count(*) FROM $wpdb->options WHERE option_name LIKE %s", - "jpsq_{$this->id}-%" - ) - ); - } - - /** - * 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() { - global $wpdb; - $value = $wpdb->get_var( - $wpdb->prepare( - "SELECT exists( SELECT option_name FROM $wpdb->options WHERE option_name LIKE %s )", - "jpsq_{$this->id}-%" - ) - ); - - return ( '1' === $value ); - } - - /** - * 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' ); - } - - $buffer_id = uniqid(); - - $result = $this->set_checkout_id( $buffer_id ); - - if ( ! $result || is_wp_error( $result ) ) { - return $result; - } - - $items = $this->fetch_items( $buffer_size ); - - if ( count( $items ) === 0 ) { - return false; - } - - $buffer = new Queue_Buffer( $buffer_id, array_slice( $items, 0, $buffer_size ) ); - - return $buffer; - } - - /** - * 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(); - - $result = $this->set_checkout_id( $buffer_id ); - - if ( ! $result || is_wp_error( $result ) ) { - return $result; - } - - // Get the map of buffer_id -> memory_size. - global $wpdb; - - $items_with_size = $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->id}-%", - $max_buffer_size - ), - OBJECT - ); - - if ( count( $items_with_size ) === 0 ) { - return false; - } - - $total_memory = 0; - $max_item_id = $items_with_size[0]->id; - $min_item_id = $max_item_id; - - foreach ( $items_with_size 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; - } - - $max_item_id = $item_with_size->id; - } - - $query = $wpdb->prepare( - "SELECT option_name AS id, option_value AS value FROM $wpdb->options WHERE option_name >= %s and option_name <= %s ORDER BY option_name ASC", - $min_item_id, - $max_item_id - ); - - $items = $wpdb->get_results( $query, OBJECT ); // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - foreach ( $items as $item ) { - // @codingStandardsIgnoreStart - $item->value = @unserialize( $item->value ); - // @codingStandardsIgnoreEnd - } - - if ( count( $items ) === 0 ) { - $this->delete_checkout_id(); - - return false; - } - - $buffer = new Queue_Buffer( $buffer_id, $items ); - - return $buffer; - } - - /** - * 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 ( 0 === count( $ids ) ) { - return 0; - } - global $wpdb; - $sql = "DELETE FROM $wpdb->options WHERE option_name IN (" . implode( ', ', array_fill( 0, count( $ids ), '%s' ) ) . ')'; - $query = call_user_func_array( array( $wpdb, 'prepare' ), array_merge( array( $sql ), $ids ) ); - - return $wpdb->query( $query ); // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - } - - /** - * 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 ) { - global $wpdb; - - if ( $limit ) { - $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->id}-%", - $limit - ), - OBJECT - ); - } else { - $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->id}-%" - ), - OBJECT - ); - } - - 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 ) { - global $wpdb; - - // return early if $items_ids is empty or not an array. - if ( empty( $items_ids ) || ! is_array( $items_ids ) ) { - return null; - } - - $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 )"; - $items = $wpdb->get_results( - $wpdb->prepare( - $query_with_placeholders, // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - $items_ids - ), - OBJECT - ); - - return $this->unserialize_values( $items ); - } - - /** - * 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 ae947009..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-replicastore.php +++ /dev/null @@ -1,1457 +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; - return $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; - return $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; - return $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 - return $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 - return $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 $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 User object. - */ - public function get_user( $user_id ) { - return \WP_User::get_instance( $user_id ); - } - - /** - * 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. - * Currently that is posts, comments, post meta and comment meta. - * - * @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 ) { - $post_checksum = $this->checksum_histogram( 'posts', null, null, null, null, true, '', false, false, $perform_text_conversion ); - $comments_checksum = $this->checksum_histogram( 'comments', null, null, null, null, true, '', false, false, $perform_text_conversion ); - $post_meta_checksum = $this->checksum_histogram( 'postmeta', null, null, null, null, true, '', false, false, $perform_text_conversion ); - $comment_meta_checksum = $this->checksum_histogram( 'commentmeta', null, null, null, null, true, '', false, false, $perform_text_conversion ); - $terms_checksum = $this->checksum_histogram( 'terms', null, null, null, null, true, '', false, false, $perform_text_conversion ); - $term_relationships_checksum = $this->checksum_histogram( 'term_relationships', null, null, null, null, true, '', false, false, $perform_text_conversion ); - $term_taxonomy_checksum = $this->checksum_histogram( 'term_taxonomy', null, null, null, null, true, '', false, false, $perform_text_conversion ); - - $result = array( - 'posts' => $this->summarize_checksum_histogram( $post_checksum ), - 'comments' => $this->summarize_checksum_histogram( $comments_checksum ), - 'post_meta' => $this->summarize_checksum_histogram( $post_meta_checksum ), - 'comment_meta' => $this->summarize_checksum_histogram( $comment_meta_checksum ), - 'terms' => $this->summarize_checksum_histogram( $terms_checksum ), - 'term_relationships' => $this->summarize_checksum_histogram( $term_relationships_checksum ), - 'term_taxonomy' => $this->summarize_checksum_histogram( $term_taxonomy_checksum ), - ); - - /** - * 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 ( $force_woocommerce_support || class_exists( 'WooCommerce' ) ) { - /** - * Guard in Try/Catch as it's possible for the WooCommerce class to exist, but - * the tables to not. If we don't do this, the response will be just the exception, without - * returning any valid data. This will prevent us from ever performing a checksum/fix - * for sites like this. - * It's better to just skip the tables in the response, instead of completely failing. - */ - - try { - $woocommerce_order_items_checksum = $this->checksum_histogram( 'woocommerce_order_items' ); - $result['woocommerce_order_items'] = $this->summarize_checksum_histogram( $woocommerce_order_items_checksum ); - } catch ( Exception $ex ) { - $result['woocommerce_order_items'] = null; - } - - try { - $woocommerce_order_itemmeta_checksum = $this->checksum_histogram( 'woocommerce_order_itemmeta' ); - $result['woocommerce_order_itemmeta'] = $this->summarize_checksum_histogram( $woocommerce_order_itemmeta_checksum ); - } catch ( Exception $ex ) { - $result['woocommerce_order_itemmeta'] = 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 $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. - * @throws Exception Throws an exception if data validation fails inside `Table_Checksum` calls. - */ - 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 ); - } catch ( Exception $ex ) { - return new WP_Error( 'checksum_disabled', $ex->getMessage() ); - } - - // Validate / Determine Buckets. - if ( $buckets === null || $buckets < 1 ) { - $buckets = $this->calculate_buckets( $table, $start_id, $end_id ); - } - if ( is_wp_error( $buckets ) ) { - return $buckets; - } - - $range_edges = $checksum_table->get_range_edges( $start_id, $end_id ); - - if ( $only_range_edges ) { - return $range_edges; - } - - $object_count = (int) $range_edges['item_count']; - - if ( 0 === $object_count ) { - return array(); - } - - $bucket_size = (int) ceil( $object_count / $buckets ); - $previous_max_id = max( 0, $range_edges['min_range'] ); - $histogram = array(); - - do { - $ids_range = $checksum_table->get_range_edges( $previous_max_id, null, $bucket_size ); - - 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; - } - - $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 - * @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 $start_id Min Object ID. - * @param int $end_id Max Object ID. - * @return int|WP_Error Number of Buckets to use. - */ - private function calculate_buckets( $table, $start_id = null, $end_id = null ) { - // Get # of objects. - try { - $checksum_table = $this->get_table_checksum_instance( $table ); - } catch ( Exception $ex ) { - return new WP_Error( 'checksum_disabled', $ex->getMessage() ); - } - $range_edges = $checksum_table->get_range_edges( $start_id, $end_id ); - $object_count = $range_edges['item_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 null $salt Salt to be used when generating the checksums. - * @param false $perform_text_conversion Should we perform text encoding conversion when calculating the checksum. - * - * @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 ) { - if ( 'users' === $table ) { - return new Table_Checksum_Users( $table, $salt, $perform_text_conversion ); - } - if ( 'usermeta' === $table ) { - return new Table_Checksum_Usermeta( $table, $salt, $perform_text_conversion ); - } - - return new Table_Checksum( $table, $salt, $perform_text_conversion ); - } -} 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 2e29adbb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-rest-endpoints.php +++ /dev/null @@ -1,872 +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, - ), - ), - ) - ); - - // 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 endges 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 ( count( $ids ) > 0 ) { - $modules[ $module_name ] = $ids; - } - } - } - - if ( empty( $modules ) ) { - $modules = null; - } - - return rest_ensure_response( - array( - 'scheduled' => Actions::do_full_sync( $modules ), - ) - ); - } - - /** - * 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( $number_of_items ) ); - } - - return rest_ensure_response( $sender->queue_pull( $queue_name, $number_of_items, $args ) ); - } - - /** - * 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' ); - $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 $$next_version$$ - * - * @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 ) || substr( $item, 0, 5 ) !== '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 1c5a2a33..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(), - ); - } - - /** - * 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 9a7981a2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-sender.php +++ /dev/null @@ -1,1003 +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' ); - 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 ( false === strpos( get_class( $sync_module ), '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; - } - - Modules::get_module( 'full-sync' )->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 - 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; - } - } - - /** - * 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 ); - } - - // 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 ) { - // 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 && count( $items_to_send ) > 0 ) { - 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' ) && version_compare( phpversion(), '7.0.16', '>=' ) ) { - 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. - */ - 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 ) ); - if ( $had_wp_error ) { - $wp_error = array_pop( $processed_item_ids ); - } - // Also checkin any items that were skipped. - if ( count( $skipped_items_ids ) > 0 ) { - $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. - * - * @return 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 ) { - 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 ); - - 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. - * @return array An array of synthetic sync actions keyed by current microtime(true) - */ - private function create_action_to_send( $action_name, $data ) { - return array( - (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 7b6d0545..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 31cee3b2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-settings.php +++ /dev/null @@ -1,588 +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, - ); - - /** - * 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 ] = self::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 ) { - - 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 ); - } - } - } - } - - /** - * 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 strpos( $setting, 'network_' ) === 0; - } - - /** - * 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 (\'' . join( '\', \'', array_map( 'esc_sql', self::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', self::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 ('" . join( "', '", array_map( 'esc_sql', self::get_setting( 'taxonomies_blacklist' ) ) ) . "')"; - } - - /** - * 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 (\'' . join( '\', \'', array_map( 'esc_sql', self::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', self::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', self::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, self::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 (\'' . join( '\', \'', array_map( 'esc_sql', self::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', self::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 ! ( self::get_setting( 'disable' ) || self::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 || ( defined( 'REST_API_REQUEST' ) && 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) self::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) self::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) self::get_setting( 'dedicated_sync_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 613323fd..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-simple-codec.php +++ /dev/null @@ -1,63 +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 18d4ca21..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-callables.php +++ /dev/null @@ -1,646 +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. - } - - /** - * 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( 'libxml_use_internal_errors' ) || - ! 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', false ); - if ( ! empty( $plugins_lock ) && ( isset( $current_screeen->id ) && 'plugins' !== $current_screeen->id ) ) { - return; - } - $plugins = array_keys( Functions::get_plugins() ); - foreach ( $plugins as $plugin_file ) { - /** - * 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, null, '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, null, '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 ( ! empty( $action_links ) && count( $action_links ) > 0 ) { - $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->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 30268305..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-comments.php +++ /dev/null @@ -1,495 +0,0 @@ -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, 'only_allow_white_listed_comment_types' ) ); - 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 ); - } - } - - // 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' ); - - 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; - } - - /** - * 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() { - add_filter( 'jetpack_sync_before_send_wp_insert_comment', array( $this, 'expand_wp_insert_comment' ) ); - - 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_filter( - 'jetpack_sync_before_send_' . $comment_action_name, - array( - $this, - 'expand_wp_insert_comment', - ) - ); - } - } - - // Full sync. - 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 - $count = $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 serialized and sent to the server. - * - * @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, - ); - } -} 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 db0d9ff4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-constants.php +++ /dev/null @@ -1,339 +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 bee3e889..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,470 +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 ) ) { - $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'] ) { - $full_sync_config['users'] = Modules::get_module( 'users' )->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( $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. - * - * @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. - * - * @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. - */ - do_action( 'jetpack_full_sync_start', $full_sync_config, $range ); - $this->send_action( 'jetpack_full_sync_start', array( $full_sync_config, $range ) ); - - 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']; - - 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; - } - } - - $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(); - - return array_filter( - Modules::get_modules(), - /** - * Select configured and not finished modules. - * - * @return bool - * @var $module Module - */ - function ( $module ) use ( $status ) { - // Skip module if not configured for this sync or module is done. - if ( ! isset( $status['config'][ $module->name() ] ) ) { - return false; - } - if ( ! $status['config'][ $module->name() ] ) { - return false; - } - if ( isset( $status['progress'][ $module->name() ]['finished'] ) ) { - if ( true === $status['progress'][ $module->name() ]['finished'] ) { - return false; - } - } - - return true; - } - ); - } - - /** - * 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 90121e88..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-full-sync.php +++ /dev/null @@ -1,730 +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 ) { - $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. - * - * @var $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 839434dd..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 PHPCompatibility.FunctionUse.NewFunctionParameters.debug_backtrace_optionsFound,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 de293a9b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-meta.php +++ /dev/null @@ -1,112 +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 ) { - $table = _get_meta_table( $object_type ); - - if ( ! $table ) { - return array(); - } - - if ( ! is_array( $config ) ) { - return array(); - } - - $meta_objects = array(); - foreach ( $config as $item ) { - $meta = null; - if ( isset( $item['id'] ) && isset( $item['meta_key'] ) ) { - $meta = $this->get_object_by_id( $object_type, (int) $item['id'], (string) $item['meta_key'] ); - } - $meta_objects[ $item['id'] . '-' . $item['meta_key'] ] = $meta; - } - - return $meta_objects; - } - - /** - * Get a single Meta Result. - * - * @param string $object_type post, comment, term, user. - * @param null $id Object ID. - * @param 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 ); - $object_id_column = $object_type . '_id'; - - // Sanitize so that the array only has integer values. - $meta = $wpdb->get_results( - $wpdb->prepare( - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - "SELECT * FROM {$table} WHERE {$object_id_column} = %d AND meta_key = %s", - $id, - $meta_key - ), - ARRAY_A - ); - - $meta_objects = null; - - if ( ! is_wp_error( $meta ) && ! empty( $meta ) ) { - foreach ( $meta as $meta_entry ) { - if ( 'post' === $object_type && strlen( $meta_entry['meta_value'] ) >= Posts::MAX_POST_META_LENGTH ) { - $meta_entry['meta_value'] = ''; - } - $meta_objects[] = array( - 'meta_type' => $object_type, - 'meta_id' => $meta_entry['meta_id'], - 'meta_key' => $meta_key, - 'meta_value' => $meta_entry['meta_value'], - 'object_id' => $meta_entry[ $object_id_column ], - ); - } - } - - return $meta_objects; - } -} 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 a50cdd52..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-module.php +++ /dev/null @@ -1,604 +0,0 @@ -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 WordPress.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 - global $wpdb; - return $wpdb->get_col( - <<id_field()} -FROM {$wpdb->{$this->table_name()}} -WHERE {$this->get_where_sql( $config )} -AND {$this->id_field()} < {$status['last_sent']} -ORDER BY {$this->id_field()} -DESC LIMIT {$chunk_size} -SQL - ); - // phpcs:enable WordPress.DB.PreparedSQL.InterpolatedNotPrepared - } - - /** - * 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() ]; - - $chunks_sent = 0; - // phpcs:ignore WordPress.CodeAnalysis.AssignmentInCondition.FoundInWhileCondition - while ( $objects = $this->get_next_chunk( $config, $status, $limits['chunk_size'] ) ) { - if ( $chunks_sent++ === $limits['max_chunks'] || microtime( true ) >= $send_until ) { - return $status; - } - - $result = $this->send_action( 'jetpack_full_sync_' . $this->name(), array( $objects, $status['last_sent'] ) ); - - if ( is_wp_error( $result ) || $wpdb->last_error ) { - $status['error'] = true; - return $status; - } - // The $ids are ordered in descending order. - $status['last_sent'] = end( $objects ); - $status['sent'] += count( $objects ); - } - - if ( ! $wpdb->last_error ) { - $status['finished'] = true; - } - - 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. - */ - public function send_action( $action_name, $data = null ) { - $sender = Sender::get_instance(); - return $sender->send_action( $action_name, $data ); - } - - /** - * 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 ) { - global $wpdb; - - if ( ! $this->table_name() ) { - return false; - } - - $results = array(); - $table = $wpdb->{$this->table_name()}; - $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 = $wpdb->{$this->table_name()}; - $where = $this->get_where_sql( $config ); - - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - return $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'; - } - -} 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 defa700e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-network-options.php +++ /dev/null @@ -1,252 +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( $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 5c156512..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-options.php +++ /dev/null @@ -1,481 +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 ( 0 === strpos( $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 ( 'theme_mods_' === substr( $args[0], 0, 11 ) ) { - $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 ) || 'theme_mods_' === substr( $option, 0, 11 ); - } - - /** - * 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 ( 0 === strpos( $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 1ba86a28..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-plugins.php +++ /dev/null @@ -1,421 +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( 'admin_action_update', array( $this, 'check_plugin_edit' ) ); - add_action( 'jetpack_edited_plugin', $callable, 10, 2 ); - add_action( 'wp_ajax_edit-theme-plugin-file', array( $this, 'plugin_edit_ajax' ), 0 ); - } - - /** - * Initialize the module in the sender. - * - * @access public - */ - public function init_before_send() { - add_filter( 'jetpack_sync_before_send_activated_plugin', array( $this, 'expand_plugin_data' ) ); - add_filter( 'jetpack_sync_before_send_deactivated_plugin', array( $this, 'expand_plugin_data' ) ); - // 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. - } - - /** - * 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' ) ) { - $plugins = array( $upgrader->plugin_info() ); - } - - if ( empty( $plugins ) ) { - return; // We shouldn't be here. - } - - switch ( $details['action'] ) { - case 'update': - $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'], $state ); - } - - return; - } - /** - * 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', array_map( array( $this, 'get_plugin_info' ), $plugins ), $state ); - break; - case 'install': - } - - if ( 'install' === $details['action'] ) { - /** - * 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 ) ); - - return; - } - } - - /** - * 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 ) { - $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 edit in the administration. - * - * @access public - * - * @todo The `admin_action_update` hook is called only for logged in users, but maybe implement nonce verification? - */ - public function check_plugin_edit() { - $screen = get_current_screen(); - // phpcs:ignore WordPress.Security.NonceVerification.Missing - if ( 'plugin-editor' !== $screen->base || ! isset( $_POST['newcontent'] ) || ! isset( $_POST['plugin'] ) ) { - return; - } - - // phpcs:ignore WordPress.Security.NonceVerification.Missing, WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- Validated manually just after. - $plugin = wp_unslash( $_POST['plugin'] ); - $plugins = get_plugins(); - if ( ! isset( $plugins[ $plugin ] ) ) { - return; - } - - /** - * Helps Sync log that a plugin was edited - * - * @since 1.6.3 - * @since-jetpack 4.9.0 - * - * @param string $plugin, Plugin slug - * @param mixed $plugins[ $plugin ], Array of plugin data - */ - do_action( 'jetpack_edited_plugin', $plugin, $plugins[ $plugin ] ); - } - - /** - * 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(). - $args = wp_unslash( $_POST ); - if ( empty( $args['file'] ) ) { - return; - } - - $file = $args['file']; - if ( 0 !== validate_file( $file ) ) { - return; - } - - if ( ! isset( $args['newcontent'] ) ) { - return; - } - - if ( ! isset( $args['nonce'] ) ) { - return; - } - - if ( empty( $args['plugin'] ) ) { - return; - } - - $plugin = $args['plugin']; - if ( ! current_user_can( 'edit_plugins' ) ) { - return; - } - - if ( ! wp_verify_nonce( $args['nonce'], 'edit-plugin_' . $file ) ) { - 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_writeable - if ( ! is_writeable( $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, - ); - } -} 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 7b3b0e79..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-posts.php +++ /dev/null @@ -1,776 +0,0 @@ - length. - * Current Setting : 5MB. - * - * @access public - * - * @var int - */ - const MAX_POST_CONTENT_LENGTH = 5000000; - - /** - * Max bytes allowed for post meta_value => length. - * Current Setting : 2MB. - * - * @access public - * - * @var int - */ - const MAX_POST_META_LENGTH = 2000000; - - /** - * 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 in the database. - * - * @access public - * - * @return string - */ - public function table_name() { - return '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, 2 ); - 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 ); - add_filter( 'jetpack_sync_before_enqueue_jetpack_sync_save_post', array( $this, 'filter_blacklisted_post_types' ) ); - - // Listen for meta changes. - $this->init_listeners_for_meta_type( 'post', $callable ); - $this->init_meta_whitelist_handler( 'post', array( $this, 'filter_meta' ) ); - - 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() { - add_filter( 'jetpack_sync_before_send_jetpack_sync_save_post', array( $this, 'expand_jetpack_sync_save_post' ) ); - - // 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. - add_filter( 'jetpack_sync_before_send_jetpack_full_sync_posts', array( $this, 'expand_post_ids' ) ); - } - - /** - * 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 - $count = $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_POST_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_POST_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. - * - * @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 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 = $args[1]; - - if ( in_array( $post->post_type, Settings::get_setting( 'post_types_blacklist' ), true ) ) { - 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 ) || ( 0 === strpos( $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; - // 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; - - 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; - - 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 ) ); - - $post->post_content_filtered = apply_filters( 'the_content', $post->post_content ); - $post->post_excerpt_filtered = apply_filters( 'the_excerpt', $post->post_excerpt ); - - 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 ); - } - - return $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. - * - * @todo Implement nonce verification. - * - * @return boolean Whether this is a Gutenberg meta box update. - */ - public function is_gutenberg_meta_box_update() { - // phpcs:disable WordPress.Security.NonceVerification.Missing, WordPress.Security.NonceVerification.Recommended - 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 ) ) { - - // Refreshing the post in the cache site before triggering the publish event. - // The true parameter means that it's an update action, not create action. - $this->wp_insert_post( $post_ID, $post, 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 - */ - do_action( 'jetpack_published_post', $post_ID, $flags ); - } - 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 ); - } - } - } - } - - /** - * Expand post IDs to post objects 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_post_ids( $args ) { - list( $post_ids, $previous_interval_end) = $args; - - $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 array( - $posts, - $this->get_metadata( $post_ids, 'post', Settings::get_setting( 'post_meta_whitelist' ) ), - $this->get_term_relationships( $post_ids ), - $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 ) ); - } -} 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 f82843f3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-protect.php +++ /dev/null @@ -1,52 +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(), - '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 ), - '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(), - '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 ), - 'session_transcript' => array(), - 'settings' => array(), - 'sex' => array(), - 'shares_count' => array(), - 'show_description' => array( 'searchable_in_all_content' => true ), - 'show_page_title' => 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', - - ); // end taxonomies. - - /** - * List of options to sync - * - * @access private - * @static - * - * @var array - */ - private static $options_to_sync = array( - '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, $this->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, $this->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 @@ - 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. - $objects_count = count( $objects ); - if ( ! count( $objects ) ) { - return array( $items_enqueued_count, true ); - } - $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 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", - $status['last_sent']['object_id'], - $status['last_sent']['term_taxonomy_id'], - $status['last_sent']['object_id'], - $chunk_size - ), - 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:disable WordPress.DB.PreparedSQL.NotPrepared - $count = $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 6bc8c064..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-terms.php +++ /dev/null @@ -1,314 +0,0 @@ -get_error_code() === 'invalid_taxonomy' ) { - // Fetch raw term. - $columns = implode( ', ', array_unique( array_merge( Defaults::$default_term_checksum_columns, array( 'term_group' ) ) ) ); - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $object = $wpdb->get_row( $wpdb->prepare( "SELECT $columns FROM $wpdb->terms WHERE term_id = %d", $id ) ); - } - } - - if ( 'term_taxonomy' === $object_type ) { - $columns = implode( ', ', array_unique( array_merge( Defaults::$default_term_taxonomy_checksum_columns, array( 'description' ) ) ) ); - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $object = $wpdb->get_row( $wpdb->prepare( "SELECT $columns FROM $wpdb->term_taxonomy WHERE term_taxonomy_id = %d", $id ) ); - } - - if ( 'term_relationships' === $object_type ) { - $columns = implode( ', ', Defaults::$default_term_relationships_checksum_columns ); - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $objects = $wpdb->get_results( $wpdb->prepare( "SELECT $columns FROM $wpdb->term_relationships WHERE object_id = %d", $id ) ); - $object = (object) array( - 'object_id' => $id, - 'relationships' => array_map( array( $this, 'expand_terms_for_relationship' ), $objects ), - ); - } - - return $object ? $object : false; - } - - /** - * 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:disable WordPress.DB.PreparedSQL.NotPrepared - $count = $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 where the terms have not changed. - * - * @param array $args Hook args. - * @return array|boolean False if no change in terms, the original hook args otherwise. - */ - public function filter_set_object_terms_no_update( $args ) { - // 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 - * - * @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 ) { - return get_term_by( 'term_taxonomy_id', $relationship->term_taxonomy_id ); - } - -} 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 7218e55d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-themes.php +++ /dev/null @@ -1,876 +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 ); - - if ( count( $old_value ) > count( $value ) ) { - - // 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'] ) || - ! 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() { - $args = wp_unslash( $_POST ); - - if ( empty( $args['theme'] ) ) { - return; - } - - if ( empty( $args['file'] ) ) { - return; - } - $file = $args['file']; - if ( 0 !== validate_file( $file ) ) { - return; - } - - if ( ! isset( $args['newcontent'] ) ) { - return; - } - - if ( ! isset( $args['nonce'] ) ) { - return; - } - - $stylesheet = $args['theme']; - 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( $args['nonce'], 'edit-theme_' . $stylesheet . '_' . $file ) ) { - 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_writeable - if ( ! is_writeable( $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'] ) { - $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 5557bab4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-updates.php +++ /dev/null @@ -1,583 +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_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 - ); - - add_action( 'automatic_updates_complete', $callable ); - - 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' ) ); - add_filter( 'jetpack_sync_before_send_jetpack_update_themes_change', array( $this, 'expand_themes' ) ); - } - - /** - * 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], $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 1bc9961a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-users.php +++ /dev/null @@ -1,903 +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 in the database. - * - * @access public - * - * @return string - */ - public function table_name() { - return '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, 'save_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, 'save_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, 0 ); - 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' ) ); - } - - /** - * 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() { - add_filter( 'jetpack_sync_before_send_jetpack_wp_login', array( $this, 'expand_login_username' ), 10, 1 ); - add_filter( 'jetpack_sync_before_send_wp_logout', array( $this, 'expand_logout_username' ), 10, 2 ); - - // 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 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 being sent to the server. - * - * @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 being sent to the server. - * - * @access public - * - * @param array $args The hook arguments. - * @param int $user_id ID of the user. - * @return array $args Expanded hook arguments. - */ - public function expand_logout_username( $args, $user_id ) { - $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 send 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 ( $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 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 - $count = $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 ) ); - - if ( count( $user_ids ) <= 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 ); - - // Do check in constant O(1) time for PHP5.5+. - if ( function_exists( 'array_column' ) ) { - $backtrace_functions = array_column( $backtrace, 'function' ); // phpcs:ignore PHPCompatibility.FunctionUse.NewFunctions.array_columnFound - $backtrace_functions_as_keys = array_flip( $backtrace_functions ); - $intersection = array_intersect_key( $backtrace_functions_as_keys, $names_as_keys ); - return ! empty( $intersection ); - } - - // Do check in linear O(n) time for < PHP5.5 ( using isset at least prevents O(n^2) ). - foreach ( $backtrace as $call ) { - if ( isset( $names_as_keys[ $call['function'] ] ) ) { - return true; - } - } - return false; - } -} 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 c8aa26ae..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-woocommerce.php +++ /dev/null @@ -1,614 +0,0 @@ -order_item_table_name; - } - - /** - * 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 ); - } - - /** - * 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 ); - $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, 'expand_order_item_ids' ) ); - } - - /** - * 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; - } - - /** - * 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. - */ - public function expand_order_item_ids( $args ) { - $order_item_ids = $args[0]; - - global $wpdb; - - $order_item_ids_sql = implode( ', ', array_map( 'intval', $order_item_ids ) ); - - $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 - $count = $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 - */ - private 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', - '_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', - - // 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. - * - * @access public - * - * @return array|object|null - */ - public function get_order_item_by_ids( $ids ) { - 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 )"; - - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - return $wpdb->get_results( $wpdb->prepare( $query, $ids ), ARRAY_A ); - } -} 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 20f686a6..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,208 +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' ); - // 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 c38ed840..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,184 +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 5826911c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum.php +++ /dev/null @@ -1,856 +0,0 @@ -salt = $salt; - - $this->default_tables = $this->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 ); - - // 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 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' => array( $this, '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' => array( $this, 'enable_woocommerce_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' ); - }, - ), - ); - } - - /** - * 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': - $values_placeholders = implode( ',', array_fill( 0, count( $filter['values'] ), '%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 ( '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 ( '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 - */ - protected 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; - } - - // No need to proceed if WooCommerce is not available. - if ( ! class_exists( 'WooCommerce' ) ) { - return false; - } - - // TODO more checks if needed. Probably query the DB to make sure the tables exist. - - return true; - } - -} 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 d21fdb0a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/CHANGELOG.md +++ /dev/null @@ -1,35 +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.1.4] - 2023-03-07 -### Changed -- Updated package dependencies. - -## [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.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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 96ffd1af..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\\Transport_Helper\\Helper_Script_Manager', 'cleanup_expired_helper_scripts' ) ); - -// Register REST routes. -$add_action( 'rest_api_init', array( 'Automattic\\Jetpack\\Transport_Helper\\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 a55c9e17..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/composer.json +++ /dev/null @@ -1,55 +0,0 @@ -{ - "name": "automattic/jetpack-transport-helper", - "description": "Package to help transport server communication", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "automattic/jetpack-connection": "^1.51.1" - }, - "require-dev": { - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/wordbless": "dev-master" - }, - "autoload": { - "files": [ - "actions.php" - ], - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "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!'", - "post-install-cmd": "WorDBless\\Composer\\InstallDropin::copy", - "post-update-cmd": "WorDBless\\Composer\\InstallDropin::copy" - }, - "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.1.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-helper-script-manager.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/src/class-helper-script-manager.php deleted file mode 100644 index 3d17f2f3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/src/class-helper-script-manager.php +++ /dev/null @@ -1,383 +0,0 @@ - self::MAX_FILESIZE ) { - return new \WP_Error( 'invalid_helper', 'Invalid Helper Script size' ); - } - - // Replace '[wp_path]' in the Helper Script with the WordPress installation location. Allows the Helper Script to find WordPress. - $script_body = str_replace( '[wp_path]', addslashes( ABSPATH ), $script_body ); - - $wp_filesystem = self::get_wp_filesystem(); - if ( ! $wp_filesystem ) { - return new \WP_Error( 'install_failed', 'Failed to install Helper Script' ); - } - - // Create a jetpack-temp directory for the Helper Script. - $temp_directory = self::create_temp_directory(); - if ( \is_wp_error( $temp_directory ) ) { - return $temp_directory; - } - - // Generate a random filename, avoid clashes. - $max_attempts = 5; - for ( $attempt = 0; $attempt < $max_attempts; $attempt++ ) { - $file_key = wp_generate_password( 10, false ); - $file_name = 'jp-helper-' . $file_key . '.php'; - $file_path = trailingslashit( $temp_directory['path'] ) . $file_name; - - if ( ! $wp_filesystem->exists( $file_path ) ) { - // Attempt to write helper script. - if ( ! self::put_contents( $file_path, $script_body ) ) { - if ( $wp_filesystem->exists( $file_path ) ) { - $wp_filesystem->delete( $file_path ); - } - - continue; - } - - // Always schedule a cleanup run shortly after EXPIRY_TIME. - \wp_schedule_single_event( time() + self::EXPIRY_TIME + 60, 'jetpack_cleanup_helper_scripts' ); - - // Success! Figure out the URL and return the path and URL. - return array( - 'path' => $file_path, - 'url' => trailingslashit( $temp_directory['url'] ) . $file_name, - ); - } - } - - return new \WP_Error( 'install_faied', 'Failed to install Helper Script' ); - } - - /** - * Given a path, verify it looks like a helper script and then delete it if so. - * - * @access public - * @static - * - * @param string $path Path to Helper Script to delete. - * @return boolean True if the file is deleted (or does not exist). - */ - public static function delete_helper_script( $path ) { - $wp_filesystem = self::get_wp_filesystem(); - if ( ! $wp_filesystem ) { - return false; - } - - if ( ! $wp_filesystem->exists( $path ) ) { - return true; - } - - // Check this file looks like a JPR helper script. - if ( ! self::verify_file_header( $path, self::HELPER_HEADER ) ) { - return false; - } - - return $wp_filesystem->delete( $path ); - } - - /** - * Search for Helper Scripts that are suspiciously old, and clean them out. - * - * @access public - * @static - */ - public static function cleanup_expired_helper_scripts() { - self::cleanup_helper_scripts( time() - self::EXPIRY_TIME ); - } - - /** - * Search for and delete all Helper Scripts. Used during uninstallation. - * - * @access public - * @static - */ - public static function delete_all_helper_scripts() { - self::cleanup_helper_scripts( null ); - } - - /** - * Search for and delete Helper Scripts. If an $expiry_time is specified, only delete Helper Scripts - * with an mtime older than $expiry_time. Otherwise, delete them all. - * - * @access public - * @static - * - * @param int|null $expiry_time If specified, only delete scripts older than $expiry_time. - */ - public static function cleanup_helper_scripts( $expiry_time = null ) { - $wp_filesystem = self::get_wp_filesystem(); - if ( ! $wp_filesystem ) { - return; - } - - foreach ( self::get_install_locations() as $directory => $url ) { - $temp_dir = trailingslashit( $directory ) . self::TEMP_DIRECTORY; - - if ( $wp_filesystem->is_dir( $temp_dir ) ) { - // Find expired helper scripts and delete them. - $helper_scripts = $wp_filesystem->dirlist( $temp_dir ); - if ( is_array( $helper_scripts ) ) { - foreach ( $helper_scripts as $entry ) { - if ( preg_match( '/^jp-helper-*\.php$/', $entry['name'] ) && ( null === $expiry_time || $entry['lastmodunix'] < $expiry_time ) ) { - self::delete_helper_script( trailingslashit( $temp_dir ) . $entry['name'] ); - } - } - } - - // Delete the directory if it's empty now. - self::delete_empty_helper_directory( $temp_dir ); - } - } - } - - /** - * Delete a helper script directory if it's empty - * - * @access public - * @static - * - * @param string $dir Path to Helper Script directory. - * @return boolean True if the directory is deleted - */ - private static function delete_empty_helper_directory( $dir ) { - $wp_filesystem = self::get_wp_filesystem(); - if ( ! $wp_filesystem ) { - return false; - } - - if ( ! $wp_filesystem->is_dir( $dir ) ) { - return false; - } - - // Tally the files in the target directory, and reject if there are too many. - $dir_contents = $wp_filesystem->dirlist( $dir ); - if ( $dir_contents === false || count( $dir_contents ) > 2 ) { - return false; - } - - // Check that the only remaining files are a README and index.php generated by this system. - $allowed_files = array( - 'README' => self::README_LINES[0], - 'index.php' => self::INDEX_FILE, - ); - - foreach ( $dir_contents as $entry ) { - $basename = $entry['name']; - $path = trailingslashit( $dir ) . $basename; - if ( ! isset( $allowed_files[ $basename ] ) ) { - return false; - } - - // Verify the file starts with the expected contents. - if ( ! self::verify_file_header( $path, $allowed_files[ $basename ] ) ) { - return false; - } - - if ( ! $wp_filesystem->delete( $path ) ) { - return false; - } - } - - // If the directory is now empty, delete it. - $dir_contents = $wp_filesystem->dirlist( $dir ); - if ( $dir_contents === false || count( $dir_contents ) === 0 ) { - return $wp_filesystem->rmdir( $dir ); - } - - return false; - } - - /** - * Find an appropriate location for a jetpack-temp folder, and create one - * - * @access public - * @static - * - * @return WP_Error|array Array containing the url and path of the temp directory if successful, WP_Error if not. - */ - private static function create_temp_directory() { - $wp_filesystem = self::get_wp_filesystem(); - if ( ! $wp_filesystem ) { - return new \WP_Error( 'temp_directory', 'Failed to create jetpack-temp directory' ); - } - - foreach ( self::get_install_locations() as $directory => $url ) { - // Check if the install location is writeable. - if ( ! $wp_filesystem->is_writable( $directory ) ) { - continue; - } - - // Create if one doesn't already exist. - $temp_dir = trailingslashit( $directory ) . self::TEMP_DIRECTORY; - if ( ! $wp_filesystem->is_dir( $temp_dir ) ) { - if ( ! $wp_filesystem->mkdir( $temp_dir ) ) { - continue; - } - - // Temp directory created. Drop a README and index.php file in there. - self::write_supplementary_temp_files( $temp_dir ); - } - - return array( - 'path' => trailingslashit( $directory ) . self::TEMP_DIRECTORY, - 'url' => trailingslashit( $url ) . self::TEMP_DIRECTORY, - ); - } - - return new \WP_Error( 'temp_directory', 'Failed to create jetpack-temp directory' ); - } - - /** - * Write out an index.php file and a README file for a new jetpack-temp directory. - * - * @access public - * @static - * - * @param string $dir Path to Helper Script directory. - */ - private static function write_supplementary_temp_files( $dir ) { - $readme_path = trailingslashit( $dir ) . 'README'; - self::put_contents( $readme_path, implode( "\n\n", self::README_LINES ) ); - - $index_path = trailingslashit( $dir ) . 'index.php'; - self::put_contents( $index_path, self::INDEX_FILE ); - } - - /** - * Write a file to the specified location with the specified contents. - * - * @access private - * @static - * - * @param string $file_path Path to write to. - * @param string $contents File contents to write. - * @return boolean True if successfully written. - */ - private static function put_contents( $file_path, $contents ) { - $wp_filesystem = self::get_wp_filesystem(); - if ( ! $wp_filesystem ) { - return false; - } - - return $wp_filesystem->put_contents( $file_path, $contents ); - } - - /** - * Checks that a file exists, is readable, and has the expected header. - * - * @access private - * @static - * - * @param string $file_path File to verify. - * @param string $expected_header Header that the file should have. - * @return boolean True if the file exists, is readable, and the header matches. - */ - private static function verify_file_header( $file_path, $expected_header ) { - $wp_filesystem = self::get_wp_filesystem(); - if ( ! $wp_filesystem ) { - return false; - } - - // Verify the file exists and is readable. - if ( ! $wp_filesystem->exists( $file_path ) || ! $wp_filesystem->is_readable( $file_path ) ) { - return false; - } - - // Verify that the file isn't too big or small. - $file_size = $wp_filesystem->size( $file_path ); - if ( $file_size < strlen( $expected_header ) || $file_size > self::MAX_FILESIZE ) { - return false; - } - - // Read the file and verify its header. - $contents = $wp_filesystem->get_contents( $file_path ); - return ( strncmp( $contents, $expected_header, strlen( $expected_header ) ) === 0 ); - } - - /** - * Gets an associative array of possible places to install a jetpack-temp directory, along with the URL to access each. - * - * @access private - * @static - * - * @return array Array, with keys specifying the full path of install locations, and values with the equivalent URL. - */ - public static function get_install_locations() { - // Include WordPress root and wp-content. - $install_locations = array( - \ABSPATH => \get_site_url(), - \WP_CONTENT_DIR => \WP_CONTENT_URL, - ); - - // Include uploads folder. - $upload_dir_info = \wp_upload_dir(); - $install_locations[ $upload_dir_info['basedir'] ] = $upload_dir_info['baseurl']; - - return $install_locations; - } - - /** - * Get the WP_Filesystem. - * - * @return \WP_Filesystem|null - */ - private static function get_wp_filesystem() { - global $wp_filesystem; - - if ( ! $wp_filesystem ) { - if ( ! function_exists( '\\WP_Filesystem' ) ) { - require_once ABSPATH . 'wp-admin/includes/file.php'; - } - - if ( ! \WP_Filesystem() ) { - return null; - } - } - - return $wp_filesystem; - } - -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/src/class-package-version.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/src/class-package-version.php deleted file mode 100644 index 0c82368c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/src/class-package-version.php +++ /dev/null @@ -1,31 +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 Returns the result of Helper Script installation. Returns one of: - * - WP_Error on failure, or - * - An array with installation info on success: - * 'path' (string) The sinstallation path. - * 'url' (string) The access url. - * 'abspath' (string) The abspath. - */ - 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(); - - // Include ABSPATH with successful result. - if ( ! is_wp_error( $installation_info ) ) { - $installation_info['abspath'] = ABSPATH; - } - - 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 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' ); - - $deleted = Helper_Script_Manager::delete_helper_script( $path_to_helper_script ); - Helper_Script_Manager::cleanup_expired_helper_scripts(); - - return rest_ensure_response( - array( - 'success' => $deleted, - ) - ); - } - -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/.phpcsignore b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/.phpcsignore deleted file mode 100644 index 9f4f5a0b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/.phpcsignore +++ /dev/null @@ -1 +0,0 @@ -rules/ 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 46c674f2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/CHANGELOG.md +++ /dev/null @@ -1,231 +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.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.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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 c62c43f9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/cli.php +++ /dev/null @@ -1,12 +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 string $user - the user. - */ - public function check_valid_blocked_user( $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'], $_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' ), $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. - */ - 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 ) { - $range = false; - if ( strpos( $ip_address, '-' ) ) { - $ip_address = explode( '-', $ip_address ); - $range = true; - } - $new_item = new \stdClass(); - $new_item->range = $range; - if ( $range ) { - $new_item->range_low = trim( $ip_address[0] ); - $new_item->range_high = trim( $ip_address[1] ); - } else { - $new_item->ip_address = $ip_address; - } - return $new_item; - } - - /** - * 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 a028290f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-brute-force-protection.php +++ /dev/null @@ -1,1134 +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 ( new Modules() )->activate( 'protect', false, false ); - } - - /** - * Disables the brute force protection module. - * - * @return bool - */ - public static function disable() { - 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'; - } - - if ( ! is_plugin_active_for_network( plugin_basename( JETPACK__PLUGIN_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; - } - - /** - * 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 = 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'], $_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 f20c619e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-compatibility.php +++ /dev/null @@ -1,228 +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, 1 ); - } - - 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, 1 ); - } - - 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', '<' ); - } - -} 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 9c0ca1f4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-rest-controller.php +++ /dev/null @@ -1,165 +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', - ) - ); - } - - /** - * 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( Waf_Runner::get_config() ); - } - - /** - * 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, (bool) $request->get_param( Waf_Rules_Manager::AUTOMATIC_RULES_ENABLED_OPTION_NAME ) ); - } - - // IP Lists Enabled - if ( isset( $request[ Waf_Rules_Manager::IP_LISTS_ENABLED_OPTION_NAME ] ) ) { - update_option( Waf_Rules_Manager::IP_LISTS_ENABLED_OPTION_NAME, (bool) $request->get_param( Waf_Rules_Manager::IP_LISTS_ENABLED_OPTION_NAME ) ); - } - - // 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 ] ); - } - - // 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 ] ); - } - - // Share Data - if ( isset( $request[ Waf_Runner::SHARE_DATA_OPTION_NAME ] ) ) { - update_option( Waf_Runner::SHARE_DATA_OPTION_NAME, (bool) $request[ Waf_Runner::SHARE_DATA_OPTION_NAME ] ); - } - - // 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 ) - ); - } - } - - 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-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 70217b1e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-cli.php +++ /dev/null @@ -1,166 +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_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( Waf_Rules_Manager::RULES_ENTRYPOINT_FILE ) - ) - ); - } -} 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 ed82ce6a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-constants.php +++ /dev/null @@ -1,104 +0,0 @@ -is_atomic_platform(); - define( 'DISABLE_JETPACK_WAF', $is_wpcom || $is_atomic ); - } - } - - /** - * 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 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 = get_option( Waf_Runner::SHARE_DATA_OPTION_NAME, false ); - define( 'JETPACK_WAF_SHARE_DATA', $share_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 9608dc41..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-initializer.php +++ /dev/null @@ -1,188 +0,0 @@ -generate(); - } catch ( Waf_Exception $e ) { - return $e->get_wp_error(); - } - - $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_deactivation() { - try { - Waf_Runner::deactivate(); - } catch ( Waf_Exception $e ) { - return $e->get_wp_error(); - } - - $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, 1 ); - } - - /** - * 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_waf_update() { - if ( get_option( self::NEEDS_UPDATE_OPTION_NAME ) ) { - // 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(); - - Waf_Constants::define_mode(); - if ( ! Waf_Runner::is_allowed_mode( JETPACK_WAF_MODE ) ) { - return new WP_Error( 'waf_mode_invalid', 'Invalid firewall mode.' ); - } - - 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(); - } - } - - update_option( self::NEEDS_UPDATE_OPTION_NAME, 0 ); - return true; - } - - /** - * Disables the WAF module when on an supported platform. - * - * @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; - } -} 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 4f111c79..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 stripos( $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 9d55d479..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-request.php +++ /dev/null @@ -1,329 +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; - } - - /** - * 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 = substr( $uri, 0, strpos( $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'] ) && 'on' === $_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 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 - */ - public function get_cookies() { - return flatten_array( $_COOKIE ); - } - - /** - * Returns the GET variables - * - * @return array - */ - public function get_get_vars() { - return flatten_array( $_GET ); - } - - /** - * Returns the POST variables - * - * @return array - */ - public function get_post_vars() { - return flatten_array( $_POST ); - } - - /** - * 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 2c9f8901..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-rules-manager.php +++ /dev/null @@ -1,323 +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() { - Waf_Constants::define_mode(); - if ( ! Waf_Runner::is_allowed_mode( JETPACK_WAF_MODE ) ) { - throw new Waf_Exception( 'Invalid firewall mode.' ); - } - $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(); - - $rules = "is_dir( dirname( $entrypoint_file_path ) ) ) { - $wp_filesystem->mkdir( dirname( $entrypoint_file_path ) ); - } - - // Ensure all potentially required rule files exist - $rule_files = array( self::RULES_ENTRYPOINT_FILE, 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 ( get_option( self::AUTOMATIC_RULES_ENABLED_OPTION_NAME ) ) { - $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_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 => get_option( Waf_Rules_Manager::AUTOMATIC_RULES_ENABLED_OPTION_NAME ), - Waf_Rules_Manager::IP_LISTS_ENABLED_OPTION_NAME => get_option( Waf_Rules_Manager::IP_LISTS_ENABLED_OPTION_NAME ), - Waf_Rules_Manager::IP_ALLOW_LIST_OPTION_NAME => get_option( Waf_Rules_Manager::IP_ALLOW_LIST_OPTION_NAME ), - Waf_Rules_Manager::IP_BLOCK_LIST_OPTION_NAME => get_option( Waf_Rules_Manager::IP_BLOCK_LIST_OPTION_NAME ), - self::SHARE_DATA_OPTION_NAME => get_option( self::SHARE_DATA_OPTION_NAME ), - 'bootstrap_path' => self::get_bootstrap_file_path(), - 'automatic_rules_available' => (bool) self::automatic_rules_available(), - 'brute_force_protection' => (bool) Brute_Force_Protection::is_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 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' ); - // phpcs:ignore - ini_set( 'display_errors', 'Off' ); - // phpcs:ignore - set_error_handler( array( self::class, 'errorHandler' ) ); - - try { - - // phpcs:ignore - $waf = new Waf_Runtime( new Waf_Transforms(), new Waf_Operators() ); - - // execute waf rules. - $rules_file_path = self::get_waf_file_path( Waf_Rules_Manager::RULES_ENTRYPOINT_FILE ); - 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(); - // phpcs:ignore - ini_set( 'display_errors', $display_errors ); - } - - /** - * 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() { - Waf_Constants::define_mode(); - if ( ! self::is_allowed_mode( JETPACK_WAF_MODE ) ) { - throw new Waf_Exception( 'Invalid firewall mode.' ); - } - - $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(); - - self::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 ); - } - } - } - - /** - * 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 ); - } - - /** - * 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(); - - // If the rules file doesn't exist, there's nothing else to do. - if ( ! $wp_filesystem->exists( self::get_waf_file_path( Waf_Rules_Manager::RULES_ENTRYPOINT_FILE ) ) ) { - return; - } - - // Empty the rules entrypoint file. - if ( ! $wp_filesystem->put_contents( self::get_waf_file_path( Waf_Rules_Manager::RULES_ENTRYPOINT_FILE ), "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 || " - */ -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; - - /** - * 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 = ''; - - /** - * 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'] ); - } - } - - // 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 ); - } - - $this->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" ); - } - } - - /** - * Write block logs. We won't write to the file if it exceeds 100 mb. - * - * @param string $rule_id Rule id. - * @param string $reason Block reason. - */ - public 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' ); - - 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 ); - } - } - } - } - - $this->write_blocklog_row( $log_data ); - } - - /** - * Write block logs to database. - * - * @param array $log_data Log data. - */ - private function write_blocklog_row( $log_data ) { - $conn = $this->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" ); - } - } - } - - /** - * Connect to WordPress database. - */ - private function connect_to_wordpress_db() { - if ( ! file_exists( JETPACK_WAF_WPCONFIG ) ) { - return; - } - - require_once JETPACK_WAF_WPCONFIG; - $conn = new \mysqli( DB_HOST, DB_USER, DB_PASSWORD, DB_NAME ); // phpcs:ignore WordPress.DB.RestrictedClasses.mysql__mysqli - - if ( $conn->connect_error ) { - error_log( 'Could not connect to the database:' . $conn->connect_error ); - return null; - } - - return $conn; - } - - /** - * Redirect. - * - * @param string $rule_id Rule id. - * @param string $url Url. - */ - public function redirect( $rule_id, $url ) { - error_log( "Jetpack WAF Redirected Request.\tRule:$rule_id\t$url" ); - header( "Location: $url" ); - exit; - } - - /** - * 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 = basename( $this->request->get_filename() ); - 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(); - 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; - } - - /** - * 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; - } - $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. - $range = 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 597e3168..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-standalone-bootstrap.php +++ /dev/null @@ -1,172 +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( dirname( dirname( dirname( dirname( $class_file ) ) ) ) ) . '/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( dirname( dirname( $package_file ) ) ) . '/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( dirname( dirname( dirname( __DIR__ ) ) ) ) . '/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'; - } - - /** - * 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(); - $mode_option = get_option( Waf_Runner::MODE_OPTION_NAME, false ); - $share_data_option = get_option( Waf_Runner::SHARE_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 a0bc7bae..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-stats.php +++ /dev/null @@ -1,68 +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 ); - } - - /** - * 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 ); - } - - /** - * 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 ); - } - - /** - * Convert utf-8 characters to unicode characters - * - * @param string $value value to be encoded. - * @return string - */ - public function utf8_to_unicode( $value ) { - return preg_replace( '/\\\u(?=[a-f0-9]{4})/', '%u', substr( json_encode( $value ), 1, -1 ) ); - } -} 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 ba59b986..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,24 +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 554f1053..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/functions.php +++ /dev/null @@ -1,70 +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. - * @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 = '' ) { - $return = array(); - foreach ( $array as $source_key => $source_value ) { - $key = ( '' === $key_prefix ) - // if this is the first level, the key name isn't enclosed in brackets - ? $source_key - // for every level after the first, enclose the key name in brackets. - : $key_prefix . '[' . $source_key . ']'; - if ( ! is_array( $source_value ) ) { - $return[] = array( $key, $source_value ); - } else { - $return = array_merge( $return, flatten_array( $source_value, $key ) ); - } - } - return $return; -} 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 747eb6dd..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/i18n-map.php +++ /dev/null @@ -1,64 +0,0 @@ - 'jetpack-protect', - 'type' => 'plugins', - 'packages' => array( - 'jetpack-admin-ui' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-admin-ui', - 'ver' => '0.2.19', - ), - 'jetpack-assets' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-assets', - 'ver' => '1.17.34', - ), - 'jetpack-config' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-config', - 'ver' => '1.15.1', - ), - 'jetpack-connection' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-connection', - 'ver' => '1.51.7', - ), - 'jetpack-idc' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-identity-crisis', - 'ver' => '0.8.40', - ), - 'jetpack-ip' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-ip', - 'ver' => '0.1.2', - ), - 'jetpack-jitm' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-jitm', - 'ver' => '2.3.4', - ), - 'jetpack-licensing' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-licensing', - 'ver' => '1.8.2', - ), - 'jetpack-my-jetpack' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-my-jetpack', - 'ver' => '2.9.1', - ), - 'jetpack-password-checker' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-password-checker', - 'ver' => '0.2.13', - ), - 'jetpack-plugins-installer' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-plugins-installer', - 'ver' => '0.2.3', - ), - 'jetpack-sync' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-sync', - 'ver' => '1.47.4', - ), - 'jetpack-transport-helper' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-transport-helper', - 'ver' => '0.1.4', - ), - 'jetpack-waf' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-waf', - 'ver' => '0.11.4', - ), - ), -); 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 8b9e6574..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/readme.txt +++ /dev/null @@ -1,169 +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.0 -Requires PHP: 5.6 -Tested up to: 6.2 -Stable tag: 1.4.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/) - -== 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 38,393 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 (38,393) 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 == -### 1.4.0 - 2023-05-05 -#### Added -- Add brute force protection. - -#### Changed -- General: indicate full compatibility with the latest version of WordPress, 6.2. -- Improve the firewall status heading to provide more information based on the current configuration. -- Updated package dependencies. - 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 dc80e624..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-credentials.php +++ /dev/null @@ -1,56 +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 05a86825..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-jetpack-protect.php +++ /dev/null @@ -1,452 +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' ), - 99 - ); - - 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. - wp_add_inline_script( 'jetpack-protect', Connection_Initial_State::render(), 'before' ); - 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; - // phpcs:disable WordPress.Security.NonceVerification.Recommended - $refresh_status_from_wpcom = isset( $_GET['checkPlan'] ); - $initial_state = array( - 'apiRoot' => esc_url_raw( rest_url() ), - 'apiNonce' => wp_create_nonce( 'wp_rest' ), - 'registrationNonce' => wp_create_nonce( 'jetpack-registration-nonce' ), - 'status' => Status::get_status( $refresh_status_from_wpcom ), - '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(), - 'jetpackScan' => My_Jetpack_Products::get_product( 'scan' ), - 'hasRequiredPlan' => Plan::has_required_plan(), - 'waf' => array( - 'isSupported' => Waf_Runner::is_supported_environment(), - 'isSeen' => self::get_waf_seen_status(), - 'upgradeIsSeen' => self::get_waf_upgrade_seen_status(), - 'displayUpgradeBadge' => self::get_waf_upgrade_badge_display_status(), - 'isEnabled' => Waf_Runner::is_enabled(), - 'isToggling' => false, - 'isUpdating' => false, - 'config' => Waf_Runner::get_config(), - 'stats' => self::get_waf_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(); - - Status::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 for user licenses. - * - * @param boolean $has_license Check if user has a license. - * @param object $licenses List of licenses. - * @param string $plugin_slug 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 ( in_array( $license->product_id, self::JETPACK_SCAN_PRODUCT_IDS, true ) ) { - $license_found = true; - break; - } - } - - return $license_found; - } - - /** - * Get WAF "Seen" Status - * - * @return bool Whether the current user has viewed the WAF screen. - */ - public static function get_waf_seen_status() { - return (bool) get_user_meta( get_current_user_id(), 'jetpack_protect_waf_seen', true ); - } - - /** - * Set WAF "Seen" Status - * - * @return bool True if seen status updated to true, false on failure. - */ - public static function set_waf_seen_status() { - return (bool) update_user_meta( get_current_user_id(), 'jetpack_protect_waf_seen', true ); - } - - /** - * 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( - 'ipAllowListCount' => Waf_Stats::get_ip_allow_list_count(), - 'ipBlockListCount' => Waf_Stats::get_ip_block_list_count(), - 'rulesVersion' => Waf_Stats::get_rules_version(), - 'automaticRulesLastUpdated' => Waf_Stats::get_automatic_rules_last_updated(), - ); - } - -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-plan.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-plan.php deleted file mode 100644 index 936f2885..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/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' ), - 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', true ); - $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/src/class-protect-status.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-protect-status.php deleted file mode 100644 index 060fa2d5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-protect-status.php +++ /dev/null @@ -1,259 +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' ), - 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. - * - * @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; - - // merge plugins from report with all installed plugins before mapping into the Status_Model - $installed_plugins = Plugins_Installer::get_plugins(); - $last_report_plugins = isset( $report_data->plugins ) ? $report_data->plugins : new \stdClass(); - $status->plugins = self::merge_installed_and_checked_lists( $installed_plugins, $last_report_plugins, array( 'type' => 'plugins' ) ); - - // merge themes from report with all installed plugins before mapping into the Status_Model - $installed_themes = Sync_Functions::get_themes(); - $last_report_themes = isset( $report_data->themes ) ? $report_data->themes : new \stdClass(); - $status->themes = self::merge_installed_and_checked_lists( $installed_themes, $last_report_themes, array( 'type' => 'themes' ) ); - - // normalize WordPress core report data and map into Status_Model - $status->core = self::normalize_core_information( isset( $report_data->core ) ? $report_data->core : new \stdClass() ); - - // check if any installed items (themes, plugins, or core) have not been checked in the report - $all_items = array_merge( $status->plugins, $status->themes, array( $status->core ) ); - $unchecked_items = array_filter( - $all_items, - function ( $item ) { - return ! isset( $item->checked ) || ! $item->checked; - } - ); - $status->has_unchecked_items = ! empty( $unchecked_items ); - - return $status; - } - - /** - * Merges the list of installed extensions with the list of extensions that were checked for known vulnerabilities and return a normalized list to be used in the UI - * - * @param array $installed The list of installed extensions, where each attribute key is the extension slug. - * @param object $checked The list of checked extensions. - * @param array $append Additional data to append to each result in the list. - * @return array Normalized list of extensions. - */ - protected static function merge_installed_and_checked_lists( $installed, $checked, $append ) { - $new_list = array(); - foreach ( array_keys( $installed ) as $slug ) { - - $checked = (object) $checked; - - $extension = new Extension_Model( - array_merge( - array( - 'name' => $installed[ $slug ]['Name'], - 'version' => $installed[ $slug ]['Version'], - 'slug' => $slug, - 'threats' => array(), - 'checked' => false, - ), - $append - ) - ); - - if ( isset( $checked->{ $slug } ) && $checked->{ $slug }->version === $installed[ $slug ]['Version'] ) { - $extension->version = $checked->{ $slug }->version; - $extension->checked = true; - - if ( is_array( $checked->{ $slug }->vulnerabilities ) ) { - foreach ( $checked->{ $slug }->vulnerabilities as $threat ) { - $extension->threats[] = new Threat_Model( - array( - 'id' => $threat->id, - 'title' => $threat->title, - 'fixed_in' => $threat->fixed_in, - 'description' => isset( $threat->description ) ? $threat->description : null, - 'source' => isset( $threat->id ) ? Redirect::get_url( 'jetpack-protect-vul-info', array( 'path' => $threat->id ) ) : null, - ) - ); - } - } - } - - $new_list[] = $extension; - - } - - $new_list = parent::sort_threats( $new_list ); - - return $new_list; - } - - /** - * Check if the WordPress version that was checked matches the current installed version. - * - * @param object $core_check The object returned by Protect wpcom endpoint. - * @return object The object representing the current status of core checks. - */ - protected static function normalize_core_information( $core_check ) { - global $wp_version; - - $core = new Extension_Model( - array( - 'type' => 'core', - 'name' => 'WordPress', - 'version' => $wp_version, - 'checked' => false, - ) - ); - - if ( isset( $core_check->version ) && $core_check->version === $wp_version ) { - if ( is_array( $core_check->vulnerabilities ) ) { - $core->checked = true; - $core->set_threats( - array_map( - function ( $vulnerability ) { - $vulnerability->source = isset( $vulnerability->id ) ? Redirect::get_url( 'jetpack-protect-vul-info', array( 'path' => $vulnerability->id ) ) : null; - return $vulnerability; - }, - $core_check->vulnerabilities - ) - ); - } - } - - return $core; - } - -} 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 465f679d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-rest-controller.php +++ /dev/null @@ -1,426 +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' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'ignore-threat', - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::api_ignore_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-seen', - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::api_get_waf_seen_status', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'waf-seen', - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::api_set_waf_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::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' ); - }, - ) - ); - } - - /** - * 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, 200 ); - } - - /** - * 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, 200 ); - } - - /** - * 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.' ); - } - - /** - * 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 occured while attempting to ignore the threat.', 500 ); - } - - return new WP_REST_Response( 'Threat ignored.' ); - } - - /** - * 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 occured 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 occured 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 occured 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 occured 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 occured 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 occured 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( - 'is_seen' => Jetpack_Protect::get_waf_seen_status(), - 'is_enabled' => Waf_Runner::is_enabled(), - 'config' => Waf_Runner::get_config(), - 'stats' => Jetpack_Protect::get_waf_stats(), - ) - ); - } - - /** - * Get WAF "Seen" status for the API endpoint - * - * @return bool Whether the current user has viewed the WAF screen. - */ - public static function api_get_waf_seen_status() { - return Jetpack_Protect::get_waf_seen_status(); - } - - /** - * Set WAF "Seen" status for the API endpoint - * - * @return bool True if seen status updated to true, false on failure. - */ - public static function api_set_waf_seen_status() { - return Jetpack_Protect::set_waf_seen_status(); - } - - /** - * 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(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-scan-status.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-scan-status.php deleted file mode 100644 index 89fb66a3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-scan-status.php +++ /dev/null @@ -1,360 +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' ), - 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. - * - * @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; - - $status = new Status_Model(); - $status->data_source = 'scan_api'; - $status->status = isset( $scan_data->state ) ? $scan_data->state : null; - $status->num_threats = 0; - $status->num_themes_threats = 0; - $status->num_plugins_threats = 0; - $status->has_unchecked_items = false; - $status->current_progress = isset( $scan_data->current->progress ) ? $scan_data->current->progress : null; - - 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' ); - } - } - - $status->core = new Extension_Model( - array( - 'type' => 'core', - 'name' => 'WordPress', - 'version' => $wp_version, - 'checked' => true, // to do: default to false once Scan API has manifest - ) - ); - - if ( isset( $scan_data->threats ) && is_array( $scan_data->threats ) ) { - foreach ( $scan_data->threats as $threat ) { - if ( isset( $threat->extension->type ) ) { - if ( 'plugin' === $threat->extension->type ) { - // add the extension if it does not yet exist in the status - if ( ! isset( $status->plugins[ $threat->extension->slug ] ) ) { - $status->plugins[ $threat->extension->slug ] = new Extension_Model( - array( - 'name' => isset( $threat->extension->name ) ? $threat->extension->name : null, - 'slug' => isset( $threat->extension->slug ) ? $threat->extension->slug : null, - 'version' => isset( $threat->extension->version ) ? $threat->extension->version : null, - 'type' => 'plugin', - 'checked' => true, - 'threats' => array(), - ) - ); - } - - $status->plugins[ $threat->extension->slug ]->threats[] = new Threat_Model( - array( - 'id' => isset( $threat->id ) ? $threat->id : null, - 'signature' => isset( $threat->signature ) ? $threat->signature : null, - 'title' => isset( $threat->title ) ? $threat->title : null, - 'description' => isset( $threat->description ) ? $threat->description : null, - 'vulnerability_description' => isset( $threat->vulnerability_description ) ? $threat->vulnerability_description : null, - 'fix_description' => isset( $threat->fix_description ) ? $threat->fix_description : null, - 'payload_subtitle' => isset( $threat->payload_subtitle ) ? $threat->payload_subtitle : null, - 'payload_description' => isset( $threat->payload_description ) ? $threat->payload_description : null, - 'first_detected' => isset( $threat->first_detected ) ? $threat->first_detected : null, - 'fixed_in' => isset( $threat->fixer->fixer ) && 'update' === $threat->fixer->fixer ? $threat->fixer->target : null, - 'severity' => isset( $threat->severity ) ? $threat->severity : null, - 'fixable' => isset( $threat->fixer ) ? $threat->fixer : null, - 'status' => isset( $threat->status ) ? $threat->status : null, - 'filename' => isset( $threat->filename ) ? $threat->filename : null, - 'context' => isset( $threat->context ) ? $threat->context : null, - 'source' => isset( $threat->source ) ? $threat->source : null, - ) - ); - ++$status->num_threats; - ++$status->num_plugins_threats; - continue; - } - - if ( 'theme' === $threat->extension->type ) { - // add the extension if it does not yet exist in the status - if ( ! isset( $status->themes[ $threat->extension->slug ] ) ) { - $status->themes[ $threat->extension->slug ] = new Extension_Model( - array( - 'name' => isset( $threat->extension->name ) ? $threat->extension->name : null, - 'slug' => isset( $threat->extension->slug ) ? $threat->extension->slug : null, - 'version' => isset( $threat->extension->version ) ? $threat->extension->version : null, - 'type' => 'theme', - 'checked' => true, - 'threats' => array(), - ) - ); - } - - $status->themes[ $threat->extension->slug ]->threats[] = new Threat_Model( - array( - 'id' => isset( $threat->id ) ? $threat->id : null, - 'signature' => isset( $threat->signature ) ? $threat->signature : null, - 'title' => isset( $threat->title ) ? $threat->title : null, - 'description' => isset( $threat->description ) ? $threat->description : null, - 'vulnerability_description' => isset( $threat->vulnerability_description ) ? $threat->vulnerability_description : null, - 'fix_description' => isset( $threat->fix_description ) ? $threat->fix_description : null, - 'payload_subtitle' => isset( $threat->payload_subtitle ) ? $threat->payload_subtitle : null, - 'payload_description' => isset( $threat->payload_description ) ? $threat->payload_description : null, - 'first_detected' => isset( $threat->first_detected ) ? $threat->first_detected : null, - 'fixed_in' => isset( $threat->fixer->fixer ) && 'update' === $threat->fixer->fixer ? $threat->fixer->target : null, - 'severity' => isset( $threat->severity ) ? $threat->severity : null, - 'fixable' => isset( $threat->fixer ) ? $threat->fixer : null, - 'status' => isset( $threat->status ) ? $threat->status : null, - 'filename' => isset( $threat->filename ) ? $threat->filename : null, - 'context' => isset( $threat->context ) ? $threat->context : null, - 'source' => isset( $threat->source ) ? $threat->source : null, - ) - ); - ++$status->num_threats; - ++$status->num_themes_threats; - continue; - } - } - - if ( isset( $threat->signature ) && 'Vulnerable.WP.Core' === $threat->signature ) { - if ( $threat->version !== $wp_version ) { - continue; - } - - $status->core->threats[] = new Threat_Model( - array( - 'id' => $threat->id, - 'signature' => $threat->signature, - 'title' => $threat->title, - 'description' => $threat->description, - 'first_detected' => $threat->first_detected, - 'severity' => $threat->severity, - ) - ); - ++$status->num_threats; - - continue; - } - - if ( ! empty( $threat->filename ) ) { - $status->files[] = new Threat_Model( $threat ); - ++$status->num_threats; - continue; - } - - if ( ! empty( $threat->table ) ) { - $status->database[] = new Threat_Model( $threat ); - ++$status->num_threats; - continue; - } - } - } - - $installed_plugins = Plugins_Installer::get_plugins(); - $status->plugins = self::merge_installed_and_checked_lists( $installed_plugins, $status->plugins, array( 'type' => 'plugins' ), true ); - - $installed_themes = Sync_Functions::get_themes(); - $status->themes = self::merge_installed_and_checked_lists( $installed_themes, $status->themes, array( 'type' => 'themes' ), true ); - - foreach ( array_merge( $status->themes, $status->plugins ) as $extension ) { - if ( ! $extension->checked ) { - $status->has_unchecked_items = true; - break; - } - } - - return $status; - } - - /** - * Merges the list of installed extensions with the list of extensions that were checked for known vulnerabilities and return a normalized list to be used in the UI - * - * @param array $installed The list of installed extensions, where each attribute key is the extension slug. - * @param object $checked The list of checked extensions. - * @param array $append Additional data to append to each result in the list. - * @return array Normalized list of extensions. - */ - protected static function merge_installed_and_checked_lists( $installed, $checked, $append ) { - $new_list = array(); - $checked = (object) $checked; - - foreach ( array_keys( $installed ) as $slug ) { - /** - * Extension Type Map - * - * @var array $extension_type_map Key value pairs of extension types and their corresponding - * identifier used by the Scan API data source. - */ - $extension_type_map = array( - 'themes' => 'r1', - 'plugins' => 'r2', - ); - - $version = $installed[ $slug ]['Version']; - $short_slug = str_replace( '.php', '', explode( '/', $slug )[0] ); - $scanifest_slug = $extension_type_map[ $append['type'] ] . ":$short_slug@$version"; - - $extension = new Extension_Model( - array_merge( - array( - 'name' => $installed[ $slug ]['Name'], - 'version' => $version, - 'slug' => $slug, - 'threats' => array(), - 'checked' => false, - ), - $append - ) - ); - - if ( ! isset( $checked->extensions ) // no extension data available from Scan API - || is_array( $checked->extensions ) && in_array( $scanifest_slug, $checked->extensions, true ) // extension data matches Scan API - ) { - $extension->checked = true; - if ( isset( $checked->{ $short_slug }->threats ) ) { - $extension->threats = $checked->{ $short_slug }->threats; - } - } - - $new_list[] = $extension; - - } - - $new_list = parent::sort_threats( $new_list ); - - return $new_list; - } - -} 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 9c62ea01..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-site-health.php +++ /dev/null @@ -1,111 +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-status.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-status.php deleted file mode 100644 index 4bf1a2e0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-status.php +++ /dev/null @@ -1,314 +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 isset( $status->num_threats ) && is_int( $status->num_threats ) ? $status->num_threats : 0; - } - - /** - * Get all threats combined - * - * @return array - */ - public static function get_all_threats() { - return array_merge( - self::get_wordpress_threats(), - self::get_themes_threats(), - self::get_plugins_threats(), - self::get_files_threats(), - self::get_database_threats() - ); - } - - /** - * Get threats found for WordPress core - * - * @return array - */ - public static function get_wordpress_threats() { - return self::get_threats( 'core' ); - } - - /** - * Get threats found for themes - * - * @return array - */ - public static function get_themes_threats() { - return self::get_threats( 'themes' ); - } - - /** - * Get threats found for plugins - * - * @return array - */ - public static function get_plugins_threats() { - return self::get_threats( 'plugins' ); - } - - /** - * Get threats found for files - * - * @return array - */ - public static function get_files_threats() { - return self::get_threats( 'files' ); - } - - /** - * Get threats found for plugins - * - * @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 ( 'core' === $type ) { - return isset( $status->$type ) && ! empty( $status->$type->threats ) ? $status->$type->threats : array(); - } - - if ( 'files' === $type || 'database' === $type ) { - return isset( $status->$type ) && ! empty( $status->$type ) ? $status->$type : array(); - } - - $threats = array(); - if ( isset( $status->$type ) ) { - foreach ( (array) $status->$type as $item ) { - if ( ! empty( $item->threats ) ) { - $threats = array_merge( $threats, $item->threats ); - } - } - } - return $threats; - } - - /** - * Check if the WordPress version that was checked matches the current installed version. - * - * @param object $core_check The object returned by Protect wpcom endpoint. - * @return object The object representing the current status of core checks. - */ - protected static function normalize_core_information( $core_check ) { - global $wp_version; - - $core = new Extension_Model( - array( - 'type' => 'core', - 'name' => 'WordPress', - 'version' => $wp_version, - 'checked' => false, - ) - ); - - if ( isset( $core_check->version ) && $core_check->version === $wp_version ) { - if ( is_array( $core_check->vulnerabilities ) ) { - $core->checked = true; - $core->set_threats( $core_check->vulnerabilities ); - } - } - - return $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 ) { - // sort primarily based on the presence of threats - if ( ! empty( $a->threats ) && empty( $b->threats ) ) { - return -1; - } - if ( empty( $a->threats ) && ! empty( $b->threats ) ) { - return 1; - } - // sort secondarily on whether the item has been checked - if ( $a->checked && ! $b->checked ) { - return 1; - } - if ( ! $a->checked && $b->checked ) { - return -1; - } - - return 0; - } - ); - - return $threats; - } - -} 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 c4b66e38..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-threats.php +++ /dev/null @@ -1,203 +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( $threat_id ); - 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(); - - 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 ) ); - } - - /** - * 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(); - - $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 ) { - $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(); - - 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(); - - return true; - } - -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/models/class-extension-model.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/models/class-extension-model.php deleted file mode 100644 index 4a1fb3b4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/models/class-extension-model.php +++ /dev/null @@ -1,111 +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 - * - * @param array $threats An array of threat data to add to the extension. - */ - public function set_threats( $threats ) { - if ( ! is_array( $threats ) ) { - $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 - ); - - $this->threats = $threats; - } - -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/models/class-status-model.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/models/class-status-model.php deleted file mode 100644 index 2ac4af68..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/models/class-status-model.php +++ /dev/null @@ -1,142 +0,0 @@ - - */ - public $themes = array(); - - /** - * Status plugins. - * - * @var array - */ - public $plugins = array(); - - /** - * File threats. - * - * @var array - */ - public $files = array(); - - /** - * Database threats. - * - * @var array - */ - public $database = 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; - - /** - * Status constructor. - * - * @param array $status The status data to load into the class instance. - */ - public function __construct( $status = array() ) { - // set status defaults - $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/src/models/class-threat-model.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/models/class-threat-model.php deleted file mode 100644 index c45226d6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/models/class-threat-model.php +++ /dev/null @@ -1,116 +0,0 @@ - $value ) { - if ( property_exists( $this, $property ) ) { - $this->$property = $value; - } - } - } - -} 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 e51f3f03..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/autoload.php +++ /dev/null @@ -1,25 +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/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 b4b46c0e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/SECURITY.md +++ /dev/null @@ -1,38 +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 has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure. - -**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 50f094b4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/composer.json +++ /dev/null @@ -1,49 +0,0 @@ -{ - "name": "automattic/jetpack-plans", - "description": "Fetch information about Jetpack Plans from wpcom", - "type": "library", - "license": "GPL-2.0-or-later", - "require": { - "automattic/jetpack-connection": "^1.51.0" - }, - "require-dev": { - "yoast/phpunit-polyfills": "1.0.4", - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/jetpack-status": "^1.16.2", - "automattic/wordbless": "@dev" - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "./vendor/phpunit/phpunit/phpunit --colors=always" - ], - "test-php": [ - "@composer phpunit" - ], - "post-install-cmd": "WorDBless\\Composer\\InstallDropin::copy", - "post-update-cmd": "WorDBless\\Composer\\InstallDropin::copy", - "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.2.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 b9679f24..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/src/class-current-plan.php +++ /dev/null @@ -1,367 +0,0 @@ - array( - 'plans' => array( - 'jetpack_free', - ), - 'supports' => array( - 'opentable', - 'calendly', - 'send-a-message', - 'whatsapp-button', - 'social-previews', - 'videopress', - - 'core/video', - 'core/cover', - 'core/audio', - ), - ), - 'personal' => array( - 'plans' => array( - 'jetpack_personal', - 'jetpack_personal_monthly', - 'personal-bundle', - 'personal-bundle-monthly', - 'personal-bundle-2y', - 'starter-plan', - ), - 'supports' => array( - 'akismet', - 'payments', - 'recurring-payments', - 'premium-content/container', - 'videopress', - ), - ), - 'premium' => array( - 'plans' => array( - 'jetpack_premium', - 'jetpack_premium_monthly', - 'value_bundle', - 'value_bundle-monthly', - 'value_bundle-2y', - ), - 'supports' => array( - 'donations', - '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', - 'ecommerce-bundle', - 'ecommerce-bundle-monthly', - 'ecommerce-bundle-2y', - 'pro-plan', - ), - '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() { - // Make the API request. - - $response = Client::wpcom_json_api_request_as_blog( sprintf( '/sites/%d', Jetpack_Options::get_option( 'id' ) ) . '?force=wpcom', '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'] ); - - // get available features if Jetpack is active. - if ( class_exists( 'Jetpack' ) ) { - foreach ( \Jetpack::get_available_modules() as $module_slug ) { - $module = \Jetpack::get_module( $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 Jetpack_Plan::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; - } - - $plan = self::get(); - - if ( - in_array( $feature, $plan['supports'], true ) - || in_array( $feature, $plan['features']['active'], true ) - ) { - return true; - } - - return false; - } -} 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 a62a95a1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/src/class-plans.php +++ /dev/null @@ -1,80 +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; - } - } - } -} 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 afef3fa2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/ClassLoader.php +++ /dev/null @@ -1,572 +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 ?string */ - private $vendorDir; - - // PSR-4 - /** - * @var array[] - * @psalm-var array> - */ - private $prefixLengthsPsr4 = array(); - /** - * @var array[] - * @psalm-var array> - */ - private $prefixDirsPsr4 = array(); - /** - * @var array[] - * @psalm-var array - */ - private $fallbackDirsPsr4 = array(); - - // PSR-0 - /** - * @var array[] - * @psalm-var array> - */ - private $prefixesPsr0 = array(); - /** - * @var array[] - * @psalm-var array - */ - private $fallbackDirsPsr0 = array(); - - /** @var bool */ - private $useIncludePath = false; - - /** - * @var string[] - * @psalm-var array - */ - private $classMap = array(); - - /** @var bool */ - private $classMapAuthoritative = false; - - /** - * @var bool[] - * @psalm-var array - */ - private $missingClasses = array(); - - /** @var ?string */ - private $apcuPrefix; - - /** - * @var self[] - */ - private static $registeredLoaders = array(); - - /** - * @param ?string $vendorDir - */ - public function __construct($vendorDir = null) - { - $this->vendorDir = $vendorDir; - } - - /** - * @return string[] - */ - public function getPrefixes() - { - if (!empty($this->prefixesPsr0)) { - return call_user_func_array('array_merge', array_values($this->prefixesPsr0)); - } - - return array(); - } - - /** - * @return array[] - * @psalm-return array> - */ - public function getPrefixesPsr4() - { - return $this->prefixDirsPsr4; - } - - /** - * @return array[] - * @psalm-return array - */ - public function getFallbackDirs() - { - return $this->fallbackDirsPsr0; - } - - /** - * @return array[] - * @psalm-return array - */ - public function getFallbackDirsPsr4() - { - return $this->fallbackDirsPsr4; - } - - /** - * @return string[] Array of classname => path - * @psalm-return array - */ - public function getClassMap() - { - return $this->classMap; - } - - /** - * @param string[] $classMap Class to filename map - * @psalm-param array $classMap - * - * @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 string[]|string $paths The PSR-0 root directories - * @param bool $prepend Whether to prepend the directories - * - * @return void - */ - public function add($prefix, $paths, $prepend = false) - { - if (!$prefix) { - if ($prepend) { - $this->fallbackDirsPsr0 = array_merge( - (array) $paths, - $this->fallbackDirsPsr0 - ); - } else { - $this->fallbackDirsPsr0 = array_merge( - $this->fallbackDirsPsr0, - (array) $paths - ); - } - - return; - } - - $first = $prefix[0]; - if (!isset($this->prefixesPsr0[$first][$prefix])) { - $this->prefixesPsr0[$first][$prefix] = (array) $paths; - - return; - } - if ($prepend) { - $this->prefixesPsr0[$first][$prefix] = array_merge( - (array) $paths, - $this->prefixesPsr0[$first][$prefix] - ); - } else { - $this->prefixesPsr0[$first][$prefix] = array_merge( - $this->prefixesPsr0[$first][$prefix], - (array) $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 string[]|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) - { - if (!$prefix) { - // Register directories for the root namespace. - if ($prepend) { - $this->fallbackDirsPsr4 = array_merge( - (array) $paths, - $this->fallbackDirsPsr4 - ); - } else { - $this->fallbackDirsPsr4 = array_merge( - $this->fallbackDirsPsr4, - (array) $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] = (array) $paths; - } elseif ($prepend) { - // Prepend directories for an already registered namespace. - $this->prefixDirsPsr4[$prefix] = array_merge( - (array) $paths, - $this->prefixDirsPsr4[$prefix] - ); - } else { - // Append directories for an already registered namespace. - $this->prefixDirsPsr4[$prefix] = array_merge( - $this->prefixDirsPsr4[$prefix], - (array) $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 string[]|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 string[]|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($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 indexed by their corresponding vendor directories. - * - * @return self[] - */ - 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; - } -} - -/** - * Scope isolated include. - * - * Prevents access to $this/self from included files. - * - * @param string $file - * @return void - * @private - */ -function includeFile($file) -{ - include $file; -} 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 c6b54af7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/InstalledVersions.php +++ /dev/null @@ -1,352 +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 || empty($installed['versions'][$packageName]['dev_requirement']); - } - } - - 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($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')) { - $installed[] = self::$installedByVendor[$vendorDir] = require $vendorDir.'/composer/installed.php'; - 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') { - self::$installed = require __DIR__ . '/installed.php'; - } else { - 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 71dad34f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_classmap.php +++ /dev/null @@ -1,197 +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\\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\\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\\Client' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-client.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\\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\\Urls' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-urls.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\\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\\REST_Endpoints' => $baseDir . '/jetpack_vendor/automattic/jetpack-identity-crisis/src/class-rest-endpoints.php', - 'Automattic\\Jetpack\\IdentityCrisis\\UI' => $baseDir . '/jetpack_vendor/automattic/jetpack-identity-crisis/src/class-ui.php', - 'Automattic\\Jetpack\\Identity_Crisis' => $baseDir . '/jetpack_vendor/automattic/jetpack-identity-crisis/src/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\\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\\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\\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\\Protect' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-protect.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\\Social' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-social.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Videopress' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-videopress.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\\Wpcom_Products' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-wpcom-products.php', - 'Automattic\\Jetpack\\Partner' => $baseDir . '/jetpack_vendor/automattic/jetpack-partner/src/class-partner.php', - 'Automattic\\Jetpack\\Partner_Coupon' => $baseDir . '/jetpack_vendor/automattic/jetpack-partner/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\\Extension_Model' => $baseDir . '/src/models/class-extension-model.php', - 'Automattic\\Jetpack\\Protect\\Plan' => $baseDir . '/src/class-plan.php', - 'Automattic\\Jetpack\\Protect\\Protect_Status' => $baseDir . '/src/class-protect-status.php', - 'Automattic\\Jetpack\\Protect\\REST_Controller' => $baseDir . '/src/class-rest-controller.php', - 'Automattic\\Jetpack\\Protect\\Scan_Status' => $baseDir . '/src/class-scan-status.php', - 'Automattic\\Jetpack\\Protect\\Site_Health' => $baseDir . '/src/class-site-health.php', - 'Automattic\\Jetpack\\Protect\\Status' => $baseDir . '/src/class-status.php', - 'Automattic\\Jetpack\\Protect\\Status_Model' => $baseDir . '/src/models/class-status-model.php', - 'Automattic\\Jetpack\\Protect\\Threat_Model' => $baseDir . '/src/models/class-threat-model.php', - 'Automattic\\Jetpack\\Protect\\Threats' => $baseDir . '/src/class-threats.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\\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_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\\Helper_Script_Manager' => $baseDir . '/jetpack_vendor/automattic/jetpack-transport-helper/src/class-helper-script-manager.php', - 'Automattic\\Jetpack\\Transport_Helper\\Package_Version' => $baseDir . '/jetpack_vendor/automattic/jetpack-transport-helper/src/class-package-version.php', - 'Automattic\\Jetpack\\Transport_Helper\\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_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 190ac33c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_files.php +++ /dev/null @@ -1,12 +0,0 @@ - $baseDir . '/jetpack_vendor/automattic/jetpack-assets/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 fc7a0691..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_real.php +++ /dev/null @@ -1,58 +0,0 @@ -setClassMapAuthoritative(true); - $loader->register(true); - - $includeFiles = \Composer\Autoload\ComposerStaticInitc4802e05bbcf59fd3b6350e8d3e5482c_protectⓥ1_4_0::$files; - foreach ($includeFiles as $fileIdentifier => $file) { - composerRequirec4802e05bbcf59fd3b6350e8d3e5482c_protectⓥ1_4_0($fileIdentifier, $file); - } - - return $loader; - } -} - -/** - * @param string $fileIdentifier - * @param string $file - * @return void - */ -function composerRequirec4802e05bbcf59fd3b6350e8d3e5482c_protectⓥ1_4_0($fileIdentifier, $file) -{ - if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { - $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true; - - require $file; - } -} 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 f57795bb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_static.php +++ /dev/null @@ -1,229 +0,0 @@ - __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-assets/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\\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\\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\\Client' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-client.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\\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\\Urls' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-urls.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\\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\\REST_Endpoints' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-identity-crisis/src/class-rest-endpoints.php', - 'Automattic\\Jetpack\\IdentityCrisis\\UI' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-identity-crisis/src/class-ui.php', - 'Automattic\\Jetpack\\Identity_Crisis' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-identity-crisis/src/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\\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\\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\\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\\Protect' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-protect.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\\Social' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-social.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Videopress' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-videopress.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\\Wpcom_Products' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-wpcom-products.php', - 'Automattic\\Jetpack\\Partner' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-partner/src/class-partner.php', - 'Automattic\\Jetpack\\Partner_Coupon' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-partner/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\\Extension_Model' => __DIR__ . '/../..' . '/src/models/class-extension-model.php', - 'Automattic\\Jetpack\\Protect\\Plan' => __DIR__ . '/../..' . '/src/class-plan.php', - 'Automattic\\Jetpack\\Protect\\Protect_Status' => __DIR__ . '/../..' . '/src/class-protect-status.php', - 'Automattic\\Jetpack\\Protect\\REST_Controller' => __DIR__ . '/../..' . '/src/class-rest-controller.php', - 'Automattic\\Jetpack\\Protect\\Scan_Status' => __DIR__ . '/../..' . '/src/class-scan-status.php', - 'Automattic\\Jetpack\\Protect\\Site_Health' => __DIR__ . '/../..' . '/src/class-site-health.php', - 'Automattic\\Jetpack\\Protect\\Status' => __DIR__ . '/../..' . '/src/class-status.php', - 'Automattic\\Jetpack\\Protect\\Status_Model' => __DIR__ . '/../..' . '/src/models/class-status-model.php', - 'Automattic\\Jetpack\\Protect\\Threat_Model' => __DIR__ . '/../..' . '/src/models/class-threat-model.php', - 'Automattic\\Jetpack\\Protect\\Threats' => __DIR__ . '/../..' . '/src/class-threats.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\\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_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\\Helper_Script_Manager' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-transport-helper/src/class-helper-script-manager.php', - 'Automattic\\Jetpack\\Transport_Helper\\Package_Version' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-transport-helper/src/class-package-version.php', - 'Automattic\\Jetpack\\Transport_Helper\\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_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ⓥ1_4_0::$prefixLengthsPsr4; - $loader->prefixDirsPsr4 = ComposerStaticInitc4802e05bbcf59fd3b6350e8d3e5482c_protectⓥ1_4_0::$prefixDirsPsr4; - $loader->classMap = ComposerStaticInitc4802e05bbcf59fd3b6350e8d3e5482c_protectⓥ1_4_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 0682851d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/installed.json +++ /dev/null @@ -1,1440 +0,0 @@ -{ - "packages": [ - { - "name": "automattic/jetpack-a8c-mc-stats", - "version": "v1.4.20", - "version_normalized": "1.4.20.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-a8c-mc-stats.git", - "reference": "6743d34fe7556455e17cbe1b7c90ed39a1f69089" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-a8c-mc-stats/zipball/6743d34fe7556455e17cbe1b7c90ed39a1f69089", - "reference": "6743d34fe7556455e17cbe1b7c90ed39a1f69089", - "shasum": "" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "yoast/phpunit-polyfills": "1.0.4" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2023-04-10T11:43:38+00:00", - "type": "jetpack-library", - "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": "1.4.x-dev" - } - }, - "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/v1.4.20" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-a8c-mc-stats" - }, - { - "name": "automattic/jetpack-admin-ui", - "version": "v0.2.19", - "version_normalized": "0.2.19.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-admin-ui.git", - "reference": "ae3c7f7a3bd564172ce48f72447ecea2c7508a5a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-admin-ui/zipball/ae3c7f7a3bd564172ce48f72447ecea2c7508a5a", - "reference": "ae3c7f7a3bd564172ce48f72447ecea2c7508a5a", - "shasum": "" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/jetpack-logo": "^1.6.1", - "automattic/wordbless": "dev-master", - "yoast/phpunit-polyfills": "1.0.4" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2023-04-10T11:44:03+00:00", - "type": "jetpack-library", - "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.2.x-dev" - }, - "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.2.19" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-admin-ui" - }, - { - "name": "automattic/jetpack-assets", - "version": "v1.17.34", - "version_normalized": "1.17.34.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-assets.git", - "reference": "73ec392493a1364dcc9e57c878136bf5c91e24af" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-assets/zipball/73ec392493a1364dcc9e57c878136bf5c91e24af", - "reference": "73ec392493a1364dcc9e57c878136bf5c91e24af", - "shasum": "" - }, - "require": { - "automattic/jetpack-constants": "^1.6.21" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "brain/monkey": "2.6.1", - "wikimedia/testing-access-wrapper": "^1.0 || ^2.0", - "yoast/phpunit-polyfills": "1.0.4" - }, - "time": "2023-03-20T19:06:49+00:00", - "type": "jetpack-library", - "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": "1.17.x-dev" - } - }, - "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/v1.17.34" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-assets" - }, - { - "name": "automattic/jetpack-autoloader", - "version": "v2.11.18", - "version_normalized": "2.11.18.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-autoloader.git", - "reference": "53cbf0528fa6931c4fa6465bccd37514f9eda720" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-autoloader/zipball/53cbf0528fa6931c4fa6465bccd37514f9eda720", - "reference": "53cbf0528fa6931c4fa6465bccd37514f9eda720", - "shasum": "" - }, - "require": { - "composer-plugin-api": "^1.1 || ^2.0" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "yoast/phpunit-polyfills": "1.0.4" - }, - "time": "2023-03-29T12:51:59+00:00", - "type": "composer-plugin", - "extra": { - "autotagger": true, - "class": "Automattic\\Jetpack\\Autoloader\\CustomAutoloaderPlugin", - "mirror-repo": "Automattic/jetpack-autoloader", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-autoloader/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "2.11.x-dev" - } - }, - "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.", - "support": { - "source": "https://github.com/Automattic/jetpack-autoloader/tree/v2.11.18" - }, - "install-path": "../automattic/jetpack-autoloader" - }, - { - "name": "automattic/jetpack-composer-plugin", - "version": "v1.1.10", - "version_normalized": "1.1.10.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-composer-plugin.git", - "reference": "c6298f3efd8a1ca76182f685d0075080e2681aa3" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-composer-plugin/zipball/c6298f3efd8a1ca76182f685d0075080e2681aa3", - "reference": "c6298f3efd8a1ca76182f685d0075080e2681aa3", - "shasum": "" - }, - "require": { - "composer-plugin-api": "^2.1.0" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "composer/composer": "^2.2 || ^2.4", - "yoast/phpunit-polyfills": "1.0.4" - }, - "time": "2023-02-20T19:47:32+00:00", - "type": "composer-plugin", - "extra": { - "plugin-modifies-install-path": true, - "class": "Automattic\\Jetpack\\Composer\\Plugin", - "mirror-repo": "Automattic/jetpack-composer-plugin", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-composer-plugin/compare/v${old}...v${new}" - }, - "autotagger": true, - "branch-alias": { - "dev-trunk": "1.1.x-dev" - } - }, - "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.", - "support": { - "source": "https://github.com/Automattic/jetpack-composer-plugin/tree/v1.1.10" - }, - "install-path": "../automattic/jetpack-composer-plugin" - }, - { - "name": "automattic/jetpack-config", - "version": "v1.15.1", - "version_normalized": "1.15.1.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-config.git", - "reference": "e4985903fb40dbc7c03bdaf58f4a80ac72c50570" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-config/zipball/e4985903fb40dbc7c03bdaf58f4a80ac72c50570", - "reference": "e4985903fb40dbc7c03bdaf58f4a80ac72c50570", - "shasum": "" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2" - }, - "time": "2023-03-29T12:51:51+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-config", - "textdomain": "jetpack-config", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-config/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "1.15.x-dev" - } - }, - "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/v1.15.1" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-config" - }, - { - "name": "automattic/jetpack-connection", - "version": "v1.51.7", - "version_normalized": "1.51.7.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-connection.git", - "reference": "4c4bae836858957d9aaf6854cf4e24c3261242c4" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-connection/zipball/4c4bae836858957d9aaf6854cf4e24c3261242c4", - "reference": "4c4bae836858957d9aaf6854cf4e24c3261242c4", - "shasum": "" - }, - "require": { - "automattic/jetpack-a8c-mc-stats": "^1.4.20", - "automattic/jetpack-admin-ui": "^0.2.19", - "automattic/jetpack-constants": "^1.6.22", - "automattic/jetpack-redirect": "^1.7.25", - "automattic/jetpack-roles": "^1.4.23", - "automattic/jetpack-status": "^1.16.4" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/wordbless": "@dev", - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2023-04-10T11:44:13+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-connection", - "textdomain": "jetpack-connection", - "version-constants": { - "::PACKAGE_VERSION": "src/class-package-version.php" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-connection/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "1.51.x-dev" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "legacy", - "src/", - "src/webhooks" - ] - }, - "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/v1.51.7" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-connection" - }, - { - "name": "automattic/jetpack-constants", - "version": "v1.6.22", - "version_normalized": "1.6.22.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-constants.git", - "reference": "7b5c44d763c7b0dd7498be2b41a89bfefe84834c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-constants/zipball/7b5c44d763c7b0dd7498be2b41a89bfefe84834c", - "reference": "7b5c44d763c7b0dd7498be2b41a89bfefe84834c", - "shasum": "" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2023-04-10T11:43:45+00:00", - "type": "jetpack-library", - "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": "1.6.x-dev" - } - }, - "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/v1.6.22" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-constants" - }, - { - "name": "automattic/jetpack-device-detection", - "version": "v1.4.25", - "version_normalized": "1.4.25.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-device-detection.git", - "reference": "cf6297f71412dce19522193c2d517cd230a0bee9" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-device-detection/zipball/cf6297f71412dce19522193c2d517cd230a0bee9", - "reference": "cf6297f71412dce19522193c2d517cd230a0bee9", - "shasum": "" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "yoast/phpunit-polyfills": "1.0.4" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2023-04-10T11:43:41+00:00", - "type": "jetpack-library", - "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": "1.4.x-dev" - } - }, - "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/v1.4.25" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-device-detection" - }, - { - "name": "automattic/jetpack-identity-crisis", - "version": "v0.8.40", - "version_normalized": "0.8.40.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-identity-crisis.git", - "reference": "9c52db5e021d6792084e1d225347b82acae2ce86" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-identity-crisis/zipball/9c52db5e021d6792084e1d225347b82acae2ce86", - "reference": "9c52db5e021d6792084e1d225347b82acae2ce86", - "shasum": "" - }, - "require": { - "automattic/jetpack-assets": "^1.17.34", - "automattic/jetpack-connection": "^1.51.2", - "automattic/jetpack-constants": "^1.6.21", - "automattic/jetpack-logo": "^1.5.22", - "automattic/jetpack-status": "^1.16.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/wordbless": "@dev", - "yoast/phpunit-polyfills": "1.0.4" - }, - "time": "2023-03-20T19:07:29+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-identity-crisis", - "textdomain": "jetpack-idc", - "version-constants": { - "::PACKAGE_VERSION": "src/class-identity-crisis.php" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-identity-crisis/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "0.8.x-dev" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Identity Crisis.", - "support": { - "source": "https://github.com/Automattic/jetpack-identity-crisis/tree/v0.8.40" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-identity-crisis" - }, - { - "name": "automattic/jetpack-ip", - "version": "v0.1.2", - "version_normalized": "0.1.2.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-ip.git", - "reference": "8cc665d68ef5230de78e2701b61b91af64d8dfe6" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-ip/zipball/8cc665d68ef5230de78e2701b61b91af64d8dfe6", - "reference": "8cc665d68ef5230de78e2701b61b91af64d8dfe6", - "shasum": "" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2023-04-10T11:43:44+00:00", - "type": "jetpack-library", - "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.1.x-dev" - }, - "textdomain": "jetpack-ip", - "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.1.2" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-ip" - }, - { - "name": "automattic/jetpack-jitm", - "version": "v2.3.4", - "version_normalized": "2.3.4.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-jitm.git", - "reference": "950d01008784d9c360ceb92bc4b67dcced76ff8c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-jitm/zipball/950d01008784d9c360ceb92bc4b67dcced76ff8c", - "reference": "950d01008784d9c360ceb92bc4b67dcced76ff8c", - "shasum": "" - }, - "require": { - "automattic/jetpack-a8c-mc-stats": "^1.4.19", - "automattic/jetpack-assets": "^1.17.34", - "automattic/jetpack-connection": "^1.51.4", - "automattic/jetpack-device-detection": "^1.4.24", - "automattic/jetpack-logo": "^1.5.22", - "automattic/jetpack-partner": "^1.7.22", - "automattic/jetpack-redirect": "^1.7.24", - "automattic/jetpack-status": "^1.16.3" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4" - }, - "time": "2023-03-29T12:52:57+00:00", - "type": "jetpack-library", - "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": "2.3.x-dev" - } - }, - "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/v2.3.4" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-jitm" - }, - { - "name": "automattic/jetpack-licensing", - "version": "v1.8.2", - "version_normalized": "1.8.2.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-licensing.git", - "reference": "46ff51c6f1f8ab5206d8bc93ec5bb23e1c174def" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-licensing/zipball/46ff51c6f1f8ab5206d8bc93ec5bb23e1c174def", - "reference": "46ff51c6f1f8ab5206d8bc93ec5bb23e1c174def", - "shasum": "" - }, - "require": { - "automattic/jetpack-connection": "^1.51.7" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/wordbless": "@dev", - "yoast/phpunit-polyfills": "1.0.4" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2023-04-10T11:44:26+00:00", - "type": "jetpack-library", - "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": "1.8.x-dev" - } - }, - "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/v1.8.2" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-licensing" - }, - { - "name": "automattic/jetpack-logo", - "version": "v1.6.1", - "version_normalized": "1.6.1.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-logo.git", - "reference": "6a7b9e5602ca81c207e573dfed9e4fc1dd6a279b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-logo/zipball/6a7b9e5602ca81c207e573dfed9e4fc1dd6a279b", - "reference": "6a7b9e5602ca81c207e573dfed9e4fc1dd6a279b", - "shasum": "" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "yoast/phpunit-polyfills": "1.0.4" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2023-04-10T11:43:42+00:00", - "type": "jetpack-library", - "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": "1.6.x-dev" - } - }, - "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/v1.6.1" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-logo" - }, - { - "name": "automattic/jetpack-my-jetpack", - "version": "v2.9.1", - "version_normalized": "2.9.1.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-my-jetpack.git", - "reference": "7b04d4767e18e06521d66863124579cbcabb2366" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-my-jetpack/zipball/7b04d4767e18e06521d66863124579cbcabb2366", - "reference": "7b04d4767e18e06521d66863124579cbcabb2366", - "shasum": "" - }, - "require": { - "automattic/jetpack-admin-ui": "^0.2.17", - "automattic/jetpack-assets": "^1.17.34", - "automattic/jetpack-connection": "^1.51.4", - "automattic/jetpack-constants": "^1.6.21", - "automattic/jetpack-jitm": "^2.3.4", - "automattic/jetpack-licensing": "^1.8.1", - "automattic/jetpack-plugins-installer": "^0.2.3", - "automattic/jetpack-redirect": "^1.7.24" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/jetpack-videopress": "^0.13.4-alpha", - "automattic/wordbless": "@dev", - "yoast/phpunit-polyfills": "1.0.4" - }, - "time": "2023-03-29T12:53:10+00:00", - "type": "jetpack-library", - "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": "2.9.x-dev" - }, - "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/v2.9.1" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-my-jetpack" - }, - { - "name": "automattic/jetpack-partner", - "version": "v1.7.23", - "version_normalized": "1.7.23.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-partner.git", - "reference": "6b179bff7c0863015aa699939e1dfe2bd4c97974" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-partner/zipball/6b179bff7c0863015aa699939e1dfe2bd4c97974", - "reference": "6b179bff7c0863015aa699939e1dfe2bd4c97974", - "shasum": "" - }, - "require": { - "automattic/jetpack-connection": "^1.51.7", - "automattic/jetpack-status": "^1.16.4" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/wordbless": "@dev", - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2023-04-10T11:44:29+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-partner", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-partner/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "1.7.x-dev" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Support functions for Jetpack hosting partners.", - "support": { - "source": "https://github.com/Automattic/jetpack-partner/tree/v1.7.23" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-partner" - }, - { - "name": "automattic/jetpack-password-checker", - "version": "v0.2.13", - "version_normalized": "0.2.13.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-password-checker.git", - "reference": "16b88d370ca2f59b38e6c44bc37fc43e72090dad" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-password-checker/zipball/16b88d370ca2f59b38e6c44bc37fc43e72090dad", - "reference": "16b88d370ca2f59b38e6c44bc37fc43e72090dad", - "shasum": "" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/wordbless": "@dev", - "yoast/phpunit-polyfills": "1.0.4" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2023-04-10T11:43:53+00:00", - "type": "jetpack-library", - "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.2.x-dev" - } - }, - "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.2.13" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-password-checker" - }, - { - "name": "automattic/jetpack-plans", - "version": "v0.2.10", - "version_normalized": "0.2.10.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-plans.git", - "reference": "262dd36d110723f2fc940aabf88c510afaf537fc" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-plans/zipball/262dd36d110723f2fc940aabf88c510afaf537fc", - "reference": "262dd36d110723f2fc940aabf88c510afaf537fc", - "shasum": "" - }, - "require": { - "automattic/jetpack-connection": "^1.51.0" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/jetpack-status": "^1.16.2", - "automattic/wordbless": "@dev", - "yoast/phpunit-polyfills": "1.0.4" - }, - "time": "2023-02-20T19:48:24+00:00", - "type": "library", - "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.2.x-dev" - } - }, - "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.2.10" - }, - "install-path": "../automattic/jetpack-plans" - }, - { - "name": "automattic/jetpack-plugins-installer", - "version": "v0.2.3", - "version_normalized": "0.2.3.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-plugins-installer.git", - "reference": "ec0e3b888ef33d4bd879de9a014ba20d771aca31" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-plugins-installer/zipball/ec0e3b888ef33d4bd879de9a014ba20d771aca31", - "reference": "ec0e3b888ef33d4bd879de9a014ba20d771aca31", - "shasum": "" - }, - "require": { - "automattic/jetpack-a8c-mc-stats": "^1.4.19" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "yoast/phpunit-polyfills": "1.0.4" - }, - "time": "2023-02-20T19:47:45+00:00", - "type": "jetpack-library", - "extra": { - "branch-alias": { - "dev-trunk": "0.2.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" - }, - "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.2.3" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-plugins-installer" - }, - { - "name": "automattic/jetpack-redirect", - "version": "v1.7.25", - "version_normalized": "1.7.25.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-redirect.git", - "reference": "67d7dce123d4af4fec4b4fe15e99aaad85308314" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-redirect/zipball/67d7dce123d4af4fec4b4fe15e99aaad85308314", - "reference": "67d7dce123d4af4fec4b4fe15e99aaad85308314", - "shasum": "" - }, - "require": { - "automattic/jetpack-status": "^1.16.4" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2023-04-10T11:44:05+00:00", - "type": "jetpack-library", - "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": "1.7.x-dev" - } - }, - "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/v1.7.25" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-redirect" - }, - { - "name": "automattic/jetpack-roles", - "version": "v1.4.23", - "version_normalized": "1.4.23.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-roles.git", - "reference": "f147b3e8061fc0de2a892ddc4f4156eb995545f9" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-roles/zipball/f147b3e8061fc0de2a892ddc4f4156eb995545f9", - "reference": "f147b3e8061fc0de2a892ddc4f4156eb995545f9", - "shasum": "" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2023-04-10T11:43:48+00:00", - "type": "jetpack-library", - "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": "1.4.x-dev" - } - }, - "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/v1.4.23" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-roles" - }, - { - "name": "automattic/jetpack-status", - "version": "v1.17.0", - "version_normalized": "1.17.0.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-status.git", - "reference": "a16c59bb54cac04c579621efffa1ca1d5738c5cc" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-status/zipball/a16c59bb54cac04c579621efffa1ca1d5738c5cc", - "reference": "a16c59bb54cac04c579621efffa1ca1d5738c5cc", - "shasum": "" - }, - "require": { - "automattic/jetpack-constants": "^1.6.22" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/jetpack-ip": "^0.1.2", - "brain/monkey": "2.6.1", - "yoast/phpunit-polyfills": "1.0.4" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2023-04-17T13:43:20+00:00", - "type": "jetpack-library", - "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": "1.17.x-dev" - } - }, - "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/v1.17.0" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-status" - }, - { - "name": "automattic/jetpack-sync", - "version": "v1.47.4", - "version_normalized": "1.47.4.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-sync.git", - "reference": "9c7f25eb8e63a9fbaa1639eaf2f68f46739e5cde" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-sync/zipball/9c7f25eb8e63a9fbaa1639eaf2f68f46739e5cde", - "reference": "9c7f25eb8e63a9fbaa1639eaf2f68f46739e5cde", - "shasum": "" - }, - "require": { - "automattic/jetpack-connection": "^1.51.3", - "automattic/jetpack-constants": "^1.6.21", - "automattic/jetpack-identity-crisis": "^0.8.40", - "automattic/jetpack-ip": "^0.1.1", - "automattic/jetpack-password-checker": "^0.2.12", - "automattic/jetpack-roles": "^1.4.22", - "automattic/jetpack-status": "^1.16.3" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/wordbless": "@dev", - "yoast/phpunit-polyfills": "1.0.4" - }, - "time": "2023-03-28T18:48:42+00:00", - "type": "jetpack-library", - "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": "1.47.x-dev" - } - }, - "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/v1.47.4" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-sync" - }, - { - "name": "automattic/jetpack-transport-helper", - "version": "v0.1.4", - "version_normalized": "0.1.4.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-transport-helper.git", - "reference": "379cd4477b9b43f3765d2e8872e6610fd5126a01" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-transport-helper/zipball/379cd4477b9b43f3765d2e8872e6610fd5126a01", - "reference": "379cd4477b9b43f3765d2e8872e6610fd5126a01", - "shasum": "" - }, - "require": { - "automattic/jetpack-connection": "^1.51.1" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/wordbless": "dev-master", - "yoast/phpunit-polyfills": "1.0.4" - }, - "time": "2023-03-07T22:00:19+00:00", - "type": "jetpack-library", - "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.1.x-dev" - }, - "textdomain": "jetpack-transport-helper" - }, - "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.1.4" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-transport-helper" - }, - { - "name": "automattic/jetpack-waf", - "version": "v0.11.4", - "version_normalized": "0.11.4.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-waf.git", - "reference": "ec68a1429a7bb0ff8c5c4b51186319b86818d0b1" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-waf/zipball/ec68a1429a7bb0ff8c5c4b51186319b86818d0b1", - "reference": "ec68a1429a7bb0ff8c5c4b51186319b86818d0b1", - "shasum": "" - }, - "require": { - "automattic/jetpack-connection": "^1.51.7", - "automattic/jetpack-constants": "^1.6.22", - "automattic/jetpack-ip": "^0.1.2", - "automattic/jetpack-status": "^1.17.0", - "wikimedia/aho-corasick": "^1.0" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^3.3.2", - "automattic/wordbless": "@dev", - "yoast/phpunit-polyfills": "1.0.4" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2023-04-27T18:11:36+00:00", - "type": "jetpack-library", - "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.11.x-dev" - } - }, - "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.11.4" - }, - "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 418d7169..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/installed.php +++ /dev/null @@ -1,257 +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' => 'v1.4.20', - 'version' => '1.4.20.0', - 'reference' => '6743d34fe7556455e17cbe1b7c90ed39a1f69089', - '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.2.19', - 'version' => '0.2.19.0', - 'reference' => 'ae3c7f7a3bd564172ce48f72447ecea2c7508a5a', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-admin-ui', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-assets' => array( - 'pretty_version' => 'v1.17.34', - 'version' => '1.17.34.0', - 'reference' => '73ec392493a1364dcc9e57c878136bf5c91e24af', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-assets', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-autoloader' => array( - 'pretty_version' => 'v2.11.18', - 'version' => '2.11.18.0', - 'reference' => '53cbf0528fa6931c4fa6465bccd37514f9eda720', - 'type' => 'composer-plugin', - 'install_path' => __DIR__ . '/../automattic/jetpack-autoloader', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-composer-plugin' => array( - 'pretty_version' => 'v1.1.10', - 'version' => '1.1.10.0', - 'reference' => 'c6298f3efd8a1ca76182f685d0075080e2681aa3', - 'type' => 'composer-plugin', - 'install_path' => __DIR__ . '/../automattic/jetpack-composer-plugin', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-config' => array( - 'pretty_version' => 'v1.15.1', - 'version' => '1.15.1.0', - 'reference' => 'e4985903fb40dbc7c03bdaf58f4a80ac72c50570', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-config', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-connection' => array( - 'pretty_version' => 'v1.51.7', - 'version' => '1.51.7.0', - 'reference' => '4c4bae836858957d9aaf6854cf4e24c3261242c4', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-connection', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-constants' => array( - 'pretty_version' => 'v1.6.22', - 'version' => '1.6.22.0', - 'reference' => '7b5c44d763c7b0dd7498be2b41a89bfefe84834c', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-constants', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-device-detection' => array( - 'pretty_version' => 'v1.4.25', - 'version' => '1.4.25.0', - 'reference' => 'cf6297f71412dce19522193c2d517cd230a0bee9', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-device-detection', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-identity-crisis' => array( - 'pretty_version' => 'v0.8.40', - 'version' => '0.8.40.0', - 'reference' => '9c52db5e021d6792084e1d225347b82acae2ce86', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-identity-crisis', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-ip' => array( - 'pretty_version' => 'v0.1.2', - 'version' => '0.1.2.0', - 'reference' => '8cc665d68ef5230de78e2701b61b91af64d8dfe6', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-ip', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-jitm' => array( - 'pretty_version' => 'v2.3.4', - 'version' => '2.3.4.0', - 'reference' => '950d01008784d9c360ceb92bc4b67dcced76ff8c', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-jitm', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-licensing' => array( - 'pretty_version' => 'v1.8.2', - 'version' => '1.8.2.0', - 'reference' => '46ff51c6f1f8ab5206d8bc93ec5bb23e1c174def', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-licensing', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-logo' => array( - 'pretty_version' => 'v1.6.1', - 'version' => '1.6.1.0', - 'reference' => '6a7b9e5602ca81c207e573dfed9e4fc1dd6a279b', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-logo', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-my-jetpack' => array( - 'pretty_version' => 'v2.9.1', - 'version' => '2.9.1.0', - 'reference' => '7b04d4767e18e06521d66863124579cbcabb2366', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-my-jetpack', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-partner' => array( - 'pretty_version' => 'v1.7.23', - 'version' => '1.7.23.0', - 'reference' => '6b179bff7c0863015aa699939e1dfe2bd4c97974', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-partner', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-password-checker' => array( - 'pretty_version' => 'v0.2.13', - 'version' => '0.2.13.0', - 'reference' => '16b88d370ca2f59b38e6c44bc37fc43e72090dad', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-password-checker', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-plans' => array( - 'pretty_version' => 'v0.2.10', - 'version' => '0.2.10.0', - 'reference' => '262dd36d110723f2fc940aabf88c510afaf537fc', - 'type' => 'library', - 'install_path' => __DIR__ . '/../automattic/jetpack-plans', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-plugins-installer' => array( - 'pretty_version' => 'v0.2.3', - 'version' => '0.2.3.0', - 'reference' => 'ec0e3b888ef33d4bd879de9a014ba20d771aca31', - '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-redirect' => array( - 'pretty_version' => 'v1.7.25', - 'version' => '1.7.25.0', - 'reference' => '67d7dce123d4af4fec4b4fe15e99aaad85308314', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-redirect', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-roles' => array( - 'pretty_version' => 'v1.4.23', - 'version' => '1.4.23.0', - 'reference' => 'f147b3e8061fc0de2a892ddc4f4156eb995545f9', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-roles', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-status' => array( - 'pretty_version' => 'v1.17.0', - 'version' => '1.17.0.0', - 'reference' => 'a16c59bb54cac04c579621efffa1ca1d5738c5cc', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-status', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-sync' => array( - 'pretty_version' => 'v1.47.4', - 'version' => '1.47.4.0', - 'reference' => '9c7f25eb8e63a9fbaa1639eaf2f68f46739e5cde', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-sync', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-transport-helper' => array( - 'pretty_version' => 'v0.1.4', - 'version' => '0.1.4.0', - 'reference' => '379cd4477b9b43f3765d2e8872e6610fd5126a01', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-transport-helper', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-waf' => array( - 'pretty_version' => 'v0.11.4', - 'version' => '0.11.4.0', - 'reference' => 'ec68a1429a7bb0ff8c5c4b51186319b86818d0b1', - '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 41da0a1f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/jetpack_autoload_classmap.php +++ /dev/null @@ -1,813 +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' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-autoloader.php' - ), - 'Autoloader_Handler' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-autoloader-handler.php' - ), - 'Autoloader_Locator' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-autoloader-locator.php' - ), - 'Automattic\\Jetpack\\A8c_Mc_Stats' => array( - 'version' => '1.4.20.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.2.19.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-admin-ui/src/class-admin-menu.php' - ), - 'Automattic\\Jetpack\\Assets' => array( - 'version' => '1.17.34.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-assets/src/class-assets.php' - ), - 'Automattic\\Jetpack\\Assets\\Logo' => array( - 'version' => '1.6.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-logo/src/class-logo.php' - ), - 'Automattic\\Jetpack\\Assets\\Semver' => array( - 'version' => '1.17.34.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-assets/src/class-semver.php' - ), - 'Automattic\\Jetpack\\Autoloader\\AutoloadFileWriter' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/AutoloadFileWriter.php' - ), - 'Automattic\\Jetpack\\Autoloader\\AutoloadGenerator' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/AutoloadGenerator.php' - ), - 'Automattic\\Jetpack\\Autoloader\\AutoloadProcessor' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/AutoloadProcessor.php' - ), - 'Automattic\\Jetpack\\Autoloader\\CustomAutoloaderPlugin' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/CustomAutoloaderPlugin.php' - ), - 'Automattic\\Jetpack\\Autoloader\\ManifestGenerator' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/ManifestGenerator.php' - ), - 'Automattic\\Jetpack\\Automatic_Install_Skin' => array( - 'version' => '0.2.3.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-plugins-installer/src/class-automatic-install-skin.php' - ), - 'Automattic\\Jetpack\\Composer\\Manager' => array( - 'version' => '1.1.10.0', - 'path' => $vendorDir . '/automattic/jetpack-composer-plugin/src/class-manager.php' - ), - 'Automattic\\Jetpack\\Composer\\Plugin' => array( - 'version' => '1.1.10.0', - 'path' => $vendorDir . '/automattic/jetpack-composer-plugin/src/class-plugin.php' - ), - 'Automattic\\Jetpack\\Config' => array( - 'version' => '1.15.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-config/src/class-config.php' - ), - 'Automattic\\Jetpack\\Connection\\Client' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-client.php' - ), - 'Automattic\\Jetpack\\Connection\\Connection_Notice' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-connection-notice.php' - ), - 'Automattic\\Jetpack\\Connection\\Error_Handler' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-error-handler.php' - ), - 'Automattic\\Jetpack\\Connection\\Initial_State' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-initial-state.php' - ), - 'Automattic\\Jetpack\\Connection\\Manager' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-manager.php' - ), - 'Automattic\\Jetpack\\Connection\\Manager_Interface' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/interface-manager.php' - ), - 'Automattic\\Jetpack\\Connection\\Nonce_Handler' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-nonce-handler.php' - ), - 'Automattic\\Jetpack\\Connection\\Package_Version' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-package-version.php' - ), - 'Automattic\\Jetpack\\Connection\\Package_Version_Tracker' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-package-version-tracker.php' - ), - 'Automattic\\Jetpack\\Connection\\Plugin' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-plugin.php' - ), - 'Automattic\\Jetpack\\Connection\\Plugin_Storage' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-plugin-storage.php' - ), - 'Automattic\\Jetpack\\Connection\\REST_Connector' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-rest-connector.php' - ), - 'Automattic\\Jetpack\\Connection\\Rest_Authentication' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-rest-authentication.php' - ), - 'Automattic\\Jetpack\\Connection\\Secrets' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-secrets.php' - ), - 'Automattic\\Jetpack\\Connection\\Server_Sandbox' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-server-sandbox.php' - ), - 'Automattic\\Jetpack\\Connection\\Tokens' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-tokens.php' - ), - 'Automattic\\Jetpack\\Connection\\Urls' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-urls.php' - ), - 'Automattic\\Jetpack\\Connection\\Utils' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-utils.php' - ), - 'Automattic\\Jetpack\\Connection\\Webhooks' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-webhooks.php' - ), - 'Automattic\\Jetpack\\Connection\\Webhooks\\Authorize_Redirect' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/webhooks/class-authorize-redirect.php' - ), - 'Automattic\\Jetpack\\Connection\\XMLRPC_Async_Call' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-async-call.php' - ), - 'Automattic\\Jetpack\\Connection\\XMLRPC_Connector' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-connector.php' - ), - 'Automattic\\Jetpack\\Constants' => array( - 'version' => '1.6.22.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-constants/src/class-constants.php' - ), - 'Automattic\\Jetpack\\CookieState' => array( - 'version' => '1.17.0.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-cookiestate.php' - ), - 'Automattic\\Jetpack\\Current_Plan' => array( - 'version' => '0.2.10.0', - 'path' => $vendorDir . '/automattic/jetpack-plans/src/class-current-plan.php' - ), - 'Automattic\\Jetpack\\Device_Detection' => array( - 'version' => '1.4.25.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-device-detection/src/class-device-detection.php' - ), - 'Automattic\\Jetpack\\Device_Detection\\User_Agent_Info' => array( - 'version' => '1.4.25.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-device-detection/src/class-user-agent-info.php' - ), - 'Automattic\\Jetpack\\Errors' => array( - 'version' => '1.17.0.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-errors.php' - ), - 'Automattic\\Jetpack\\Files' => array( - 'version' => '1.17.0.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-files.php' - ), - 'Automattic\\Jetpack\\Heartbeat' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-heartbeat.php' - ), - 'Automattic\\Jetpack\\IP\\Utils' => array( - 'version' => '0.1.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-ip/src/class-utils.php' - ), - 'Automattic\\Jetpack\\IdentityCrisis\\REST_Endpoints' => array( - 'version' => '0.8.40.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-identity-crisis/src/class-rest-endpoints.php' - ), - 'Automattic\\Jetpack\\IdentityCrisis\\UI' => array( - 'version' => '0.8.40.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-identity-crisis/src/class-ui.php' - ), - 'Automattic\\Jetpack\\Identity_Crisis' => array( - 'version' => '0.8.40.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-identity-crisis/src/class-identity-crisis.php' - ), - 'Automattic\\Jetpack\\JITMS\\JITM' => array( - 'version' => '2.3.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-jitm/src/class-jitm.php' - ), - 'Automattic\\Jetpack\\JITMS\\Post_Connection_JITM' => array( - 'version' => '2.3.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-jitm/src/class-post-connection-jitm.php' - ), - 'Automattic\\Jetpack\\JITMS\\Pre_Connection_JITM' => array( - 'version' => '2.3.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-jitm/src/class-pre-connection-jitm.php' - ), - 'Automattic\\Jetpack\\JITMS\\Rest_Api_Endpoints' => array( - 'version' => '2.3.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-jitm/src/class-rest-api-endpoints.php' - ), - 'Automattic\\Jetpack\\Licensing' => array( - 'version' => '1.8.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-licensing/src/class-licensing.php' - ), - 'Automattic\\Jetpack\\Licensing\\Endpoints' => array( - 'version' => '1.8.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-licensing/src/class-endpoints.php' - ), - 'Automattic\\Jetpack\\Modules' => array( - 'version' => '1.17.0.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-modules.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Hybrid_Product' => array( - 'version' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-hybrid-product.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Initializer' => array( - 'version' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-initializer.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Module_Product' => array( - 'version' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-module-product.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Product' => array( - 'version' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products' => array( - 'version' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-products.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Anti_Spam' => array( - 'version' => '2.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' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-backup.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Boost' => array( - 'version' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-boost.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Crm' => array( - 'version' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-crm.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Extras' => array( - 'version' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-extras.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Protect' => array( - 'version' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-protect.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Scan' => array( - 'version' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-scan.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Search' => array( - 'version' => '2.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' => '2.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' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-security.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Social' => array( - 'version' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-social.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Videopress' => array( - 'version' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-videopress.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\REST_Products' => array( - 'version' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-products.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\REST_Purchases' => array( - 'version' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-purchases.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Wpcom_Products' => array( - 'version' => '2.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-wpcom-products.php' - ), - 'Automattic\\Jetpack\\Partner' => array( - 'version' => '1.7.23.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-partner/src/class-partner.php' - ), - 'Automattic\\Jetpack\\Partner_Coupon' => array( - 'version' => '1.7.23.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-partner/src/class-partner-coupon.php' - ), - 'Automattic\\Jetpack\\Password_Checker' => array( - 'version' => '0.2.13.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-password-checker/src/class-password-checker.php' - ), - 'Automattic\\Jetpack\\Paths' => array( - 'version' => '1.17.0.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-paths.php' - ), - 'Automattic\\Jetpack\\Plans' => array( - 'version' => '0.2.10.0', - 'path' => $vendorDir . '/automattic/jetpack-plans/src/class-plans.php' - ), - 'Automattic\\Jetpack\\Plugins_Installer' => array( - 'version' => '0.2.3.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\\Extension_Model' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/models/class-extension-model.php' - ), - 'Automattic\\Jetpack\\Protect\\Plan' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/class-plan.php' - ), - 'Automattic\\Jetpack\\Protect\\Protect_Status' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/class-protect-status.php' - ), - 'Automattic\\Jetpack\\Protect\\REST_Controller' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/class-rest-controller.php' - ), - 'Automattic\\Jetpack\\Protect\\Scan_Status' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/class-scan-status.php' - ), - 'Automattic\\Jetpack\\Protect\\Site_Health' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/class-site-health.php' - ), - 'Automattic\\Jetpack\\Protect\\Status' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/class-status.php' - ), - 'Automattic\\Jetpack\\Protect\\Status_Model' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/models/class-status-model.php' - ), - 'Automattic\\Jetpack\\Protect\\Threat_Model' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/models/class-threat-model.php' - ), - 'Automattic\\Jetpack\\Protect\\Threats' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/class-threats.php' - ), - 'Automattic\\Jetpack\\Redirect' => array( - 'version' => '1.7.25.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-redirect/src/class-redirect.php' - ), - 'Automattic\\Jetpack\\Roles' => array( - 'version' => '1.4.23.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-roles/src/class-roles.php' - ), - 'Automattic\\Jetpack\\Status' => array( - 'version' => '1.17.0.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-status.php' - ), - 'Automattic\\Jetpack\\Status\\Cache' => array( - 'version' => '1.17.0.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-cache.php' - ), - 'Automattic\\Jetpack\\Status\\Host' => array( - 'version' => '1.17.0.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-host.php' - ), - 'Automattic\\Jetpack\\Status\\Visitor' => array( - 'version' => '1.17.0.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-visitor.php' - ), - 'Automattic\\Jetpack\\Sync\\Actions' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-actions.php' - ), - 'Automattic\\Jetpack\\Sync\\Codec_Interface' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/interface-codec.php' - ), - 'Automattic\\Jetpack\\Sync\\Data_Settings' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-data-settings.php' - ), - 'Automattic\\Jetpack\\Sync\\Dedicated_Sender' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-dedicated-sender.php' - ), - 'Automattic\\Jetpack\\Sync\\Default_Filter_Settings' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-default-filter-settings.php' - ), - 'Automattic\\Jetpack\\Sync\\Defaults' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-defaults.php' - ), - 'Automattic\\Jetpack\\Sync\\Functions' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-functions.php' - ), - 'Automattic\\Jetpack\\Sync\\Health' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-health.php' - ), - 'Automattic\\Jetpack\\Sync\\JSON_Deflate_Array_Codec' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-json-deflate-array-codec.php' - ), - 'Automattic\\Jetpack\\Sync\\Listener' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-listener.php' - ), - 'Automattic\\Jetpack\\Sync\\Lock' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-lock.php' - ), - 'Automattic\\Jetpack\\Sync\\Main' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-main.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-modules.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Attachments' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-attachments.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Callables' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-callables.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Comments' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-comments.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Constants' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-constants.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Full_Sync' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-full-sync.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Full_Sync_Immediately' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-full-sync-immediately.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Import' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-import.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Menus' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-menus.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Meta' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-meta.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Module' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-module.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Network_Options' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-network-options.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Options' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-options.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Plugins' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-plugins.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Posts' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-posts.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Protect' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-protect.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Search' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-search.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Stats' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-stats.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Term_Relationships' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-term-relationships.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Terms' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-terms.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Themes' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-themes.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Updates' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-updates.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Users' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-users.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\WP_Super_Cache' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-wp-super-cache.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\WooCommerce' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-woocommerce.php' - ), - 'Automattic\\Jetpack\\Sync\\Package_Version' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-package-version.php' - ), - 'Automattic\\Jetpack\\Sync\\Queue' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-queue.php' - ), - 'Automattic\\Jetpack\\Sync\\Queue_Buffer' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-queue-buffer.php' - ), - 'Automattic\\Jetpack\\Sync\\REST_Endpoints' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-rest-endpoints.php' - ), - 'Automattic\\Jetpack\\Sync\\REST_Sender' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-rest-sender.php' - ), - 'Automattic\\Jetpack\\Sync\\Replicastore' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-replicastore.php' - ), - 'Automattic\\Jetpack\\Sync\\Replicastore\\Table_Checksum' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum.php' - ), - 'Automattic\\Jetpack\\Sync\\Replicastore\\Table_Checksum_Usermeta' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum-usermeta.php' - ), - 'Automattic\\Jetpack\\Sync\\Replicastore\\Table_Checksum_Users' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum-users.php' - ), - 'Automattic\\Jetpack\\Sync\\Replicastore_Interface' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/interface-replicastore.php' - ), - 'Automattic\\Jetpack\\Sync\\Sender' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-sender.php' - ), - 'Automattic\\Jetpack\\Sync\\Server' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-server.php' - ), - 'Automattic\\Jetpack\\Sync\\Settings' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-settings.php' - ), - 'Automattic\\Jetpack\\Sync\\Simple_Codec' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-simple-codec.php' - ), - 'Automattic\\Jetpack\\Sync\\Users' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-users.php' - ), - 'Automattic\\Jetpack\\Sync\\Utils' => array( - 'version' => '1.47.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-utils.php' - ), - 'Automattic\\Jetpack\\Terms_Of_Service' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-terms-of-service.php' - ), - 'Automattic\\Jetpack\\Tracking' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-tracking.php' - ), - 'Automattic\\Jetpack\\Transport_Helper\\Helper_Script_Manager' => array( - 'version' => '0.1.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-transport-helper/src/class-helper-script-manager.php' - ), - 'Automattic\\Jetpack\\Transport_Helper\\Package_Version' => array( - 'version' => '0.1.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-transport-helper/src/class-package-version.php' - ), - 'Automattic\\Jetpack\\Transport_Helper\\REST_Controller' => array( - 'version' => '0.1.4.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.11.4.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.11.4.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.11.4.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.11.4.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.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-transient-cleanup.php' - ), - 'Automattic\\Jetpack\\Waf\\CLI' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-cli.php' - ), - 'Automattic\\Jetpack\\Waf\\File_System_Exception' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/exceptions/class-file-system-exception.php' - ), - 'Automattic\\Jetpack\\Waf\\REST_Controller' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-rest-controller.php' - ), - 'Automattic\\Jetpack\\Waf\\Rules_API_Exception' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/exceptions/class-rules-api-exception.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Compatibility' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-compatibility.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Constants' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-constants.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Exception' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/exceptions/class-waf-exception.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Initializer' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-initializer.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Operators' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-operators.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Request' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-request.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Rules_Manager' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-rules-manager.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Runner' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-runner.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Runtime' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-runtime.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Standalone_Bootstrap' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-standalone-bootstrap.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Stats' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-stats.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Transforms' => array( - 'version' => '0.11.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-transforms.php' - ), - 'Container' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-container.php' - ), - 'Hook_Manager' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-hook-manager.php' - ), - 'Jetpack_IXR_Client' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-ixr-client.php' - ), - 'Jetpack_IXR_ClientMulticall' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-ixr-clientmulticall.php' - ), - 'Jetpack_Options' => array( - 'version' => '1.51.7.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' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-signature.php' - ), - 'Jetpack_Tracks_Client' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-tracks-client.php' - ), - 'Jetpack_Tracks_Event' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-tracks-event.php' - ), - 'Jetpack_XMLRPC_Server' => array( - 'version' => '1.51.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-xmlrpc-server.php' - ), - 'Latest_Autoloader_Guard' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-latest-autoloader-guard.php' - ), - 'Manifest_Reader' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-manifest-reader.php' - ), - 'PHP_Autoloader' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-php-autoloader.php' - ), - 'Path_Processor' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-path-processor.php' - ), - 'Plugin_Locator' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-plugin-locator.php' - ), - 'Plugins_Handler' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-plugins-handler.php' - ), - 'Shutdown_Handler' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-shutdown-handler.php' - ), - 'Version_Loader' => array( - 'version' => '2.11.18.0', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-version-loader.php' - ), - 'Version_Selector' => array( - 'version' => '2.11.18.0', - '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 b8c225a9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/jetpack_autoload_filemap.php +++ /dev/null @@ -1,21 +0,0 @@ - array( - 'version' => '1.17.34.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-assets/actions.php' - ), - '590147edb63acb03b2852d5c4db13ce8' => array( - 'version' => '0.1.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-transport-helper/actions.php' - ), - '3d45c7e6a7f0e71849e33afe4b3b3ede' => array( - 'version' => '0.11.4.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 d673084e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/platform_check.php +++ /dev/null @@ -1,26 +0,0 @@ -= 50509)) { - $issues[] = 'Your Composer dependencies require a PHP version ">= 5.5.9". 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 c197e59c..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 867582b3..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. - * - * @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 ( ! $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 a2f569aa..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-autoloader.php +++ /dev/null @@ -1,90 +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 ) ); - - // 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 4aba6d96..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 6aa091be..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 403163cd..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-latest-autoloader-guard.php +++ /dev/null @@ -1,86 +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; - } -} 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 afb7a3ae..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 4f825f38..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 ( 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 a710929c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-php-autoloader.php +++ /dev/null @@ -1,93 +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; - } - - $file = $jetpack_autoloader_loader->find_class_file( $class_name ); - if ( ! isset( $file ) ) { - return false; - } - - 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 0fd4a278..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-plugin-locator.php +++ /dev/null @@ -1,156 +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( dirname( __DIR__ ) ); - - // 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 ) { - // phpcs:disable WordPress.Security.NonceVerification.Recommended - - /** - * 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; - } - - // phpcs:enable WordPress.Security.NonceVerification.Recommended - 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 e46547b3..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 4bd9dfb6..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 42f60237..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-version-loader.php +++ /dev/null @@ -1,164 +0,0 @@ -version_selector = $version_selector; - $this->classmap = $classmap; - $this->psr4_map = $psr4_map; - $this->filemap = $filemap; - } - - /** - * 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( - isset( $this->classmap[ $class_name ] ) ? $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 ( ! isset( $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 9621ddd2..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 7886218d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/CHANGELOG.md +++ /dev/null @@ -1,111 +0,0 @@ -##### [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/CONTRIBUTING.md b/wp-content/upgrade-temp-backup/plugins/menu-icons/CONTRIBUTING.md deleted file mode 100644 index 36b5b5b1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/CONTRIBUTING.md +++ /dev/null @@ -1,13 +0,0 @@ -## Releasing - -This repository uses conventional [changelog commit](https://github.com/Codeinwp/conventional-changelog-simple-preset) messages to trigger release - -How to release a new version: - -- Clone the master branch -- Do your changes -- Send a PR to master and merge it using the following subject message - - `release: ` - for patch release - - `release(minor): ` - for minor release - - `release(major): ` - for major release - The release notes will inherit the body of the commit message which triggered the release. For more details check the [simple-preset](https://github.com/Codeinwp/conventional-changelog-simple-preset) that we use. \ No newline at end of file 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 da1c6c2b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/dashboard-notice.css +++ /dev/null @@ -1,44 +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; - width: 105px; - 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 cc3d61b8..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;width:105px;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 7bfb0952..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/front.php +++ /dev/null @@ -1,514 +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; - } - - $title_class = ! 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 = '' ); - } - - ?> - . ?> - - - - -
        - - - - - ` 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 3caf4427..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-backup-codes.php +++ /dev/null @@ -1,402 +0,0 @@ - WP_REST_Server::CREATABLE, - 'callback' => array( $this, 'rest_generate_codes' ), - 'permission_callback' => function( $request ) { - return current_user_can( 'edit_user', $request['user_id'] ); - }, - 'args' => array( - 'user_id' => array( - 'required' => true, - 'type' => 'number', - ), - '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 ); - } - - for ( $i = 0; $i < $num_codes; $i++ ) { - $code = $this->get_code(); - $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 Backup 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.', '%s unused codes remaining.', $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 Backup Codes provider 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'; - ?> -

        -

        - - -

        - 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 ); - } -} 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 f1625dce..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-dummy.php +++ /dev/null @@ -1,99 +0,0 @@ - -

        - get_code(); - - 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. - * - * @param integer $token_ttl Token time-to-live in seconds. - * @param integer $user_id User ID. - */ - return (int) apply_filters( 'two_factor_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 ); - } - - 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 ) { - 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 false; - } - - 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 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 330451c2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-fido-u2f.php +++ /dev/null @@ -1,397 +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; - } -} 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 f7c84ecb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-provider.php +++ /dev/null @@ -1,125 +0,0 @@ -get_label() ); - } - - /** - * 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 ); - - /** - * 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; - } -} 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 12a80763..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-totp.php +++ /dev/null @@ -1,768 +0,0 @@ - WP_REST_Server::DELETABLE, - 'callback' => array( $this, 'rest_delete_totp' ), - 'permission_callback' => function( $request ) { - return current_user_can( 'edit_user', $request['user_id'] ); - }, - 'args' => array( - 'user_id' => array( - 'required' => true, - 'type' => 'number', - ), - ), - ), - array( - 'methods' => WP_REST_Server::CREATABLE, - 'callback' => array( $this, 'rest_setup_totp' ), - 'permission_callback' => function( $request ) { - return current_user_can( 'edit_user', $request['user_id'] ); - }, - 'args' => array( - 'user_id' => array( - 'required' => true, - 'type' => 'number', - ), - '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( 'Time Based One-Time Password (TOTP)', 'Provider Label', '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 ); - - 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 $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 false - * - * @codeCoverageIgnore - */ - public function user_two_factor_options( $user ) { - if ( ! isset( $user->ID ) ) { - return false; - } - - $key = $this->get_user_totp_key( $user->ID ); - - wp_enqueue_script( 'two-factor-qr-code-generator' ); - - ?> -
        - 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; - } -} 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 0aa252cb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/readme.txt +++ /dev/null @@ -1,52 +0,0 @@ -=== Two-Factor === -Contributors: georgestephanis, valendesigns, stevenkword, extendwings, sgrant, aaroncampbell, johnbillion, stevegrunwell, netweb, kasparsd, alihusnainarshad, passoniate -Tags: two factor, two step, authentication, login, totp, fido u2f, u2f, email, backup codes, 2fa, yubikey -Requires at least: 4.3 -Tested up to: 6.0 -Requires PHP: 5.6 -Stable tag: 0.8.1 - -Enable Two-Factor Authentication using time-based one-time passwords (OTP, Google Authenticator), Universal 2nd Factor (FIDO U2F, YubiKey), 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_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_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. - -== 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 c4a64c09..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/two-factor.php +++ /dev/null @@ -1,48 +0,0 @@ - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/BrowserCache_Plugin.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/BrowserCache_Plugin.php index 810b1286..71c4c6ca 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/BrowserCache_Plugin.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/BrowserCache_Plugin.php @@ -377,7 +377,7 @@ class BrowserCache_Plugin { $menu_items['20190.browsercache'] = array( 'id' => 'w3tc_flush_browsercache', 'parent' => 'w3tc_flush', - 'title' => __( 'Browser Cache: Update Media Query String', 'w3-total-cache' ), + 'title' => __( 'Browser Cache', 'w3-total-cache' ), 'href' => wp_nonce_url( admin_url( 'admin.php?page=w3tc_dashboard&w3tc_flush_browser_cache' ), 'w3tc' ) diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheFlush.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheFlush.php index 1ce276eb..80930b32 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheFlush.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheFlush.php @@ -62,7 +62,7 @@ class CacheFlush { * Flushes object cache */ function objectcache_flush() { - if ( $this->_config->get_boolean( 'objectcache.enabled' ) ) { + if ( $this->_config->getf_boolean( 'objectcache.enabled' ) ) { $this->_executor->objectcache_flush(); } } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheFlush_Locally.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheFlush_Locally.php index c0a4bb49..37e22ab0 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheFlush_Locally.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheFlush_Locally.php @@ -188,7 +188,7 @@ class CacheFlush_Locally { add_action( 'w3tc_flush_all', array( $this, 'dbcache_flush' ), 100, 2 ); - if ( $config->get_boolean( 'objectcache.enabled' ) ) + if ( $config->getf_boolean( 'objectcache.enabled' ) ) add_action( 'w3tc_flush_all', array( $this, 'objectcache_flush' ), 200, 1 ); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheGroups_Plugin_Admin.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheGroups_Plugin_Admin.php index 035ae70f..63e9a4c4 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheGroups_Plugin_Admin.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheGroups_Plugin_Admin.php @@ -70,9 +70,6 @@ class CacheGroups_Plugin_Admin extends Base_Page_Settings { // Load view. require W3TC_DIR . '/CacheGroups_Plugin_Admin_View.php'; - - // Footer. - require W3TC_INC_DIR . '/options/common/footer.php'; } /** @@ -99,7 +96,7 @@ class CacheGroups_Plugin_Admin extends Base_Page_Settings { $theme = isset( $group_config['theme'] ) ? trim( $group_config['theme'] ) : 'default'; $enabled = isset( $group_config['enabled'] ) ? (bool) $group_config['enabled'] : true; $redirect = isset( $group_config['redirect'] ) ? trim( $group_config['redirect'] ) : ''; - $agents = isset( $group_config['agents'] ) ? explode( "\r\n", trim( $group_config['agents'] ) ) : array(); + $agents = isset( $group_config['agents'] ) ? Util_Environment::textarea_to_array( $group_config['agents'] ) : array(); $mobile_groups[ $group ] = array( 'theme' => $theme, @@ -151,9 +148,12 @@ class CacheGroups_Plugin_Admin extends Base_Page_Settings { $group_config ); - $mobile_groups[ $group ]['agents'] = array_unique( $mobile_groups[ $group ]['agents'] ); - $mobile_groups[ $group ]['agents'] = array_map( 'strtolower', $mobile_groups[ $group ]['agents'] ); - + $mobile_groups[ $group ]['agents'] = array_unique( + array_map( + 'strtolower', + $mobile_groups[ $group ]['agents'] + ) + ); sort( $mobile_groups[ $group ]['agents'] ); } @@ -183,7 +183,7 @@ class CacheGroups_Plugin_Admin extends Base_Page_Settings { $theme = isset( $group_config['theme'] ) ? trim( $group_config['theme'] ) : 'default'; $enabled = isset( $group_config['enabled'] ) ? (bool) $group_config['enabled'] : true; $redirect = isset( $group_config['redirect'] ) ? trim( $group_config['redirect'] ) : ''; - $referrers = isset( $group_config['referrers'] ) ? explode( "\r\n", trim( $group_config['referrers'] ) ) : array(); + $referrers = isset( $group_config['referrers'] ) ? Util_Environment::textarea_to_array( $group_config['referrers'] ) : array(); $referrer_groups[ $group ] = array( 'theme' => $theme, @@ -209,9 +209,12 @@ class CacheGroups_Plugin_Admin extends Base_Page_Settings { $group_config ); - $referrer_groups[ $group ]['referrers'] = array_unique( $referrer_groups[ $group ]['referrers'] ); - $referrer_groups[ $group ]['referrers'] = array_map( 'strtolower', $referrer_groups[ $group ]['referrers'] ); - + $referrer_groups[ $group ]['referrers'] = array_unique( + array_map( + 'strtolower', + $referrer_groups[ $group ]['referrers'] + ) + ); sort( $referrer_groups[ $group ]['referrers'] ); } @@ -238,15 +241,9 @@ class CacheGroups_Plugin_Admin extends Base_Page_Settings { $group = trim( $group, '_' ); if ( $group ) { - $enabled = isset( $group_config['enabled'] ) ? - (bool) $group_config['enabled'] : false; - $cache = isset( $group_config['cache'] ) ? - (bool) $group_config['cache'] : false; - $cookies = isset( $group_config['cookies'] ) ? - explode( "\r\n", trim( $group_config['cookies'] ) ) : array(); - $cookies = array_unique( $cookies ); - - sort( $cookies ); + $enabled = isset( $group_config['enabled'] ) ? (bool) $group_config['enabled'] : false; + $cache = isset( $group_config['cache'] ) ? (bool) $group_config['cache'] : false; + $cookies = isset( $group_config['cookies'] ) ? Util_Environment::textarea_to_array( $group_config['cookies'] ) : array(); $cookiegroups[ $group ] = array( 'enabled' => $enabled, diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheGroups_Plugin_Admin_View.js b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheGroups_Plugin_Admin_View.js index 6a213a84..ed46e06a 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheGroups_Plugin_Admin_View.js +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheGroups_Plugin_Admin_View.js @@ -7,62 +7,123 @@ */ jQuery(function() { + jQuery(document).on( 'submit', '#cachegroups_form', function() { + var error = []; - // User agent groups. + var mobile_groups = jQuery('#mobile_groups li'); + mobile_groups.each(function(index, mobile_group) { + var $mobile_group = jQuery(mobile_group); - jQuery('#mobile_form').on( 'submit', function() { - var error = false; + if ($mobile_group.find('.mobile_group_enabled:checked').length) { + var name = $mobile_group.find('.mobile_group').text(); + var theme = $mobile_group.find('select').val(); + var redirect = $mobile_group.find('input[type=text]').val(); + var agents = $mobile_group.find('textarea').val().split("\n").filter(function(line){return line.trim()!==''}).map(function(line){return line.trim();}); - jQuery('#mobile_groups li').each(function() { - if (jQuery(this).find(':checked').length) { - var group = jQuery(this).find('.mobile_group').text(); - var theme = jQuery(this).find(':selected').val(); - var redirect = jQuery(this).find('input[type=text]').val(); - var agents = jQuery.trim(jQuery(this).find('textarea').val()).split("\n"); + mobile_groups.not($mobile_group).each(function(index, compare_mobile_group) { + var $compare_mobile_group = jQuery(compare_mobile_group); - jQuery('#mobile_groups li').each(function() { - if (jQuery(this).find(':checked').length) { - var compare_group = jQuery(this).find('.mobile_group').text(); - if (compare_group != group) { - var compare_theme = jQuery(this).find(':selected').val(); - var compare_redirect = jQuery(this).find('input[type=text]').val(); - var compare_agents = jQuery.trim(jQuery(this).find('textarea').val()).split("\n"); + if ($compare_mobile_group.find('.mobile_group_enabled:checked').length) { + var compare_name = $compare_mobile_group.find('.mobile_group').text(); + var compare_theme = $compare_mobile_group.find('select').val(); + var compare_redirect = $compare_mobile_group.find('input[type=text]').val(); + var compare_agents = $compare_mobile_group.find('textarea').val().split("\n").filter(function(line){return line.trim()!==''}).map(function(line){return line.trim();}); - if (compare_redirect == '' && redirect == '' && compare_theme != '' && compare_theme == theme) { - alert('Duplicate theme "' + compare_theme + '" found in the group "' + group + '".'); - error = true; - return false; - } + var groups = sort_array([name, compare_name]); - if (compare_redirect != '' && compare_redirect == redirect) { - alert('Duplicate redirect "' + compare_redirect + '" found in the group "' + group + '".'); - error = true; - return false; - } + if (compare_redirect === '' && redirect === '' && compare_theme !== '' && compare_theme === theme) { + error.push('Duplicate theme "' + compare_theme + '" found in the user agent groups "' + groups[0] + '" and "' + groups[1] + '"'); + } - jQuery.each(compare_agents, function(index, value) { - if (jQuery.inArray(value, agents) != -1) { - alert('Duplicate stem "' + value + '" found in the group "' + compare_group + '".'); - error = true; - return false; - } - }); - } - } - }); + if (compare_redirect !== '' && compare_redirect === redirect) { + error.push('Duplicate redirect "' + compare_redirect + '" found in the user agent groups "' + groups[0] + '" and "' + groups[1] + '"'); + } - if (error) { - return false; - } - } - }); + jQuery.each(compare_agents, function(index, value) { + if (jQuery.inArray(value, agents) !== -1) { + error.push('Duplicate stem "' + value + '" found in the user agent groups "' + groups[0] + '" and "' + groups[1] + '"'); + } + }); + } + }); + } + }); - if (error) { + var referrer_groups = jQuery('#referrer_groups li'); + referrer_groups.each(function(index, referrer_group) { + var $referrer_group = jQuery(referrer_group); + + if ($referrer_group.find('.referrer_group_enabled:checked').length) { + var name = $referrer_group.find('.referrer_group').text(); + var theme = $referrer_group.find('select').val(); + var redirect = $referrer_group.find('input[type=text]').val(); + var agents = $referrer_group.find('textarea').val().split("\n").filter(function(line){return line.trim()!==''}).map(function(line){return line.trim();}); + + referrer_groups.not($referrer_group).each(function(index, compare_referrer_group) { + var $compare_referrer_group = jQuery(compare_referrer_group); + + if ($compare_referrer_group.find('.referrer_group_enabled:checked').length) { + var compare_name = $compare_referrer_group.find('.referrer_group').text(); + var compare_theme = $compare_referrer_group.find('select').val(); + var compare_redirect = $compare_referrer_group.find('input[type=text]').val(); + var compare_agents = $compare_referrer_group.find('textarea').val().split("\n").filter(function(line){return line.trim()!==''}).map(function(line){return line.trim();}); + + var groups = sort_array([name, compare_name]); + + if (compare_redirect === '' && redirect === '' && compare_theme !== '' && compare_theme === theme) { + error.push('Duplicate theme "' + compare_theme + '" found in the referrer groups "' + groups[0] + '" and "' + groups[1] + '"'); + } + + if (compare_redirect !== '' && compare_redirect === redirect) { + error.push('Duplicate redirect "' + compare_redirect + '" found in the referrer groups "' + groups[0] + '" and "' + groups[1] + '"'); + } + + jQuery.each(compare_agents, function(index, value) { + if (jQuery.inArray(value, agents) !== -1) { + error.push('Duplicate stem "' + value + '" found in the referrer groups "' + groups[0] + '" and "' + groups[1] + '"'); + } + }); + } + }); + } + }); + + var cookiegroups = jQuery('#cookiegroups li'); + cookiegroups.each(function(index, cookiegroup) { + var $cookiegroup = jQuery(cookiegroup); + + if ($cookiegroup.find('.cookiegroup_enabled:checked').length) { + var name = $cookiegroup.find('.cookiegroup_name').text(); + var agents = $cookiegroup.find('textarea').val().split("\n").filter(function(line){return line.trim()!==''}).map(function(line){return line.trim();}); + console.log(agents); + cookiegroups.not($cookiegroup).each(function(index, compare_cookiegroup) { + var $compare_cookiegroup = jQuery(compare_cookiegroup); + + if ($compare_cookiegroup.find('.cookiegroup_enabled:checked').length) { + var compare_name = $compare_cookiegroup.find('.cookiegroup_name').text(); + var compare_agents = $compare_cookiegroup.find('textarea').val().split("\n").filter(function(line){return line.trim()!==''}).map(function(line){return line.trim();}); + console.log(compare_agents); + var groups = sort_array([name, compare_name]); + + jQuery.each(compare_agents, function(index, value) { + if (jQuery.inArray(value, agents) !== -1) { + error.push('Duplicate stem "' + value + '" found in the cookie groups "' + groups[0] + '" and "' + groups[1] + '"'); + } + }); + } + }); + } + }); + + if (error.length !== 0) { + alert(unique_array(error).join('\n')); return false; } + + return true; }); - jQuery('#mobile_add').on( 'click', function() { + jQuery(document).on( 'click', '#mobile_add', function() { var group = prompt('Enter group name (only "0-9", "a-z", "_" symbols are allowed).'); if (group !== null) { @@ -83,7 +144,46 @@ jQuery(function() { }); if (!exists) { - var li = jQuery('
      • Group name:' + (jQuery('#mobile_groups li').length + 1) + '. ' + group + '

        Assign this group of user agents to a specific them. Leaving this option "Active Theme" allows any plugins you have (e.g. mobile plugins) to properly handle requests for these user agents. If the "redirect users to" field is not empty, this setting is ignored.

        A 302 redirect is used to send this group of users to another hostname (domain); recommended if a 3rd party service provides a mobile version of your site.

        Specify the user agents for this group.

      • '); + var li = jQuery('
      • ' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '
        Group name:' + + '' + (jQuery('#mobile_groups li').length + 1) + '. ' + + '' + group + ' ' + + '' + + '
        ' + + '' + + '' + + '
        ' + + '' + + '

        Assign this group of user agents to a specific them. Leaving this option "Active Theme" allows any plugins you have (e.g. mobile plugins) to properly handle requests for these user agents. If the "redirect users to" field is not empty, this setting is ignored.

        ' + + '
        ' + + '' + + '

        A 302 redirect is used to send this group of users to another hostname (domain); recommended if a 3rd party service provides a mobile version of your site.

        ' + + '
        ' + + '' + + '

        Specify the user agents for this group.

        ' + + '
        ' + + '
      • '); var select = li.find('select'); jQuery.each(mobile_themes, function(index, value) { @@ -101,7 +201,7 @@ jQuery(function() { } }); - jQuery('.mobile_delete').on('click', function () { + jQuery(document).on('click', '.mobile_delete', function () { if (confirm('Are you sure want to delete this group?')) { jQuery(this).parents('#mobile_groups li').remove(); w3tc_mobile_groups_clear(); @@ -113,59 +213,7 @@ jQuery(function() { // Referrer groups. - jQuery('#referrer_form').on( 'submit', function() { - var error = false; - - jQuery('#referrer_groups li').each(function() { - if (jQuery(this).find(':checked').length) { - var group = jQuery(this).find('.referrer_group').text(); - var theme = jQuery(this).find(':selected').val(); - var redirect = jQuery(this).find('input[type=text]').val(); - var agents = jQuery.trim(jQuery(this).find('textarea').val()).split("\n"); - - jQuery('#referrer_groups li').each(function() { - if (jQuery(this).find(':checked').length) { - var compare_group = jQuery(this).find('.referrer_group').text(); - if (compare_group != group) { - var compare_theme = jQuery(this).find(':selected').val(); - var compare_redirect = jQuery(this).find('input[type=text]').val(); - var compare_agents = jQuery.trim(jQuery(this).find('textarea').val()).split("\n"); - - if (compare_redirect == '' && redirect == '' && compare_theme != '' && compare_theme == theme) { - alert('Duplicate theme "' + compare_theme + '" found in the group "' + group + '".'); - error = true; - return false; - } - - if (compare_redirect != '' && compare_redirect == redirect) { - alert('Duplicate redirect "' + compare_redirect + '" found in the group "' + group + '".'); - error = true; - return false; - } - - jQuery.each(compare_agents, function(index, value) { - if (jQuery.inArray(value, agents) != -1) { - alert('Duplicate stem "' + value + '" found in the group "' + compare_group + '".'); - error = true; - return false; - } - }); - } - } - }); - - if (error) { - return false; - } - } - }); - - if (error) { - return false; - } - }); - - jQuery('#referrer_add').on( 'click', function() { + jQuery(document).on( 'click', '#referrer_add', function() { var group = prompt('Enter group name (only "0-9", "a-z", "_" symbols are allowed).'); if (group !== null) { @@ -186,7 +234,48 @@ jQuery(function() { }); if (!exists) { - var li = jQuery('
      • Group name:' + (jQuery('#referrer_groups li').length + 1) + '. ' + group + '

        Assign this group of referrers to a specific them. Leaving this option "Active Theme" allows any plugins you have (e.g. referrer plugins) to properly handle requests for these referrers. If the "redirect users to" field is not empty, this setting is ignored.

        A 302 redirect is used to send this group of users to another hostname (domain); recommended if a 3rd party service provides a referrer version of your site.

        Specify the referrers for this group.

      • '); + var li = jQuery('
      • ' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '' + + '
        Group name:' + + '' + (jQuery('#referrer_groups li').length + 1) + '. ' + + '' + group + ' ' + + '' + + '
        ' + + '' + + '' + + '' + + '' + + '
        ' + + '' + + '

        Assign this group of referrers to a specific them. Leaving this option "Active Theme" allows any plugins you have (e.g. referrer plugins) to properly handle requests for these referrers. If the "redirect users to" field is not empty, this setting is ignored.

        ' + + '
        ' + + '' + + '

        A 302 redirect is used to send this group of users to another hostname (domain); recommended if a 3rd party service provides a referrer version of your site.

        ' + + '
        ' + + '' + + '

        Specify the referrers for this group.

        ' + + '
        ' + + '
      • '); var select = li.find('select'); jQuery.each(referrer_themes, function(index, value) { @@ -204,7 +293,7 @@ jQuery(function() { } }); - jQuery('.referrer_delete').on('click', function () { + jQuery(document).on('click', '.referrer_delete', function () { if (confirm('Are you sure want to delete this group?')) { jQuery(this).parents('#referrer_groups li').remove(); w3tc_referrer_groups_clear(); @@ -216,7 +305,7 @@ jQuery(function() { // Cookie groups. - jQuery( '#w3tc_cookiegroup_add' ).on( 'click', function() { + jQuery(document).on( 'click', '#w3tc_cookiegroup_add', function() { var group = prompt('Enter group name (only "0-9", "a-z", "_" symbols are allowed).'); if (group !== null) { @@ -241,27 +330,32 @@ jQuery(function() { '' + '' + '' + - '' + + '' + + '' + '' + '' + '' + '' + + '' + + '' + '' + '' + '' + '' + + '' + + '' + '' + '' + - '' + - '
        Group name:' + (jQuery('#cookiegroups li').length + 1) + '. ' + + '' + + '' + (jQuery('#cookiegroups li').length + 1) + '. ' + '' + group + ' ' + - '
        ' + - '
        ' + - '
        ' + - '

        Specify the cookies for this group. Values like \'cookie\', \'cookie=value\', and cookie[a-z]+=value[a-z]+are supported. Remember to escape special characters like spaces, dots or dashes with a backslash. Regular expressions are also supported.

        '); + '' + + '' + + '

        Specify the cookies for this group. Values like \'cookie\', \'cookie=value\', and cookie[a-z]+=value[a-z]+are supported. Remember to escape special characters like spaces, dots or dashes with a backslash. Regular expressions are also supported.

        ' + + '' + + '' + + '' + + ''); var select = li.find('select'); jQuery('#cookiegroups').append(li); @@ -275,7 +369,7 @@ jQuery(function() { } }); - jQuery('.w3tc_cookiegroup_delete').on( 'click', function () { + jQuery(document).on( 'click', '.w3tc_cookiegroup_delete', function () { if (confirm('Are you sure want to delete this group?')) { jQuery(this).parents('#cookiegroups li').remove(); w3tc_cookiegroups_clear(); @@ -322,3 +416,10 @@ function w3tc_cookiegroups_clear() { jQuery('#cookiegroups_empty').hide(); } } +function unique_array(array) { + return jQuery.grep(array,function(el,i){return i === jQuery.inArray(el,array)}); +} + +function sort_array(array) { + return array.sort(); +} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheGroups_Plugin_Admin_View.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheGroups_Plugin_Admin_View.php index 1aa7f738..1cd03412 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheGroups_Plugin_Admin_View.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/CacheGroups_Plugin_Admin_View.php @@ -21,8 +21,9 @@ if ( ! defined( 'W3TC' ) ) { ?>
        + - +
        -

        Total Cache Image Service

        +

        Total Cache WebP Converter

        -

        Total Cache Image Service

        +

        Total Cache WebP Converter

        -

        Total Cache Image Service - +

        Total Cache WebP Converter - - 'newrelic.configuration_overloaded' ) ); + ?> @@ -82,5 +95,5 @@ Util_Ui::config_overloading_button( array( 'key' => 'newrelic.configuration_over - + diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extension_NewRelic_Page_View_Apm.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extension_NewRelic_Page_View_Apm.php index 001478d3..b5bff860 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extension_NewRelic_Page_View_Apm.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extension_NewRelic_Page_View_Apm.php @@ -6,24 +6,19 @@ if ( ! defined( 'W3TC' ) ) { } ?> -

        - - | - -

        is_extension_active_frontend( 'newrelic' ) ) { - echo '' . esc_html__( 'enabled', 'w3-total-cache' ) . ''; + echo '' . esc_html__( 'enabled', 'w3-total-cache' ) . '.'; } else { - echo '' . esc_html__( 'disabled', 'w3-total-cache' ) . ''; + echo '' . esc_html__( 'disabled', 'w3-total-cache' ) . '.'; } ?> - .

        +

        @@ -169,238 +164,236 @@ if ( ! defined( 'W3TC' ) ) {

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

        - -

        -
        - - - - - - - - - - - + + + + + + + + + +
        - get_boolean( array( 'newrelic', 'accept.logged_roles' ) ), - $config->is_sealed( 'newrelic' ) - ); - echo wp_kses( - sprintf( - // translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. - __( - 'Use %1$sRUM%2$s only for following user roles', - 'w3-total-cache' - ), - '', - '' - ), - array( - 'acronym' => array( - 'title' => array(), - ), - ) - ); - ?> - -

        - ', - '' - ), - array( - 'acronym' => array( - 'title' => array(), - ), - ) - ); - ?> -

        - -
        - get_array( array( 'newrelic', 'accept.roles' ) ); ?> -
        - $role_data ) : ?> - - id="role_" - /> - - -
        -
        - - - + + + + - - - - + +
        + + /> - get_boolean( array( 'newrelic', 'include_rum' ) ) ); ?> - /> -

        - ', - '' - ), - array( - 'acronym' => array( - 'title' => array(), - ), - ) - ); - ?> -

        -
        - - - -

        - +

        - - - get_boolean( array( 'newrelic', 'use_php_function' ) ) ); ?>/> +
        + + + + + + + - - - + + + - -
        + get_boolean( array( 'newrelic', 'accept.logged_roles' ) ), + $config->is_sealed( 'newrelic' ) + ); + echo wp_kses( + sprintf( + // translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. + __( + 'Use %1$sRUM%2$s only for following user roles', + 'w3-total-cache' + ), + '', + '' + ), + array( + 'acronym' => array( + 'title' => array(), + ), + ) + ); + ?> +

        ', - '' + '', + '' ), array( - 'a' => array( - 'href' => array(), + 'acronym' => array( + 'title' => array(), ), ) ); ?>

        - - -
        - - - get_boolean( array( 'newrelic', 'enable_xmit' ) ) ); ?> /> -

        - + get_array( array( 'newrelic', 'accept.roles' ) ); ?> +
        + $role_data ) : ?> + + id="role_" + /> + + + + +

        + + + /> + get_boolean( array( 'newrelic', 'include_rum' ) ) ); ?> + /> +

        + ', + '' ), - 'em' => array(), - ) - ); - ?> -

        -
        - - + array( + 'acronym' => array( + 'title' => array(), + ), + ) + ); + ?> +

        +
        + + + + +

        + +

        + + + get_boolean( array( 'newrelic', 'use_php_function' ) ) ); ?>/> +

        + ', + '' + ), + array( + 'a' => array( + 'href' => array(), + ), + ) + ); + ?> +

        + +
        + + + get_boolean( array( 'newrelic', 'enable_xmit' ) ) ); ?> /> +

        + ', + '', + '', + '' + ), + array( + 'a' => array( + 'href' => array(), + ), + 'em' => array(), + ) + ); + ?> +

        +
        + +
        diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extension_Swarmify_Page_View.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extension_Swarmify_Page_View.php index 3d4c229a..d0cb83f0 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extension_Swarmify_Page_View.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extension_Swarmify_Page_View.php @@ -5,24 +5,19 @@ if ( ! defined( 'W3TC' ) ) { die(); } ?> -

        - - | - -

        is_extension_active_frontend( 'swarmify' ) ) { - echo '' . esc_html__( 'enabled', 'w3-total-cache' ) . ''; + echo '' . esc_html__( 'enabled', 'w3-total-cache' ) . '.'; } else { - echo '' . esc_html__( 'disabled', 'w3-total-cache' ) . ''; + echo '' . esc_html__( 'disabled', 'w3-total-cache' ) . '.'; } ?> - .

        +
        @@ -38,7 +33,7 @@ if ( ! defined( 'W3TC' ) ) { ); ?>
        - + @@ -75,7 +70,7 @@ if ( ! defined( 'W3TC' ) ) { ); ?> - +
        diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extension_Wpml_Plugin_Admin.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extension_Wpml_Plugin_Admin.php index 4e5e97bf..f7eb30c0 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extension_Wpml_Plugin_Admin.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extension_Wpml_Plugin_Admin.php @@ -19,7 +19,7 @@ class Extension_Wpml_Plugin_Admin { if ( !$state->get_boolean( 'wpml.hide_note_language_negotiation_type' ) ) { $notes[] = sprintf( - __( 'W3 Total Cache\'s Page caching cannot work effectively when WPML Language URL formatis "Language name added as a parameter" used. Please consider another URL format. Visit the WPML -> Languages settings. %s' , + __( 'W3 Total Cache\'s Page caching cannot work effectively when WPML Language URL format is "Language name added as a parameter" used. Please consider another URL format. Visit the WPML -> Languages settings. %s', 'w3-total-cache' ), Util_Ui::button_hide_note2( array( 'w3tc_default_config_state' => 'y', @@ -111,7 +111,7 @@ class Extension_Wpml_Plugin_Admin { $config = Dispatcher::config(); if ( !Util_Environment::is_w3tc_pro( $config ) ) - $activate_text = 'Available after upgrade. '; + $activate_text = 'Available after upgrade. '; else { $activate_text = sprintf( 'Click here to try it. ', Util_Ui::url( array( 'w3tc_extensions_activate' => $extension_id ) ) ); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extensions_Plugin_Admin.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extensions_Plugin_Admin.php index 1ba87791..df1108f9 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extensions_Plugin_Admin.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Extensions_Plugin_Admin.php @@ -231,7 +231,7 @@ class Extensions_Plugin_Admin { if ( isset( $info['notice'] ) && get_transient( $transient_name ) ) { ?> -
        +

        array( + 'title' => esc_html__( 'Delay Scripts', 'w3-total-cache' ), + 'icon' => 'dashicons-media-code', + 'text' => esc_html__( "Delay the loading of specified internal/external JavaScript sources on your pages separate from Minify.", 'w3-total-cache' ), + 'button' => '', + 'link' => '' . __( 'More info', 'w3-total-cache' ) . '', + 'is_premium' => true, + 'is_new' => true, + ), 'pagespeed' => array( 'title' => esc_html__( 'Google Page Speed', 'w3-total-cache' ), 'icon' => 'dashicons-analytics', 'text' => esc_html__( "Adds the ability to analyze the website's homepage and provide a detailed breakdown of performance metrics including potential issues and proposed solutions.", 'w3-total-cache' ), 'button' => '', + esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_pagespeed' ) ) . '\'">' . + __( 'Launch', 'w3-total-cache' ) . '', 'link' => '' . __( 'More info', 'w3-total-cache' ) . '', 'is_premium' => false, @@ -356,7 +371,7 @@ class FeatureShowcase_Plugin_Admin { 'is_new' => false, ), 'imageservice' => array( - 'title' => esc_html__( 'Image Service', 'w3-total-cache' ), + 'title' => esc_html__( 'WebP Converter', 'w3-total-cache' ), 'icon' => 'dashicons-embed-photo', 'text' => esc_html( $imageservice_description ), 'button' => empty( $imageservice_button_text ) ? '' : diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/FeatureShowcase_Plugin_Admin_View.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/FeatureShowcase_Plugin_Admin_View.php index f2dd862e..8a2ab080 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/FeatureShowcase_Plugin_Admin_View.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/FeatureShowcase_Plugin_Admin_View.php @@ -28,12 +28,7 @@ namespace W3TC; $is_pro = Util_Environment::is_w3tc_pro( $config ); -if ( $is_pro ) { - require W3TC_INC_DIR . '/options/common/header.php'; -} else { - require W3TC_INC_DIR . '/options/parts/dashboard_banner.php'; -} - +require W3TC_INC_DIR . '/options/common/header.php'; ?>

        @@ -80,17 +75,17 @@ foreach ( $cards as $feature_id => $card ) {

        diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_AdminActions_Default.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_AdminActions_Default.php index 89fc3974..5633a7bd 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_AdminActions_Default.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_AdminActions_Default.php @@ -48,7 +48,7 @@ class Generic_AdminActions_Default { * * @return void */ - function w3tc_default_save_licence_key() { + function w3tc_default_save_license_key() { $license = Util_Request::get_string( 'license_key' ); try { $old_config = new Config(); @@ -273,37 +273,6 @@ class Generic_AdminActions_Default { } } - /** - * Page Cache tab - */ - if ( 'w3tc_pgcache' === $this->_page ) { - // Textarea settings. - $settings = array( - 'pgcache.mirrors.home_urls', - 'pgcache.purge.pages', - 'pgcache.accept.qs', - 'pgcache.reject.ua', - 'pgcache.reject.cookie', - 'pgcache.reject.uri', - 'pgcache.reject.categories', - 'pgcache.reject.tags', - 'pgcache.reject.authors', - 'pgcache.reject.custom', - 'pgcache.accept.files', - 'pgcache.accept.uri', - 'pgcache.cache.headers', - ); - // Remove empty lines, trim values, and sort. - foreach ( $settings as $setting ) { - $setting_array = $config->get_array( $setting ); - if ( ! empty( $setting_array ) && is_array( $setting_array ) ) { - $values = array_filter( array_map( 'trim', $setting_array ), 'strlen' ); - sort( $values ); - $config->set( $setting, $values ); - } - } - } - /** * Minify tab */ @@ -696,10 +665,6 @@ class Generic_AdminActions_Default { array_map( 'stripslashes_deep', $request_value ); } else { $request_value = stripslashes( $request_value ); - - if ( strpos( $request_key, 'memcached__servers' ) || strpos( $request_key, 'redis__servers' ) ) { - $request_value = explode( ',', $request_value ); - } } if ( 'extension__' === substr( $request_key, 0, 11 ) ) { @@ -712,26 +677,40 @@ class Generic_AdminActions_Default { } } - $key = Util_Ui::config_key_from_http_name( $request_key ); - if ( is_array( $key ) ) { - $config->set( $key, $request_value ); - } elseif ( array_key_exists( $key, $keys ) ) { - $descriptor = $keys[ $key ]; - if ( isset( $descriptor['type'] ) ) { - if ( 'array' === $descriptor['type'] ) { - if ( is_array( $request_value ) ) { - $request_value = implode( "\n", $request_value ); - } - $request_value = explode( "\n", str_replace( "\r\n", "\n", $request_value ) ); - } elseif ( 'boolean' === $descriptor['type'] ) { - $request_value = ( '1' === $request_value ); - } elseif ( 'integer' === $descriptor['type'] ) { - $request_value = (int) $request_value; - } - } + $key = Util_Ui::config_key_from_http_name( $request_key ); + $descriptor = null; - $config->set( $key, $request_value ); + if ( ! is_array( $key ) && array_key_exists( $key, $keys ) ) { + $descriptor = $keys[ $key ]; } + + /** + * This filter is needed for compound keys to set the appropirate data type to save as. + * Mainly used by extensions with textarea fields that don't feature a ConfigKeys entry. + * If no filter exists to define such fields it will save as a string, requiring post-processing. + * + * @since 2.4.2 + * + * @param mixed $descriptor Array containing correct data type or null if not matched. + * @param array $key Key to match on. + */ + $descriptor = apply_filters( 'w3tc_config_key_descriptor', $descriptor, $key ); + + if ( isset( $descriptor['type'] ) ) { + if ( 'array' === $descriptor['type'] ) { + if ( is_array( $request_value ) ) { + // This is needed for radio inputs. + $request_value = implode( "\n", $request_value ); + } + $request_value = Util_Environment::textarea_to_array( $request_value ); + } elseif ( 'boolean' === $descriptor['type'] ) { + $request_value = ( '1' === $request_value ); + } elseif ( 'integer' === $descriptor['type'] ) { + $request_value = (int) $request_value; + } + } + + $config->set( $key, $request_value ); } } } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_AdminActions_Flush.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_AdminActions_Flush.php index 84054b2f..c6b2c9e2 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_AdminActions_Flush.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_AdminActions_Flush.php @@ -275,7 +275,7 @@ class Generic_AdminActions_Flush { $this->flush_dbcache(); } - if ( $this->_config->get_string( 'objectcache.engine' ) == $type && $this->_config->get_boolean( 'objectcache.enabled' ) ) { + if ( $this->_config->get_string( 'objectcache.engine' ) == $type && $this->_config->getf_boolean( 'objectcache.enabled' ) ) { $this->flush_objectcache(); } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_Page_Dashboard_View.css b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_Page_Dashboard_View.css index a453a3b8..9df0f442 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_Page_Dashboard_View.css +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_Page_Dashboard_View.css @@ -7,6 +7,11 @@ height: 36px; line-height: 36px; } +#w3tc-dashboard-widgets .hndle, +#w3tc-dashboard-widgets .hndle .w3tc-widget-w3tc-logo, +#w3tc-dashboard-widgets .hndle .w3tc-widget-text { + cursor: default; +} #w3tc-dashboard-widgets .hndle, #w3tc-dashboard-widgets .hndle span { font-family: Arial, sans-serif; font-weight: bold; diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_Plugin.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_Plugin.php index f618393c..9f1ed212 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_Plugin.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_Plugin.php @@ -254,6 +254,27 @@ class Generic_Plugin { ), ); + if ( + ! empty( $this->_config->get_string( array( 'cloudflare', 'email' ) ) ) + && ! empty( $this->_config->get_string( array( 'cloudflare', 'key' ) ) ) + && ( + $modules->can_empty_memcache() + || $modules->can_empty_opcode() + || $modules->can_empty_file() + || $modules->can_empty_varnish() + ) + ) { + $menu_items['10015.generic'] = array( + 'id' => 'w3tc_flush_all_except_cf', + 'parent' => 'w3tc', + 'title' => __( 'Purge All Caches Except CloudFlare', 'w3-total-cache' ), + 'href' => wp_nonce_url( + network_admin_url( 'admin.php?page=w3tc_dashboard&w3tc_cloudflare_flush_all_except_cf' ), + 'w3tc' + ), + ); + } + if ( ! is_admin() ) { $menu_items['10020.generic'] = array( 'id' => 'w3tc_flush_current_page', @@ -648,7 +669,7 @@ class Generic_Plugin { private function is_debugging() { $debug = $this->_config->get_boolean( 'pgcache.enabled' ) && $this->_config->get_boolean( 'pgcache.debug' ); $debug = $debug || ( $this->_config->get_boolean( 'dbcache.enabled' ) && $this->_config->get_boolean( 'dbcache.debug' ) ); - $debug = $debug || ( $this->_config->get_boolean( 'objectcache.enabled' ) && $this->_config->get_boolean( 'objectcache.debug' ) ); + $debug = $debug || ( $this->_config->getf_boolean( 'objectcache.enabled' ) && $this->_config->get_boolean( 'objectcache.debug' ) ); $debug = $debug || ( $this->_config->get_boolean( 'browsercache.enabled' ) && $this->_config->get_boolean( 'browsercache.debug' ) ); $debug = $debug || ( $this->_config->get_boolean( 'minify.enabled' ) && $this->_config->get_boolean( 'minify.debug' ) ); $debug = $debug || ( $this->_config->get_boolean( 'cdn.enabled' ) && $this->_config->get_boolean( 'cdn.debug' ) ); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_Plugin_Admin.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_Plugin_Admin.php index 1f199703..6cf042dc 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_Plugin_Admin.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_Plugin_Admin.php @@ -65,13 +65,16 @@ class Generic_Plugin_Admin { add_action( 'wp_ajax_w3tc_ajax', array( $this, 'wp_ajax_w3tc_ajax' ) ); add_action( 'admin_head', array( $this, 'admin_head' ) ); + add_action( 'admin_footer', array( $this, 'admin_footer' ) ); if ( is_network_admin() ) { add_action( 'network_admin_menu', array( $this, 'network_admin_menu' ) ); add_filter( 'network_admin_plugin_action_links_' . W3TC_FILE, array( $this, 'plugin_action_links' ) ); + add_action( 'network_admin_notices', array( $this, 'top_nav_bar' ), 0 ); } else { add_action( 'admin_menu', array( $this, 'admin_menu' ) ); add_filter( 'plugin_action_links_' . W3TC_FILE, array( $this, 'plugin_action_links' ) ); + add_action( 'admin_notices', array( $this, 'top_nav_bar' ), 0 ); } add_filter( 'favorite_actions', array( $this, 'favorite_actions' ) ); @@ -94,11 +97,11 @@ class Generic_Plugin_Admin { // Load w3tc_message. $message_id = Util_Request::get_string( 'w3tc_message' ); if ( $message_id ) { - $v = get_transient( 'w3tc_message' ); + $v = get_option( 'w3tc_message' ); if ( isset( $v[ $message_id ] ) ) { $this->w3tc_message = $v[ $message_id ]; - delete_transient( 'w3tc_message' ); + delete_option( 'w3tc_message' ); } } } @@ -362,6 +365,7 @@ class Generic_Plugin_Admin { public function admin_enqueue_scripts() { wp_register_style( 'w3tc-options', plugins_url( 'pub/css/options.css', W3TC_FILE ), array(), W3TC_VERSION ); wp_register_style( 'w3tc-lightbox', plugins_url( 'pub/css/lightbox.css', W3TC_FILE ), array(), W3TC_VERSION ); + wp_register_style( 'w3tc-bootstrap-css', plugins_url( 'pub/css/bootstrap-buttons.css', W3TC_FILE ), array(), W3TC_VERSION ); wp_register_style( 'w3tc-widget', plugins_url( 'pub/css/widget.css', W3TC_FILE ), array(), W3TC_VERSION ); wp_register_script( 'w3tc-metadata', plugins_url( 'pub/js/metadata.js', W3TC_FILE ), array(), W3TC_VERSION, false ); @@ -397,6 +401,15 @@ class Generic_Plugin_Admin { } } + /** + * Render sticky top navigation bar on all W3TC admin pages. + */ + public function top_nav_bar() { + if ( Util_Admin::is_w3tc_admin_page() ) { + require W3TC_INC_DIR . '/options/common/top_nav_bar.php'; + } + } + /** * Define icon styles for the custom post type. * @@ -451,39 +464,52 @@ class Generic_Plugin_Admin { } if ( defined( 'W3TC_DEVELOPER' ) && W3TC_DEVELOPER ) { - $profile = 'UA-2264433-7'; + $profile = 'G-Q3CHQJWERM'; } else { - $profile = 'UA-2264433-8'; + $profile = 'G-5TFS8M5TTY'; } $state = Dispatcher::config_state(); + wp_enqueue_script( + 'w3tc_ga', + 'https://www.googletagmanager.com/gtag/js?id=' . esc_attr( $profile ), + array(), + W3TC_VERSION, + true + ); ?> - is_w3tc_page ) { + require W3TC_INC_DIR . '/options/common/footer.php'; + } + } + /** * Render network admin menu. */ @@ -581,6 +616,7 @@ class Generic_Plugin_Admin { */ public function admin_print_styles() { wp_enqueue_style( 'w3tc-options' ); + wp_enqueue_style( 'w3tc-bootstrap-css' ); wp_enqueue_style( 'w3tc-lightbox' ); } @@ -829,11 +865,9 @@ class Generic_Plugin_Admin { } $line = preg_replace( '~^\s*\*\s*~', '', htmlspecialchars( $line ) ); echo '
      • ' . esc_html( $line ) . '
      • '; - } else { - if ( $ul ) { - echo '
        '; - $ul = false; - } + } elseif ( $ul ) { + echo '
        '; + $ul = false; } } @@ -951,6 +985,7 @@ class Generic_Plugin_Admin { $note_messages = array( 'config_save' => __( 'Plugin configuration successfully updated.', 'w3-total-cache' ), + 'config_save_flush' => __( 'Plugin configuration successfully updated and all caches successfully emptied.', 'w3-total-cache' ), 'flush_all' => __( 'All caches successfully emptied.', 'w3-total-cache' ), 'flush_memcached' => __( 'Memcached cache(s) successfully emptied.', 'w3-total-cache' ), 'flush_opcode' => __( 'Opcode cache(s) successfully emptied.', 'w3-total-cache' ), @@ -1096,7 +1131,7 @@ class Generic_Plugin_Admin { foreach ( $notes as $key => $note ) { echo wp_kses( sprintf( - '

        %2$s

        ', + '

        %2$s

        ', esc_attr( $key ), $note ), @@ -1124,7 +1159,7 @@ class Generic_Plugin_Admin { foreach ( $errors as $key => $error ) { printf( - '

        %2$s

        ', + '

        %2$s

        ', esc_attr( $key ), $error // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_WidgetCommunity_View.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_WidgetCommunity_View.php index bc04b962..e7ad0167 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_WidgetCommunity_View.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_WidgetCommunity_View.php @@ -35,8 +35,6 @@ if ( !defined( 'W3TC' ) )

        - -

        \ No newline at end of file + +

        diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_WidgetServices.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_WidgetServices.php index 3faf70ef..2133539c 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_WidgetServices.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_WidgetServices.php @@ -1,16 +1,20 @@
        ' . - '
        ' . - __( 'Premium Services', 'w3-total-cache' ) . - '
        ', + /** + * W3TC dashboard Premium Services widget. + */ + public function wp_dashboard_setup() { + Util_Widget::add( + 'w3tc_services', + '
        ' . __( 'Premium Services', 'w3-total-cache' ) . '
        ', array( $this, 'widget_form' ), - null, 'normal' ); + null, + 'normal' + ); } - - - public function load_request_types() { - $v = get_site_option( 'w3tc_generic_widgetservices' ); - try { - $v = json_decode( $v, true ); - if ( isset( $v['items'] ) && isset( $v['expires'] ) && - $v['expires'] > time() ) - return $v['items']; - } catch ( \Exception $e ) { - } - - - $result = wp_remote_request( W3TC_SUPPORT_SERVICES_URL, - array( 'method' => 'GET' ) ); - - if ( is_wp_error( $result ) ) - return null; - - $response_json = json_decode( $result['body'], true ); - - if ( is_null( $response_json ) || !isset( $response_json['items'] ) ) - return null; - - update_site_option( 'w3tc_generic_widgetservices', - json_encode( array( - 'content' => $response_json, - 'expires' => time() + 3600 * 24 * 7 - ) ) ); - - return $response_json['items']; - } - - - + /** + * Premium Services widget content. + */ public function widget_form() { - $items = $this->load_request_types(); - - include W3TC_DIR . '/Generic_WidgetServices_View.php'; + include W3TC_DIR . '/Generic_WidgetServices_View.php'; } -/* - wp_enqueue_style( 'w3tc-widget-newrelic', - plugins_url( 'Extension_NewRelic_Widget_View.css', W3TC_FILE ), - array(), W3TC_VERSION ); - - if ( Util_Admin::get_current_wp_page() == 'w3tc_dashboard' ) - add_action( 'admin_enqueue_scripts', array( $this, 'enqueue' ) ); - - $this->_json_request_types = array( - 'email_support' => sprintf( __( 'Less than 15 Minute Email Support Response %s', 'w3-total-cache' ), '(M-F 9AM - 5PM EDT): $175 USD' ), - 'phone_support' => sprintf( __( 'Less than 15 Minute Phone Support Response %s', 'w3-total-cache' ), '(M-F 9AM - 5PM EDT): $250 USD' ), - 'plugin_config' => sprintf( __( 'Professional Plugin Configuration %s', 'w3-total-cache' ), 'Starting @ $200 USD' ), - 'theme_config' => sprintf( __( 'Theme Performance Optimization & Plugin Configuration %s', 'w3-total-cache' ), 'Starting @ $350 USD' ), - 'linux_config' => sprintf( __( 'Linux Server Optimization & Plugin Configuration %s', 'w3-total-cache' ), 'Starting @ $450 USD' ) + /** + * Premium Services widget services list. + */ + public static function get_services() { + return array( + __( 'Billing Support', 'w3-total-cache' ), + __( 'Sales Questions', 'w3-total-cache' ), + __( 'Submit a Bug Report', 'w3-total-cache' ), + __( 'Suggest a New Feature', 'w3-total-cache' ), + __( 'Performance Audit & Consultation', 'w3-total-cache' ), + __( 'Plugin Configuration', 'w3-total-cache' ), + __( 'CDN Configuration: Full-Site Delivery', 'w3-total-cache' ), + __( 'Hosting Environment Troubleshooting', 'w3-total-cache' ), + __( 'Eliminate render-blocking Javascripts', 'w3-total-cache' ), + __( 'Investigate Compatibility Issue', 'w3-total-cache' ), ); - $this->_request_types = array( - 'email_support' => sprintf( __( 'Less than 15 Minute Email Support Response %s', 'w3-total-cache' ), '
        (M-F 9AM - 5PM EDT): $175 USD' ), - 'phone_support' => sprintf( __( 'Less than 15 Minute Phone Support Response %s', 'w3-total-cache' ), '
        (M-F 9AM - 5PM EDT): $250 USD' ), - 'plugin_config' => sprintf( __( 'Professional Plugin Configuration %s', 'w3-total-cache' ), '
        Starting @ $200 USD' ), - 'theme_config' => sprintf( __( 'Theme Performance Optimization & Plugin Configuration %s', 'w3-total-cache' ), '
        Starting @ $350 USD' ), - 'linux_config' => sprintf( __( 'Linux Server Optimization & Plugin Configuration %s', 'w3-total-cache' ), '
        Starting @ $450 USD' ) - ); - - function widget_form() { - include W3TC_INC_WIDGET_DIR . '/services.php'; } - - public function enqueue() { - wp_enqueue_style( 'w3tc-widget' ); - wp_enqueue_script( 'w3tc-metadata' ); - wp_enqueue_script( 'w3tc-widget' ); - }*/ } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_WidgetServices_View.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_WidgetServices_View.php index 4466055a..9258114a 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_WidgetServices_View.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Generic_WidgetServices_View.php @@ -5,33 +5,15 @@ if ( ! defined( 'W3TC' ) ) { die(); } ?> -
        - -
          - -
        • -
          - -
          - -
        • - -
        -
        -

        - -

        -
        +
          + ' . esc_html( $service ) . ''; + } + ?> +
        +
        + + + diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Licensing_Plugin_Admin.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Licensing_Plugin_Admin.php index fd6fe30e..aad91b58 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Licensing_Plugin_Admin.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Licensing_Plugin_Admin.php @@ -47,10 +47,7 @@ class Licensing_Plugin_Admin { ), ) ), - 'href' => wp_nonce_url( - network_admin_url( 'admin.php?page=w3tc_dashboard&w3tc_message_action=licensing_upgrade' ), - 'w3tc' - ), + 'href' => wp_nonce_url( network_admin_url( 'admin.php?page=w3tc_dashboard&w3tc_message_action=licensing_upgrade' ), 'w3tc' ), ); } @@ -59,7 +56,7 @@ class Licensing_Plugin_Admin { 'id' => 'w3tc_debug_overlay_upgrade', 'parent' => 'w3tc_debug_overlays', 'title' => esc_html__( 'Upgrade', 'w3-total-cache' ), - 'href' => wp_nonce_url( network_admin_url( 'admin.php?page=w3tc_dashboard&w3tc_message_action=licensing_upgrade' ), 'w3tc' ) + 'href' => wp_nonce_url( network_admin_url( 'admin.php?page=w3tc_dashboard&w3tc_message_action=licensing_upgrade' ), 'w3tc' ), ); } @@ -170,7 +167,7 @@ class Licensing_Plugin_Admin { 'It looks like your W3 Total Cache Pro license has expired. %1$s to continue using the Pro features', 'w3-total-cache' ), - '' ), diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Minify_Plugin.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Minify_Plugin.php index c64d9d76..80550789 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Minify_Plugin.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Minify_Plugin.php @@ -307,7 +307,7 @@ class Minify_Plugin { $menu_items['20210.minify'] = array( 'id' => 'w3tc_flush_minify', 'parent' => 'w3tc_flush', - 'title' => __( 'Minify', 'w3-total-cache' ), + 'title' => __( 'Minify Cache', 'w3-total-cache' ), 'href' => wp_nonce_url( admin_url( 'admin.php?page=w3tc_dashboard&w3tc_flush_minify' ), 'w3tc' ) diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Minify_Plugin_Admin.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Minify_Plugin_Admin.php index 8497c81d..85a988be 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Minify_Plugin_Admin.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Minify_Plugin_Admin.php @@ -46,7 +46,7 @@ class Minify_Plugin_Admin { $menu_items['90040.minify'] = array( 'id' => 'w3tc_overlay_minify', 'parent' => 'w3tc_debug_overlays', - 'title' => __( 'Minify', 'w3-total-cache' ), + 'title' => __( 'Minify Cache', 'w3-total-cache' ), 'href' => wp_nonce_url( network_admin_url( 'admin.php?page=w3tc_dashboard&w3tc_message_action=minify_help' ), 'w3tc' ) ); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Mobile_Base.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Mobile_Base.php index dd019620..77f9aade 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Mobile_Base.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Mobile_Base.php @@ -10,7 +10,7 @@ abstract class Mobile_Base { private $_groups = array(); private $_compare_key = ''; private $_config_key = ''; - private $_cacheclass = ''; + private $_cachecase = ''; /** * PHP5-style constructor diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Environment.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Environment.php index 76dae20b..382aeaad 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Environment.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Environment.php @@ -21,7 +21,7 @@ class ObjectCache_Environment { $exs = new Util_Environment_Exceptions(); try { - $addin_required = $config->get_boolean( 'objectcache.enabled' ); + $addin_required = $config->getf_boolean( 'objectcache.enabled' ); $addin_required = apply_filters( 'w3tc_objectcache_addin_required', $addin_required ); @@ -43,7 +43,7 @@ class ObjectCache_Environment { * @throws Util_Environment_Exceptions */ public function fix_on_event( $config, $event, $old_config = null ) { - if ( $config->get_boolean( 'objectcache.enabled' ) && + if ( $config->getf_boolean( 'objectcache.enabled' ) && $config->get_string( 'objectcache.engine' ) == 'file' ) { if ( !wp_next_scheduled( 'w3_objectcache_cleanup' ) ) { wp_schedule_event( time(), diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Page.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Page.php index 52961518..49390083 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Page.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Page.php @@ -17,7 +17,7 @@ class ObjectCache_Page extends Base_Page_Settings { * @return void */ function view() { - $objectcache_enabled = $this->_config->get_boolean( 'objectcache.enabled' ); + $objectcache_enabled = $this->_config->getf_boolean( 'objectcache.enabled' ); include W3TC_INC_DIR . '/options/objectcache.php'; } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Plugin.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Plugin.php index 6560ea4d..e8a98dc2 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Plugin.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Plugin.php @@ -75,7 +75,8 @@ class ObjectCache_Plugin { add_filter( 'w3tc_usage_statistics_sources', array( $this, 'w3tc_usage_statistics_sources' ) ); if ( Util_Environment::is_wpmu() ) { - add_action( 'delete_blog', array( $this, 'on_change' ), 0 ); + add_action( 'wp_uninitialize_site', array( $this, 'on_change' ), 0 ); + add_action( 'wp_update_site', array( $this, 'on_change' ), 0 ); add_action( 'switch_blog', array( $this, 'switch_blog' ), 0, 2 ); } } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Plugin_Admin.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Plugin_Admin.php index 403c502c..0e7c0116 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Plugin_Admin.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_Plugin_Admin.php @@ -7,7 +7,7 @@ class ObjectCache_Plugin_Admin { add_filter( 'w3tc_config_labels', array( $config_labels, 'config_labels' ) ); $c = Dispatcher::config(); - if ( $c->get_boolean( 'objectcache.enabled' ) ) { + if ( $c->getf_boolean( 'objectcache.enabled' ) ) { add_filter( 'w3tc_errors', array( $this, 'w3tc_errors' ) ); add_filter( 'w3tc_notes', array( $this, 'w3tc_notes' ) ); add_filter( 'w3tc_usage_statistics_summary_from_history', array( diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_WpObjectCache.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_WpObjectCache.php index d0566c42..30e50da9 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_WpObjectCache.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_WpObjectCache.php @@ -36,6 +36,24 @@ class ObjectCache_WpObjectCache { return $cache->get( $id, $group, $force, $found ); } + /** + * Retrieves multiple values from the cache in one call. + * + * @since 2.2.8 + * + * @param array $ids Array of keys under which the cache contents are stored. + * @param string $group Optional. Where the cache contents are grouped. Default 'default'. + * @param bool $force Optional. Whether to force an update of the local cache + * from the persistent cache. Default false. + * + * @return array Array of return values, grouped by key. Each value is either + * the cache contents on success, or false on failure. + */ + public function get_multiple( $ids, $group = 'default', $force = false ) { + $cache = $this->_get_engine( $group ); + return $cache->get_multiple( $ids, $group, $force ); + } + /** * Set to the cache * @@ -50,6 +68,23 @@ class ObjectCache_WpObjectCache { return $cache->set( $id, $data, $group, $expire ); } + /** + * Sets multiple values to the cache in one call. + * + * @since 2.2.8 + * + * @param array $data Array of key and value to be set. + * @param string $group Optional. Where the cache contents are grouped. Default empty. + * @param int $expire Optional. When to expire the cache contents, in seconds. + * Default 0 (no expiration). + * + * @return bool[] Array of return values, grouped by key. Each value is always true. + */ + public function set_multiple( $data, $group = 'default', $expire = 0 ) { + $cache = $this->_get_engine( $group ); + return $cache->set_multiple( $data, $group, $expire ); + } + /** * Delete from the cache * @@ -63,6 +98,22 @@ class ObjectCache_WpObjectCache { return $cache->delete( $id, $group, $force ); } + /** + * Deletes multiple values from the cache in one call. + * + * @since 2.2.8 + * + * @param array $keys Array of keys to be deleted. + * @param string $group Optional. Where the cache contents are grouped. Default empty. + * + * @return bool[] Array of return values, grouped by key. Each value is either + * true on success, or false if the contents were not deleted. + */ + public function delete_multiple( $keys, $group = 'default' ) { + $cache = $this->_get_engine( $group ); + return $cache->delete_multiple( $keys, $group ); + } + /** * Add to the cache * @@ -77,6 +128,24 @@ class ObjectCache_WpObjectCache { return $cache->add( $id, $data, $group, $expire ); } + /** + * Adds multiple values to the cache in one call. + * + * @since 2.2.8 + * + * @param array $data Array of keys and values to be added. + * @param string $group Optional. Where the cache contents are grouped. Default empty. + * @param int $expire Optional. When to expire the cache contents, in seconds. + * Default 0 (no expiration). + * + * @return bool[] Array of return values, grouped by key. Each value is either + * true on success, or false if cache key and group already exist. + */ + public function add_multiple( array $data, $group = '', $expire = 0 ) { + $cache = $this->_get_engine( $group ); + return $cache->add_multiple( $data, $group, $expire ); + } + /** * Replace in the cache * diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_WpObjectCache_Regular.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_WpObjectCache_Regular.php index 91cdb66e..7ba3900b 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_WpObjectCache_Regular.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/ObjectCache_WpObjectCache_Regular.php @@ -243,6 +243,25 @@ class ObjectCache_WpObjectCache_Regular { return $value; } + /** + * Get multiple from the cache + * + * @since 2.2.8 + * + * @param string $ids IDs. + * @param string $group Group. + * @param bool $force Force flag. + * + * @return mixed + */ + public function get_multiple( $ids, $group = 'default', $force = false ) { + $found_cache = array(); + foreach ( $ids as $id ) { + $found_cache[ $id ] = $this->get( $id, $group, $force ); + } + return $found_cache; + } + /** * Set to the cache * @@ -329,6 +348,27 @@ class ObjectCache_WpObjectCache_Regular { return $return; } + /** + * Sets multiple values to the cache in one call. + * + * @since 2.2.8 + * + * @param array $data Array of keys and values to be set. + * @param string $group Optional. Where the cache contents are grouped. Default empty. + * @param int $expire Optional. When to expire the cache contents, in seconds. + * Default 0 (no expiration). + * + * @return bool[] Array of return values, grouped by key. Each value is either + * true on success, or false on failure. + */ + public function set_multiple( array $data, $group = '', $expire = 0 ) { + $values = array(); + foreach ( $data as $key => $value ) { + $values[ $key ] = $this->set( $key, $value, $group, $expire ); + } + return $values; + } + /** * Delete from the cache * @@ -371,6 +411,25 @@ class ObjectCache_WpObjectCache_Regular { return $return; } + /** + * Deletes multiple values from the cache in one call. + * + * @since 2.2.8 + * + * @param array $keys Array of keys under which the cache to deleted. + * @param string $group Optional. Where the cache contents are grouped. Default empty. + * + * @return bool[] Array of return values, grouped by key. Each value is either + * true on success, or false if the contents were not deleted. + */ + public function delete_multiple( array $keys, $group = '' ) { + $values = array(); + foreach ( $keys as $key ) { + $values[ $key ] = $this->delete( $key, $group ); + } + return $values; + } + /** * Add to the cache * @@ -388,6 +447,27 @@ class ObjectCache_WpObjectCache_Regular { return $this->set( $id, $data, $group, $expire ); } + /** + * Add multiple to the cache + * + * @since 2.2.8 + * + * @param array $data Array of keys and values to be added. + * @param string $group Optional. Where the cache contents are grouped. Default empty. + * @param int $expire Optional. When to expire the cache contents, in seconds. + * Default 0 (no expiration). + * + * @return bool[] Array of return values, grouped by key. Each value is either + * true on success, or false if cache key and group already exist. + */ + public function add_multiple( array $data, $group = '', $expire = 0 ) { + $values = array(); + foreach ( $data as $key => $value ) { + $values[ $key ] = $this->add( $key, $value, $group, $expire ); + } + return $values; + } + /** * Replace in the cache * @@ -789,7 +869,7 @@ class ObjectCache_WpObjectCache_Regular { /** * Skip if disabled */ - if ( !$this->_config->get_boolean( 'objectcache.enabled' ) ) { + if ( !$this->_config->getf_boolean( 'objectcache.enabled' ) ) { $this->cache_reject_reason = 'objectcache.disabled'; return false; diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Api.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Api.php index e7770260..7bcd8792 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Api.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Api.php @@ -344,7 +344,7 @@ class PageSpeed_Api { * @param string $gacode New Google access authentication code. * @param string $w3tc_pagespeed_key W3 API access key. * - * @return JSON + * @return string */ public function process_authorization_response( $gacode, $w3tc_pagespeed_key ) { if ( empty( $gacode ) ) { diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Instructions.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Instructions.php index 7cf5e960..b2478a34 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Instructions.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Instructions.php @@ -33,15 +33,26 @@ class PageSpeed_Instructions { 'instructions' => '

        ' . wp_kses( sprintf( - // translators: 1 W3TC plugin name, 2 HTML a tag to W3TC minify JS admin page - // translators: 3 HTML a tag to W3TC minify CSS admin page. + // translators: 1 W3TC plugin name, 2 HTML a tag to W3TC Minify JS admin page + // translators: 3 HTML a tag to W3TC general settings user experience section + // translators: 4 HTML a tag to W3TC user expereince advanced settings page + // translators: 5 HTML a tag to W3TC Minify CSS admin page, 6 HTML line break tag. esc_html__( - '%1$s can eliminate render blocking resources. Once Minified, you can defer JS in the %2$s. Render blocking CSS can be eliminated in %3$s using the "Eliminate Render blocking CSS by moving it to HTTP body" (PRO FEATURE).', + '%1$s can eliminate render blocking resources.%6$sOnce Minified, you can defer JS in the + %2$s.%6$sThe Defer Scripts (PRO FEATURE) can also be used with or without Minify to defer + the loading of JS files containing the "src" attribute. Scripts matched using this + feature will be excluded from the Minify process. To enable this feature navigate + to %3$s and check the "Defer JavaScript" checkbox. Once enabled the settings can be found + at %4$s.%6$sRender blocking CSS can be eliminated in %5$s using the "Eliminate Render + blocking CSS by moving it to HTTP body" (PRO FEATURE).', 'w3-total-cache' ), 'W3 Total Cache', '' . esc_html__( 'Performance » Minify » JS', 'w3-total-cache' ) . ' ', - '' . esc_html__( 'Performance » Minify » CSS', 'w3-total-cache' ) . '' + '' . esc_html__( 'Performance » General Settings » User Experience', 'w3-total-cache' ) . '', + '' . esc_html__( 'Performance » User Experience', 'w3-total-cache' ) . '', + '' . esc_html__( 'Performance » Minify » CSS', 'w3-total-cache' ) . '', + '

        ' ), $allowed_tags ) . '

        ', @@ -126,7 +137,7 @@ class PageSpeed_Instructions { '

        ' . sprintf( // translators: 1 W3TC plugin name, opening HTML a tag to Image Service extension, 3 closing HTML a tag. esc_html__( - 'Use %1$s %2$sImage Service%3$s to convert media library images to WebP.', + 'Use %1$s %2$sWebP Converter%3$s to convert media library images to WebP.', 'w3-total-cache' ), 'W3 Total Cache', @@ -139,7 +150,7 @@ class PageSpeed_Instructions { '

        ' . sprintf( // translators: 1 W3TC plugin name, opening HTML a tag to Image Service extension, 3 closing HTML a tag. esc_html__( - 'Use %1$s %2$sImage Service%3$s to convert media library images to WebP.', + 'Use %1$s %2$sWebP Converter%3$s to convert media library images to WebP.', 'w3-total-cache' ), 'W3 Total Cache', @@ -217,7 +228,7 @@ class PageSpeed_Instructions { '

        ' . sprintf( // translators: 1 W3TC plugin name, opening HTML a tag to Image Service extension, 3 closing HTML a tag. esc_html__( - 'Use %1$s %2$sImage Service%3$s to convert media library images to WebP.', + 'Use %1$s %2$sWebP Converter%3$s to convert media library images to WebP.', 'w3-total-cache' ), 'W3 Total Cache', @@ -279,7 +290,7 @@ class PageSpeed_Instructions { // translators: 1 W3TC plugin name, 2 opening HTML a tag to CSS Minify settings, 3 closing HTML a tag, // translators: 4 opening html a tagl to JS Minify settings, 5 closing HTML a tag. esc_html__( - 'Compress your HTML, CSS, and JavaScript files and minify your CSS and JavaScript to ensure your text-based resources are as small as they can be. Use the %1$s Minify %2$sJS%3$s and %4$sCSS%5$s features to accomplish this.', + 'Compress your HTML, CSS, and JavaScript files and Minify your CSS and JavaScript to ensure your text-based resources are as small as they can be. Use the %1$s Minify %2$sJS%3$s and %4$sCSS%5$s features to accomplish this.', 'w3-total-cache' ), 'W3 Total Cache', @@ -291,7 +302,7 @@ class PageSpeed_Instructions {

        ' . sprintf( // translators: 1 W3TC plugin name, 2 opening HTML a tag to W3TC extensions, 3 closing HTML a tag. esc_html__( - 'Optimize your image delivery by sizing them properly and compressing them for smaller sizes. Use Webp conversion via the %1$s %2$sImage Service%3$s extension.', + 'Optimize your image delivery by sizing them properly and compressing them for smaller sizes. Use Webp conversion via the %1$s %2$sWebP Converter%3$s extension.', 'w3-total-cache' ), 'W3 Total Cache', diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Page.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Page.php index a3eb782c..72ce897f 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Page.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Page.php @@ -110,7 +110,7 @@ class PageSpeed_Page { 'Before you can get started using the Google PageSpeed tool, you’ll first need to authorize access. Please click %1$s.', 'w3-total-cache' ), - '' . esc_html__( 'here', 'w3-total-cache' ) . '' + '' . esc_html__( 'here', 'w3-total-cache' ) . '' ), ) ); @@ -155,7 +155,7 @@ class PageSpeed_Page { } else { $api_response['time'] = time(); $api_response['display_time'] = \current_time( 'M jS, Y g:ia', false ); - update_option( 'w3tc_pagespeed_data_' . $encoded_url, wp_json_encode( $api_response ), Util_PageSpeed::get_cache_life() ); + update_option( 'w3tc_pagespeed_data_' . $encoded_url, wp_json_encode( $api_response ), 'yes' ); } } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Page_View.css b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Page_View.css index 07a88825..2108235e 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Page_View.css +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Page_View.css @@ -1,35 +1,39 @@ #w3tcps_container { - max-width: 1234px; + max-width: 1234px; } .w3tcps_loading .spinner { - margin-top: 0; - float: left; + margin-top: 0; + float: left; } .w3tcps_content .postbox { - border: unset; - box-shadow: unset; - background: unset; + border: unset; + box-shadow: unset; + background: unset; +} + +.w3tcps_content .postbox-title { + border: unset !important; } .w3tcps_content .postbox .hndle { - border-bottom: unset !important; + border-bottom: unset !important; } .w3tcps_timestamp { - margin-right: 5px; + margin-right: 5px; } #w3tcps-core-metrics .inside { - display: flex; - flex-wrap: wrap; - gap: 5px; + display: flex; + flex-wrap: wrap; + gap: 5px; } .w3tcps_metric { - min-width: 255px; - flex: 1 1 33%; + min-width: 255px; + flex: 1 1 33%; box-sizing: border-box; border: 1px solid #c3c4c7; background: #fff; @@ -37,7 +41,7 @@ .w3tcps_metric_title { font-size: 14px; - border-bottom: 1px solid #ccd0d4; + border-bottom: 1px solid #ccd0d4; } .w3tcps_metric_title, @@ -47,27 +51,27 @@ } .w3tcps_item_desciption { - background-color: hsla(210, 17%, 77%, 0.1); - padding: 15px !important; - margin: 0 !important; + background-color: hsla(210, 17%, 77%, 0.1); + padding: 15px !important; + margin: 0 !important; } .w3tcps_breakdown_items_container { - display: flex; - flex-direction: row; - flex-wrap: wrap; - grid-row-gap: .75em; - grid-column-gap: .75em; - padding: .75em; + display: flex; + flex-direction: row; + flex-wrap: wrap; + grid-row-gap: .75em; + grid-column-gap: .75em; + padding: .75em; } .w3tcps_breakdown_items_container .w3tcps_breakdown_items_table, .w3tcps_breakdown_items_container .w3tcps_instruction { - flex: 49%; - flex-grow: 1; - align-self: flex-start; - border: 1px solid #ccd0d4; - border-collapse: collapse; + flex: 49%; + flex-grow: 1; + align-self: flex-start; + border: 1px solid #ccd0d4; + border-collapse: collapse; } .w3tcps_breakdown_items_table { @@ -76,12 +80,12 @@ .w3tcps_breakdown_items_table th, .w3tcps_breakdown_items_table td { - text-align: left; + text-align: left; padding: 8px 10px; } .w3tcps_breakdown_items_table .copyurl { - cursor: pointer; + cursor: pointer; } .w3tcps_breakdown_items_table tr:nth-child(even) { @@ -89,11 +93,11 @@ } .w3tcps_instruction { - padding: 0; + padding: 0; } .w3tc_instruction_copy { - padding: 10px; + padding: 10px; } #w3tcps_desktop { @@ -104,9 +108,9 @@ cursor: pointer; } -.w3tcps_breakdown_items_toggle .dashicons{ +.w3tcps_breakdown_items_toggle .dashicons { position: absolute; - right: 35px; + right: 35px; } .w3tcps_range { @@ -118,17 +122,17 @@ } .w3tcps_breakdown_items { - margin: 0; - padding: 0; + margin: 0; + padding: 0; display: none; - background: #ffffff; + background: #ffffff; } #w3tcps-screenshots .inside { - display: flex; - flex-direction: row; - flex-wrap: wrap; - gap: 5px; + display: flex; + flex-direction: row; + flex-wrap: wrap; + gap: 5px; } #w3tcps-screenshots .inside .w3tcps_screenshots_final_mobile, @@ -148,20 +152,20 @@ } .w3tcps_audit_results { - border: 1px solid #c3c4c7; - border-top: 0; - border-bottom: 0; + border: 1px solid #c3c4c7; + border-top: 0; + border-bottom: 0; background: #fff; - min-width: 320px; + min-width: 320px; } .w3tcps_screenshots_other_mobile, .w3tcps_screenshots_final_mobile, .w3tcps_screenshots_other_desktop, .w3tcps_screenshots_final_desktop { - border: 1px solid #c3c4c7; + border: 1px solid #c3c4c7; background: #fff; - min-width: 250px + min-width: 250px } .w3tcps_final_screenshot_container { @@ -171,12 +175,12 @@ .opportunities .audits, .diagnostics .audits, .passed_audits .audits { - padding: 0; - margin: 0; - border-left: 2px solid #72aee6; - border-right: 0; - border-top: 0; - border-bottom: 1px solid #ccd0d4; + padding: 0 !important; + margin: 0 !important; + border-left: 2px solid #72aee6; + border-right: 0; + border-top: 0; + border-bottom: 1px solid #ccd0d4; } .opportunities .w3tcps_range, @@ -195,7 +199,7 @@ .w3tcps_other_screenshot_container, .w3tcps_final_screenshot_container { - text-align: center; + text-align: center; } .w3tcps_screenshots_other_mobile img, @@ -215,9 +219,9 @@ .w3tcps_blank::before { border: calc(0.2 * 14px) solid #bdbdbd; border-radius: 100%; - width: 12px; + width: 12px; height: 12px; - min-width: 12px; + min-width: 12px; } .w3tcps_fail::before { @@ -232,13 +236,13 @@ background: #fa3; width: calc(14px * 0.88); height: calc(14px * 0.88); - min-width: 12px; + min-width: 12px; } .w3tcps_pass::before { border-radius: 100%; background: #0c6; - min-width: 14px; + min-width: 14px; } .gauge { @@ -250,7 +254,7 @@ margin: 0 10px; } -.gauge:before{ +.gauge:before { content: ""; display: block; padding-top: 50%; @@ -267,70 +271,70 @@ } .gauge .percentage { - position: absolute; + position: absolute; top: -1px; left: -1px; bottom: 0; right: -1px; background-color: var(--background, #fff); - transform:rotate(var(--rotation)); - transform-origin: bottom center; + transform: rotate(var(--rotation)); + transform-origin: bottom center; transition-duration: 600; } .gauge .value { - position:absolute; - bottom:0%; - left:0; - width:100%; + position: absolute; + bottom: 0%; + left: 0; + width: 100%; text-align: center; } .w3tc_fancy_header { - background: #0e1920; - border-bottom: 6px solid #cdeae7; - height: 2.75em; - position: relative; + background: #0e1920; + border-bottom: 6px solid #cdeae7; + height: 2.75em; + position: relative; } .w3tc_fancy_title { - color: #fff; - position: absolute; - bottom: 0; - padding-left: 50px; + color: #fff; + position: absolute; + bottom: 0; + padding-left: 50px; } -.w3tc_fancy_title > span:nth-of-type(1), -.w3tc_fancy_title > span:nth-of-type(2), -.w3tc_fancy_title > span:nth-of-type(3) { - font-size: 2em; +.w3tc_fancy_title>span:nth-of-type(1), +.w3tc_fancy_title>span:nth-of-type(2), +.w3tc_fancy_title>span:nth-of-type(3) { + font-size: 2em; } -.w3tc_fancy_title > span:nth-of-type(2) { - color: #30bec4; +.w3tc_fancy_title>span:nth-of-type(2) { + color: #30bec4; } -.w3tc_fancy_title > span:nth-of-type(4) { - font-size: 1.8em; - font-style: italic; +.w3tc_fancy_title>span:nth-of-type(4) { + font-size: 1.8em; + font-style: italic; } .w3tc_fancy_icon { - position: absolute; - top: 3px; - left: 3px; - width: 37px; - height: 37px; + position: absolute; + top: 3px; + left: 3px; + width: 37px; + height: 37px; } @media only screen and (max-width: 1024px) { - .w3tcps_breakdown_items_container { - flex-direction: column; - } + .w3tcps_breakdown_items_container { + flex-direction: column; + } } @media only screen and (max-width: 600px) { - .w3tcps_audit_results { - border-top: 1px solid #ccd0d4; - } -} + .w3tcps_audit_results { + border-top: 1px solid #ccd0d4; + } +} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Page_View.js b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Page_View.js index 67016f01..26e97656 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Page_View.js +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Page_View.js @@ -69,14 +69,11 @@ jQuery(document).ready(function ($) { function w3tcps_breakdown_items_toggle() { if (window.w3tc_ga) { w3tc_ga( - 'send', 'event', + 'metric', { eventCategory: 'w3tc_pagespeed', - eventAction: 'metric', - eventLabel: $(this).attr('gatitle'), - eventValue: 0, - transport: 'beacon' + eventLabel: $(this).attr('gatitle') } ); } @@ -95,14 +92,11 @@ jQuery(document).ready(function ($) { function w3tcps_mobile_toggle() { if (window.w3tc_ga) { w3tc_ga( - 'send', 'event', + 'mobile_tab', { eventCategory: 'w3tc_pagespeed', - eventAction: 'mobile_tab', - eventLabel: $('#w3tcps_control_mobile').text(), - eventValue: 0, - transport: 'beacon' + eventLabel: $('#w3tcps_control_mobile').text() } ); } @@ -123,14 +117,11 @@ jQuery(document).ready(function ($) { function w3tcps_desktop_toggle() { if (window.w3tc_ga) { w3tc_ga( - 'send', 'event', + 'desktop_tab', { eventCategory: 'w3tc_pagespeed', - eventAction: 'desktop_tab', - eventLabel: $('#w3tcps_control_desktop').text(), - eventValue: 0, - transport: 'beacon' + eventLabel: $('#w3tcps_control_desktop').text() } ); } @@ -153,14 +144,11 @@ jQuery(document).ready(function ($) { if (window.w3tc_ga) { w3tc_ga( - 'send', 'event', + 'filter_tab', { eventCategory: 'w3tc_pagespeed', - eventAction: 'filter_tab', - eventLabel: $(this).text(), - eventValue: 0, - transport: 'beacon' + eventLabel: $(this).text() } ); } @@ -247,14 +235,11 @@ jQuery(document).ready(function ($) { $('.w3tcps_content').on('click', '.w3tcps_analyze', function () { if (window.w3tc_ga) { w3tc_ga( - 'send', 'event', + 're_analyze', { eventCategory: 'w3tc_pagespeed', - eventAction: 're_analyze', - eventLabel: $(this).closest('.page_post').find('.w3tcps_buttons').attr('page_post_url'), - eventValue: 0, - transport: 'beacon' + eventLabel: $(this).closest('.page_post').find('.w3tcps_buttons').attr('page_post_url') } ); } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Widget.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Widget.php index 8b0b6e42..9aacff34 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Widget.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PageSpeed_Widget.php @@ -129,7 +129,7 @@ class PageSpeed_Widget { 'Before you can get started using the Google PageSpeed tool, you’ll first need to authorize access. Please click %1$s.', 'w3-total-cache' ), - '' . esc_html__( 'here', 'w3-total-cache' ) . '' + '' . esc_html__( 'here', 'w3-total-cache' ) . '' ), ) ); @@ -174,7 +174,7 @@ class PageSpeed_Widget { } else { $api_response['time'] = time(); $api_response['display_time'] = \current_time( 'M jS, Y g:ia', false ); - update_option( 'w3tc_pagespeed_data_' . $home_url, wp_json_encode( $api_response ), Util_PageSpeed::get_cache_life() ); + update_option( 'w3tc_pagespeed_data_' . $home_url, wp_json_encode( $api_response ), 'yes' ); } } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PgCache_ContentGrabber.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PgCache_ContentGrabber.php index b0340fa1..0cf24efc 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PgCache_ContentGrabber.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PgCache_ContentGrabber.php @@ -104,16 +104,29 @@ class PgCache_ContentGrabber { private $output_size = 0; /** - * - * * @var bool If cached page should be displayed after init */ var $_late_init = false; + /** + * @var bool late caching + */ + var $_late_caching = false; + var $_cached_data = null; var $_old_exists = false; + /** + * @var bool Nginx memcached flag + */ + var $_nginx_memcached = false; + + /** + * @var string + */ + var $_page_group; + /** * PHP5 Constructor */ diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PgCache_Plugin.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PgCache_Plugin.php index 70cb8d5a..7f87dd42 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PgCache_Plugin.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/PgCache_Plugin.php @@ -327,7 +327,7 @@ class PgCache_Plugin { $menu_items['20110.pagecache'] = array( 'id' => 'w3tc_flush_pgcache', 'parent' => 'w3tc_flush', - 'title' => __( 'Page Cache: All', 'w3-total-cache' ), + 'title' => __( 'Page Cache', 'w3-total-cache' ), 'href' => wp_nonce_url( admin_url( 'admin.php?page=w3tc_dashboard&w3tc_flush_pgcache' ), 'w3tc' ), ); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Root_AdminMenu.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Root_AdminMenu.php index ddd8bdf4..02d19d86 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Root_AdminMenu.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Root_AdminMenu.php @@ -218,6 +218,7 @@ class Root_AdminMenu { if ( ! empty( Util_Request::get_string( 'w3tc_dbcluster_config' ) ) ) { $options_dbcache = new DbCache_Page(); $options_dbcache->dbcluster_config(); + return; } /** @@ -310,8 +311,6 @@ class Root_AdminMenu { do_action( 'w3tc_settings_page-' . $this->_page ); // phpcs:ignore WordPress.NamingConventions.ValidHookName.UseUnderscores - $view->render_footer(); - break; } } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Root_Loader.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Root_Loader.php index 6df93f89..92422a60 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Root_Loader.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Root_Loader.php @@ -40,7 +40,7 @@ class Root_Loader { $plugins[] = new DbCache_Plugin(); } - if ( $c->get_boolean( 'objectcache.enabled' ) ) { + if ( $c->getf_boolean( 'objectcache.enabled' ) ) { $plugins[] = new ObjectCache_Plugin(); } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/SetupGuide_Plugin_Admin.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/SetupGuide_Plugin_Admin.php index 4b2e03bc..4e7d00ba 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/SetupGuide_Plugin_Admin.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/SetupGuide_Plugin_Admin.php @@ -488,7 +488,7 @@ class SetupGuide_Plugin_Admin { if ( wp_verify_nonce( Util_Request::get_string( '_wpnonce' ), 'w3tc_wizard' ) ) { $config = new Config(); $results = array( - 'enabled' => $config->get_boolean( 'objectcache.enabled' ), + 'enabled' => $config->getf_boolean( 'objectcache.enabled' ), 'engine' => $config->get_string( 'objectcache.engine' ), 'elapsed' => null, ); @@ -527,7 +527,7 @@ class SetupGuide_Plugin_Admin { wp_send_json_success( array( - 'enabled' => $config->get_boolean( 'objectcache.enabled' ), + 'enabled' => $config->getf_boolean( 'objectcache.enabled' ), 'engine' => $config->get_string( 'objectcache.engine' ), ) ); @@ -556,7 +556,7 @@ class SetupGuide_Plugin_Admin { $is_updating = false; $success = false; $config = new Config(); - $old_enabled = $config->get_boolean( 'objectcache.enabled' ); + $old_enabled = $config->getf_boolean( 'objectcache.enabled' ); $old_engine = $config->get_string( 'objectcache.engine' ); $allowed_engines = array( '', @@ -588,7 +588,7 @@ class SetupGuide_Plugin_Admin { $f->objectcache_flush(); } - if ( $config->get_boolean( 'objectcache.enabled' ) === $enable && + if ( $config->getf_boolean( 'objectcache.enabled' ) === $enable && ( ! $enable || $config->get_string( 'objectcache.engine' ) === $engine ) ) { $success = true; $message = __( 'Settings updated', 'w3-total-cache' ); @@ -608,7 +608,7 @@ class SetupGuide_Plugin_Admin { 'message' => $message, 'enable' => $enable, 'engine' => $engine, - 'current_enabled' => $config->get_boolean( 'objectcache.enabled' ), + 'current_enabled' => $config->getf_boolean( 'objectcache.enabled' ), 'current_engine' => $config->get_string( 'objectcache.engine' ), 'previous_enabled' => $old_enabled, 'previous_engine' => $old_engine, @@ -814,6 +814,67 @@ class SetupGuide_Plugin_Admin { } } + /** + * Admin-Ajax: Get the imageservice settings. + * + * @since 2.3.4 + * + * @see \W3TC\Config::is_extension_active() + * @see \W3TC\Config::get_string() + */ + public function get_imageservice_settings() { + if ( wp_verify_nonce( Util_Request::get_string( '_wpnonce' ), 'w3tc_wizard' ) ) { + $config = new Config(); + + wp_send_json_success( + array( + 'enabled' => $config->is_extension_active( 'imageservice' ), + ) + ); + } else { + wp_send_json_error( __( 'Security violation', 'w3-total-cache' ), 403 ); + } + } + + /** + * Admin-Ajax: Configure image optimization. + * + * @since 2.3.4 + * + * @see \W3TC\Dispatcher::component() + * @see \W3TC\Config::get_boolean() + * @see \W3TC\Config::set() + * @see \W3TC\Config::save() + * @see \W3TC\Dispatcher::component() + * @see \W3TC\CacheFlush::flush_posts() + * + * @uses $_POST['enable'] + */ + public function config_imageservice() { + if ( wp_verify_nonce( Util_Request::get_string( '_wpnonce' ), 'w3tc_wizard' ) ) { + $enable = ! empty( Util_Request::get_string( 'enable' ) ); + $config = new Config(); + + if ( ! empty( $enable ) ) { + Extensions_Util::activate_extension( 'imageservice', $config ); + } else { + Extensions_Util::deactivate_extension( 'imageservice', $config ); + } + + $is_enabled = $config->is_extension_active( 'imageservice' ); + + wp_send_json_success( + array( + 'success' => $is_enabled === $enable, + 'enable' => $enable, + 'imageservice_enabled' => $is_enabled, + ) + ); + } else { + wp_send_json_error( __( 'Security violation', 'w3-total-cache' ), 403 ); + } + } + /** * Display the terms of service dialog if needed. * @@ -889,7 +950,7 @@ class SetupGuide_Plugin_Admin { 'install_version' => esc_attr( $state->get_string( 'common.install_version' ) ), 'w3tc_edition' => esc_attr( Util_Environment::w3tc_edition( $config ) ), 'list_widgets' => esc_attr( Util_Widget::list_widgets() ), - 'ga_profile' => ( defined( 'W3TC_DEVELOPER' ) && W3TC_DEVELOPER ) ? 'UA-2264433-7' : 'UA-2264433-8', + 'ga_profile' => ( defined( 'W3TC_DEVELOPER' ) && W3TC_DEVELOPER ) ? 'G-Q3CHQJWERM' : 'G-5TFS8M5TTY', 'tos_choice' => Licensing_Core::get_tos_choice(), 'track_usage' => $config->get_boolean( 'common.track_usage' ), 'test_complete_msg' => __( @@ -912,6 +973,7 @@ class SetupGuide_Plugin_Admin { 'enabled' => __( 'Enabled', 'w3-total-cache' ), 'notEnabled' => __( 'Not Enabled', 'w3-total-cache' ), 'dashboardUrl' => esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_dashboard' ) ), + 'objcache_disabled' => ( ! $config->getf_boolean( 'objectcache.enabled' ) && has_filter( 'w3tc_config_item_objectcache.enabled' ) ), ), ), ), @@ -1022,6 +1084,20 @@ class SetupGuide_Plugin_Admin { 'config_browsercache', ), ), + array( + 'tag' => 'wp_ajax_w3tc_get_imageservice_settings', + 'function' => array( + $this, + 'get_imageservice_settings', + ), + ), + array( + 'tag' => 'wp_ajax_w3tc_config_imageservice', + 'function' => array( + $this, + 'config_imageservice', + ), + ), array( 'tag' => 'wp_ajax_w3tc_get_lazyload_settings', 'function' => array( @@ -1059,6 +1135,10 @@ class SetupGuide_Plugin_Admin { 'id' => 'browsercache', 'text' => __( 'Browser Cache', 'w3-total-cache' ), ), + array( + 'id' => 'imageservice', + 'text' => __( 'Image Optimization', 'w3-total-cache' ), + ), array( 'id' => 'lazyload', 'text' => __( 'Lazy Load', 'w3-total-cache' ), @@ -1198,15 +1278,15 @@ class SetupGuide_Plugin_Admin { ) . '

        ' . esc_html__( 'W3 Total Cache', 'w3-total-cache' ) . ' ' . esc_html__( 'can help you speed up dynamic pages by persistently storing objects.', 'w3-total-cache' ) . - '

        -

        - - -

        - + '

        ' . + ( ! $config->getf_boolean( 'objectcache.enabled' ) && has_filter( 'w3tc_config_item_objectcache.enabled' ) ? '

        ' . esc_html__( 'Object Cache is disabled via filter.', 'w3-total-cache' ) . '

        ' : '' ) . + ( ! has_filter( 'w3tc_config_item_objectcache.enabled' ) ? '

        + + +

        ' : '' ) . + ' @@ -1265,6 +1345,18 @@ class SetupGuide_Plugin_Admin { ', ), + array( // Image Service. + 'headline' => __( 'Image Optimization', 'w3-total-cache' ), + 'id' => 'io1', + 'markup' => '

        ' . + esc_html__( + 'Adds the ability to convert images in the Media Library to the modern WebP format for better performance.', + 'w3-total-cache' + ) . '

        +

        +

        ', + ), array( // Lazy load. 'headline' => __( 'Lazy Load', 'w3-total-cache' ), 'id' => 'll1', @@ -1314,16 +1406,31 @@ class SetupGuide_Plugin_Admin { '' . esc_html__( 'UNKNOWN', 'w3-total-cache' ) . '' ) . '

        ' . - sprintf( - // translators: 1: HTML strong open tag, 2: HTML strong close tag, 3: Label. - esc_html__( - '%1$sObject Cache%2$s engine set to %1$s%3$s%2$s', - 'w3-total-cache' - ), - '', - '', - '' . esc_html__( 'UNKNOWN', 'w3-total-cache' ) . '' - ) . '

        + ( + ! $config->getf_boolean( 'objectcache.enabled' ) && has_filter( 'w3tc_config_item_objectcache.enabled' ) + ? + sprintf( + // translators: 1: HTML strong open tag, 2: HTML strong close tag. + esc_html__( + '%1$sObject Cache%2$s is %1$sdisabled via filter%2$s', + 'w3-total-cache' + ), + '', + '' + ) + : + sprintf( + // translators: 1: HTML strong open tag, 2: HTML strong close tag, 3: Label. + esc_html__( + '%1$sObject Cache%2$s engine set to %1$s%3$s%2$s', + 'w3-total-cache' + ), + '', + '', + '' . esc_html__( 'UNKNOWN', 'w3-total-cache' ) . '' + ) + ) . + '

        ' . sprintf( // translators: 1: HTML strong open tag, 2: HTML strong close tag, 3: Label. @@ -1335,6 +1442,16 @@ class SetupGuide_Plugin_Admin { '', '' . esc_html__( 'UNKNOWN', 'w3-total-cache' ) . '' ) . '

        +

        ' . sprintf( + // translators: 1: HTML strong open tag, 2: HTML strong close tag, 3: Label. + esc_html__( + '%1$sImage Optimization%2$s enabled? %1$s%3$s%2$s', + 'w3-total-cache' + ), + '', + '', + '' . esc_html__( 'UNKNOWN', 'w3-total-cache' ) . '' + ) . '

        ' . sprintf( // translators: 1: HTML strong open tag, 2: HTML strong close tag, 3: Label. esc_html__( @@ -1363,10 +1480,17 @@ class SetupGuide_Plugin_Admin { 'Please visit %1$sGeneral Settings%2$s to learn more about these features.', 'w3-total-cache' ), - '', + '', + '' + ) . '

        +

        ' . esc_html__( 'Google PageSpeed Tool', 'w3-total-cache' ) . '

        +

        ' . sprintf( + // translators: 1: Anchor/link open tag, 2: Anchor/link close tag. + esc_html__( + 'Google PageSpeed Insights can be used to analyze your homepage and provide an explanation of metrics and recommendations for improvements using W3 Total Cache features/extensions. This tool is enabled by default but will not function until authorization is granted, which can be done on the %1$sGeneral Settings%2$s page.', + 'w3-total-cache' + ), + '', '' ) . '

        ' . esc_html__( 'Need help?', 'w3-total-cache' ) . '

        diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Support_Page.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Support_Page.php index 40381f81..547f16f7 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Support_Page.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Support_Page.php @@ -74,7 +74,8 @@ class Support_Page { Licensing_Core::terms_accept(); include W3TC_DIR . '/Support_Page_View_DoneContent.php'; - } else + } else { include W3TC_DIR . '/Support_Page_View_PageContent.php'; + } } } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Support_Page_View_DoneContent.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Support_Page_View_DoneContent.php index 4f00ba8f..101f6e67 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Support_Page_View_DoneContent.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Support_Page_View_DoneContent.php @@ -1,3 +1,4 @@ +
        Thank you for filling out the form
        diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/SystemOpCache_GeneralPage_View.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/SystemOpCache_GeneralPage_View.php index c5d91bb4..9b0be095 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/SystemOpCache_GeneralPage_View.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/SystemOpCache_GeneralPage_View.php @@ -4,9 +4,23 @@ namespace W3TC; if ( ! defined( 'W3TC' ) ) { die(); } -?> - +Util_Ui::postbox_header_tabs( + esc_html__( 'Opcode Cache', 'w3-total-cache' ), + esc_html__( + 'Opcode cache is a powerful feature that enhances the performance of a WordPress website by caching + compiled PHP code. By storing pre-compiled code in memory, opcode cache eliminates the need for + repetitive interpretation and compilation of PHP files, resulting in significantly faster execution + times. Opcode cache reduces server load and improves response times, ultimately enhancing the + overall speed and responsiveness of your WordPress site. If opcode cache is available on the + hosting server it will automatically be selected in the dropdown and enabled.', + 'w3-total-cache' + ), + '', + 'system_opcache' +); + +?>
        -' -); -?> diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UsageStatistics_GeneralPage_View.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UsageStatistics_GeneralPage_View.php index 5a5cc597..eda76043 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UsageStatistics_GeneralPage_View.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UsageStatistics_GeneralPage_View.php @@ -1,27 +1,47 @@ +Util_Ui::postbox_header_tabs( + esc_html__( 'Statistics', 'w3-total-cache' ), + esc_html__( + 'Cache Usage Statistics is a feature that provides valuable insights into the performance of your website\'s + caching system. It displays detailed data regarding the utilization of your cache and overall performance + metrics. By monitoring these statistics, website owners can identify areas of improvement, optimize their + caching settings, and ultimately enhance the speed and responsiveness of their WordPress site, resulting + in a smoother user experience for visitors.', + 'w3-total-cache' + ), + '', + 'stats', + Util_UI::admin_url( 'admin.php?page=w3tc_stats' ) +); - - 'stats.enabled', - 'label' => esc_html__( 'Cache usage statistics', 'w3-total-cache' ), - 'control' => 'checkbox', +?> +
        + 'stats.enabled', + 'label' => esc_html__( 'Cache usage statistics', 'w3-total-cache' ), + 'control' => 'checkbox', 'checkbox_label' => __( 'Enable', 'w3-total-cache' ), - 'disabled' => ( $is_pro ? null : true ), - 'excerpt' => __( 'Enable statistics collection. Note that this consumes additional resources and is not recommended to be run continuously.', - 'w3-total-cache' ), - 'description' => array( + 'disabled' => ( $is_pro ? null : true ), + 'excerpt' => __( 'Enable statistics collection. Note that this consumes additional resources and is not recommended to be run continuously.', 'w3-total-cache' ), + 'description' => array( __( 'Statistics provides near-complete transparency into the behavior of your caching performance, allowing you to identify opportunities to further improve your website speed and ensure operations are working as expected. Includes metrics like cache sizes, object lifetimes, hit vs miss ratio, etc across every caching method configured in your settings.', 'w3-total-cache' ), __( 'Some statistics are available directly on your Performance Dashboard, however, the comprehensive suite of statistics are available on the Statistics screen. Web server logs created by Nginx or Apache can be analyzed if accessible.', 'w3-total-cache' ), wp_kses( @@ -34,76 +54,92 @@ Util_Ui::config_item_pro( array( array( 'a' => array( 'href' => array() ) ) ), ), - ) ); -Util_Ui::config_item( array( - 'key' => 'stats.slot_seconds', - 'label' => __( 'Slot time (seconds):', 'w3-total-cache' ), - 'control' => 'textbox', - 'textbox_type' => 'number', - 'description' => __( 'The duration of time in seconds to collect statistics per interval.', 'w3-total-cache' ), - 'show_in_free' => false, - ) ); -Util_Ui::config_item( array( - 'key' => 'stats.slots_count', - 'label' => __( 'Slots collected:', 'w3-total-cache' ), - 'control' => 'textbox', - 'textbox_type' => 'number', - 'description' => __( 'The number of intervals that are represented in the graph.', 'w3-total-cache' ), - 'show_in_free' => false, - ) ); + ) +); -Util_Ui::config_item( array( - 'key' => 'stats.cpu.enabled', - 'control' => 'checkbox', +Util_Ui::config_item( + array( + 'key' => 'stats.slot_seconds', + 'label' => __( 'Slot time (seconds):', 'w3-total-cache' ), + 'control' => 'textbox', + 'textbox_type' => 'number', + 'description' => __( 'The duration of time in seconds to collect statistics per interval.', 'w3-total-cache' ), + 'show_in_free' => false, + ) +); + +Util_Ui::config_item( + array( + 'key' => 'stats.slots_count', + 'label' => __( 'Slots collected:', 'w3-total-cache' ), + 'control' => 'textbox', + 'textbox_type' => 'number', + 'description' => __( 'The number of intervals that are represented in the graph.', 'w3-total-cache' ), + 'show_in_free' => false, + ) +); + +Util_Ui::config_item( + array( + 'key' => 'stats.cpu.enabled', + 'control' => 'checkbox', 'checkbox_label' => __( 'Use the system reported averages of CPU resource usage.', 'w3-total-cache' ), - 'description' => __( 'Collect CPU usage', 'w3-total-cache' ), - 'show_in_free' => false, - ) ); -Util_Ui::config_item( array( - 'key' => 'stats.access_log.enabled', - 'control' => 'checkbox', + 'description' => __( 'Collect CPU usage', 'w3-total-cache' ), + 'show_in_free' => false, + ) +); +Util_Ui::config_item( + array( + 'key' => 'stats.access_log.enabled', + 'control' => 'checkbox', 'checkbox_label' => __( 'Parse server access log', 'w3-total-cache' ), - 'disabled' => ( $is_pro ? null : true ), - 'description' => __( 'Enable collecting statistics from an Access Log. This provides much more precise statistics.', 'w3-total-cache' ), - 'show_in_free' => false, - ) ); -Util_Ui::config_item( array( - 'key' => 'stats.access_log.webserver', - 'label' => __( 'Webserver:', 'w3-total-cache' ), - 'control' => 'selectbox', + 'disabled' => ( $is_pro ? null : true ), + 'description' => __( 'Enable collecting statistics from an Access Log. This provides much more precise statistics.', 'w3-total-cache' ), + 'show_in_free' => false, + ) +); + +Util_Ui::config_item( + array( + 'key' => 'stats.access_log.webserver', + 'label' => __( 'Webserver:', 'w3-total-cache' ), + 'control' => 'selectbox', 'selectbox_values' => array( 'apache' => 'Apache', - 'nginx' => 'Nginx' + 'nginx' => 'Nginx', ), - 'description' => __( 'Webserver type generating access logs.' ,'w3-total-cache' ), + 'description' => __( 'Webserver type generating access logs.', 'w3-total-cache' ), 'show_in_free' => false, - ) ); -Util_Ui::config_item( array( - 'key' => 'stats.access_log.filename', - 'label' => __( 'Access Log Filename:', 'w3-total-cache' ), - 'control' => 'textbox', - 'textbox_size' => 60, - 'description' => __( 'Where your access log is located.', 'w3-total-cache' ), - 'control_after' => - '', - 'show_in_free' => false, - ) ); -Util_Ui::config_item( array( - 'key' => 'stats.access_log.format', - 'label' => __( 'Access Log Format:', 'w3-total-cache' ), - 'control' => 'textbox', - 'textbox_size' => 60, - 'description' => __( 'Format of your access log from webserver configuration.', 'w3-total-cache' ), - 'control_after' => - '', - 'show_in_free' => false, - ) ); + ) +); + +Util_Ui::config_item( + array( + 'key' => 'stats.access_log.filename', + 'label' => __( 'Access Log Filename:', 'w3-total-cache' ), + 'control' => 'textbox', + 'textbox_size' => 60, + 'description' => __( 'Where your access log is located.', 'w3-total-cache' ), + 'control_after' => '', + 'show_in_free' => false, + ) +); + +Util_Ui::config_item( + array( + 'key' => 'stats.access_log.format', + 'label' => __( 'Access Log Format:', 'w3-total-cache' ), + 'control' => 'textbox', + 'textbox_size' => 60, + 'description' => __( 'Format of your access log from webserver configuration.', 'w3-total-cache' ), + 'control_after' => '', + 'show_in_free' => false, + ) +); + ?>
        - '; + + $buffer = preg_replace( + '~]*)*>~Ui', + $footer_script . '\\0', + $buffer, + 1 + ); + + return $buffer; + } + + /** + * Filters script tags that are flaged as deferred. This is used to prevent Minify from touching scripts deferred by this feature. + * + * @since 2.4.2 + * + * @param array $script_tags array of script tags. + * + * @return array + */ + public function w3tc_minify_js_script_tags( $script_tags ) { + if ( ! is_null( $this->mutator ) ) { + $script_tags = $this->mutator->w3tc_minify_js_script_tags( $script_tags ); + } + + return $script_tags; + } + + /** + * Renders the user experience defer JS settings page. + * + * @since 2.4.2 + * + * @return void + */ + public function w3tc_userexperience_page() { + if ( Util_Environment::is_w3tc_pro( $this->config ) ) { + include __DIR__ . '/UserExperience_DeferScripts_Page_View.php'; + } + } + + /** + * Specify config key typing for fields that need it. + * + * @since 2.4.2 + * + * @param mixed $descriptor Descriptor. + * @param mixed $key Compound key array. + * + * @return array + */ + public function w3tc_config_key_descriptor( $descriptor, $key ) { + if ( is_array( $key ) && 'user-experience-defer-scripts.includes' === implode( '.', $key ) ) { + $descriptor = array( 'type' => 'array' ); + } + + return $descriptor; + } + + /** + * Performs actions on save. + * + * @since 2.4.2 + * + * @param array $data Array of save data. + * + * @return array + */ + public function w3tc_save_options( $data ) { + $new_config = $data['new_config']; + $old_config = $data['old_config']; + + if ( + $new_config->get_array( array( 'user-experience-defer-scripts', 'timeout' ) ) !== $old_config->get_array( array( 'user-experience-defer-scripts', 'timeout' ) ) + || $new_config->get_array( array( 'user-experience-defer-scripts', 'includes' ) ) !== $old_config->get_array( array( 'user-experience-defer-scripts', 'includes' ) ) + ) { + $minify_enabled = $this->config->get_boolean( 'minify.enabled' ); + $pgcache_enabled = $this->config->get_boolean( 'pgcache.enabled' ); + if ( $minify_enabled || $pgcache_enabled ) { + $state = Dispatcher::config_state(); + if ( $minify_enabled ) { + $state->set( 'minify.show_note.need_flush', true ); + } + if ( $pgcache_enabled ) { + $state->set( 'common.show_note.flush_posts_needed', true ); + } + $state->save(); + } + } + + return $data; + } +} + +$o = new UserExperience_DeferScripts_Extension(); +$o->run(); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_DeferScripts_Mutator.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_DeferScripts_Mutator.php new file mode 100644 index 00000000..03c929b7 --- /dev/null +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_DeferScripts_Mutator.php @@ -0,0 +1,175 @@ +config = $config; + } + + /** + * Runs User Experience DeferScripts Mutator. + * + * @since 2.4.2 + * + * @param string $buffer Buffer string containing browser output. + * + * @return string + */ + public function run( $buffer ) { + $r = apply_filters( + 'w3tc_deferscripts_mutator_before', + array( + 'buffer' => $buffer, + 'modified' => $this->modified, + ) + ); + + $buffer = $r['buffer']; + $this->modified = $r['modified']; + + $this->includes = $this->config->get_array( + array( + 'user-experience-defer-scripts', + 'includes', + ) + ); + + $buffer = preg_replace_callback( + '~]+>~is', + array( + $this, + 'tag_script', + ), + $buffer + ); + + return $buffer; + } + + /** + * Get modified status flag. + * + * @since 2.4.2 + * + * @return boolean + */ + public function content_modified() { + return $this->modified; + } + + /** + * Modifies script tag for script matched to be deferred. + * + * @since 2.4.2 + * + * @param array $matches array of matched JS entries. + * + * @return string + */ + public function tag_script( $matches ) { + $content = $matches[0]; + + if ( $this->is_content_included( $content ) ) { + $count = 0; + $content = preg_replace( + '~(\s)src=~is', + '$1data-lazy="w3tc" data-src=', + $content, + -1, + $count + ); + + if ( $count > 0 ) { + $this->modified = true; + } + } + + return $content; + } + + /** + * Checks if content has already been deferred. + * + * @since 2.4.2 + * + * @param string $content script tag string. + * + * @return boolean + */ + private function is_content_included( $content ) { + foreach ( $this->includes as $w ) { + if ( ! empty( $w ) ) { + if ( strpos( $content, $w ) !== false ) { + return true; + } + } + } + + return false; + } + + /** + * Filters out scripts so Minify doesn't touch deferred scripts. + * + * @since 2.4.2 + * + * @param array $script_tags array of script tags. + * + * @return array + */ + public function w3tc_minify_js_script_tags( $script_tags ) { + return array_values( + array_filter( + $script_tags, + function( $i ) { + return ! preg_match( '~\sdata-lazy="w3tc"\s~', $i ); + } + ) + ); + } +} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_DeferScripts_Page_View.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_DeferScripts_Page_View.php new file mode 100644 index 00000000..dab7e12f --- /dev/null +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_DeferScripts_Page_View.php @@ -0,0 +1,69 @@ +get( array( 'user-experience-defer-scripts', 'timeout' ) ) ) ) { + $c->set( array( 'user-experience-defer-scripts', 'timeout' ), 5000 ); + $c->save(); +} + +?> + +

        +

        + ', + '' + ), + array( + 'a' => array( + 'href' => array(), + 'target' => array(), + ), + ) + ); + ?> +

        + + array( 'user-experience-defer-scripts', 'timeout' ), + 'label' => esc_html__( 'Timeout:', 'w3-total-cache' ), + 'control' => 'textbox', + 'description' => esc_html__( 'Timeout (in milliseconds) to delay the loading of delayed scripts if no user action is taken during page load', 'w3-total-cache' ), + ) + ); + + Util_Ui::config_item( + array( + 'key' => array( 'user-experience-defer-scripts', 'includes' ), + 'label' => esc_html__( 'Delay list:', 'w3-total-cache' ), + 'control' => 'textarea', + 'description' => esc_html__( 'Specify keywords to match any attribute of script tags containing the "src" attribute. Include one entry per line, e.g. (googletagmanager.com, gtag/js, myscript.js, and name="myscript")', 'w3-total-cache' ), + ) + ); + + ?> +
        + diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_DeferScripts_Script.js b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_DeferScripts_Script.js new file mode 100644 index 00000000..2c890fe8 --- /dev/null +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_DeferScripts_Script.js @@ -0,0 +1,9 @@ +(function(w,k,o) { +var t=setTimeout(f,{config_timeout}); +k.forEach(function(e){w.addEventListener(e,f,o)}); +function f(){ +document.querySelectorAll("script[data-lazy='w3tc']").forEach(function(i){i.src = i.dataset.src}) +clearTimeout(t); +k.forEach(function(e){w.removeEventListener(e,f,o)}) +} +})(window,["keydown","mouseover","touchmove","touchstart","wheel"],{passive:!0}) diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_GeneralPage_View.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_GeneralPage_View.php index 41e26057..6ae6d205 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_GeneralPage_View.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_GeneralPage_View.php @@ -1,13 +1,35 @@ 'lazyload.configuration_overloaded' ) ); + ?> @@ -17,6 +39,7 @@ Util_Ui::config_overloading_button( array( 'key' => 'lazyload.configuration_over 'key' => 'lazyload.enabled', 'control' => 'checkbox', 'checkbox_label' => esc_html__( 'Lazy Load Images', 'w3-total-cache' ), + 'label_class' => 'w3tc_single_column', 'description' => esc_html__( 'Defer loading offscreen images.', 'w3-total-cache' ), ) ); @@ -25,6 +48,7 @@ Util_Ui::config_overloading_button( array( 'key' => 'lazyload.configuration_over array( 'key' => 'lazyload_googlemaps_general_settings', 'control' => 'none', + 'label_class' => 'w3tc_single_column', 'none_label' => esc_html__( 'Lazy Load Google Maps', 'w3-total-cache' ), 'excerpt' => wp_kses( sprintf( @@ -38,7 +62,7 @@ Util_Ui::config_overloading_button( array( 'key' => 'lazyload.configuration_over '', '', '', - '', + '', '' ), array( @@ -56,16 +80,50 @@ Util_Ui::config_overloading_button( array( 'key' => 'lazyload.configuration_over array( 'extension_id' => 'user-experience-emoji', 'checkbox_label' => esc_html__( 'Disable Emoji', 'w3-total-cache' ), - 'description' => esc_html__( 'Remove emojis support from your website.', 'w3-total-cache' ) + 'description' => esc_html__( 'Remove emojis support from your website.', 'w3-total-cache' ), + 'label_class' => 'w3tc_single_column', ) ); - ?> - 'user-experience-defer-scripts', + 'checkbox_label' => esc_html__( 'Delay Scripts', 'w3-total-cache' ), + 'description' => __( + 'Delay the loading of specified interal/external JavaScript sources on your pages separate from Minify. For best results it is recommended to enable the Minify feature to optimize internal sources and to then use the Delay JavaScript feature to handle external sources and/or any internal sources excluded from Minify.', + 'w3-total-cache' + ) . ( + Util_Environment::is_w3tc_pro( $config ) && $config->is_extension_active( 'user-experience-defer-scripts' ) + ? wp_kses( + sprintf( + // translators: 1 opening HTML a tag to W3TC User Experience page, 2 closing HTML a tag. + __( + ' Settings can be found on the %1$sUser Experience page%2$s.', + 'w3-total-cache' + ), + '', + '' + ), + array( + 'a' => array( + 'href' => array(), + ), + ) + ) + : '' + ), + 'label_class' => 'w3tc_single_column', + 'pro' => true, + 'disabled' => ! Util_Environment::is_w3tc_pro( $config ) ? true : false, + ) + ); + Util_Ui::config_item_extension_enabled( array( 'extension_id' => 'user-experience-oembed', 'checkbox_label' => esc_html__( 'Disable wp-embed script', 'w3-total-cache' ), - 'description' => esc_html__( 'Remove wp-embed.js script from your website. oEmbed functionality still works but you will not be able to embed other WordPress posts on your pages.', 'w3-total-cache' ) + 'description' => esc_html__( 'Remove wp-embed.js script from your website. oEmbed functionality still works but you will not be able to embed other WordPress posts on your pages.', 'w3-total-cache' ), + 'label_class' => 'w3tc_single_column', ) ); @@ -74,11 +132,11 @@ Util_Ui::config_overloading_button( array( 'key' => 'lazyload.configuration_over 'key' => 'jquerymigrate.disabled', 'control' => 'checkbox', 'checkbox_label' => esc_html__( 'Disable jquery-migrate on the front-end', 'w3-total-cache' ), + 'label_class' => 'w3tc_single_column', 'description' => esc_html__( 'Remove jquery-migrate support from your website front-end.', 'w3-total-cache' ), ) ); ?>
        - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_LazyLoad_Page_View.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_LazyLoad_Page_View.php index cfe7f580..d0372f1c 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_LazyLoad_Page_View.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_LazyLoad_Page_View.php @@ -14,7 +14,7 @@ $is_wp_google_map_plugin = ( in_array( 'wp-google-map-plugin/wp-google-map-plugi $is_google_maps_easy = ( in_array( 'google-maps-easy/gmp.php', $plugins, true ) ); ?> - +
        - +
        @@ -211,8 +211,5 @@ $is_google_maps_easy = ( in_array( 'google-maps-easy/gmp.php', $plugins, tru
        -

        - -

        diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_Page_View.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_Page_View.php index dcf9eff6..794034e4 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_Page_View.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_Page_View.php @@ -8,16 +8,17 @@ if ( !defined( 'W3TC' ) )

        Lazy loading is currently get_boolean( 'lazyload.enabled' ) ): ?> - enabled + enabled. - disabled + disabled. - .

        -
        - - -
        + +
        + + + +
        diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_Plugin_Admin.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_Plugin_Admin.php index 2f6eed7c..977e114e 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_Plugin_Admin.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/UserExperience_Plugin_Admin.php @@ -2,53 +2,69 @@ namespace W3TC; class UserExperience_Plugin_Admin { - function run() { + /** + * Runs the user experience feature. + * + * @return void + */ + public function run() { add_filter( 'w3tc_admin_menu', array( $this, 'w3tc_admin_menu' ) ); - add_action( 'w3tc_settings_page-w3tc_userexperience', - array( $this, 'w3tc_settings_page_w3tc_userexperience' ) ); - add_action( 'admin_init_w3tc_general', - array( '\W3TC\UserExperience_GeneralPage', 'admin_init_w3tc_general' ) ); - add_filter( 'w3tc_extensions', array( - '\W3TC\UserExperience_Plugin_Admin', - 'w3tc_extensions' ), - 10, 2 ); - + add_action( 'w3tc_settings_page-w3tc_userexperience', array( $this, 'w3tc_settings_page_w3tc_userexperience' ) ); + add_action( 'admin_init_w3tc_general', array( '\W3TC\UserExperience_GeneralPage', 'admin_init_w3tc_general' ) ); + add_filter( 'w3tc_extensions', array( '\W3TC\UserExperience_Plugin_Admin', 'w3tc_extensions' ), 10, 2 ); } - - + /** + * Set user experience admin menu item. + * + * @param array $menu + * + * @return array + */ public function w3tc_admin_menu( $menu ) { - $c = Dispatcher::config(); - $menu['w3tc_userexperience'] = array( - 'page_title' => __( 'User Experience', 'w3-total-cache' ), - 'menu_text' => __( 'User Experience', 'w3-total-cache' ), + 'page_title' => __( 'User Experience', 'w3-total-cache' ), + 'menu_text' => __( 'User Experience', 'w3-total-cache' ), 'visible_always' => false, - 'order' => 1200 + 'order' => 1200, ); return $menu; } - - - static public function w3tc_extensions( $extensions, $config ) { + /** + * Configures extensions for user experience. + * + * @param array $extensions + * @param object $config + * + * @return array + */ + public static function w3tc_extensions( $extensions, $config ) { + $extensions['user-experience-defer-scripts'] = array( + 'public' => false, + 'extension_id' => 'user-experience-defer-scripts', + 'path' => 'w3-total-cache/UserExperience_DeferScripts_Extension.php', + ); $extensions['user-experience-emoji'] = array( - 'public' => false, + 'public' => false, 'extension_id' => 'user-experience-emoji', - 'path' => 'w3-total-cache/UserExperience_Emoji_Extension.php' + 'path' => 'w3-total-cache/UserExperience_Emoji_Extension.php', ); $extensions['user-experience-oembed'] = array( - 'public' => false, + 'public' => false, 'extension_id' => 'user-experience-oembed', - 'path' => 'w3-total-cache/UserExperience_OEmbed_Extension.php' + 'path' => 'w3-total-cache/UserExperience_OEmbed_Extension.php', ); return $extensions; } - - + /** + * Render user experience advanced settings page. + * + * @return void + */ public function w3tc_settings_page_w3tc_userexperience() { $v = new UserExperience_Page(); $v->render_content(); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_Admin.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_Admin.php index 07ef2636..48336a7e 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_Admin.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_Admin.php @@ -1,27 +1,40 @@ $page - ), $params ); + } + + $params = array_merge( array( 'page' => $page ), $params ); } } @@ -29,164 +42,207 @@ class Util_Admin { } /** - * Redirect function to current admin page with errors and messages specified + * Redirect function to current admin page with errors and messages specified. * - * @param array $params - * @param array $errors - * @param array $notes - * @param bool $check_referrer + * @static + * + * @param array $params Parameters. + * @param array $errors Errors. + * @param array $notes Notes. + * @param bool $check_referrer Check referrer. * @return void */ - static public function redirect_with_custom_messages( $params, $errors = null, - $notes = null, $check_referrer = false ) { - if ( empty( $errors ) && Util_Admin::single_system_item( $notes ) ) { - Util_Admin::redirect( array_merge( $params, array( - 'w3tc_note' => $notes[0] ) ), $check_referrer ); + public static function redirect_with_custom_messages( $params, $errors = null, $notes = null, $check_referrer = false ) { + if ( empty( $errors ) && self::single_system_item( $notes ) ) { + self::redirect( array_merge( $params, array( 'w3tc_note' => $notes[0] ) ), $check_referrer ); return; } - if ( Util_Admin::single_system_item( $errors ) && empty( $notes ) ) { - Util_Admin::redirect( array_merge( $params, array( - 'w3tc_error' => $errors[0] ) ), $check_referrer ); + if ( self::single_system_item( $errors ) && empty( $notes ) ) { + self::redirect( array_merge( $params, array( 'w3tc_error' => $errors[0] ) ), $check_referrer ); return; } $message_id = uniqid(); - set_transient( 'w3tc_message', + update_option( + 'w3tc_message', array( - $message_id => array( 'errors' => $errors, 'notes' => $notes ) - ), 600 ); + $message_id => array( + 'errors' => $errors, + 'notes' => $notes, + ), + ), + 'yes' + ); - Util_Admin::redirect( array_merge( $params, array( - 'w3tc_message' => $message_id ) ), $check_referrer ); + self::redirect( array_merge( $params, array( 'w3tc_message' => $message_id ) ), $check_referrer ); } /** - * Special redirect with ability to pass custom_message_id based on $data + * Special redirect with ability to pass custom_message_id based on $data. * query_string * actions - which actions to call on render * errors * notes + * + * @static + * + * @param array $data Data. */ - static public function redirect_with_custom_messages2( $data ) { - if ( !isset( $data['query_string']['page'] ) ) { - $data['query_string']['page'] = - Util_Request::get_string( 'page' ); - if ( $data['query_string']['page'] == 'w3tc_extensions' ) { - $data['query_string']['extension'] = - Util_Request::get_string( 'extension' ); - $data['query_string']['action'] = - Util_Request::get_string( 'action' ); + public static function redirect_with_custom_messages2( $data ) { + if ( ! isset( $data['query_string']['page'] ) ) { + $data['query_string']['page'] = Util_Request::get_string( 'page' ); + + if ( 'w3tc_extensions' === $data['query_string']['page'] ) { + $data['query_string']['extension'] = Util_Request::get_string( 'extension' ); + $data['query_string']['action'] = Util_Request::get_string( 'action' ); } } $message_id = uniqid(); - set_transient( 'w3tc_message', array( $message_id => $data ), 600 ); + + update_option( 'w3tc_message', array( $message_id => $data ), 'yes' ); + $data['query_string']['w3tc_message'] = $message_id; Util_Environment::redirect( 'admin.php', $data['query_string'] ); } - - static public function custom_message_id( $errors = null, $notes = null ) { + /** + * Custom message id. + * + * @static + * + * @param array $errors Errors. + * @param array $notes Notes. + */ + public static function custom_message_id( $errors = null, $notes = null ) { $message_id = uniqid(); - set_transient( 'w3tc_message', + update_option( + 'w3tc_message', array( - $message_id => array( 'errors' => $errors, 'notes' => $notes ) - ), 600 ); + $message_id => array( + 'errors' => $errors, + 'notes' => $notes, + ), + ), + 'yes' + ); return 'w3tc_message=' . $message_id; } - /* - * Checks if contains single message item + /** + * Checks if contains single message item. * - * @param $a array - * @return boolean + * @static + * + * @param array $a Array. + * @return bool */ - static public function single_system_item( $a ) { - if ( !is_array( $a ) || count( $a ) != 1 ) + public static function single_system_item( $a ) { + if ( ! is_array( $a ) || count( $a ) !== 1 ) { return false; + } $first_key = array_keys( $a ); $first_key = $first_key[0]; - $pos = strpos( $a[$first_key], ' ' ); - if ( $pos === false ) + $pos = strpos( $a[ $first_key ], ' ' ); + + if ( false === $pos ) { return true; + } return false; } /** - * Save config, can't decline save process. (difference from action_save) + * Save config, can't decline save process. (difference from action_save). + * + * Do some actions on config keys update. * - * Do some actions on config keys update * Used in several places such as: * * 1. common config save * 2. import settings * - * @param Config $current_config - * @param Config $new_config + * @static + * + * @param Config $current_config Current config. + * @param Config $new_config New config. * @return bool - * @throws Exception + * @throws \Exception Exception. */ - static public function config_save( $current_config, $new_config ) { + public static function config_save( $current_config, $new_config ) { $master_config = ( $new_config->is_master() ? $new_config : Dispatcher::config_master() ); if ( $master_config->get_integer( 'common.instance_id', 0 ) == 0 ) { $master_config->set( 'common.instance_id', mt_rand() ); - if ( !$new_config->is_master() ) + + if ( ! $new_config->is_master() ) { $master_config->save(); + } } $old_config = new Config(); $browsercache_dependencies = array(); if ( $new_config->get_boolean( 'browsercache.enabled' ) ) { - $browsercache_dependencies = array_merge( $browsercache_dependencies, array( + $browsercache_dependencies = array_merge( + $browsercache_dependencies, + array( 'browsercache.rewrite', 'browsercache.cssjs.replace', 'browsercache.html.replace', - 'browsercache.other.replace' - ) ); + 'browsercache.other.replace', + ) + ); if ( $new_config->get_boolean( 'browsercache.cssjs.replace' ) ) { - $browsercache_dependencies = array_merge( $browsercache_dependencies, array( + $browsercache_dependencies = array_merge( + $browsercache_dependencies, + array( 'browsercache.cssjs.compression', 'browsercache.cssjs.expires', 'browsercache.cssjs.lifetime', 'browsercache.cssjs.cache.control', 'browsercache.cssjs.cache.policy', 'browsercache.cssjs.etag', - 'browsercache.cssjs.w3tc' - ) ); + 'browsercache.cssjs.w3tc', + ) + ); } if ( $new_config->get_boolean( 'browsercache.html.replace' ) ) { - $browsercache_dependencies = array_merge( $browsercache_dependencies, array( + $browsercache_dependencies = array_merge( + $browsercache_dependencies, + array( 'browsercache.html.compression', 'browsercache.html.expires', 'browsercache.html.lifetime', 'browsercache.html.cache.control', 'browsercache.html.cache.policy', 'browsercache.html.etag', - 'browsercache.html.w3tc' - ) ); + 'browsercache.html.w3tc', + ) + ); } if ( $new_config->get_boolean( 'browsercache.other.replace' ) ) { - $browsercache_dependencies = array_merge( $browsercache_dependencies, array( + $browsercache_dependencies = array_merge( + $browsercache_dependencies, + array( 'browsercache.other.compression', 'browsercache.other.expires', 'browsercache.other.lifetime', 'browsercache.other.cache.control', 'browsercache.other.cache.policy', 'browsercache.other.etag', - 'browsercache.other.w3tc' - ) ); + 'browsercache.other.w3tc', + ) + ); } $old_bc_dependencies_values = array(); @@ -209,7 +265,9 @@ class Util_Admin { $cache_flush = Dispatcher::component( 'CacheFlush' ); if ( $cache_flush->flushable_posts() ) { - $pgcache_dependencies = array_merge( $browsercache_dependencies, array( + $pgcache_dependencies = array_merge( + $browsercache_dependencies, + array( 'pgcache.debug', 'pgcache.cache.query', 'pgcache.cache.home', @@ -236,27 +294,25 @@ class Util_Admin { 'objectcache.enabled', 'minify.enabled', 'mobile.enabled', - 'referrer.enabled' - ) ); + 'referrer.enabled', + ) + ); + if ( $new_config->get_boolean( 'pgcache.mirrors.enabled' ) ) { - $pgcache_dependencies = array_merge( $pgcache_dependencies, array( - 'pgcache.mirrors.home_urls' - ) ); + $pgcache_dependencies = array_merge( $pgcache_dependencies, array( 'pgcache.mirrors.home_urls' ) ); } if ( $new_config->get_boolean( 'dbcache.enabled' ) ) { - $pgcache_dependencies = array_merge( $pgcache_dependencies, array( - 'dbcache.debug' - ) ); + $pgcache_dependencies = array_merge( $pgcache_dependencies, array( 'dbcache.debug' ) ); } - if ( $new_config->get_boolean( 'objectcache.enabled' ) ) { - $pgcache_dependencies = array_merge( $pgcache_dependencies, array( - 'objectcache.debug' - ) ); + if ( $new_config->getf_boolean( 'objectcache.enabled' ) ) { + $pgcache_dependencies = array_merge( $pgcache_dependencies, array( 'objectcache.debug' ) ); } if ( $new_config->get_boolean( 'minify.enabled' ) ) { - $pgcache_dependencies = array_merge( $pgcache_dependencies, array( + $pgcache_dependencies = array_merge( + $pgcache_dependencies, + array( 'minify.auto', 'minify.debug', 'minify.rewrite', @@ -277,17 +333,16 @@ class Util_Admin { 'minify.htmltidy.options.wrap', 'minify.reject.logged', 'minify.reject.ua', - 'minify.reject.uri' - ) ); + 'minify.reject.uri', + ) + ); } - /** - * - * - * @var W3_ModuleStatus $modules - */ + $modules = Dispatcher::component( 'ModuleStatus' ); if ( $modules->is_running( 'cdn' ) ) { - $pgcache_dependencies = array_merge( $pgcache_dependencies, array( + $pgcache_dependencies = array_merge( + $pgcache_dependencies, + array( 'cdn.enabled', 'cdn.debug', 'cdn.engine', @@ -323,31 +378,29 @@ class Util_Admin { 'cdn.reject.roles', 'cdn.reject.ua', 'cdn.reject.uri', - 'cdn.reject.files' - ) ); - } elseif ( $old_config->get_boolean( 'cdn.enabled' ) && !$new_config->get_boolean( 'cdn.enabled' ) ) { + 'cdn.reject.files', + ) + ); + } elseif ( $old_config->get_boolean( 'cdn.enabled' ) && ! $new_config->get_boolean( 'cdn.enabled' ) ) { $pgcache_dependencies = array_merge( $pgcache_dependencies, array( 'cdn.enabled' ) ); } if ( $new_config->get_boolean( 'mobile.enabled' ) ) { - $pgcache_dependencies = array_merge( $pgcache_dependencies, array( - 'mobile.rgroups' - ) ); + $pgcache_dependencies = array_merge( $pgcache_dependencies, array( 'mobile.rgroups' ) ); } if ( $new_config->get_boolean( 'referrer.enabled' ) ) { - $pgcache_dependencies = array_merge( $pgcache_dependencies, array( - 'referrer.rgroups' - ) ); + $pgcache_dependencies = array_merge( $pgcache_dependencies, array( 'referrer.rgroups' ) ); } - - if ( $new_config->get_boolean( 'browsercache.enabled' ) && - $new_config->get_string( 'pgcache.engine' ) == 'file_generic' ) { - $pgcache_dependencies = array_merge( $pgcache_dependencies, array( + if ( $new_config->get_boolean( 'browsercache.enabled' ) && $new_config->get_string( 'pgcache.engine' ) === 'file_generic' ) { + $pgcache_dependencies = array_merge( + $pgcache_dependencies, + array( 'browsercache.html.last_modified', - 'browsercache.other.last_modified' - ) ); + 'browsercache.other.last_modified', + ) + ); } $old_pgcache_dependencies_values = array(); @@ -368,17 +421,22 @@ class Util_Admin { * Show need empty minify notification */ if ( $current_config->get_boolean( 'minify.enabled' ) && $new_config->get_boolean( 'minify.enabled' ) && ( ( $new_config->get_boolean( 'minify.css.enable' ) && ( $new_config->get_boolean( 'minify.auto' ) || count( $new_config->get_array( 'minify.css.groups' ) ) ) ) || ( $new_config->get_boolean( 'minify.js.enable' ) && ( $new_config->get_boolean( 'minify.auto' ) || count( $new_config->get_array( 'minify.js.groups' ) ) ) ) ) ) { - $minify_dependencies = array_merge( $browsercache_dependencies, array( + $minify_dependencies = array_merge( + $browsercache_dependencies, + array( 'minify.auto', 'minify.debug', 'minify.options', 'minify.symlinks', 'minify.css.enable', - 'minify.js.enable' - ) ); + 'minify.js.enable', + ) + ); if ( $new_config->get_boolean( 'minify.css.enable' ) && ( $new_config->get_boolean( 'minify.auto' ) || count( $new_config->get_array( 'minify.css.groups' ) ) ) ) { - $minify_dependencies = array_merge( $minify_dependencies, array( + $minify_dependencies = array_merge( + $minify_dependencies, + array( 'minify.css.engine', 'minify.css.method', 'minify.css.strip.comments', @@ -404,12 +462,15 @@ class Util_Admin { 'minify.csstidy.options.css_level', 'minify.csstidy.options.preserve_css', 'minify.csstidy.options.timestamp', - 'minify.csstidy.options.template' - ) ); + 'minify.csstidy.options.template', + ) + ); } if ( $new_config->get_boolean( 'minify.js.enable' ) && ( $new_config->get_boolean( 'minify.auto' ) || count( $new_config->get_array( 'minify.js.groups' ) ) ) ) { - $minify_dependencies = array_merge( $minify_dependencies, array( + $minify_dependencies = array_merge( + $minify_dependencies, + array( 'minify.js.engine', 'minify.js.method', 'minify.js.combine.header', @@ -427,21 +488,15 @@ class Util_Admin { 'minify.ccjs.path.java', 'minify.ccjs.path.jar', 'minify.ccjs.options.compilation_level', - 'minify.ccjs.options.formatting' - ) ); + 'minify.ccjs.options.formatting', + ) + ); } - /** - * - * - * @var W3_ModuleStatus $modules - */ $modules = Dispatcher::component( 'ModuleStatus' ); if ( $modules->is_running( 'cdn' ) ) { - $minify_dependencies = array_merge( $minify_dependencies, array( - 'cdn.engine', 'cdn.enabled' - ) ); - } elseif ( $old_config->get_boolean( 'cdn.enabled' ) && !$new_config->get_boolean( 'cdn.enabled' ) ) { + $minify_dependencies = array_merge( $minify_dependencies, array( 'cdn.engine', 'cdn.enabled' ) ); + } elseif ( $old_config->get_boolean( 'cdn.enabled' ) && ! $new_config->get_boolean( 'cdn.enabled' ) ) { $minify_dependencies = array_merge( $minify_dependencies, array( 'cdn.enabled' ) ); } @@ -459,11 +514,11 @@ class Util_Admin { } } - if ( $new_config->get_boolean( 'cdn.enabled' ) && !Cdn_Util::is_engine_mirror( $new_config->get_string( 'cdn.engine' ) ) ) { + if ( $new_config->get_boolean( 'cdn.enabled' ) && ! Cdn_Util::is_engine_mirror( $new_config->get_string( 'cdn.engine' ) ) ) { /** * Show notification when CDN enabled */ - if ( !$old_config->get_boolean( 'cdn.enabled' ) ) { + if ( ! $old_config->get_boolean( 'cdn.enabled' ) ) { $state = Dispatcher::config_state(); $state->set( 'cdn.show_note_cdn_upload', true ); $state->save(); @@ -472,9 +527,7 @@ class Util_Admin { /** * Show notification when Browser Cache settings changes */ - $cdn_dependencies = array( - 'browsercache.enabled' - ); + $cdn_dependencies = array( 'browsercache.enabled' ); if ( $new_config->get_boolean( 'cdn.enabled' ) ) { $cdn_dependencies = array( @@ -498,7 +551,7 @@ class Util_Admin { 'browsercache.other.cache.control', 'browsercache.other.cache.policy', 'browsercache.other.etag', - 'browsercache.other.w3tc' + 'browsercache.other.w3tc', ); } @@ -510,7 +563,7 @@ class Util_Admin { $new_cdn_dependencies_values[] = $new_config->get( $cdn_dependency ); } - if ( serialize( $old_cdn_dependencies_values ) != serialize( $new_cdn_dependencies_values ) ) { + if ( serialize( $old_cdn_dependencies_values ) !== serialize( $new_cdn_dependencies_values ) ) { $state = Dispatcher::config_state(); $state->set( 'cdn.show_note_cdn_reupload', true ); $state->save(); @@ -520,10 +573,10 @@ class Util_Admin { /** * Show need empty object cache notification */ - if ( $current_config->get_boolean( 'objectcache.enabled' ) ) { + if ( $current_config->getf_boolean( 'objectcache.enabled' ) ) { $objectcache_dependencies = array( 'objectcache.groups.global', - 'objectcache.groups.nonpersistent' + 'objectcache.groups.nonpersistent', ); $old_objectcache_dependencies_values = array(); @@ -548,22 +601,21 @@ class Util_Admin { try { $new_config->save(); } catch ( \Exception $ex ) { - // try to fix environment, it potentially can be fixed silently - // dont show error here, it will be called again later - // in admin_notices + // try to fix environment, it potentially can be fixed silently don't show error here, it will be called again later in admin_notices. try { $environment = Dispatcher::component( 'Root_Environment' ); $environment->fix_in_wpadmin( $new_config ); - } catch ( \Exception $ex ) { + } catch ( \Exception $ex ) { // phpcs:ignore Generic.CodeAnalysis.EmptyStatement.DetectedCatch + // Do nothing. } - // retry save process and complain now on failure + // Retry save process and complain now on failure. try { $new_config->save(); } catch ( \Exception $ex ) { throw new \Exception( - 'Can\'t change configuration: ' . - $ex->getMessage() ); + 'Can\'t change configuration: ' . $ex->getMessage() + ); } } @@ -584,7 +636,7 @@ class Util_Admin { w3tc_dbcache_flush(); } - if ( $old_config->get_string( 'objectcache.engine' ) != $new_config->get_string( 'objectcache.engine' ) || $old_config->get_string( 'objectcache.enabled' ) != $new_config->get_string( 'objectcache.enabled' ) ) { + if ( $old_config->get_string( 'objectcache.engine' ) != $new_config->get_string( 'objectcache.engine' ) || $old_config->getf_boolean( 'objectcache.enabled' ) !== $new_config->getf_boolean( 'objectcache.enabled' ) ) { w3tc_objectcache_flush(); } @@ -620,8 +672,8 @@ class Util_Admin { * Auto upload browsercache files to CDN */ if ( $new_config->get_boolean( 'cdn.enabled' ) && $new_config->get_string( 'cdn.engine' ) == 'ftp' ) { - Util_Admin::cdn_delete_browsercache( $current_config ); - Util_Admin::cdn_upload_browsercache( $current_config ); + self::cdn_delete_browsercache( $current_config ); + self::cdn_upload_browsercache( $current_config ); } return true; @@ -630,11 +682,13 @@ class Util_Admin { /** - * Uploads minify files to CDN + * Uploads minify files to CDN. + * + * @static * * @return void */ - static public function cdn_upload_minify() { + public static function cdn_upload_minify() { $w3_plugin_cdn = Dispatcher::component( 'Cdn_Plugin' ); $common = Dispatcher::component( 'Cdn_Core' ); @@ -644,22 +698,27 @@ class Util_Admin { $results = array(); foreach ( $files as $file ) { - $upload[] = $common->build_file_descriptor( $common->docroot_filename_to_absolute_path( $file ), - $common->uri_to_cdn_uri( $common->docroot_filename_to_uri( $file ) ) ); + $upload[] = $common->build_file_descriptor( + $common->docroot_filename_to_absolute_path( $file ), + $common->uri_to_cdn_uri( $common->docroot_filename_to_uri( $file ) ) + ); } $common->upload( $upload, true, $results ); } /** - * Uploads Browser Cache .htaccess to FTP + * Uploads Browser Cache .htaccess to FTP. * - * @var Config $config + * @static + * + * @param Config $config Config. * @return void */ - static public function cdn_upload_browsercache( $config ) { + public static function cdn_upload_browsercache( $config ) { $common = Dispatcher::component( 'Cdn_Core' ); - $Cdn_Core_Admin = Dispatcher::component( 'Cdn_Core_Admin' ); + + Dispatcher::component( 'Cdn_Core_Admin' ); $ce = Dispatcher::component( 'Cdn_Environment' ); $rules = $ce->rules_generate_for_ftp( $config ); @@ -681,59 +740,84 @@ class Util_Admin { } /** - * Deletes Browser Cache .htaccess from FTP + * Deletes Browser Cache .htaccess from FTP. + * + * @static * * @return void */ - static public function cdn_delete_browsercache() { - $common = Dispatcher::component( 'Cdn_Core' ); - + public static function cdn_delete_browsercache() { + $common = Dispatcher::component( 'Cdn_Core' ); $cdn_path = Util_Rule::get_cdn_rules_path(); $tmp_path = W3TC_CACHE_TMP_DIR . '/' . $cdn_path; - - $results = array(); - $delete = array( - $common->build_file_descriptor( $tmp_path, $cdn_path ) - ); + $results = array(); + $delete = array( $common->build_file_descriptor( $tmp_path, $cdn_path ) ); $common->delete( $delete, false, $results ); } /** - * Returns cookie domain + * Returns cookie domain. + * + * @static * * @return string */ - static public function get_cookie_domain() { + public static function get_cookie_domain() { $site_url = get_option( 'siteurl' ); $parse_url = @parse_url( $site_url ); - if ( $parse_url && !empty( $parse_url['host'] ) ) { + if ( $parse_url && ! empty( $parse_url['host'] ) ) { return $parse_url['host']; } return isset( $_SERVER['HTTP_HOST'] ) ? sanitize_text_field( wp_unslash( $_SERVER['HTTP_HOST'] ) ) : ''; } - /* - * Returns current w3tc admin page + /** + * Returns current w3tc admin page. + * + * @static + * + * @return string */ - static public function get_current_page() { + public static function get_current_page() { $page = Util_Request::get_string( 'page' ); - if ( substr( $page, 0, 5 ) == 'w3tc_' ) + if ( substr( $page, 0, 5 ) === 'w3tc_' ) { return $page; + } return 'w3tc_dashboard'; } /** - * Check if current page is a W3TC admin page + * Returns current w3tc extension id. + * + * @static + * + * @return string + */ + public static function get_current_extension() { + $page = Util_Request::get_string( 'page' ); + $extension = Util_Request::get_string( 'extension' ); + + if ( substr( $page, 0, 5 ) === 'w3tc_' && ! empty( $extension ) ) { + return $extension; + } + + return ''; + } + + /** + * Check if current page is a W3TC admin page. + * + * @static * * @return bool */ - static public function is_w3tc_admin_page() { + public static function is_w3tc_admin_page() { $page_val = Util_Request::get_string( 'page' ); if ( ! empty( $page_val ) && 'w3tc_' === substr( $page_val, 0, 5 ) ) { return true; @@ -749,11 +833,13 @@ class Util_Admin { /** - * Returns current WordPress page + * Returns current WordPress page. + * + * @static * * @return string */ - static public function get_current_wp_page() { + public static function get_current_wp_page() { return Util_Request::get_string( 'page' ); } } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_AttachToActions.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_AttachToActions.php index e25cfd32..0f0ae25a 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_AttachToActions.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_AttachToActions.php @@ -49,7 +49,8 @@ class Util_AttachToActions { // multisite. if ( Util_Environment::is_wpmu() ) { - add_action( 'delete_blog', array( $o, 'on_change' ), 0 ); + add_action( 'wp_uninitialize_site', array( $o, 'on_change' ), 0 ); + add_action( 'wp_update_site', array( $o, 'on_change' ), 0 ); } } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_Environment.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_Environment.php index 8387abae..7baf6063 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_Environment.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_Environment.php @@ -173,8 +173,13 @@ class Util_Environment { * * @return bool */ - public static function is_dbcluster() { - if ( ! defined( 'W3TC_PRO' ) || ! W3TC_PRO ) { + public static function is_dbcluster( $config = null ) { + if ( is_null( $config ) ) { + // fallback for compatibility with older wp-content/db.php + $config = \W3TC\Dispatcher::config(); + } + + if ( !self::is_w3tc_pro( $config ) ) { return false; } @@ -1555,4 +1560,56 @@ class Util_Environment { self::$is_using_master_config = null; } + + /** + * Removes blank lines, trim values, removes duplicates, and sorts array. + * + * @since 2.4.3 + * + * @param array $values Array of values. + * + * @return array + */ + public static function clean_array( $values ) { + if ( ! empty( $values ) && is_array( $values ) ) { + $values = array_unique( + array_filter( + array_map( + 'trim', + $values + ), + 'strlen' + ) + ); + sort( $values ); + } + + return $values; + } + + /** + * Parses textarea setting value from string to array. + * + * @since 2.4.3 + * + * @param string $value Value. + * + * @return array + */ + public static function textarea_to_array( $value ) { + $values_array = array(); + + if ( ! empty( $value ) ) { + $values_array = self::clean_array( + preg_split( + '/\R/', + $value, + 0, + PREG_SPLIT_NO_EMPTY + ) + ); + } + + return $values_array; + } } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_PageSpeed.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_PageSpeed.php index 2cbaf9fc..635630a4 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_PageSpeed.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_PageSpeed.php @@ -362,20 +362,47 @@ class Util_PageSpeed { $headers .= '' . esc_html__( 'Element', 'w3-total-cache' ) . ''; $items .= ''; if ( isset( $item['node'] ) ) { - $items .= '

        ' . esc_html( $item['node']['snippet'] ) . '

        '; - $items .= '

        ' . esc_html( $item['node']['selector'] ) . '

        '; + $items .= '

        ' . __( 'Snippet', 'w3-total-cache' ) . ': ' . esc_html( $item['node']['snippet'] ) . '

        '; + $items .= '

        ' . __( 'Selector', 'w3-total-cache' ) . ': ' . esc_html( $item['node']['selector'] ) . '

        '; } $items .= ''; $headers .= '' . esc_html__( 'Value', 'w3-total-cache' ) . ''; - $items .= '' . esc_html( $item['value'] ) . ''; + $items .= is_array( $item['value'] ) ? '' . esc_html( $item['value']['value'] ) . '' : '' . esc_html( $item['value'] ) . ''; } elseif ( isset( $item['node'] ) ) { $headers .= '' . esc_html__( 'Element', 'w3-total-cache' ) . ''; $items .= ''; - $items .= '

        ' . esc_html( $item['node']['snippet'] ) . '

        '; - $items .= '

        ' . esc_html( $item['node']['selector'] ) . '

        '; + $items .= '

        ' . __( 'Snippet', 'w3-total-cache' ) . ': ' . esc_html( $item['node']['snippet'] ) . '

        '; + $items .= '

        ' . __( 'Selector', 'w3-total-cache' ) . ': ' . esc_html( $item['node']['selector'] ) . '

        '; $items .= ''; } + if ( isset( $item['headings'] ) && isset( $item['items'] ) ) { + $items .= ''; + foreach ( $item['headings'] as $heading ) { + $items .= ''; + } + $items .= ''; + foreach ( $item['items'] as $sub_item ) { + $items .= ''; + if ( isset( $sub_item['node'] ) ) { + $items .= ''; + } + if ( isset( $sub_item['phase'] ) && isset( $sub_item['timing'] ) && isset( $sub_item['percent'] ) ) { + $items .= ''; + $items .= ''; + $items .= ''; + } + $items .= ''; + } + $items .= '
        ' . esc_html( $heading['label'], 'w3-total-cache' ) . '
        '; + $items .= '

        ' . __( 'Snippet', 'w3-total-cache' ) . ': ' . esc_html( $sub_item['node']['snippet'] ) . '

        '; + $items .= '

        ' . __( 'Selector', 'w3-total-cache' ) . ': ' . esc_html( $sub_item['node']['selector'] ) . '

        '; + $items .= '
        ' . esc_html( $sub_item['phase'] ) . '' . esc_html( $sub_item['percent'] ) . '' . esc_html( $sub_item['timing'] ) . ' ms
        '; + } + if ( isset( $item['responseTime'] ) ) { + $headers .= '' . esc_html__( 'Response Time', 'w3-total-cache' ) . ''; + $items .= '' . esc_html( $item['responseTime'] ) . ''; + } $items .= ''; } @@ -545,20 +572,47 @@ class Util_PageSpeed { $headers .= '' . esc_html__( 'Element', 'w3-total-cache' ) . ''; $items .= ''; if ( isset( $item['node'] ) ) { - $items .= '

        ' . esc_html( $item['node']['snippet'] ) . '

        '; - $items .= '

        ' . esc_html( $item['node']['selector'] ) . '

        '; + $items .= '

        ' . __( 'Snippet', 'w3-total-cache' ) . ': ' . esc_html( $item['node']['snippet'] ) . '

        '; + $items .= '

        ' . __( 'Selector', 'w3-total-cache' ) . ': ' .esc_html( $item['node']['selector'] ) . '

        '; } $items .= ''; $headers .= '' . esc_html__( 'Value', 'w3-total-cache' ) . ''; - $items .= '' . esc_html( $item['value'] ) . ''; + $items .= is_array( $item['value'] ) ? '' . esc_html( $item['value']['value'] ) . '' : '' . esc_html( $item['value'] ) . ''; } elseif ( isset( $item['node'] ) ) { $headers .= '' . esc_html__( 'Element', 'w3-total-cache' ) . ''; $items .= ''; - $items .= '

        ' . esc_html( $item['node']['snippet'] ) . '

        '; - $items .= '

        ' . esc_html( $item['node']['selector'] ) . '

        '; + $items .= '

        ' . __( 'Snippet', 'w3-total-cache' ) . ': ' . esc_html( $item['node']['snippet'] ) . '

        '; + $items .= '

        ' . __( 'Selector', 'w3-total-cache' ) . ': ' . esc_html( $item['node']['selector'] ) . '

        '; $items .= ''; } + if ( isset( $item['headings'] ) && isset( $item['items'] ) ) { + $items .= ''; + foreach ( $item['headings'] as $heading ) { + $items .= ''; + } + $items .= ''; + foreach ( $item['items'] as $sub_item ) { + $items .= ''; + if ( isset( $sub_item['node'] ) ) { + $items .= ''; + } + if ( isset( $sub_item['phase'] ) && isset( $sub_item['timing'] ) && isset( $sub_item['percent'] ) ) { + $items .= ''; + $items .= ''; + $items .= ''; + } + $items .= ''; + } + $items .= '
        ' . esc_html( $heading['label'], 'w3-total-cache' ) . '
        '; + $items .= '

        ' . __( 'Snippet', 'w3-total-cache' ) . ': ' . esc_html( $sub_item['node']['snippet'] ) . '

        '; + $items .= '

        ' . __( 'Selector', 'w3-total-cache' ) . ': ' . esc_html( $sub_item['node']['selector'] ) . '

        '; + $items .= '
        ' . esc_html( $sub_item['phase'] ) . '' . esc_html( $sub_item['percent'] ) . '' . esc_html( $sub_item['timing'] ) . ' ms
        '; + } + if ( isset( $item['responseTime'] ) ) { + $headers .= '' . esc_html__( 'Response Time', 'w3-total-cache' ) . ''; + $items .= '' . esc_html( $item['responseTime'] ) . ''; + } $items .= ''; } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_PageUrls.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_PageUrls.php index d1871cb3..2caa249c 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_PageUrls.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_PageUrls.php @@ -871,4 +871,117 @@ class Util_PageUrls { } return $archive_slug; } + + /** + * Gets page title based on key + * + * @param string $id Page ID. + * @return string + */ + public static function get_page_mapping( $id ) { + $map = array( + 'w3tc_dashboard' => array( + 'page_name' => esc_html__( 'Dashboard', 'w3-total-cache' ), + ), + 'w3tc_feature_showcase' => array( + 'page_name' => esc_html__( 'Feature Showcase', 'w3-total-cache' ), + ), + 'w3tc_general' => array( + 'page_name' => esc_html__( 'General Settings', 'w3-total-cache' ), + ), + 'w3tc_pgcache' => array( + 'page_name' => esc_html__( 'Page Cache', 'w3-total-cache' ), + 'parent_name' => esc_html__( 'General Settings', 'w3-total-cache' ), + 'parent_link' => esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_general' ) ), + ), + 'w3tc_minify' => array( + 'page_name' => esc_html__( 'Minify', 'w3-total-cache' ), + 'parent_name' => esc_html__( 'General Settings', 'w3-total-cache' ), + 'parent_link' => esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_general' ) ), + ), + 'w3tc_dbcache' => array( + 'page_name' => esc_html__( 'Database Cache', 'w3-total-cache' ), + 'parent_name' => esc_html__( 'General Settings', 'w3-total-cache' ), + 'parent_link' => esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_general' ) ), + ), + 'w3tc_objectcache' => array( + 'page_name' => esc_html__( 'Object Cache', 'w3-total-cache' ), + 'parent_name' => esc_html__( 'General Settings', 'w3-total-cache' ), + 'parent_link' => esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_general' ) ), + ), + 'w3tc_browsercache' => array( + 'page_name' => esc_html__( 'Browser Cache', 'w3-total-cache' ), + 'parent_name' => esc_html__( 'General Settings', 'w3-total-cache' ), + 'parent_link' => esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_general' ) ), + ), + 'w3tc_cachegroups' => array( + 'page_name' => esc_html__( 'Cache Groups', 'w3-total-cache' ), + 'parent_name' => esc_html__( 'General Settings', 'w3-total-cache' ), + 'parent_link' => esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_general' ) ), + ), + 'w3tc_cdn' => array( + 'page_name' => esc_html__( 'CDN', 'w3-total-cache' ), + 'parent_name' => esc_html__( 'General Settings', 'w3-total-cache' ), + 'parent_link' => esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_general' ) ), + ), + 'w3tc_fragmentcache' => array( + 'page_name' => esc_html__( 'Fragment Cache', 'w3-total-cache' ), + 'parent_name' => esc_html__( 'General Settings', 'w3-total-cache' ), + 'parent_link' => esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_general' ) ), + ), + 'w3tc_support' => array( + 'page_name' => esc_html__( 'Support', 'w3-total-cache' ), + ), + 'w3tc_pagespeed' => array( + 'page_name' => esc_html__( 'Google PageSpeed', 'w3-total-cache' ), + ), + 'w3tc_userexperience' => array( + 'page_name' => esc_html__( 'User Experience', 'w3-total-cache' ), + 'parent_name' => esc_html__( 'General Settings', 'w3-total-cache' ), + 'parent_link' => esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_general' ) ), + ), + 'w3tc_install' => array( + 'page_name' => esc_html__( 'Install', 'w3-total-cache' ), + ), + 'w3tc_setup_guide' => array( + 'page_name' => esc_html__( 'Setup Guide', 'w3-total-cache' ), + ), + 'w3tc_extensions' => array( + 'page_name' => esc_html__( 'Extensions', 'w3-total-cache' ), + ), + 'w3tc_stats' => array( + 'page_name' => esc_html__( 'Statistics', 'w3-total-cache' ), + ), + 'w3tc_extension_page_imageservice' => array( + 'page_name' => esc_html__( 'WebP Converter', 'w3-total-cache' ), + 'parent_name' => esc_html__( 'Extensions', 'w3-total-cache' ), + 'parent_link' => esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_extensions#imageservice' ) ), + ), + 'w3tc_monitoring' => array( + 'page_name' => esc_html__( 'Monitoring', 'w3-total-cache' ), + 'parent_name' => esc_html__( 'General Settings', 'w3-total-cache' ), + 'parent_link' => esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_general' ) ), + ), + 'w3tc_about' => array( + 'page_name' => esc_html__( 'About', 'w3-total-cache' ), + ), + 'swarmify' => array( + 'page_name' => 'Swarmify', + 'parent_name' => esc_html__( 'Extensions', 'w3-total-cache' ), + 'parent_link' => esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_extensions#swarmify' ) ), + ), + 'cloudflare' => array( + 'page_name' => 'CloudFlare', + 'parent_name' => esc_html__( 'Extensions', 'w3-total-cache' ), + 'parent_link' => esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_extensions#cloudflare' ) ), + ), + 'amp' => array( + 'page_name' => 'AMP', + 'parent_name' => esc_html__( 'Extensions', 'w3-total-cache' ), + 'parent_link' => esc_url( Util_Ui::admin_url( 'admin.php?page=w3tc_extensions#amp' ) ), + ), + ); + + return ! empty( $map[ $id ] ) ? $map[ $id ] : ''; + } } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_Ui.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_Ui.php index 5b0e03bd..7e49b4c0 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_Ui.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/Util_Ui.php @@ -180,13 +180,46 @@ class Util_Ui { * @return void */ public static function postbox_header( $title, $class = '', $id = '' ) { - if ( ! empty( $id ) ) { - $id = ' id="' . esc_attr( $id ) . '"'; - } + $id = ( ! empty( $id ) ) ? ' id="' . esc_attr( $id ) . '"' : ''; echo ' -

        -

        ' . wp_kses( $title, self::get_allowed_html_for_wp_kses_from_content( $title ) ) . '

        -
        '; +

        ' . wp_kses( $title, self::get_allowed_html_for_wp_kses_from_content( $title ) ) . '

        +
        '; + } + + /** + * Returns postbox header with tabs and links (used on the General settings page exclusively) + * + * WordPress 5.5 introduced .postbox-header, which broke the styles of our postboxes. This was + * resolved by adding additional css to /pub/css/options.css and pub/css/widget.css tagged with + * a "WP 5.5" comment. + * + * @todo Add .postbox-header to our postboxes and cleanup css. + * @link https://github.com/BoldGrid/w3-total-cache/issues/237 + * + * @param string $title + * @param string $description + * @param string $class + * @param string $id + * @param string $adv_link + * @param array $extra_links + * @return void + */ + public static function postbox_header_tabs( $title, $description = '', $class = '', $id = '', $adv_link = '', $extra_links = array() ) { + $display_id = ( ! empty( $id ) ) ? ' id="' . esc_attr( $id ) . '"' : ''; + $description = ( ! empty( $description ) ) ? '
        ' . wp_kses( $description, self::get_allowed_html_for_wp_kses_from_content( $description ) ) . '
        ' : ''; + $basic_settings_tab = ( ! empty( $adv_link ) ) ? '' . esc_html__( 'Basic Settings', 'w3-total-cache' ) . '' : ''; + $adv_settings_tab = ( ! empty( $adv_link ) ) ? '' . esc_html__( 'Advanced Settings', 'w3-total-cache' ) . '' : ''; + + $extra_link_tabs = ''; + foreach ( $extra_links as $extra_link_text => $extra_link ) { + $extra_link_tabs .= '' . esc_html( $extra_link_text ) . ''; + } + + echo ' +

        ' . wp_kses( $title, self::get_allowed_html_for_wp_kses_from_content( $title ) ) . '

        + ' . $description . ' + +
        '; } /** @@ -231,6 +264,156 @@ class Util_Ui { +
        + +
        + +
        + + + + + + + +
        + +
        + + + +
        + +
        + +
        + is_sealed( $key ) ) { @@ -269,14 +452,14 @@ class Util_Ui { if ( empty( $page_val ) || ( ! empty( $page_val ) && 'w3tc_' !== substr( $page_val, 0, 5 ) ) ) { $logo = sprintf( - 'W3 Total Cache"', + 'W3 Total Cache"', esc_url( plugins_url( '/pub/img/W3TC_dashboard_logo_title.png', W3TC_FILE ) ) . '' ); } else { $logo = ''; } return sprintf( - '
        %s
        ', + '
        %s
        ', $id ? 'id="' . esc_attr( $id ) . '"' : '', $logo . wp_kses( $message, self::get_allowed_html_for_wp_kses_from_content( $message ) ) ); @@ -307,7 +490,7 @@ class Util_Ui { if ( empty( $page_val ) || ( ! empty( $page_val ) && 'w3tc_' !== substr( $page_val, 0, 5 ) ) ) { $logo = sprintf( - 'W3 Total Cache', + 'W3 Total Cache', esc_url( plugins_url( '/pub/img/W3TC_dashboard_logo_title.png', W3TC_FILE ) . '' ) ); } else { @@ -315,7 +498,7 @@ class Util_Ui { } $v = sprintf( - '
        %s
        ', + '
        %s
        ', $id ? 'id="' . esc_attr( $id ) . '"' : '', $logo . wp_kses( $message, self::get_allowed_html_for_wp_kses_from_content( $message ) ) ); @@ -915,28 +1098,9 @@ class Util_Ui { } public static function config_item_extension_enabled( $a ) { - echo "\n\n"; - - $c = Dispatcher::config(); - self::checkbox2( - array( - 'name' => 'extension__' . self::config_key_to_http_name( $a['extension_id'] ), - 'value' => $c->is_extension_active_frontend( $a['extension_id'] ), - 'label' => $a['checkbox_label'], - ) - ); - - if ( isset( $a['description'] ) ) { - echo '

        ' . wp_kses( $a['description'], self::get_allowed_html_for_wp_kses_from_content( $a['description'] ) ) . '

        '; - } - - echo "\n"; - } - - public static function config_item_pro( $a ) { - $a = self::config_item_preprocess( $a ); - - if ( 'w3tc_no_trtd' !== $a['label_class'] ) { + if ( 'w3tc_single_column' === $a['label_class'] ) { + echo ''; + } else { echo ''; if ( ! empty( $a['label'] ) ) { @@ -946,7 +1110,51 @@ class Util_Ui { echo "\n\n"; } - self::pro_wrap_maybe_start(); + if ( isset( $a['pro'] ) ) { + self::pro_wrap_maybe_start(); + } + + $c = Dispatcher::config(); + self::checkbox2( + array( + 'name' => 'extension__' . self::config_key_to_http_name( $a['extension_id'] ), + 'value' => $c->is_extension_active_frontend( $a['extension_id'] ), + 'label' => $a['checkbox_label'], + 'disabled' => isset( $a['disabled'] ) ? $a['disabled'] : false, + ) + ); + + if ( isset( $a['description'] ) ) { + echo '

        ' . wp_kses( $a['description'], self::get_allowed_html_for_wp_kses_from_content( $a['description'] ) ) . '

        '; + } + + if ( isset( $a['pro'] ) ) { + self::pro_wrap_maybe_end( 'extension__' . self::config_key_to_http_name( $a['extension_id'] ) ); + } + + echo ( isset( $a['style'] ) ? '' : '' ); + echo "\n"; + } + + public static function config_item_pro( $a ) { + $a = self::config_item_preprocess( $a ); + + if ( 'w3tc_single_column' === $a['label_class'] ) { + echo ''; + } elseif ( 'w3tc_no_trtd' !== $a['label_class'] ) { + echo ''; + + if ( ! empty( $a['label'] ) ) { + self::label( $a['control_name'], $a['label'] ); + } + + echo "\n\n"; + } + + // If wrap_separate is not set we wrap everything. + if ( ! isset( $a['wrap_separate'] ) ) { + self::pro_wrap_maybe_start(); + } self::control2( $a ); @@ -954,6 +1162,15 @@ class Util_Ui { echo wp_kses( $a['control_after'], self::get_allowed_html_for_wp_kses_from_content( $a['control_after'] ) ); } + // If wrap_separate is set we wrap only the description. + if ( isset( $a['wrap_separate'] ) ) { + // If not pro we add a spacer for better separation of control element and wrapper. + if ( ! Util_Environment::is_w3tc_pro( Dispatcher::config() ) ) { + echo '

        '; + } + self::pro_wrap_maybe_start(); + } + if ( isset( $a['description'] ) ) { self::pro_wrap_description( $a['excerpt'], $a['description'], $a['control_name'] ); } @@ -961,7 +1178,8 @@ class Util_Ui { self::pro_wrap_maybe_end( $a['control_name'] ); if ( 'w3tc_no_trtd' !== $a['label_class'] ) { - echo "\n"; + echo ( isset( $a['style'] ) ? '' : '' ); + echo "\n"; } } @@ -1042,21 +1260,25 @@ class Util_Ui { 'optgroup' => 2, ); - self::config_item( - array( - 'key' => $a['key'], - 'label' => ( isset( $a['label'] ) ? $a['label'] : null ), - 'disabled' => ( isset( $a['disabled'] ) ? $a['disabled'] : null ), - 'control' => 'selectbox', - 'selectbox_values' => $values, - 'selectbox_optgroups' => array( - __( 'Shared Server:', 'w3-total-cache' ), - __( 'Dedicated / Virtual Server:', 'w3-total-cache' ), - __( 'Multiple Servers:', 'w3-total-cache' ), - ), - 'control_after' => isset( $a['control_after'] ) ? $a['control_after'] : null, - ) + $item_engine_config = array( + 'key' => $a['key'], + 'label' => ( isset( $a['label'] ) ? $a['label'] : null ), + 'disabled' => ( isset( $a['disabled'] ) ? $a['disabled'] : null ), + 'control' => 'selectbox', + 'selectbox_values' => $values, + 'selectbox_optgroups' => array( + __( 'Shared Server:', 'w3-total-cache' ), + __( 'Dedicated / Virtual Server:', 'w3-total-cache' ), + __( 'Multiple Servers:', 'w3-total-cache' ), + ), + 'control_after' => isset( $a['control_after'] ) ? $a['control_after'] : null, ); + + if ( isset( $a['pro'] ) ) { + self::config_item_pro( $item_engine_config ); + } else { + self::config_item( $item_engine_config ); + } } public static function pro_wrap_maybe_start() { @@ -1066,7 +1288,8 @@ class Util_Ui { ?>
        -
        +
        ★ PRO
        +
        ' . esc_html( $page_mapping['parent_name'] ) . '' : ''; + $current = '' . esc_html( $page_mapping['page_name'] ) . ''; + ?> +

        + + W3 Total Cache + + +

        + get_string( 'license.status' ) + ); + + switch ( $page ) { + case 'w3tc_general': + if ( ! empty( $_REQUEST['view'] ) ) { + break; + } + + $message_bus_link = array(); + if ( Util_Environment::is_w3tc_pro( $config ) ) { + $message_bus_link = array( + array( + 'id' => 'amazon_sns', + 'text' => esc_html__( 'Message Bus', 'w3-total-cache' ), + ), + ); + } + + $licensing_link = array(); + if ( $licensing_visible ) { + $licensing_link = array( + array( + 'id' => 'licensing', + 'text' => esc_html__( 'Licensing', 'w3-total-cache' ), + ), + ); + } + + $links = array_merge( + array( + array( + 'id' => 'general', + 'text' => esc_html__( 'General', 'w3-total-cache' ), + ), + array( + 'id' => 'page_cache', + 'text' => esc_html__( 'Page Cache', 'w3-total-cache' ), + ), + array( + 'id' => 'minify', + 'text' => esc_html__( 'Minify', 'w3-total-cache' ), + ), + array( + 'id' => 'system_opcache', + 'text' => esc_html__( 'Opcode Cache', 'w3-total-cache' ), + ), + array( + 'id' => 'database_cache', + 'text' => esc_html__( 'Database Cache', 'w3-total-cache' ), + ), + array( + 'id' => 'object_cache', + 'text' => esc_html__( 'Object Cache', 'w3-total-cache' ), + ), + array( + 'id' => 'browser_cache', + 'text' => esc_html__( 'Browser Cache', 'w3-total-cache' ), + ), + array( + 'id' => 'cdn', + 'text' => wp_kses( + sprintf( + // translators: 1 opening HTML abbr tag, 2 closing HTML abbr tag. + __( + '%1$sCDN%2$s', + 'w3-total-cache' + ), + '', + '' + ), + array( + 'abbr' => array( + 'title' => array(), + ), + ) + ), + ), + array( + 'id' => 'reverse_proxy', + 'text' => esc_html__( 'Reverse Proxy', 'w3-total-cache' ), + ), + ), + $message_bus_link, + $custom_areas, + $licensing_link, + array( + array( + 'id' => 'miscellaneous', + 'text' => esc_html__( 'Miscellaneous', 'w3-total-cache' ), + ), + array( + 'id' => 'debug', + 'text' => esc_html__( 'Debug', 'w3-total-cache' ), + ), + array( + 'id' => 'image_service', + 'text' => esc_html__( 'WebP Converter', 'w3-total-cache' ), + ), + array( + 'id' => 'google_pagespeed', + 'text' => __( 'Google PageSpeed', 'w3-total-cache' ), + ), + array( + 'id' => 'settings', + 'text' => esc_html__( 'Import / Export Settings', 'w3-total-cache' ), + ), + ) + ); + + $links_buff = array(); + foreach ( $links as $link ) { + $links_buff[] = "{$link['text']}"; + } + + ?> +
        + array( + 'href' => array(), + 'class' => array(), + ), + ) + ); + ?> +
        + +
        + | + | + | + | + | + | + +
        + + + +
        + | + +
        + +
        + +
        + + + +
        + | + | + +
        + +
        + | + | + | + +
        + +
        + get_array( 'extensions.active' ); + if ( array_key_exists( 'user-experience-defer-scripts', $extensions_active ) ) { + // If more items are added this will only encompase the Defer Scripts, but if only 1 item show no sub-nav. + ?> + | + + +
        + + + +
        + | + +
        + +
        + | + | + +
        + +
        + | + | + +
        + +
        + | + +
        + +
        + +
        + +
        + | + +
        + +
        + | + | + | + +
        + +
        + 'w3tc_flush_varnish', 'parent' => 'w3tc_flush', - 'title' => __( 'Reverse Proxy', 'w3-total-cache' ), + 'title' => __( 'Varnish Cache', 'w3-total-cache' ), 'href' => wp_nonce_url( admin_url( 'admin.php?page=w3tc_dashboard&w3tc_flush_varnish' ), 'w3tc' ) diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/extension-example/Extension_Example_Page_View.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/extension-example/Extension_Example_Page_View.php index 03f7d798..cd8059a9 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/extension-example/Extension_Example_Page_View.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/extension-example/Extension_Example_Page_View.php @@ -6,7 +6,6 @@ if ( ! defined( 'W3TC' ) ) { } ?>

        - |

        diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/lightbox/self_test.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/lightbox/self_test.php index 95aaa801..01090709 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/lightbox/self_test.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/lightbox/self_test.php @@ -19,7 +19,7 @@ if ( ! defined( 'W3TC' ) ) { '%1$sInstalled/Ok/Yes/True/On%2$s: Functionality will work properly.%3$s', 'w3-total-cache' ), - '', + '', '', '
        ' ), @@ -37,7 +37,7 @@ if ( ! defined( 'W3TC' ) ) { '%1$sNot detected/Not available/Off%2$s: May be installed, but cannot be automatically confirmed. Functionality may be limited.%3$s', 'w3-total-cache' ), - '', + '', '', '
        ' ), @@ -55,7 +55,7 @@ if ( ! defined( 'W3TC' ) ) { '%1$sNot installed/Error/No/False%2$s: Plugin or some functions may not work.%3$s', 'w3-total-cache' ), - '', + '', '', '
        ' ), @@ -96,16 +96,16 @@ if ( ! defined( 'W3TC' ) ) { Microsoft IIS - Not detected + Not detected
      • FTP functions: - Installed + Installed - Not detected + Not detected - + - +
      • @@ -145,9 +145,9 @@ if ( ! defined( 'W3TC' ) ) {
      • - + - +
      • @@ -155,9 +155,9 @@ if ( ! defined( 'W3TC' ) ) {
      • zlib extension: - + - +
      • @@ -165,9 +165,9 @@ if ( ! defined( 'W3TC' ) ) {
      • brotli extension: - + - +
      • @@ -175,53 +175,53 @@ if ( ! defined( 'W3TC' ) ) {
      • Opcode cache: - + - + - + - + = 6 ) : ?> - + - +
      • - + - +
      • - + - +
      • - + - +
      • - + - +
      • @@ -229,11 +229,11 @@ if ( ! defined( 'W3TC' ) ) {
      • - + - + - + - + - + - +
      • - + - +
      • - + - +
      • - + - +
      • SSH2 extension: - + - + : - + - + - +
      • @@ -437,15 +437,15 @@ if ( ! defined( 'W3TC' ) ) { : - + - + - + - + @@ -457,9 +457,9 @@ if ( ! defined( 'W3TC' ) ) {
      • : - + - +
      • @@ -467,49 +467,49 @@ if ( ! defined( 'W3TC' ) ) { : - + - + - +
      • - + - +
      • - + - + - +
      • - + - +
      • - () + () - +
      • diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/about.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/about.php index 220b2b0f..1e1a6ac7 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/about.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/about.php @@ -259,5 +259,3 @@ if ( ! defined( 'W3TC' ) ) {

        - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/browsercache.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/browsercache.php index 366e4d38..7fb6e988 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/browsercache.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/browsercache.php @@ -75,6 +75,7 @@ $security_session_values = array(

        +

        @@ -345,7 +346,6 @@ $security_session_values = array( ?> - - - @@ -720,11 +718,8 @@ $security_session_values = array( -
        - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/cdn.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/cdn.php index b2fe4a88..8e61c1e4 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/cdn.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/cdn.php @@ -15,16 +15,10 @@ if ( ! defined( 'W3TC' ) ) { // so nothing to upload from network admin. $upload_blogfiles_enabled = $cdn_mirror || ! is_network_admin() || ! Util_Environment::is_using_master_config(); +$can_purge = Cdn_Util::can_purge( $cdn_engine ); + +require W3TC_INC_DIR . '/options/common/header.php'; ?> - -

        - - | - | - | - | - -

        -

        - + +

        Maximize CDN usage by or - . - - objects from the CDN using this tool - - - or - - - . - - - ', - '' - ), - array( - 'acronym' => array( - 'title' => array(), - ), - ) - ); + +

        + - . - Check - - - ', - '' +

        + objects from the CDN' : ''; + $cdn_mirror_purge_button = $cdn_mirror_purge_all ? ( $can_purge ? ' or ' : '' ) . '' : ''; + echo $cdn_purge_button . $cdn_mirror_purge_button; + ?> +

        + + ', + '' + ), + array( + 'acronym' => array( + 'title' => array(), + ), + ) + ); + ?> + . + Check + + + array( - 'title' => array(), - ), - ) - ); - ?> - - + '', + '' + ), + array( + 'acronym' => array( + 'title' => array(), + ), + ) + ); + ?> + + +

        +
        @@ -352,7 +352,6 @@ $upload_blogfiles_enabled = $cdn_mirror || ! is_network_admin() || ! Util_Enviro
        - @@ -372,7 +371,6 @@ $upload_blogfiles_enabled = $cdn_mirror || ! is_network_admin() || ! Util_Enviro ?> - @@ -854,7 +852,6 @@ $upload_blogfiles_enabled = $cdn_mirror || ! is_network_admin() || ! Util_Enviro - @@ -899,4 +896,3 @@ $upload_blogfiles_enabled = $cdn_mirror || ! is_network_admin() || ! Util_Enviro
        - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/common/footer.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/common/footer.php index 04f5b844..9a94c53b 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/common/footer.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/common/footer.php @@ -1 +1,108 @@ + +
        + diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/common/header.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/common/header.php index 80c3305e..6572d8e0 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/common/header.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/common/header.php @@ -4,397 +4,7 @@ namespace W3TC; if ( ! defined( 'W3TC' ) ) { die(); } - -$config = Dispatcher::config(); -$state = Dispatcher::config_state(); -$page = Util_Admin::get_current_page(); -$licensing_visible = ( - ( ! Util_Environment::is_wpmu() || is_network_admin() ) && - ! ini_get( 'w3tc.license_key' ) && - 'host_valid' !== $state->get_string( 'license.status' ) -); - do_action( 'w3tc-dashboard-head' ); ?>
        - - - - - 'general', - 'text' => esc_html__( 'General', 'w3-total-cache' ), - ), - array( - 'id' => 'page_cache', - 'text' => esc_html__( 'Page Cache', 'w3-total-cache' ), - ), - array( - 'id' => 'minify', - 'text' => esc_html__( 'Minify', 'w3-total-cache' ), - ), - array( - 'id' => 'system_opcache', - 'text' => esc_html__( 'Opcode Cache', 'w3-total-cache' ), - ), - array( - 'id' => 'database_cache', - 'text' => esc_html__( 'Database Cache', 'w3-total-cache' ), - ), - array( - 'id' => 'object_cache', - 'text' => esc_html__( 'Object Cache', 'w3-total-cache' ), - ), - ); - - if ( Util_Environment::is_w3tc_pro( $config ) ) { - $anchors[] = array( - 'id' => 'fragmentcache', - 'text' => esc_html__( 'Fragment Cache', 'w3-total-cache' ), - ); - } - - $anchors = array_merge( - $anchors, - array( - array( - 'id' => 'browser_cache', - 'text' => esc_html__( 'Browser Cache', 'w3-total-cache' ), - ), - array( - 'id' => 'cdn', - 'text' => wp_kses( - sprintf( - // translators: 1 opening HTML abbr tag, 2 closing HTML abbr tag. - __( - '%1$sCDN%2$s', - 'w3-total-cache' - ), - '', - '' - ), - array( - 'abbr' => array( - 'title' => array(), - ), - ) - ), - ), - array( - 'id' => 'reverse_proxy', - 'text' => esc_html__( 'Reverse Proxy', 'w3-total-cache' ), - ), - ) - ); - - if ( Util_Environment::is_w3tc_pro() ) { - $anchors[] = array( - 'id' => 'amazon_sns', - 'text' => esc_html__( 'Message Bus', 'w3-total-cache' ), - ); - } - - $anchors[] = array( - 'id' => 'monitoring', - 'text' => esc_html__( 'Monitoring', 'w3-total-cache' ), - ); - - if ( $licensing_visible ) { - array( - 'id' => 'licensing', - 'text' => esc_html__( 'Licensing', 'w3-total-cache' ), - ); - } - - $link_attrs = array_merge( - $anchors, - $custom_areas, - array( - array( - 'id' => 'google_page_speed', - 'text' => __( 'Google PageSpeed', 'w3-total-cache' ) - ), - array( - 'id' => 'miscellaneous', - 'text' => esc_html__( 'Miscellaneous', 'w3-total-cache' ), - ), - array( - 'id' => 'debug', - 'text' => esc_html__( 'Debug', 'w3-total-cache' ), - ), - array( - 'id' => 'settings', - 'text' => esc_html__( 'Import / Export Settings', 'w3-total-cache' ), - ), - ) - ); - - $links = array(); - foreach ( $link_attrs as $link ) { - $links[] = "{$link['text']}"; - } - - $links[] = 'Compatibility Test'; - - ?> -

        - array( - 'href' => array(), - 'class' => array(), - ), - ) - ); - ?> -

        - -

        - - | - | - | - | - | - | - -

        - -

        - - | - | - - ', - '', - '', - '' - ), - array( - 'acronym' => array( - 'title' => array(), - ), - ) - ); - ?> - | - - ', - '' - ), - array( - 'acronym' => array( - 'title' => array(), - ), - ) - ); - ?> - | - - ', - '' - ), - array( - 'acronym' => array( - 'title' => array(), - ), - ) - ); - ?> - | - | - -

        - -

        - - | - | - -

        - -

        - - | - -

        - -

        - - | - | - - ', - '', - '', - '' - ), - array( - 'acronym' => array( - 'title' => array(), - ), - ) - ); - ?> - | - - ', - '', - '', - '' - ), - array( - 'acronym' => array( - 'title' => array(), - ), - ) - ); - ?> - | - | - -

        - -

        - - | - | - | - -

        - -

        - - | - - | - - - | - - | - - ', - '' - ), - array( - 'acronym' => array( - 'title' => array(), - ), - ) - ); - ?> - -

        - + diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/common/top_nav_bar.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/common/top_nav_bar.php new file mode 100644 index 00000000..923f2088 --- /dev/null +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/common/top_nav_bar.php @@ -0,0 +1,218 @@ + array( + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_general' ), + 'text' => __( 'General Settings', 'w3-total-cache' ), + ), + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_pgcache' ), + 'text' => __( 'Page Cache', 'w3-total-cache' ), + ), + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_minify' ), + 'text' => __( 'Minify', 'w3-total-cache' ), + ), + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_dbcache' ), + 'text' => __( 'Database Cache', 'w3-total-cache' ), + ), + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_objectcache' ), + 'text' => __( 'Object Cache', 'w3-total-cache' ), + ), + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_browsercache' ), + 'text' => __( 'Browser Cache', 'w3-total-cache' ), + ), + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_cachegroups' ), + 'text' => __( 'Cache Groups', 'w3-total-cache' ), + ), + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_cdn' ), + 'text' => 'CDN', + ), + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_fragmentcache' ), + 'text' => __( 'Fragment Cache', 'w3-total-cache' ), + ), + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_userexperience' ), + 'text' => __( 'User Experience', 'w3-total-cache' ), + ), + ), + 'tools' => array( + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_extensions' ), + 'text' => __( 'Extensions', 'w3-total-cache' ), + ), + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_stats' ), + 'text' => __( 'Statistics', 'w3-total-cache' ), + ), + array( + 'url' => $config->is_extension_active( 'imageservice' ) + ? Util_Ui::admin_url( 'upload.php?page=w3tc_extension_page_imageservice' ) + : Util_Ui::admin_url( 'admin.php?page=w3tc_general#image_service' ), + 'text' => __( 'WebP Converter', 'w3-total-cache' ), + ), + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_pagespeed' ), + 'text' => __( 'Google PageSpeed', 'w3-total-cache' ), + ), + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_setup_guide' ), + 'text' => __( 'Setup Guide', 'w3-total-cache' ), + ), + ), + 'info' => array( + array( + 'url' => Util_UI::admin_url( 'admin.php?page=w3tc_about' ), + 'text' => __( 'About', 'w3-total-cache' ), + ), + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_feature_showcase' ), + 'text' => __( 'Feature Showcase', 'w3-total-cache' ), + ), + array( + 'url' => Util_Ui::admin_url( 'admin.php?page=w3tc_install' ), + 'text' => __( 'Install', 'w3-total-cache' ), + ), + array( + 'url' => '#', + 'text' => __( 'Compatibility Test', 'w3-total-cache' ), + 'class' => 'compatiblity-test button-self-test', + ), + array( + 'url' => 'https://api.w3-edge.com/v1/redirects/faq', + 'text' => 'FAQ', + 'target' => '_blank', + 'dashicon' => '', + ), + ), +); + +do_action( 'w3tc_dashboard_top_nav_bar' ); +?> +
        +
        + + + + +
        +
        diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/dashboard.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/dashboard.php index b9d268ae..596ecec3 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/dashboard.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/dashboard.php @@ -40,53 +40,30 @@ if ( Util_Environment::is_w3tc_pro( Dispatcher::config() ) ) { // When header.php is not included (above), we need to do our head action and open the wrap. do_action( 'w3tc-dashboard-head' ); echo '
        '; - - require W3TC_INC_DIR . '/options/parts/dashboard_banner.php'; } ?>
        -

        - - , - array( - 'type' => array(), - 'name' => array(), - 'value' => array(), - ), - ) - ); - ?> - /> - /> - /> - /> - - - - class="button" /> - array( - 'class' => array(), - 'disabled' => array(), - 'id' => array(), - 'name' => array(), - 'type' => array(), - 'value' => array(), - ), - ) - ); - ?> - . -

        +
        + +
        + +
        +
        +
        +
        + array( + 'type' => array(), + 'name' => array(), + 'value' => array(), + ), + ) + ); + ?>
        @@ -132,4 +109,3 @@ if ( Util_Environment::is_w3tc_pro( Dispatcher::config() ) ) { ?>
        - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/dbcache.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/dbcache.php index 01c56264..334407cc 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/dbcache.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/dbcache.php @@ -7,47 +7,29 @@ if ( ! defined( 'W3TC' ) ) { ?> -
        -

        - _config->get_string( 'dbcache.engine' ) ) ), - '' . esc_html__( 'enabled', 'w3-total-cache' ) : 'disabled">' . esc_html__( 'disabled', 'w3-total-cache' ) ) . '' +

        + array( - 'class' => array(), - ), - ) - ); - ?> -

        -

        - - array( - 'type' => array(), - 'name' => array(), - 'value' => array(), - ), - ) - ); - ?> - class="button" /> - -

        -
        + esc_html( Cache::engine_name( $this->_config->get_string( 'dbcache.engine' ) ) ), + '' . esc_html__( 'enabled', 'w3-total-cache' ) : 'disabled">' . esc_html__( 'disabled', 'w3-total-cache' ) ) . '' + ), + array( + 'span' => array( + 'class' => array(), + ), + ) + ); + ?> +

        +
        @@ -59,7 +41,6 @@ if ( ! defined( 'W3TC' ) ) {
        - @@ -149,9 +130,6 @@ if ( ! defined( 'W3TC' ) ) { -
        - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/edd/buy.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/edd/buy.php index 2171168c..49541234 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/edd/buy.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/edd/buy.php @@ -1,4 +1,10 @@ -
        +
        @@ -56,5 +56,3 @@ if ( ! defined( 'W3TC' ) ) { - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/enterprise/dbcluster_general_section.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/enterprise/dbcluster_general_section.php index 3402341c..d62e5568 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/enterprise/dbcluster_general_section.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/enterprise/dbcluster_general_section.php @@ -9,7 +9,7 @@ if ( !defined( 'W3TC' ) ) diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/extensions.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/extensions.php index a21ed08b..6b0cc5cc 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/extensions.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/extensions.php @@ -6,28 +6,6 @@ if ( ! defined( 'W3TC' ) ) { } ?>
        - ', - '', - '', - '

        ' - ), - array( - 'p' => array(), - 'span' => array( - 'class' => array(), - ), - ) - ); - } - ?>
        diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/extensions/list.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/extensions/list.php index fcd2d642..887fb395 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/extensions/list.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/extensions/list.php @@ -114,8 +114,9 @@ if ( ! defined( 'W3TC' ) ) { $links, array( 'a' => array( - 'href' => array(), - 'class' => array(), + 'href' => array(), + 'class' => array(), + 'target' => array(), ), ) ); @@ -204,7 +205,8 @@ if ( ! defined( 'W3TC' ) ) { 'By %s', 'w3-total-cache' ), - '' . esc_html( $meta['author'] ) . '' + '' . esc_html( $meta['author'] ) . '' ), array( 'a' => array( @@ -215,7 +217,7 @@ if ( ! defined( 'W3TC' ) ) { ); ?> | -
        @@ -261,7 +263,3 @@ if ( ! defined( 'W3TC' ) ) {

        - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/general.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/general.php index 6ace6864..7e473b83 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/general.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/general.php @@ -12,30 +12,19 @@ if ( ! defined( 'W3TC' ) ) { } require W3TC_INC_DIR . '/options/common/header.php'; -?> -

        - ' . esc_html__( 'enabled', 'w3-total-cache' ) : 'disabled">' . esc_html__( 'disabled', 'w3-total-cache' ) ) . '.' - ), - array( - 'span' => array( - 'class' => array(), - ), - ) - ); - ?> -

        +?> +
        - +
        + value="_config ) ? 'Edit Database Cluster Configuration' : 'Enable database cluster'; ?>" />

        Create db-cluster-config.php file with your database cluster configuration to enable it.

        @@ -53,7 +42,7 @@ require W3TC_INC_DIR . '/options/common/header.php'; ); ?> _config->is_preview() ) : ?> - +

        - +

        - 'pgcache.configuration_overloaded' ) ); ?> -

        -
        - ' - ); - ?> 'minify.configuration_overloaded' ) ); ?> -

        - ' . __( 'CSS', 'w3-total-cache' ) . '', - '' . __( 'JS', 'w3-total-cache' ) . '', - '' . __( 'HTML', 'w3-total-cache' ) . '' - ) - ); - ?> -

        esc_html__( 'Manual', 'w3-total-cache' ), ), 'description' => esc_html__( - 'Select manual mode to use fields on the minify settings tab to specify files to be minified, otherwise files will be minified automatically.', + 'Select manual mode to use fields on the Minify settings tab to specify files to be minified, otherwise files will be minified automatically.', 'w3-total-cache' ), 'control_after' => ' ' . esc_html__( 'Learn more', 'w3-total-cache' ) . + . esc_attr__( 'How to use manual Minify', 'w3-total-cache' ) . '">' . esc_html__( 'Learn more', 'w3-total-cache' ) . '', ) ); @@ -287,7 +267,7 @@ require W3TC_INC_DIR . '/options/common/header.php'; ), ), 'control_after' => ' ' . esc_html__( 'Learn more', 'w3-total-cache' ) . + esc_attr__( 'How to use Minify HTML', 'w3-total-cache' ) . '">' . esc_html__( 'Learn more', 'w3-total-cache' ) . '', ) ); @@ -323,27 +303,25 @@ require W3TC_INC_DIR . '/options/common/header.php'; ?>
        - ' - ); - ?> 'dbcache.configuration_overloaded' ) ); ?> -

        - 'dbcache.engine' ) ); ?> - +
        - ' - ); - ?> - 'objectcache.configuration_overloaded' ) ); + echo ( ! $this->_config->getf_boolean( 'objectcache.enabled' ) && has_filter( 'w3tc_config_item_objectcache.enabled' ) ? '

        ' . esc_html__( 'Object Cache is disabled via filter.', 'w3-total-cache' ) . '

        ' : '' ); ?> -

        - 'objectcache.enabled', - 'control' => 'checkbox', - 'checkbox_label' => esc_html__( 'Enable', 'w3-total-cache' ), - 'description' => wp_kses( - sprintf( - // translators: 1 opening HTML a tag to WordPress codex for WP Object Cache, 2 Opening HTML acronym tag, - // translators: 3 closing HTML acronym tag, 4 closing HTML a tag. - __( - 'Object caching greatly increases performance for highly dynamic sites that use the %1$sObject Cache %2$sAPI%3$s%4$s.', - 'w3-total-cache' - ), - '', - '', - '', - '' + $objectcache_config_item = array( + 'key' => 'objectcache.enabled', + 'control' => 'checkbox', + 'checkbox_label' => esc_html__( 'Enable', 'w3-total-cache' ), + 'description' => wp_kses( + sprintf( + // translators: 1 opening HTML a tag to WordPress codex for WP Object Cache, 2 Opening HTML acronym tag, + // translators: 3 closing HTML acronym tag, 4 closing HTML a tag. + __( + 'Object caching greatly increases performance for highly dynamic sites that use the %1$sObject Cache %2$sAPI%3$s%4$s.', + 'w3-total-cache' ), - array( - 'acronym' => array( - 'title' => array(), - ), - 'a' => array( - 'href' => array(), - 'target' => array(), - ), - ) + '', + '', + '', + '' ), - ) + array( + 'acronym' => array( + 'title' => array(), + ), + 'a' => array( + 'href' => array(), + 'target' => array(), + ), + ) + ), ); + if ( ! $this->_config->getf_boolean( 'objectcache.enabled' ) && has_filter( 'w3tc_config_item_objectcache.enabled' ) ) { + $objectcache_config_item['disabled'] = true; + } + Util_Ui::config_item( $objectcache_config_item ); Util_Ui::config_item_engine( array( 'key' => 'objectcache.engine' ) ); ?>
        - ' - ); - ?> - 'browsercache.configuration_overloaded' ) ); ?> -

        -
        - 'varnish.configuration_overloaded' ) ); ?> -

        - ', - '', - '', - '' - ), - array( - 'a' => array( - 'href' => array(), - ), - ) - ); - ?> -

        @@ -535,23 +494,21 @@ require W3TC_INC_DIR . '/options/common/header.php';
        - ' - ); - ?> - - -

        - -

        + +
        @@ -677,11 +634,425 @@ require W3TC_INC_DIR . '/options/common/header.php';
        - - + + + + + + + + + + + +
        + + + + + +

        + ' . esc_html__( 'upgrading', 'w3-total-cache' ) . '' + ), + array( + 'a' => array( + 'class' => array(), + 'data-src' => array(), + 'href' => array(), + ), + ) + ); + ?> +

        +
        + + + + + + + + + + + + + + + + + + + + + + + + + + + + 'docroot_fix.enable', + 'control' => 'checkbox', + 'checkbox_label' => esc_html__( 'Fix document root path', 'w3-total-cache' ), + 'label_class' => 'w3tc_single_column', + 'description' => sprintf( + // translators: 1: WordPress ABSPATH value, 2: Server document root value. + esc_html__( 'Fix incorrect server document root path. Uses the WordPress ABSPATH ("%1$s") in place of the current server document root ("%2$s").', 'w3-total-cache' ), + esc_attr( untrailingslashit( ABSPATH ) ), + esc_attr( ! empty( $_SERVER['DOCUMENT_ROOT'] ) ? esc_url_raw( wp_unslash( $_SERVER['DOCUMENT_ROOT'] ) ) : '' ) + ), + ) + ); + + Util_Ui::config_item( + array( + 'key' => 'common.track_usage', + 'control' => 'checkbox', + 'checkbox_label' => esc_html__( 'Anonymously track usage to improve product quality', 'w3-total-cache' ), + 'label_class' => 'w3tc_single_column', + ) + ); + ?> +
        + checkbox( 'common.force_master' ); ?> +

        +
        + /> +

        +
        + /> + +

        + ', + '' + ), + array( + 'a' => array( + 'href' => array(), + ), + ) + ); + ?> +

        +
        + /> + +

        + ', + '' + ), + array( + 'acronym' => array( + 'title' => array(), + ), + ) + ); + ?> +

        +
        + /> + +

        +
        + + + + ', + '' + ), + array( + 'acronym' => array( + 'title' => array(), + ), + ) + ), + '', + 'debug' + ); + ?> + + + + + + +
        + checkbox_debug( 'pgcache.debug' ); ?>
        + checkbox_debug( 'minify.debug' ); ?>
        + checkbox_debug( 'dbcache.debug' ); ?>
        + checkbox_debug( 'objectcache.debug' ); ?>
        + + checkbox_debug( array( 'fragmentcache', 'debug' ) ); ?>
        + + checkbox_debug( 'cdn.debug' ); ?>
        + checkbox_debug( 'cdnfsd.debug' ); ?>
        + checkbox_debug( 'varnish.debug' ); ?> + +
        + checkbox_debug( 'cluster.messagebus.debug' ); ?> + +

        + ', + '' + ), + array( + 'acronym' => array( + 'title' => array(), + ), + ) + ); + ?> +

        +
        + + + + + + +
        + + + checkbox_debug_pro( + 'pgcache.debug_purge', + __( 'Page Cache Purge Log', 'w3-total-cache' ), + ' (' . __( 'view log', 'w3-total-cache' ) . ')' + ); + ?> +
        + + checkbox_debug_pro( + 'dbcache.debug_purge', + __( 'Database Cache Purge Log', 'w3-total-cache' ), + ' (' . __( 'view log', 'w3-total-cache' ) . ')' + ); + ?> +
        + + checkbox_debug_pro( + 'objectcache.debug_purge', + __( 'Object Cache Purge Log', 'w3-total-cache' ), + ' (' . __( 'view log', 'w3-total-cache' ) . ')' + ); + ?> +
        + + + +
        + + + + _config->is_extension_active( 'imageservice' ) + ? Util_UI::admin_url( 'upload.php?page=w3tc_extension_page_imageservice' ) + : '' + ); + + if ( $this->_config->get_boolean( 'extension.imageservice' ) ) { + Extensions_Util::activate_extension( 'imageservice', $this->_config ); + } else { + Extensions_Util::deactivate_extension( 'imageservice', $this->_config ); + } + ?> + + _config->is_extension_active( 'imageservice' ) + ? sprintf( + // Translators: 1 name of plugin, 2 opening HTML a tag, 3 closing HTML a tag. + __( 'The tool and its settings can be found on the %1$s %2$sWebP Converter%3$s page.', 'w3-total-cache' ), + 'Total Cache', + '', + '' + ) : ''; + Util_Ui::config_item_pro( + array( + 'key' => 'extension.imageservice', + 'label' => esc_html__( 'WebP Converter', 'w3-total-cache' ), + 'control' => 'checkbox', + 'checkbox_label' => __( 'Enable WebP Converter Extension', 'w3-total-cache' ), + 'excerpt' => wp_kses( + sprintf( + // translators: 1 HTML line breaks, 2 license rates for free/pro users, 3 link to image service tool. + __( + 'This extension allows for optimizing media library images to WebP format.%1$s%2$s%1$s%3$s', + 'w3-total-cache' + ), + '

        ', + Util_Environment::is_w3tc_pro( $this->_config ) + ? sprintf( + // translators: 1 free hourly rate, 2 free monthly rate, 3 opening HTML a tag to documentation URL, + // translators: 4 closing HTML a tag. + __( + 'As a Pro license holder you are granted conversion rates of %1$s/hour and %2$s/month. Conversion rates are subject to change and documentation can be found %3$shere%4$s.', + 'w3-total-cache' + ), + number_format_i18n( W3TC_IMAGE_SERVICE_PRO_HLIMIT, 0 ), + empty( W3TC_IMAGE_SERVICE_PRO_MLIMIT ) + ? esc_html__( 'unlimited', 'w3-total-cache' ) : number_format_i18n( W3TC_IMAGE_SERVICE_PRO_MLIMIT, 0 ), + '', + '' + ) + : sprintf( + // translators: 1 free hourly rate, 2 pro monthly rate, 3 pro hourly rate, 4 pro monthly rate, + // translators: 5 opening HTML a tag to documentation URL, 6 closing HTML a tag. + __( + 'As a free user you are limited to conversions of %1$s/hour and %2$s/month. The Pro license increases these rates to %3$s/hour and %4$s/month. Conversion rates are subject to change and documentation can be found %5$shere%6$s.', + 'w3-total-cache' + ), + number_format_i18n( W3TC_IMAGE_SERVICE_FREE_HLIMIT, 0 ), + number_format_i18n( W3TC_IMAGE_SERVICE_FREE_MLIMIT, 0 ), + number_format_i18n( W3TC_IMAGE_SERVICE_PRO_HLIMIT, 0 ), + empty( W3TC_IMAGE_SERVICE_PRO_MLIMIT ) + ? esc_html__( 'unlimited', 'w3-total-cache' ) : number_format_i18n( W3TC_IMAGE_SERVICE_PRO_MLIMIT, 0 ), + '', + '' + ), + $image_service_link + ), + array( + 'a' => array( + 'href' => array(), + 'target' => array(), + ), + 'br' => array(), + ) + ), + 'description' => array(), + 'label_class' => 'w3tc_single_column', + 'wrap_separate' => true, + ) + ); + ?> +
        + + + + Util_UI::admin_url( 'admin.php?page=w3tc_pagespeed' ) ) + ); + ?> _config->get_string( 'widget.pagespeed.access_token' ) ) ? $this->_config->get_string( 'widget.pagespeed.access_token' ) : '' ); $w3_pagespeed = new PageSpeed_Api( $access_token_json ); @@ -721,7 +1092,7 @@ require W3TC_INC_DIR . '/options/common/header.php'; } elseif ( ! empty( $response['refresh_token'] ) ) { update_option( 'w3tcps_authorize_success', - __( 'Google PageSpeed Insights API authorization successfull.', 'w3-total-cache' ) + __( 'Google PageSpeed Insights API authorization successful.', 'w3-total-cache' ) ); } else { update_option( @@ -730,7 +1101,7 @@ require W3TC_INC_DIR . '/options/common/header.php'; ); update_option( 'w3tcps_authorize_fail_message', - __( 'Missing refresh token.', 'w3-totoal-cache' ) + __( 'Missing refresh token.', 'w3-total-cache' ) ); } @@ -820,303 +1191,22 @@ require W3TC_INC_DIR . '/options/common/header.php'; ?> - - - - - - - - - - - - - -
        - - - - - -

        - ' . esc_html__( 'upgrading', 'w3-total-cache' ) . '' - ), - array( - 'a' => array( - 'class' => array(), - 'data-src' => array(), - 'href' => array(), - ), - ) - ); - ?> -

        -
        - - - - - - - - - - - - - - - - - - - - - - - - - - - 'docroot_fix.enable', - 'control' => 'checkbox', - 'checkbox_label' => esc_html__( 'Fix document root path', 'w3-total-cache' ), - 'label_class' => 'w3tc_single_column', - 'description' => sprintf( - // translators: 1: WordPress ABSPATH value, 2: Server document root value. - esc_html__( 'Fix incorrect server document root path. Uses the WordPress ABSPATH ("%1$s") in place of the current server document root ("%2$s").', 'w3-total-cache' ), - esc_attr( untrailingslashit( ABSPATH ) ), - esc_attr( ! empty( $_SERVER['DOCUMENT_ROOT'] ) ? esc_url_raw( wp_unslash( $_SERVER['DOCUMENT_ROOT'] ) ) : '' ) - ), - ) - ); - - Util_Ui::config_item( - array( - 'key' => 'common.track_usage', - 'control' => 'checkbox', - 'checkbox_label' => esc_html__( 'Anonymously track usage to improve product quality', 'w3-total-cache' ), - 'label_class' => 'w3tc_single_column', - ) - ); - ?> -
        - checkbox( 'common.force_master' ); ?> -

        -
        - /> -

        -
        - /> - -

        - ', - '' - ), - array( - 'a' => array( - 'href' => array(), - ), - ) - ); - ?> -

        -
        - /> - -

        - ', - '' - ), - array( - 'acronym' => array( - 'title' => array(), - ), - ) - ); - ?> -

        -
        - /> - -

        -
        - - - - - -

        - ', - '' - ), - array( - 'acronym' => array( - 'title' => array(), - ), - ) - ); - ?> -

        - - - - - - -
        - checkbox_debug( 'pgcache.debug' ); ?>
        - checkbox_debug( 'minify.debug' ); ?>
        - checkbox_debug( 'dbcache.debug' ); ?>
        - checkbox_debug( 'objectcache.debug' ); ?>
        - _config ) ) : ?> - checkbox_debug( array( 'fragmentcache', 'debug' ) ); ?>
        - - checkbox_debug( 'cdn.debug' ); ?>
        - checkbox_debug( 'cdnfsd.debug' ); ?>
        - checkbox_debug( 'varnish.debug' ); ?> - -
        - checkbox_debug( 'cluster.messagebus.debug' ); ?> - -

        - ', - '' - ), - array( - 'acronym' => array( - 'title' => array(), - ), - ) - ); - ?> -

        -
        - - - - - - -
        - - - checkbox_debug_pro( - 'pgcache.debug_purge', - __( 'Page Cache Purge Log', 'w3-total-cache' ), - ' (' . __( 'view log', 'w3-total-cache' ) . ')' - ); - ?> -
        - - checkbox_debug_pro( - 'dbcache.debug_purge', - __( 'Database Cache Purge Log', 'w3-total-cache' ), - ' (' . __( 'view log', 'w3-total-cache' ) . ')' - ); - ?> -
        - - checkbox_debug_pro( - 'objectcache.debug_purge', - __( 'Object Cache Purge Log', 'w3-total-cache' ), - ' (' . __( 'view log', 'w3-total-cache' ) . ')' - ); - ?> -
        - - - -
        - -
        -
        - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/install.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/install.php index 30bb24c9..fd848340 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/install.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/install.php @@ -418,5 +418,3 @@ if ( ! defined( 'W3TC' ) ) {
        - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/minify.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/minify.php index 93aa05bf..bc320bb1 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/minify.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/minify.php @@ -39,27 +39,6 @@ if ( ! defined( 'W3TC' ) ) { ?>

        - ' - ), - array( - 'input' => array( - 'type' => array(), - 'name' => array(), - 'value' => array(), - 'disabled' => array(), - 'class' => array(), - ), - ) - ); - ?> @@ -87,9 +66,9 @@ if ( ! defined( 'W3TC' ) ) { ); ?>

        -
        +
        @@ -153,7 +132,6 @@ if ( ! defined( 'W3TC' ) ) { ?>
        - - - - @@ -1004,7 +979,6 @@ if ( ! defined( 'W3TC' ) ) { - @@ -1071,5 +1045,3 @@ if ( ! defined( 'W3TC' ) ) {
        - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/objectcache.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/objectcache.php index e2851aa9..18d11af4 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/objectcache.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/objectcache.php @@ -7,48 +7,30 @@ if ( ! defined( 'W3TC' ) ) { ?> -
        -

        - ' . Cache::engine_name( $this->_config->get_string( 'objectcache.engine' ) ) . '', - '' . esc_html__( 'enabled', 'w3-total-cache' ) : 'disabled">' . esc_html__( 'disabled', 'w3-total-cache' ) ) . '' +

        + array(), - 'span' => array( - 'class' => array(), - ), - ) - ); - ?> -

        -

        - - array( - 'type' => array(), - 'name' => array(), - 'value' => array(), - ), - ) - ); - ?> - class="button" /> -

        -
        + '' . Cache::engine_name( $this->_config->get_string( 'objectcache.engine' ) ) . '', + '' . esc_html__( 'enabled', 'w3-total-cache' ) : 'disabled">' . esc_html__( 'disabled', 'w3-total-cache' ) ) . ( ! $this->_config->getf_boolean( 'objectcache.enabled' ) && has_filter( 'w3tc_config_item_objectcache.enabled' ) ? esc_html__( ' via filter', 'w3-total-cache' ) : '' ) . '' + ), + array( + 'strong' => array(), + 'span' => array( + 'class' => array(), + ), + ) + ); + ?> +

        +
        @@ -133,9 +115,6 @@ if ( ! defined( 'W3TC' ) ) {
        -
        - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/parts/dashboard_banner.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/parts/dashboard_banner.php index dbfcf14f..640c6515 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/parts/dashboard_banner.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/parts/dashboard_banner.php @@ -30,7 +30,7 @@ if ( ! defined( 'W3TC' ) ) { ); ?>
        -

        +

        @@ -53,10 +53,8 @@ if ( ! defined( 'W3TC' ) ) { ?>

        - +

        diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/parts/memcached.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/parts/memcached.php index cbcae00e..00e7dd2d 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/parts/memcached.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/parts/memcached.php @@ -12,15 +12,12 @@ if ( ! defined( 'W3TC' ) ) { - - value="_config->get_array( $module . '.memcached.servers' ) ) ); ?>" size="80" /> + type="button" value="" /> -

        +

        diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/parts/memcached_extension.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/parts/memcached_extension.php index 8823b4ed..8c3c53bd 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/parts/memcached_extension.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/parts/memcached_extension.php @@ -14,15 +14,12 @@ $config = Dispatcher::config(); - - value="get_array( array( $module, 'memcached.servers' ) ) ) ); ?>" size="80" /> + type="button" value="" /> -

        +

        - - value="_config->get_array( $module . '.redis.servers' ) ) ); ?>" - size="100" /> + type="button" value="" /> -

        +

        - - value="get_array( array( $module, 'redis.servers' ) ) ) ); ?>" - size="100" /> + type="button" value="" /> -

        +

        -
        -

        - ' . esc_html( Cache::engine_name( $this->_config->get_string( 'pgcache.engine' ) ) ) . '', - '' . esc_html__( 'enabled', 'w3-total-cache' ) : 'disabled">' . esc_html__( 'disabled', 'w3-total-cache' ) ) . '.' +

        + array(), - 'span' => array( - 'class' => array(), - ), - ) - ); - ?> -

        -

        - ' + '' . esc_html( Cache::engine_name( $this->_config->get_string( 'pgcache.engine' ) ) ) . '', + '' . esc_html__( 'enabled', 'w3-total-cache' ) : 'disabled">' . esc_html__( 'disabled', 'w3-total-cache' ) ) . '.' + ), + array( + 'strong' => array(), + 'span' => array( + 'class' => array(), ), - array( - 'input' => array( - 'type' => array(), - 'name' => array(), - 'value' => array(), - 'disabled' => array(), - 'class' => array(), - ), - ) - ); - ?> -

        -
        + ) + ); + ?> +

        +
        @@ -147,7 +123,6 @@ if ( ! defined( 'W3TC' ) ) {
        - @@ -209,7 +184,7 @@ if ( ! defined( 'W3TC' ) ) { ); ?> - + @@ -278,7 +253,6 @@ if ( ! defined( 'W3TC' ) ) { - - - + @@ -808,7 +781,6 @@ if ( ! defined( 'W3TC' ) ) { - @@ -881,5 +853,3 @@ if ( ! defined( 'W3TC' ) ) {
        - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/support.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/support.php index 2f06b89f..def5c5f1 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/support.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/options/support.php @@ -28,5 +28,3 @@ if ( ! defined( 'W3TC' ) ) { } ?>
        - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_export_file.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_export_file.php index c917671c..15ee620d 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_export_file.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_export_file.php @@ -58,5 +58,3 @@ if ( ! defined( 'W3TC' ) ) {
        - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_export_library.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_export_library.php index 04187512..3d229b27 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_export_library.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_export_library.php @@ -48,5 +48,3 @@ jQuery(function() {
        - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_import_library.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_import_library.php index 957952cb..0772e978 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_import_library.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_import_library.php @@ -93,5 +93,3 @@ jQuery(function() {

        - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_purge.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_purge.php index 832faf4a..f44ea048 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_purge.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_purge.php @@ -84,5 +84,3 @@ if ( ! defined( 'W3TC' ) ) {
        - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_queue.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_queue.php index c5ce3a3c..0e10eec4 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_queue.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_queue.php @@ -106,5 +106,3 @@ if ( ! defined( 'W3TC' ) ) {

        - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_rename_domain.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_rename_domain.php index f8176e68..79b9bd7f 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_rename_domain.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/popup/cdn_rename_domain.php @@ -74,5 +74,3 @@ jQuery(function() {
        - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/wizard/template.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/wizard/template.php index 137a627f..9a58205c 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/wizard/template.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/inc/wizard/template.php @@ -98,85 +98,86 @@ class Template { 'tr' => array(), ); + do_action( 'w3tc-dashboard-head' ); ?> +
        + +
        -
        - -
        - -
        - TOTAL CACHE: config['title'] ); ?> -
        -
        - -
        - -
          - config['steps'] as $number => $step ) { - $number++; - $element_id = 'w3tc-wizard-step-' . ( isset( $step['id'] ) ? $step['id'] : $number ); - if ( isset( $this->config['steps_location'] ) && 'left' === $this->config['steps_location'] ) { - ?> -
        • - -
        • - -
        • -
        • - -
        - - config['slides'] as $number => $slide ) { - $number++; - $element_id = 'w3tc-wizard-slide-' . ( isset( $slide['id'] ) ? $slide['id'] : $number ); - ?> -
        -

        - +
        + +
        + TOTAL CACHE: config['title'] ); ?>
        - - -
        - - - - -
        +
        + +
          + config['steps'] as $number => $step ) { + $number++; + $element_id = 'w3tc-wizard-step-' . ( isset( $step['id'] ) ? $step['id'] : $number ); + if ( isset( $this->config['steps_location'] ) && 'left' === $this->config['steps_location'] ) { + ?> +
        • + +
        • + +
        • +
        • + +
        + + config['slides'] as $number => $slide ) { + $number++; + $element_id = 'w3tc-wizard-slide-' . ( isset( $slide['id'] ) ? $slide['id'] : $number ); + ?> +
        +

        + +
        + + +
        + + + + + +
        \n" "Language-Team: LANGUAGE \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"POT-Creation-Date: 2023-06-19T14:09:34+00:00\n" +"POT-Creation-Date: 2023-08-09T13:31:59+00:00\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "X-Generator: WP-CLI 2.5.0\n" "X-Domain: w3-total-cache\n" #. Plugin Name of the plugin -#: Generic_Plugin_Admin.php:1071 -#: SetupGuide_Plugin_Admin.php:1081 -#: SetupGuide_Plugin_Admin.php:1127 -#: SetupGuide_Plugin_Admin.php:1199 -#: SetupGuide_Plugin_Admin.php:1228 +#: Generic_Plugin_Admin.php:1095 +#: SetupGuide_Plugin_Admin.php:1161 +#: SetupGuide_Plugin_Admin.php:1207 +#: SetupGuide_Plugin_Admin.php:1279 +#: SetupGuide_Plugin_Admin.php:1308 msgid "W3 Total Cache" msgstr "" @@ -32,6 +32,10 @@ msgid "The highest rated and most complete WordPress performance plugin. Dramati msgstr "" #. Author of the plugin +#: inc/options/common/footer.php:100 +#: inc/options/common/footer.php:101 +#: inc/options/common/footer.php:103 +#: inc/options/common/footer.php:104 msgid "BoldGrid" msgstr "" @@ -58,14 +62,14 @@ msgstr "" #: BrowserCache_ConfigLabels.php:11 #: BrowserCache_ConfigLabels.php:22 #: BrowserCache_ConfigLabels.php:31 -#: inc/options/browsercache.php:88 +#: inc/options/browsercache.php:89 msgid "Set Last-Modified header" msgstr "" #: BrowserCache_ConfigLabels.php:12 #: BrowserCache_ConfigLabels.php:23 #: BrowserCache_ConfigLabels.php:32 -#: inc/options/browsercache.php:98 +#: inc/options/browsercache.php:99 msgid "Set expires header" msgstr "" @@ -78,7 +82,7 @@ msgstr "" #: BrowserCache_ConfigLabels.php:14 #: BrowserCache_ConfigLabels.php:25 #: BrowserCache_ConfigLabels.php:34 -#: inc/options/browsercache.php:105 +#: inc/options/browsercache.php:106 msgid "Set cache control header" msgstr "" @@ -95,7 +99,7 @@ msgstr "" #: BrowserCache_ConfigLabels.php:17 #: BrowserCache_ConfigLabels.php:28 #: BrowserCache_ConfigLabels.php:37 -#: inc/options/browsercache.php:120 +#: inc/options/browsercache.php:121 msgid "Set W3 Total Cache header" msgstr "" @@ -111,7 +115,7 @@ msgstr "" #: BrowserCache_ConfigLabels.php:20 #: BrowserCache_ConfigLabels.php:40 -#: inc/options/browsercache.php:183 +#: inc/options/browsercache.php:184 msgid "Prevent caching of objects after settings change" msgstr "" @@ -122,7 +126,7 @@ msgstr "" #: BrowserCache_ConfigLabels.php:27 #: BrowserCache_ConfigLabels.php:36 -#: inc/options/browsercache.php:113 +#: inc/options/browsercache.php:114 msgid "Set entity tag (ETag)" msgstr "" @@ -473,7 +477,7 @@ msgid "Controls whether the current document is allowed to use the WebXR Device msgstr "" #: BrowserCache_Page_View_SectionSecurity.php:164 -#: inc/options/common/header.php:347 +#: Util_Ui.php:1786 msgid "Security Headers" msgstr "" @@ -489,16 +493,16 @@ msgstr "" #: BrowserCache_Page_View_SectionSecurity.php:383 #: inc/options/about.php:50 #: inc/options/about.php:74 -#: inc/options/browsercache.php:137 -#: inc/options/browsercache.php:165 +#: inc/options/browsercache.php:138 +#: inc/options/browsercache.php:166 #: inc/options/cdn.php:339 -#: inc/options/cdn.php:879 -#: inc/options/general.php:453 +#: inc/options/cdn.php:876 +#: inc/options/general.php:448 #: inc/options/install.php:114 -#: inc/options/minify.php:572 -#: inc/options/minify.php:847 -#: inc/options/minify.php:1025 -#: inc/options/pgcache.php:830 +#: inc/options/minify.php:549 +#: inc/options/minify.php:823 +#: inc/options/minify.php:999 +#: inc/options/pgcache.php:802 msgid "Hypertext Transfer Protocol" msgstr "" @@ -517,13 +521,13 @@ msgstr "" #: BrowserCache_Page_View_SectionSecurity.php:758 #: BrowserCache_Page_View_SectionSecurity.php:948 #: BrowserCache_Page_View_SectionSecurity.php:1080 -#: Generic_Plugin_Admin.php:879 -#: inc/options/browsercache.php:201 +#: Generic_Plugin_Admin.php:902 +#: inc/options/browsercache.php:202 #: inc/options/browsercache.php:473 -#: inc/options/browsercache.php:702 -#: inc/options/pgcache.php:177 -#: inc/options/pgcache.php:544 -#: inc/options/pgcache.php:623 +#: inc/options/browsercache.php:700 +#: inc/options/pgcache.php:152 +#: inc/options/pgcache.php:517 +#: inc/options/pgcache.php:596 msgid "Uniform Resource Locator" msgstr "" @@ -558,11 +562,11 @@ msgstr "" #: Cdn_StackPath_Page_View.php:131 #: Cdn_StackPath_Page_View.php:157 #: Cdn_StackPath_Page_View.php:201 -#: Extension_CloudFlare_Page_View.php:698 -#: Extension_CloudFlare_Page_View.php:745 -#: Extension_CloudFlare_Page_View.php:767 -#: Extension_CloudFlare_Page_View.php:783 -#: inc/options/cdn.php:466 +#: Extension_CloudFlare_Page_View.php:690 +#: Extension_CloudFlare_Page_View.php:737 +#: Extension_CloudFlare_Page_View.php:759 +#: Extension_CloudFlare_Page_View.php:775 +#: inc/options/cdn.php:464 #: inc/options/cdn/akamai.php:59 #: inc/options/cdn/akamai.php:89 #: inc/options/cdn/att.php:33 @@ -590,9 +594,9 @@ msgid "Secure Sockets Layer" msgstr "" #: BrowserCache_Page_View_SectionSecurity.php:258 -#: Extension_CloudFlare_Page_View.php:805 -#: Extension_CloudFlare_Page_View.php:821 -#: Extension_CloudFlare_Page_View.php:844 +#: Extension_CloudFlare_Page_View.php:797 +#: Extension_CloudFlare_Page_View.php:813 +#: Extension_CloudFlare_Page_View.php:836 msgid "Transport Layer Security" msgstr "" @@ -728,31 +732,30 @@ msgstr "" #: BrowserCache_Page_View_SectionSecurity.php:727 #: BrowserCache_Page_View_SectionSecurity.php:1049 -#: Cdn_GeneralPage_View.php:104 -#: Extension_CloudFlare_Page_View.php:396 +#: Cdn_GeneralPage_View.php:95 +#: Extension_CloudFlare_Page_View.php:388 #: inc/options/about.php:78 #: inc/options/about.php:139 #: inc/options/about.php:185 #: inc/options/browsercache.php:361 #: inc/options/cdn.php:261 #: inc/options/cdn/s3_compatible.php:31 -#: inc/options/common/header.php:256 -#: inc/options/common/header.php:310 -#: inc/options/general.php:207 -#: inc/options/general.php:233 +#: inc/options/general.php:219 #: inc/options/install.php:76 -#: inc/options/minify.php:118 -#: inc/options/minify.php:615 -#: inc/options/minify.php:634 -#: inc/options/minify.php:727 -#: inc/options/minify.php:818 -#: inc/options/minify.php:967 +#: inc/options/minify.php:97 +#: inc/options/minify.php:591 +#: inc/options/minify.php:610 +#: inc/options/minify.php:703 +#: inc/options/minify.php:794 +#: inc/options/minify.php:942 #: Minify_HelpPopup_View.php:54 #: Minify_HelpPopup_View.php:82 #: Minify_HelpPopup_View.php:110 #: PageSpeed_Instructions.php:68 #: PageSpeed_Instructions.php:85 #: PageSpeed_Instructions.php:357 +#: Util_Ui.php:1701 +#: Util_Ui.php:1749 msgid "Cascading Style Sheet" msgstr "" @@ -835,7 +838,20 @@ msgid "One of:" msgstr "" #: BrowserCache_Plugin.php:380 -msgid "Browser Cache: Update Media Query String" +#: FeatureShowcase_Plugin_Admin.php:456 +#: inc/options/common/top_nav_bar.php:40 +#: inc/options/general.php:418 +#: PageSpeed_Instructions.php:307 +#: PageSpeed_Instructions.php:517 +#: PageSpeed_Instructions.php:578 +#: Root_AdminMenu.php:85 +#: Root_AdminMenu.php:86 +#: SetupGuide_Plugin_Admin.php:1136 +#: SetupGuide_Plugin_Admin.php:1301 +#: SetupGuide_Plugin_Admin.php:1334 +#: Util_PageUrls.php:913 +#: Util_Ui.php:1560 +msgid "Browser Cache" msgstr "" #. translators: 1 opening HTML a tag to Browser Cache CSP-Report-Only settings, 2 closing HTML a tag. @@ -852,144 +868,144 @@ msgid "Enabling even a single user agent group will set a cookie called \"w3tc_r msgstr "" #: CacheGroups_Plugin_Admin.php:48 -#: CacheGroups_Plugin_Admin_View.php:336 +#: CacheGroups_Plugin_Admin_View.php:328 msgid "Per the above, make sure that visitors are notified about the cookie as per any regulations in your market." msgstr "" -#: CacheGroups_Plugin_Admin_View.php:35 -#: inc/options/common/header.php:357 +#: CacheGroups_Plugin_Admin_View.php:36 +#: Util_Ui.php:1794 msgid "Manage User Agent Groups" msgstr "" -#: CacheGroups_Plugin_Admin_View.php:39 -#: CacheGroups_Plugin_Admin_View.php:164 -#: CacheGroups_Plugin_Admin_View.php:242 +#: CacheGroups_Plugin_Admin_View.php:40 +#: CacheGroups_Plugin_Admin_View.php:161 +#: CacheGroups_Plugin_Admin_View.php:238 msgid "Create a group" msgstr "" -#: CacheGroups_Plugin_Admin_View.php:40 +#: CacheGroups_Plugin_Admin_View.php:41 msgid "of user agents by specifying names in the user agents field. Assign a set of user agents to use a specific theme, redirect them to another domain or if an existing mobile plugin is active, create user agent groups to ensure that a unique cache is created for each user agent group. Drag and drop groups into order (if needed) to determine their priority (top -> down)." msgstr "" -#: CacheGroups_Plugin_Admin_View.php:54 -#: CacheGroups_Plugin_Admin_View.php:178 -#: CacheGroups_Plugin_Admin_View.php:256 +#: CacheGroups_Plugin_Admin_View.php:55 +#: CacheGroups_Plugin_Admin_View.php:175 +#: CacheGroups_Plugin_Admin_View.php:252 msgid "Group name:" msgstr "" -#: CacheGroups_Plugin_Admin_View.php:59 -#: CacheGroups_Plugin_Admin_View.php:181 -#: CacheGroups_Plugin_Admin_View.php:262 +#: CacheGroups_Plugin_Admin_View.php:60 +#: CacheGroups_Plugin_Admin_View.php:178 +#: CacheGroups_Plugin_Admin_View.php:258 msgid "Delete group" msgstr "" -#: CacheGroups_Plugin_Admin_View.php:65 -#: CacheGroups_Plugin_Admin_View.php:186 -#: CacheGroups_Plugin_Admin_View.php:269 +#: CacheGroups_Plugin_Admin_View.php:66 +#: CacheGroups_Plugin_Admin_View.php:183 +#: CacheGroups_Plugin_Admin_View.php:265 msgid "Enabled:" msgstr "" -#: CacheGroups_Plugin_Admin_View.php:78 -#: CacheGroups_Plugin_Admin_View.php:195 -#: inc/options/minify.php:458 -#: inc/options/minify.php:741 +#: CacheGroups_Plugin_Admin_View.php:79 +#: CacheGroups_Plugin_Admin_View.php:192 +#: inc/options/minify.php:435 +#: inc/options/minify.php:717 msgid "Theme:" msgstr "" -#: CacheGroups_Plugin_Admin_View.php:84 -#: CacheGroups_Plugin_Admin_View.php:199 +#: CacheGroups_Plugin_Admin_View.php:85 +#: CacheGroups_Plugin_Admin_View.php:196 msgid "-- Pass-through --" msgstr "" -#: CacheGroups_Plugin_Admin_View.php:90 +#: CacheGroups_Plugin_Admin_View.php:91 msgid "Assign this group of user agents to a specific theme. Selecting \"Pass-through\" allows any plugin(s) (e.g. mobile plugins) to properly handle requests for these user agents. If the \"redirect users to\" field is not empty, this setting is ignored." msgstr "" -#: CacheGroups_Plugin_Admin_View.php:96 -#: CacheGroups_Plugin_Admin_View.php:209 +#: CacheGroups_Plugin_Admin_View.php:97 +#: CacheGroups_Plugin_Admin_View.php:206 msgid "Redirect users to:" msgstr "" -#: CacheGroups_Plugin_Admin_View.php:104 +#: CacheGroups_Plugin_Admin_View.php:105 msgid "A 302 redirect is used to send this group of users to another hostname (domain); recommended if a 3rd party service provides a mobile version of your site." msgstr "" -#: CacheGroups_Plugin_Admin_View.php:109 +#: CacheGroups_Plugin_Admin_View.php:110 msgid "User agents:" msgstr "" -#: CacheGroups_Plugin_Admin_View.php:116 +#: CacheGroups_Plugin_Admin_View.php:117 msgid "Specify the user agents for this group. Remember to escape special characters like spaces, dots or dashes with a backslash. Regular expressions are also supported." msgstr "" -#: CacheGroups_Plugin_Admin_View.php:124 +#: CacheGroups_Plugin_Admin_View.php:125 msgid "No groups added. All user agents recieve the same page and minify cache results." msgstr "" -#: CacheGroups_Plugin_Admin_View.php:134 -#: CacheGroups_Plugin_Admin_View.php:323 -#: inc/options/cdn.php:860 +#: CacheGroups_Plugin_Admin_View.php:131 +#: CacheGroups_Plugin_Admin_View.php:315 +#: inc/options/cdn.php:857 #: inc/options/install.php:361 -#: inc/options/minify.php:1010 +#: inc/options/minify.php:984 msgid "Note(s):" msgstr "" -#: CacheGroups_Plugin_Admin_View.php:162 -#: inc/options/common/header.php:358 +#: CacheGroups_Plugin_Admin_View.php:159 +#: Util_Ui.php:1795 msgid "Manage Referrer Groups" msgstr "" -#: CacheGroups_Plugin_Admin_View.php:164 +#: CacheGroups_Plugin_Admin_View.php:161 msgid "of referrers by specifying names in the referrers field. Assign a set of referrers to use a specific theme, redirect them to another domain, create referrer groups to ensure that a unique cache is created for each referrer group. Drag and drop groups into order (if needed) to determine their priority (top -> down)." msgstr "" -#: CacheGroups_Plugin_Admin_View.php:204 +#: CacheGroups_Plugin_Admin_View.php:201 msgid "Assign this group of referrers to a specific theme. Selecting \"Pass-through\" allows any plugin(s) (e.g. referrer plugins) to properly handle requests for these referrers. If the \"redirect users to\" field is not empty, this setting is ignored." msgstr "" -#: CacheGroups_Plugin_Admin_View.php:213 +#: CacheGroups_Plugin_Admin_View.php:210 msgid "A 302 redirect is used to send this group of referrers to another hostname (domain)." msgstr "" -#: CacheGroups_Plugin_Admin_View.php:218 +#: CacheGroups_Plugin_Admin_View.php:215 #: Generic_ConfigLabels.php:20 msgid "Referrers:" msgstr "" -#: CacheGroups_Plugin_Admin_View.php:222 +#: CacheGroups_Plugin_Admin_View.php:219 msgid "Specify the referrers for this group. Remember to escape special characters like spaces, dots or dashes with a backslash. Regular expressions are also supported." msgstr "" -#: CacheGroups_Plugin_Admin_View.php:229 +#: CacheGroups_Plugin_Admin_View.php:226 msgid "No groups added. All referrers recieve the same page and minify cache results." msgstr "" -#: CacheGroups_Plugin_Admin_View.php:238 -#: inc/options/common/header.php:359 +#: CacheGroups_Plugin_Admin_View.php:234 +#: Util_Ui.php:1796 msgid "Manage Cookie Groups" msgstr "" -#: CacheGroups_Plugin_Admin_View.php:243 +#: CacheGroups_Plugin_Admin_View.php:239 msgid "of Cookies by specifying names in the Cookies field. Assign a set of Cookies to ensure that a unique cache is created for each Cookie group. Drag and drop groups into order (if needed) to determine their priority (top -> down)." msgstr "" -#: CacheGroups_Plugin_Admin_View.php:283 +#: CacheGroups_Plugin_Admin_View.php:279 msgid "Cache:" msgstr "" -#: CacheGroups_Plugin_Admin_View.php:297 +#: CacheGroups_Plugin_Admin_View.php:293 msgid "Cookies:" msgstr "" -#: CacheGroups_Plugin_Admin_View.php:305 +#: CacheGroups_Plugin_Admin_View.php:301 msgid "Specify the cookies for this group. Values like 'cookie', 'cookie=value', and cookie[a-z]+=value[a-z]+ are supported. Remember to escape special characters like spaces, dots or dashes with a backslash. Regular expressions are also supported." msgstr "" -#: CacheGroups_Plugin_Admin_View.php:313 +#: CacheGroups_Plugin_Admin_View.php:309 msgid "No groups added. All Cookies recieve the same page and minify cache results." msgstr "" -#: CacheGroups_Plugin_Admin_View.php:333 +#: CacheGroups_Plugin_Admin_View.php:325 msgid "Content is cached for each group separately." msgstr "" @@ -1220,29 +1236,29 @@ msgstr "" msgid "Secret key not specified." msgstr "" -#: Cdnfsd_CloudFront_Page_View.php:14 -#: Cdnfsd_LimeLight_Page_View.php:14 -#: Cdnfsd_StackPath2_Page_View.php:16 -#: Cdnfsd_StackPath_Page_View.php:14 -#: Cdnfsd_TransparentCDN_Page_View.php:22 -#: Extension_CloudFlare_Cdn_Page_View.php:10 +#: Cdnfsd_CloudFront_Page_View.php:12 +#: Cdnfsd_LimeLight_Page_View.php:12 +#: Cdnfsd_StackPath2_Page_View.php:14 +#: Cdnfsd_StackPath_Page_View.php:12 +#: Cdnfsd_TransparentCDN_Page_View.php:20 +#: Extension_CloudFlare_Cdn_Page_View.php:8 msgid "Configuration: Full-Site Delivery" msgstr "" -#: Cdnfsd_CloudFront_Page_View.php:19 -#: Cdnfsd_LimeLight_Page_View.php:19 -#: Cdnfsd_StackPath2_Page_View.php:25 -#: Cdnfsd_StackPath_Page_View.php:19 +#: Cdnfsd_CloudFront_Page_View.php:17 +#: Cdnfsd_LimeLight_Page_View.php:17 +#: Cdnfsd_StackPath2_Page_View.php:23 +#: Cdnfsd_StackPath_Page_View.php:17 #: Cdn_StackPath2_Page_View.php:45 #: Cdn_StackPath_Page_View.php:21 -#: Extension_CloudFlare_Page_View.php:55 +#: Extension_CloudFlare_Page_View.php:48 msgid "Specify account credentials:" msgstr "" -#: Cdnfsd_CloudFront_Page_View.php:25 -#: Cdnfsd_LimeLight_Page_View.php:25 -#: Cdnfsd_StackPath2_Page_View.php:32 -#: Cdnfsd_StackPath_Page_View.php:26 +#: Cdnfsd_CloudFront_Page_View.php:23 +#: Cdnfsd_LimeLight_Page_View.php:23 +#: Cdnfsd_StackPath2_Page_View.php:30 +#: Cdnfsd_StackPath_Page_View.php:24 #: Cdn_GoogleDrive_Page_View.php:19 #: Cdn_Highwinds_Page_View.php:17 #: Cdn_LimeLight_Page_View.php:18 @@ -1250,14 +1266,14 @@ msgstr "" #: Cdn_RackSpaceCloudFiles_Page_View.php:16 #: Cdn_StackPath2_Page_View.php:57 #: Cdn_StackPath_Page_View.php:28 -#: Extension_CloudFlare_Page_View.php:63 +#: Extension_CloudFlare_Page_View.php:56 msgid "Reauthorize" msgstr "" -#: Cdnfsd_CloudFront_Page_View.php:28 -#: Cdnfsd_LimeLight_Page_View.php:28 -#: Cdnfsd_StackPath2_Page_View.php:37 -#: Cdnfsd_StackPath_Page_View.php:31 +#: Cdnfsd_CloudFront_Page_View.php:26 +#: Cdnfsd_LimeLight_Page_View.php:26 +#: Cdnfsd_StackPath2_Page_View.php:35 +#: Cdnfsd_StackPath_Page_View.php:29 #: Cdn_GoogleDrive_Page_View.php:16 #: Cdn_Highwinds_Page_View.php:14 #: Cdn_LimeLight_Page_View.php:15 @@ -1267,31 +1283,30 @@ msgstr "" #: Cdn_StackPath2_Widget_View_Unauthorized.php:68 #: Cdn_StackPath_Page_View.php:33 #: Cdn_StackPath_Widget_View_Unauthorized.php:38 -#: Extension_CloudFlare_Page_View.php:68 +#: Extension_CloudFlare_Page_View.php:61 msgid "Authorize" msgstr "" #. translators: 3 opening HTML acronym tag, 4 closing HTML acronym tag. -#: Cdnfsd_CloudFront_Page_View.php:42 -#: Cdnfsd_StackPath2_Page_View.php:52 -#: Cdnfsd_StackPath_Page_View.php:46 +#: Cdnfsd_CloudFront_Page_View.php:40 +#: Cdnfsd_StackPath2_Page_View.php:50 +#: Cdnfsd_StackPath_Page_View.php:44 msgid "%1$sCDN%2$s %3$sCNAME%4$s:" msgstr "" -#: Cdnfsd_CloudFront_Page_View.php:46 +#: Cdnfsd_CloudFront_Page_View.php:44 #: Cdnfsd_GeneralPage_View.php:21 #: Cdnfsd_GeneralPage_View.php:34 #: Cdnfsd_GeneralPage_View.php:68 #: Cdnfsd_GeneralPage_View.php:116 #: Cdnfsd_GeneralPage_View.php:137 -#: Cdnfsd_StackPath2_Page_View.php:56 -#: Cdnfsd_StackPath_Page_View.php:50 +#: Cdnfsd_StackPath2_Page_View.php:54 +#: Cdnfsd_StackPath_Page_View.php:48 #: Cdnfsd_StackPath_Popup_View_Zone.php:42 #: Cdnfsd_StackPath_Popup_View_Zone.php:50 #: Cdn_GeneralPage_View.php:22 -#: Cdn_GeneralPage_View.php:51 -#: Cdn_GeneralPage_View.php:71 -#: Cdn_GeneralPage_View.php:131 +#: Cdn_GeneralPage_View.php:62 +#: Cdn_GeneralPage_View.php:122 #: Cdn_Highwinds_Page_View.php:35 #: Cdn_Highwinds_Page_View.php:92 #: Cdn_Highwinds_Page_View.php:144 @@ -1322,7 +1337,7 @@ msgstr "" #: Cdn_StackPath_Page_View.php:231 #: Cdn_StackPath_Widget_View_Unauthorized.php:16 #: Cdn_StackPath_Widget_View_Unauthorized.php:33 -#: Generic_Plugin_Admin.php:971 +#: Generic_Plugin_Admin.php:995 #: inc/lightbox/self_test.php:122 #: inc/lightbox/self_test.php:247 #: inc/lightbox/self_test.php:318 @@ -1331,26 +1346,26 @@ msgstr "" #: inc/options/about.php:119 #: inc/options/about.php:141 #: inc/options/about.php:226 -#: inc/options/cdn.php:73 -#: inc/options/cdn.php:95 +#: inc/options/cdn.php:71 +#: inc/options/cdn.php:93 #: inc/options/cdn.php:149 #: inc/options/cdn.php:196 #: inc/options/cdn.php:227 #: inc/options/cdn.php:265 #: inc/options/cdn.php:297 -#: inc/options/cdn.php:394 -#: inc/options/cdn.php:413 -#: inc/options/cdn.php:468 -#: inc/options/cdn.php:495 -#: inc/options/cdn.php:595 -#: inc/options/cdn.php:675 -#: inc/options/cdn.php:703 -#: inc/options/cdn.php:740 -#: inc/options/cdn.php:771 -#: inc/options/cdn.php:798 +#: inc/options/cdn.php:392 +#: inc/options/cdn.php:411 +#: inc/options/cdn.php:466 +#: inc/options/cdn.php:493 +#: inc/options/cdn.php:593 +#: inc/options/cdn.php:673 +#: inc/options/cdn.php:701 +#: inc/options/cdn.php:738 +#: inc/options/cdn.php:769 +#: inc/options/cdn.php:796 +#: inc/options/cdn.php:838 #: inc/options/cdn.php:840 -#: inc/options/cdn.php:842 -#: inc/options/cdn.php:877 +#: inc/options/cdn.php:874 #: inc/options/cdn/akamai.php:87 #: inc/options/cdn/akamai.php:119 #: inc/options/cdn/att.php:61 @@ -1368,19 +1383,19 @@ msgstr "" #: inc/options/cdn/rscf.php:104 #: inc/options/cdn/s3.php:123 #: inc/options/cdn/s3_compatible.php:99 -#: inc/options/common/header.php:100 #: inc/options/install.php:146 #: inc/options/install.php:150 #: inc/popup/cdn_import_library.php:57 #: inc/popup/cdn_purge.php:19 #: Root_AdminMenu.php:97 #: Root_AdminMenu.php:100 +#: Util_Ui.php:1571 msgid "Content Delivery Network" msgstr "" -#: Cdnfsd_CloudFront_Page_View.php:48 -#: Cdnfsd_StackPath2_Page_View.php:58 -#: Cdnfsd_StackPath_Page_View.php:52 +#: Cdnfsd_CloudFront_Page_View.php:46 +#: Cdnfsd_StackPath2_Page_View.php:56 +#: Cdnfsd_StackPath_Page_View.php:50 #: Cdn_Highwinds_Page_View.php:37 #: Cdn_Highwinds_Page_View.php:123 #: Cdn_Highwinds_Popup_View_ConfigureCnamesForm.php:24 @@ -1430,9 +1445,9 @@ msgstr "" #: Cdnfsd_CloudFront_Popup_View_Distribution.php:40 #: Cdnfsd_CloudFront_Popup_View_Distribution.php:44 -#: Extension_CloudFlare_Page_View.php:619 -#: Extension_CloudFlare_Page_View.php:643 -#: Extension_CloudFlare_Page_View.php:659 +#: Extension_CloudFlare_Page_View.php:611 +#: Extension_CloudFlare_Page_View.php:635 +#: Extension_CloudFlare_Page_View.php:651 msgid "Internet Protocol" msgstr "" @@ -1556,19 +1571,20 @@ msgstr "" #: Cdn_StackPath_Widget_View_Unauthorized.php:16 #: Cdn_StackPath_Widget_View_Unauthorized.php:33 #: Extension_NewRelic_AdminNotes.php:23 -#: Generic_Plugin_Admin.php:971 +#: Generic_Plugin_Admin.php:995 #: PageSpeed_Instructions.php:383 #: PageSpeed_Instructions.php:397 #: PageSpeed_Instructions.php:579 #: PageSpeed_Instructions.php:621 #: PageSpeed_Instructions.php:644 +#: Util_PageUrls.php:923 msgid "CDN" msgstr "" #. translators: 3 opening HTML a tag to W3TC MaxCDN Signup admin page, 4 closing HTML a tag. #. translators: 3 opening HTML a tag, 4 closing HTML a tag. #: Cdnfsd_GeneralPage_View.php:30 -#: Cdn_GeneralPage_View.php:67 +#: Cdn_GeneralPage_View.php:58 msgid "If you do not have a %1$sCDN%2$s provider try StackPath. %3$sSign up now to enjoy a special offer!%4$s." msgstr "" @@ -1580,45 +1596,47 @@ msgstr "" #: Cdnfsd_GeneralPage_View.php:66 #: Cdnfsd_GeneralPage_View.php:114 #: Generic_WidgetCommunity_View.php:22 +#: inc/options/common/footer.php:61 +#: inc/options/common/footer.php:62 msgid "Full Site Delivery" msgstr "" #: Cdnfsd_GeneralPage_View.php:78 -#: Cdn_GeneralPage_View.php:95 -#: extension-example/Extension_Example_Page_View.php:28 +#: Cdn_GeneralPage_View.php:86 +#: extension-example/Extension_Example_Page_View.php:27 +#: Extension_Genesis_Page_View.php:29 #: Extension_Genesis_Page_View.php:38 #: Extension_Genesis_Page_View.php:47 #: Extension_Genesis_Page_View.php:56 -#: Extension_Genesis_Page_View.php:65 +#: Extension_Genesis_Page_View.php:72 #: Extension_Genesis_Page_View.php:81 -#: Extension_Genesis_Page_View.php:90 +#: Extension_Genesis_Page_View.php:98 #: Extension_Genesis_Page_View.php:107 -#: Extension_Genesis_Page_View.php:116 +#: Extension_Genesis_Page_View.php:124 #: Extension_Genesis_Page_View.php:133 -#: Extension_Genesis_Page_View.php:142 -#: Extension_Genesis_Page_View.php:159 +#: Extension_Genesis_Page_View.php:150 +#: Extension_Genesis_Page_View.php:175 #: Extension_Genesis_Page_View.php:184 #: Extension_Genesis_Page_View.php:193 -#: Extension_Genesis_Page_View.php:202 -#: inc/options/general.php:98 -#: inc/options/general.php:121 -#: inc/options/general.php:221 -#: inc/options/general.php:353 -#: inc/options/general.php:390 -#: inc/options/general.php:445 -#: inc/options/minify.php:285 -#: inc/options/minify.php:564 -#: inc/options/minify.php:644 -#: inc/options/minify.php:839 -#: inc/options/pgcache.php:161 -#: inc/options/pgcache.php:489 -#: inc/options/pgcache.php:497 +#: inc/options/general.php:87 +#: inc/options/general.php:119 +#: inc/options/general.php:207 +#: inc/options/general.php:341 +#: inc/options/general.php:381 +#: inc/options/general.php:440 +#: inc/options/minify.php:262 +#: inc/options/minify.php:541 +#: inc/options/minify.php:620 +#: inc/options/minify.php:815 +#: inc/options/pgcache.php:136 +#: inc/options/pgcache.php:462 +#: inc/options/pgcache.php:470 #: Minify_ConfigLabels.php:17 #: Minify_ConfigLabels.php:22 #: Minify_ConfigLabels.php:29 #: PgCache_ConfigLabels.php:40 -#: SystemOpCache_GeneralPage_View.php:41 -#: UsageStatistics_GeneralPage_View.php:20 +#: SystemOpCache_GeneralPage_View.php:55 +#: UsageStatistics_GeneralPage_View.php:41 msgid "Enable" msgstr "" @@ -1655,44 +1673,42 @@ msgstr "" #. translators: 1 HTML strong tag containing CDN Engine value, 2 HTML span tag containing CDN Engine enabled/disabled value. #: Cdnfsd_Page_View_Header.php:14 #: Cdn_Page_View_Header.php:15 -#: inc/options/cdn.php:34 +#: inc/options/cdn.php:28 msgid "Content Delivery Network support via %1$s is currently %2$s." msgstr "" #: Cdnfsd_Page_View_Header.php:19 #: Cdn_Page_View_Header.php:20 -#: extension-example/Extension_Example_Page_View.php:13 -#: Extension_CloudFlare_Page_View.php:20 -#: Extension_FragmentCache_Page_View.php:29 -#: Extension_Genesis_Page_View.php:21 -#: Extension_NewRelic_Page_View_Apm.php:18 -#: Extension_Swarmify_Page_View.php:17 +#: extension-example/Extension_Example_Page_View.php:12 +#: Extension_CloudFlare_Page_View.php:12 +#: Extension_FragmentCache_Page_View.php:22 +#: Extension_Genesis_Page_View.php:12 +#: Extension_NewRelic_Page_View_Apm.php:13 +#: Extension_Swarmify_Page_View.php:12 #: inc/options/browsercache.php:27 -#: inc/options/cdn.php:39 +#: inc/options/cdn.php:33 #: inc/options/dashboard.php:27 -#: inc/options/dbcache.php:21 -#: inc/options/general.php:26 +#: inc/options/dbcache.php:20 #: inc/options/minify.php:31 -#: inc/options/objectcache.php:21 -#: inc/options/pgcache.php:21 +#: inc/options/objectcache.php:20 +#: inc/options/pgcache.php:20 msgid "enabled" msgstr "" #: Cdnfsd_Page_View_Header.php:19 #: Cdn_Page_View_Header.php:20 -#: Extension_CloudFlare_Page_View.php:22 -#: Extension_FragmentCache_Page_View.php:31 -#: Extension_Genesis_Page_View.php:23 -#: Extension_NewRelic_Page_View_Apm.php:20 -#: Extension_Swarmify_Page_View.php:19 +#: Extension_CloudFlare_Page_View.php:14 +#: Extension_FragmentCache_Page_View.php:24 +#: Extension_Genesis_Page_View.php:14 +#: Extension_NewRelic_Page_View_Apm.php:15 +#: Extension_Swarmify_Page_View.php:14 #: inc/options/browsercache.php:27 -#: inc/options/cdn.php:39 +#: inc/options/cdn.php:33 #: inc/options/dashboard.php:27 -#: inc/options/dbcache.php:21 -#: inc/options/general.php:26 +#: inc/options/dbcache.php:20 #: inc/options/minify.php:31 -#: inc/options/objectcache.php:21 -#: inc/options/pgcache.php:21 +#: inc/options/objectcache.php:20 +#: inc/options/pgcache.php:20 msgid "disabled" msgstr "" @@ -1841,19 +1857,19 @@ msgstr "" msgid "Error. Check your parameters and try again or contact with support." msgstr "" -#: Cdnfsd_TransparentCDN_Page_View.php:30 +#: Cdnfsd_TransparentCDN_Page_View.php:28 msgid "Company id:" msgstr "" -#: Cdnfsd_TransparentCDN_Page_View.php:40 +#: Cdnfsd_TransparentCDN_Page_View.php:38 msgid "Client id:" msgstr "" -#: Cdnfsd_TransparentCDN_Page_View.php:49 +#: Cdnfsd_TransparentCDN_Page_View.php:47 msgid "Client secret:" msgstr "" -#: Cdnfsd_TransparentCDN_Page_View.php:60 +#: Cdnfsd_TransparentCDN_Page_View.php:58 msgid "Test TransparentCDN" msgstr "" @@ -2164,62 +2180,56 @@ msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. #. translators: 1 opening HTML abbr tag, 2 closing HTML abbr tag. #: Cdn_GeneralPage_View.php:18 -#: inc/options/common/header.php:96 +#: Util_Ui.php:1567 msgid "%1$sCDN%2$s" msgstr "" -#. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Cdn_GeneralPage_View.php:47 -msgid "Host static files with your %1$sCDN%2$s to reduce page load time." +#: Cdn_GeneralPage_View.php:31 +msgid "" +"Content Delivery Network (CDN) is a powerful feature that can significantly enhance the performance of \n" +"\t\t\tyour WordPress website. By leveraging a distributed network of servers located worldwide, a CDN helps \n" +"\t\t\tdeliver your website's static files, such as images, CSS, and JavaScript, to visitors more efficiently. \n" +"\t\t\tThis reduces the latency and improves the loading speed of your website, resulting in a faster and \n" +"\t\t\tsmoother browsing experience for your users. With W3 Total Cache's CDN integration, you can easily \n" +"\t\t\tconfigure and connect your website to a CDN service of your choice, unleashing the full potential of \n" +"\t\t\tyour WordPress site's speed optimization." msgstr "" #. translators: 3 opening HTML acronym tag, 4 closing acronym tag. -#: Cdn_GeneralPage_View.php:100 +#: Cdn_GeneralPage_View.php:91 msgid "Theme files, media library attachments, %1$sCSS%2$s, %3$sJS%4$s files etc will quickly for site visitors." msgstr "" -#: Cdn_GeneralPage_View.php:106 -#: Extension_CloudFlare_Page_View.php:373 +#: Cdn_GeneralPage_View.php:97 +#: Extension_CloudFlare_Page_View.php:365 #: inc/options/browsercache.php:363 #: inc/options/cdn.php:263 #: inc/options/cdn/s3_compatible.php:33 -#: inc/options/common/header.php:236 -#: inc/options/common/header.php:312 -#: inc/options/general.php:208 -#: inc/options/general.php:235 +#: inc/options/general.php:221 #: inc/options/install.php:78 #: inc/options/install.php:80 -#: inc/options/minify.php:120 -#: inc/options/minify.php:263 -#: inc/options/minify.php:281 -#: inc/options/minify.php:444 -#: inc/options/minify.php:543 -#: inc/options/minify.php:940 +#: inc/options/minify.php:99 +#: inc/options/minify.php:240 +#: inc/options/minify.php:258 +#: inc/options/minify.php:421 +#: inc/options/minify.php:520 +#: inc/options/minify.php:915 #: Minify_HelpPopup_View.php:56 #: Minify_HelpPopup_View.php:112 #: Minify_HelpPopup_View.php:114 #: PageSpeed_Instructions.php:69 #: PageSpeed_Instructions.php:86 #: PageSpeed_Instructions.php:358 +#: Util_Ui.php:1681 +#: Util_Ui.php:1751 msgid "JavaScript" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Cdn_GeneralPage_View.php:127 +#: Cdn_GeneralPage_View.php:118 msgid "Select the %1$sCDN%2$s type you wish to use." msgstr "" -#: Cdn_GeneralPage_View.php:150 -#: Extension_CloudFlare_GeneralPage_View.php:40 -#: Extension_FragmentCache_GeneralPage_View.php:27 -#: inc/options/general.php:188 -#: inc/options/general.php:330 -#: inc/options/general.php:369 -#: inc/options/general.php:424 -#: SystemOpCache_GeneralPage_View.php:50 -msgid "Empty cache" -msgstr "" - #: Cdn_GoogleDrive_Page_View.php:12 #: Cdn_Highwinds_Page_View.php:10 #: Cdn_LimeLight_Page_View.php:11 @@ -2391,7 +2401,7 @@ msgstr "" #: Cdn_StackPath2_Page_View.php:306 #: Cdn_StackPath_Page_View.php:233 #: inc/options/about.php:76 -#: inc/options/browsercache.php:507 +#: inc/options/browsercache.php:506 #: inc/options/cdn/akamai.php:121 #: inc/options/cdn/att.php:95 #: inc/options/cdn/cotendo.php:102 @@ -2399,16 +2409,15 @@ msgstr "" #: inc/options/cdn/ftp.php:331 #: inc/options/cdn/mirror.php:81 #: inc/options/cdn/rscf.php:135 -#: inc/options/common/header.php:214 -#: inc/options/common/header.php:333 -#: inc/options/general.php:209 -#: inc/options/general.php:231 -#: inc/options/general.php:1010 -#: inc/options/general.php:1049 -#: inc/options/minify.php:169 -#: inc/options/minify.php:195 -#: inc/options/pgcache.php:832 -#: inc/options/pgcache.php:861 +#: inc/options/general.php:217 +#: inc/options/general.php:877 +#: inc/options/general.php:918 +#: inc/options/minify.php:147 +#: inc/options/minify.php:173 +#: inc/options/pgcache.php:804 +#: inc/options/pgcache.php:833 +#: Util_Ui.php:1659 +#: Util_Ui.php:1772 msgid "Hypertext Markup Language" msgstr "" @@ -2464,7 +2473,7 @@ msgstr "" #: Cdn_Highwinds_Widget_View.php:18 #: Cdn_StackPath2_Widget_View_Authorized.php:20 #: Cdn_StackPath_Widget_View_Authorized.php:32 -#: inc/options/cdn.php:86 +#: inc/options/cdn.php:84 #: inc/popup/cdn_purge.php:75 msgid "Purge" msgstr "" @@ -2502,7 +2511,7 @@ msgid "Username:" msgstr "" #: Cdn_LimeLight_Popup_View_Intro.php:34 -#: Extension_Swarmify_Page_View.php:33 +#: Extension_Swarmify_Page_View.php:28 msgid "API Key:" msgstr "" @@ -2562,7 +2571,7 @@ msgid "logged in role is rejected" msgstr "" #: Cdn_Plugin.php:793 -msgid "CDN: All" +msgid "CDN Cache" msgstr "" #: Cdn_Plugin.php:802 @@ -2692,7 +2701,7 @@ msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. #: Cdn_RackSpaceCdn_Popup_View_Intro.php:31 #: Cdn_RackSpaceCloudFiles_Popup_View_Intro.php:32 -#: Extension_NewRelic_GeneralPage_View.php:48 +#: Extension_NewRelic_GeneralPage_View.php:61 #: Extension_NewRelic_Popup_View_Intro.php:25 #: inc/options/cdn/rscf.php:22 msgid "%1$sAPI%2$s key:" @@ -2702,15 +2711,15 @@ msgstr "" #: Cdn_RackSpaceCloudFiles_Popup_View_Intro.php:36 #: Extension_CloudFlare_Plugin_Admin.php:40 #: Extension_CloudFlare_Popup_View_Intro.php:36 -#: Extension_NewRelic_GeneralPage_View.php:52 +#: Extension_NewRelic_GeneralPage_View.php:65 #: Extension_NewRelic_Popup_View_Intro.php:29 #: inc/options/cdn/cotendo.php:40 #: inc/options/cdn/rscf.php:26 -#: inc/options/general.php:400 -#: inc/options/general.php:607 -#: inc/options/general.php:636 -#: inc/options/pgcache.php:404 -#: inc/options/pgcache.php:445 +#: inc/options/general.php:391 +#: inc/options/general.php:592 +#: inc/options/general.php:621 +#: inc/options/pgcache.php:377 +#: inc/options/pgcache.php:418 msgid "Application Programming Interface" msgstr "" @@ -2797,7 +2806,7 @@ msgstr "" #: Cdn_StackPath2_Page_View.php:63 #: Cdn_StackPath2_Widget_View_Unauthorized.php:71 -#: Generic_WidgetServices.php:33 +#: Generic_WidgetServices.php:37 msgid "Premium Services" msgstr "" @@ -2943,7 +2952,7 @@ msgid "Content Breakdown" msgstr "" #: Cdn_StackPath_Widget_View_Authorized.php:63 -#: SetupGuide_Plugin_Admin.php:1261 +#: SetupGuide_Plugin_Admin.php:1341 msgid "File" msgstr "" @@ -3134,18 +3143,20 @@ msgid "Database Cache:" msgstr "" #: DbCache_ConfigLabels.php:9 -#: DbCache_Plugin.php:239 -#: DbCache_Plugin.php:246 -#: DbCache_Plugin.php:255 +#: DbCache_Plugin.php:240 +#: DbCache_Plugin.php:247 +#: DbCache_Plugin.php:256 #: FeatureShowcase_Plugin_Admin.php:432 -#: inc/options/common/header.php:69 -#: inc/options/general.php:341 +#: inc/options/common/top_nav_bar.php:32 +#: inc/options/general.php:319 #: Root_AdminMenu.php:73 #: Root_AdminMenu.php:74 -#: SetupGuide_Plugin_Admin.php:1052 -#: SetupGuide_Plugin_Admin.php:1158 -#: SetupGuide_Plugin_Admin.php:1169 +#: SetupGuide_Plugin_Admin.php:1128 +#: SetupGuide_Plugin_Admin.php:1238 +#: SetupGuide_Plugin_Admin.php:1249 #: UsageStatistics_Page_View.php:316 +#: Util_PageUrls.php:903 +#: Util_Ui.php:1552 msgid "Database Cache" msgstr "" @@ -3159,7 +3170,7 @@ msgid "Maximum lifetime of cache objects:" msgstr "" #: DbCache_ConfigLabels.php:12 -#: Extension_FragmentCache_Page_View.php:106 +#: Extension_FragmentCache_Page_View.php:80 #: Minify_ConfigLabels.php:32 #: ObjectCache_ConfigLabels.php:11 #: PgCache_ConfigLabels.php:44 @@ -3190,11 +3201,11 @@ msgid "Remove it for me" msgstr "" #. translators: 1 interval in seconds. -#: DbCache_Plugin.php:106 +#: DbCache_Plugin.php:107 msgid "[W3TC] Database Cache file GC (every %d seconds)" msgstr "" -#: DbCache_Plugin.php:191 +#: DbCache_Plugin.php:192 #: UsageStatistics_Page_View.php:311 msgid "Database" msgstr "" @@ -3274,58 +3285,35 @@ msgid "Total query time: " msgstr "" #: extension-example/Extension_Example_Page_View.php:9 -#: Extension_CloudFlare_Page_View.php:9 -#: Extension_FragmentCache_Page_View.php:12 -#: Extension_Genesis_Page_View.php:9 -#: Extension_NewRelic_Page_View_Apm.php:10 -#: Extension_Swarmify_Page_View.php:9 -#: inc/options/cdn.php:21 -#: inc/options/common/header.php:186 -#: inc/options/common/header.php:367 -msgid "Jump to:" -msgstr "" - -#: extension-example/Extension_Example_Page_View.php:10 -#: Extension_CloudFlare_Page_View.php:10 -#: Extension_FragmentCache_Page_View.php:13 -#: Extension_Genesis_Page_View.php:10 -#: Extension_NewRelic_Page_View_Apm.php:11 -#: Extension_Swarmify_Page_View.php:10 -#: inc/options/cdn.php:22 -#: inc/options/common/header.php:187 -#: inc/options/common/header.php:202 -#: inc/options/common/header.php:277 -#: inc/options/common/header.php:288 -#: inc/options/common/header.php:298 -#: inc/options/common/header.php:356 msgid "Main Menu" msgstr "" -#: extension-example/Extension_Example_Page_View.php:11 +#: extension-example/Extension_Example_Page_View.php:10 #: Extensions_Plugin_Admin.php:75 #: Extensions_Plugin_Admin.php:76 -#: Extension_CloudFlare_Page_View.php:11 -#: Extension_FragmentCache_Page_View.php:14 -#: Extension_Genesis_Page_View.php:11 -#: Extension_NewRelic_Page_View_Apm.php:12 -#: Extension_Swarmify_Page_View.php:11 #: FeatureShowcase_Plugin_Admin.php:468 +#: inc/options/common/top_nav_bar.php:62 +#: Util_PageUrls.php:950 +#: Util_PageUrls.php:957 +#: Util_PageUrls.php:970 +#: Util_PageUrls.php:975 +#: Util_PageUrls.php:980 msgid "Extensions" msgstr "" -#: extension-example/Extension_Example_Page_View.php:13 +#: extension-example/Extension_Example_Page_View.php:12 msgid "Example extension is currently " msgstr "" -#: extension-example/Extension_Example_Page_View.php:27 +#: extension-example/Extension_Example_Page_View.php:26 msgid "Add postfix to page titles" msgstr "" -#: extension-example/Extension_Example_Page_View.php:29 +#: extension-example/Extension_Example_Page_View.php:28 msgid "Check if you want to add postfix to each post title." msgstr "" -#: extension-example/Extension_Example_Page_View.php:36 +#: extension-example/Extension_Example_Page_View.php:35 msgid "Postfix to page titles" msgstr "" @@ -3333,22 +3321,25 @@ msgstr "" msgid "Extension %s has been successfully activated." msgstr "" -#: Extension_Amp_Page_View.php:10 -#: Extension_ImageService_Page_View.php:51 -#: Extension_Swarmify_Page_View.php:27 -#: inc/options/cdn.php:24 +#: Extension_Amp_Page_View.php:11 +#: Extension_ImageService_Page_View.php:45 +#: Extension_Swarmify_Page_View.php:22 +#: Util_Ui.php:1805 +#: Util_Ui.php:1877 +#: Util_Ui.php:1899 +#: Util_Ui.php:1907 msgid "Configuration" msgstr "" -#: Extension_Amp_Page_View.php:16 +#: Extension_Amp_Page_View.php:17 msgid "AMP URL Type:" msgstr "" -#: Extension_Amp_Page_View.php:22 +#: Extension_Amp_Page_View.php:23 msgid "If AMP page URLs are tag based (/my-page/amp/) or query string based (/my-page?amp)" msgstr "" -#: Extension_Amp_Page_View.php:31 +#: Extension_Amp_Page_View.php:32 msgid "AMP URL Postfix:" msgstr "" @@ -3372,38 +3363,44 @@ msgstr "" msgid "Failed to update CloudFlare settings:" msgstr "" -#: Extension_CloudFlare_Cdn_Page_View.php:15 +#: Extension_CloudFlare_Cdn_Page_View.php:13 msgid "Configuration:" msgstr "" -#: Extension_CloudFlare_GeneralPage_View.php:8 +#: Extension_CloudFlare_GeneralPage_View.php:9 msgid "Network Performance & Security powered by CloudFlare" msgstr "" -#: Extension_CloudFlare_GeneralPage_View.php:11 -msgid "CloudFlare protects and accelerates websites." -msgstr "" - -#: Extension_CloudFlare_GeneralPage_View.php:19 -#: Extension_CloudFlare_Page_View.php:126 -#: Extension_NewRelic_Page_View_Apm.php:180 -msgid "Cache time:" -msgstr "" - -#: Extension_CloudFlare_GeneralPage_View.php:21 -msgid "How many minutes data retrieved from CloudFlare should be stored. Minimum is 1 minute." -msgstr "" - -#: Extension_CloudFlare_GeneralPage_View.php:28 -msgid "Page Caching:" -msgstr "" - -#: Extension_CloudFlare_GeneralPage_View.php:30 -msgid "Flush CloudFlare on Post Modifications" +#: Extension_CloudFlare_GeneralPage_View.php:10 +msgid "" +"CloudFlare is a powerful content delivery network (CDN) and security service that can greatly enhance \n" +"\t\t\tthe performance and security of your WordPress website. By integrating CloudFlare with W3 Total Cache, \n" +"\t\t\tyou can take advantage of its global network of servers to deliver your website's content faster to \n" +"\t\t\tvisitors from around the world, resulting in reduced loading times and improved user experience. \n" +"\t\t\tAdditionally, CloudFlare offers various optimization features like minification, caching, and image \n" +"\t\t\toptimization, further accelerating your website's loading speed and overall performance." msgstr "" #: Extension_CloudFlare_GeneralPage_View.php:31 -#: Extension_CloudFlare_Page_View.php:138 +#: Extension_CloudFlare_Page_View.php:119 +#: Extension_NewRelic_Page_View_Apm.php:173 +msgid "Cache time:" +msgstr "" + +#: Extension_CloudFlare_GeneralPage_View.php:33 +msgid "How many minutes data retrieved from CloudFlare should be stored. Minimum is 1 minute." +msgstr "" + +#: Extension_CloudFlare_GeneralPage_View.php:40 +msgid "Page Caching:" +msgstr "" + +#: Extension_CloudFlare_GeneralPage_View.php:42 +msgid "Flush CloudFlare on Post Modifications" +msgstr "" + +#: Extension_CloudFlare_GeneralPage_View.php:43 +#: Extension_CloudFlare_Page_View.php:131 msgid "Enable when you have html pages cached on CloudFlare level." msgstr "" @@ -3411,197 +3408,192 @@ msgstr "" msgid "Save CloudFlare settings" msgstr "" -#: Extension_CloudFlare_Page_View.php:12 -#: Extension_CloudFlare_Page_View.php:49 -msgid "Credentials" -msgstr "" - -#: Extension_CloudFlare_Page_View.php:13 -#: Extension_CloudFlare_Page_View.php:87 -#: inc/options/browsercache.php:79 -#: inc/options/cdn.php:23 -#: inc/options/cdn.php:125 -#: inc/options/common/header.php:53 -#: inc/options/common/header.php:188 -#: inc/options/common/header.php:203 -#: inc/options/common/header.php:278 -#: inc/options/common/header.php:299 -#: inc/options/dbcache.php:52 -#: inc/options/general.php:38 -#: inc/options/minify.php:94 -#: inc/options/pgcache.php:59 -msgid "General" -msgstr "" - -#: Extension_CloudFlare_Page_View.php:14 -msgid "Information" -msgstr "" - -#: Extension_CloudFlare_Page_View.php:17 +#: Extension_CloudFlare_Page_View.php:9 msgid "CloudFlare extension is currently " msgstr "" -#: Extension_CloudFlare_Page_View.php:42 +#: Extension_CloudFlare_Page_View.php:34 msgid "Purge CloudFlare cache" msgstr "" -#: Extension_CloudFlare_Page_View.php:43 -#: Extension_FragmentCache_Page_View.php:59 +#: Extension_CloudFlare_Page_View.php:35 msgid "if needed." msgstr "" -#: Extension_CloudFlare_Page_View.php:77 +#: Extension_CloudFlare_Page_View.php:42 +#: Util_Ui.php:1890 +msgid "Credentials" +msgstr "" + +#: Extension_CloudFlare_Page_View.php:70 #: Extension_CloudFlare_Popup_View_Zones.php:35 msgid "Zone:" msgstr "" -#: Extension_CloudFlare_Page_View.php:92 +#: Extension_CloudFlare_Page_View.php:80 +#: inc/options/browsercache.php:80 +#: inc/options/cdn.php:125 +#: inc/options/dbcache.php:34 +#: inc/options/general.php:22 +#: inc/options/minify.php:73 +#: inc/options/pgcache.php:35 +#: Util_Ui.php:1536 +#: Util_Ui.php:1634 +#: Util_Ui.php:1648 +#: Util_Ui.php:1721 +#: Util_Ui.php:1738 +#: Util_Ui.php:1804 +#: Util_Ui.php:1891 +msgid "General" +msgstr "" + +#: Extension_CloudFlare_Page_View.php:85 msgid "Authenticate your account in order to access settings." msgstr "" -#: Extension_CloudFlare_Page_View.php:100 +#: Extension_CloudFlare_Page_View.php:93 msgid "CloudFlare not available: " msgstr "" -#: Extension_CloudFlare_Page_View.php:110 +#: Extension_CloudFlare_Page_View.php:103 msgid "Widget statistics interval:" msgstr "" -#: Extension_CloudFlare_Page_View.php:113 +#: Extension_CloudFlare_Page_View.php:106 msgid "Last 30 minutes" msgstr "" -#: Extension_CloudFlare_Page_View.php:114 +#: Extension_CloudFlare_Page_View.php:107 msgid "Last 6 hours" msgstr "" -#: Extension_CloudFlare_Page_View.php:115 +#: Extension_CloudFlare_Page_View.php:108 msgid "Last 12 hours" msgstr "" -#: Extension_CloudFlare_Page_View.php:116 +#: Extension_CloudFlare_Page_View.php:109 msgid "Last 24 hours" msgstr "" -#: Extension_CloudFlare_Page_View.php:117 +#: Extension_CloudFlare_Page_View.php:110 msgid "Last week" msgstr "" -#: Extension_CloudFlare_Page_View.php:118 +#: Extension_CloudFlare_Page_View.php:111 msgid "Last month" msgstr "" -#: Extension_CloudFlare_Page_View.php:128 +#: Extension_CloudFlare_Page_View.php:121 msgid "How many minutes data retrieved from CloudFlare: should be stored. Minimum is 1 minute." msgstr "" -#: Extension_CloudFlare_Page_View.php:135 +#: Extension_CloudFlare_Page_View.php:128 msgid "Page caching:" msgstr "" -#: Extension_CloudFlare_Page_View.php:137 +#: Extension_CloudFlare_Page_View.php:130 msgid "Flush CloudFlare on Post Modifications:" msgstr "" -#: Extension_CloudFlare_Page_View.php:145 +#: Extension_CloudFlare_Page_View.php:138 msgid "Minified JS Rocket Loader Exclude:" msgstr "" -#: Extension_CloudFlare_Page_View.php:146 +#: Extension_CloudFlare_Page_View.php:139 msgid "Exclude minified JS files from being processed by Rocket Loader:" msgstr "" -#: Extension_CloudFlare_Page_View.php:148 +#: Extension_CloudFlare_Page_View.php:141 msgid "Exclusion achieved by adding data-cfasync=\"false\" to script tags." msgstr "" -#: Extension_CloudFlare_Page_View.php:160 +#: Extension_CloudFlare_Page_View.php:152 msgid "CloudFlare: Caching" msgstr "" -#: Extension_CloudFlare_Page_View.php:167 +#: Extension_CloudFlare_Page_View.php:159 msgid "Development mode:" msgstr "" -#: Extension_CloudFlare_Page_View.php:168 +#: Extension_CloudFlare_Page_View.php:160 msgid "Development Mode temporarily allows you to enter development mode for your websites if you need to make changes to your site. This will bypass CloudFlare's accelerated cache and slow down your site, but is useful if you are making changes to cacheable content (like images, css, or JavaScript) and would like to see those changes right away." msgstr "" -#: Extension_CloudFlare_Page_View.php:175 +#: Extension_CloudFlare_Page_View.php:167 msgid "Cache level:" msgstr "" -#: Extension_CloudFlare_Page_View.php:178 +#: Extension_CloudFlare_Page_View.php:170 msgid "Aggressive (cache all static resources, including ones with a query string)" msgstr "" -#: Extension_CloudFlare_Page_View.php:179 +#: Extension_CloudFlare_Page_View.php:171 msgid "Basic (cache most static resources (i.e., css, images, and JavaScript)" msgstr "" -#: Extension_CloudFlare_Page_View.php:180 +#: Extension_CloudFlare_Page_View.php:172 msgid "Simplified (ignore the query string when delivering a cached resource)" msgstr "" -#: Extension_CloudFlare_Page_View.php:182 +#: Extension_CloudFlare_Page_View.php:174 msgid "How the content is cached by CloudFlare" msgstr "" -#: Extension_CloudFlare_Page_View.php:189 +#: Extension_CloudFlare_Page_View.php:181 msgid "Query string sorting:" msgstr "" -#: Extension_CloudFlare_Page_View.php:190 +#: Extension_CloudFlare_Page_View.php:182 msgid "CloudFlare will treat files with the same query strings as the same file in cache, regardless of the order of the query strings." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:200 +#: Extension_CloudFlare_Page_View.php:192 msgid "Browser cache %1$sTTL%2$s:" msgstr "" -#: Extension_CloudFlare_Page_View.php:204 -#: Extension_CloudFlare_Page_View.php:249 -#: Extension_CloudFlare_Page_View.php:271 -#: Extension_CloudFlare_Page_View.php:304 +#: Extension_CloudFlare_Page_View.php:196 +#: Extension_CloudFlare_Page_View.php:241 +#: Extension_CloudFlare_Page_View.php:263 +#: Extension_CloudFlare_Page_View.php:296 msgid "Time-to-Live" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:245 +#: Extension_CloudFlare_Page_View.php:237 msgid "Browser cache %1$sTTL%2$s (in seconds) specifies how long CloudFlare-cached resources will remain on your visitors' computers." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:267 +#: Extension_CloudFlare_Page_View.php:259 msgid "Challenge %1$sTTL%2$s:" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:300 +#: Extension_CloudFlare_Page_View.php:292 msgid "Specify how long a visitor is allowed access to your site after successfully completing a challenge (such as a CAPTCHA). After the %1$sTTL%2$s has expired the visitor will have to complete a new challenge." msgstr "" -#: Extension_CloudFlare_Page_View.php:319 +#: Extension_CloudFlare_Page_View.php:311 msgid "Edge cache TTL:" msgstr "" -#: Extension_CloudFlare_Page_View.php:337 +#: Extension_CloudFlare_Page_View.php:329 msgid "Controls how long CloudFlare's edge servers will cache a resource before getting back to your server for a fresh copy." msgstr "" -#: Extension_CloudFlare_Page_View.php:346 +#: Extension_CloudFlare_Page_View.php:338 msgid "CloudFlare: Content Processing" msgstr "" -#: Extension_CloudFlare_Page_View.php:352 +#: Extension_CloudFlare_Page_View.php:344 msgid "Rocket Loader:" msgstr "" -#: Extension_CloudFlare_Page_View.php:355 -#: Extension_CloudFlare_Page_View.php:523 -#: Extension_CloudFlare_Page_View.php:543 -#: Extension_CloudFlare_Page_View.php:733 +#: Extension_CloudFlare_Page_View.php:347 +#: Extension_CloudFlare_Page_View.php:515 +#: Extension_CloudFlare_Page_View.php:535 +#: Extension_CloudFlare_Page_View.php:725 #: inc/lightbox/self_test.php:276 #: inc/lightbox/self_test.php:285 #: inc/lightbox/self_test.php:483 @@ -3609,292 +3601,293 @@ msgstr "" msgid "Off" msgstr "" -#: Extension_CloudFlare_Page_View.php:356 +#: Extension_CloudFlare_Page_View.php:348 msgid "On (automatically run on the JavaScript resources on your site)" msgstr "" -#: Extension_CloudFlare_Page_View.php:357 +#: Extension_CloudFlare_Page_View.php:349 msgid "Manual (run when attribute present only)" msgstr "" -#: Extension_CloudFlare_Page_View.php:359 +#: Extension_CloudFlare_Page_View.php:351 msgid "Rocket Loader is a general-purpose asynchronous JavaScript loader coupled with a lightweight virtual browser which can safely run any JavaScript code after window.onload." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:369 +#: Extension_CloudFlare_Page_View.php:361 msgid "Minify %1$sJS%2$s:" msgstr "" -#: Extension_CloudFlare_Page_View.php:382 +#: Extension_CloudFlare_Page_View.php:374 msgid "Minify JavaScript files." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:392 +#: Extension_CloudFlare_Page_View.php:384 msgid "Minify %1$sCSS%2$s:" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:415 +#: Extension_CloudFlare_Page_View.php:407 msgid "Minify %1$sHTML%2$s:" msgstr "" -#: Extension_CloudFlare_Page_View.php:419 -#: Extension_CloudFlare_Page_View.php:435 +#: Extension_CloudFlare_Page_View.php:411 +#: Extension_CloudFlare_Page_View.php:427 msgid "HyperText Markup Language" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:431 +#: Extension_CloudFlare_Page_View.php:423 msgid "Minify %1$sHTML%2$s content." msgstr "" -#: Extension_CloudFlare_Page_View.php:450 +#: Extension_CloudFlare_Page_View.php:442 msgid "Server side exclude:" msgstr "" -#: Extension_CloudFlare_Page_View.php:451 +#: Extension_CloudFlare_Page_View.php:443 msgid "If there is sensitive content on your website that you want visible to real visitors, but that you want to hide from suspicious visitors, all you have to do is wrap the content with CloudFlare SSE tags." msgstr "" -#: Extension_CloudFlare_Page_View.php:458 +#: Extension_CloudFlare_Page_View.php:450 msgid "Email obfuscation:" msgstr "" -#: Extension_CloudFlare_Page_View.php:459 +#: Extension_CloudFlare_Page_View.php:451 msgid "Encrypt email adresses on your web page from bots, while keeping them visible to humans. " msgstr "" -#: Extension_CloudFlare_Page_View.php:466 +#: Extension_CloudFlare_Page_View.php:458 msgid "Response buffering\"" msgstr "" -#: Extension_CloudFlare_Page_View.php:467 +#: Extension_CloudFlare_Page_View.php:459 msgid "CloudFlare may buffer the whole payload to deliver it at once to the client versus allowing it to be delivered in chunks." msgstr "" -#: Extension_CloudFlare_Page_View.php:474 +#: Extension_CloudFlare_Page_View.php:466 msgid "Prefetch preload:" msgstr "" -#: Extension_CloudFlare_Page_View.php:475 +#: Extension_CloudFlare_Page_View.php:467 msgid "CloudFlare will prefetch any URLs that are included in the response headers." msgstr "" -#: Extension_CloudFlare_Page_View.php:482 +#: Extension_CloudFlare_Page_View.php:474 msgid "Mobile redirect:" msgstr "" -#: Extension_CloudFlare_Page_View.php:483 +#: Extension_CloudFlare_Page_View.php:475 msgid "Automatically redirect visitors on mobile devices to a mobile-optimized subdomain" msgstr "" -#: Extension_CloudFlare_Page_View.php:490 +#: Extension_CloudFlare_Page_View.php:482 msgid "Enable error pages:" msgstr "" -#: Extension_CloudFlare_Page_View.php:491 +#: Extension_CloudFlare_Page_View.php:483 msgid "CloudFlare will proxy customer error pages on any 502,504 errors on origin server instead of showing a default CloudFlare error page. This does not apply to 522 errors and is limited to Enterprise Zones." msgstr "" -#: Extension_CloudFlare_Page_View.php:498 +#: Extension_CloudFlare_Page_View.php:490 msgid "CloudFlare: Image Processing" msgstr "" -#: Extension_CloudFlare_Page_View.php:504 +#: Extension_CloudFlare_Page_View.php:496 msgid "Hotlink protection:" msgstr "" -#: Extension_CloudFlare_Page_View.php:505 +#: Extension_CloudFlare_Page_View.php:497 msgid "When enabled, the Hotlink Protection option ensures that other sites cannot suck up your bandwidth by building pages that use images hosted on your site." msgstr "" -#: Extension_CloudFlare_Page_View.php:512 +#: Extension_CloudFlare_Page_View.php:504 msgid "Mirage:" msgstr "" -#: Extension_CloudFlare_Page_View.php:513 +#: Extension_CloudFlare_Page_View.php:505 msgid "Automatically optimize image loading for website visitors on mobile devices" msgstr "" -#: Extension_CloudFlare_Page_View.php:520 +#: Extension_CloudFlare_Page_View.php:512 msgid "Images polishing:" msgstr "" -#: Extension_CloudFlare_Page_View.php:524 +#: Extension_CloudFlare_Page_View.php:516 msgid "Lossless (Reduce the size of PNG, JPEG, and GIF files - no impact on visual quality)" msgstr "" -#: Extension_CloudFlare_Page_View.php:525 +#: Extension_CloudFlare_Page_View.php:517 msgid "Lossy (Further reduce the size of JPEG files for faster image loading)" msgstr "" -#: Extension_CloudFlare_Page_View.php:527 +#: Extension_CloudFlare_Page_View.php:519 msgid "Strips metadata and compresses your images for faster page load times." msgstr "" -#: Extension_CloudFlare_Page_View.php:534 +#: Extension_CloudFlare_Page_View.php:526 msgid "CloudFlare: Protection" msgstr "" -#: Extension_CloudFlare_Page_View.php:540 +#: Extension_CloudFlare_Page_View.php:532 msgid "Security level:" msgstr "" -#: Extension_CloudFlare_Page_View.php:544 +#: Extension_CloudFlare_Page_View.php:536 msgid "Low" msgstr "" -#: Extension_CloudFlare_Page_View.php:545 +#: Extension_CloudFlare_Page_View.php:537 msgid "Medium" msgstr "" -#: Extension_CloudFlare_Page_View.php:546 +#: Extension_CloudFlare_Page_View.php:538 msgid "High" msgstr "" -#: Extension_CloudFlare_Page_View.php:547 +#: Extension_CloudFlare_Page_View.php:539 msgid "Under Attack" msgstr "" -#: Extension_CloudFlare_Page_View.php:549 +#: Extension_CloudFlare_Page_View.php:541 msgid "security profile for your website, which will automatically adjust each of the security settings." msgstr "" -#: Extension_CloudFlare_Page_View.php:556 +#: Extension_CloudFlare_Page_View.php:548 msgid "Browser integrity check:" msgstr "" -#: Extension_CloudFlare_Page_View.php:557 +#: Extension_CloudFlare_Page_View.php:549 msgid "Browser Integrity Check is similar to Bad Behavior and looks for common HTTP headers abused most commonly by spammers and denies access to your page. It will also challenge visitors that do not have a user agent or a non standard user agent (also commonly used by abuse bots, crawlers or visitors)." msgstr "" -#: Extension_CloudFlare_Page_View.php:564 +#: Extension_CloudFlare_Page_View.php:556 msgid "Always online:" msgstr "" -#: Extension_CloudFlare_Page_View.php:565 +#: Extension_CloudFlare_Page_View.php:557 msgid "When enabled, Always Online will serve pages from our cache if your server is offline" msgstr "" -#: Extension_CloudFlare_Page_View.php:572 +#: Extension_CloudFlare_Page_View.php:564 msgid "Web application firewall:" msgstr "" -#: Extension_CloudFlare_Page_View.php:573 +#: Extension_CloudFlare_Page_View.php:565 msgid "The Web Application Firewall (WAF) examines HTTP requests to your website. It inspects both GET and POST requests and applies rules to help filter out illegitimate traffic from legitimate website visitors." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:583 +#: Extension_CloudFlare_Page_View.php:575 msgid "Advanced %1$sDDoS%2$s protection:" msgstr "" -#: Extension_CloudFlare_Page_View.php:587 +#: Extension_CloudFlare_Page_View.php:579 msgid "Distributed Denial of Service" msgstr "" -#: Extension_CloudFlare_Page_View.php:596 +#: Extension_CloudFlare_Page_View.php:588 msgid "Advanced protection from Distributed Denial of Service (DDoS) attacks on your website." msgstr "" -#: Extension_CloudFlare_Page_View.php:603 +#: Extension_CloudFlare_Page_View.php:595 msgid "Max upload:" msgstr "" -#: Extension_CloudFlare_Page_View.php:604 +#: Extension_CloudFlare_Page_View.php:596 msgid "Max size of file allowed for uploading" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:615 +#: Extension_CloudFlare_Page_View.php:607 msgid "CloudFlare: %1$sIP%2$s" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:639 +#: Extension_CloudFlare_Page_View.php:631 msgid "%1$sIP%2$s geolocation:" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:655 +#: Extension_CloudFlare_Page_View.php:647 msgid "Enable %1$sIP%2$s Geolocation to have CloudFlare geolocate visitors to your website and pass the country code to you." msgstr "" -#: Extension_CloudFlare_Page_View.php:674 +#: Extension_CloudFlare_Page_View.php:666 msgid "IPv6:" msgstr "" -#: Extension_CloudFlare_Page_View.php:675 +#: Extension_CloudFlare_Page_View.php:667 msgid "Enable IPv6." msgstr "" -#: Extension_CloudFlare_Page_View.php:682 +#: Extension_CloudFlare_Page_View.php:674 msgid "True client IP:" msgstr "" -#: Extension_CloudFlare_Page_View.php:683 +#: Extension_CloudFlare_Page_View.php:675 msgid "Allows customer to continue to use True Client IP (Akamai feature) in the headers we send to the origin." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:694 +#: Extension_CloudFlare_Page_View.php:686 msgid "CloudFlare: %1$sSSL%2$s" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:718 +#: Extension_CloudFlare_Page_View.php:710 msgid "%1$sSSL%2$s:" msgstr "" -#: Extension_CloudFlare_Page_View.php:722 +#: Extension_CloudFlare_Page_View.php:714 msgid "Secure Sockets Layer\">" msgstr "" -#: Extension_CloudFlare_Page_View.php:734 +#: Extension_CloudFlare_Page_View.php:726 msgid "Flexible (HTTPS to end-user only)" msgstr "" -#: Extension_CloudFlare_Page_View.php:735 +#: Extension_CloudFlare_Page_View.php:727 msgid "Full (https everywhere)" msgstr "" -#: Extension_CloudFlare_Page_View.php:736 +#: Extension_CloudFlare_Page_View.php:728 msgid "Strict" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:741 +#: Extension_CloudFlare_Page_View.php:733 msgid "%1$sSSL%2$s encrypts your visitor's connection and safeguards credit card numbers and other personal data to and from your website." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:763 +#: Extension_CloudFlare_Page_View.php:755 msgid "Security header (%1$sSSL%2$s):" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:779 +#: Extension_CloudFlare_Page_View.php:771 msgid "Enables or disables %1$sSSL%2$s header." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:801 +#: Extension_CloudFlare_Page_View.php:793 msgid "%1$sTLS%2$s 1.2 only:" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:817 +#: Extension_CloudFlare_Page_View.php:809 msgid "Enable Crypto %1$sTLS%2$s 1.2 feature for this zone and prevent use of previous versions." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_CloudFlare_Page_View.php:840 +#: Extension_CloudFlare_Page_View.php:832 msgid "%1$sTLS%2$s Client authentication requires CloudFlare to connect to your origin server using a client certificate" msgstr "" #: Extension_CloudFlare_Plugin.php:151 +#: Extension_CloudFlare_Plugin_Admin.php:162 msgid "CloudFlare" msgstr "" @@ -3920,17 +3913,8 @@ msgstr "" msgid "%1$sCloudFlare plugin detected. We recommend removing the plugin as it offers no additional capabilities when W3 Total Cache is installed. This message will disappear when CloudFlare is removed. %2$s%3$s" msgstr "" -#: Extension_CloudFlare_Plugin_Admin.php:162 -msgid "CloudFlare: All" -msgstr "" - -#: Extension_CloudFlare_Plugin_Admin.php:297 -#: PageSpeed_Instructions.php:427 -msgid " or " -msgstr "" - -#: Extension_CloudFlare_Plugin_Admin.php:298 -msgid "empty all caches except CloudFlare" +#: Extension_CloudFlare_Plugin_Admin.php:299 +msgid "Empty All Caches Except CloudFlare" msgstr "" #: Extension_CloudFlare_Popup_View_Intro.php:16 @@ -3954,336 +3938,372 @@ msgstr "" msgid "You have not configured well email, API token / global key or domain" msgstr "" -#: Extension_FragmentCache_GeneralPage_View.php:10 -msgid "Enable fragment caching reduce execution time for common operations." -msgstr "" - -#: Extension_FragmentCache_GeneralPage_View.php:17 -msgid "Fragment Cache Method:" -msgstr "" - -#: Extension_FragmentCache_Page_View.php:15 -#: Extension_FragmentCache_Page_View.php:65 -#: Extension_NewRelic_Widget_View_Apm.php:14 -msgid "Overview" -msgstr "" - -#: Extension_FragmentCache_Page_View.php:16 -#: Extension_FragmentCache_Page_View.php:87 -#: inc/options/cdn.php:25 -#: inc/options/cdn.php:380 -#: inc/options/common/header.php:190 -#: inc/options/common/header.php:267 -#: inc/options/common/header.php:279 -#: inc/options/common/header.php:289 -#: inc/options/dbcache.php:65 -#: inc/options/minify.php:883 -#: inc/options/objectcache.php:53 -#: inc/options/pgcache.php:483 -msgid "Advanced" -msgstr "" - -#: Extension_FragmentCache_Page_View.php:21 -msgid "Fragment caching" -msgstr "" - -#: Extension_FragmentCache_Page_View.php:23 -msgid "via" -msgstr "" - -#: Extension_FragmentCache_Page_View.php:27 -msgid "is currently" -msgstr "" - -#: Extension_FragmentCache_Page_View.php:58 -msgid "Empty the entire cache" -msgstr "" - -#: Extension_FragmentCache_Page_View.php:68 -msgid "Registered fragment groups:" -msgstr "" - -#: Extension_FragmentCache_Page_View.php:78 -msgid "The groups above will be flushed upon setting changes." -msgstr "" - -#: Extension_FragmentCache_Page_View.php:80 -msgid "No groups have been registered." -msgstr "" - -#: Extension_FragmentCache_Page_View.php:99 -msgid "Default lifetime of cached fragments:" -msgstr "" - -#: Extension_FragmentCache_Page_View.php:101 -#: Extension_FragmentCache_Page_View.php:108 -#: inc/options/browsercache.php:398 -#: inc/options/browsercache.php:545 -#: inc/options/browsercache.php:627 -#: inc/options/cdn.php:637 -#: inc/options/cdn.php:646 -#: inc/options/dbcache.php:81 -#: inc/options/dbcache.php:89 -#: inc/options/minify.php:899 -#: inc/options/minify.php:914 -#: inc/options/objectcache.php:68 -#: inc/options/objectcache.php:76 -#: inc/options/pgcache.php:227 -#: inc/options/pgcache.php:564 -#: inc/options/pgcache.php:574 -#: inc/options/pgcache.php:581 -msgid "seconds" -msgstr "" - -#: Extension_FragmentCache_Page_View.php:102 -#: inc/options/dbcache.php:82 -#: inc/options/objectcache.php:69 -#: inc/options/pgcache.php:565 -msgid "Determines the natural expiration time of unchanged cache items. The higher the value, the larger the cache." -msgstr "" - -#: Extension_FragmentCache_Page_View.php:109 -#: inc/options/dbcache.php:90 -#: inc/options/minify.php:915 -#: inc/options/objectcache.php:77 -#: inc/options/pgcache.php:575 -msgid "If caching to disk, specify how frequently expired cache data is removed. For busy sites, a lower value is best." -msgstr "" - -#: Extension_FragmentCache_Page_View.php:113 -msgid "Manual fragment groups:" -msgstr "" - -#: Extension_FragmentCache_Page_View.php:118 -msgid "Specify fragment groups that should be managed by W3 Total Cache. Enter one action per line comma delimited, e.g. (group, action1, action2). Include the prefix used for a transient by a theme or plugin." -msgstr "" - -#: Extension_FragmentCache_Plugin_Admin.php:24 -msgid "Increase the performance of dynamic sites that cannot benefit from the caching of entire pages." -msgstr "" - -#: Extension_FragmentCache_Plugin_Admin.php:26 -msgid "Fragment caching extends the core functionality of WordPress by enabling caching policies to be set on groups of objects that are cached. This allows you to optimize various elements in themes and plugins to use caching to save resources and reduce response times. You can also use caching methods like Memcached or Redis (for example) to scale. Instructions for use are available in the FAQ available under the help menu. This feature also gives you control over the caching policies by the group as well as visibility into the configuration by extending the WordPress Object API with additional functionality." -msgstr "" - -#: Extension_FragmentCache_Plugin_Admin.php:27 -msgid "Fragment caching is a powerful, but advanced feature. If you need help, take a look at our premium support, customization and audit services." -msgstr "" - -#: Extension_FragmentCache_Plugin_Admin.php:101 -#: Extension_FragmentCache_Plugin_Admin.php:103 -#: Extension_FragmentCache_Plugin_Admin.php:161 -#: Extension_FragmentCache_Plugin_Admin.php:169 +#: Extension_FragmentCache_GeneralPage_View.php:11 +#: Extension_FragmentCache_Plugin_Admin.php:107 +#: Extension_FragmentCache_Plugin_Admin.php:108 +#: Extension_FragmentCache_Plugin_Admin.php:124 +#: Extension_FragmentCache_Plugin_Admin.php:159 +#: Extension_FragmentCache_Plugin_Admin.php:167 #: FeatureShowcase_Plugin_Admin.php:299 -#: inc/options/common/header.php:80 -#: inc/options/general.php:1031 +#: inc/options/common/footer.php:64 +#: inc/options/common/footer.php:65 +#: inc/options/common/top_nav_bar.php:52 +#: inc/options/general.php:900 +#: Util_PageUrls.php:928 msgid "Fragment Cache" msgstr "" -#: Extension_FragmentCache_Plugin_Admin.php:118 -msgid "Fragment Cache: All Fragments" +#: Extension_FragmentCache_GeneralPage_View.php:12 +msgid "" +"Fragment caching is a powerful feature that helps improve the speed and performance of your \n" +"\t\t\twebsite. It allows you to cache specific sections or fragments of your web pages instead \n" +"\t\t\tof caching the entire page. By selectively caching these fragments, such as sidebar widgets \n" +"\t\t\tor dynamic content, you can reduce the processing time required to generate the page, \n" +"\t\t\tresulting in faster load times and improved overall site performance." +msgstr "" + +#: Extension_FragmentCache_GeneralPage_View.php:31 +msgid "Fragment Cache Method:" +msgstr "" + +#: Extension_FragmentCache_Page_View.php:14 +msgid "Fragment caching" +msgstr "" + +#: Extension_FragmentCache_Page_View.php:16 +msgid "via" +msgstr "" + +#: Extension_FragmentCache_Page_View.php:20 +msgid "is currently" +msgstr "" + +#: Extension_FragmentCache_Page_View.php:39 +#: Extension_NewRelic_Widget_View_Apm.php:14 +#: Util_Ui.php:1858 +msgid "Overview" +msgstr "" + +#: Extension_FragmentCache_Page_View.php:42 +msgid "Registered fragment groups:" +msgstr "" + +#: Extension_FragmentCache_Page_View.php:52 +msgid "The groups above will be flushed upon setting changes." +msgstr "" + +#: Extension_FragmentCache_Page_View.php:54 +msgid "No groups have been registered." +msgstr "" + +#: Extension_FragmentCache_Page_View.php:61 +#: inc/options/cdn.php:378 +#: inc/options/dbcache.php:46 +#: inc/options/minify.php:858 +#: inc/options/objectcache.php:35 +#: inc/options/pgcache.php:456 +#: Util_Ui.php:1639 +#: Util_Ui.php:1712 +#: Util_Ui.php:1722 +#: Util_Ui.php:1730 +#: Util_Ui.php:1806 +#: Util_Ui.php:1859 +msgid "Advanced" +msgstr "" + +#: Extension_FragmentCache_Page_View.php:73 +msgid "Default lifetime of cached fragments:" +msgstr "" + +#: Extension_FragmentCache_Page_View.php:75 +#: Extension_FragmentCache_Page_View.php:82 +#: inc/options/browsercache.php:398 +#: inc/options/browsercache.php:544 +#: inc/options/browsercache.php:625 +#: inc/options/cdn.php:635 +#: inc/options/cdn.php:644 +#: inc/options/dbcache.php:62 +#: inc/options/dbcache.php:70 +#: inc/options/minify.php:874 +#: inc/options/minify.php:889 +#: inc/options/objectcache.php:50 +#: inc/options/objectcache.php:58 +#: inc/options/pgcache.php:202 +#: inc/options/pgcache.php:537 +#: inc/options/pgcache.php:547 +#: inc/options/pgcache.php:554 +msgid "seconds" +msgstr "" + +#: Extension_FragmentCache_Page_View.php:76 +#: inc/options/dbcache.php:63 +#: inc/options/objectcache.php:51 +#: inc/options/pgcache.php:538 +msgid "Determines the natural expiration time of unchanged cache items. The higher the value, the larger the cache." +msgstr "" + +#: Extension_FragmentCache_Page_View.php:83 +#: inc/options/dbcache.php:71 +#: inc/options/minify.php:890 +#: inc/options/objectcache.php:59 +#: inc/options/pgcache.php:548 +msgid "If caching to disk, specify how frequently expired cache data is removed. For busy sites, a lower value is best." +msgstr "" + +#: Extension_FragmentCache_Page_View.php:87 +msgid "Manual fragment groups:" +msgstr "" + +#: Extension_FragmentCache_Page_View.php:92 +msgid "Specify fragment groups that should be managed by W3 Total Cache. Enter one action per line comma delimited, e.g. (group, action1, action2). Include the prefix used for a transient by a theme or plugin." +msgstr "" + +#: Extension_FragmentCache_Plugin_Admin.php:17 +msgid "Valid W3 Total Cache Pro license" +msgstr "" + +#: Extension_FragmentCache_Plugin_Admin.php:28 +msgid "Increase the performance of dynamic sites that cannot benefit from the caching of entire pages." +msgstr "" + +#: Extension_FragmentCache_Plugin_Admin.php:30 +msgid "Fragment caching extends the core functionality of WordPress by enabling caching policies to be set on groups of objects that are cached. This allows you to optimize various elements in themes and plugins to use caching to save resources and reduce response times. You can also use caching methods like Memcached or Redis (for example) to scale. Instructions for use are available in the FAQ available under the help menu. This feature also gives you control over the caching policies by the group as well as visibility into the configuration by extending the WordPress Object API with additional functionality." +msgstr "" + +#: Extension_FragmentCache_Plugin_Admin.php:31 +msgid "Fragment caching is a powerful, but advanced feature. If you need help, take a look at our premium support, customization and audit services." +msgstr "" + +#: Extension_FragmentCache_Plugin_Admin.php:95 +#: Extension_ImageService_Plugin_Admin.php:132 +#: Extension_ImageService_Plugin_Admin.php:559 +#: Extension_ImageService_Plugin_Admin.php:735 +#: FeatureShowcase_Plugin_Admin.php:209 +#: FeatureShowcase_Plugin_Admin.php:256 +#: FeatureShowcase_Plugin_Admin.php:268 +#: FeatureShowcase_Plugin_Admin.php:280 +#: FeatureShowcase_Plugin_Admin.php:292 +#: FeatureShowcase_Plugin_Admin.php:304 +#: FeatureShowcase_Plugin_Admin.php:316 +#: FeatureShowcase_Plugin_Admin.php:328 +#: FeatureShowcase_Plugin_Admin.php:340 +#: FeatureShowcase_Plugin_Admin.php:377 +#: FeatureShowcase_Plugin_Admin.php:389 +#: FeatureShowcase_Plugin_Admin.php:401 +#: FeatureShowcase_Plugin_Admin.php:413 +#: FeatureShowcase_Plugin_Admin.php:425 +#: FeatureShowcase_Plugin_Admin.php:437 +#: FeatureShowcase_Plugin_Admin.php:449 +#: FeatureShowcase_Plugin_Admin.php:461 +#: FeatureShowcase_Plugin_Admin.php:473 +#: FeatureShowcase_Plugin_Admin.php:485 +#: Generic_Plugin_Admin.php:775 +#: inc/options/common/top_nav_bar.php:136 +#: inc/options/common/top_nav_bar.php:137 +#: inc/options/extensions/list.php:102 +msgid "Settings" msgstr "" #: Extension_FragmentCache_WpObjectCache.php:534 msgid "Fragment Caching %d/%d fragments using %s%s" msgstr "" -#: Extension_Genesis_Page_View.php:12 -#: Extension_Genesis_Page_View.php:30 -#: Extension_Genesis_Page_View.php:221 -msgid "Header" -msgstr "" - -#: Extension_Genesis_Page_View.php:13 -#: Extension_Genesis_Page_View.php:74 -msgid "Content" -msgstr "" - -#: Extension_Genesis_Page_View.php:14 -#: Extension_Genesis_Page_View.php:152 -#: Extension_Genesis_Page_View.php:223 -msgid "Sidebar" -msgstr "" - -#: Extension_Genesis_Page_View.php:15 -#: Extension_Genesis_Page_View.php:212 -msgid "Exclusions" -msgstr "" - -#: Extension_Genesis_Page_View.php:18 +#: Extension_Genesis_Page_View.php:9 msgid "Genesis extension is currently " msgstr "" -#: Extension_Genesis_Page_View.php:37 +#: Extension_Genesis_Page_View.php:21 +#: Extension_Genesis_Page_View.php:212 +#: Util_Ui.php:1916 +msgid "Header" +msgstr "" + +#: Extension_Genesis_Page_View.php:28 msgid "Cache wp_head loop:" msgstr "" -#: Extension_Genesis_Page_View.php:39 +#: Extension_Genesis_Page_View.php:30 msgid "Cache wp_head. This includes the embedded CSS, JS etc." msgstr "" -#: Extension_Genesis_Page_View.php:46 +#: Extension_Genesis_Page_View.php:37 msgid "Cache header:" msgstr "" -#: Extension_Genesis_Page_View.php:48 +#: Extension_Genesis_Page_View.php:39 msgid "Cache header loop. This is the area where the logo is located." msgstr "" -#: Extension_Genesis_Page_View.php:55 +#: Extension_Genesis_Page_View.php:46 msgid "Cache primary navigation:" msgstr "" -#: Extension_Genesis_Page_View.php:57 +#: Extension_Genesis_Page_View.php:48 msgid "Caches the navigation filter; per page." msgstr "" -#: Extension_Genesis_Page_View.php:64 +#: Extension_Genesis_Page_View.php:55 msgid "Cache secondary navigation:" msgstr "" -#: Extension_Genesis_Page_View.php:66 +#: Extension_Genesis_Page_View.php:57 msgid "Caches secondary navigation filter; per page." msgstr "" -#: Extension_Genesis_Page_View.php:82 +#: Extension_Genesis_Page_View.php:65 +#: Util_Ui.php:1917 +msgid "Content" +msgstr "" + +#: Extension_Genesis_Page_View.php:73 msgid "Cache front page post loop:" msgstr "" -#: Extension_Genesis_Page_View.php:83 +#: Extension_Genesis_Page_View.php:74 msgid "Caches the front page post loop, pagination is supported." msgstr "" -#: Extension_Genesis_Page_View.php:91 +#: Extension_Genesis_Page_View.php:82 msgid "Cache author/tag/categories/term post loop:" msgstr "" -#: Extension_Genesis_Page_View.php:92 +#: Extension_Genesis_Page_View.php:83 msgid "Caches the posts listed on tag, categories, author and other term pages, pagination is supported." msgstr "" -#: Extension_Genesis_Page_View.php:99 +#: Extension_Genesis_Page_View.php:90 msgid "Excluded terms pages / posts:" msgstr "" -#: Extension_Genesis_Page_View.php:100 +#: Extension_Genesis_Page_View.php:91 msgid "List of pages / posts that should not have the terms loop cached. Specify one page / post per line. This area supports regular expressions." msgstr "" -#: Extension_Genesis_Page_View.php:108 +#: Extension_Genesis_Page_View.php:99 msgid "Flush posts loop:" msgstr "" -#: Extension_Genesis_Page_View.php:109 +#: Extension_Genesis_Page_View.php:100 msgid "Flushes the posts loop cache on post updates. See setting above for affected loops." msgstr "" -#: Extension_Genesis_Page_View.php:117 +#: Extension_Genesis_Page_View.php:108 msgid "Cache single post / page:" msgstr "" -#: Extension_Genesis_Page_View.php:118 +#: Extension_Genesis_Page_View.php:109 msgid "Caches the single post / page loop, pagination is supported." msgstr "" -#: Extension_Genesis_Page_View.php:125 +#: Extension_Genesis_Page_View.php:116 msgid "Excluded single pages / posts:" msgstr "" -#: Extension_Genesis_Page_View.php:126 +#: Extension_Genesis_Page_View.php:117 msgid "List of pages / posts that should not have the single post / post loop cached. Specify one page / post per line. This area supports regular expressions." msgstr "" -#: Extension_Genesis_Page_View.php:134 +#: Extension_Genesis_Page_View.php:125 msgid "Cache comments:" msgstr "" -#: Extension_Genesis_Page_View.php:135 +#: Extension_Genesis_Page_View.php:126 msgid "Caches the comments loop, pagination is supported." msgstr "" -#: Extension_Genesis_Page_View.php:143 +#: Extension_Genesis_Page_View.php:134 msgid "Cache pings:" msgstr "" -#: Extension_Genesis_Page_View.php:144 +#: Extension_Genesis_Page_View.php:135 msgid "Caches the ping loop, pagination is supported. One per line." msgstr "" -#: Extension_Genesis_Page_View.php:160 +#: Extension_Genesis_Page_View.php:143 +#: Extension_Genesis_Page_View.php:214 +#: Util_Ui.php:1918 +msgid "Sidebar" +msgstr "" + +#: Extension_Genesis_Page_View.php:151 msgid "Cache sidebar:" msgstr "" -#: Extension_Genesis_Page_View.php:161 +#: Extension_Genesis_Page_View.php:152 msgid "Caches sidebar loop, the widget area." msgstr "" -#: Extension_Genesis_Page_View.php:168 +#: Extension_Genesis_Page_View.php:159 msgid "Exclude pages:" msgstr "" -#: Extension_Genesis_Page_View.php:169 +#: Extension_Genesis_Page_View.php:160 msgid "List of pages that should not have sidebar cached. Specify one page / post per line. This area supports regular expressions." msgstr "" -#: Extension_Genesis_Page_View.php:177 -#: Extension_Genesis_Page_View.php:222 +#: Extension_Genesis_Page_View.php:168 +#: Extension_Genesis_Page_View.php:213 msgid "Footer" msgstr "" -#: Extension_Genesis_Page_View.php:185 +#: Extension_Genesis_Page_View.php:176 msgid "Cache genesis footer:" msgstr "" -#: Extension_Genesis_Page_View.php:186 +#: Extension_Genesis_Page_View.php:177 msgid "Caches footer loop." msgstr "" -#: Extension_Genesis_Page_View.php:194 +#: Extension_Genesis_Page_View.php:185 msgid "Cache footer:" msgstr "" -#: Extension_Genesis_Page_View.php:195 +#: Extension_Genesis_Page_View.php:186 msgid "Caches wp_footer loop." msgstr "" -#: Extension_Genesis_Page_View.php:203 +#: Extension_Genesis_Page_View.php:194 msgid "Disable fragment cache:" msgstr "" -#: Extension_Genesis_Page_View.php:215 +#: Extension_Genesis_Page_View.php:203 +#: Util_Ui.php:1919 +msgid "Exclusions" +msgstr "" + +#: Extension_Genesis_Page_View.php:206 msgid "Select hooks" msgstr "" -#: Extension_Genesis_Page_View.php:224 +#: Extension_Genesis_Page_View.php:215 msgid "The Loop" msgstr "" -#: Extension_Genesis_Page_View.php:227 +#: Extension_Genesis_Page_View.php:218 msgid "Comments" msgstr "" -#: Extension_Genesis_Page_View.php:228 +#: Extension_Genesis_Page_View.php:219 msgid "Pings" msgstr "" -#: Extension_Genesis_Page_View.php:229 +#: Extension_Genesis_Page_View.php:220 msgid "Primary navigation" msgstr "" -#: Extension_Genesis_Page_View.php:230 +#: Extension_Genesis_Page_View.php:221 msgid "Secondary navigation" msgstr "" -#: Extension_Genesis_Page_View.php:247 +#: Extension_Genesis_Page_View.php:238 msgid "Select hooks from the list that should not be cached if user belongs to any of the roles selected below." msgstr "" -#: Extension_Genesis_Page_View.php:252 +#: Extension_Genesis_Page_View.php:243 msgid "Select roles:" msgstr "" -#: Extension_Genesis_Page_View.php:270 +#: Extension_Genesis_Page_View.php:261 msgid "Select user roles that should not use the fragment cache." msgstr "" @@ -4365,125 +4385,133 @@ msgstr "" msgid "Every Ten Seconds" msgstr "" -#: Extension_ImageService_Page_View.php:61 +#: Extension_ImageService_Page_View.php:55 msgid "Compression type:" msgstr "" -#: Extension_ImageService_Page_View.php:67 +#: Extension_ImageService_Page_View.php:61 msgid "Image compression type." msgstr "" -#: Extension_ImageService_Page_View.php:78 +#: Extension_ImageService_Page_View.php:72 msgid "Auto-convert:" msgstr "" -#: Extension_ImageService_Page_View.php:84 +#: Extension_ImageService_Page_View.php:78 msgid "Auto-convert images on upload." msgstr "" -#: Extension_ImageService_Page_View.php:95 +#: Extension_ImageService_Page_View.php:89 msgid "Visibility:" msgstr "" -#: Extension_ImageService_Page_View.php:98 +#: Extension_ImageService_Page_View.php:92 msgid "Never" msgstr "" -#: Extension_ImageService_Page_View.php:99 +#: Extension_ImageService_Page_View.php:93 msgid "If extension is active" msgstr "" -#: Extension_ImageService_Page_View.php:100 +#: Extension_ImageService_Page_View.php:94 msgid "Always" msgstr "" -#: Extension_ImageService_Page_View.php:102 +#: Extension_ImageService_Page_View.php:96 msgid "Show converted image attachments in the Media Library." msgstr "" -#: Extension_ImageService_Page_View.php:113 +#: Extension_ImageService_Page_View.php:106 +#: inc/options/common/top_nav_bar.php:158 +#: inc/options/common/top_nav_bar.php:159 +#: Util_Ui.php:1878 msgid "Tools" msgstr "" -#: Extension_ImageService_Page_View.php:121 +#: Extension_ImageService_Page_View.php:114 msgid "Convert all images:" msgstr "" -#: Extension_ImageService_Page_View.php:125 +#: Extension_ImageService_Page_View.php:118 msgid "Convert all images in the media library." msgstr "" -#: Extension_ImageService_Page_View.php:132 +#: Extension_ImageService_Page_View.php:125 msgid "Revert all images:" msgstr "" -#: Extension_ImageService_Page_View.php:136 +#: Extension_ImageService_Page_View.php:129 msgid "Revert all converted images in the media library." msgstr "" -#: Extension_ImageService_Page_View.php:147 +#: Extension_ImageService_Page_View.php:140 +#: inc/options/common/top_nav_bar.php:66 #: UsageStatistics_GeneralPage.php:25 +#: UsageStatistics_GeneralPage_View.php:18 #: UsageStatistics_Plugin_Admin.php:75 #: UsageStatistics_Plugin_Admin.php:76 +#: Util_PageUrls.php:953 +#: Util_Ui.php:1879 msgid "Statistics" msgstr "" -#: Extension_ImageService_Page_View.php:156 +#: Extension_ImageService_Page_View.php:149 msgid "Counts and filesizes by status:" msgstr "" -#: Extension_ImageService_Page_View.php:160 +#: Extension_ImageService_Page_View.php:153 msgid "Total:" msgstr "" -#: Extension_ImageService_Page_View.php:165 +#: Extension_ImageService_Page_View.php:158 msgid "Converted:" msgstr "" -#: Extension_ImageService_Page_View.php:170 +#: Extension_ImageService_Page_View.php:163 msgid "Sending:" msgstr "" -#: Extension_ImageService_Page_View.php:175 +#: Extension_ImageService_Page_View.php:168 msgid "Processing:" msgstr "" -#: Extension_ImageService_Page_View.php:180 +#: Extension_ImageService_Page_View.php:173 msgid "Not converted:" msgstr "" -#: Extension_ImageService_Page_View.php:185 +#: Extension_ImageService_Page_View.php:178 msgid "Unconverted:" msgstr "" -#: Extension_ImageService_Page_View.php:191 -#: Extension_ImageService_Page_View.php:218 -#: Extension_ImageService_Plugin_Admin.php:555 +#: Extension_ImageService_Page_View.php:184 +#: Extension_ImageService_Page_View.php:211 +#: Extension_ImageService_Plugin_Admin.php:557 #: UsageStatistics_Page_View.php:15 msgid "Refresh" msgstr "" -#: Extension_ImageService_Page_View.php:197 +#: Extension_ImageService_Page_View.php:190 msgid "Image Service API usage:" msgstr "" -#: Extension_ImageService_Page_View.php:201 +#: Extension_ImageService_Page_View.php:194 msgid "Hourly requests:" msgstr "" -#: Extension_ImageService_Page_View.php:205 +#: Extension_ImageService_Page_View.php:198 msgid "Hourly limit:" msgstr "" -#: Extension_ImageService_Page_View.php:209 +#: Extension_ImageService_Page_View.php:202 msgid "Monthly requests:" msgstr "" -#: Extension_ImageService_Page_View.php:213 +#: Extension_ImageService_Page_View.php:206 msgid "Monthly limit:" msgstr "" #: Extension_ImageService_Plugin_Admin.php:79 +#: SetupGuide_Plugin_Admin.php:1352 msgid "Adds the ability to convert images in the Media Library to the modern WebP format for better performance." msgstr "" @@ -4497,33 +4525,6 @@ msgstr "" msgid "Total Cache Image Service has been activated. Now, you can %1$sadjust the settings%2$s or go to the %3$sMedia Library%2$s to convert images to WebP. %4$sLearn more%2$s." msgstr "" -#: Extension_ImageService_Plugin_Admin.php:132 -#: Extension_ImageService_Plugin_Admin.php:557 -#: Extension_ImageService_Plugin_Admin.php:733 -#: FeatureShowcase_Plugin_Admin.php:209 -#: FeatureShowcase_Plugin_Admin.php:256 -#: FeatureShowcase_Plugin_Admin.php:268 -#: FeatureShowcase_Plugin_Admin.php:280 -#: FeatureShowcase_Plugin_Admin.php:292 -#: FeatureShowcase_Plugin_Admin.php:304 -#: FeatureShowcase_Plugin_Admin.php:316 -#: FeatureShowcase_Plugin_Admin.php:328 -#: FeatureShowcase_Plugin_Admin.php:340 -#: FeatureShowcase_Plugin_Admin.php:377 -#: FeatureShowcase_Plugin_Admin.php:389 -#: FeatureShowcase_Plugin_Admin.php:401 -#: FeatureShowcase_Plugin_Admin.php:413 -#: FeatureShowcase_Plugin_Admin.php:425 -#: FeatureShowcase_Plugin_Admin.php:437 -#: FeatureShowcase_Plugin_Admin.php:449 -#: FeatureShowcase_Plugin_Admin.php:461 -#: FeatureShowcase_Plugin_Admin.php:473 -#: FeatureShowcase_Plugin_Admin.php:485 -#: Generic_Plugin_Admin.php:752 -#: inc/options/extensions/list.php:102 -msgid "Settings" -msgstr "" - #: Extension_ImageService_Plugin_Admin.php:133 msgid "Media Library" msgstr "" @@ -4537,158 +4538,160 @@ msgstr "" msgid "Total Cache Image Service" msgstr "" -#: Extension_ImageService_Plugin_Admin.php:543 -#: Extension_ImageService_Plugin_Admin.php:735 -#: Extension_ImageService_Plugin_Admin.php:739 +#: Extension_ImageService_Plugin_Admin.php:545 +#: Extension_ImageService_Plugin_Admin.php:737 +#: Extension_ImageService_Plugin_Admin.php:741 msgid "Convert" msgstr "" -#: Extension_ImageService_Plugin_Admin.php:544 -#: Extension_ImageService_Plugin_Admin.php:723 +#: Extension_ImageService_Plugin_Admin.php:546 +#: Extension_ImageService_Plugin_Admin.php:725 msgid "Sending..." msgstr "" -#: Extension_ImageService_Plugin_Admin.php:545 +#: Extension_ImageService_Plugin_Admin.php:547 msgid "Submitted" msgstr "" -#: Extension_ImageService_Plugin_Admin.php:546 -#: Extension_ImageService_Plugin_Admin.php:726 +#: Extension_ImageService_Plugin_Admin.php:548 +#: Extension_ImageService_Plugin_Admin.php:728 msgid "Processing..." msgstr "" -#: Extension_ImageService_Plugin_Admin.php:547 -#: Extension_ImageService_Plugin_Admin.php:729 +#: Extension_ImageService_Plugin_Admin.php:549 +#: Extension_ImageService_Plugin_Admin.php:731 msgid "Converted" msgstr "" -#: Extension_ImageService_Plugin_Admin.php:548 +#: Extension_ImageService_Plugin_Admin.php:550 msgid "Not converted" msgstr "" -#: Extension_ImageService_Plugin_Admin.php:549 +#: Extension_ImageService_Plugin_Admin.php:551 msgid "Reverting..." msgstr "" -#: Extension_ImageService_Plugin_Admin.php:550 +#: Extension_ImageService_Plugin_Admin.php:552 msgid "Reverted" msgstr "" -#: Extension_ImageService_Plugin_Admin.php:551 -#: Extension_ImageService_Plugin_Admin.php:751 +#: Extension_ImageService_Plugin_Admin.php:553 +#: Extension_ImageService_Plugin_Admin.php:753 msgid "Revert" msgstr "" -#: Extension_ImageService_Plugin_Admin.php:552 +#: Extension_ImageService_Plugin_Admin.php:554 msgid "Error" msgstr "" -#: Extension_ImageService_Plugin_Admin.php:553 +#: Extension_ImageService_Plugin_Admin.php:555 msgid "Failed to retrieve a response. Please reload the page to try again." msgstr "" -#: Extension_ImageService_Plugin_Admin.php:554 +#: Extension_ImageService_Plugin_Admin.php:556 msgid "API error. Please reload the page to try again," msgstr "" -#: Extension_ImageService_Plugin_Admin.php:556 +#: Extension_ImageService_Plugin_Admin.php:558 msgid "Refreshing..." msgstr "" #. translators: 1: HTML anchor open tag, 2: HTML anchor close tag. -#: Extension_ImageService_Plugin_Admin.php:560 +#: Extension_ImageService_Plugin_Admin.php:562 msgid "Images queued for conversion. Progress can be seen in the %1$sMedia Library%2$s." msgstr "" #. translators: 1: HTML anchor open tag, 2: HTML anchor close tag. -#: Extension_ImageService_Plugin_Admin.php:566 -#: Extension_ImageService_Plugin_Admin.php:684 +#: Extension_ImageService_Plugin_Admin.php:568 +#: Extension_ImageService_Plugin_Admin.php:686 msgid "The converted image would be larger than the original; conversion canceled. %1$sLearn more%2$s." msgstr "" -#: Extension_ImageService_Plugin_Admin.php:608 +#: Extension_ImageService_Plugin_Admin.php:610 #: FeatureShowcase_Plugin_Admin.php:359 +#: Util_PageUrls.php:956 msgid "Image Service" msgstr "" -#: Extension_ImageService_Plugin_Admin.php:756 +#: Extension_ImageService_Plugin_Admin.php:758 msgid "Attachment id: " msgstr "" #. translators: 1: Submissions. -#: Extension_ImageService_Plugin_Admin.php:865 +#: Extension_ImageService_Plugin_Admin.php:867 msgid "Submitted %1$u image for processing." msgid_plural "Submitted %1$u images for processing." msgstr[0] "" msgstr[1] "" #. translators: 1: Successes, 2: Skipped, 3: Errored, 4: Invalid. -#: Extension_ImageService_Plugin_Admin.php:883 +#: Extension_ImageService_Plugin_Admin.php:885 msgid "Successful: %1$u | Skipped: %2$u | Errored: %3$u | Invalid: %4$u" msgstr "" -#: Extension_ImageService_Plugin_Admin.php:904 +#: Extension_ImageService_Plugin_Admin.php:906 msgid "All selected optimizations have been reverted." msgstr "" #. translators: 1: HTML anchor open tag, 2: HTML anchor close tag. -#: Extension_ImageService_Plugin_Admin.php:919 +#: Extension_ImageService_Plugin_Admin.php:921 msgid "Switch to %1$slist mode%2$s for WebP conversions." msgstr "" #. translators: 1: HTML achor open tag, 2: HTML anchor close tag. -#: Extension_ImageService_Plugin_Admin.php:948 -#: Extension_ImageService_Plugin_Admin.php:1154 +#: Extension_ImageService_Plugin_Admin.php:950 +#: Extension_ImageService_Plugin_Admin.php:1156 msgid "%1$sLearn more%2$s." msgstr "" -#: Extension_ImageService_Plugin_Admin.php:1169 -#: Extension_ImageService_Plugin_Admin.php:1255 -#: Extension_ImageService_Plugin_Admin.php:1291 +#: Extension_ImageService_Plugin_Admin.php:1171 +#: Extension_ImageService_Plugin_Admin.php:1257 +#: Extension_ImageService_Plugin_Admin.php:1293 msgid "Missing input post id." msgstr "" #. translators: 1: Image filepath. -#: Extension_ImageService_Plugin_Admin.php:1185 +#: Extension_ImageService_Plugin_Admin.php:1187 msgid "File \"%1$s\" does not exist." msgstr "" -#: Extension_ImageService_Plugin_Admin.php:1216 +#: Extension_ImageService_Plugin_Admin.php:1218 msgid "Invalid API response." msgstr "" -#: Extension_ImageService_Plugin_Admin.php:1283 +#: Extension_ImageService_Plugin_Admin.php:1285 msgid "Missing converted attachment id." msgstr "" #: Extension_NewRelic_AdminNotes.php:19 #: FeatureShowcase_Plugin_Admin.php:372 -#: inc/options/common/header.php:57 -#: inc/options/general.php:109 +#: inc/options/common/top_nav_bar.php:24 +#: inc/options/general.php:98 #: PageSpeed_Instructions.php:190 #: PageSpeed_Instructions.php:577 #: PgCache_ConfigLabels.php:9 #: PgCache_Plugin.php:298 #: PgCache_Plugin.php:306 #: PgCache_Plugin.php:314 +#: PgCache_Plugin.php:330 #: Root_AdminMenu.php:61 #: Root_AdminMenu.php:62 -#: SetupGuide_Plugin_Admin.php:1048 -#: SetupGuide_Plugin_Admin.php:1115 +#: SetupGuide_Plugin_Admin.php:1124 +#: SetupGuide_Plugin_Admin.php:1195 #: UsageStatistics_Page_View.php:28 +#: Util_PageUrls.php:893 +#: Util_Ui.php:1540 msgid "Page Cache" msgstr "" #: Extension_NewRelic_AdminNotes.php:21 #: FeatureShowcase_Plugin_Admin.php:384 -#: inc/options/common/header.php:61 -#: inc/options/general.php:196 -#: inc/options/minify.php:344 -#: inc/options/minify.php:363 -#: inc/options/minify.php:383 +#: inc/options/common/top_nav_bar.php:28 +#: inc/options/general.php:186 +#: inc/options/minify.php:321 +#: inc/options/minify.php:340 +#: inc/options/minify.php:360 #: Minify_ConfigLabels.php:9 -#: Minify_Plugin.php:310 -#: Minify_Plugin_Admin.php:49 #: PageSpeed_Instructions.php:67 #: PageSpeed_Instructions.php:84 #: PageSpeed_Instructions.php:275 @@ -4697,6 +4700,8 @@ msgstr "" #: Root_AdminMenu.php:67 #: Root_AdminMenu.php:68 #: UsageStatistics_Page_View.php:214 +#: Util_PageUrls.php:898 +#: Util_Ui.php:1544 msgid "Minify" msgstr "" @@ -4716,132 +4721,142 @@ msgstr "" #: Extension_NewRelic_GeneralPage_View.php:9 #: Extension_NewRelic_Plugin_Admin.php:97 #: Extension_NewRelic_Plugin_Admin.php:98 -#: inc/options/common/header.php:126 +#: Util_PageUrls.php:961 msgid "Monitoring" msgstr "" +#: Extension_NewRelic_GeneralPage_View.php:10 +msgid "" +"\"New Relic\" is a powerful performance monitoring and analysis tool that enhance the speed and efficiency \n" +"\t\t\tof a WordPress website. By utilizing New Relic, website owners can gain valuable insights into their \n" +"\t\t\tsite's performance, identifying bottlenecks, slow queries, and other performance issues. With this \n" +"\t\t\tinformation, users can optimize their website's configuration, improve caching strategies, and make \n" +"\t\t\tinformed decisions to deliver a faster and more responsive browsing experience for their visitors." +msgstr "" + #. translators: 3 opening HTML a tag to NewRelic documentation for PHP, 4 closing HTML a tag. -#: Extension_NewRelic_GeneralPage_View.php:20 +#: Extension_NewRelic_GeneralPage_View.php:33 msgid "New Relic may not be installed or not active on this server. %1$sSign up for a (free) account%2$s. Visit %3$sNew Relic%4$s for installation instructions." msgstr "" -#: Extension_NewRelic_GeneralPage_View.php:72 -#: Extension_NewRelic_Page_View_Apm.php:41 +#: Extension_NewRelic_GeneralPage_View.php:85 +#: Extension_NewRelic_Page_View_Apm.php:36 msgid "Application name:" msgstr "" -#: Extension_NewRelic_Page_View_Apm.php:15 +#: Extension_NewRelic_Page_View_Apm.php:10 msgid "NewRelic extension is currently" msgstr "" -#: Extension_NewRelic_Page_View_Apm.php:28 +#: Extension_NewRelic_Page_View_Apm.php:23 msgid "Application Settings" msgstr "" -#: Extension_NewRelic_Page_View_Apm.php:33 +#: Extension_NewRelic_Page_View_Apm.php:28 msgid "Application ID:" msgstr "" -#: Extension_NewRelic_Page_View_Apm.php:49 +#: Extension_NewRelic_Page_View_Apm.php:44 msgid "Alerts enabled:" msgstr "" -#: Extension_NewRelic_Page_View_Apm.php:59 +#: Extension_NewRelic_Page_View_Apm.php:54 msgid "Application ApDex Threshold:" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_NewRelic_Page_View_Apm.php:74 +#: Extension_NewRelic_Page_View_Apm.php:69 msgid "%1$sRUM%2$s ApDex Threshold:" msgstr "" -#: Extension_NewRelic_Page_View_Apm.php:78 -#: Extension_NewRelic_Page_View_Apm.php:107 -#: Extension_NewRelic_Page_View_Apm.php:213 -#: Extension_NewRelic_Page_View_Apm.php:233 -#: Extension_NewRelic_Page_View_Apm.php:269 -#: Extension_NewRelic_Page_View_Apm.php:297 +#: Extension_NewRelic_Page_View_Apm.php:73 +#: Extension_NewRelic_Page_View_Apm.php:102 +#: Extension_NewRelic_Page_View_Apm.php:206 +#: Extension_NewRelic_Page_View_Apm.php:226 +#: Extension_NewRelic_Page_View_Apm.php:262 +#: Extension_NewRelic_Page_View_Apm.php:290 msgid "Real User Monitoring" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_NewRelic_Page_View_Apm.php:103 +#: Extension_NewRelic_Page_View_Apm.php:98 msgid "%1$sRUM%2$s enabled:" msgstr "" -#: Extension_NewRelic_Page_View_Apm.php:145 +#: Extension_NewRelic_Page_View_Apm.php:140 msgid "Save New Relic settings" msgstr "" #. translators: 1 opening HTML a tag to W3TC monitoring settings page, 2 closing HTML a tag. -#: Extension_NewRelic_Page_View_Apm.php:153 +#: Extension_NewRelic_Page_View_Apm.php:148 msgid "Application settings could not be retrieved. New Relic may not be properly configured, %1$sreview the settings%2$s." msgstr "" -#: Extension_NewRelic_Page_View_Apm.php:169 +#: Extension_NewRelic_Page_View_Apm.php:164 msgid "Application settings are only visible when New Relic is enabled" msgstr "" -#: Extension_NewRelic_Page_View_Apm.php:175 +#: Extension_NewRelic_Page_View_Apm.php:168 msgid "Dashboard Settings" msgstr "" -#: Extension_NewRelic_Page_View_Apm.php:187 +#: Extension_NewRelic_Page_View_Apm.php:180 msgid "How many minutes data retrieved from New Relic should be stored. Minimum is 1 minute." msgstr "" -#: Extension_NewRelic_Page_View_Apm.php:195 -#: Extension_Swarmify_Page_View.php:44 +#: Extension_NewRelic_Page_View_Apm.php:188 +#: Extension_Swarmify_Page_View.php:39 +#: Util_Ui.php:1908 msgid "Behavior Settings" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_NewRelic_Page_View_Apm.php:209 +#: Extension_NewRelic_Page_View_Apm.php:202 msgid "Use %1$sRUM%2$s only for following user roles" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_NewRelic_Page_View_Apm.php:229 +#: Extension_NewRelic_Page_View_Apm.php:222 msgid "Select user roles that %1$sRUM%2$s should be enabled for:" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_NewRelic_Page_View_Apm.php:265 +#: Extension_NewRelic_Page_View_Apm.php:258 msgid "Include %1$sRUM%2$s in compressed or cached pages:" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_NewRelic_Page_View_Apm.php:293 +#: Extension_NewRelic_Page_View_Apm.php:286 msgid "This enables inclusion of %1$sRUM%2$s when using Page Cache together with Browser Cache gzip or when using Page Cache with Disc: Enhanced" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: Extension_NewRelic_Page_View_Apm.php:317 +#: Extension_NewRelic_Page_View_Apm.php:310 msgid "Use %1$sPHP%2$s function to set application name:" msgstr "" -#: Extension_NewRelic_Page_View_Apm.php:321 -#: inc/options/common/header.php:385 +#: Extension_NewRelic_Page_View_Apm.php:314 #: inc/options/install.php:310 #: inc/options/parts/memcached.php:50 +#: Util_Ui.php:1840 msgid "Hypertext Preprocessor" msgstr "" -#: Extension_NewRelic_Page_View_Apm.php:337 +#: Extension_NewRelic_Page_View_Apm.php:330 msgid "This is required when using New Relic on a network install to set the proper names for sites." msgstr "" #. translators: 1 opening HTML a tag to NewRelic per directory settings documentation, 2 closing HTML a tag. -#: Extension_NewRelic_Page_View_Apm.php:347 +#: Extension_NewRelic_Page_View_Apm.php:340 msgid "Enable this to dynamically set proper application name. (See New Relic %1$sPer-directory settings%2$s for other methods." msgstr "" -#: Extension_NewRelic_Page_View_Apm.php:369 +#: Extension_NewRelic_Page_View_Apm.php:362 msgid "Enable XMIT:" msgstr "" #. translators: 3 closing HTML a tag, 4 closing HTML em tag. -#: Extension_NewRelic_Page_View_Apm.php:381 +#: Extension_NewRelic_Page_View_Apm.php:374 msgid "Enable this if you want to record the metric and transaction data (until the name is changed using PHP function), specify a value of true for this argument to make the agent send the transaction to the daemon. There is a slight performance impact as it takes a few milliseconds for the agent to dump its data. %1$sFrom %2$sNew Relic PHP API doc%3$s%4$s" msgstr "" @@ -4995,47 +5010,47 @@ msgstr "" msgid "You have not configured API key and Account Id." msgstr "" -#: Extension_Swarmify_Page_View.php:14 +#: Extension_Swarmify_Page_View.php:9 msgid "Swarmify extension is currently" msgstr "" -#: Extension_Swarmify_Page_View.php:36 +#: Extension_Swarmify_Page_View.php:31 msgid "Swarmify API Key required in order to start optimizing your videos experience" msgstr "" -#: Extension_Swarmify_Page_View.php:50 +#: Extension_Swarmify_Page_View.php:45 msgid "<video>:" msgstr "" -#: Extension_Swarmify_Page_View.php:52 +#: Extension_Swarmify_Page_View.php:47 msgid "Optimize <video> HTML tags" msgstr "" -#: Extension_Swarmify_Page_View.php:53 +#: Extension_Swarmify_Page_View.php:48 msgid "Optimize videos delivered using <video> HTML tag." msgstr "" -#: Extension_Swarmify_Page_View.php:60 +#: Extension_Swarmify_Page_View.php:55 msgid "JWPlayer:" msgstr "" -#: Extension_Swarmify_Page_View.php:62 +#: Extension_Swarmify_Page_View.php:57 msgid "Optimize JWPlayer" msgstr "" -#: Extension_Swarmify_Page_View.php:63 +#: Extension_Swarmify_Page_View.php:58 msgid "Optimize videos delivered using JWPlayer script." msgstr "" -#: Extension_Swarmify_Page_View.php:70 +#: Extension_Swarmify_Page_View.php:65 msgid "Logged In:" msgstr "" -#: Extension_Swarmify_Page_View.php:72 +#: Extension_Swarmify_Page_View.php:67 msgid "Don't optimize videos for logged in users" msgstr "" -#: Extension_Swarmify_Page_View.php:73 +#: Extension_Swarmify_Page_View.php:68 msgid "Only unauthenticated users will view optimized version of a given page." msgstr "" @@ -5088,7 +5103,7 @@ msgid "Activating the Yoast SEO extension for W3 Total Cache msgstr "" #: Extension_Wpml_Plugin_Admin.php:22 -msgid "W3 Total Cache's Page caching cannot work effectively when WPML Language URL formatis \"Language name added as a parameter\" used. Please consider another URL format. Visit the WPML -> Languages settings. %s" +msgid "W3 Total Cache's Page caching cannot work effectively when WPML Language URL format is \"Language name added as a parameter\" used. Please consider another URL format. Visit the WPML -> Languages settings. %s" msgstr "" #: Extension_Wpml_Plugin_Admin.php:50 @@ -5164,7 +5179,9 @@ msgid "More info" msgstr "" #: FeatureShowcase_Plugin_Admin.php:251 -#: UserExperience_GeneralPage_View.php:28 +#: inc/options/common/footer.php:75 +#: inc/options/common/footer.php:76 +#: UserExperience_GeneralPage_View.php:49 msgid "Lazy Load Google Maps" msgstr "" @@ -5181,6 +5198,8 @@ msgid "Provide the best user experience possible by enhancing by hosting HTML pa msgstr "" #: FeatureShowcase_Plugin_Admin.php:275 +#: inc/options/common/footer.php:70 +#: inc/options/common/footer.php:71 msgid "Eliminate Render Blocking CSS" msgstr "" @@ -5201,6 +5220,8 @@ msgid "Unlocking the fragment caching module delivers enhanced performance for p msgstr "" #: FeatureShowcase_Plugin_Admin.php:311 +#: inc/options/common/footer.php:67 +#: inc/options/common/footer.php:68 msgid "Rest API Caching" msgstr "" @@ -5209,6 +5230,8 @@ msgid "Save server resources or add scale and performance by caching the WordPre msgstr "" #: FeatureShowcase_Plugin_Admin.php:323 +#: inc/options/common/footer.php:81 +#: inc/options/common/footer.php:82 #: UsageStatistics_Widget.php:25 msgid "Caching Statistics" msgstr "" @@ -5218,6 +5241,8 @@ msgid "Analytics for your WordPress and Server cache that allow you to track the msgstr "" #: FeatureShowcase_Plugin_Admin.php:335 +#: inc/options/common/footer.php:84 +#: inc/options/common/footer.php:85 msgid "Purge Logs" msgstr "" @@ -5242,8 +5267,8 @@ msgid "Reduce load time by decreasing the size and number of CSS and JS files." msgstr "" #: FeatureShowcase_Plugin_Admin.php:396 -#: SetupGuide_Plugin_Admin.php:1278 -#: UserExperience_GeneralPage_View.php:19 +#: SetupGuide_Plugin_Admin.php:1370 +#: UserExperience_GeneralPage_View.php:38 msgid "Lazy Load Images" msgstr "" @@ -5260,10 +5285,10 @@ msgid "Host static files with a CDN to reduce page load time." msgstr "" #: FeatureShowcase_Plugin_Admin.php:420 -#: inc/options/common/header.php:65 -#: SystemOpCache_GeneralPage_View.php:8 -#: SystemOpCache_GeneralPage_View.php:15 +#: SystemOpCache_GeneralPage_View.php:9 +#: SystemOpCache_GeneralPage_View.php:29 #: SystemOpCache_Plugin_Admin.php:55 +#: Util_Ui.php:1548 msgid "Opcode Cache" msgstr "" @@ -5276,20 +5301,22 @@ msgid "Persistently store data to reduce post, page and feed creation time." msgstr "" #: FeatureShowcase_Plugin_Admin.php:444 -#: inc/options/common/header.php:73 -#: inc/options/general.php:378 +#: inc/options/common/top_nav_bar.php:36 +#: inc/options/general.php:357 #: ObjectCache_ConfigLabels.php:9 -#: ObjectCache_Plugin.php:250 -#: ObjectCache_Plugin.php:310 -#: ObjectCache_Plugin.php:318 -#: ObjectCache_Plugin.php:327 +#: ObjectCache_Plugin.php:251 +#: ObjectCache_Plugin.php:311 +#: ObjectCache_Plugin.php:319 +#: ObjectCache_Plugin.php:328 #: Root_AdminMenu.php:79 #: Root_AdminMenu.php:80 -#: SetupGuide_Plugin_Admin.php:1056 -#: SetupGuide_Plugin_Admin.php:1192 -#: SetupGuide_Plugin_Admin.php:1206 +#: SetupGuide_Plugin_Admin.php:1132 +#: SetupGuide_Plugin_Admin.php:1272 +#: SetupGuide_Plugin_Admin.php:1286 #: UsageStatistics_Page_View.php:250 #: UsageStatistics_Page_View.php:255 +#: Util_PageUrls.php:908 +#: Util_Ui.php:1556 msgid "Object Cache" msgstr "" @@ -5297,22 +5324,7 @@ msgstr "" msgid "Persistently store objects to reduce execution time for common operations." msgstr "" -#: FeatureShowcase_Plugin_Admin.php:456 -#: inc/options/common/header.php:89 -#: inc/options/general.php:433 -#: PageSpeed_Instructions.php:307 -#: PageSpeed_Instructions.php:517 -#: PageSpeed_Instructions.php:578 -#: Root_AdminMenu.php:85 -#: Root_AdminMenu.php:86 -#: SetupGuide_Plugin_Admin.php:1060 -#: SetupGuide_Plugin_Admin.php:1221 -#: SetupGuide_Plugin_Admin.php:1254 -msgid "Browser Cache" -msgstr "" - #: FeatureShowcase_Plugin_Admin.php:458 -#: inc/options/general.php:437 msgid "Reduce server load and decrease response time by using the cache available in site visitor's web browser." msgstr "" @@ -5321,8 +5333,10 @@ msgid "Additional features to extend the functionality of W3 Total Cache, such a msgstr "" #: FeatureShowcase_Plugin_Admin.php:480 +#: inc/options/common/top_nav_bar.php:44 #: Root_AdminMenu.php:91 #: Root_AdminMenu.php:92 +#: Util_PageUrls.php:918 msgid "Cache Groups" msgstr "" @@ -5330,10 +5344,14 @@ msgstr "" msgid "Manage cache groups for user agents, referrers, and cookies." msgstr "" -#: FeatureShowcase_Plugin_Admin_View.php:74 +#: FeatureShowcase_Plugin_Admin_View.php:69 msgid "PRO FEATURE" msgstr "" +#: FeatureShowcase_Plugin_Admin_View.php:82 +msgid "Unlock Feature" +msgstr "" + #: Generic_AdminActions_Config.php:55 msgid "Content-Disposition: attachment; filename=%s.json" msgstr "" @@ -5477,8 +5495,8 @@ msgid "Topic ID:" msgstr "" #: Generic_ConfigLabels.php:12 -#: inc/options/common/header.php:120 -#: inc/options/general.php:551 +#: inc/options/general.php:527 +#: Util_Ui.php:1517 msgid "Message Bus" msgstr "" @@ -5523,9 +5541,8 @@ msgid "Enable reverse proxy caching via varnish" msgstr "" #: Generic_ConfigLabels.php:26 -#: inc/options/common/header.php:112 -#: inc/options/general.php:473 -#: Varnish_Plugin.php:81 +#: inc/options/general.php:468 +#: Util_Ui.php:1583 msgid "Reverse Proxy" msgstr "" @@ -5549,24 +5566,24 @@ msgid "Clear Log" msgstr "" #: Generic_Plugin.php:238 -#: Generic_Plugin_Admin.php:188 -#: Generic_Plugin_Admin.php:197 -#: Generic_Plugin_Admin.php:206 -#: Generic_Plugin_Admin.php:215 -#: Generic_Plugin_Admin.php:224 -#: Generic_Plugin_Admin.php:238 -#: Generic_Plugin_Admin.php:246 -#: Generic_Plugin_Admin.php:254 -#: Generic_Plugin_Admin.php:262 -#: Generic_Plugin_Admin.php:270 -#: Generic_Plugin_Admin.php:278 -#: Generic_Plugin_Admin.php:286 -#: Generic_Plugin_Admin.php:297 -#: Generic_Plugin_Admin.php:305 -#: Generic_Plugin_Admin.php:313 -#: Generic_Plugin_Admin.php:321 -#: Generic_Plugin_Admin.php:329 -#: Generic_Plugin_Admin.php:339 +#: Generic_Plugin_Admin.php:191 +#: Generic_Plugin_Admin.php:200 +#: Generic_Plugin_Admin.php:209 +#: Generic_Plugin_Admin.php:218 +#: Generic_Plugin_Admin.php:227 +#: Generic_Plugin_Admin.php:241 +#: Generic_Plugin_Admin.php:249 +#: Generic_Plugin_Admin.php:257 +#: Generic_Plugin_Admin.php:265 +#: Generic_Plugin_Admin.php:273 +#: Generic_Plugin_Admin.php:281 +#: Generic_Plugin_Admin.php:289 +#: Generic_Plugin_Admin.php:300 +#: Generic_Plugin_Admin.php:308 +#: Generic_Plugin_Admin.php:316 +#: Generic_Plugin_Admin.php:324 +#: Generic_Plugin_Admin.php:332 +#: Generic_Plugin_Admin.php:342 #: Root_AdminMenu.php:166 #: Root_AdminMenu.php:167 msgid "Performance" @@ -5576,31 +5593,49 @@ msgstr "" msgid "Purge All Caches" msgstr "" -#: Generic_Plugin.php:261 +#: Generic_Plugin.php:270 +msgid "Purge All Caches Except CloudFlare" +msgstr "" + +#: Generic_Plugin.php:282 msgid "Purge Current Page" msgstr "" -#: Generic_Plugin.php:272 +#: Generic_Plugin.php:293 msgid "Purge Modules" msgstr "" -#: Generic_Plugin.php:279 +#: Generic_Plugin.php:300 +#: inc/options/common/top_nav_bar.php:84 #: Root_AdminMenu.php:49 #: Root_AdminMenu.php:50 +#: Util_PageUrls.php:887 msgid "Feature Showcase" msgstr "" -#: Generic_Plugin.php:289 +#: Generic_Plugin.php:310 +#: inc/options/common/top_nav_bar.php:20 #: Root_AdminMenu.php:55 #: Root_AdminMenu.php:56 +#: Util_PageUrls.php:890 +#: Util_PageUrls.php:894 +#: Util_PageUrls.php:899 +#: Util_PageUrls.php:904 +#: Util_PageUrls.php:909 +#: Util_PageUrls.php:914 +#: Util_PageUrls.php:919 +#: Util_PageUrls.php:924 +#: Util_PageUrls.php:929 +#: Util_PageUrls.php:940 +#: Util_PageUrls.php:962 msgid "General Settings" msgstr "" -#: Generic_Plugin.php:298 +#: Generic_Plugin.php:319 msgid "Manage Extensions" msgstr "" -#: Generic_Plugin.php:308 +#: Generic_Plugin.php:329 #: PageSpeed_Instructions.php:70 #: PageSpeed_Instructions.php:87 #: PageSpeed_Instructions.php:359 @@ -5609,57 +5644,61 @@ msgstr "" msgid "FAQ" msgstr "" -#: Generic_Plugin.php:318 +#: Generic_Plugin.php:339 +#: inc/options/common/footer.php:50 +#: inc/options/common/top_nav_bar.php:201 +#: inc/options/common/top_nav_bar.php:202 #: Root_AdminMenu.php:113 #: Root_AdminMenu.php:114 +#: Util_PageUrls.php:933 msgid "Support" msgstr "" -#: Generic_Plugin.php:329 +#: Generic_Plugin.php:350 msgid "Debug: Overlays" msgstr "" -#: Generic_Plugin.php:334 +#: Generic_Plugin.php:355 msgid "Support Us" msgstr "" #. translators: 4: HTML line break tag, 5: HTML opening a tag to purge CDN manually, 6: HTML closing a tag. -#: Generic_Plugin_Admin.php:616 +#: Generic_Plugin_Admin.php:639 msgid "Please see %1$sAmazon's CloudFront documentation -- Paying for file invalidation%2$sThe first 1,000 invalidation paths that you submit per month are free; you pay for each invalidation path over 1,000 in a month.%3$sYou can disable automatic purging by enabling %4$sOnly purge CDN manually%5$s." msgstr "" -#: Generic_Plugin_Admin.php:753 +#: Generic_Plugin_Admin.php:776 msgid "Premium Support" msgstr "" -#: Generic_Plugin_Admin.php:774 +#: Generic_Plugin_Admin.php:797 msgid "Empty Caches" msgstr "" -#: Generic_Plugin_Admin.php:821 +#: Generic_Plugin_Admin.php:844 msgid "Take a minute to update, here's why:" msgstr "" #. translators: 1 enable button link. -#: Generic_Plugin_Admin.php:858 +#: Generic_Plugin_Admin.php:881 msgid "Fancy permalinks are disabled. Please %1$s it first, then re-attempt to enabling enhanced disk mode." msgstr "" #. translators: 1 enable button link. -#: Generic_Plugin_Admin.php:866 +#: Generic_Plugin_Admin.php:889 msgid "Fancy permalinks are disabled. Please %1$s it first, then re-attempt to enabling the 'Do not process 404 errors for static objects with WordPress'." msgstr "" -#: Generic_Plugin_Admin.php:872 +#: Generic_Plugin_Admin.php:895 msgid "Please select request type." msgstr "" #. translators: 1 HTML acronym URL (uniform resource locator). -#: Generic_Plugin_Admin.php:875 +#: Generic_Plugin_Admin.php:898 msgid "Please enter the address of the site in the site %1$s field." msgstr "" -#: Generic_Plugin_Admin.php:879 +#: Generic_Plugin_Admin.php:902 #: Util_PageSpeed.php:279 #: Util_PageSpeed.php:289 #: Util_PageSpeed.php:462 @@ -5667,55 +5706,55 @@ msgstr "" msgid "URL" msgstr "" -#: Generic_Plugin_Admin.php:881 +#: Generic_Plugin_Admin.php:904 msgid "Please enter your name in the Name field" msgstr "" -#: Generic_Plugin_Admin.php:882 +#: Generic_Plugin_Admin.php:905 msgid "Please enter valid email address in the E-Mail field." msgstr "" -#: Generic_Plugin_Admin.php:883 +#: Generic_Plugin_Admin.php:906 msgid "Please enter your phone in the phone field." msgstr "" -#: Generic_Plugin_Admin.php:884 +#: Generic_Plugin_Admin.php:907 msgid "Please enter subject in the subject field." msgstr "" -#: Generic_Plugin_Admin.php:885 +#: Generic_Plugin_Admin.php:908 msgid "Please describe the issue in the issue description field." msgstr "" -#: Generic_Plugin_Admin.php:886 +#: Generic_Plugin_Admin.php:909 msgid "Please enter an administrator login. Create a temporary one just for this support case if needed." msgstr "" -#: Generic_Plugin_Admin.php:887 +#: Generic_Plugin_Admin.php:910 msgid "Please enter WP Admin password, be sure it's spelled correctly." msgstr "" #. translators: 1 HTML acronym SSH (secure shell), 2 HTML acronym FTP (file transfer protocol). -#: Generic_Plugin_Admin.php:890 +#: Generic_Plugin_Admin.php:913 msgid "Please enter %1$s or %2$s host for the site." msgstr "" -#: Generic_Plugin_Admin.php:894 -#: Generic_Plugin_Admin.php:903 -#: Generic_Plugin_Admin.php:912 +#: Generic_Plugin_Admin.php:917 +#: Generic_Plugin_Admin.php:926 +#: Generic_Plugin_Admin.php:935 #: inc/options/cdn/ftp.php:240 msgid "Secure Shell" msgstr "" -#: Generic_Plugin_Admin.php:894 -#: Generic_Plugin_Admin.php:903 -#: Generic_Plugin_Admin.php:912 +#: Generic_Plugin_Admin.php:917 +#: Generic_Plugin_Admin.php:926 +#: Generic_Plugin_Admin.php:935 msgid "SSH" msgstr "" -#: Generic_Plugin_Admin.php:895 -#: Generic_Plugin_Admin.php:904 -#: Generic_Plugin_Admin.php:913 +#: Generic_Plugin_Admin.php:918 +#: Generic_Plugin_Admin.php:927 +#: Generic_Plugin_Admin.php:936 #: inc/lightbox/self_test.php:120 #: inc/lightbox/self_test.php:316 #: inc/options/cdn/ftp.php:19 @@ -5730,197 +5769,201 @@ msgstr "" msgid "File Transfer Protocol" msgstr "" -#: Generic_Plugin_Admin.php:895 -#: Generic_Plugin_Admin.php:904 -#: Generic_Plugin_Admin.php:913 +#: Generic_Plugin_Admin.php:918 +#: Generic_Plugin_Admin.php:927 +#: Generic_Plugin_Admin.php:936 msgid "FTP" msgstr "" #. translators: 1 HTML acronym SSH (secure shell), 2 HTML acronym FTP (file transfer protocol). -#: Generic_Plugin_Admin.php:899 +#: Generic_Plugin_Admin.php:922 msgid "Please enter %1$s or %2$s login for the server. Create a temporary one just for this support case if needed." msgstr "" #. translators: 1 HTML acronym SSH (secure shell), 2 HTML acronym FTP (file transfer protocol). -#: Generic_Plugin_Admin.php:908 +#: Generic_Plugin_Admin.php:931 msgid "Please enter %1$s or %2$s password for the %2$s account." msgstr "" -#: Generic_Plugin_Admin.php:915 +#: Generic_Plugin_Admin.php:938 msgid "Unable to send the support request." msgstr "" -#: Generic_Plugin_Admin.php:916 +#: Generic_Plugin_Admin.php:939 msgid "Please select config file." msgstr "" -#: Generic_Plugin_Admin.php:917 +#: Generic_Plugin_Admin.php:940 msgid "Unable to upload config file." msgstr "" -#: Generic_Plugin_Admin.php:918 +#: Generic_Plugin_Admin.php:941 msgid "Configuration file could not be imported." msgstr "" #. translators: 1 W3TC config director path. -#: Generic_Plugin_Admin.php:921 +#: Generic_Plugin_Admin.php:944 msgid "Default settings could not be restored. Please run %1$s to make the configuration file write-able, then try again." msgstr "" -#: Generic_Plugin_Admin.php:927 +#: Generic_Plugin_Admin.php:950 msgid "Unable to purge attachment." msgstr "" -#: Generic_Plugin_Admin.php:928 +#: Generic_Plugin_Admin.php:951 msgid "Unable to purge post." msgstr "" #. translators: 1 absolute path to wp-config.php, 2 cookie domain definition, 3 require once wp-setting.php definition. -#: Generic_Plugin_Admin.php:931 +#: Generic_Plugin_Admin.php:954 msgid "%1$s could not be written, please edit config and add: %2$s before %3$s." msgstr "" #. translators: 1 absolute path to wp-config.php, 2 cooke domain definition, 3 require once wp-setting.php definition. -#: Generic_Plugin_Admin.php:941 +#: Generic_Plugin_Admin.php:964 msgid "%1$s could not be written, please edit config and add:%2$s before %3$s." msgstr "" -#: Generic_Plugin_Admin.php:949 +#: Generic_Plugin_Admin.php:972 msgid "Pull Zone could not be automatically created." msgstr "" -#: Generic_Plugin_Admin.php:953 +#: Generic_Plugin_Admin.php:976 msgid "Plugin configuration successfully updated." msgstr "" -#: Generic_Plugin_Admin.php:954 +#: Generic_Plugin_Admin.php:977 +msgid "Plugin configuration successfully updated and all caches successfully emptied." +msgstr "" + +#: Generic_Plugin_Admin.php:978 msgid "All caches successfully emptied." msgstr "" -#: Generic_Plugin_Admin.php:955 +#: Generic_Plugin_Admin.php:979 msgid "Memcached cache(s) successfully emptied." msgstr "" -#: Generic_Plugin_Admin.php:956 +#: Generic_Plugin_Admin.php:980 msgid "Opcode cache(s) successfully emptied." msgstr "" -#: Generic_Plugin_Admin.php:957 +#: Generic_Plugin_Admin.php:981 msgid "Disk cache(s) successfully emptied." msgstr "" -#: Generic_Plugin_Admin.php:958 +#: Generic_Plugin_Admin.php:982 msgid "Page cache successfully emptied." msgstr "" -#: Generic_Plugin_Admin.php:959 +#: Generic_Plugin_Admin.php:983 msgid "Database cache successfully emptied." msgstr "" -#: Generic_Plugin_Admin.php:960 +#: Generic_Plugin_Admin.php:984 msgid "Object cache successfully emptied." msgstr "" -#: Generic_Plugin_Admin.php:961 +#: Generic_Plugin_Admin.php:985 msgid "Fragment cache successfully emptied." msgstr "" -#: Generic_Plugin_Admin.php:962 +#: Generic_Plugin_Admin.php:986 msgid "Minify cache successfully emptied." msgstr "" -#: Generic_Plugin_Admin.php:963 +#: Generic_Plugin_Admin.php:987 msgid "Media Query string has been successfully updated." msgstr "" -#: Generic_Plugin_Admin.php:964 +#: Generic_Plugin_Admin.php:988 msgid "Varnish servers successfully purged." msgstr "" #. translators: 1 HTML acronym for CDN (content delivery network). -#: Generic_Plugin_Admin.php:967 +#: Generic_Plugin_Admin.php:991 msgid "%1$s was successfully purged." msgstr "" -#: Generic_Plugin_Admin.php:973 +#: Generic_Plugin_Admin.php:997 msgid "The support request has been successfully sent." msgstr "" -#: Generic_Plugin_Admin.php:974 +#: Generic_Plugin_Admin.php:998 msgid "Settings successfully imported." msgstr "" -#: Generic_Plugin_Admin.php:975 +#: Generic_Plugin_Admin.php:999 msgid "Settings successfully restored." msgstr "" -#: Generic_Plugin_Admin.php:976 +#: Generic_Plugin_Admin.php:1000 msgid "Preview mode was successfully enabled" msgstr "" -#: Generic_Plugin_Admin.php:977 +#: Generic_Plugin_Admin.php:1001 msgid "Preview mode was successfully disabled" msgstr "" -#: Generic_Plugin_Admin.php:978 +#: Generic_Plugin_Admin.php:1002 msgid "Preview settings successfully deployed. Preview mode remains enabled until it's disabled. Continue testing new settings or disable preview mode if done." msgstr "" -#: Generic_Plugin_Admin.php:979 +#: Generic_Plugin_Admin.php:1003 msgid "Attachment successfully purged." msgstr "" -#: Generic_Plugin_Admin.php:980 +#: Generic_Plugin_Admin.php:1004 msgid "Post successfully purged." msgstr "" -#: Generic_Plugin_Admin.php:981 +#: Generic_Plugin_Admin.php:1005 msgid "New relic settings have been updated." msgstr "" -#: Generic_Plugin_Admin.php:982 +#: Generic_Plugin_Admin.php:1006 msgid "The add-in has been removed." msgstr "" -#: Generic_Plugin_Admin.php:983 +#: Generic_Plugin_Admin.php:1007 msgid "Edge mode has been enabled." msgstr "" -#: Generic_Plugin_Admin.php:984 +#: Generic_Plugin_Admin.php:1008 msgid "Edge mode has been disabled." msgstr "" -#: Generic_Plugin_Admin.php:985 +#: Generic_Plugin_Admin.php:1009 msgid "Pull Zone was automatically created." msgstr "" -#: Generic_Plugin_Admin.php:1035 +#: Generic_Plugin_Admin.php:1059 msgid "Required files and directories have been automatically created" msgstr "" -#: Generic_Plugin_Admin.php:1062 +#: Generic_Plugin_Admin.php:1086 msgid "W3 Total Cache Error:" msgstr "" -#: Generic_Plugin_Admin.php:1063 +#: Generic_Plugin_Admin.php:1087 msgid "Files and directories could not be automatically created to complete the installation." msgstr "" -#: Generic_Plugin_Admin.php:1066 +#: Generic_Plugin_Admin.php:1090 #: Util_Activation.php:240 msgid "Please execute commands manually" msgstr "" -#: Generic_Plugin_Admin.php:1067 +#: Generic_Plugin_Admin.php:1091 #: Util_Activation.php:244 msgid "View required changes" msgstr "" -#: Generic_Plugin_Admin.php:1070 +#: Generic_Plugin_Admin.php:1094 msgid "or use FTP form to allow " msgstr "" -#: Generic_Plugin_Admin.php:1072 +#: Generic_Plugin_Admin.php:1096 msgid "make it automatically." msgstr "" @@ -5997,13 +6040,53 @@ msgstr "" msgid "Plus, there's even more that allow you to completely fine tune your website's performance." msgstr "" -#: Generic_WidgetCommunity_View.php:41 -#: inc/options/parts/dashboard_banner.php:59 +#: Generic_WidgetCommunity_View.php:39 +#: inc/options/parts/dashboard_banner.php:57 msgid "Learn more about Pro" msgstr "" -#: Generic_WidgetServices_View.php:35 -msgid "Buy now" +#: Generic_WidgetServices.php:56 +msgid "Billing Support" +msgstr "" + +#: Generic_WidgetServices.php:57 +msgid "Sales Questions" +msgstr "" + +#: Generic_WidgetServices.php:58 +msgid "Submit a Bug Report" +msgstr "" + +#: Generic_WidgetServices.php:59 +msgid "Suggest a New Feature" +msgstr "" + +#: Generic_WidgetServices.php:60 +msgid "Performance Audit & Consultation" +msgstr "" + +#: Generic_WidgetServices.php:61 +msgid "Plugin Configuration" +msgstr "" + +#: Generic_WidgetServices.php:62 +msgid "CDN Configuration: Full-Site Delivery" +msgstr "" + +#: Generic_WidgetServices.php:63 +msgid "Hosting Environment Troubleshooting" +msgstr "" + +#: Generic_WidgetServices.php:64 +msgid "Eliminate render-blocking Javascripts" +msgstr "" + +#: Generic_WidgetServices.php:65 +msgid "Investigate Compatibility Issue" +msgstr "" + +#: Generic_WidgetServices_View.php:18 +msgid "Learn More" msgstr "" #: Generic_WidgetSpreadTheWord_Plugin.php:44 @@ -6085,42 +6168,42 @@ msgstr "" #: inc/lightbox/minify_recommendations.php:35 #: inc/lightbox/minify_recommendations.php:93 -#: inc/options/minify.php:490 -#: inc/options/minify.php:773 +#: inc/options/minify.php:467 +#: inc/options/minify.php:749 msgid "File URI:" msgstr "" #: inc/lightbox/minify_recommendations.php:36 #: inc/lightbox/minify_recommendations.php:94 -#: inc/options/minify.php:491 -#: inc/options/minify.php:774 +#: inc/options/minify.php:468 +#: inc/options/minify.php:750 msgid "Template:" msgstr "" #: inc/lightbox/minify_recommendations.php:37 -#: inc/options/minify.php:492 +#: inc/options/minify.php:469 msgid "Embed Location:" msgstr "" #: inc/lightbox/minify_recommendations.php:57 -#: inc/options/minify.php:513 +#: inc/options/minify.php:490 msgid "Embed in <head>" msgstr "" #: inc/lightbox/minify_recommendations.php:58 -#: inc/options/minify.php:514 +#: inc/options/minify.php:491 msgid "Embed after <body>" msgstr "" #: inc/lightbox/minify_recommendations.php:59 -#: inc/options/minify.php:515 +#: inc/options/minify.php:492 msgid "Embed before </body>" msgstr "" #: inc/lightbox/minify_recommendations.php:63 #: inc/lightbox/minify_recommendations.php:112 -#: inc/options/minify.php:520 -#: inc/options/minify.php:795 +#: inc/options/minify.php:497 +#: inc/options/minify.php:771 msgid "Verify URI" msgstr "" @@ -6412,12 +6495,12 @@ msgid "URL rewrite:" msgstr "" #: inc/lightbox/self_test.php:501 -#: SetupGuide_Plugin_Admin.php:912 +#: SetupGuide_Plugin_Admin.php:973 msgid "Enabled" msgstr "" #: inc/lightbox/self_test.php:503 -#: inc/options/minify.php:145 +#: inc/options/minify.php:124 msgid "Disabled" msgstr "" @@ -6523,9 +6606,9 @@ msgid "Caching of search results pages (i.e. %1$sURI%2$ss with query string vari msgstr "" #: inc/options/about.php:164 -#: inc/options/browsercache.php:229 -#: inc/options/browsercache.php:263 -#: inc/options/browsercache.php:291 +#: inc/options/browsercache.php:230 +#: inc/options/browsercache.php:264 +#: inc/options/browsercache.php:292 msgid "Uniform Resource Identifier" msgstr "" @@ -6579,140 +6662,140 @@ msgid "%1$s to make existing file modifications visible to visitors with a prime msgstr "" #: inc/options/browsercache.php:60 -#: inc/options/cdn.php:120 -#: inc/options/minify.php:76 +#: inc/options/cdn.php:119 +#: inc/options/minify.php:55 msgid "Update media query string" msgstr "" -#: inc/options/browsercache.php:80 +#: inc/options/browsercache.php:81 msgid "Specify global browser cache policy." msgstr "" -#: inc/options/browsercache.php:90 +#: inc/options/browsercache.php:91 #: inc/options/browsercache.php:382 -#: inc/options/browsercache.php:528 -#: inc/options/browsercache.php:611 +#: inc/options/browsercache.php:527 +#: inc/options/browsercache.php:609 msgid "Set the Last-Modified header to enable 304 Not Modified response." msgstr "" -#: inc/options/browsercache.php:99 +#: inc/options/browsercache.php:100 #: inc/options/browsercache.php:388 -#: inc/options/browsercache.php:534 -#: inc/options/browsercache.php:617 +#: inc/options/browsercache.php:533 +#: inc/options/browsercache.php:615 msgid "Set the expires header to encourage browser caching of files." msgstr "" -#: inc/options/browsercache.php:106 +#: inc/options/browsercache.php:107 #: inc/options/browsercache.php:404 -#: inc/options/browsercache.php:551 -#: inc/options/browsercache.php:633 +#: inc/options/browsercache.php:550 +#: inc/options/browsercache.php:631 msgid "Set pragma and cache-control headers to encourage browser caching of files." msgstr "" -#: inc/options/browsercache.php:114 +#: inc/options/browsercache.php:115 #: inc/options/browsercache.php:434 -#: inc/options/browsercache.php:580 -#: inc/options/browsercache.php:663 +#: inc/options/browsercache.php:579 +#: inc/options/browsercache.php:661 msgid "Set the ETag header to encourage browser caching of files." msgstr "" -#: inc/options/browsercache.php:121 +#: inc/options/browsercache.php:122 #: inc/options/browsercache.php:440 -#: inc/options/browsercache.php:586 -#: inc/options/browsercache.php:669 +#: inc/options/browsercache.php:585 +#: inc/options/browsercache.php:667 msgid "Set this header to assist in identifying optimized files." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/browsercache.php:133 +#: inc/options/browsercache.php:134 msgid "Enable %1$sHTTP%2$s (gzip) compression" msgstr "" -#: inc/options/browsercache.php:148 -#: inc/options/browsercache.php:176 +#: inc/options/browsercache.php:149 +#: inc/options/browsercache.php:177 #: inc/options/browsercache.php:446 #: inc/options/browsercache.php:452 -#: inc/options/browsercache.php:592 -#: inc/options/browsercache.php:598 -#: inc/options/browsercache.php:675 -#: inc/options/browsercache.php:681 +#: inc/options/browsercache.php:591 +#: inc/options/browsercache.php:597 +#: inc/options/browsercache.php:673 +#: inc/options/browsercache.php:679 msgid "Reduce the download time for text-based files." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/browsercache.php:161 +#: inc/options/browsercache.php:162 msgid "Enable %1$sHTTP%2$s (brotli) compression" msgstr "" -#: inc/options/browsercache.php:184 +#: inc/options/browsercache.php:185 #: inc/options/browsercache.php:458 -#: inc/options/browsercache.php:687 +#: inc/options/browsercache.php:685 msgid "Whenever settings are changed, a new query string will be generated and appended to objects allowing the new policy to be applied." msgstr "" -#: inc/options/browsercache.php:191 +#: inc/options/browsercache.php:192 #: inc/options/browsercache.php:463 -#: inc/options/browsercache.php:692 +#: inc/options/browsercache.php:690 msgid "Remove query strings from static resources" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/browsercache.php:197 +#: inc/options/browsercache.php:198 #: inc/options/browsercache.php:469 -#: inc/options/browsercache.php:698 +#: inc/options/browsercache.php:696 msgid "Resources with a \"?\" in the %1$sURL%2$s are not cached by some proxy caching servers." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/browsercache.php:225 +#: inc/options/browsercache.php:226 msgid "Do not add the prevent caching query string to the specified %1$sURI%2$ss. Supports regular expressions." msgstr "" -#: inc/options/browsercache.php:246 +#: inc/options/browsercache.php:247 msgid "Don't set cookies for static files" msgstr "" -#: inc/options/browsercache.php:247 +#: inc/options/browsercache.php:248 #: inc/options/browsercache.php:489 -#: inc/options/browsercache.php:718 +#: inc/options/browsercache.php:716 msgid "Removes Set-Cookie header for responses." msgstr "" -#: inc/options/browsercache.php:253 +#: inc/options/browsercache.php:254 msgid "Reduce server load by allowing the web server to handle 404 (not found) errors for static files (images etc)." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/browsercache.php:259 +#: inc/options/browsercache.php:260 msgid "If enabled - you may get 404 File Not Found response for some files generated on-the-fly by WordPress plugins. You may add those file %1$sURI%2$ss to 404 error exception list below to avoid that." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/browsercache.php:287 +#: inc/options/browsercache.php:288 msgid "Never process 404 (not found) events for the specified %1$sURI%2$ss." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/browsercache.php:313 +#: inc/options/browsercache.php:314 msgid "Rewrite %1$sURL%2$s structure of objects" msgstr "" -#: inc/options/browsercache.php:317 +#: inc/options/browsercache.php:318 msgid "Universal Resource Locator" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/browsercache.php:329 +#: inc/options/browsercache.php:330 msgid "Generate unique %1$sURI%2$s for each file protected from caching by browser." msgstr "" -#: inc/options/browsercache.php:333 +#: inc/options/browsercache.php:334 msgid "Universal Resource Indicator" msgstr "" #. translators: 3 opening HTML acronym tag, 4 closing HTML acronym tag. #: inc/options/browsercache.php:357 -#: inc/options/common/header.php:306 +#: Util_Ui.php:1745 msgid "%1$sCSS%2$s & %3$sJS%4$s" msgstr "" @@ -6721,26 +6804,26 @@ msgid "Specify browser cache policy for Cascading Style Sheets and JavaScript fi msgstr "" #: inc/options/browsercache.php:420 -#: inc/options/browsercache.php:566 -#: inc/options/browsercache.php:649 +#: inc/options/browsercache.php:565 +#: inc/options/browsercache.php:647 msgid "cache with max-age (\"public, max-age=EXPIRES_SECONDS\")" msgstr "" #: inc/options/browsercache.php:421 -#: inc/options/browsercache.php:567 -#: inc/options/browsercache.php:650 +#: inc/options/browsercache.php:566 +#: inc/options/browsercache.php:648 msgid "cache with validation (\"public, must-revalidate, proxy-revalidate\")" msgstr "" #: inc/options/browsercache.php:422 -#: inc/options/browsercache.php:568 -#: inc/options/browsercache.php:651 +#: inc/options/browsercache.php:567 +#: inc/options/browsercache.php:649 msgid "cache with max-age and validation (\"max-age=EXPIRES_SECONDS, public, must-revalidate, proxy-revalidate\")" msgstr "" #: inc/options/browsercache.php:423 -#: inc/options/browsercache.php:569 -#: inc/options/browsercache.php:652 +#: inc/options/browsercache.php:568 +#: inc/options/browsercache.php:650 msgid "cache without proxy (\"private, must-revalidate\")" msgstr "" @@ -6749,72 +6832,65 @@ msgid "don't cache (\"max-age=0, private, no-store, no-cache, must-revalidate\") msgstr "" #: inc/options/browsercache.php:427 -#: inc/options/browsercache.php:573 -#: inc/options/browsercache.php:656 +#: inc/options/browsercache.php:572 +#: inc/options/browsercache.php:654 msgid "The Expires header already sets the max-age." msgstr "" #. translators: 3 opening HTML acronym tag, 4 closing HTML acronym tag. -#: inc/options/browsercache.php:503 -#: inc/options/common/header.php:210 -#: inc/options/common/header.php:329 -#: inc/options/minify.php:165 +#: inc/options/browsercache.php:502 +#: inc/options/minify.php:143 +#: Util_Ui.php:1655 +#: Util_Ui.php:1768 msgid "%1$sHTML%2$s & %3$sXML%4$s" msgstr "" -#: inc/options/browsercache.php:509 -#: inc/options/pgcache.php:258 -#: inc/options/pgcache.php:795 +#: inc/options/browsercache.php:508 +#: inc/options/pgcache.php:233 +#: inc/options/pgcache.php:768 msgid "Extensible Markup Language" msgstr "" -#: inc/options/browsercache.php:522 +#: inc/options/browsercache.php:521 msgid "Specify browser cache policy for posts, pages, feeds and text-based files." msgstr "" -#: inc/options/browsercache.php:570 -#: inc/options/browsercache.php:653 +#: inc/options/browsercache.php:569 +#: inc/options/browsercache.php:651 msgid "no-cache (\"max-age=0, private, no-store, no-cache, must-revalidate\")" msgstr "" -#: inc/options/browsercache.php:606 +#: inc/options/browsercache.php:604 msgid "Media & Other Files" msgstr "" -#: inc/options/cdn.php:26 -#: inc/options/common/header.php:193 -#: inc/options/common/header.php:268 -#: inc/options/pgcache.php:814 -msgid "Note(s)" -msgstr "" - #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/cdn.php:69 +#: inc/options/cdn.php:67 msgid "Prepare the %1$sCDN%2$s by:" msgstr "" -#: inc/options/cdn.php:83 +#: inc/options/cdn.php:81 msgid "importing attachments into the Media Library" msgstr "" -#: inc/options/cdn.php:84 +#: inc/options/cdn.php:82 msgid "unsuccessful file transfers" msgstr "" -#: inc/options/cdn.php:84 +#: inc/options/cdn.php:82 msgid "if some objects appear to be missing." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/cdn.php:91 +#: inc/options/cdn.php:89 msgid " objects from the %1$sCDN%2$s if needed." msgstr "" -#: inc/options/cdn.php:106 +#: inc/options/cdn.php:104 msgid "if the domain name of your site has ever changed." msgstr "" -#: inc/options/cdn.php:120 +#: inc/options/cdn.php:119 msgid "to make existing file modifications visible to visitors with a primed cache." msgstr "" @@ -6877,139 +6953,139 @@ msgstr "" msgid "Adds canonical %1$sHTTP%2$s header to assets files." msgstr "" -#: inc/options/cdn.php:358 +#: inc/options/cdn.php:357 msgid "Configuration: Objects" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/cdn.php:390 +#: inc/options/cdn.php:388 msgid "Only purge %1$sCDN%2$s manually" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/cdn.php:409 +#: inc/options/cdn.php:407 msgid "Purge %1$sCDN%2$s only if explicit purge button is clicked." msgstr "" #. translators: 1: HTML break, 2: HTML anchor open tag, 3: HTML anchor close tag. -#: inc/options/cdn.php:429 +#: inc/options/cdn.php:427 msgid "Please see %2$sAmazon's CloudFront documentation -- Paying for file invalidation%3$s:%1$sThe first 1,000 invalidation paths that you submit per month are free; you pay for each invalidation path over 1,000 in a month.%1$sYou can disable automatic purging by enabling \"Only purge CDN manually\"." msgstr "" #. translators: 5 opening HTML acronym tag, 6 closing HTML acronym tag. -#: inc/options/cdn.php:462 +#: inc/options/cdn.php:460 msgid "When %1$sSSL%2$s pages are returned no %3$sCDN%4$s %5$sURL%6$ss will appear in HTML pages." msgstr "" -#: inc/options/cdn.php:470 +#: inc/options/cdn.php:468 #: inc/popup/cdn_rename_domain.php:26 msgid "Uniform Resource Indicator" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/cdn.php:491 +#: inc/options/cdn.php:489 msgid "All Media Library content will use %1$sCDN%2$s links on administration pages." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/cdn.php:516 +#: inc/options/cdn.php:514 msgid "Add %1$sCORS%2$s headers to allow cross-domain assets usage." msgstr "" -#: inc/options/cdn.php:520 +#: inc/options/cdn.php:518 msgid "Access-Control-Allow-Origin" msgstr "" -#: inc/options/cdn.php:537 +#: inc/options/cdn.php:535 msgid "Select user roles that will use the origin server exclusively:" msgstr "" -#: inc/options/cdn.php:566 -#: inc/options/dbcache.php:109 +#: inc/options/cdn.php:564 +#: inc/options/dbcache.php:90 #: inc/options/install.php:83 #: inc/options/install.php:255 -#: inc/options/pgcache.php:672 -#: inc/options/pgcache.php:743 +#: inc/options/pgcache.php:645 +#: inc/options/pgcache.php:716 #: PageSpeed_Instructions.php:70 #: PageSpeed_Instructions.php:87 #: PageSpeed_Instructions.php:359 msgid "Frequently Asked Questions" msgstr "" -#: inc/options/cdn.php:585 +#: inc/options/cdn.php:583 msgid "Automatically upload minify files" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/cdn.php:591 +#: inc/options/cdn.php:589 msgid "If %1$sCDN%2$s is enabled (and not using the origin pull method), your minified files will be automatically uploaded." msgstr "" -#: inc/options/cdn.php:628 +#: inc/options/cdn.php:626 msgid "Automatically attempt to find and upload changed files." msgstr "" -#: inc/options/cdn.php:638 +#: inc/options/cdn.php:636 msgid "Specify the interval between upload of changed files." msgstr "" -#: inc/options/cdn.php:647 +#: inc/options/cdn.php:645 msgid "The number of seconds to wait before upload attempt." msgstr "" -#: inc/options/cdn.php:656 +#: inc/options/cdn.php:654 msgid "Number of files processed per upload attempt." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/cdn.php:671 +#: inc/options/cdn.php:669 msgid "Specify the file types within the WordPress core to host with the %1$sCDN%2$s." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/cdn.php:699 +#: inc/options/cdn.php:697 msgid "Specify the file types in the active theme to host with the %1$sCDN%2$s." msgstr "" -#: inc/options/cdn.php:722 +#: inc/options/cdn.php:720 msgid "Automatically import files hosted with 3rd parties of these types (if used in your posts / pages) to your media library." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/cdn.php:736 +#: inc/options/cdn.php:734 msgid "Specify any files outside of theme or other common directories to host with the %1$sCDN%2$s." msgstr "" -#: inc/options/cdn.php:752 +#: inc/options/cdn.php:750 msgid "To upload files in blogs.dir for current blog write wp-content/<currentblog>/." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/cdn.php:767 +#: inc/options/cdn.php:765 msgid "Specify user agents that should not access files hosted with the %1$sCDN%2$s." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/cdn.php:794 +#: inc/options/cdn.php:792 msgid "Specify the path of files that should not use the %1$sCDN%2$s." msgstr "" #. translators: 1 Cookie Domain. -#: inc/options/cdn.php:821 +#: inc/options/cdn.php:819 msgid "Set cookie domain to \"%1$s\"" msgstr "" #. translators: 3 opening HTML acronym tag, 4 closing HTML acronym tag. -#: inc/options/cdn.php:836 +#: inc/options/cdn.php:834 msgid "If using subdomain for %1$sCDN%2$s functionality, this setting helps prevent new users from sending cookies in requests to the %3$sCDN%4$s subdomain." msgstr "" -#: inc/options/cdn.php:865 +#: inc/options/cdn.php:862 msgid "You can use placeholders {wp_content_dir}, {plugins_dir}, {uploads_dir} instead of writing folder paths (wp-content, wp-content/plugins, wp-content/uploads)." msgstr "" #. translators: 5 opening HTML a tag to W3TC BrowserCache admin page, 6 closing HTML a tag. -#: inc/options/cdn.php:873 +#: inc/options/cdn.php:870 msgid "If using Amazon Web Services or Self-Hosted %1$sCDN%2$s types, enable %3$sHTTP%4$s compression in the \"Media & Other Files\" section on %5$sBrowser Cache%6$s Settings tab." msgstr "" @@ -7166,8 +7242,8 @@ msgid "(reserved for JS before )" msgstr "" #: inc/options/cdn/common/cnames.php:58 -#: inc/options/minify.php:519 -#: inc/options/minify.php:794 +#: inc/options/minify.php:496 +#: inc/options/minify.php:770 #: inc/popup/cdn_queue.php:25 #: inc/popup/cdn_queue.php:34 #: inc/popup/cdn_queue.php:58 @@ -7321,104 +7397,119 @@ msgid "Theme files, media library attachments, %1$sCSS%2$s, %3$sJS%4$s files etc msgstr "" #. translators: 1 opening HTML span tag, 2 opening HTML sup tag, 3 closing HTML sup tag, 4 closing HTML span tag. -#: inc/options/common/header.php:25 +#: inc/options/common/footer.php:22 +#: inc/options/common/top_nav_bar.php:114 msgid "W3 Total Cache %1$sby W3 EDGE %2$s®%3$s%4$s" msgstr "" -#: inc/options/common/header.php:132 -#: inc/options/general.php:833 -msgid "Licensing" +#: inc/options/common/footer.php:41 +msgid "Documentation" msgstr "" -#: inc/options/common/header.php:142 -#: inc/options/general.php:684 +#: inc/options/common/footer.php:42 +#: inc/options/common/footer.php:43 +msgid "Support Center" +msgstr "" + +#: inc/options/common/footer.php:45 +#: inc/options/common/footer.php:46 +msgid "GitHub" +msgstr "" + +#: inc/options/common/footer.php:51 +#: inc/options/common/footer.php:52 +msgid "Forums" +msgstr "" + +#: inc/options/common/footer.php:54 +#: inc/options/common/footer.php:55 +msgid "Premium Support Services" +msgstr "" + +#: inc/options/common/footer.php:59 +msgid "Pro Features" +msgstr "" + +#: inc/options/common/footer.php:78 +#: inc/options/common/footer.php:79 +msgid "WPML Extension" +msgstr "" + +#: inc/options/common/footer.php:91 +msgid "Learn more about Pro!" +msgstr "" + +#: inc/options/common/footer.php:96 +msgid "Follow Us" +msgstr "" + +#: inc/options/common/footer.php:97 +#: inc/options/common/footer.php:98 +msgid "W3 Edge" +msgstr "" + +#: inc/options/common/top_nav_bar.php:56 +#: UserExperience_GeneralPage_View.php:16 +#: UserExperience_Plugin_Admin.php:24 +#: UserExperience_Plugin_Admin.php:25 +#: Util_PageUrls.php:939 +msgid "User Experience" +msgstr "" + +#: inc/options/common/top_nav_bar.php:70 +#: inc/options/general.php:984 #: PageSpeed_Page_View.php:23 #: Root_AdminMenu.php:119 #: Root_AdminMenu.php:120 +#: Util_PageUrls.php:936 +#: Util_Ui.php:1600 msgid "Google PageSpeed" msgstr "" -#: inc/options/common/header.php:146 -#: inc/options/general.php:872 -msgid "Miscellaneous" +#: inc/options/common/top_nav_bar.php:74 +#: Root_AdminMenu.php:131 +#: Root_AdminMenu.php:132 +#: SetupGuide_Plugin_Admin.php:931 +#: Util_PageUrls.php:947 +msgid "Setup Guide" msgstr "" -#: inc/options/common/header.php:150 -#: inc/options/general.php:1000 -msgid "Debug" +#: inc/options/common/top_nav_bar.php:80 +#: Root_AdminMenu.php:137 +#: Root_AdminMenu.php:138 +#: Util_PageUrls.php:966 +msgid "About" msgstr "" -#: inc/options/common/header.php:154 -#: inc/options/general.php:1118 -msgid "Import / Export Settings" +#: inc/options/common/top_nav_bar.php:88 +#: Root_AdminMenu.php:125 +#: Root_AdminMenu.php:126 +#: Util_PageUrls.php:944 +msgid "Install" msgstr "" -#: inc/options/common/header.php:189 -msgid "Mirrors" +#: inc/options/common/top_nav_bar.php:92 +msgid "Compatibility Test" msgstr "" -#: inc/options/common/header.php:191 -#: inc/options/pgcache.php:215 -msgid "Cache Preload" +#: inc/options/common/top_nav_bar.php:132 +#: inc/options/common/top_nav_bar.php:133 +#: inc/options/dashboard.php:72 +#: Root_AdminMenu.php:43 +#: Root_AdminMenu.php:44 +#: Util_PageUrls.php:884 +#: Util_Ui.php:1868 +msgid "Dashboard" msgstr "" -#: inc/options/common/header.php:192 -msgid "Purge Policy" +#: inc/options/common/top_nav_bar.php:180 +#: inc/options/common/top_nav_bar.php:181 +msgid "Info" msgstr "" -#: inc/options/common/header.php:201 -#: inc/options/common/header.php:276 -#: inc/options/common/header.php:287 -#: inc/options/common/header.php:297 -#: inc/options/common/header.php:355 -msgid "Jump to: " -msgstr "" - -#: inc/options/common/header.php:216 -#: inc/options/common/header.php:335 -#: inc/options/minify.php:171 -msgid "eXtensible Markup Language" -msgstr "" - -#. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/common/header.php:232 -#: inc/options/minify.php:259 -msgid "%1$sJS%2$s" -msgstr "" - -#. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/common/header.php:252 -#: inc/options/minify.php:611 -msgid "%1$sCSS%2$s" -msgstr "" - -#: inc/options/common/header.php:346 -msgid "Media" -msgstr "" - -#: inc/options/common/header.php:368 -#: inc/options/install.php:11 -msgid "Initial Installation" -msgstr "" - -#: inc/options/common/header.php:370 -msgid "Rewrite Rules" -msgstr "" - -#: inc/options/common/header.php:373 -#: inc/options/install.php:282 -msgid "Other" -msgstr "" - -#: inc/options/common/header.php:375 -#: inc/options/install.php:291 -msgid "Services" -msgstr "" - -#. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/common/header.php:381 -#: inc/options/install.php:306 -msgid "%1$sPHP%2$s Modules" +#: inc/options/common/top_nav_bar.php:207 +#: Licensing_Plugin_Admin.php:58 +msgid "Upgrade" msgstr "" #. translators: 3 HTML strong tag indicating W3TC version, 4 closing HTML p tag. @@ -7426,121 +7517,61 @@ msgstr "" msgid "%1$sThe plugin is currently %2$s in %3$s mode.%4$s" msgstr "" -#: inc/options/dashboard.php:50 -msgid "Perform a" -msgstr "" - -#: inc/options/dashboard.php:51 -msgid "compatibility check" -msgstr "" - -#: inc/options/dashboard.php:64 -msgid "empty all caches" -msgstr "" - -#: inc/options/dashboard.php:64 -msgid "at once or" -msgstr "" - -#: inc/options/dashboard.php:65 -msgid "empty only the memcached cache(s)" -msgstr "" - -#: inc/options/dashboard.php:65 -#: inc/options/dashboard.php:66 -#: inc/options/dashboard.php:67 -#: inc/options/dashboard.php:69 -#: inc/options/dashboard.php:73 -msgid "or" -msgstr "" - -#: inc/options/dashboard.php:66 -msgid "empty only the opcode cache" -msgstr "" - -#: inc/options/dashboard.php:67 -msgid "empty only the disk cache(s)" -msgstr "" - -#: inc/options/dashboard.php:69 -msgid "purge CDN completely" -msgstr "" - -#: inc/options/dashboard.php:71 -msgid "update Media Query String" -msgstr "" - -#: inc/options/dashboard.php:95 -#: Root_AdminMenu.php:43 -#: Root_AdminMenu.php:44 -msgid "Dashboard" +#: inc/options/dashboard.php:48 +msgid "Flush caches with " msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/dashboard.php:101 +#: inc/options/dashboard.php:78 msgid "Thanks for choosing W3TC as your Web Performance Optimization (%1$sWPO%2$s) framework!" msgstr "" -#: inc/options/dashboard.php:105 +#: inc/options/dashboard.php:82 msgid "Web Performance Optimization" msgstr "" #. translators: 1 Database cache engine name, 2 HTML span indicating DB cache enabled/disabled. -#: inc/options/dbcache.php:16 +#: inc/options/dbcache.php:15 msgid "Database caching via %1$s is currently %2$s." msgstr "" -#: inc/options/dbcache.php:32 -msgid "To rebuild the database cache use the" -msgstr "" - -#: inc/options/dbcache.php:45 -#: inc/options/minify.php:50 -#: inc/options/objectcache.php:46 -msgid "empty cache" -msgstr "" - -#: inc/options/dbcache.php:46 -msgid "operation." -msgstr "" - -#: inc/options/dbcache.php:57 +#: inc/options/dbcache.php:39 msgid "Enabling this option is recommended to maintain default WordPress behavior." msgstr "" #. translators: 3 closing HTML acronym tag, 4 closing HTML a tag. -#: inc/options/dbcache.php:104 +#: inc/options/dbcache.php:85 msgid "Always ignore the specified pages / directories. Supports regular expressions (See %1$s%2$sFAQ%3$s%4$s)." msgstr "" -#: inc/options/dbcache.php:131 +#: inc/options/dbcache.php:112 msgid "Do not cache queries that contain these terms. Any entered prefix (set in wp-config.php) will be replaced with current database prefix (default: wp_). Query stems can be identified using debug mode." msgstr "" -#: inc/options/dbcache.php:139 +#: inc/options/dbcache.php:120 msgid "Do not cache queries that contain these words or regular expressions." msgstr "" -#: inc/options/dbcache.php:147 +#: inc/options/dbcache.php:128 msgid "Disable caching once specified constants defined." msgstr "" -#. translators: 1 HTML input button to buy plugin. -#: inc/options/edd/buy.php:14 +#. translators: 1 HTML a link to buy plugin. +#: inc/options/edd/buy.php:20 msgid "Unlock more speed, %1$s now!" msgstr "" -#: inc/options/edd/buy.php:18 -#: UsageStatistics_Page_View_Free.php:18 +#: inc/options/edd/buy.php:24 +#: UsageStatistics_Page_View_Free.php:17 msgid "upgrade" msgstr "" #. translators: 1 HTML a tag to W3TC licencing page. -#: inc/options/edd/buy.php:36 +#: inc/options/edd/buy.php:42 msgid "Please enter the license key you received after successful checkout %1$s." msgstr "" -#: inc/options/edd/buy.php:40 +#: inc/options/edd/buy.php:46 #: PageSpeed_Instructions.php:258 #: PageSpeed_Instructions.php:483 #: PageSpeed_Page.php:113 @@ -7622,484 +7653,559 @@ msgstr "" msgid "Visit extension site" msgstr "" -#. translators: 1 HTML span tag indicating plugin enabled/disabled. -#: inc/options/general.php:22 -msgid "The plugin is currently %1$s If an option is disabled it means that either your current installation is not compatible or software installation is required." -msgstr "" - -#: inc/options/general.php:41 +#: inc/options/general.php:30 msgid "Preview mode:" msgstr "" -#: inc/options/general.php:56 +#: inc/options/general.php:45 msgid "Disable" msgstr "" -#: inc/options/general.php:60 +#: inc/options/general.php:49 msgid "Deploy" msgstr "" #. translators: 1 HTML input submit to preview changes. -#: inc/options/general.php:79 +#: inc/options/general.php:68 msgid "To preview any changed settings (without deploying): %1$s" msgstr "" -#: inc/options/general.php:100 +#: inc/options/general.php:89 msgid "Use preview mode to test configuration scenarios prior to releasing them (deploy) on the actual site. Preview mode remains active even after deploying settings until the feature is disabled." msgstr "" -#: inc/options/general.php:113 -msgid "Enable page caching to decrease the response time of the site." +#: inc/options/general.php:99 +msgid "" +"Page cache is a technique used to speed up the performance of a website by storing a copy of the \n" +"\t\t\t\t\tgenerated HTML page in the server's memory or disk, and then serving that copy to subsequent \n" +"\t\t\t\t\tvisitors instead of generating the page from scratch each time. This can result in significant \n" +"\t\t\t\t\tspeed improvements for websites with high traffic or dynamic content." msgstr "" -#: inc/options/general.php:122 +#: inc/options/general.php:120 msgid "Caching pages will reduce the response time of your site and increase the scale of your web server." msgstr "" -#: inc/options/general.php:131 -#: SetupGuide_Plugin_Admin.php:910 +#: inc/options/general.php:129 +#: SetupGuide_Plugin_Admin.php:971 msgid "Disk: Basic" msgstr "" -#: inc/options/general.php:135 -#: SetupGuide_Plugin_Admin.php:911 +#: inc/options/general.php:133 +#: SetupGuide_Plugin_Admin.php:972 msgid "Disk: Enhanced" msgstr "" -#: inc/options/general.php:140 -#: SystemOpCache_GeneralPage_View.php:29 -#: Util_Ui.php:1016 +#: inc/options/general.php:138 +#: SystemOpCache_GeneralPage_View.php:43 +#: Util_Ui.php:1213 msgid "Opcode: Alternative PHP Cache (APC / APCu)" msgstr "" -#: inc/options/general.php:145 -#: Util_Ui.php:1021 +#: inc/options/general.php:143 +#: Util_Ui.php:1218 msgid "Opcode: eAccelerator" msgstr "" -#: inc/options/general.php:150 -#: Util_Ui.php:1026 +#: inc/options/general.php:148 +#: Util_Ui.php:1223 msgid "Opcode: XCache" msgstr "" -#: inc/options/general.php:155 -#: Util_Ui.php:1031 +#: inc/options/general.php:153 +#: Util_Ui.php:1228 msgid "Opcode: WinCache" msgstr "" -#: inc/options/general.php:160 +#: inc/options/general.php:158 #: UsageStatistics_Page_View.php:405 -#: Util_Ui.php:1036 +#: Util_Ui.php:1233 msgid "Memcached" msgstr "" -#: inc/options/general.php:165 +#: inc/options/general.php:163 msgid "Nginx + Memcached" msgstr "" -#: inc/options/general.php:165 +#: inc/options/general.php:163 msgid " (available after upgrade)" msgstr "" -#: inc/options/general.php:170 +#: inc/options/general.php:168 #: UsageStatistics_Page_View.php:434 -#: Util_Ui.php:1041 +#: Util_Ui.php:1238 msgid "Redis" msgstr "" -#: inc/options/general.php:175 +#: inc/options/general.php:173 msgid "Shared Server (disk enhanced is best):" msgstr "" -#: inc/options/general.php:176 -#: Util_Ui.php:1054 +#: inc/options/general.php:174 +#: Util_Ui.php:1250 msgid "Dedicated / Virtual Server:" msgstr "" -#: inc/options/general.php:177 -#: Util_Ui.php:1055 +#: inc/options/general.php:175 +#: Util_Ui.php:1251 msgid "Multiple Servers:" msgstr "" -#. translators: 3 HTML acronym for Hypertext Markup Language (HTML). -#: inc/options/general.php:206 -msgid "Reduce load time by decreasing the size and number of %1$s and %2$s files. Automatically remove unnecessary data from %1$s, %2$s, feed, page and post %3$s." -msgstr "" - -#: inc/options/general.php:207 -#: PageSpeed_Instructions.php:68 -#: PageSpeed_Instructions.php:85 -#: PageSpeed_Instructions.php:357 -msgid "CSS" -msgstr "" - -#: inc/options/general.php:208 -#: PageSpeed_Instructions.php:69 -#: PageSpeed_Instructions.php:86 -#: PageSpeed_Instructions.php:358 -msgid "JS" -msgstr "" - -#: inc/options/general.php:209 -msgid "HTML" +#: inc/options/general.php:187 +msgid "" +"Minification is a technique used to reduce the file size of HTML, CSS, and JavaScript \n" +"\t\t\t\t\tfiles by removing unnecessary characters such as whitespace, comments, and line breaks. \n" +"\t\t\t\t\tThis process can significantly improve the load times of web pages by reducing the amount \n" +"\t\t\t\t\tof data that needs to be downloaded by the user's browser." msgstr "" #. translators: 5 opening HTML acronym tag, 6 closing HTML acronym tag. -#: inc/options/general.php:227 +#: inc/options/general.php:213 msgid "Minification can decrease file size of %1$sHTML%2$s, %3$sCSS%4$s, %5$sJS%6$s and feeds respectively by ~10%% on average." msgstr "" -#: inc/options/general.php:245 +#: inc/options/general.php:231 msgid "Minify frequently asked questions" msgstr "" -#: inc/options/general.php:245 -#: inc/options/general.php:264 -#: inc/options/general.php:273 -#: inc/options/general.php:290 +#: inc/options/general.php:231 +#: inc/options/general.php:250 +#: inc/options/general.php:259 +#: inc/options/general.php:276 msgid "Learn more" msgstr "" -#: inc/options/general.php:256 +#: inc/options/general.php:242 msgid "Auto" msgstr "" -#: inc/options/general.php:257 +#: inc/options/general.php:243 msgid "Manual" msgstr "" -#: inc/options/general.php:259 +#: inc/options/general.php:245 msgid "Select manual mode to use fields on the minify settings tab to specify files to be minified, otherwise files will be minified automatically." msgstr "" -#: inc/options/general.php:264 +#: inc/options/general.php:250 msgid "How to use manual minify" msgstr "" -#: inc/options/general.php:273 +#: inc/options/general.php:259 msgid "Choosing a minification method" msgstr "" -#: inc/options/general.php:283 -#: inc/options/general.php:313 +#: inc/options/general.php:269 +#: inc/options/general.php:299 msgid "Minify (default)" msgstr "" -#: inc/options/general.php:286 +#: inc/options/general.php:272 msgid "HTML Tidy" msgstr "" -#: inc/options/general.php:290 +#: inc/options/general.php:276 msgid "How to use minify HTML" msgstr "" -#: inc/options/general.php:300 +#: inc/options/general.php:286 msgid "JSMin (default)" msgstr "" -#: inc/options/general.php:301 +#: inc/options/general.php:287 msgid "Google Closure Compiler (Web Service)" msgstr "" -#: inc/options/general.php:302 +#: inc/options/general.php:288 msgid "Google Closure Compiler (Local Java)" msgstr "" -#: inc/options/general.php:303 +#: inc/options/general.php:289 msgid "Narcissus" msgstr "" -#: inc/options/general.php:304 -#: inc/options/general.php:319 +#: inc/options/general.php:290 +#: inc/options/general.php:305 msgid "YUI Compressor" msgstr "" -#: inc/options/general.php:315 +#: inc/options/general.php:301 msgid "CSS Tidy" msgstr "" -#: inc/options/general.php:318 +#: inc/options/general.php:304 msgid "YUI Compressor (PHP)" msgstr "" -#: inc/options/general.php:345 -msgid "Enable database caching to reduce post, page and feed creation time." +#: inc/options/general.php:320 +msgid "" +"Enable this setting to utilize the power of caching your WordPress site's database queries. \n" +"\t\t\t\t\tBy storing frequently accessed database queries in memory, the database cache reduces the need for \n" +"\t\t\t\t\trepetitive database interactions, resulting in faster page load times. This feature is particularly \n" +"\t\t\t\t\tbeneficial for websites with heavy database usage, improving overall performance and delivering a smoother \n" +"\t\t\t\t\tuser experience." msgstr "" -#: inc/options/general.php:354 +#: inc/options/general.php:342 msgid "Caching database objects decreases the response time of your site. Best used if object caching is not possible." msgstr "" -#: inc/options/general.php:382 -msgid "Enable object caching to further reduce execution time for common operations." +#: inc/options/general.php:358 +msgid "" +"Enable this option to utilize an object cache mechanism, which significantly enhances the performance \n" +"\t\t\t\t\tof your WordPress website. Object caching stores frequently accessed database queries and complex data \n" +"\t\t\t\t\tstructures in memory, reducing the need to retrieve them from the database repeatedly. By doing so, it \n" +"\t\t\t\t\tminimizes the processing time required to generate dynamic content, resulting in faster page loading times \n" +"\t\t\t\t\tand improved overall site speed. Enabling object cache is particularly beneficial for websites with heavy \n" +"\t\t\t\t\tdatabase usage or high traffic volumes, as it helps alleviate the strain on the server by efficiently \n" +"\t\t\t\t\tserving cached data." +msgstr "" + +#: inc/options/general.php:373 +#: SetupGuide_Plugin_Admin.php:1282 +msgid "Object Cache is disabled via filter." msgstr "" #. translators: 3 closing HTML acronym tag, 4 closing HTML a tag. -#: inc/options/general.php:395 +#: inc/options/general.php:386 msgid "Object caching greatly increases performance for highly dynamic sites that use the %1$sObject Cache %2$sAPI%3$s%4$s." msgstr "" +#: inc/options/general.php:419 +msgid "" +"Enabling browser caching will instruct visitors' web browsers to store static files from your WordPress \n" +"\t\t\t\t\twebsite, such as images, CSS, and JavaScript files, locally on their devices. By doing so, subsequent \n" +"\t\t\t\t\tvisits to your site will retrieve these cached files from the browser's storage, reducing the need \n" +"\t\t\t\t\tfor repeated downloads. This results in faster page loading times and a smoother browsing experience \n" +"\t\t\t\t\tfor your visitors, ultimately improving the overall speed and performance of your WordPress website." +msgstr "" + #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/general.php:449 +#: inc/options/general.php:444 msgid "Enable %1$sHTTP%2$s compression and add headers to reduce server load and decrease file load time." msgstr "" -#. translators: 3 opening HTML a tag to W3TC Browsercache admin page, 4 closing HTML a tag. -#: inc/options/general.php:483 -msgid "A reverse proxy adds scale to an server by handling requests before WordPress does. Purge settings are set on the %1$sPage Cache settings%2$s page and %3$sBrowser Cache settings%4$s are set on the browser cache settings page." +#: inc/options/general.php:469 +msgid "" +"A reverse proxy is a server that sits between a client and a web server, acting as an intermediary \n" +"\t\t\t\t\tfor requests. It retrieves resources on behalf of the client from the server, and then returns \n" +"\t\t\t\t\tthe response to the client. By utilizing a reverse proxy, such as Varnish or Nginx, in conjunction \n" +"\t\t\t\t\twith W3 Total Cache, you can significantly enhance the performance of your WordPress website by \n" +"\t\t\t\t\tcaching and serving static content directly from the reverse proxy server, reducing the load on \n" +"\t\t\t\t\tyour WordPress server and improving response times for visitors." msgstr "" #. translators: 3 opening HTML acronym tag, 4 closing HTML acronym tag. -#: inc/options/general.php:517 +#: inc/options/general.php:501 msgid "Specify the IP addresses of your varnish instances above. The %1$sVCL%2$s's %3$sACL%4$s must allow this request." msgstr "" -#: inc/options/general.php:521 +#: inc/options/general.php:505 msgid "Varnish Configuration Language" msgstr "" -#: inc/options/general.php:523 +#: inc/options/general.php:507 msgid "Access Control List" msgstr "" -#: inc/options/general.php:542 -msgid "Purge cache" -msgstr "" - -#: inc/options/general.php:553 -msgid "Allows policy management to be shared between a dynamic pool of servers. For example, each server in a pool to use opcode caching (which is not a shared resource) and purging is then syncronized between any number of servers in real-time; each server therefore behaves identically even though resources are not shared." +#: inc/options/general.php:528 +msgid "" +"Allows policy management to be shared between a dynamic pool of servers. For example, each \n" +"\t\t\t\t\t\tserver in a pool to use opcode caching (which is not a shared resource) and purging is \n" +"\t\t\t\t\t\tthen syncronized between any number of servers in real-time; each server therefore behaves \n" +"\t\t\t\t\t\tidentically even though resources are not shared." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/general.php:574 +#: inc/options/general.php:559 msgid "Specify the Amazon %1$sSNS%2$s service endpoint hostname. If empty, then default \"sns.us-east-1.amazonaws.com\" will be used." msgstr "" -#: inc/options/general.php:578 -#: inc/options/general.php:665 +#: inc/options/general.php:563 +#: inc/options/general.php:650 msgid "Simple Notification Service" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/general.php:603 +#: inc/options/general.php:588 msgid "Specify the %1$sAPI%2$s Key." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/general.php:632 +#: inc/options/general.php:617 msgid "Specify the %1$sAPI%2$s secret." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/general.php:661 +#: inc/options/general.php:646 msgid "Specify the %1$sSNS%2$s topic." msgstr "" -#. translators: 1 Request response code, 2 Error message. -#: inc/options/general.php:705 -msgid "Response Code: %1$s
        Response Message: %2$s" +#: inc/options/general.php:677 +#: Util_Ui.php:1527 +msgid "Licensing" msgstr "" -#: inc/options/general.php:715 -#: inc/options/general.php:729 -#: inc/options/general.php:770 -msgid "Google PageSpeed Insights API authorization failed." +#: inc/options/general.php:678 +msgid "" +"The plugin license is a key that unlocks advanced features and support for the W3 Total Cache \n" +"\t\t\t\t\t\tWordPress plugin. By activating the license, users gain access to enhanced caching mechanisms, \n" +"\t\t\t\t\t\toptimization tools, enabling them to significantly speed up their \n" +"\t\t\t\t\t\tWordPress websites and improve overall performance." msgstr "" -#: inc/options/general.php:724 -msgid "Google PageSpeed Insights API authorization successfull." -msgstr "" - -#: inc/options/general.php:743 -msgid "Google PageSpeed Insights API authorization successfully reset." -msgstr "" - -#: inc/options/general.php:751 -msgid "Unique site ID missing for authorize request!" -msgstr "" - -#: inc/options/general.php:753 -msgid "Authorize URL missing for authorize request!" -msgstr "" - -#: inc/options/general.php:755 -msgid "Return URL missing for authorize request!" -msgstr "" - -#: inc/options/general.php:757 -msgid "Failed to process authorize request!" -msgstr "" - -#: inc/options/general.php:761 -msgid "No authorize code returned to W3-API from Google!" -msgstr "" - -#: inc/options/general.php:763 -msgid "No W3Key return to W3-API from Google!" -msgstr "" - -#: inc/options/general.php:765 -msgid "No W3-API matching record found during Google authorization return processing!" -msgstr "" - -#: inc/options/general.php:788 -msgid "Valid" -msgstr "" - -#: inc/options/general.php:805 -msgid "Allow W3 Total Cache to connect to the PageSpeed Insights API on your behalf." -msgstr "" - -#: inc/options/general.php:815 -msgid "Enable Google PageSpeed dashboard widget" -msgstr "" - -#: inc/options/general.php:816 -msgid "Display Google PageSpeed results on the WordPress dashboard." -msgstr "" - -#: inc/options/general.php:841 +#: inc/options/general.php:697 msgid "Verify license key" msgstr "" -#. translators: 1 HTML a tag to trigger W3TC licence upgrade. -#: inc/options/general.php:848 +#. translators: 1 HTML a tag to W3TC marketing page. +#: inc/options/general.php:704 msgid "Please enter the license key provided after %1$s." msgstr "" -#: inc/options/general.php:852 +#: inc/options/general.php:708 msgid "upgrading" msgstr "" -#: inc/options/general.php:878 +#: inc/options/general.php:730 +#: Util_Ui.php:1592 +msgid "Miscellaneous" +msgstr "" + +#: inc/options/general.php:731 +msgid "" +"Miscellaneous settings provide additional options and configurations to optimize and speed up \n" +"\t\t\t\t\tyour WordPress website." +msgstr "" + +#: inc/options/general.php:746 msgid "Only one configuration file for whole network will be created and used. Recommended if all sites have the same configuration." msgstr "" -#: inc/options/general.php:887 +#: inc/options/general.php:755 msgid "If empty the default path will be used.." msgstr "" #. translators: 1 opening HTML a tag to W3TC install admin page. -#: inc/options/general.php:900 +#: inc/options/general.php:768 msgid "Notify of server configuration errors, if this option is disabled, the server configuration for active settings can be found on the %1$sinstall%2$s tab." msgstr "" -#: inc/options/general.php:920 +#: inc/options/general.php:788 msgid "Enable file locking" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/general.php:926 +#: inc/options/general.php:794 msgid "Not recommended for %1$sNFS%2$s systems." msgstr "" -#: inc/options/general.php:930 -#: inc/options/general.php:956 +#: inc/options/general.php:798 +#: inc/options/general.php:824 msgid "Network File System" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/general.php:952 +#: inc/options/general.php:820 msgid "Optimize disk enhanced page and minify disk caching for %1$sNFS%2$s" msgstr "" -#: inc/options/general.php:967 +#: inc/options/general.php:835 msgid "Try this option if your hosting environment uses a network based file system for a possible performance improvement." msgstr "" -#: inc/options/general.php:975 +#: inc/options/general.php:843 msgid "Fix document root path" msgstr "" #. translators: 1: WordPress ABSPATH value, 2: Server document root value. -#: inc/options/general.php:979 +#: inc/options/general.php:847 msgid "Fix incorrect server document root path. Uses the WordPress ABSPATH (\"%1$s\") in place of the current server document root (\"%2$s\")." msgstr "" -#: inc/options/general.php:990 +#: inc/options/general.php:858 msgid "Anonymously track usage to improve product quality" msgstr "" +#: inc/options/general.php:869 +#: Util_Ui.php:1596 +msgid "Debug" +msgstr "" + #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/general.php:1006 +#: inc/options/general.php:873 msgid "Detailed information about each cache will be appended in (publicly available) %1$sHTML%2$s comments in the page's source code. Performance in this mode will not be optimal, use sparingly and disable when not in use." msgstr "" -#: inc/options/general.php:1024 +#: inc/options/general.php:893 msgid "Debug mode:" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/general.php:1045 +#: inc/options/general.php:914 msgid "If selected, detailed caching information will appear at the end of each page in a %1$sHTML%2$s comment. View a page's source code to review." msgstr "" -#: inc/options/general.php:1065 +#: inc/options/general.php:934 msgid "Purge Logs:" msgstr "" -#: inc/options/general.php:1072 +#: inc/options/general.php:941 msgid "Page Cache Purge Log" msgstr "" -#: inc/options/general.php:1073 -#: inc/options/general.php:1082 -#: inc/options/general.php:1091 +#: inc/options/general.php:942 +#: inc/options/general.php:951 +#: inc/options/general.php:960 msgid "view log" msgstr "" -#: inc/options/general.php:1081 +#: inc/options/general.php:950 msgid "Database Cache Purge Log" msgstr "" -#: inc/options/general.php:1090 +#: inc/options/general.php:959 msgid "Object Cache Purge Log" msgstr "" -#: inc/options/general.php:1098 +#: inc/options/general.php:967 msgid "Purge Logs provide information on when your cache has been purged and what triggered it." msgstr "" -#: inc/options/general.php:1100 +#: inc/options/general.php:969 msgid "Sometimes, you'll encounter a complex issue involving your cache being purged for an unknown reason. The Purge Logs functionality can help you easily resolve those issues." msgstr "" -#: inc/options/general.php:1133 +#: inc/options/general.php:985 +msgid "" +"The PageSpeed Tool is a powerful feature that can be used to help optimize and enhance the performance \n" +"\t\t\t\t\tof your WordPress website. By leveraging the insights and recommendations provided by Google's \n" +"\t\t\t\t\tPageSpeed Insights API, this tool analyzes your website's speed and suggests improvements to boost \n" +"\t\t\t\t\tits performance. By implementing the recommended optimizations, such as minimizing CSS and JavaScript, \n" +"\t\t\t\t\toptimizing images, and enabling browser caching, you can significantly accelerate your WordPress site, \n" +"\t\t\t\t\tresulting in faster loading times and an improved user experience." +msgstr "" + +#: inc/options/general.php:997 +msgid "PageSpeed Tool" +msgstr "" + +#. translators: 1 Request response code, 2 Error message. +#: inc/options/general.php:1020 +msgid "Response Code: %1$s
        Response Message: %2$s" +msgstr "" + +#: inc/options/general.php:1030 +#: inc/options/general.php:1044 +#: inc/options/general.php:1085 +msgid "Google PageSpeed Insights API authorization failed." +msgstr "" + +#: inc/options/general.php:1039 +msgid "Google PageSpeed Insights API authorization successfull." +msgstr "" + +#: inc/options/general.php:1058 +msgid "Google PageSpeed Insights API authorization successfully reset." +msgstr "" + +#: inc/options/general.php:1066 +msgid "Unique site ID missing for authorize request!" +msgstr "" + +#: inc/options/general.php:1068 +msgid "Authorize URL missing for authorize request!" +msgstr "" + +#: inc/options/general.php:1070 +msgid "Return URL missing for authorize request!" +msgstr "" + +#: inc/options/general.php:1072 +msgid "Failed to process authorize request!" +msgstr "" + +#: inc/options/general.php:1076 +msgid "No authorize code returned to W3-API from Google!" +msgstr "" + +#: inc/options/general.php:1078 +msgid "No W3Key return to W3-API from Google!" +msgstr "" + +#: inc/options/general.php:1080 +msgid "No W3-API matching record found during Google authorization return processing!" +msgstr "" + +#: inc/options/general.php:1103 +msgid "Valid" +msgstr "" + +#: inc/options/general.php:1120 +msgid "Allow W3 Total Cache to connect to the PageSpeed Insights API on your behalf." +msgstr "" + +#: inc/options/general.php:1130 +msgid "Enable Google PageSpeed dashboard widget" +msgstr "" + +#: inc/options/general.php:1131 +msgid "Display Google PageSpeed results on the WordPress dashboard." +msgstr "" + +#: inc/options/general.php:1146 +#: Util_Ui.php:1604 +msgid "Import / Export Settings" +msgstr "" + +#: inc/options/general.php:1147 +msgid "" +"This tool allows users to easily transfer their W3 Total Cache plugin settings between different \n" +"\t\t\t\t\tWordPress installations by exporting the current configuration as a file and importing it on \n" +"\t\t\t\t\tanother site, ensuring consistent caching and performance optimizations across multiple websites." +msgstr "" + +#: inc/options/general.php:1169 msgid "Import configuration:" msgstr "" -#: inc/options/general.php:1136 +#: inc/options/general.php:1172 msgid "Upload" msgstr "" -#: inc/options/general.php:1137 +#: inc/options/general.php:1173 msgid "Upload and replace the active settings file." msgstr "" -#: inc/options/general.php:1141 +#: inc/options/general.php:1177 msgid "Export configuration:" msgstr "" -#: inc/options/general.php:1143 +#: inc/options/general.php:1179 msgid "Download" msgstr "" -#: inc/options/general.php:1144 +#: inc/options/general.php:1180 msgid "Download the active settings file." msgstr "" -#: inc/options/general.php:1148 +#: inc/options/general.php:1184 msgid "Reset configuration:" msgstr "" -#: inc/options/general.php:1150 +#: inc/options/general.php:1186 msgid "Restore Default Settings" msgstr "" -#: inc/options/general.php:1151 +#: inc/options/general.php:1187 msgid "Revert all settings to the defaults. Any settings staged in preview mode will not be modified." msgstr "" +#: inc/options/install.php:11 +#: Util_Ui.php:1823 +msgid "Initial Installation" +msgstr "" + #: inc/options/install.php:14 msgid "Set the permissions of wp-content/ back to 755, e.g.:" msgstr "" @@ -8153,6 +8259,16 @@ msgstr "" msgid "Rewrite Rules (based on active settings)" msgstr "" +#: inc/options/install.php:282 +#: Util_Ui.php:1828 +msgid "Other" +msgstr "" + +#: inc/options/install.php:291 +#: Util_Ui.php:1830 +msgid "Services" +msgstr "" + #: inc/options/install.php:294 msgid "Server Preparation" msgstr "" @@ -8161,6 +8277,12 @@ msgstr "" msgid "Install Memcached Deamon" msgstr "" +#. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. +#: inc/options/install.php:306 +#: Util_Ui.php:1836 +msgid "%1$sPHP%2$s Modules" +msgstr "" + #: inc/options/install.php:323 msgid "Install Memcached Module" msgstr "" @@ -8213,245 +8335,258 @@ msgstr "" msgid "Minify via %1$s is currently %2$s." msgstr "" -#. translators: 1 HTML submit button to rebuild minify cache. -#: inc/options/minify.php:46 -msgid "To rebuild the minify cache use the %1$s operation." -msgstr "" - -#: inc/options/minify.php:64 +#: inc/options/minify.php:43 msgid "Get minify hints using the" msgstr "" -#: inc/options/minify.php:65 +#: inc/options/minify.php:44 msgid "help" msgstr "" -#: inc/options/minify.php:66 +#: inc/options/minify.php:45 msgid "wizard." msgstr "" #. translators: %1 HTML input submit. -#: inc/options/minify.php:72 +#: inc/options/minify.php:51 msgid "%1$s to make existing file modifications visible to visitors with a primed cache." msgstr "" #. translators: 3 opening HTML acronym tag, 4 closing HTML acronym tag. -#: inc/options/minify.php:114 +#: inc/options/minify.php:93 msgid "If disabled, %1$sCSS%2$s and %3$sJS%4$s embeddings will use GET variables instead of \"fancy\" links." msgstr "" -#: inc/options/minify.php:136 +#: inc/options/minify.php:115 msgid "Authenticated users will not receive minified pages if this option is enabled." msgstr "" -#: inc/options/minify.php:146 +#: inc/options/minify.php:125 msgid "Admin Notification" msgstr "" -#: inc/options/minify.php:147 +#: inc/options/minify.php:126 msgid "Email Notification" msgstr "" -#: inc/options/minify.php:148 +#: inc/options/minify.php:127 msgid "Both Admin & Email Notification" msgstr "" -#: inc/options/minify.php:150 +#: inc/options/minify.php:129 msgid "Notify when minify cache creation errors occur." msgstr "" +#: inc/options/minify.php:149 +#: Util_Ui.php:1661 +#: Util_Ui.php:1774 +msgid "eXtensible Markup Language" +msgstr "" + #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/minify.php:191 +#: inc/options/minify.php:169 msgid "%1$sHTML%2$s minify settings:" msgstr "" -#: inc/options/minify.php:233 +#: inc/options/minify.php:211 msgid "Do not remove comments that contain these terms." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/minify.php:277 +#: inc/options/minify.php:236 +#: Util_Ui.php:1677 +msgid "%1$sJS%2$s" +msgstr "" + +#. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. +#: inc/options/minify.php:254 msgid "%1$sJS%2$s minify settings:" msgstr "" -#: inc/options/minify.php:294 -#: inc/options/minify.php:652 +#: inc/options/minify.php:271 +#: inc/options/minify.php:628 msgid "Minify method:" msgstr "" -#: inc/options/minify.php:298 -#: inc/options/minify.php:656 +#: inc/options/minify.php:275 +#: inc/options/minify.php:632 msgid "Combine & Minify" msgstr "" -#: inc/options/minify.php:301 -#: inc/options/minify.php:659 +#: inc/options/minify.php:278 +#: inc/options/minify.php:635 msgid "Minify only" msgstr "" -#: inc/options/minify.php:304 -#: inc/options/minify.php:662 +#: inc/options/minify.php:281 +#: inc/options/minify.php:638 #: Minify_ConfigLabels.php:24 #: Minify_ConfigLabels.php:26 #: Minify_ConfigLabels.php:28 msgid "Combine only" msgstr "" -#: inc/options/minify.php:312 -#: inc/options/minify.php:669 +#: inc/options/minify.php:289 +#: inc/options/minify.php:645 msgid "Minify engine settings:" msgstr "" -#: inc/options/minify.php:314 +#: inc/options/minify.php:291 msgid "Operations in areas:" msgstr "" #. translators: 1 opening HTML span tag, 2 closing HTML span tag. -#: inc/options/minify.php:327 +#: inc/options/minify.php:304 msgid "Before %1$s</head>%2$s" msgstr "" -#: inc/options/minify.php:349 -#: inc/options/minify.php:368 -#: inc/options/minify.php:387 +#: inc/options/minify.php:326 +#: inc/options/minify.php:345 +#: inc/options/minify.php:364 msgid "Default (blocking)" msgstr "" -#: inc/options/minify.php:350 -#: inc/options/minify.php:369 -#: inc/options/minify.php:388 +#: inc/options/minify.php:327 +#: inc/options/minify.php:346 +#: inc/options/minify.php:365 msgid "Non-blocking using JS" msgstr "" -#: inc/options/minify.php:351 -#: inc/options/minify.php:370 -#: inc/options/minify.php:389 +#: inc/options/minify.php:328 +#: inc/options/minify.php:347 +#: inc/options/minify.php:366 msgid "Non-blocking using \"async\"" msgstr "" -#: inc/options/minify.php:352 -#: inc/options/minify.php:371 -#: inc/options/minify.php:390 +#: inc/options/minify.php:329 +#: inc/options/minify.php:348 +#: inc/options/minify.php:367 msgid "Non-blocking using \"defer\"" msgstr "" -#: inc/options/minify.php:354 -#: inc/options/minify.php:373 -#: inc/options/minify.php:391 +#: inc/options/minify.php:331 +#: inc/options/minify.php:350 +#: inc/options/minify.php:368 msgid "Non-blocking using \"extsrc\"" msgstr "" -#: inc/options/minify.php:355 -#: inc/options/minify.php:374 -#: inc/options/minify.php:392 +#: inc/options/minify.php:332 +#: inc/options/minify.php:351 +#: inc/options/minify.php:369 msgid "Non-blocking using \"asyncsrc\"" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/minify.php:440 +#: inc/options/minify.php:417 msgid "%1$sJS%2$s file management:" msgstr "" -#: inc/options/minify.php:473 +#: inc/options/minify.php:450 msgid "Files are minified by template. First select the theme to manage, then add scripts used in all templates to the \"All Templates\" group. Use the menu above to manage scripts unique to a specific template. If necessary drag & drop to resolve dependency issues (due to incorrect order)." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/minify.php:539 +#: inc/options/minify.php:516 msgid "No %1$sJS%2$s files added" msgstr "" -#: inc/options/minify.php:554 +#: inc/options/minify.php:531 msgid "Add a script" msgstr "" #. translators: 1 opening HTML acronym tag for HTTP (Hypertext Transfer Protocol), 2 closing HTML acronym tag. -#: inc/options/minify.php:568 -#: inc/options/minify.php:843 +#: inc/options/minify.php:545 +#: inc/options/minify.php:819 msgid "For better performance, send files to browser before they are requested when using the %1$sHTTP%2$s/2 protocol." msgstr "" #. translators: 1 HTML line break tag followed by opening HTML b tag, 2 closing HTML b tag. -#: inc/options/minify.php:586 +#: inc/options/minify.php:563 msgid " %1$sNot supported by \"Disk: Enhanced\" page cache method for Nginx%2$s" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/minify.php:630 +#: inc/options/minify.php:587 +#: Util_Ui.php:1697 +msgid "%1$sCSS%2$s" +msgstr "" + +#. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. +#: inc/options/minify.php:606 msgid "%1$sCSS%2$s minify settings:" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/minify.php:723 +#: inc/options/minify.php:699 msgid "%1$sCSS%2$s file management:" msgstr "" -#: inc/options/minify.php:756 +#: inc/options/minify.php:732 msgid "Files are minified by template. First select the theme to manage, then add style sheets used in all templates to the \"All Templates\" group. Use the menu above to manage style sheets unique to a specific template. If necessary drag & drop to resolve dependency issues (due to incorrect order)." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/minify.php:814 +#: inc/options/minify.php:790 msgid "No %1$sCSS%2$s files added" msgstr "" -#: inc/options/minify.php:829 +#: inc/options/minify.php:805 msgid "Add a style sheet" msgstr "" #. translators: 1 HTML line break tag, 2 opening HTML b tag, 3 closing HTML b tag. -#: inc/options/minify.php:861 +#: inc/options/minify.php:837 msgid " %1$s%2$sNot supported by \"Disk: Enhanced\" page cache method for Nginx%3$s" msgstr "" -#: inc/options/minify.php:900 +#: inc/options/minify.php:875 msgid "Specify the interval between download and update of external files in the minify cache. Hint: 6 hours is 21600 seconds. 12 hours is 43200 seconds. 24 hours is 86400 seconds." msgstr "" -#: inc/options/minify.php:923 +#: inc/options/minify.php:898 msgid "Always ignore the specified pages / directories. Use relative paths. Omit: protocol, hostname, leading forward slash and query strings." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/minify.php:936 +#: inc/options/minify.php:911 msgid "Always ignore the specified %1$sJS%2$s files. Use relative paths. Omit: protocol, hostname, leading forward slash and query strings." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/minify.php:963 +#: inc/options/minify.php:938 msgid "Always ignore the specified %1$sCSS%2$s files. Use relative paths. Omit: protocol, hostname, leading forward slash and query strings." msgstr "" -#: inc/options/minify.php:986 +#: inc/options/minify.php:961 msgid "Specify user agents that will never receive minified content." msgstr "" -#: inc/options/minify.php:994 +#: inc/options/minify.php:969 msgid "Specify external files/libraries that should be combined." msgstr "" -#: inc/options/minify.php:1000 +#: inc/options/minify.php:975 msgid "Use Regular Expressions for file name matching" msgstr "" -#: inc/options/minify.php:1001 +#: inc/options/minify.php:976 msgid "If external script file names vary, use regular expressions in the \"Include external files/libraries\" field to simplify matching." msgstr "" #. translators: 3 opening HTML a tag to W3TC Browsercache admin page, 4 closing HTML a tag. -#: inc/options/minify.php:1021 +#: inc/options/minify.php:995 msgid "Enable %1$sHTTP%2$s compression in the \"Cascading Style Sheets & JavaScript\" section on %3$sBrowser Cache%4$s Settings tab." msgstr "" #. translators: 3 opening HTML a tag to W3TC Browsercache admin, 4 closing HTML a tag. -#: inc/options/minify.php:1047 +#: inc/options/minify.php:1021 msgid "The %1$sTTL%2$s of page cache files is set via the \"Expires header lifetime\" field in the \"Cascading Style Sheets & JavaScript\" section on %3$sBrowser Cache%4$s Settings tab." msgstr "" -#: inc/options/minify.php:1051 -#: inc/options/pgcache.php:592 -#: inc/options/pgcache.php:594 -#: inc/options/pgcache.php:859 +#: inc/options/minify.php:1025 +#: inc/options/pgcache.php:565 +#: inc/options/pgcache.php:567 +#: inc/options/pgcache.php:831 msgid "Time to Live" msgstr "" @@ -8525,7 +8660,7 @@ msgid "All optimisations" msgstr "" #: inc/options/minify/csstidy2.php:23 -#: SetupGuide_Plugin_Admin.php:908 +#: SetupGuide_Plugin_Admin.php:969 msgid "None" msgstr "" @@ -8571,44 +8706,40 @@ msgid "symbols (set to 0 to disable)" msgstr "" #. translators: 1 HTML strong tag containing Objectcache Engine value, 2 HTML span tag containing Objectcache Engine enabled/disabled value. -#: inc/options/objectcache.php:16 -msgid "Object caching via %1$s is currently %2$s" +#: inc/options/objectcache.php:15 +msgid "Object caching via %1$s is currently %2$s." msgstr "" -#: inc/options/objectcache.php:33 -msgid "To rebuild the object cache use the" +#: inc/options/objectcache.php:20 +msgid " via filter" msgstr "" -#: inc/options/objectcache.php:47 -msgid " operation." -msgstr "" - -#: inc/options/objectcache.php:85 +#: inc/options/objectcache.php:67 msgid "Groups shared amongst sites in network mode." msgstr "" -#: inc/options/objectcache.php:93 +#: inc/options/objectcache.php:75 msgid "Groups that should not be cached." msgstr "" -#: inc/options/objectcache.php:99 +#: inc/options/objectcache.php:81 msgid "Enable caching for wp-admin requests" msgstr "" -#: inc/options/objectcache.php:100 +#: inc/options/objectcache.php:82 msgid "Enabling this option will increase wp-admin performance, but may cause side-effects" msgstr "" -#: inc/options/objectcache.php:105 +#: inc/options/objectcache.php:87 msgid "Store transients in database" msgstr "" -#: inc/options/objectcache.php:106 +#: inc/options/objectcache.php:88 msgid "Use that to store transients in database even when external cache is used. That allows transient values to survive object cache cleaning / expiration" msgstr "" #. translators: 1 opening HTML em tag, 2 closing HTML em tag. -#: inc/options/objectcache.php:118 +#: inc/options/objectcache.php:100 msgid "Enabling this option will increase load on server on certain actions but will guarantee that the Object Cache is always clean and contains latest changes. %1$sEnable if you are experiencing issues with options displaying wrong value/state (checkboxes etc).%2$2" msgstr "" @@ -8749,249 +8880,257 @@ msgid "Specify redis password" msgstr "" #. translators: 1 HTML strong tag containing PageCache Engine name, 2 HTML span tag containing PageCache Engine enabled/disabled. -#: inc/options/pgcache.php:16 +#: inc/options/pgcache.php:15 msgid "Page caching via %1$s is currently %2$s" msgstr "" -#. translators: 1 Nonce Field followed by submit HTML input to flush PageCache. -#: inc/options/pgcache.php:37 -msgid "To rebuild the page cache use the %1$s operation" -msgstr "" - -#: inc/options/pgcache.php:64 +#: inc/options/pgcache.php:40 msgid "For many blogs this is your most visited page, it is recommended that you cache it." msgstr "" -#: inc/options/pgcache.php:71 +#: inc/options/pgcache.php:47 msgid "By default the front page is cached when using static front page in reading settings." msgstr "" -#: inc/options/pgcache.php:78 +#: inc/options/pgcache.php:54 msgid "Even if using a feed proxy service enabling this option is still recommended." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/pgcache.php:89 +#: inc/options/pgcache.php:65 msgid "Cache %1$sSSL%2$s requests (uniquely) for improved performance." msgstr "" -#: inc/options/pgcache.php:93 +#: inc/options/pgcache.php:69 msgid "Secure Socket Layer" msgstr "" -#: inc/options/pgcache.php:118 +#: inc/options/pgcache.php:94 msgid "Search result (and similar) pages will be cached if enabled." msgstr "" -#: inc/options/pgcache.php:124 +#: inc/options/pgcache.php:100 msgid "Reduce server load by caching 404 pages. If the disk enhanced method of disk caching is used, 404 pages will be returned with a 200 response code. Use at your own risk." msgstr "" -#: inc/options/pgcache.php:130 +#: inc/options/pgcache.php:106 msgid "Unauthenticated users may view a cached version of the last authenticated user's view of a given page. Disabling this option is not recommended." msgstr "" -#: inc/options/pgcache.php:136 +#: inc/options/pgcache.php:112 msgid "Select user roles that should not receive cached pages:" msgstr "" -#: inc/options/pgcache.php:153 +#: inc/options/pgcache.php:128 +#: Util_Ui.php:1635 msgid "Aliases" msgstr "" -#: inc/options/pgcache.php:160 +#: inc/options/pgcache.php:135 msgid "Cache alias hostnames:" msgstr "" -#: inc/options/pgcache.php:163 +#: inc/options/pgcache.php:138 msgid "If the same WordPress content is accessed from different domains" msgstr "" #. translators: 1 opneing HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/pgcache.php:173 +#: inc/options/pgcache.php:148 msgid "Additional home %1$sURL%2$ss:" msgstr "" #. translators: 4 HTML line break tag, 5 HTML line break tag. -#: inc/options/pgcache.php:191 +#: inc/options/pgcache.php:166 msgid "Specify full home %1$sURL%2$ss of your mirrors so that plugin will flush it's cache when content is changed. For example:%3$s http://my-site.com%4$shttp://www.my-site.com%5$shttps://my-site.com" msgstr "" -#: inc/options/pgcache.php:228 +#: inc/options/pgcache.php:190 +#: Util_Ui.php:1636 +msgid "Cache Preload" +msgstr "" + +#: inc/options/pgcache.php:203 msgid "The number of seconds to wait before creating another set of cached pages." msgstr "" -#: inc/options/pgcache.php:237 +#: inc/options/pgcache.php:212 msgid "Limit the number of pages to create per batch. Fewer pages may be better for under-powered servers." msgstr "" #. translators: 3 opening HTML acronym tag, 4 closing HTML acronym tag. -#: inc/options/pgcache.php:252 +#: inc/options/pgcache.php:227 msgid "A %1$scompliant%2$s sitemap can be used to specify the pages to maintain in the primed cache. Pages will be cached according to the priorities specified in the %3$sXML%4$s file." msgstr "" -#: inc/options/pgcache.php:295 +#: inc/options/pgcache.php:269 msgid "Purge Policy: " msgstr "" -#: inc/options/pgcache.php:300 +#: inc/options/pgcache.php:274 msgid "Specify the pages and feeds to purge when posts are created, edited, or comments posted. The defaults are recommended because additional options may reduce server performance:" msgstr "" #. translators: 1 HTML line break tag. -#: inc/options/pgcache.php:357 +#: inc/options/pgcache.php:331 msgid "Specify number of pages that lists posts (archive etc) that should be purged on post updates etc, i.e example.com/ ... example.com/page/5. %1$s0 means all pages that lists posts are purged, i.e example.com/page/2 ... ." msgstr "" -#: inc/options/pgcache.php:377 +#: inc/options/pgcache.php:351 msgid "Specify additional pages to purge. Including parent page in path. Ex: parent/posts." msgstr "" -#: inc/options/pgcache.php:384 +#: inc/options/pgcache.php:358 msgid "Specify a regular expression that matches your sitemaps." msgstr "" #. translators: 3 opening HTML acronym tag, 4 closing HTML acronym tag. -#: inc/options/pgcache.php:398 +#: inc/options/pgcache.php:371 msgid "%1$sREST%2$s %3$sAPI%4$s" msgstr "" -#: inc/options/pgcache.php:402 -#: inc/options/pgcache.php:443 +#: inc/options/pgcache.php:375 +#: inc/options/pgcache.php:416 msgid "REpresentational State Transfer" msgstr "" -#: inc/options/pgcache.php:425 +#: inc/options/pgcache.php:398 msgid "Don't cache" msgstr "" -#: inc/options/pgcache.php:427 +#: inc/options/pgcache.php:400 msgid "Cache" msgstr "" -#: inc/options/pgcache.php:430 +#: inc/options/pgcache.php:403 msgid "If you're using the WordPress API make sure to use caching to scale performance." msgstr "" -#: inc/options/pgcache.php:432 +#: inc/options/pgcache.php:405 msgid "If you use WordPress as a backend for integrations, API caching may be for you. Similar to page caching, repeat requests will benefit by having significantly lower response times and consume fewer resources to deliver. If WordPress is not used as a backend, for additional security, the API can be disabled completely." msgstr "" #. translators: 3 opening HTML acronym tag, 4 closing HTML acronym tag. -#: inc/options/pgcache.php:439 +#: inc/options/pgcache.php:412 msgid "Disable %1$sREST%2$s %3$sAPI%4$s" msgstr "" #. translators: 3 opneing HTML acronym tag, 4 closing HTML acronym tag. -#: inc/options/pgcache.php:460 +#: inc/options/pgcache.php:433 msgid "Controls WordPress %1$sREST%2$s %3$sAPI%4$s functionality." msgstr "" -#: inc/options/pgcache.php:486 +#: inc/options/pgcache.php:459 msgid "Late initialization:" msgstr "" -#: inc/options/pgcache.php:490 +#: inc/options/pgcache.php:463 msgid "Enables support for WordPress functionality in fragment caching for the page caching engine. Use of this feature may increase response times." msgstr "" -#: inc/options/pgcache.php:494 +#: inc/options/pgcache.php:467 msgid "Late caching:" msgstr "" -#: inc/options/pgcache.php:498 +#: inc/options/pgcache.php:471 msgid "Overwrites key of page caching via custom filters by postponing entry extraction during the init action." msgstr "" -#: inc/options/pgcache.php:512 +#: inc/options/pgcache.php:485 msgid "Compatibility mode:" msgstr "" -#: inc/options/pgcache.php:515 +#: inc/options/pgcache.php:488 msgid "Decreases performance by ~20% at scale in exchange for increasing interoperability with more hosting environments and WordPress idiosyncrasies. Enable this option if you experience issues with the Apache rules." msgstr "" -#: inc/options/pgcache.php:520 +#: inc/options/pgcache.php:493 msgid "Charset:" msgstr "" -#: inc/options/pgcache.php:523 +#: inc/options/pgcache.php:496 msgid "Resolve issues incorrect odd character encoding that may appear in cached pages." msgstr "" -#: inc/options/pgcache.php:528 +#: inc/options/pgcache.php:501 msgid "Reject HEAD requests:" msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/pgcache.php:540 +#: inc/options/pgcache.php:513 msgid "If disabled, HEAD requests can often be cached resulting in \"empty pages\" being returned for subsequent requests for a %1$sURL%2$s." msgstr "" #. translators: 3 opening HTML acronym tag, 4 closing HTML acronym tag. -#: inc/options/pgcache.php:588 +#: inc/options/pgcache.php:561 msgid "Significantly reduce the default %1$sTTL%2$s for comment cookies to reduce the number of authenticated user traffic. Enter -1 to revert to default %3$sTTL%4$s." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/pgcache.php:619 +#: inc/options/pgcache.php:592 msgid "Always cache %1$sURL%2$ss that use these query string name-value pairs. The value part is not required. But if used, separate name-value pairs with an equals sign (i.e., name=value). Each pair should be on their own line." msgstr "" -#: inc/options/pgcache.php:642 +#: inc/options/pgcache.php:615 msgid "Never send cache pages for these user agents." msgstr "" -#: inc/options/pgcache.php:651 +#: inc/options/pgcache.php:624 msgid "Never cache pages that use the specified cookies." msgstr "" #. translators: 2 opening HTML acronym tag, 3 closing HTML acronym tag, 4 closing HTML acronym tag. -#: inc/options/pgcache.php:667 +#: inc/options/pgcache.php:640 msgid "Always ignore the specified pages / directories. Supports regular expressions (See %1$s%2$sFAQ%3$s%4$s)" msgstr "" -#: inc/options/pgcache.php:695 +#: inc/options/pgcache.php:668 msgid "Always ignore all pages filed under the specified category slugs." msgstr "" -#: inc/options/pgcache.php:704 +#: inc/options/pgcache.php:677 msgid "Always ignore all pages filed under the specified tag slugs." msgstr "" -#: inc/options/pgcache.php:713 +#: inc/options/pgcache.php:686 msgid "Always ignore all pages filed under the specified author usernames." msgstr "" -#: inc/options/pgcache.php:722 +#: inc/options/pgcache.php:695 msgid "Always ignore all pages filed under the specified custom fields. Separate name-value pairs with an equals sign (i.e., name=value)." msgstr "" #. translators: 3 closing HTML acronym tag, 4 closing HTML acronym tag. -#: inc/options/pgcache.php:738 +#: inc/options/pgcache.php:711 msgid "Cache the specified pages / directories even if listed in the \"never cache the following pages\" field. Supports regular expression (See %1$s%2$sFAQ%3$s%4$s)" msgstr "" -#: inc/options/pgcache.php:768 +#: inc/options/pgcache.php:741 msgid "Cache the specified pages even if they don't have trailing slash." msgstr "" -#: inc/options/pgcache.php:778 +#: inc/options/pgcache.php:751 msgid "Specify additional page headers to cache." msgstr "" #. translators: 1 opening HTML acronym tag, 2 closing HTML acronym tag. -#: inc/options/pgcache.php:791 +#: inc/options/pgcache.php:764 msgid "Return correct Content-Type header for %1$sXML%2$s files (e.g., feeds and sitemaps). Slows down cache engine." msgstr "" +#: inc/options/pgcache.php:786 +#: Util_Ui.php:1640 +#: Util_Ui.php:1713 +#: Util_Ui.php:1807 +msgid "Note(s)" +msgstr "" + #. translators: 5 opening HTML a tag to W3TC BrowserCache admin page, 6 closing HTML a tag. -#: inc/options/pgcache.php:826 +#: inc/options/pgcache.php:798 msgid "Enable %1$sHTTP%2$s compression in the \"%3$sHTML%4$s\" section on %5$sBrowser Cache Settings tab." msgstr "" #. translators: 5 opening HTML a tag to W3TC BrowserCache admin page, 6 closing HTML a tag. -#: inc/options/pgcache.php:855 +#: inc/options/pgcache.php:827 msgid "The %1$sTTL%2$s of page cache files is set via the \"Expires header lifetime\" field in the \"%3$sHTML%4$s\" section on %5$sBrowser Cache%6$s Settings tab." msgstr "" @@ -9201,23 +9340,23 @@ msgstr "" msgid "Loading..." msgstr "" -#: inc/wizard/template.php:160 +#: inc/wizard/template.php:162 msgid "SKIP" msgstr "" -#: inc/wizard/template.php:163 +#: inc/wizard/template.php:165 msgid "PREVIOUS" msgstr "" -#: inc/wizard/template.php:166 +#: inc/wizard/template.php:168 msgid "NEXT" msgstr "" -#: inc/wizard/template.php:169 +#: inc/wizard/template.php:171 msgid "DASHBOARD" msgstr "" -#: inc/wizard/template.php:248 +#: inc/wizard/template.php:249 msgid "Are you sure that you want to leave this page?" msgstr "" @@ -9250,69 +9389,65 @@ msgstr "" msgid "%1$sUpgrade Performance%2$s" msgstr "" -#: Licensing_Plugin_Admin.php:61 -msgid "Upgrade" -msgstr "" - #. translators: 1 HTML input button for renewing license. -#: Licensing_Plugin_Admin.php:169 +#: Licensing_Plugin_Admin.php:166 msgid "It looks like your W3 Total Cache Pro license has expired. %1$s to continue using the Pro features" msgstr "" -#: Licensing_Plugin_Admin.php:175 +#: Licensing_Plugin_Admin.php:172 msgid "Renew Now" msgstr "" -#: Licensing_Plugin_Admin.php:189 +#: Licensing_Plugin_Admin.php:186 msgid "The W3 Total Cache license key you entered is not valid." msgstr "" -#: Licensing_Plugin_Admin.php:191 +#: Licensing_Plugin_Admin.php:188 msgid "Please enter it again." msgstr "" -#: Licensing_Plugin_Admin.php:193 +#: Licensing_Plugin_Admin.php:190 msgid "The W3 Total Cache license key is not active for this site." msgstr "" #. translators: HTML a tag to W3TC Licence Reset. -#: Licensing_Plugin_Admin.php:198 +#: Licensing_Plugin_Admin.php:195 msgid "The W3 Total Cache license key is not active for this site. You can switch your license to this website following %1$sthis link%2$s" msgstr "" -#: Licensing_Plugin_Admin.php:218 +#: Licensing_Plugin_Admin.php:215 msgid "The W3 Total Cache license key is not active." msgstr "" -#: Licensing_Plugin_Admin.php:221 +#: Licensing_Plugin_Admin.php:218 msgid "The W3 Total Cache license key can't be verified." msgstr "" -#: Licensing_Plugin_Admin.php:248 +#: Licensing_Plugin_Admin.php:245 msgid "The W3 Total Cache license key is deactivated for this site." msgstr "" -#: Licensing_Plugin_Admin.php:252 +#: Licensing_Plugin_Admin.php:249 msgid "The W3 Total Cache license key is activated for this site." msgstr "" -#: Licensing_Plugin_Admin.php:268 -#: SetupGuide_Plugin_Admin.php:1109 +#: Licensing_Plugin_Admin.php:265 +#: SetupGuide_Plugin_Admin.php:1189 msgid "Accept" msgstr "" -#: Licensing_Plugin_Admin.php:272 -#: SetupGuide_Plugin_Admin.php:1110 +#: Licensing_Plugin_Admin.php:269 +#: SetupGuide_Plugin_Admin.php:1190 msgid "Decline" msgstr "" #. translators: 1 opening HTML a tag to W3TC Terms page, 2 closing HTML a tag. -#: Licensing_Plugin_Admin.php:297 +#: Licensing_Plugin_Admin.php:294 msgid "Our terms of use and privacy policies have been updated. Please %1$sreview%2$s and accept them." msgstr "" #. translators: 1: HTML break tag, 2: Anchor/link open tag, 3: Anchor/link close tag. -#: Licensing_Plugin_Admin.php:307 +#: Licensing_Plugin_Admin.php:304 msgid "By allowing us to collect data about how W3 Total Cache is used, we can improve our features and experience for everyone. This data will not include any personally identifiable information.%1$sFeel free to review our %2$sterms of use and privacy policy%3$s." msgstr "" @@ -9594,6 +9729,11 @@ msgstr "" msgid "I Understand the Risks" msgstr "" +#: Minify_Plugin.php:310 +#: Minify_Plugin_Admin.php:49 +msgid "Minify Cache" +msgstr "" + #: Minify_Plugin.php:321 msgid "Minified using %s%s" msgstr "" @@ -9658,7 +9798,7 @@ msgid "Purges Log" msgstr "" #. translators: 1 interval in seconds. -#: ObjectCache_Plugin.php:116 +#: ObjectCache_Plugin.php:117 msgid "[W3TC] Object Cache file GC (every %d seconds)" msgstr "" @@ -9671,15 +9811,15 @@ msgid "Empty the object cache" msgstr "" #. translators: 1: Cache hits, 2: Cache total cache objects, 3: Engine anme, 4: Reason. -#: ObjectCache_WpObjectCache_Regular.php:850 +#: ObjectCache_WpObjectCache_Regular.php:930 msgid "Object Caching %1$d/%2$d objects using %3$s%4$s" msgstr "" -#: ObjectCache_WpObjectCache_Regular.php:902 +#: ObjectCache_WpObjectCache_Regular.php:982 msgid "Object caching is disabled" msgstr "" -#: ObjectCache_WpObjectCache_Regular.php:904 +#: ObjectCache_WpObjectCache_Regular.php:984 msgid "DONOTCACHEOBJECT constant is defined" msgstr "" @@ -9818,6 +9958,18 @@ msgstr "" msgid "On the %1$s tab all of the recommended settings are preset. Use the help button to simplify discovery of your %2$s and %3$s files and groups. Pay close attention to the method and location of your %3$s group embeddings. See the plugin's %4$s for more information on usage." msgstr "" +#: PageSpeed_Instructions.php:68 +#: PageSpeed_Instructions.php:85 +#: PageSpeed_Instructions.php:357 +msgid "CSS" +msgstr "" + +#: PageSpeed_Instructions.php:69 +#: PageSpeed_Instructions.php:86 +#: PageSpeed_Instructions.php:358 +msgid "JS" +msgstr "" + #: PageSpeed_Instructions.php:94 msgid "Some themes and plugins are loading JS files or parts of the JS files on all pages and not only on the pages that should be loading on. For eaxmple if you are using some contact form plugin, there is a chance that the JS file of that plugin will load not only on the /contact/ page, but on all other pages as well and this is why the unused JS should be removed." msgstr "" @@ -10179,6 +10331,10 @@ msgstr "" msgid "Don't lazy load images that appear \"above the fold\" just use a standard " msgstr "" +#: PageSpeed_Instructions.php:427 +msgid " or " +msgstr "" + #: PageSpeed_Instructions.php:427 msgid "\telement." msgstr "" @@ -10788,7 +10944,7 @@ msgid "Handle XML mime t msgstr "" #. translators: 1: Engine name, 2: Reject reason placeholder, 3: Page key extension. -#: PgCache_ContentGrabber.php:1591 +#: PgCache_ContentGrabber.php:1604 msgid "Page Caching using %1$s%2$s%3$s" msgstr "" @@ -10806,10 +10962,6 @@ msgstr "" msgid "[W3TC] Page Cache prime (every %d seconds)" msgstr "" -#: PgCache_Plugin.php:330 -msgid "Page Cache: All" -msgstr "" - #: PgCache_Plugin.php:338 msgid "Page Cache: Current Page" msgstr "" @@ -10832,22 +10984,6 @@ msgstr "" msgid "error" msgstr "" -#: Root_AdminMenu.php:125 -#: Root_AdminMenu.php:126 -msgid "Install" -msgstr "" - -#: Root_AdminMenu.php:131 -#: Root_AdminMenu.php:132 -#: SetupGuide_Plugin_Admin.php:870 -msgid "Setup Guide" -msgstr "" - -#: Root_AdminMenu.php:137 -#: Root_AdminMenu.php:138 -msgid "About" -msgstr "" - #: SetupGuide_Plugin_Admin.php:86 #: SetupGuide_Plugin_Admin.php:122 #: SetupGuide_Plugin_Admin.php:180 @@ -10864,6 +11000,8 @@ msgstr "" #: SetupGuide_Plugin_Admin.php:737 #: SetupGuide_Plugin_Admin.php:764 #: SetupGuide_Plugin_Admin.php:813 +#: SetupGuide_Plugin_Admin.php:835 +#: SetupGuide_Plugin_Admin.php:874 msgid "Security violation" msgstr "" @@ -10899,329 +11037,377 @@ msgstr "" msgid "Not present" msgstr "" -#: SetupGuide_Plugin_Admin.php:895 +#: SetupGuide_Plugin_Admin.php:956 msgid "Testing complete. Click Next to advance to the section and see the results." msgstr "" -#: SetupGuide_Plugin_Admin.php:899 +#: SetupGuide_Plugin_Admin.php:960 msgid "Could not perform this test. Please reload the page to try again or click skip button to abort the setup guide." msgstr "" -#: SetupGuide_Plugin_Admin.php:903 +#: SetupGuide_Plugin_Admin.php:964 msgid "Could not update configuration. Please reload the page to try again or click skip button to abort the setup guide." msgstr "" -#: SetupGuide_Plugin_Admin.php:907 +#: SetupGuide_Plugin_Admin.php:968 msgid "Unavailable" msgstr "" -#: SetupGuide_Plugin_Admin.php:909 -#: Util_Ui.php:1011 +#: SetupGuide_Plugin_Admin.php:970 +#: Util_Ui.php:1208 msgid "Disk" msgstr "" -#: SetupGuide_Plugin_Admin.php:913 +#: SetupGuide_Plugin_Admin.php:974 msgid "Not Enabled" msgstr "" -#: SetupGuide_Plugin_Admin.php:1044 +#: SetupGuide_Plugin_Admin.php:1120 msgid "Welcome" msgstr "" -#: SetupGuide_Plugin_Admin.php:1064 -#: SetupGuide_Plugin_Admin.php:1269 +#: SetupGuide_Plugin_Admin.php:1140 +#: SetupGuide_Plugin_Admin.php:1349 +msgid "Image Optimization" +msgstr "" + +#: SetupGuide_Plugin_Admin.php:1144 +#: SetupGuide_Plugin_Admin.php:1361 msgid "Lazy Load" msgstr "" -#: SetupGuide_Plugin_Admin.php:1068 +#: SetupGuide_Plugin_Admin.php:1148 msgid "More Caching Options" msgstr "" -#: SetupGuide_Plugin_Admin.php:1073 +#: SetupGuide_Plugin_Admin.php:1153 msgid "Welcome to the W3 Total Cache Setup Guide!" msgstr "" -#: SetupGuide_Plugin_Admin.php:1077 +#: SetupGuide_Plugin_Admin.php:1157 msgid "You have selected the Performance Suite that professionals have consistently ranked #1 for options and speed improvements." msgstr "" -#: SetupGuide_Plugin_Admin.php:1082 +#: SetupGuide_Plugin_Admin.php:1162 msgid "provides many options to help your website perform faster. While the ideal settings vary for every website, there are a few settings we recommend that you enable now." msgstr "" #. translators: 1: Anchor/link open tag, 2: Anchor/link close tag. -#: SetupGuide_Plugin_Admin.php:1089 +#: SetupGuide_Plugin_Admin.php:1169 msgid "If you prefer to configure the settings on your own, you can %1$sskip this setup guide%2$s." msgstr "" #. translators: 1: Anchor/link open tag, 2: Anchor/link close tag. -#: SetupGuide_Plugin_Admin.php:1101 +#: SetupGuide_Plugin_Admin.php:1181 msgid "By allowing us to collect data about how W3 Total Cache is used, we can improve our features and experience for everyone. This data will not include any personally identifiable information. Feel free to review our %1$sterms of use and privacy policy%2$s." msgstr "" #. translators: 1: HTML emphesis open tag, 2: HTML emphesis close tag. -#: SetupGuide_Plugin_Admin.php:1119 +#: SetupGuide_Plugin_Admin.php:1199 msgid "The time it takes between a visitor's browser page request and receiving the first byte of a response is referred to as %1$sTime to First Byte%2$s." msgstr "" -#: SetupGuide_Plugin_Admin.php:1128 +#: SetupGuide_Plugin_Admin.php:1208 msgid "can help you speed up" msgstr "" -#: SetupGuide_Plugin_Admin.php:1129 -#: SetupGuide_Plugin_Admin.php:1140 +#: SetupGuide_Plugin_Admin.php:1209 +#: SetupGuide_Plugin_Admin.php:1220 msgid "Time to First Byte" msgstr "" -#: SetupGuide_Plugin_Admin.php:1132 +#: SetupGuide_Plugin_Admin.php:1212 msgid "We'll test your homepage with Page Cache disabled and then with several storage engines. You should review the test results and choose the best for your website." msgstr "" -#: SetupGuide_Plugin_Admin.php:1138 +#: SetupGuide_Plugin_Admin.php:1218 msgid "Test Page Cache" msgstr "" -#: SetupGuide_Plugin_Admin.php:1139 +#: SetupGuide_Plugin_Admin.php:1219 msgid "Measuring" msgstr "" -#: SetupGuide_Plugin_Admin.php:1144 +#: SetupGuide_Plugin_Admin.php:1224 msgid "Test URL:" msgstr "" -#: SetupGuide_Plugin_Admin.php:1149 -#: SetupGuide_Plugin_Admin.php:1175 -#: SetupGuide_Plugin_Admin.php:1212 +#: SetupGuide_Plugin_Admin.php:1229 +#: SetupGuide_Plugin_Admin.php:1255 +#: SetupGuide_Plugin_Admin.php:1292 msgid "Select" msgstr "" -#: SetupGuide_Plugin_Admin.php:1150 -#: SetupGuide_Plugin_Admin.php:1176 -#: SetupGuide_Plugin_Admin.php:1213 +#: SetupGuide_Plugin_Admin.php:1230 +#: SetupGuide_Plugin_Admin.php:1256 +#: SetupGuide_Plugin_Admin.php:1293 msgid "Storage Engine" msgstr "" -#: SetupGuide_Plugin_Admin.php:1151 -#: SetupGuide_Plugin_Admin.php:1177 -#: SetupGuide_Plugin_Admin.php:1214 +#: SetupGuide_Plugin_Admin.php:1231 +#: SetupGuide_Plugin_Admin.php:1257 +#: SetupGuide_Plugin_Admin.php:1294 msgid "Time (ms)" msgstr "" -#: SetupGuide_Plugin_Admin.php:1161 +#: SetupGuide_Plugin_Admin.php:1241 msgid "Many database queries are made in every dynamic page request. A database cache may speed up the generation of dynamic pages. Database Cache serves query results directly from a storage engine." msgstr "" -#: SetupGuide_Plugin_Admin.php:1167 +#: SetupGuide_Plugin_Admin.php:1247 msgid "Test Database Cache" msgstr "" -#: SetupGuide_Plugin_Admin.php:1168 -#: SetupGuide_Plugin_Admin.php:1205 -#: SetupGuide_Plugin_Admin.php:1253 +#: SetupGuide_Plugin_Admin.php:1248 +#: SetupGuide_Plugin_Admin.php:1285 +#: SetupGuide_Plugin_Admin.php:1333 msgid "Testing" msgstr "" -#: SetupGuide_Plugin_Admin.php:1185 +#: SetupGuide_Plugin_Admin.php:1265 msgid "By default, this feature is disabled. We recommend using Redis or Memcached, otherwise leave this feature disabled as the server database engine may be faster than using disk caching." msgstr "" -#: SetupGuide_Plugin_Admin.php:1195 +#: SetupGuide_Plugin_Admin.php:1275 msgid "WordPress caches objects used to build pages, but does not reuse them for future page requests." msgstr "" -#: SetupGuide_Plugin_Admin.php:1200 +#: SetupGuide_Plugin_Admin.php:1280 msgid "can help you speed up dynamic pages by persistently storing objects." msgstr "" -#: SetupGuide_Plugin_Admin.php:1204 +#: SetupGuide_Plugin_Admin.php:1284 msgid "Test Object Cache" msgstr "" -#: SetupGuide_Plugin_Admin.php:1224 +#: SetupGuide_Plugin_Admin.php:1304 msgid "To render your website, browsers must download many different types of assets, including javascript files, CSS stylesheets, images, and more. For most assets, once a browser has downloaded them, they shouldn't have to download them again." msgstr "" -#: SetupGuide_Plugin_Admin.php:1229 +#: SetupGuide_Plugin_Admin.php:1309 msgid "can help ensure browsers are properly caching your assets." msgstr "" #. translators: 1: HTML emphesis open tag, 2: HTML emphesis close tag. -#: SetupGuide_Plugin_Admin.php:1235 +#: SetupGuide_Plugin_Admin.php:1315 msgid "The %1$sCache-Control%2$s header tells your browser how it should cache specific files. The %1$smax-age%2$s setting tells your browser how long, in seconds, it should use its cached version of a file before requesting an updated one." msgstr "" #. translators: 1: HTML emphesis open tag, 2: HTML emphesis close tag. -#: SetupGuide_Plugin_Admin.php:1244 +#: SetupGuide_Plugin_Admin.php:1324 msgid "To improve %1$sBrowser Cache%2$s, we recommend enabling %1$sBrowser Cache%2$s." msgstr "" -#: SetupGuide_Plugin_Admin.php:1252 +#: SetupGuide_Plugin_Admin.php:1332 msgid "Test Browser Cache" msgstr "" -#: SetupGuide_Plugin_Admin.php:1260 +#: SetupGuide_Plugin_Admin.php:1340 msgid "Setting" msgstr "" -#: SetupGuide_Plugin_Admin.php:1262 +#: SetupGuide_Plugin_Admin.php:1342 msgid "Cache-Control Header" msgstr "" -#: SetupGuide_Plugin_Admin.php:1272 +#: SetupGuide_Plugin_Admin.php:1358 +msgid "Enable Image Service" +msgstr "" + +#: SetupGuide_Plugin_Admin.php:1364 msgid "Pages containing images and other objects can have their load time reduced by deferring them until they are needed. For example, images can be loaded when a visitor scrolls down the page to make them visible." msgstr "" -#: SetupGuide_Plugin_Admin.php:1281 +#: SetupGuide_Plugin_Admin.php:1373 msgid "Setup Complete!" msgstr "" #. translators: 1: HTML strong open tag, 2: HTML strong close tag, 3: Label. -#: SetupGuide_Plugin_Admin.php:1286 +#: SetupGuide_Plugin_Admin.php:1378 msgid "%1$sPage Cache%2$s engine set to %1$s%3$s%2$s" msgstr "" -#: SetupGuide_Plugin_Admin.php:1292 -#: SetupGuide_Plugin_Admin.php:1314 -#: SetupGuide_Plugin_Admin.php:1325 -#: SetupGuide_Plugin_Admin.php:1336 -#: SetupGuide_Plugin_Admin.php:1346 +#: SetupGuide_Plugin_Admin.php:1384 +#: SetupGuide_Plugin_Admin.php:1406 +#: SetupGuide_Plugin_Admin.php:1430 +#: SetupGuide_Plugin_Admin.php:1443 +#: SetupGuide_Plugin_Admin.php:1453 +#: SetupGuide_Plugin_Admin.php:1463 msgid "UNKNOWN" msgstr "" #. translators: 1: HTML strong open tag, 2: HTML strong close tag. -#: SetupGuide_Plugin_Admin.php:1297 +#: SetupGuide_Plugin_Admin.php:1389 msgid "%1$sTime to First Byte%2$s has changed by %1$s%3$s%2$s" msgstr "" #. translators: 1: HTML strong open tag, 2: HTML strong close tag, 3: Label. -#: SetupGuide_Plugin_Admin.php:1308 +#: SetupGuide_Plugin_Admin.php:1400 msgid "%1$sDatabase Cache%2$s engine set to %1$s%3$s%2$s" msgstr "" +#. translators: 1: HTML strong open tag, 2: HTML strong close tag. +#: SetupGuide_Plugin_Admin.php:1414 +msgid "%1$sObject Cache%2$s is %1$sdisabled via filter%2$s" +msgstr "" + #. translators: 1: HTML strong open tag, 2: HTML strong close tag, 3: Label. -#: SetupGuide_Plugin_Admin.php:1319 +#: SetupGuide_Plugin_Admin.php:1424 msgid "%1$sObject Cache%2$s engine set to %1$s%3$s%2$s" msgstr "" #. translators: 1: HTML strong open tag, 2: HTML strong close tag, 3: Label. -#: SetupGuide_Plugin_Admin.php:1330 +#: SetupGuide_Plugin_Admin.php:1437 msgid "%1$sBrowser Cache%2$s headers set for JavaScript, CSS, and images? %1$s%3$s%2$s" msgstr "" #. translators: 1: HTML strong open tag, 2: HTML strong close tag, 3: Label. -#: SetupGuide_Plugin_Admin.php:1340 +#: SetupGuide_Plugin_Admin.php:1447 +msgid "%1$sImage Optimization%2$s enabled? %1$s%3$s%2$s" +msgstr "" + +#. translators: 1: HTML strong open tag, 2: HTML strong close tag, 3: Label. +#: SetupGuide_Plugin_Admin.php:1457 msgid "%1$sLazy Load%2$s images? %1$s%3$s%2$s" msgstr "" -#: SetupGuide_Plugin_Admin.php:1348 +#: SetupGuide_Plugin_Admin.php:1465 msgid "What's Next?" msgstr "" #. translators: 1: HTML emphesis open tag, 2: HTML emphesis close tag. -#: SetupGuide_Plugin_Admin.php:1352 +#: SetupGuide_Plugin_Admin.php:1469 msgid "Your website's performance can still be improved by configuring %1$sminify%2$s settings, setting up a %1$sCDN%2$s, and more!" msgstr "" #. translators: 1: Anchor/link open tag, 2: Anchor/link close tag. -#: SetupGuide_Plugin_Admin.php:1362 +#: SetupGuide_Plugin_Admin.php:1479 msgid "Please visit %1$sGeneral Settings%2$s to learn more about these features." msgstr "" -#: SetupGuide_Plugin_Admin.php:1372 +#: SetupGuide_Plugin_Admin.php:1486 +msgid "Google PageSpeed Tool" +msgstr "" + +#. translators: 1: Anchor/link open tag, 2: Anchor/link close tag. +#: SetupGuide_Plugin_Admin.php:1489 +msgid "Google PageSpeed Insights can be used to analyze your homepage and provide an explanation of metrics and recommendations for improvements using W3 Total Cache features/extensions. This tool is enabled by default but will not function until authorization is granted, which can be done on the %1$sGeneral Settings%2$s page." +msgstr "" + +#: SetupGuide_Plugin_Admin.php:1496 msgid "Need help?" msgstr "" #. translators: 1: Anchor/link open tag, 2: Anchor/link close tag. -#: SetupGuide_Plugin_Admin.php:1376 +#: SetupGuide_Plugin_Admin.php:1500 msgid "We're here to help you! Visit our %1$sSupport Center%2$s for helpful information and to ask questions." msgstr "" -#: SystemOpCache_GeneralPage_View.php:21 +#: SystemOpCache_GeneralPage_View.php:10 +msgid "" +"Opcode cache is a powerful feature that enhances the performance of a WordPress website by caching \n" +"\t\t\tcompiled PHP code. By storing pre-compiled code in memory, opcode cache eliminates the need for \n" +"\t\t\trepetitive interpretation and compilation of PHP files, resulting in significantly faster execution \n" +"\t\t\ttimes. Opcode cache reduces server load and improves response times, ultimately enhancing the \n" +"\t\t\toverall speed and responsiveness of your WordPress site. If opcode cache is available on the \n" +"\t\t\thosting server it will automatically be selected in the dropdown and enabled." +msgstr "" + +#: SystemOpCache_GeneralPage_View.php:35 msgid "Not Available" msgstr "" -#: SystemOpCache_GeneralPage_View.php:25 +#: SystemOpCache_GeneralPage_View.php:39 msgid "Opcode: Zend Opcache" msgstr "" -#: SystemOpCache_GeneralPage_View.php:42 +#: SystemOpCache_GeneralPage_View.php:56 msgid "Once enabled, each file request will update the cache with the latest version. When this setting is off, the Opcode Cache will not check, instead PHP must be restarted in order for setting changes to be reflected." msgstr "" -#: UsageStatistics_GeneralPage_View.php:18 +#: UsageStatistics_GeneralPage_View.php:19 +msgid "" +"Cache Usage Statistics is a feature that provides valuable insights into the performance of your website's\n" +"\t\tcaching system. It displays detailed data regarding the utilization of your cache and overall performance\n" +"\t\tmetrics. By monitoring these statistics, website owners can identify areas of improvement, optimize their\n" +"\t\tcaching settings, and ultimately enhance the speed and responsiveness of their WordPress site, resulting\n" +"\t\tin a smoother user experience for visitors." +msgstr "" + +#: UsageStatistics_GeneralPage_View.php:39 msgid "Cache usage statistics" msgstr "" -#: UsageStatistics_GeneralPage_View.php:22 +#: UsageStatistics_GeneralPage_View.php:43 msgid "Enable statistics collection. Note that this consumes additional resources and is not recommended to be run continuously." msgstr "" -#: UsageStatistics_GeneralPage_View.php:25 +#: UsageStatistics_GeneralPage_View.php:45 msgid "Statistics provides near-complete transparency into the behavior of your caching performance, allowing you to identify opportunities to further improve your website speed and ensure operations are working as expected. Includes metrics like cache sizes, object lifetimes, hit vs miss ratio, etc across every caching method configured in your settings." msgstr "" -#: UsageStatistics_GeneralPage_View.php:26 +#: UsageStatistics_GeneralPage_View.php:46 msgid "Some statistics are available directly on your Performance Dashboard, however, the comprehensive suite of statistics are available on the Statistics screen. Web server logs created by Nginx or Apache can be analyzed if accessible." msgstr "" #. translators: 1 The opening anchor tag linking to our support page, 2 its closing tag. -#: UsageStatistics_GeneralPage_View.php:30 +#: UsageStatistics_GeneralPage_View.php:50 msgid "Use the caching statistics to compare the performance of different configurations like caching methods, object lifetimes and so on. Did you know that we offer premium support, customization and audit services? %1$sClick here for more information%2$s." msgstr "" -#: UsageStatistics_GeneralPage_View.php:40 +#: UsageStatistics_GeneralPage_View.php:63 msgid "Slot time (seconds):" msgstr "" -#: UsageStatistics_GeneralPage_View.php:43 +#: UsageStatistics_GeneralPage_View.php:66 msgid "The duration of time in seconds to collect statistics per interval." msgstr "" -#: UsageStatistics_GeneralPage_View.php:48 +#: UsageStatistics_GeneralPage_View.php:74 msgid "Slots collected:" msgstr "" -#: UsageStatistics_GeneralPage_View.php:51 +#: UsageStatistics_GeneralPage_View.php:77 msgid "The number of intervals that are represented in the graph." msgstr "" -#: UsageStatistics_GeneralPage_View.php:58 +#: UsageStatistics_GeneralPage_View.php:86 msgid "Use the system reported averages of CPU resource usage." msgstr "" -#: UsageStatistics_GeneralPage_View.php:59 +#: UsageStatistics_GeneralPage_View.php:87 msgid "Collect CPU usage" msgstr "" -#: UsageStatistics_GeneralPage_View.php:65 +#: UsageStatistics_GeneralPage_View.php:95 msgid "Parse server access log" msgstr "" -#: UsageStatistics_GeneralPage_View.php:67 +#: UsageStatistics_GeneralPage_View.php:97 msgid "Enable collecting statistics from an Access Log. This provides much more precise statistics." msgstr "" -#: UsageStatistics_GeneralPage_View.php:72 +#: UsageStatistics_GeneralPage_View.php:105 msgid "Webserver:" msgstr "" -#: UsageStatistics_GeneralPage_View.php:78 +#: UsageStatistics_GeneralPage_View.php:111 msgid "Webserver type generating access logs." msgstr "" -#: UsageStatistics_GeneralPage_View.php:83 +#: UsageStatistics_GeneralPage_View.php:119 msgid "Access Log Filename:" msgstr "" -#: UsageStatistics_GeneralPage_View.php:86 +#: UsageStatistics_GeneralPage_View.php:122 msgid "Where your access log is located." msgstr "" -#: UsageStatistics_GeneralPage_View.php:93 +#: UsageStatistics_GeneralPage_View.php:131 msgid "Access Log Format:" msgstr "" -#: UsageStatistics_GeneralPage_View.php:96 +#: UsageStatistics_GeneralPage_View.php:134 msgid "Format of your access log from webserver configuration." msgstr "" @@ -11634,47 +11820,51 @@ msgstr "" msgid "Upgrade to Pro" msgstr "" -#: UserExperience_GeneralPage_View.php:9 -#: UserExperience_Plugin_Admin.php:24 -#: UserExperience_Plugin_Admin.php:25 -msgid "User Experience" +#: UserExperience_GeneralPage_View.php:17 +msgid "" +"User Experience (UX) is a setting that focuses on enhancing the overall browsing experience for visitors\n" +"\t\tof your website. By enabling this feature, you can optimize your website's performance by minimizing\n" +"\t\tload times, reducing server requests, and delivering content more efficiently. This ultimately leads\n" +"\t\tto faster page loading, improved user satisfaction, and increased engagement, resulting in a speedier\n" +"\t\tand more enjoyable WordPress website." msgstr "" -#: UserExperience_GeneralPage_View.php:20 +#: UserExperience_GeneralPage_View.php:40 msgid "Defer loading offscreen images." msgstr "" #. translators: 5 opening HTML a tag to W3TC User Experience page, 6 closing HTML a tag. -#: UserExperience_GeneralPage_View.php:33 +#: UserExperience_GeneralPage_View.php:54 msgid "In addition to lazy loading images, with %1$sW3 Total Cache Pro%2$s you can lazy load %3$sGoogle Maps%4$s! More information and settings can be found on the %5$sUser Experience page%6$s." msgstr "" -#: UserExperience_GeneralPage_View.php:58 +#: UserExperience_GeneralPage_View.php:79 msgid "Disable Emoji" msgstr "" -#: UserExperience_GeneralPage_View.php:59 +#: UserExperience_GeneralPage_View.php:80 msgid "Remove emojis support from your website." msgstr "" -#: UserExperience_GeneralPage_View.php:67 +#: UserExperience_GeneralPage_View.php:89 msgid "Disable wp-embed script" msgstr "" -#: UserExperience_GeneralPage_View.php:68 +#: UserExperience_GeneralPage_View.php:90 msgid "Remove wp-embed.js script from your website. oEmbed functionality still works but you will not be able to embed other WordPress posts on your pages." msgstr "" -#: UserExperience_GeneralPage_View.php:76 +#: UserExperience_GeneralPage_View.php:99 msgid "Disable jquery-migrate on the front-end" msgstr "" -#: UserExperience_GeneralPage_View.php:77 +#: UserExperience_GeneralPage_View.php:101 msgid "Remove jquery-migrate support from your website front-end." msgstr "" #: UserExperience_LazyLoad_Page_View.php:17 #: UserExperience_LazyLoad_Plugin.php:123 +#: Util_Ui.php:1815 msgid "Lazy Loading" msgstr "" @@ -11985,38 +12175,116 @@ msgstr "" msgid "All Templates" msgstr "" -#: Util_Ui.php:187 -msgid "Click to toggle" +#: Util_Ui.php:210 +msgid "Basic Settings" msgstr "" -#: Util_Ui.php:217 +#: Util_Ui.php:211 +msgid "Advanced Settings" +msgstr "" + +#: Util_Ui.php:250 msgid "Save all settings" msgstr "" -#: Util_Ui.php:228 +#: Util_Ui.php:261 +#: Util_Ui.php:310 msgid "Save Settings & Purge Caches" msgstr "" -#: Util_Ui.php:1053 +#: Util_Ui.php:305 +#: Util_Ui.php:315 +msgid "Save Settings" +msgstr "" + +#: Util_Ui.php:339 +msgid "Empty All Caches" +msgstr "" + +#: Util_Ui.php:361 +msgid "Empty Page Cache" +msgstr "" + +#: Util_Ui.php:364 +msgid "Empty Browser Cache" +msgstr "" + +#: Util_Ui.php:367 +msgid "Empty Minify Cache" +msgstr "" + +#: Util_Ui.php:370 +msgid "Empty Database Cache" +msgstr "" + +#: Util_Ui.php:373 +msgid "Empty Object Cache" +msgstr "" + +#: Util_Ui.php:377 +msgid "Empty CDN Cache" +msgstr "" + +#: Util_Ui.php:380 +msgid "Empty Fragment Cache" +msgstr "" + +#: Util_Ui.php:383 +msgid "Empty Varnish Cache" +msgstr "" + +#: Util_Ui.php:386 +msgid "Empty CloudFlare Cache" +msgstr "" + +#: Util_Ui.php:391 +msgid "Empty OpCode Cache" +msgstr "" + +#: Util_Ui.php:1249 msgid "Shared Server:" msgstr "" -#: Util_Ui.php:1087 +#: Util_Ui.php:1289 msgid "Show More" msgstr "" -#: Util_Ui.php:1148 +#: Util_Ui.php:1350 msgid "Use common settings" msgstr "" -#: Util_Ui.php:1151 +#: Util_Ui.php:1353 msgid "Use specific settings" msgstr "" -#: Util_Ui.php:1178 +#: Util_Ui.php:1380 msgid "Preview" msgstr "" +#: Util_Ui.php:1637 +msgid "Purge Policy" +msgstr "" + +#: Util_Ui.php:1638 +msgid "Rest API" +msgstr "" + +#: Util_Ui.php:1785 +msgid "Media" +msgstr "" + +#: Util_Ui.php:1825 +msgid "Rewrite Rules" +msgstr "" + +#: Util_Ui.php:1867 +msgid "Application" +msgstr "" + +#: Util_Ui.php:1869 +msgid "Behavior" +msgstr "" + #: Util_Widget.php:54 msgid "View all" msgstr "" @@ -12042,6 +12310,10 @@ msgstr "" msgid "FTP credentials don't allow to delete " msgstr "" +#: Varnish_Plugin.php:81 +msgid "Varnish Cache" +msgstr "" + #. translators: 1 class name, 2 file name. #: w3-total-cache-api.php:188 msgid "Attempt to create object of class %1$s has been made, but file %2$s doesnt exists" diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/bootstrap-buttons.css b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/bootstrap-buttons.css new file mode 100644 index 00000000..900dc0c9 --- /dev/null +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/bootstrap-buttons.css @@ -0,0 +1,1415 @@ +/*! + * Bootstrap v4.0.0 (https://getbootstrap.com) + * Copyright 2011-2018 The Bootstrap Authors + * Copyright 2011-2018 Twitter, Inc. + * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) + */ + +/* + * The CSS in this file was manually pulled from the bootstrap.css to avoid unintended impact on other style definitions + */ + +.btn { + display: inline-block; + font-weight: 400; + text-align: center; + white-space: nowrap; + vertical-align: middle; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + border: 1px solid transparent; + padding: 0.375rem 0.75rem; + font-size: 1rem; + line-height: 1.5; + border-radius: 0.25rem; + transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out; + } + + .btn:hover, .btn:focus { + text-decoration: none; + } + + .btn:focus, .btn.focus { + outline: 0; + box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25); + } + + .btn.disabled, .btn:disabled { + opacity: 0.65; + } + + .btn:not(:disabled):not(.disabled) { + cursor: pointer; + } + + .btn:not(:disabled):not(.disabled):active, .btn:not(:disabled):not(.disabled).active { + background-image: none; + } + + a.btn.disabled, + fieldset:disabled a.btn { + pointer-events: none; + } + + .btn-primary { + color: #fff; + background-color: #007bff; + border-color: #007bff; + } + + .btn-primary:hover { + color: #fff; + background-color: #0069d9; + border-color: #0062cc; + } + + .btn-primary:focus, .btn-primary.focus { + box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.5); + } + + .btn-primary.disabled, .btn-primary:disabled { + color: #fff; + background-color: #007bff; + border-color: #007bff; + } + + .btn-primary:not(:disabled):not(.disabled):active, .btn-primary:not(:disabled):not(.disabled).active, + .show > .btn-primary.dropdown-toggle { + color: #fff; + background-color: #0062cc; + border-color: #005cbf; + } + + .btn-primary:not(:disabled):not(.disabled):active:focus, .btn-primary:not(:disabled):not(.disabled).active:focus, + .show > .btn-primary.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.5); + } + + .btn-secondary { + color: #fff; + background-color: #6c757d; + border-color: #6c757d; + } + + .btn-secondary:hover { + color: #fff; + background-color: #5a6268; + border-color: #545b62; + } + + .btn-secondary:focus, .btn-secondary.focus { + box-shadow: 0 0 0 0.2rem rgba(108, 117, 125, 0.5); + } + + .btn-secondary.disabled, .btn-secondary:disabled { + color: #fff; + background-color: #6c757d; + border-color: #6c757d; + } + + .btn-secondary:not(:disabled):not(.disabled):active, .btn-secondary:not(:disabled):not(.disabled).active, + .show > .btn-secondary.dropdown-toggle { + color: #fff; + background-color: #545b62; + border-color: #4e555b; + } + + .btn-secondary:not(:disabled):not(.disabled):active:focus, .btn-secondary:not(:disabled):not(.disabled).active:focus, + .show > .btn-secondary.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(108, 117, 125, 0.5); + } + + .btn-success { + color: #fff; + background-color: #28a745; + border-color: #28a745; + } + + .btn-success:hover { + color: #fff; + background-color: #218838; + border-color: #1e7e34; + } + + .btn-success:focus, .btn-success.focus { + box-shadow: 0 0 0 0.2rem rgba(40, 167, 69, 0.5); + } + + .btn-success.disabled, .btn-success:disabled { + color: #fff; + background-color: #28a745; + border-color: #28a745; + } + + .btn-success:not(:disabled):not(.disabled):active, .btn-success:not(:disabled):not(.disabled).active, + .show > .btn-success.dropdown-toggle { + color: #fff; + background-color: #1e7e34; + border-color: #1c7430; + } + + .btn-success:not(:disabled):not(.disabled):active:focus, .btn-success:not(:disabled):not(.disabled).active:focus, + .show > .btn-success.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(40, 167, 69, 0.5); + } + + .btn-info { + color: #fff; + background-color: #17a2b8; + border-color: #17a2b8; + } + + .btn-info:hover { + color: #fff; + background-color: #138496; + border-color: #117a8b; + } + + .btn-info:focus, .btn-info.focus { + box-shadow: 0 0 0 0.2rem rgba(23, 162, 184, 0.5); + } + + .btn-info.disabled, .btn-info:disabled { + color: #fff; + background-color: #17a2b8; + border-color: #17a2b8; + } + + .btn-info:not(:disabled):not(.disabled):active, .btn-info:not(:disabled):not(.disabled).active, + .show > .btn-info.dropdown-toggle { + color: #fff; + background-color: #117a8b; + border-color: #10707f; + } + + .btn-info:not(:disabled):not(.disabled):active:focus, .btn-info:not(:disabled):not(.disabled).active:focus, + .show > .btn-info.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(23, 162, 184, 0.5); + } + + .btn-warning { + color: #212529; + background-color: #ffc107; + border-color: #ffc107; + } + + .btn-warning:hover { + color: #212529; + background-color: #e0a800; + border-color: #d39e00; + } + + .btn-warning:focus, .btn-warning.focus { + box-shadow: 0 0 0 0.2rem rgba(255, 193, 7, 0.5); + } + + .btn-warning.disabled, .btn-warning:disabled { + color: #212529; + background-color: #ffc107; + border-color: #ffc107; + } + + .btn-warning:not(:disabled):not(.disabled):active, .btn-warning:not(:disabled):not(.disabled).active, + .show > .btn-warning.dropdown-toggle { + color: #212529; + background-color: #d39e00; + border-color: #c69500; + } + + .btn-warning:not(:disabled):not(.disabled):active:focus, .btn-warning:not(:disabled):not(.disabled).active:focus, + .show > .btn-warning.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(255, 193, 7, 0.5); + } + + .btn-danger { + color: #fff; + background-color: #dc3545; + border-color: #dc3545; + } + + .btn-danger:hover { + color: #fff; + background-color: #c82333; + border-color: #bd2130; + } + + .btn-danger:focus, .btn-danger.focus { + box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.5); + } + + .btn-danger.disabled, .btn-danger:disabled { + color: #fff; + background-color: #dc3545; + border-color: #dc3545; + } + + .btn-danger:not(:disabled):not(.disabled):active, .btn-danger:not(:disabled):not(.disabled).active, + .show > .btn-danger.dropdown-toggle { + color: #fff; + background-color: #bd2130; + border-color: #b21f2d; + } + + .btn-danger:not(:disabled):not(.disabled):active:focus, .btn-danger:not(:disabled):not(.disabled).active:focus, + .show > .btn-danger.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.5); + } + + .btn-light { + color: #212529; + background-color: #f8f9fa; + border-color: #f8f9fa; + } + + .btn-light:hover { + color: #212529; + background-color: #e2e6ea; + border-color: #dae0e5; + } + + .btn-light:focus, .btn-light.focus { + box-shadow: 0 0 0 0.2rem rgba(248, 249, 250, 0.5); + } + + .btn-light.disabled, .btn-light:disabled { + color: #212529; + background-color: #f8f9fa; + border-color: #f8f9fa; + } + + .btn-light:not(:disabled):not(.disabled):active, .btn-light:not(:disabled):not(.disabled).active, + .show > .btn-light.dropdown-toggle { + color: #212529; + background-color: #dae0e5; + border-color: #d3d9df; + } + + .btn-light:not(:disabled):not(.disabled):active:focus, .btn-light:not(:disabled):not(.disabled).active:focus, + .show > .btn-light.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(248, 249, 250, 0.5); + } + + .btn-dark { + color: #fff; + background-color: #343a40; + border-color: #343a40; + } + + .btn-dark:hover { + color: #fff; + background-color: #23272b; + border-color: #1d2124; + } + + .btn-dark:focus, .btn-dark.focus { + box-shadow: 0 0 0 0.2rem rgba(52, 58, 64, 0.5); + } + + .btn-dark.disabled, .btn-dark:disabled { + color: #fff; + background-color: #343a40; + border-color: #343a40; + } + + .btn-dark:not(:disabled):not(.disabled):active, .btn-dark:not(:disabled):not(.disabled).active, + .show > .btn-dark.dropdown-toggle { + color: #fff; + background-color: #1d2124; + border-color: #171a1d; + } + + .btn-dark:not(:disabled):not(.disabled):active:focus, .btn-dark:not(:disabled):not(.disabled).active:focus, + .show > .btn-dark.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(52, 58, 64, 0.5); + } + + .btn-outline-primary { + color: #007bff; + background-color: transparent; + background-image: none; + border-color: #007bff; + } + + .btn-outline-primary:hover { + color: #fff; + background-color: #007bff; + border-color: #007bff; + } + + .btn-outline-primary:focus, .btn-outline-primary.focus { + box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.5); + } + + .btn-outline-primary.disabled, .btn-outline-primary:disabled { + color: #007bff; + background-color: transparent; + } + + .btn-outline-primary:not(:disabled):not(.disabled):active, .btn-outline-primary:not(:disabled):not(.disabled).active, + .show > .btn-outline-primary.dropdown-toggle { + color: #fff; + background-color: #007bff; + border-color: #007bff; + } + + .btn-outline-primary:not(:disabled):not(.disabled):active:focus, .btn-outline-primary:not(:disabled):not(.disabled).active:focus, + .show > .btn-outline-primary.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.5); + } + + .btn-outline-secondary { + color: #6c757d; + background-color: transparent; + background-image: none; + border-color: #6c757d; + } + + .btn-outline-secondary:hover { + color: #fff; + background-color: #6c757d; + border-color: #6c757d; + } + + .btn-outline-secondary:focus, .btn-outline-secondary.focus { + box-shadow: 0 0 0 0.2rem rgba(108, 117, 125, 0.5); + } + + .btn-outline-secondary.disabled, .btn-outline-secondary:disabled { + color: #6c757d; + background-color: transparent; + } + + .btn-outline-secondary:not(:disabled):not(.disabled):active, .btn-outline-secondary:not(:disabled):not(.disabled).active, + .show > .btn-outline-secondary.dropdown-toggle { + color: #fff; + background-color: #6c757d; + border-color: #6c757d; + } + + .btn-outline-secondary:not(:disabled):not(.disabled):active:focus, .btn-outline-secondary:not(:disabled):not(.disabled).active:focus, + .show > .btn-outline-secondary.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(108, 117, 125, 0.5); + } + + .btn-outline-success { + color: #28a745; + background-color: transparent; + background-image: none; + border-color: #28a745; + } + + .btn-outline-success:hover { + color: #fff; + background-color: #28a745; + border-color: #28a745; + } + + .btn-outline-success:focus, .btn-outline-success.focus { + box-shadow: 0 0 0 0.2rem rgba(40, 167, 69, 0.5); + } + + .btn-outline-success.disabled, .btn-outline-success:disabled { + color: #28a745; + background-color: transparent; + } + + .btn-outline-success:not(:disabled):not(.disabled):active, .btn-outline-success:not(:disabled):not(.disabled).active, + .show > .btn-outline-success.dropdown-toggle { + color: #fff; + background-color: #28a745; + border-color: #28a745; + } + + .btn-outline-success:not(:disabled):not(.disabled):active:focus, .btn-outline-success:not(:disabled):not(.disabled).active:focus, + .show > .btn-outline-success.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(40, 167, 69, 0.5); + } + + .btn-outline-info { + color: #17a2b8; + background-color: transparent; + background-image: none; + border-color: #17a2b8; + } + + .btn-outline-info:hover { + color: #fff; + background-color: #17a2b8; + border-color: #17a2b8; + } + + .btn-outline-info:focus, .btn-outline-info.focus { + box-shadow: 0 0 0 0.2rem rgba(23, 162, 184, 0.5); + } + + .btn-outline-info.disabled, .btn-outline-info:disabled { + color: #17a2b8; + background-color: transparent; + } + + .btn-outline-info:not(:disabled):not(.disabled):active, .btn-outline-info:not(:disabled):not(.disabled).active, + .show > .btn-outline-info.dropdown-toggle { + color: #fff; + background-color: #17a2b8; + border-color: #17a2b8; + } + + .btn-outline-info:not(:disabled):not(.disabled):active:focus, .btn-outline-info:not(:disabled):not(.disabled).active:focus, + .show > .btn-outline-info.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(23, 162, 184, 0.5); + } + + .btn-outline-warning { + color: #ffc107; + background-color: transparent; + background-image: none; + border-color: #ffc107; + } + + .btn-outline-warning:hover { + color: #212529; + background-color: #ffc107; + border-color: #ffc107; + } + + .btn-outline-warning:focus, .btn-outline-warning.focus { + box-shadow: 0 0 0 0.2rem rgba(255, 193, 7, 0.5); + } + + .btn-outline-warning.disabled, .btn-outline-warning:disabled { + color: #ffc107; + background-color: transparent; + } + + .btn-outline-warning:not(:disabled):not(.disabled):active, .btn-outline-warning:not(:disabled):not(.disabled).active, + .show > .btn-outline-warning.dropdown-toggle { + color: #212529; + background-color: #ffc107; + border-color: #ffc107; + } + + .btn-outline-warning:not(:disabled):not(.disabled):active:focus, .btn-outline-warning:not(:disabled):not(.disabled).active:focus, + .show > .btn-outline-warning.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(255, 193, 7, 0.5); + } + + .btn-outline-danger { + color: #dc3545; + background-color: transparent; + background-image: none; + border-color: #dc3545; + } + + .btn-outline-danger:hover { + color: #fff; + background-color: #dc3545; + border-color: #dc3545; + } + + .btn-outline-danger:focus, .btn-outline-danger.focus { + box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.5); + } + + .btn-outline-danger.disabled, .btn-outline-danger:disabled { + color: #dc3545; + background-color: transparent; + } + + .btn-outline-danger:not(:disabled):not(.disabled):active, .btn-outline-danger:not(:disabled):not(.disabled).active, + .show > .btn-outline-danger.dropdown-toggle { + color: #fff; + background-color: #dc3545; + border-color: #dc3545; + } + + .btn-outline-danger:not(:disabled):not(.disabled):active:focus, .btn-outline-danger:not(:disabled):not(.disabled).active:focus, + .show > .btn-outline-danger.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.5); + } + + .btn-outline-light { + color: #f8f9fa; + background-color: transparent; + background-image: none; + border-color: #f8f9fa; + } + + .btn-outline-light:hover { + color: #212529; + background-color: #f8f9fa; + border-color: #f8f9fa; + } + + .btn-outline-light:focus, .btn-outline-light.focus { + box-shadow: 0 0 0 0.2rem rgba(248, 249, 250, 0.5); + } + + .btn-outline-light.disabled, .btn-outline-light:disabled { + color: #f8f9fa; + background-color: transparent; + } + + .btn-outline-light:not(:disabled):not(.disabled):active, .btn-outline-light:not(:disabled):not(.disabled).active, + .show > .btn-outline-light.dropdown-toggle { + color: #212529; + background-color: #f8f9fa; + border-color: #f8f9fa; + } + + .btn-outline-light:not(:disabled):not(.disabled):active:focus, .btn-outline-light:not(:disabled):not(.disabled).active:focus, + .show > .btn-outline-light.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(248, 249, 250, 0.5); + } + + .btn-outline-dark { + color: #343a40; + background-color: transparent; + background-image: none; + border-color: #343a40; + } + + .btn-outline-dark:hover { + color: #fff; + background-color: #343a40; + border-color: #343a40; + } + + .btn-outline-dark:focus, .btn-outline-dark.focus { + box-shadow: 0 0 0 0.2rem rgba(52, 58, 64, 0.5); + } + + .btn-outline-dark.disabled, .btn-outline-dark:disabled { + color: #343a40; + background-color: transparent; + } + + .btn-outline-dark:not(:disabled):not(.disabled):active, .btn-outline-dark:not(:disabled):not(.disabled).active, + .show > .btn-outline-dark.dropdown-toggle { + color: #fff; + background-color: #343a40; + border-color: #343a40; + } + + .btn-outline-dark:not(:disabled):not(.disabled):active:focus, .btn-outline-dark:not(:disabled):not(.disabled).active:focus, + .show > .btn-outline-dark.dropdown-toggle:focus { + box-shadow: 0 0 0 0.2rem rgba(52, 58, 64, 0.5); + } + + .btn-link { + font-weight: 400; + color: #007bff; + background-color: transparent; + } + + .btn-link:hover { + color: #0056b3; + text-decoration: underline; + background-color: transparent; + border-color: transparent; + } + + .btn-link:focus, .btn-link.focus { + text-decoration: underline; + border-color: transparent; + box-shadow: none; + } + + .btn-link:disabled, .btn-link.disabled { + color: #6c757d; + } + + .btn-lg, .btn-group-lg > .btn { + padding: 0.5rem 1rem; + font-size: 1.25rem; + line-height: 1.5; + border-radius: 0.3rem; + } + + .btn-sm, .btn-group-sm > .btn { + padding: 0.25rem 0.5rem; + font-size: 0.875rem; + line-height: 1.5; + border-radius: 0.2rem; + } + + .btn-block { + display: block; + width: 100%; + } + + .btn-block + .btn-block { + margin-top: 0.5rem; + } + + input[type="submit"].btn-block, + input[type="reset"].btn-block, + input[type="button"].btn-block { + width: 100%; + } + + .fade { + opacity: 0; + transition: opacity 0.15s linear; + } + + .fade.show { + opacity: 1; + } + + .collapse { + display: none; + } + + .collapse.show { + display: block; + } + + tr.collapse.show { + display: table-row; + } + + tbody.collapse.show { + display: table-row-group; + } + + .collapsing { + position: relative; + height: 0; + overflow: hidden; + transition: height 0.35s ease; + } + + .dropup, + .dropdown { + position: relative; + } + + .dropdown-toggle::after { + display: inline-block; + width: 0; + height: 0; + margin-left: 0.255em; + vertical-align: 0.255em; + content: ""; + border-top: 0.3em solid; + border-right: 0.3em solid transparent; + border-bottom: 0; + border-left: 0.3em solid transparent; + } + + .dropdown-toggle:empty::after { + margin-left: 0; + } + + .dropdown-menu { + position: absolute; + top: 100%; + left: 0; + z-index: 1000; + display: none; + float: left; + min-width: 10rem; + padding: 0.5rem 0; + margin: 0.125rem 0 0; + font-size: 1rem; + color: #212529; + text-align: left; + list-style: none; + background-color: #fff; + background-clip: padding-box; + border: 1px solid rgba(0, 0, 0, 0.15); + border-radius: 0.25rem; + } + + .dropup .dropdown-menu { + margin-top: 0; + margin-bottom: 0.125rem; + } + + .dropup .dropdown-toggle::after { + display: inline-block; + width: 0; + height: 0; + margin-left: 0.255em; + vertical-align: 0.255em; + content: ""; + border-top: 0; + border-right: 0.3em solid transparent; + border-bottom: 0.3em solid; + border-left: 0.3em solid transparent; + } + + .dropup .dropdown-toggle:empty::after { + margin-left: 0; + } + + .dropright .dropdown-menu { + margin-top: 0; + margin-left: 0.125rem; + } + + .dropright .dropdown-toggle::after { + display: inline-block; + width: 0; + height: 0; + margin-left: 0.255em; + vertical-align: 0.255em; + content: ""; + border-top: 0.3em solid transparent; + border-bottom: 0.3em solid transparent; + border-left: 0.3em solid; + } + + .dropright .dropdown-toggle:empty::after { + margin-left: 0; + } + + .dropright .dropdown-toggle::after { + vertical-align: 0; + } + + .dropleft .dropdown-menu { + margin-top: 0; + margin-right: 0.125rem; + } + + .dropleft .dropdown-toggle::after { + display: inline-block; + width: 0; + height: 0; + margin-left: 0.255em; + vertical-align: 0.255em; + content: ""; + } + + .dropleft .dropdown-toggle::after { + display: none; + } + + .dropleft .dropdown-toggle::before { + display: inline-block; + width: 0; + height: 0; + margin-right: 0.255em; + vertical-align: 0.255em; + content: ""; + border-top: 0.3em solid transparent; + border-right: 0.3em solid; + border-bottom: 0.3em solid transparent; + } + + .dropleft .dropdown-toggle:empty::after { + margin-left: 0; + } + + .dropleft .dropdown-toggle::before { + vertical-align: 0; + } + + .dropdown-divider { + height: 0; + margin: 0.5rem 0; + overflow: hidden; + border-top: 1px solid #e9ecef; + } + + .dropdown-item { + display: block; + width: 100%; + padding: 0.25rem 1.5rem; + clear: both; + font-weight: 400; + color: #212529; + text-align: inherit; + white-space: nowrap; + background-color: transparent; + border: 0; + } + + .dropdown-item:hover, .dropdown-item:focus { + color: #16181b; + text-decoration: none; + background-color: #f8f9fa; + } + + .dropdown-item.active, .dropdown-item:active { + color: #fff; + text-decoration: none; + background-color: #007bff; + } + + .dropdown-item.disabled, .dropdown-item:disabled { + color: #6c757d; + background-color: transparent; + } + + .dropdown-menu.show { + display: block; + } + + .dropdown-header { + display: block; + padding: 0.5rem 1.5rem; + margin-bottom: 0; + font-size: 0.875rem; + color: #6c757d; + white-space: nowrap; + } + + .btn-group, + .btn-group-vertical { + position: relative; + display: -webkit-inline-box; + display: -ms-inline-flexbox; + display: inline-flex; + vertical-align: middle; + } + + .btn-group > .btn, + .btn-group-vertical > .btn { + position: relative; + -webkit-box-flex: 0; + -ms-flex: 0 1 auto; + flex: 0 1 auto; + } + + .btn-group > .btn:hover, + .btn-group-vertical > .btn:hover { + z-index: 1; + } + + .btn-group > .btn:focus, .btn-group > .btn:active, .btn-group > .btn.active, + .btn-group-vertical > .btn:focus, + .btn-group-vertical > .btn:active, + .btn-group-vertical > .btn.active { + z-index: 1; + } + + .btn-group .btn + .btn, + .btn-group .btn + .btn-group, + .btn-group .btn-group + .btn, + .btn-group .btn-group + .btn-group, + .btn-group-vertical .btn + .btn, + .btn-group-vertical .btn + .btn-group, + .btn-group-vertical .btn-group + .btn, + .btn-group-vertical .btn-group + .btn-group { + margin-left: -1px; + } + + .btn-toolbar { + display: -webkit-box; + display: -ms-flexbox; + display: flex; + -ms-flex-wrap: wrap; + flex-wrap: wrap; + -webkit-box-pack: start; + -ms-flex-pack: start; + justify-content: flex-start; + } + + .btn-toolbar .input-group { + width: auto; + } + + .btn-group > .btn:first-child { + margin-left: 0; + } + + .btn-group > .btn:not(:last-child):not(.dropdown-toggle), + .btn-group > .btn-group:not(:last-child) > .btn { + border-top-right-radius: 0; + border-bottom-right-radius: 0; + } + + .btn-group > .btn:not(:first-child), + .btn-group > .btn-group:not(:first-child) > .btn { + border-top-left-radius: 0; + border-bottom-left-radius: 0; + } + + .dropdown-toggle-split { + padding-right: 0.5625rem; + padding-left: 0.5625rem; + } + + .dropdown-toggle-split::after { + margin-left: 0; + } + + .btn-sm + .dropdown-toggle-split, .btn-group-sm > .btn + .dropdown-toggle-split { + padding-right: 0.375rem; + padding-left: 0.375rem; + } + + .btn-lg + .dropdown-toggle-split, .btn-group-lg > .btn + .dropdown-toggle-split { + padding-right: 0.75rem; + padding-left: 0.75rem; + } + + .btn-group-vertical { + -webkit-box-orient: vertical; + -webkit-box-direction: normal; + -ms-flex-direction: column; + flex-direction: column; + -webkit-box-align: start; + -ms-flex-align: start; + align-items: flex-start; + -webkit-box-pack: center; + -ms-flex-pack: center; + justify-content: center; + } + + .btn-group-vertical .btn, + .btn-group-vertical .btn-group { + width: 100%; + } + + .btn-group-vertical > .btn + .btn, + .btn-group-vertical > .btn + .btn-group, + .btn-group-vertical > .btn-group + .btn, + .btn-group-vertical > .btn-group + .btn-group { + margin-top: -1px; + margin-left: 0; + } + + .btn-group-vertical > .btn:not(:last-child):not(.dropdown-toggle), + .btn-group-vertical > .btn-group:not(:last-child) > .btn { + border-bottom-right-radius: 0; + border-bottom-left-radius: 0; + } + + .btn-group-vertical > .btn:not(:first-child), + .btn-group-vertical > .btn-group:not(:first-child) > .btn { + border-top-left-radius: 0; + border-top-right-radius: 0; + } + + .btn-group-toggle > .btn, + .btn-group-toggle > .btn-group > .btn { + margin-bottom: 0; + } + + .btn-group-toggle > .btn input[type="radio"], + .btn-group-toggle > .btn input[type="checkbox"], + .btn-group-toggle > .btn-group > .btn input[type="radio"], + .btn-group-toggle > .btn-group > .btn input[type="checkbox"] { + position: absolute; + clip: rect(0, 0, 0, 0); + pointer-events: none; + } + + .input-group { + position: relative; + display: -webkit-box; + display: -ms-flexbox; + display: flex; + -ms-flex-wrap: wrap; + flex-wrap: wrap; + -webkit-box-align: stretch; + -ms-flex-align: stretch; + align-items: stretch; + width: 100%; + } + + .input-group > .form-control, + .input-group > .custom-select, + .input-group > .custom-file { + position: relative; + -webkit-box-flex: 1; + -ms-flex: 1 1 auto; + flex: 1 1 auto; + width: 1%; + margin-bottom: 0; + } + + .input-group > .form-control:focus, + .input-group > .custom-select:focus, + .input-group > .custom-file:focus { + z-index: 3; + } + + .input-group > .form-control + .form-control, + .input-group > .form-control + .custom-select, + .input-group > .form-control + .custom-file, + .input-group > .custom-select + .form-control, + .input-group > .custom-select + .custom-select, + .input-group > .custom-select + .custom-file, + .input-group > .custom-file + .form-control, + .input-group > .custom-file + .custom-select, + .input-group > .custom-file + .custom-file { + margin-left: -1px; + } + + .input-group > .form-control:not(:last-child), + .input-group > .custom-select:not(:last-child) { + border-top-right-radius: 0; + border-bottom-right-radius: 0; + } + + .input-group > .form-control:not(:first-child), + .input-group > .custom-select:not(:first-child) { + border-top-left-radius: 0; + border-bottom-left-radius: 0; + } + + .input-group > .custom-file { + display: -webkit-box; + display: -ms-flexbox; + display: flex; + -webkit-box-align: center; + -ms-flex-align: center; + align-items: center; + } + + .input-group > .custom-file:not(:last-child) .custom-file-label, + .input-group > .custom-file:not(:last-child) .custom-file-label::before { + border-top-right-radius: 0; + border-bottom-right-radius: 0; + } + + .input-group > .custom-file:not(:first-child) .custom-file-label, + .input-group > .custom-file:not(:first-child) .custom-file-label::before { + border-top-left-radius: 0; + border-bottom-left-radius: 0; + } + + .input-group-prepend, + .input-group-append { + display: -webkit-box; + display: -ms-flexbox; + display: flex; + } + + .input-group-prepend .btn, + .input-group-append .btn { + position: relative; + z-index: 2; + } + + .input-group-prepend .btn + .btn, + .input-group-prepend .btn + .input-group-text, + .input-group-prepend .input-group-text + .input-group-text, + .input-group-prepend .input-group-text + .btn, + .input-group-append .btn + .btn, + .input-group-append .btn + .input-group-text, + .input-group-append .input-group-text + .input-group-text, + .input-group-append .input-group-text + .btn { + margin-left: -1px; + } + + .input-group-prepend { + margin-right: -1px; + } + + .input-group-append { + margin-left: -1px; + } + + .input-group-text { + display: -webkit-box; + display: -ms-flexbox; + display: flex; + -webkit-box-align: center; + -ms-flex-align: center; + align-items: center; + padding: 0.375rem 0.75rem; + margin-bottom: 0; + font-size: 1rem; + font-weight: 400; + line-height: 1.5; + color: #495057; + text-align: center; + white-space: nowrap; + background-color: #e9ecef; + border: 1px solid #ced4da; + border-radius: 0.25rem; + } + + .input-group-text input[type="radio"], + .input-group-text input[type="checkbox"] { + margin-top: 0; + } + + .input-group > .input-group-prepend > .btn, + .input-group > .input-group-prepend > .input-group-text, + .input-group > .input-group-append:not(:last-child) > .btn, + .input-group > .input-group-append:not(:last-child) > .input-group-text, + .input-group > .input-group-append:last-child > .btn:not(:last-child):not(.dropdown-toggle), + .input-group > .input-group-append:last-child > .input-group-text:not(:last-child) { + border-top-right-radius: 0; + border-bottom-right-radius: 0; + } + + .input-group > .input-group-append > .btn, + .input-group > .input-group-append > .input-group-text, + .input-group > .input-group-prepend:not(:first-child) > .btn, + .input-group > .input-group-prepend:not(:first-child) > .input-group-text, + .input-group > .input-group-prepend:first-child > .btn:not(:first-child), + .input-group > .input-group-prepend:first-child > .input-group-text:not(:first-child) { + border-top-left-radius: 0; + border-bottom-left-radius: 0; + } + + .custom-control { + position: relative; + display: block; + min-height: 1.5rem; + padding-left: 1.5rem; + } + + .custom-control-inline { + display: -webkit-inline-box; + display: -ms-inline-flexbox; + display: inline-flex; + margin-right: 1rem; + } + + .custom-control-input { + position: absolute; + z-index: -1; + opacity: 0; + } + + .custom-control-input:checked ~ .custom-control-label::before { + color: #fff; + background-color: #007bff; + } + + .custom-control-input:focus ~ .custom-control-label::before { + box-shadow: 0 0 0 1px #fff, 0 0 0 0.2rem rgba(0, 123, 255, 0.25); + } + + .custom-control-input:active ~ .custom-control-label::before { + color: #fff; + background-color: #b3d7ff; + } + + .custom-control-input:disabled ~ .custom-control-label { + color: #6c757d; + } + + .custom-control-input:disabled ~ .custom-control-label::before { + background-color: #e9ecef; + } + + .custom-control-label { + margin-bottom: 0; + } + + .custom-control-label::before { + position: absolute; + top: 0.25rem; + left: 0; + display: block; + width: 1rem; + height: 1rem; + pointer-events: none; + content: ""; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + background-color: #dee2e6; + } + + .custom-control-label::after { + position: absolute; + top: 0.25rem; + left: 0; + display: block; + width: 1rem; + height: 1rem; + content: ""; + background-repeat: no-repeat; + background-position: center center; + background-size: 50% 50%; + } + + .custom-checkbox .custom-control-label::before { + border-radius: 0.25rem; + } + + .custom-checkbox .custom-control-input:checked ~ .custom-control-label::before { + background-color: #007bff; + } + + .custom-checkbox .custom-control-input:checked ~ .custom-control-label::after { + background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%23fff' d='M6.564.75l-3.59 3.612-1.538-1.55L0 4.26 2.974 7.25 8 2.193z'/%3E%3C/svg%3E"); + } + + .custom-checkbox .custom-control-input:indeterminate ~ .custom-control-label::before { + background-color: #007bff; + } + + .custom-checkbox .custom-control-input:indeterminate ~ .custom-control-label::after { + background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 4'%3E%3Cpath stroke='%23fff' d='M0 2h4'/%3E%3C/svg%3E"); + } + + .custom-checkbox .custom-control-input:disabled:checked ~ .custom-control-label::before { + background-color: rgba(0, 123, 255, 0.5); + } + + .custom-checkbox .custom-control-input:disabled:indeterminate ~ .custom-control-label::before { + background-color: rgba(0, 123, 255, 0.5); + } + + .custom-radio .custom-control-label::before { + border-radius: 50%; + } + + .custom-radio .custom-control-input:checked ~ .custom-control-label::before { + background-color: #007bff; + } + + .custom-radio .custom-control-input:checked ~ .custom-control-label::after { + background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3E%3Ccircle r='3' fill='%23fff'/%3E%3C/svg%3E"); + } + + .custom-radio .custom-control-input:disabled:checked ~ .custom-control-label::before { + background-color: rgba(0, 123, 255, 0.5); + } + + .custom-select { + display: inline-block; + width: 100%; + height: calc(2.25rem + 2px); + padding: 0.375rem 1.75rem 0.375rem 0.75rem; + line-height: 1.5; + color: #495057; + vertical-align: middle; + background: #fff url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 5'%3E%3Cpath fill='%23343a40' d='M2 0L0 2h4zm0 5L0 3h4z'/%3E%3C/svg%3E") no-repeat right 0.75rem center; + background-size: 8px 10px; + border: 1px solid #ced4da; + border-radius: 0.25rem; + -webkit-appearance: none; + -moz-appearance: none; + appearance: none; + } + + .custom-select:focus { + border-color: #80bdff; + outline: 0; + box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.075), 0 0 5px rgba(128, 189, 255, 0.5); + } + + .custom-select:focus::-ms-value { + color: #495057; + background-color: #fff; + } + + .custom-select[multiple], .custom-select[size]:not([size="1"]) { + height: auto; + padding-right: 0.75rem; + background-image: none; + } + + .custom-select:disabled { + color: #6c757d; + background-color: #e9ecef; + } + + .custom-select::-ms-expand { + opacity: 0; + } + + .custom-select-sm { + height: calc(1.8125rem + 2px); + padding-top: 0.375rem; + padding-bottom: 0.375rem; + font-size: 75%; + } + + .custom-select-lg { + height: calc(2.875rem + 2px); + padding-top: 0.375rem; + padding-bottom: 0.375rem; + font-size: 125%; + } + + .custom-file { + position: relative; + display: inline-block; + width: 100%; + height: calc(2.25rem + 2px); + margin-bottom: 0; + } + + .custom-file-input { + position: relative; + z-index: 2; + width: 100%; + height: calc(2.25rem + 2px); + margin: 0; + opacity: 0; + } + + .custom-file-input:focus ~ .custom-file-control { + border-color: #80bdff; + box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25); + } + + .custom-file-input:focus ~ .custom-file-control::before { + border-color: #80bdff; + } + + .custom-file-input:lang(en) ~ .custom-file-label::after { + content: "Browse"; + } + + .custom-file-label { + position: absolute; + top: 0; + right: 0; + left: 0; + z-index: 1; + height: calc(2.25rem + 2px); + padding: 0.375rem 0.75rem; + line-height: 1.5; + color: #495057; + background-color: #fff; + border: 1px solid #ced4da; + border-radius: 0.25rem; + } + + .custom-file-label::after { + position: absolute; + top: 0; + right: 0; + bottom: 0; + z-index: 3; + display: block; + height: calc(calc(2.25rem + 2px) - 1px * 2); + padding: 0.375rem 0.75rem; + line-height: 1.5; + color: #495057; + content: "Browse"; + background-color: #e9ecef; + border-left: 1px solid #ced4da; + border-radius: 0 0.25rem 0.25rem 0; + } + + .sr-only { + position: absolute; + width: 1px; + height: 1px; + padding: 0; + overflow: hidden; + clip: rect(0, 0, 0, 0); + white-space: nowrap; + -webkit-clip-path: inset(50%); + clip-path: inset(50%); + border: 0; + } + + .sr-only-focusable:active, .sr-only-focusable:focus { + position: static; + width: auto; + height: auto; + overflow: visible; + clip: auto; + white-space: normal; + -webkit-clip-path: none; + clip-path: none; + } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/feature-showcase.css b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/feature-showcase.css index e736e320..81d1ed95 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/feature-showcase.css +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/feature-showcase.css @@ -1,167 +1,169 @@ -@media screen and (max-width: 320px) { - .w3tc-card-container { - grid-template-columns: 1fr; - } +@media screen and (max-width: 900px) { + .w3tc-card-container { + grid-template-columns: 1fr 1fr; + } } -@media screen and (max-width: 900px) { - .w3tc-card-container { - grid-template-columns: 1fr 1fr; - } +@media screen and (max-width: 560px) { + .w3tc-card-container { + grid-template-columns: 1fr; + } } @media screen and (min-width: 900px) { - .w3tc-card-container { - grid-template-columns: 1fr 1fr 1fr; - } + .w3tc-card-container { + grid-template-columns: 1fr 1fr 1fr; + } } @media screen and (min-width: 1400px) { - .w3tc-card-container { - grid-template-columns: 1fr 1fr 1fr 1fr; - } + .w3tc-card-container { + grid-template-columns: 1fr 1fr 1fr 1fr; + } } .w3tc-page-container { - max-width: 1234px; - padding: 0; + max-width: 1234px; + padding: 0; } #w3tc_dashboard_banner { - max-width: 1234px; - width: 100%; + max-width: 1234px; + width: 100%; } .w3tc-card-container { - display: grid; - grid-gap: 2em; + display: grid; + grid-gap: 2em; } .w3tc-card { - background: #fff; - border: 1px solid #ddd; - display: flex; - flex-direction: column; - position: relative; + background: #fff; + border: 1px solid #ddd; + display: flex; + flex-direction: column; + position: relative; } .w3tc-card-title { - height: 2.5em; + height: 2.5em; } .w3tc-card-title.w3tc-card-premium { - background-color: #2d4149; + background-color: #2d4149; } -.w3tc-card-title.w3tc-card-premium > p { - color: #fff; +.w3tc-card-title.w3tc-card-premium>p { + color: #fff; } -.w3tc-card-title.w3tc-card-premium > p.w3tc-card-pro { - color: #30bec3; - margin: 0; +.w3tc-card-title.w3tc-card-premium>p.w3tc-card-pro { + color: #30bec3; + margin: 0; } -.w3tc-card-title > p:first-child { - font-size: 1.3em; - margin: 0; - white-space: nowrap; +.w3tc-card-title>p:first-child { + font-size: 1.3em; + margin: 0; + white-space: nowrap; } .w3tc-card-body { - flex-grow: 10; + flex-grow: 10; } .w3tc-card-title, .w3tc-card-body { - padding: 10px 10px 15px 10px; + padding: 10px 10px 15px 10px; } .w3tc-card-icon { - border-top: 3px solid #000; - border-bottom: 1px solid #ddd; - height: 60px; - padding: 20px 0; - text-align: center; + border-top: 3px solid #000; + border-bottom: 1px solid #ddd; + height: 60px; + padding: 20px 0; + text-align: center; } .w3tc-card-icon .dashicons { - font-size: 60px; - height: 60px; - width: 60px; + font-size: 60px; + height: 60px; + width: 60px; } .w3tc-card-icon-inactive { - border-top-color: #aaa; + border-top-color: #aaa; } .w3tc-card-icon img { - max-height: 60px; + max-height: 60px; } .w3tc-card-upgrade { - background: #e7e7e7; + background: #e7e7e7; } .w3tc-card-ribbon-new { - height: 75px; - overflow: hidden; - position: absolute; - right: -5px; top: -5px; - text-align: right; - width: 75px; - z-index: 1; - } + height: 75px; + overflow: hidden; + position: absolute; + right: -5px; + top: -5px; + text-align: right; + width: 75px; + z-index: 1; +} - .w3tc-card-ribbon-new span { - background: #30bec3; - box-shadow: 0 3px 10px -5px rgba(0, 0, 0, 0.5); - color: #fff; - display: block; - font-size: 12px; - font-weight: bold; - line-height: 20px; - position: absolute; - right: -21px; - text-transform: uppercase; - text-align: center; - top: 19px; - transform: rotate(45deg); - -webkit-transform: rotate(45deg); /* Needed for Safari */ - width: 100px; - } +.w3tc-card-ribbon-new span { + background: #30bec3; + box-shadow: 0 3px 10px -5px rgba(0, 0, 0, 0.5); + color: #fff; + display: block; + font-size: 12px; + font-weight: bold; + line-height: 20px; + position: absolute; + right: -21px; + text-transform: uppercase; + text-align: center; + top: 19px; + transform: rotate(45deg); + -webkit-transform: rotate(45deg); + /* Needed for Safari */ + width: 100px; +} - .w3tc-card-ribbon-new span::before { - border-left: 3px solid #30bec3; - border-right: 3px solid transparent; - border-bottom: 3px solid transparent; - border-top: 3px solid #30bec3; - content: ''; - left: 0px; - position: absolute; - top: 100%; - z-index: -1; - } +.w3tc-card-ribbon-new span::before { + border-left: 3px solid #30bec3; + border-right: 3px solid transparent; + border-bottom: 3px solid transparent; + border-top: 3px solid #30bec3; + content: ''; + left: 0px; + position: absolute; + top: 100%; + z-index: -1; +} - .w3tc-card-ribbon-new span::after { - border-right: 3px solid #30bec3; - border-left: 3px solid transparent; - border-bottom: 3px solid transparent; - border-top: 3px solid #30bec3; - content: ''; - position: absolute; - right: 0%; - top: 100%; - z-index: -1; - } +.w3tc-card-ribbon-new span::after { + border-right: 3px solid #30bec3; + border-left: 3px solid transparent; + border-bottom: 3px solid transparent; + border-top: 3px solid #30bec3; + content: ''; + position: absolute; + right: 0%; + top: 100%; + z-index: -1; +} - .w3tc-card-footer { - margin: 0 0 10px 10px; - } +.w3tc-card-footer { + margin: 0 0 10px 10px; +} - .w3tc-card-footer > div { - display: inline-block; - text-align: center; - vertical-align: middle; - width: 50%; - } +.w3tc-card-footer>div { + display: inline-block; + text-align: center; + vertical-align: middle; + width: 50%; +} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/options.css b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/options.css index 42135733..75742997 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/options.css +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/options.css @@ -1,10 +1,59 @@ -#w3tc h2.logo { - width: 224px; - height: 44px; - background: url("../img/W3TC_dashboard_logo_title.png") top right no-repeat; - text-indent: -9999px; - margin:5px 0 10px 0; - padding:0; +#wpcontent { + padding-right: 20px; +} + +#wpcontent #w3tc, +#wpcontent #w3tc_dashboard_banner, +#wpcontent .w3tc-page-container { + max-width: 1200px; + margin: 1em auto 0; +} + +#wpbody-content>.update-nag, +#wpbody-content>.notice, +#wpbody-content>.error { + max-width: 1200px; + margin: 0 auto 5px !important; + padding: 10px 12px !important; + display: block; + box-sizing: border-box; +} + +#wpbody-content>.update-nag p, +#wpbody-content>.notice p, +#wpbody-content>.error p { + padding: 0 !important; + margin: 0 !important; +} + +#wpbody-content>.update-nag.is-dismissible p, +#wpbody-content>.notice.is-dismissible p, +#wpbody-content>.error.is-dismissible p { + padding: 0 29px 0 0 !important; +} + +#wpbody-content>.updated.w3tc_note, +#wpbody-content>.error.w3tc_error { + max-width: 1200px; + margin: 0 auto 5px !important; + padding: 10px 12px !important; + display: block; + box-sizing: border-box; +} + +#wpbody-content>.updated.w3tc_note p, +#wpbody-content>.error.w3tc_error p { + margin: 0; + padding: 0; +} + +#wpbody-content>.updated.w3tc_note.is-dismissible p, +#wpbody-content>.error.w3tc_error.is-dismissible p { + margin: 0 29px 0 0; +} + +#w3tc_form { + margin-top: 10px; } #icon-w3tc_general { @@ -13,37 +62,51 @@ .w3tc-enabled { color: #090; - font-weight: 700 + font-weight: 700; } .w3tc-disabled { color: #f00; - font-weight: 700 + font-weight: 700; } .w3tc-empty { font-weight: 700; - font-style: italic + font-style: italic; } .w3tc-success { - background: #bfb + background: #bfb; } .w3tc-error { - background: #f99 + background: #f99; } + div.w3tc-error.inline { display:inline-block; } -input.w3tc-error, textarea.w3tc-error { + +input.w3tc-error, +textarea.w3tc-error { background: none; - border: 1px solid #f99 + border: 1px solid #f99; } +input.w3tc-error, +textarea.w3tc-error { + background: none; + border: 1px solid #f99; +} + +#memcached_test_status, +#redis_test_status { + display: inline-block; + vertical-align: top; +} .w3tc-status { - padding: 5px + padding: 5px; } #w3tc-help ul { @@ -60,8 +123,35 @@ input.w3tc-error, textarea.w3tc-error { text-decoration: underline; } +#w3tc>#w3tc-breadcrumb { + vertical-align: middle; + margin-bottom: 20px; +} + +#w3tc>#w3tc-breadcrumb a { + text-decoration: none; +} + +#w3tc>#w3tc-breadcrumb .dashicons-admin-home { + vertical-align: text-bottom; +} + +#w3tc>#w3tc-breadcrumb .dashicons-arrow-right-alt2 { + font-size: 14px; + vertical-align: sub; +} + +#w3tc>#w3tc-options-menu { + position: sticky; + top: 80px; + background: #f0f0f1; + z-index: 3; + margin: 0; + padding: 5px 0; +} + #w3tc acronym { - border-bottom: 1px dotted #666 + border-bottom: 1px dotted #666; } #w3tc ul { @@ -78,7 +168,7 @@ input.w3tc-error, textarea.w3tc-error { margin-bottom: 0; } -#w3tc ul.w3tc-incomp-plugins li div{ +#w3tc ul.w3tc-incomp-plugins li div { width: 150px; display: inline-block; } @@ -100,38 +190,42 @@ input.w3tc-error, textarea.w3tc-error { } #w3tc h5 { - margin: 0 + margin: 0; } #w3tc hr { clear: both; - margin-top: 10px + margin-top: 10px; } -#w3tc #toc a, #qa a { - text-decoration: none +#toc a, +#qa a { + text-decoration: none; } -#w3tc #toc a:hover, #qa a:hover { - text-decoration: underline +#toc a:hover, +#qa a:hover { + text-decoration: underline; } -#w3tc #toc ul { +#toc ul { margin: 0; - padding: 0 + padding: 0; } -#w3tc #toc li { +#toc li { margin: 0; - padding: 0 + padding: 0; } -#w3tc #qa { +#qa { clear: both; padding: 10px; } -#w3tc #qa, #w3tc #about, #w3tc #install { +#qa, +#about, +#install { width: 760px; } @@ -165,7 +259,7 @@ input.w3tc-error, textarea.w3tc-error { color: #000; margin: 1em 0; overflow: auto; - background: #eee; + background: #ffffff; padding: 12px 15px; border: 1px solid #ccc; } @@ -192,7 +286,8 @@ input.w3tc-error, textarea.w3tc-error { background: #e9e9e9; } -#cdn_cnames li span, .w3tc_cdn_cname_comment { +#cdn_cnames li span, +.w3tc_cdn_cname_comment { padding-left: 10px; color: #999; } @@ -212,7 +307,7 @@ input.w3tc-error, textarea.w3tc-error { .w3tc_cachegroups li { cursor: ns-resize; list-style: none; - background: #f0f0f0; + background: #f9f9f9; margin-bottom: 1em; border-radius: 8px; -webkit-border-radius: 8px; @@ -222,7 +317,7 @@ input.w3tc-error, textarea.w3tc-error { #mobile_groups li:hover, #referrer_groups li:hover, .w3tc_cachegroups li:hover { - background: #e9e9e9; + background: #f5f5f5; } #mobile_groups li table, @@ -272,7 +367,8 @@ input.w3tc-error, textarea.w3tc-error { text-align: left; } -#support_loading, .w3tc-checking { +#support_loading, +.w3tc-checking { height: 32px; background: url(../img/wpspin_light.gif) left center no-repeat; padding-left: 38px; @@ -280,40 +376,126 @@ input.w3tc-error, textarea.w3tc-error { margin: 1em 0; font-weight: bold; } + #w3tc .postbox .inside { padding: 0 10px; } -#w3tc .postbox .hndle { +#w3tc .postbox .postbox-title { cursor: auto; - border-bottom: 1px solid #ccd0d4; /* WP 5.5 */ + border-bottom: 1px solid #ccd0d4; + /* WP 5.5 */ } -#w3tc .postbox-header { - border-bottom: 0; /* WP 5.5 */ +.performance_page_w3tc_general #preview-button { + padding: 0; + color: #2271b1; + background: unset; + border: unset; + text-decoration: underline; + box-shadow: unset; } -#w3tc .postbox .handlediv { - float: right; /* WP 5.5 */ +.performance_page_w3tc_general #preview-button:hover { + color: #135e96; } -#pgcache_reject_roles label, #newrelic_accept_roles label, #cdn_reject_roles label { +#w3tc .postbox-tabs { + margin-bottom: 50px; + border: unset; + box-shadow: unset; + background: unset; +} + +#w3tc .postbox-tabs .inside { + padding: 5px 15px; + background: #fff; + border: 1px solid #c3c4c7; + box-shadow: 0 1px 1px rgba(0, 0, 0, .04); + margin-top: 0; +} + +#w3tc .postbox-tabs .postbox-title { + cursor: auto; + margin: 20px 0; + border: unset; +} + +#w3tc .postbox-tabs .postbox-description { + margin: 20px 0 25px; +} + +#w3tc .postbox-tabs .form-table th { + padding: 20px 0; +} + +#w3tc .postbox-tabs table:not(.w3tc-pro-feature) .w3tc-gopro { + margin: 5px 0; +} + +#pgcache_reject_roles label, +#newrelic_accept_roles label, +#cdn_reject_roles label { margin-right: 15px; } -#minify_form fieldset{ +#w3tc .postbox-tabs .nav-tab-wrapper { + border-bottom: unset; +} + +#w3tc .postbox-tabs .nav-tab-wrapper .nav-tab-active { + background: #ffffff; +} + +#w3tc .postbox-tabs .nav-tab-wrapper .nav-tab { + border-bottom: 1px solid #c3c4c7; + margin: 0 .5em -1px 0; + padding: 2px 8px; + font-size: 14px; + font-weight: normal; +} + +#w3tc .postbox-tabs .nav-tab-wrapper .nav-tab.link-tab { + background: #ffffff; + color: #2271b1; +} + +#w3tc .postbox-tabs .nav-tab-wrapper .nav-tab.link-tab:hover { + background: #f6f7f7; + color: #135e96; +} + +#w3tc .postbox-tabs .nav-tab-wrapper .nav-tab .dashicons { + font-size: 16px; + height: 13px; + line-height: 25px; + vertical-align: top !important; +} + +#w3tc .postbox-header { + border-bottom: 0; + /* WP 5.5 */ +} + +#pgcache_reject_roles label, +#newrelic_accept_roles label, +#cdn_reject_roles label { + margin-right: 15px; +} + +#minify_form fieldset { padding-bottom: 10px; } -#minify_form .html-tag{ +#minify_form .html-tag { font-weight: bold; color: #107e0e; float: right; } -#minify_form fieldset label{ +#minify_form fieldset label { margin-bottom: 5px; - margin-right:10px; + margin-right: 10px; } #minify_table td { @@ -334,21 +516,27 @@ input.w3tc-error, textarea.w3tc-error { } .recom_js_type { - width:160px; + width: 160px; } + .w3tc-missing-files ul { - margin-left:5px; + margin-left: 5px; } -#w3tc .updated p, #w3tc_dashboard p, #w3tc_general p, #w3tc_cdn p { line-height: 30px} +#w3tc .updated p, +#w3tc_dashboard p, +#w3tc_general p, +#w3tc_cdn p { line-height: 30px} -#w3tc .updated p, #w3tc_general p, #w3tc_cdn p { line-height: 30px} +#w3tc .updated p, +#w3tc_general p, +#w3tc_cdn p { line-height: 30px} -#w3tc #application ul { +#application ul { margin-top:0; } -#monitoring td label{ +#monitoring td label { display: block; } @@ -361,26 +549,35 @@ input.w3tc-error, textarea.w3tc-error { font-family: courier, sans-serif; } -.minify_auto_test, .w3tc-loading { +.minify_auto_test, +.w3tc-loading { height: 16px; background: url(../img/wpspin_light.gif) right top no-repeat; width: 16px; } + .create-error p { - margin:0; + margin: 0; } + .create-error { padding: 3px; - display:none; + display: none; } #w3tc_extensions table.extensions .column-name { - width:180px; + width: 180px; } + #wpbody-content .metabox-holder.extension-settings { padding-top: 0; } +#wpbody-content .metabox-holder .postbox { + box-shadow: unset; + scroll-margin-top: 136px; +} + #w3tc .subsubsub { margin-left: 0; } @@ -394,7 +591,7 @@ td.w3tc-td-with-button { } .w3tc_loading { - position:absolute; + position: absolute; width: 100%; text-align: center; } @@ -410,6 +607,7 @@ td.w3tc-td-with-button { th.w3tc_config_checkbox { padding-top: 15px; } + td.w3tc_config_value_text { padding-top: 20px; } @@ -450,8 +648,10 @@ td.w3tc_config_value_text { font-weight: normal; } -/*---*/ -/* js bound to id */ + +/** + * JS bound to id + */ th.w3tc_extensions_manage_column_check { padding: 0 0 0 5px; @@ -460,8 +660,8 @@ th.w3tc_extensions_manage_column_check { } #browsercache_security_xfo_allow { - padding-top:0; - padding-bottom:4px; + padding-top: 0; + padding-bottom: 4px; } .lightbox-content-padded { @@ -482,7 +682,7 @@ th.w3tc_extensions_manage_column_check { /** - * Go pro features. + * Go pro features */ .w3tc-gopro-more .dashicons { @@ -508,6 +708,7 @@ th.w3tc_extensions_manage_column_check { background: green; color: #fff; } + .button.w3tc-gopro-button:hover, .button.w3tc-gopro-button:focus { border-color: green; @@ -517,17 +718,111 @@ th.w3tc_extensions_manage_column_check { } table:not(.w3tc-pro-feature) .w3tc-gopro { - border-left: 3px solid green; margin: 5px -20px 5px -13px; box-shadow: 0 5px 5px -3px #888; background: #efefef; padding: 10px; - background-image: linear-gradient( to right, #f1f1f1, #f1f1f1, #f1f1f1, #f1f1f1, #e7f3f3, #56bec1, #16252c ); + background-image: linear-gradient( to right, #f0f0f1, #f0f0f1, #f0f0f1, #f0f0f1, #e7f3f3, #56bec1, #16252c); position: relative; padding-right: 280px; + border: 1px solid #c3c4c7; } -/* Pro features on the Extensions page. */ +.w3tc-gopro-ribbon { + height: 75px; + overflow: hidden; + position: absolute; + left: -5px; + top: -5px; + text-align: right; + width: 75px; + z-index: 1; +} + +.w3tc-gopro-ribbon>span { + background: #30bec3; + box-shadow: 0 3px 10px -5px rgba(0, 0, 0, 0.5); + color: #fff; + display: block; + font-size: 12px; + font-weight: 900; + line-height: 20px; + position: absolute; + right: -3px; + text-transform: uppercase; + text-align: center; + top: 17px; + width: 100px; + padding-bottom: 1px; + -webkit-transform: rotate(-45deg); + transform: rotate(-45deg); +} + +.w3tc-gopro-ribbon>span .w3tc-gopro-ribbon-star { + font-size: 16px; + line-height: 13px; +} + +.w3tc-gopro-ribbon>span::before { + border-left: 3px solid #30bec3; + border-right: 3px solid transparent; + border-bottom: 3px solid transparent; + border-top: 3px solid #30bec3; + content: ''; + left: 0px; + position: absolute; + top: 100%; + z-index: -1; +} + +.w3tc-gopro-ribbon>span::after { + border-right: 3px solid #30bec3; + border-left: 3px solid transparent; + border-bottom: 3px solid transparent; + border-top: 3px solid #30bec3; + content: ''; + position: absolute; + right: 0%; + top: 100%; + z-index: -1; +} + +.w3tc-gopro-content { + padding-left: 60px; +} + +.w3tc-gopro-action { + padding-left: 60px; +} + +.w3tc-gopro-action .w3tc-gopro-button { + border: unset; + background: unset; + outline: unset; + padding: 0; + box-shadow: unset; + color: #2271b1; + text-decoration: underline; + font-size: 14px; + line-height: 1.3; + transition-property: border, background, color; + transition-duration: .05s; + transition-timing-function: ease-in-out; +} + +.w3tc-gopro-action .w3tc-gopro-button:hover, +.w3tc-gopro-action .w3tc-gopro-button:focus { + color: #135e96; + border-color: unset; + box-shadow: unset; + background: unset; +} + + +/** + * Pro features on the Extensions page + */ + #the-list .w3tc-gopro { margin-right: -10px; padding-right: 196px; @@ -535,7 +830,7 @@ table:not(.w3tc-pro-feature) .w3tc-gopro { /** - * A Table for a pro feature. + * A Table for a pro feature */ table.w3tc-pro-feature { @@ -553,7 +848,7 @@ table:not(.w3tc-pro-feature) .w3tc-gopro:after { background-repeat: no-repeat; background-position: top right; background-size: 100% 100%; - content:""; + content: ""; width: 321px; height: 174px; position: absolute; @@ -578,55 +873,32 @@ table.w3tc-pro-feature th { } table.w3tc-pro-feature td { - background-image: linear-gradient( to right, #f1f1f1, #f1f1f1, #f1f1f1, #e7f3f3, #56bec1, #16252c ); + background-image: linear-gradient( to right, #f0f0f1, #f0f0f1, #f0f0f1, #e7f3f3, #56bec1, #16252c); padding-right: 401.25px; } -/* Size of comet background for pro features not in a pro table. */ +/* Size of comet background for pro features not in a pro table */ table:not(.w3tc-pro-feature) .w3tc-gopro:after { width: 280px; height: 152px; } -/* Size of comet background for pro features on Extensions page. */ +/* Size of comet background for pro features on Extensions page */ #the-list .plugin-description .w3tc-gopro:after { width: 196px; height: 106px; } -@media ( max-width: 782px ) { - table.w3tc-pro-feature:after { - background-image: none; - } - - table.w3tc-pro-feature td { - background-image: none; - } - - table.w3tc-pro-feature td { - padding: 12px; - } - - /* Pro features that aren't a . A for example - User Experience > Lazy Load Google Maps. */ - table:not(.w3tc-pro-feature) .w3tc-gopro { - padding-right: initial; - background: #efefef; - } - - table:not(.w3tc-pro-feature) .w3tc-gopro:after { - background: none; - } -} /** - * Banner ad on dashboard. + * Banner ad on dashboard */ #w3tc_dashboard_banner { margin-right: 200px; } -#w3tc #w3tc_dashboard_banner .inside { +#w3tc_dashboard_banner .inside { background-image: url("../img/transparent-comet-moon.png"), linear-gradient( to right, #fff 60%, #56bec1 100% ); background-repeat: no-repeat; background-position: top right; @@ -635,12 +907,12 @@ table:not(.w3tc-pro-feature) .w3tc-gopro:after { padding: 0 250px 12px 12px; } -#w3tc_dashboard_banner .inside > p:first-of-type { +#w3tc_dashboard_banner .inside>p:first-of-type { margin-top: 0; padding-top: 1em; } -#w3tc_dashboard_banner .postbox .hndle { +#w3tc_dashboard_banner .postbox .postbox-title { background: #eee; border-bottom: 3px solid #65bbbd; } @@ -654,16 +926,16 @@ table:not(.w3tc-pro-feature) .w3tc-gopro:after { } @media screen and (max-width: 960px) { - #w3tc #w3tc_dashboard_banner { + #w3tc_dashboard_banner { margin: 45px auto auto auto; } - #w3tc #w3tc_dashboard_banner .inside { + #w3tc_dashboard_banner .inside { background: none; padding: 12px; } - #w3tc #w3tc_dashboard_banner .inside > p:first-of-type { + #w3tc_dashboard_banner .inside > p:first-of-type { padding-top: initial; } } @@ -686,12 +958,16 @@ table:not(.w3tc-pro-feature) .w3tc-gopro:after { } .w3tc-label-danger { - /* Same color as "update plugin count" in WP Dashboard left nav. */ - background: #ca4a1f;; + background: #ca4a1f; /* Same color as "update plugin count" in WP Dashboard left nav. */ + ; } -/* Learn more links */ -a > span.dashicons-external { + +/** + * Learn more links + */ + +a>span.dashicons-external { text-decoration: none; } @@ -707,3 +983,522 @@ td .w3tc-control-after span { .w3tc-ftp-form input[type="password"] { width: 100%; } + + +/** + * Top navigation bar + */ + +#screen-meta-links { + position: relative; + top: 49px; + margin-bottom: -50px; + z-index: 9; +} + +#w3tc-top-nav-bar { + margin: 0 -20px 15px; + background: #ffffff; + position: sticky; + top: 32px; + z-index: 10; + box-shadow: 0 1px 0 #ccd0d4, 0 1px 1px 1px rgba(0, 0, 0, 0.04); +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content { + max-width: 1200px; + margin: 0 auto; + padding: 0 15px; + display: flex; + align-items: center; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content .logo-link { + float: left; + width: 30%; + min-width: 215px; + text-align: left; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content .logo-link h2.logo { + height: 40px; + background: url("../img/W3TC_dashboard_logo_title.png") top left no-repeat; + background-size: contain; + background-origin: content-box; + text-indent: -9999px; + margin: 4px 0; + padding: 0; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links { + float: right; + width: 70%; + text-align: right; + font-size: 0; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links .w3tc-top-nav-dropdown { + position: relative; + display: inline-block; + margin-left: 4px; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links .w3tc-top-nav-dropdown .dashicons { + font-size: 14px; + vertical-align: middle; + display: inline; + margin-left: 4px; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links .w3tc-top-nav-dropdown:hover .w3tc-top-nav-dropdown-content { + display: block; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links .w3tc-top-nav-dropdown-content { + display: none; + position: absolute; + background-color: #f9f9f9; + width: 160px; + box-shadow: 0px 0px 2px 0px #c3c4c7; + z-index: 1; + top: 30px; + right: 0; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links a { + color: #2271b1; + text-decoration: none; + font-size: 13px; + text-align: center; + line-height: 2.15384615; + display: inline-block; + min-height: 30px; + padding: 0 10px; + cursor: pointer; + border-radius: 3px; + border: 1px solid #ffffff; + box-sizing: border-box; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links a.no-link { + cursor: default; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links input { + box-shadow: unset; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links>a:hover, +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links .w3tc-top-nav-dropdown:hover>a { + background-color: #f0f0f1; + border: 1px solid #2271b1; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links>a, +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links input { + margin-left: 4px; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links input.button-buy-plugin, +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links a.w3tc-gopro-button { + border-color: darkgreen; + box-shadow: 0 1px 0 darkgreen; + background: green; + color: #fff; + box-shadow: unset; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links input.button-buy-plugin:hover, +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links input.button-buy-plugin:focus, +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links a.w3tc-gopro-button:hover, +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links a.w3tc-gopro-button:focus { + border-color: green; + box-shadow: 0 1px 0 green; + background: #009900; + box-shadow: unset; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links .w3tc-top-nav-dropdown-content>a { + color: #2271b1; + border: unset; + padding: 5px 15px; + display: block; + text-align: left; +} + +#w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links .w3tc-top-nav-dropdown-content>a:hover { + background-color: #f0f0f1; +} + + +/** + * Footer + */ + +#w3tc-footer { + background: #ffffff; + box-shadow: 0 -1px 0 #ccd0d4, 0 -1px 1px 1px rgba(0, 0, 0, 0.04); + position: absolute; + left: 0; + right: 0; + margin-left: 160px; +} + +#w3tc-footer #w3tc-footer-container { + width: 100%; + max-width: 1200px; + padding: 10px 0; + margin: 0 auto; + display: flex; + column-gap: 20px; +} + +#w3tc-footer .w3tc-footer-link { + display: block; + width: 100%; + margin-bottom: 10px; + text-decoration: none; +} + +#w3tc-footer .w3tc-footer-link .dashicons { + color: #000000; + text-decoration: none; + margin-right: 5px; +} +#w3tc-footer .button-buy-plugin, +#w3tc-footer .w3tc-gopro-button { + margin-top: 10px; + white-space: normal; + float: left; + clear: both; + border-color: darkgreen; + box-shadow: 0 1px 0 darkgreen; + background: green; + color: #fff; + box-shadow: unset; +} + +#w3tc-footer .w3tc-footer-column-1 { + width: 20%; + margin-bottom: 15px; +} + +#w3tc-footer .w3tc-footer-column-2 { + width: 40%; + margin-bottom: 15px; +} + +#w3tc-footer .w3tc-footer-inner-column-50 { + width: 50%; + padding-right: 15px; + float: left; + box-sizing: border-box; +} + +#w3tc-footer .logo-link h2.logo { + height: 40px; + background: url("../img/W3TC_dashboard_logo_title.png") top left no-repeat; + background-size: contain; + background-origin: content-box; + text-indent: -9999px; + margin: .67em 0; + padding: 0 10px; +} + + +/** + * Button Save Dropdown + */ + +.w3tc_form_bar { + position: sticky; + top: 102px; + background: #f0f0f1; + z-index: 2; + display: flex; +} + +/* Adjusted for general settings page sticky sub-nav */ +.performance_page_w3tc_general .w3tc_form_bar { + top: 122px; +} + +/* Adjusted for pagecache settings page sticky sub-nav */ +.performance_page_w3tc_userexperience .w3tc_form_bar { + top: 80px; +} + +.w3tc_form_bar>#w3tc-options-menu { + width: 70%; + align-self: center; + padding: 5px 0; +} + +#w3tc_dashboard .w3tc_dashboard_flush_container { + margin: 10px 0; +} + +#w3tc_dashboard .w3tc_dashboard_flush_container>span { + vertical-align: middle; +} + +#w3tc_dashboard .w3tc-button-control-container { + display: inline-block; +} + +.w3tc_form_bar>.w3tc-button-control-container { + width: 30%; + min-width: 290px; + align-self: center; +} + +.w3tc_form_bar>.w3tc-button-control-container .w3tc-button-flush-dropdown, +.w3tc_form_bar>.w3tc-button-control-container .w3tc-button-save-dropdown { + margin-left: 5px; + float: right; +} + +.w3tc_form_bar.w3tc_form_bar_bordered { + border-bottom: 1px solid #c3c4c7; +} + +.w3tc-button-control-container { + padding: 10px 0 !important; + margin: 0 !important; +} + +.w3tc-button-control-container::after { + content: " "; + display: block; + height: 0; + clear: both; +} + +.w3tc-button-control-container>.btn-group a { + text-decoration: none; +} + +.w3tc-button-control-container .dropdown-menu { + padding: 0; + border: none; + box-shadow: 0px 0px 2px 0px #c3c4c7; +} + +.w3tc-button-control-container .dropdown-menu .dropdown-item { + font-size: 13px; + line-height: 2.15384615; + cursor: pointer; + margin: 0 0 3px 0; + box-sizing: border-box; + min-height: 30px; + background: #f9f9f9; + color: #2271b1; + padding: 5px 15px; + text-align: left; + border-radius: 3px; + box-shadow: 0 2px 0 1px #f9f9f9; +} + +.w3tc-button-control-container .dropdown-menu .dropdown-item:hover { + color: #2271b1; + background-color: #f0f0f1; + box-shadow: 0 2px 0 1px #f0f0f1; +} + +.w3tc-button-control-container .dropdown-menu .dropdown-item:focus { + box-shadow: 0 0 0 1px #4f94d4, 0 0 2px 1px rgba(79, 148, 212, .8); + outline: 1px solid transparent; +} + +.w3tc-button-control-container .dropdown-menu-right { + left: unset; + right: 0; +} + +.w3tc-button-control-container .w3tc-button-flush-dropdown>.btn { + color: #2271b1; + background: #f6f7f7; + border-color: #2271b1; + margin-right: 0; +} + +.w3tc-button-control-container .w3tc-button-flush-dropdown>.btn:hover { + background: #f0f0f1; +} + +.w3tc-button-control-container .w3tc-button-save-dropdown>.btn { + color: #ffffff; + background: #2271b1; + border-color: #2271b1; + margin-right: 0; +} + +.w3tc-button-control-container .w3tc-button-save-dropdown>.btn:hover { + background: #135e96; +} + +.w3tc-button-control-container .w3tc-button-save-dropdown>.btn:not(.dropdown-toggle) { + border-top: 1px solid #135e96; + border-right: 1px solid #ffffff; + border-bottom: 1px solid #135e96; + border-left: 1px solid #135e96; +} + +.w3tc-button-control-container .w3tc-button-save-dropdown>.dropdown-toggle { + border-top: 1px solid #135e96; + border-right: 1px solid #135e96; + border-bottom: 1px solid #135e96; + border-left: 1px solid #ffffff; +} + +.w3tc-button-control-container .w3tc-button-flush-dropdown>.btn:focus, +.w3tc-button-control-container .w3tc-button-save-dropdown>.btn:focus { + box-shadow: unset; +} + +.w3tc-button-control-container .w3tc-button-flush-dropdown>.dropdown-toggle-split, +.w3tc-button-control-container .w3tc-button-save-dropdown>.dropdown-toggle-split { + padding-left: 10px; + padding-right: 10px; +} + +.wufoo-form-container { + min-height: 725px; +} + +/* Hide admin notices on Setup Guide page */ +.performance_page_w3tc_setup_guide #wpbody-content>.update-nag, +.performance_page_w3tc_setup_guide #wpbody-content>.notice, +.performance_page_w3tc_setup_guide #wpbody-content>.error, +.performance_page_w3tc_setup_guide #wpbody-content>.updated.w3tc_note, +.performance_page_w3tc_setup_guide #wpbody-content>.error.w3tc_error { + display: none; +} + +@media screen and (max-width: 1200px) { + .w3tc_form_bar>#w3tc-options-menu, + .w3tc_form_bar>.w3tc-button-control-container { + width: 100%; + text-align: center; + } + .w3tc_form_bar { + flex-wrap: wrap; + } + .w3tc_form_bar .w3tc-button-control-container .w3tc-button-flush-dropdown, + .w3tc_form_bar .w3tc-button-control-container .w3tc-button-save-dropdown { + float: unset; + } +} + +@media screen and (max-width: 960px) { + #w3tc #w3tc_dashboard_banner { + margin: 45px auto auto auto; + } + #w3tc #w3tc_dashboard_banner .inside { + background: none; + padding: 12px; + } + #w3tc #w3tc_dashboard_banner .inside>p:first-of-type { + padding-top: initial; + } + #w3tc-footer { + width: calc(100% - 36px); + margin-left: 36px; + padding: 0 15px; + } + #w3tc-footer #w3tc-footer-container { + flex-wrap: wrap; + } + #w3tc-footer .w3tc-footer-column-1, + #w3tc-footer .w3tc-footer-column-2 { + width: 100%; + padding: 0 10px; + } + #w3tc-footer .logo-link h2.logo { + background-position: center; + } +} + +@media ( max-width: 782px) { + #wpcontent { + padding-right: 10px; + } + #screen-meta-links { + top: 43px; + } + #w3tc-top-nav-bar { + top: 46px; + } + #w3tc-top-nav-bar #w3tc-top-nav-bar-content .logo-link h2.logo { + height: 34px; + background: url("../img/w3tc_w3tc-logo.png") top left no-repeat; + background-size: auto; + background-origin: content-box; + } + #w3tc-top-nav-bar #w3tc-top-nav-bar-content .logo-link { + width: 10%; + min-width: 51px; + } + #w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links { + width: 90%; + } + #w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links>a, + #w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links>input, + #w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links .w3tc-top-nav-dropdown>a { + line-height: 2.71428571; + min-height: 40px; + font-size: 14px; + vertical-align: middle; + } + #w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links>input, + #w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links>a.w3tc-gopro-button { + margin-top: 3px; + } + #w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links .w3tc-top-nav-dropdown-content { + top: 40px; + } + #w3tc-footer { + margin-left: 0; + width: 100%; + } + table.w3tc-pro-feature:after { + background-image: none; + } + table.w3tc-pro-feature td { + background-image: none; + } + table.w3tc-pro-feature td { + padding: 12px; + } + + /* Pro features that aren't a
        . A for example - User Experience > Lazy Load Google Maps. */ + table:not(.w3tc-pro-feature) .w3tc-gopro { + padding-right: initial; + background: #efefef; + margin: 5px 0; + } + table:not(.w3tc-pro-feature) .w3tc-gopro:after { + background: none; + } + .w3tc-button-control-container .dropdown-menu .dropdown-item { + padding-left: 10px; + padding-right: 10px; + } + #memcached_test_status, + #redis_test_status { + display: inline-block; + vertical-align: middle; + } +} + +@media ( max-width: 600px) { + #w3tc-top-nav-bar { + top: 0px; + } + + #w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links>a, + #w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links>input, + #w3tc-top-nav-bar #w3tc-top-nav-bar-content #w3tc-top-nav-bar-content-links .w3tc-top-nav-dropdown>a { + padding: 0 5px; + } +} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/setup-guide.css b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/setup-guide.css index cf872230..fd75edd0 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/setup-guide.css +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/setup-guide.css @@ -29,3 +29,11 @@ hyphens: auto; overflow-wrap: break-word; } + +p#w3tc-breadcrumb { + margin-bottom: 0 !important; +} + +.w3tc-wizard-slides p { + line-height: 1.2em !important; +} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/wizard.css b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/wizard.css index cdd5ae24..08d5adb2 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/wizard.css +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/css/wizard.css @@ -1,177 +1,199 @@ /* Main container */ + #w3tc-wizard-container { - background: #fff; - padding: 10px; - border-radius: 8px; - max-width: 900px; + background: #fff; + padding: 10px; + border-radius: 8px; + max-width: 900px; } + /* Header */ + #w3tc_wizard_header { - background: #0e1920; - border-bottom: 6px solid #cdeae7; - height: 6em; - position: relative; + background: #0e1920; + border-bottom: 6px solid #cdeae7; + height: 6em; + position: relative; } + /* Main title */ + #w3tc_wizard_title { - color: #fff; - position: absolute; - bottom: 0; + color: #fff; + position: absolute; + bottom: 0; } + /* Title text: "TOTAL CACHE:" */ -#w3tc_wizard_title > span:nth-of-type(1), -#w3tc_wizard_title > span:nth-of-type(2), -#w3tc_wizard_title > span:nth-of-type(3) { - font-size: 2.5em; + +#w3tc_wizard_title>span:nth-of-type(1), +#w3tc_wizard_title>span:nth-of-type(2), +#w3tc_wizard_title>span:nth-of-type(3) { + font-size: 2.5em; } + /* Title text: "CACHE" */ -#w3tc_wizard_title > span:nth-of-type(2) { - color: #30bec4; + +#w3tc_wizard_title>span:nth-of-type(2) { + color: #30bec4; } + /* Title text: "$this->config['title']" */ -#w3tc_wizard_title > span:nth-of-type(4) { - font-size: 2.1em; - font-style: italic; + +#w3tc_wizard_title>span:nth-of-type(4) { + font-size: 2.1em; + font-style: italic; } + /* Wizard icon (w3 cube with shadow) */ + #w3tc_wizard_icon { - position: absolute; - top: 10px; - left: -2px; + position: absolute; + top: 10px; + left: -2px; } + /** * Left nav / steps. */ ul#w3tc-options-menu { - position: absolute; - left: 0; - top: 30px; - margin: 0; + position: absolute; + left: 0; + top: 30px; + margin: 0; } #w3tc-options-menu li { - display: block; - padding: 5px; - margin: 0; - border: 1px solid #ddd; - border-bottom: 0; + display: block; + padding: 5px; + margin: 0; + border: 1px solid #ddd; + border-bottom: 0; } #w3tc-options-menu li:last-of-type { - border-bottom: 1px solid #ddd; + border-bottom: 1px solid #ddd; } + /* Active step */ + #w3tc-options-menu li.is-active { - background-color: #0073aa; - color: #fff; + background-color: #0073aa; + color: #fff; } + /* Wizard content */ + #w3tc_wizard_content { - background-image: - url(../img/moon-bottom-left.png), - url(../img/moon-bottom-right.png); - background-size: 15% !Important; - background-repeat: - no-repeat, - no-repeat; - background-position: - bottom left, - bottom right; - background-size: - auto, - auto 60%; - min-height: 545px; - padding-bottom: 70px; - padding-right: 160px; - position: relative; + background-image: url(../img/moon-bottom-left.png), url(../img/moon-bottom-right.png); + background-size: 15% !Important; + background-repeat: no-repeat, no-repeat; + background-position: bottom left, bottom right; + background-size: auto, auto 60%; + min-height: 545px; + padding-right: 160px; + position: relative; } + +/* Wizard content slides */ + +#w3tc_wizard_content .w3tc-wizard-slides { + padding: 0 10px; +} + + /* Footer */ + #w3tc_wizard_footer { - width: 100%; + width: 100%; } + /* Buttons */ + #w3tc-wizard-buttons { - display: flex; + display: flex; } -#w3tc-wizard-buttons > span { - flex: 1; +#w3tc-wizard-buttons>span { + flex: 1; } + /* All buttons. */ -#w3tc-wizard-buttons > span > button { - width: 100%; - border: 0; - padding: 10px 0; - cursor: pointer; + +#w3tc-wizard-buttons>span>button { + width: 100%; + border: 0; + padding: 10px 0; + cursor: pointer; } + /* Next and Dashboard buttons. */ + #w3tc-wizard-next:enabled, #w3tc-wizard-dashboard { - background-color: #825772; - color: #fff; + background-color: #825772; + color: #fff; } + /* Miscellaneous */ + #w3tc_wizard_title, #w3tc_wizard_content { - padding-left: 160px; + padding-left: 160px; } .w3tc-overlay { - display: none; + display: none; } -#wpfooter { - position: relative; -} /* Spinner */ + .spinner.inline { - float: none; - visibility: visible; - vertical-align: top; - margin-left: 0px; + float: none; + visibility: visible; + vertical-align: top; + margin-left: 0px; } .spinner.spinner-left { - margin-left: 5px; + margin-left: 5px; } + /* Notices */ -.w3tc_note, -#setting-error-tgmpa { - display: none; - visibility: hidden; -} .w3tc-notice-recommended { - padding-top: 5px; + padding-top: 5px; } .w3tc-notice-recommended .dashicons-lightbulb { - color: #00a0d2; + color: #00a0d2; } #w3tc-dbcache-recommended { - margin: 10px 0px; + margin: 10px 0px; } + /* Tables */ + .widefat thead th, .widefat td { - line-height: 1em; + line-height: 1em; } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/lightbox.js b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/lightbox.js index f7a0ce2d..5af7a6ea 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/lightbox.js +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/lightbox.js @@ -60,16 +60,21 @@ var W3tc_Lightbox = { } else if (this.options.url) { this.load(this.options.url, this.options.callback); - if (typeof ga != 'undefined') { + if (window.w3tc_ga) { var w3tc_action = this.options.url.match(/w3tc_action=([^&]+)/); - if (window.w3tc_ga) { - if (w3tc_action && w3tc_action[1]) - w3tc_ga('send', 'pageview', 'overlays/' + w3tc_action[1]); - else { - var w3tc_action = this.options.url.match(/&(w3tc_[^&]+)&/); - if (w3tc_action && w3tc_action[1]) - w3tc_ga('send', 'pageview', 'overlays/' + w3tc_action[1]); - } + + if (! w3tc_action || ! w3tc_action[1]) { + w3tc_action = this.options.url.match(/&(w3tc_[^&]+)&/); + } + + if (w3tc_action && w3tc_action[1]) { + w3tc_ga( + 'event', + 'pageview', + { + eventLabel: 'overlays/' + w3tc_action[1] + } + ); } } } @@ -385,9 +390,7 @@ function w3tc_lightbox_self_test(nonce) { function w3tc_lightbox_upgrade(nonce, data_src, renew_key) { var client_id = ''; if (window.w3tc_ga) { - w3tc_ga(function(tracker) { - client_id = tracker.get('clientId'); - }); + client_id = w3tc_ga_cid; } W3tc_Lightbox.open({ @@ -412,9 +415,11 @@ function w3tc_lightbox_upgrade(nonce, data_src, renew_key) { jQuery('#w3tc-purchase-link', lightbox.container).on( 'click', function() { lightbox.close(); - jQuery([document.documentElement, document.body]).animate({ - scrollTop: jQuery("#licensing").offset().top - }, 2000); + if ( jQuery('#licensing').length ) { + jQuery([document.documentElement, document.body]).animate({ + scrollTop: jQuery('#licensing').offset().top + }, 2000); + } }); // Allow for customizations of the "upgrade" overlay specifically. @@ -444,7 +449,7 @@ function w3tc_lightbox_buy_plugin(nonce, data_src, renew_key, client_id) { var data = event.data.split(' '); if (data[0] === 'license') { // legacy purchase - w3tc_lightbox_save_licence_key(function() { + w3tc_lightbox_save_license_key(function() { lightbox.close(); }); } else if (data[0] === 'v2_license') { @@ -457,7 +462,7 @@ function w3tc_lightbox_buy_plugin(nonce, data_src, renew_key, client_id) { window.location = window.location + '&refresh'; } - w3tc_lightbox_save_licence_key(data[1], nonce, function() { + w3tc_lightbox_save_license_key(data[1], nonce, function() { jQuery('#buy_frame').attr('src', data[3]); }); } @@ -476,12 +481,12 @@ function w3tc_lightbox_buy_plugin(nonce, data_src, renew_key, client_id) { }); } -function w3tc_lightbox_save_licence_key(license_key, nonce, callback) { +function w3tc_lightbox_save_license_key(license_key, nonce, callback) { jQuery('#plugin_license_key').val(license_key); var params = { - w3tc_default_save_licence_key: 1, + w3tc_default_save_license_key: 1, license_key: license_key, - _wpnonce: nonce + _wpnonce: ('array' === jQuery.type(nonce)) ? nonce[0] : nonce }; jQuery.post('admin.php?page=w3tc_dashboard', params, function(data) { diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/options.js b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/options.js index e2da7f44..1229a321 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/options.js +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/options.js @@ -124,7 +124,8 @@ function w3tc_cdn_get_cnames() { } function w3tc_cdn_cnames_assign() { - var li = jQuery('#cdn_cnames li'), size = li.length; + var li = jQuery('#cdn_cnames li'), + size = li.length; if (size > 1) { li.eq(0).find('.cdn_cname_delete').show(); @@ -164,9 +165,10 @@ function w3tc_toggle(name, check) { check = true; } - var id = '#' + name, cls = '.' + name; + var id = '#' + name, + cls = '.' + name; - jQuery(cls).on( 'click', function() { + jQuery(cls).on('click', function() { var checked = check; jQuery(cls).each(function() { @@ -186,7 +188,7 @@ function w3tc_toggle(name, check) { } }); - jQuery(id).on( 'click', function() { + jQuery(id).on('click', function() { var checked = jQuery(this).is(':checked'); jQuery(cls).each(function() { if (checked) { @@ -199,11 +201,13 @@ function w3tc_toggle(name, check) { } function w3tc_toggle2(name, dependent_ids) { - var id = '#' + name, dependants = '', n; + var id = '#' + name, + dependants = '', + n; for (n = 0; n < dependent_ids.length; n++) dependants += (n > 0 ? ',' : '') + '#' + dependent_ids[n]; - jQuery(dependants).on( 'click', function() { + jQuery(dependants).on('click', function() { var total_checked = true; jQuery(dependants).each(function() { @@ -220,7 +224,7 @@ function w3tc_toggle2(name, dependent_ids) { } }); - jQuery(id).on( 'click', function() { + jQuery(id).on('click', function() { var checked = jQuery(this).is(':checked'); jQuery(dependants).each(function() { if (checked) { @@ -251,58 +255,51 @@ function w3tc_starts_with(s, starts_with) { } function w3tc_security_headers() { - var directive_description = - { - browsercache_security_hsts_directive: - { - maxage: 'The time, in seconds (as defined under the "Expires Header Lifetime" box of "Media & Other Files"), that the browser should remember that this site is only to be accessed using HTTPS. This only affects the site\'s main domain.', - maxagepre: 'The time, in seconds (as defined under the "Expires Header Lifetime" box of "Media & Other Files"), that the browser should remember that this site is only to be accessed using HTTPS with a request to be included in Chrome\'s HSTS preload list - a list of sites that are hardcoded into Chrome as being https only. This only affects the site\'s main domain.', - maxageinc: 'The time, in seconds (as defined under the "Expires Header Lifetime" box of "Media & Other Files"), that the browser should remember that this site is only to be accessed using HTTPS. This affects the site\'s subdomains as well.', - maxageincpre: 'The time, in seconds (as defined under the "Expires Header Lifetime" box of "Media & Other Files"), that the browser should remember that this site is only to be accessed using HTTPS with a request to be included in Chrome\'s HSTS preload list - a list of sites that are hardcoded into Chrome as being https only. This affects the site\'s subdomains as well.' - }, - browsercache_security_xfo_directive: - { - same: "The page can only be displayed in a frame on the same origin as the page itself.", - deny: "The page cannot be displayed in a frame, regardless of the site attempting to do so.", - allow: "The page can only be displayed in a frame on the specified URL." - }, - browsercache_security_xss_directive: - { - 0: "Disables XSS filtering.", - 1: "Enables XSS filtering (usually default in browsers). If a cross-site scripting attack is detected, the browser will sanitize the page (remove the unsafe parts).", - block: "Enables XSS filtering. Rather than sanitizing the page, the browser will prevent rendering of the page if an attack is detected." - }, - browsercache_security_pkp_extra: - { - maxage: 'The time, in seconds (as defined under the "Expires Header Lifetime" box of "Media & Other Files"), that the browser should remember that this site is only to be accessed using one of the defined keys. This only affects the site\'s main domain.', - maxageinc: 'The time, in seconds (as defined under the "Expires Header Lifetime" box of "Media & Other Files"), that the browser should remember that this site is only to be accessed using one of the defined keys. This affects the site\'s subdomains as well.' - }, - browsercache_security_pkp_report_only: - { - 0: 'This instructs the browser to enforce the HPKP policy.', - 1: 'This sets up HPKP without enforcement allowing you to use pinning to test its impact without the risk of a failed connection caused by your site being unreachable or HPKP being misconfigured.' - } - }; + var directive_description = { + browsercache_security_hsts_directive: { + maxage: 'The time, in seconds (as defined under the "Expires Header Lifetime" box of "Media & Other Files"), that the browser should remember that this site is only to be accessed using HTTPS. This only affects the site\'s main domain.', + maxagepre: 'The time, in seconds (as defined under the "Expires Header Lifetime" box of "Media & Other Files"), that the browser should remember that this site is only to be accessed using HTTPS with a request to be included in Chrome\'s HSTS preload list - a list of sites that are hardcoded into Chrome as being https only. This only affects the site\'s main domain.', + maxageinc: 'The time, in seconds (as defined under the "Expires Header Lifetime" box of "Media & Other Files"), that the browser should remember that this site is only to be accessed using HTTPS. This affects the site\'s subdomains as well.', + maxageincpre: 'The time, in seconds (as defined under the "Expires Header Lifetime" box of "Media & Other Files"), that the browser should remember that this site is only to be accessed using HTTPS with a request to be included in Chrome\'s HSTS preload list - a list of sites that are hardcoded into Chrome as being https only. This affects the site\'s subdomains as well.' + }, + browsercache_security_xfo_directive: { + same: "The page can only be displayed in a frame on the same origin as the page itself.", + deny: "The page cannot be displayed in a frame, regardless of the site attempting to do so.", + allow: "The page can only be displayed in a frame on the specified URL." + }, + browsercache_security_xss_directive: { + 0: "Disables XSS filtering.", + 1: "Enables XSS filtering (usually default in browsers). If a cross-site scripting attack is detected, the browser will sanitize the page (remove the unsafe parts).", + block: "Enables XSS filtering. Rather than sanitizing the page, the browser will prevent rendering of the page if an attack is detected." + }, + browsercache_security_pkp_extra: { + maxage: 'The time, in seconds (as defined under the "Expires Header Lifetime" box of "Media & Other Files"), that the browser should remember that this site is only to be accessed using one of the defined keys. This only affects the site\'s main domain.', + maxageinc: 'The time, in seconds (as defined under the "Expires Header Lifetime" box of "Media & Other Files"), that the browser should remember that this site is only to be accessed using one of the defined keys. This affects the site\'s subdomains as well.' + }, + browsercache_security_pkp_report_only: { + 0: 'This instructs the browser to enforce the HPKP policy.', + 1: 'This sets up HPKP without enforcement allowing you to use pinning to test its impact without the risk of a failed connection caused by your site being unreachable or HPKP being misconfigured.' + } + }; - jQuery('#browsercache_security_hsts_directive,#browsercache_security_xfo_directive,#browsercache_security_xss_directive,#browsercache_security_pkp_extra,#browsercache_security_pkp_report_only').on( 'change', - function() { - jQuery('#' + jQuery(this).attr('id') + '_description').html('' + directive_description[jQuery(this).attr('id')][jQuery(this).val()] + ''); + jQuery('#browsercache_security_hsts_directive,#browsercache_security_xfo_directive,#browsercache_security_xss_directive,#browsercache_security_pkp_extra,#browsercache_security_pkp_report_only').on('change', + function() { + jQuery('#' + jQuery(this).attr('id') + '_description').html('' + directive_description[jQuery(this).attr('id')][jQuery(this).val()] + ''); if (jQuery(this).attr('id') == 'browsercache_security_xfo_directive') { if (jQuery(this).val() == 'allow') { jQuery('#browsercache_security_xfo_allow').show(); - }else { + } else { jQuery('#browsercache_security_xfo_allow').hide(); } } - }); + }); - if(jQuery('#browsercache_security_xfo_allow').length) { + if (jQuery('#browsercache_security_xfo_allow').length) { if (jQuery('#browsercache_security_xfo_directive').val() == 'allow') { jQuery('#browsercache_security_xfo_allow').show(); } else { jQuery('#browsercache_security_xfo_allow').hide(); } - jQuery('#browsercache_security_hsts_directive,#browsercache_security_xfo_directive,#browsercache_security_xss_directive,#browsercache_security_pkp_extra,#browsercache_security_pkp_report_only').on( 'change', ); } } @@ -315,28 +312,28 @@ function w3tc_csp_reference() { url: ajaxurl + '?action=w3tc_ajax&_wpnonce=' + w3tc_nonce + '&w3tc_action=browsercache_quick_reference', }); - jQuery('div#overlay,.lightbox-content').on( 'click', function() { + jQuery('div#overlay,.lightbox-content').on('click', function() { W3tc_Lightbox.close(); }); } function cdn_cf_check() { // Prevents JS error for non W3TC pages. - if ( typeof w3tcData === 'undefined' ) { + if (typeof w3tcData === 'undefined') { return; } - var cdnEnabled = jQuery( '#cdn__enabled' ).is( ':checked' ), - cdnEngine = jQuery( '#cdn__engine' ).find( ':selected' ).val(), - cdnFlushManually = jQuery( '[name="cdn__flush_manually"]' ).is( ':checked' ); + var cdnEnabled = jQuery('#cdn__enabled').is(':checked'), + cdnEngine = jQuery('#cdn__engine').find(':selected').val(), + cdnFlushManually = jQuery('[name="cdn__flush_manually"]').is(':checked'); // Remove any cf admin notices. - jQuery( '.w3tc-cf-notice' ).remove(); + jQuery('.w3tc-cf-notice').remove(); // General page. - if ( ! w3tcData.cdnFlushManually && cdnEnabled && ( 'cf' === cdnEngine || 'cf2' === cdnEngine ) ) { + if (!w3tcData.cdnFlushManually && cdnEnabled && ('cf' === cdnEngine || 'cf2' === cdnEngine)) { // Print cf admin notice. - jQuery( '#cdn .inside' ).prepend( + jQuery('#cdn .inside').prepend( '

        ' + w3tcData.cfWarning + '

        ' @@ -344,22 +341,59 @@ function cdn_cf_check() { } // CDN page. - if ( ! cdnFlushManually && w3tcData.cdnEnabled && ( 'cf' === w3tcData.cdnEngine || 'cf2' === w3tcData.cdnEngine ) ) { + if (!cdnFlushManually && w3tcData.cdnEnabled && ('cf' === w3tcData.cdnEngine || 'cf2' === w3tcData.cdnEngine)) { // Show warning on the CDN page for flush manually. - jQuery( '#cdn-flushmanually-warning' ).show(); + jQuery('#cdn-flushmanually-warning').show(); } else { // Hide warning on the CDN page for flush manually. - jQuery( '#cdn-flushmanually-warning' ).hide(); + jQuery('#cdn-flushmanually-warning').hide(); } } +function set_sticky_bar_positions() { + jQuery('#w3tc > #w3tc-options-menu').css( + 'top', + Math.floor( + ((jQuery(window).width() > 600 && jQuery('#wpadminbar').length) ? jQuery('#wpadminbar').outerHeight() : 0) + + jQuery('#w3tc-top-nav-bar').outerHeight() + ) + ); + jQuery('.w3tc_form_bar').css( + 'top', + Math.floor( + ((jQuery(window).width() > 600 && jQuery('#wpadminbar').length) ? jQuery('#wpadminbar').outerHeight() : 0) + + jQuery('#w3tc-top-nav-bar').outerHeight() + + ((jQuery('#w3tc > #w3tc-options-menu').length) ? jQuery('#w3tc > #w3tc-options-menu').outerHeight() : 0) + ) + ); +} + + +function set_footer_position() { + jQuery('#w3tc-footer').insertAfter(jQuery('#wpfooter')); + jQuery('#w3tc-footer').css( + 'bottom', + Math.floor(0 - jQuery('#w3tc-footer').outerHeight()) + ); +} + +function debounce(func){ + var timer; + return function(event){ + if(timer){ + clearTimeout(timer); + } + timer = setTimeout(func,100,event); + }; +} + jQuery(function() { // general page - jQuery('.w3tc_read_technical_info').on( 'click', function() { + jQuery('.w3tc_read_technical_info').on('click', function() { jQuery('.w3tc_technical_info').toggle(); }); - jQuery('#plugin_license_key_verify').on( 'click', function() { + jQuery('#plugin_license_key_verify').on('click', function() { jQuery('.w3tc_license_verification').html("Checking..."); var license_key = jQuery('#plugin_license_key').val(); @@ -392,57 +426,54 @@ jQuery(function() { // When CDN is enabled as "cf" or "cf2", then display a notice about possible charges. cdn_cf_check(); - jQuery( '#cdn__enabled' ).on( 'click', cdn_cf_check ); - jQuery( '#cdn__engine' ).on( 'change', cdn_cf_check ); + jQuery('#cdn__enabled').on('click', cdn_cf_check); + jQuery('#cdn__engine').on('change', cdn_cf_check); /** * CDN page. * When CDN is enabled as "cf" or "cf2", then display a notice about possible charges. */ - jQuery( '[name="cdn__flush_manually"]' ).on( 'click', cdn_cf_check ); + jQuery('[name="cdn__flush_manually"]').on('click', cdn_cf_check); // pagecache page w3tc_input_enable('#pgcache_reject_roles input[type=checkbox]', jQuery('#pgcache__reject__logged_roles:checked').length); - jQuery('#pgcache__reject__logged_roles').on('click', function () { + jQuery('#pgcache__reject__logged_roles').on('click', function() { w3tc_input_enable('#pgcache_reject_roles input[type=checkbox]', jQuery('#pgcache__reject__logged_roles:checked').length); }); - if(jQuery('#pgcache__cache__nginx_handle_xml').is('*')) - jQuery('#pgcache__cache__nginx_handle_xml').attr('checked',jQuery('#pgcache__cache__feed').is(':checked')); + if (jQuery('#pgcache__cache__nginx_handle_xml').is('*')) + jQuery('#pgcache__cache__nginx_handle_xml').attr('checked', jQuery('#pgcache__cache__feed').is(':checked')); - jQuery('#pgcache__cache__feed').on( 'change', function(){ - if(jQuery('#pgcache__cache__nginx_handle_xml').is('*')) - jQuery('#pgcache__cache__nginx_handle_xml').attr('checked',this.checked); + jQuery('#pgcache__cache__feed').on('change', function() { + if (jQuery('#pgcache__cache__nginx_handle_xml').is('*')) + jQuery('#pgcache__cache__nginx_handle_xml').attr('checked', this.checked); }); // browsercache page - w3tc_toggle2('browsercache_last_modified', - ['browsercache__cssjs__last_modified', 'browsercache__html__last_modified', - 'browsercache__other__last_modified']); - w3tc_toggle2('browsercache_expires', - ['browsercache__cssjs__expires', 'browsercache__html__expires', - 'browsercache__other__expires']); - w3tc_toggle2('browsercache_cache_control', - ['browsercache__cssjs__cache__control', 'browsercache__html__cache__control', - 'browsercache__other__cache__control']); - w3tc_toggle2('browsercache_etag', - ['browsercache__cssjs__etag', 'browsercache__html__etag', - 'browsercache__other__etag']); - w3tc_toggle2('browsercache_w3tc', - ['browsercache__cssjs__w3tc', 'browsercache__html__w3tc', - 'browsercache__other__w3tc']); - w3tc_toggle2('browsercache_compression', - ['browsercache__cssjs__compression', 'browsercache__html__compression', - 'browsercache__other__compression']); - w3tc_toggle2('browsercache_brotli', - ['browsercache__cssjs__brotli', 'browsercache__html__brotli', - 'browsercache__other__brotli']); - w3tc_toggle2('browsercache_replace', - ['browsercache__cssjs__replace', 'browsercache__other__replace']); - w3tc_toggle2('browsercache_querystring', - ['browsercache__cssjs__querystring', 'browsercache__other__querystring']); - w3tc_toggle2('browsercache_nocookies', - ['browsercache__cssjs__nocookies', 'browsercache__other__nocookies']); + w3tc_toggle2('browsercache_last_modified', ['browsercache__cssjs__last_modified', 'browsercache__html__last_modified', + 'browsercache__other__last_modified' + ]); + w3tc_toggle2('browsercache_expires', ['browsercache__cssjs__expires', 'browsercache__html__expires', + 'browsercache__other__expires' + ]); + w3tc_toggle2('browsercache_cache_control', ['browsercache__cssjs__cache__control', 'browsercache__html__cache__control', + 'browsercache__other__cache__control' + ]); + w3tc_toggle2('browsercache_etag', ['browsercache__cssjs__etag', 'browsercache__html__etag', + 'browsercache__other__etag' + ]); + w3tc_toggle2('browsercache_w3tc', ['browsercache__cssjs__w3tc', 'browsercache__html__w3tc', + 'browsercache__other__w3tc' + ]); + w3tc_toggle2('browsercache_compression', ['browsercache__cssjs__compression', 'browsercache__html__compression', + 'browsercache__other__compression' + ]); + w3tc_toggle2('browsercache_brotli', ['browsercache__cssjs__brotli', 'browsercache__html__brotli', + 'browsercache__other__brotli' + ]); + w3tc_toggle2('browsercache_replace', ['browsercache__cssjs__replace', 'browsercache__other__replace']); + w3tc_toggle2('browsercache_querystring', ['browsercache__cssjs__querystring', 'browsercache__other__querystring']); + w3tc_toggle2('browsercache_nocookies', ['browsercache__cssjs__nocookies', 'browsercache__other__nocookies']); w3tc_security_headers(); @@ -454,19 +485,19 @@ jQuery(function() { w3tc_minify_js_theme(jQuery('#js_themes').val()); w3tc_minify_css_theme(jQuery('#css_themes').val()); - jQuery('#minify__html__enable').on( 'click', function() { + jQuery('#minify__html__enable').on('click', function() { w3tc_input_enable('.html_enabled', this.checked); }); - jQuery('#minify__js__enable').on( 'click', function() { + jQuery('#minify__js__enable').on('click', function() { w3tc_input_enable('.js_enabled', jQuery(this).is(':checked')); }); - jQuery('#minify__css__enable').on( 'click', function() { + jQuery('#minify__css__enable').on('click', function() { w3tc_input_enable('.css_enabled', jQuery(this).is(':checked')); }); - jQuery('.js_file_verify,.css_file_verify').on('click', function () { + jQuery('.js_file_verify,.css_file_verify').on('click', function() { var file = jQuery(this).parents('li').find(':text').val(); if (file == '') { alert('Empty URI'); @@ -481,19 +512,19 @@ jQuery(function() { } }); - jQuery('.js_file_template').on('change', function () { + jQuery('.js_file_template').on('change', function() { jQuery(this).parents('li').find(':text').attr('name', 'js_files[' + jQuery('#js_themes').val() + '][' + jQuery(this).val() + '][' + jQuery(this).parents('li').find('.js_file_location').val() + '][]'); }); - jQuery('.css_file_template').on('change', function () { + jQuery('.css_file_template').on('change', function() { jQuery(this).parents('li').find(':text').attr('name', 'css_files[' + jQuery('#css_themes').val() + '][' + jQuery(this).val() + '][include][]'); }); - jQuery('.js_file_location').on('change', function () { + jQuery('.js_file_location').on('change', function() { jQuery(this).parents('li').find(':text').attr('name', 'js_files[' + jQuery('#js_themes').val() + '][' + jQuery(this).parents('li').find('.js_file_template').val() + '][' + jQuery(this).val() + '][]'); }); - jQuery('.js_file_delete').on('click', function () { + jQuery('.js_file_delete').on('click', function() { var parent = jQuery(this).parents('li'); if (parent.find('input[type=text]').val() == '' || confirm('Are you sure you want to remove this JS file?')) { parent.remove(); @@ -504,7 +535,7 @@ jQuery(function() { return false; }); - jQuery('.css_file_delete').on('click', function () { + jQuery('.css_file_delete').on('click', function() { var parent = jQuery(this).parents('li'); if (parent.find('input[type=text]').val() == '' || confirm('Are you sure you want to remove this CSS file?')) { parent.remove(); @@ -515,27 +546,36 @@ jQuery(function() { return false; }); - jQuery('#js_file_add').on( 'click', function() { + jQuery('#js_file_add').on('click', function() { w3tc_minify_js_file_add(jQuery('#js_themes').val(), 'default', 'include', ''); }); - jQuery('#css_file_add').on( 'click', function() { + jQuery('#css_file_add').on('click', function() { w3tc_minify_css_file_add(jQuery('#css_themes').val(), 'default', ''); }); - jQuery('#js_themes').on( 'change', function() { + jQuery('#js_themes').on('change', function() { w3tc_minify_js_theme(jQuery(this).val()); }); - jQuery('#css_themes').on( 'change', function() { + jQuery('#css_themes').on('change', function() { w3tc_minify_css_theme(jQuery(this).val()); }); - jQuery('#minify_form').on( 'submit', function() { - var js = [], css = [], invalid_js = [], invalid_css = [], duplicate = false, query_js = [], query_css = []; + jQuery('#minify_form').on('submit', function() { + var js = [], + css = [], + invalid_js = [], + invalid_css = [], + duplicate = false, + query_js = [], + query_css = []; jQuery('#js_files :text').each(function() { - var v = jQuery(this).val(), n = jQuery(this).attr('name'), c = v + n, g = ''; + var v = jQuery(this).val(), + n = jQuery(this).attr('name'), + c = v + n, + g = ''; var match = /js_files\[([a-z0-9_\/]+)\]/.exec(n); if (match) { g = '[' + jQuery('#js_themes option[value=' + match[1] + ']').text() + '] ' + v; @@ -563,7 +603,10 @@ jQuery(function() { }); jQuery('#css_files :text').each(function() { - var v = jQuery(this).val(), n = jQuery(this).attr('name'), c = v + n, g = ''; + var v = jQuery(this).val(), + n = jQuery(this).attr('name'), + c = v + n, + g = ''; var match = /css_files\[([a-z0-9_\/]+)\]/.exec(n); if (match) { g = '[' + jQuery('#css_themes option[value=' + match[1] + ']').text() + '] ' + v; @@ -621,54 +664,54 @@ jQuery(function() { }); // CDN - jQuery('.w3tc-tab').on( 'click', function() { + jQuery('.w3tc-tab').on('click', function() { jQuery('.w3tc-tab-content').hide(); jQuery(this.rel).show(); }); w3tc_input_enable('#cdn_reject_roles input[type=checkbox]', jQuery('#cdn__reject__logged_roles:checked').length); - jQuery('#cdn__reject__logged_roles').on('click', function () { + jQuery('#cdn__reject__logged_roles').on('click', function() { w3tc_input_enable('#cdn_reject_roles input[type=checkbox]', jQuery('#cdn__reject__logged_roles:checked').length); }); - jQuery('#cdn_export_library').on( 'click', function() { + jQuery('#cdn_export_library').on('click', function() { w3tc_popup('admin.php?page=w3tc_cdn&w3tc_cdn_export_library&_wpnonce=' + jQuery(this).metadata().nonce, 'cdn_export_library'); }); - jQuery('#cdn_import_library').on( 'click', function() { + jQuery('#cdn_import_library').on('click', function() { w3tc_popup('admin.php?page=w3tc_cdn&w3tc_cdn_import_library&_wpnonce=' + jQuery(this).metadata().nonce, 'cdn_import_library'); }); - jQuery('#cdn_queue').on( 'click', function() { + jQuery('#cdn_queue').on('click', function() { w3tc_popup('admin.php?page=w3tc_cdn&w3tc_cdn_queue&_wpnonce=' + jQuery(this).metadata().nonce, 'cdn_queue'); }); - jQuery('#cdn_rename_domain').on( 'click', function() { + jQuery('#cdn_rename_domain').on('click', function() { w3tc_popup('admin.php?page=w3tc_cdn&w3tc_cdn_rename_domain&_wpnonce=' + jQuery(this).metadata().nonce, 'cdn_rename_domain'); }); - jQuery('#cdn_purge').on( 'click', function() { + jQuery('#cdn_purge').on('click', function() { w3tc_popup('admin.php?page=w3tc_cdn&w3tc_cdn_purge&_wpnonce=' + jQuery(this).metadata().nonce, 'cdn_purge'); }); - jQuery('.cdn_export').on( 'click', function() { + jQuery('.cdn_export').on('click', function() { var metadata = jQuery(this).metadata(); w3tc_popup('admin.php?page=w3tc_cdn&w3tc_cdn_export&cdn_export_type=' + metadata.type + '&_wpnonce=' + metadata.nonce, 'cdn_export_' + metadata.type); }); - jQuery('#validate_cdn_key').on( 'click', function() { - var me = jQuery(this); - var metadata = me.metadata(); - w3tc_validate_cdn_key_result(metadata.type, metadata.nonce); + jQuery('#validate_cdn_key').on('click', function() { + var me = jQuery(this); + var metadata = me.metadata(); + w3tc_validate_cdn_key_result(metadata.type, metadata.nonce); }); - jQuery('#use_poll_zone').on( 'click', function() { - var me = jQuery(this); - var metadata = me.metadata(); - w3tc_use_poll_zone(metadata.type, metadata.nonce); + jQuery('#use_poll_zone').on('click', function() { + var me = jQuery(this); + var metadata = me.metadata(); + w3tc_use_poll_zone(metadata.type, metadata.nonce); }); - jQuery('#cdn_test').on( 'click', function() { + jQuery('#cdn_test').on('click', function() { var me = jQuery(this); var metadata = me.metadata(); var cnames = w3tc_cdn_get_cnames(); @@ -779,7 +822,8 @@ jQuery(function() { break; case 'cotendo': - var zones = [], zones_val = jQuery('#cdn_cotendo_zones').val(); + var zones = [], + zones_val = jQuery('#cdn_cotendo_zones').val(); if (zones_val) { zones = zones_val.split(/[\r\n,;]+/); @@ -800,7 +844,8 @@ jQuery(function() { } break; case 'akamai': - var emails = [], emails_val = jQuery('#cdn_akamai_email_notification').val(); + var emails = [], + emails_val = jQuery('#cdn_akamai_email_notification').val(); if (emails_val) { emails = emails_val.split(/[\r\n,;]+/); @@ -872,7 +917,7 @@ jQuery(function() { }); }); - jQuery('#cdn_create_container').on('click', function () { + jQuery('#cdn_create_container').on('click', function() { var me = jQuery(this); var metadata = me.metadata(); var cnames = w3tc_cdn_get_cnames(); @@ -984,53 +1029,53 @@ jQuery(function() { }); }); - jQuery('#memcached_test').on( 'click', function() { + jQuery('#memcached_test').on('click', function() { var status = jQuery('#memcached_test_status'); status.removeClass('w3tc-error'); status.removeClass('w3tc-success'); status.addClass('w3tc-process'); status.html('Testing...'); jQuery.post('admin.php?page=w3tc_dashboard', { - w3tc_test_memcached: 1, - servers: jQuery('#memcached_servers').val(), - binary_protocol: jQuery('[id$=__memcached__binary_protocol]').is(':checked'), - username: jQuery('#memcached_username').val(), - password: jQuery('#memcached_password').val(), - _wpnonce: jQuery(this).metadata().nonce - }, function(data) { - status.addClass(data.result ? 'w3tc-success' : 'w3tc-error'); - status.html(data.error); - }, 'json') - .fail(function() { - status.addClass('w3tc-error'); - status.html('Request failed'); - }); + w3tc_test_memcached: 1, + servers: jQuery('#memcached_servers').val().replace(/(\r\n|\r|\n)/g,','), + binary_protocol: jQuery('[id$=__memcached__binary_protocol]').is(':checked'), + username: jQuery('#memcached_username').val(), + password: jQuery('#memcached_password').val(), + _wpnonce: jQuery(this).metadata().nonce + }, function(data) { + status.addClass(data.result ? 'w3tc-success' : 'w3tc-error'); + status.html(data.error); + }, 'json') + .fail(function() { + status.addClass('w3tc-error'); + status.html('Request failed'); + }); }); - jQuery('.w3tc_common_redis_test').on( 'click', function() { + jQuery('.w3tc_common_redis_test').on('click', function() { var status = jQuery('.w3tc_common_redis_test_result'); status.removeClass('w3tc-error'); status.removeClass('w3tc-success'); status.addClass('w3tc-process'); status.html('Testing...'); jQuery.post('admin.php?page=w3tc_dashboard', { - w3tc_test_redis: 1, - servers: jQuery('#redis_servers').val(), - verify_tls_certificates: jQuery('[id$=__redis__verify_tls_certificates]').is(':checked'), - dbid : jQuery('#redis_dbid').val(), - password : jQuery('#redis_password').val(), - _wpnonce: jQuery(this).metadata().nonce - }, function(data) { - status.addClass(data.result ? 'w3tc-success' : 'w3tc-error'); - status.html(data.error); - }, 'json') - .fail(function() { - status.addClass('w3tc-error'); - status.html('Request failed'); - }); + w3tc_test_redis: 1, + servers: jQuery('#redis_servers').val().replace(/(\r\n|\r|\n)/g,','), + verify_tls_certificates: jQuery('[id$=__redis__verify_tls_certificates]').is(':checked'), + dbid: jQuery('#redis_dbid').val(), + password: jQuery('#redis_password').val(), + _wpnonce: jQuery(this).metadata().nonce + }, function(data) { + status.addClass(data.result ? 'w3tc-success' : 'w3tc-error'); + status.html(data.error); + }, 'json') + .fail(function() { + status.addClass('w3tc-error'); + status.html('Request failed'); + }); }); - jQuery('.minifier_test').on( 'click', function() { + jQuery('.minifier_test').on('click', function() { var me = jQuery(this); var metadata = me.metadata(); var params = { @@ -1088,7 +1133,7 @@ jQuery(function() { jQuery(this).trigger("size_change"); }); - jQuery('.cdn_cname_delete').on('click', function () { + jQuery('.cdn_cname_delete').on('click', function() { var p = jQuery(this).parent(); if (p.find('input[type=text]').val() == '' || confirm('Are you sure you want to remove this CNAME?')) { p.remove(); @@ -1097,8 +1142,9 @@ jQuery(function() { } }); - jQuery('#cdn_form').on( 'submit', function() { - var cnames = [], ret = true; + jQuery('#cdn_form').on('submit', function() { + var cnames = [], + ret = true; jQuery('#cdn_cnames input[type=text]').each(function() { var cname = jQuery(this).val(); @@ -1154,8 +1200,9 @@ jQuery(function() { } // show hide rules - jQuery('.w3tc-show-rules').on( 'click', function() { - var btn = jQuery(this), rules = btn.parent().find('.w3tc-rules'); + jQuery('.w3tc-show-rules').on('click', function() { + var btn = jQuery(this), + rules = btn.parent().find('.w3tc-rules'); if (rules.is(':visible')) { rules.css('display', 'none'); @@ -1168,8 +1215,9 @@ jQuery(function() { // show hide missing files - jQuery('.w3tc-show-required-changes').on( 'click', function() { - var btn = jQuery(this), rules = jQuery('.w3tc-required-changes'); + jQuery('.w3tc-show-required-changes').on('click', function() { + var btn = jQuery(this), + rules = jQuery('.w3tc-required-changes'); if (rules.is(':visible')) { rules.css('display', 'none'); @@ -1181,8 +1229,9 @@ jQuery(function() { }); // show hide missing files - jQuery('.w3tc-show-ftp-form').on( 'click', function() { - var btn = jQuery(this), rules = jQuery('.w3tc-ftp-form'); + jQuery('.w3tc-show-ftp-form').on('click', function() { + var btn = jQuery(this), + rules = jQuery('.w3tc-ftp-form'); if (rules.is(':visible')) { rules.css('display', 'none'); @@ -1194,8 +1243,9 @@ jQuery(function() { }); // show hide missing files - jQuery('.w3tc-show-technical-info').on( 'click', function() { - var btn = jQuery(this), info = jQuery('.w3tc-technical-info'); + jQuery('.w3tc-show-technical-info').on('click', function() { + var btn = jQuery(this), + info = jQuery('.w3tc-technical-info'); if (info.is(':visible')) { info.css('display', 'none'); @@ -1212,13 +1262,13 @@ jQuery(function() { }); // toggle hiddent content - jQuery('.w3tc_link_more').on( 'click', function() { + jQuery('.w3tc_link_more').on('click', function() { var target_class = jQuery(this).metadata().for_class; jQuery('.' + target_class).slideToggle(); }); // check for unsaved changes - jQuery('#w3tc input,#w3tc select,#w3tc textarea').on('change', function () { + jQuery('#w3tc input,#w3tc select,#w3tc textarea').on('change', function() { var ignore = false; jQuery(this).parents().addBack().each(function() { if (jQuery(this).hasClass('w3tc-ignore-change') || jQuery(this).hasClass('lightbox')) { @@ -1235,18 +1285,19 @@ jQuery(function() { jQuery('body').on('click', '.w3tc-button-save', w3tc_beforeupload_unbind); - jQuery('.contextual-help-tabs ul li a').on( 'click', function() { + jQuery('.contextual-help-tabs ul li a').on('click', function() { var id = jQuery(this).attr('aria-controls'); var i = jQuery('#' + id + ' .w3tchelp_content'); w3tc_load_faq_section(i); }); - jQuery('#contextual-help-link').on( 'click', function() { + jQuery('#contextual-help-link').on('click', function() { var i = jQuery('.w3tchelp_content').first(); w3tc_load_faq_section(i); }); var w3tchelp_loaded = {}; + function w3tc_load_faq_section(i) { var section = i.data('section'); @@ -1271,7 +1322,7 @@ jQuery(function() { } // extensions page - jQuery('.w3tc_extensions_manage_input_checkall').on( 'click', function(v) { + jQuery('.w3tc_extensions_manage_input_checkall').on('click', function(v) { var c = jQuery(this).is(':checked'); jQuery('.w3tc_extensions_manage_input_checkall').prop('checked', c); @@ -1282,7 +1333,7 @@ jQuery(function() { }); // gopro block - jQuery('.w3tc-gopro-more').on( 'click', function(e) { + jQuery('.w3tc-gopro-more').on('click', function(e) { e.preventDefault(); if (!jQuery(this).data('expanded')) { jQuery(this).data('expanded', '1'); @@ -1295,37 +1346,172 @@ jQuery(function() { } if (window.w3tc_ga) { - w3tc_ga('send', 'event', 'anchor', 'click', - jQuery(this).data('href')); + w3tc_ga( + 'event', + 'anchor', + { + eventCategory: 'click', + eventLabel: jQuery(this).data('href') + } + ); } - }); - // google analytics events + // Bootstrap dropdown toggle + jQuery('.dropdown-toggle').on('click', function() { + jQuery('.dropdown-toggle').not(this).next().hide(); + jQuery(this).next().toggle(); + }); + + // Bootstrap dropdown hide on click away + jQuery(document).mouseup(function(e) { + var dropdowns = jQuery('.dropdown-toggle'); + if (!dropdowns.is(e.target) && dropdowns.has(e.target).length === 0) { + dropdowns.next().hide(); + } + }); + + // Options menu achor links + jQuery('#w3tc-top-nav-bar a').on('click', function(e) { + if (window.w3tc_ga) { + w3tc_ga( + 'event', + { + eventCategory: 'w3tc_topnav_bar', + eventAction: 'link', + eventLabel: jQuery(this).text() + } + ); + } + }); + + // Options menu achor links + jQuery('#w3tc-options-menu a').on('click', function(e) { + if (window.w3tc_ga) { + w3tc_ga( + 'event', + { + eventCategory: 'w3tc_options_menu', + eventAction: 'anchor', + eventLabel: jQuery(this).text() + } + ); + } + }); + + // Form control bar buttons + jQuery('.w3tc_form_bar input').on('click', function(e) { + if (window.w3tc_ga) { + w3tc_ga( + 'event', + { + eventCategory: 'w3tc_form_bar', + eventAction: 'button', + eventLabel: jQuery(this).text() + } + ); + } + }); + + // Footer links + jQuery('#w3tc-footer a').on('click', function(e) { + if (window.w3tc_ga) { + w3tc_ga( + 'event', + { + eventCategory: 'w3tc_footer', + eventAction: 'link', + eventLabel: jQuery(this).text() + } + ); + } + }); + + // General settings advanced options links + jQuery('.advanced-settings a').on('click', function(e) { + if (window.w3tc_ga) { + w3tc_ga( + 'event', + { + eventCategory: 'w3tc_general_advanced_tab', + eventAction: 'link', + eventLabel: jQuery(this).attr('gatitle') + } + ); + } + }); + + // Extra links + jQuery('.extra-link a').on('click', function(e) { + if (window.w3tc_ga) { + w3tc_ga( + 'event', + { + eventCategory: 'w3tc_general_extra_link_tab', + eventAction: 'link', + eventLabel: jQuery(this).attr('gatitle') + } + ); + } + }); + + // Analytics events. if (typeof w3tc_ga != 'undefined') { jQuery('.w3tc_error').each(function() { var id = jQuery(this).attr('id'); var text = jQuery(this).text(); - if (id && window.w3tc_ga) - w3tc_ga('send', 'event', 'w3tc_error', id, text); + if (id && window.w3tc_ga) { + w3tc_ga( + 'event', + 'w3tc_error', + { + eventCategory: id, + eventLabel: text + } + ); + } }); jQuery('.w3tc_note').each(function() { var id = jQuery(this).attr('id'); var text = jQuery(this).text(); - if (id && window.w3tc_ga) - w3tc_ga('send', 'event', 'w3tc_note', id, text); + if (id && window.w3tc_ga) { + w3tc_ga( + 'event', + 'w3tc_note', + { + eventCategory: id, + eventLabel: text + } + ); + } }); jQuery('body').on('click', 'a', function() { var url = jQuery(this).attr('href'); - if (url && window.w3tc_ga) - w3tc_ga('send', 'event', 'anchor', 'click', url, {useBeacon: true}); + if (url && window.w3tc_ga) { + w3tc_ga( + 'event', + 'anchor', + { + eventCategory: 'click', + eventLabel: url + } + ); + } }); jQuery('body').on('click', 'input[type="button"]', function() { var name = jQuery(this).attr('name'); - if (name && window.w3tc_ga) - w3tc_ga('send', 'event', 'button', 'click', name, {useBeacon: true}); + if (name && window.w3tc_ga) { + w3tc_ga( + 'event', + 'button', + { + eventCategory: 'click', + eventLabel: name + } + ); + } }); jQuery('body').on('click', 'input[type="submit"]', function() { var name = jQuery(this).attr('name'); @@ -1333,24 +1519,98 @@ jQuery(function() { if (!id) id = name; - if (name && window.w3tc_ga) - w3tc_ga('send', 'event', 'button', id, name, {useBeacon: true}); + if (name && window.w3tc_ga) { + w3tc_ga( + 'event', + 'button', + { + eventCategory: id, + eventLabel: name + } + ); + } }); jQuery('body').on('click', 'input[type="checkbox"]', function() { var name = jQuery(this).attr('name'); var action = jQuery(this).is(':checked') ? 'check' : 'uncheck'; - if (name && window.w3tc_ga) - w3tc_ga('send', 'event', 'checkbox', action, name); + if (name && window.w3tc_ga) { + w3tc_ga( + 'event', + 'checkbox', + { + eventCategory: action, + eventLabel: name + } + ); + } }); jQuery('body').on('change', 'select', function() { var name = jQuery(this).attr('name'); var value = jQuery(this).val(); - if (name && value && window.w3tc_ga) - w3tc_ga('send', 'event', 'select', value, name); + if (name && value && window.w3tc_ga) { + w3tc_ga( + 'event', + 'select', + { + eventCategory: value, + eventLabel: name + } + ); + } }); } + + jQuery("a").on('click', function(event) { + if (this.hash !== "" && this.href.replace(this.hash, '') === window.location.href.replace(window.location.hash, '')) { + event.preventDefault(); + var hash = this.hash, + wpadminbar_height = (jQuery(window).width() > 600 && jQuery('#wpadminbar').length) ? jQuery('#wpadminbar').outerHeight() : 0, + nav_bar_height = (jQuery('#w3tc-top-nav-bar').length) ? jQuery('#w3tc-top-nav-bar').outerHeight() : 0, + options_menu_height = (jQuery('#w3tc > #w3tc-options-menu').length) ? jQuery('#w3tc > #w3tc-options-menu').outerHeight() : 0, + form_bar_height = (jQuery('.w3tc_form_bar').length) ? jQuery('.w3tc_form_bar').outerHeight() : 0; + jQuery('html, body').animate({ + scrollTop: jQuery(hash.replace(/\./g, '\\.')).offset().top - wpadminbar_height - nav_bar_height - options_menu_height - form_bar_height + }, + 600 + ); + } + }); + + var hash = window.location.hash; + if (hash !== "") { + // Start at top of page rather than instantly loading at the anchor point + window.scrollTo(0, 0); + var wpadminbar_height = (jQuery(window).width() > 600 && jQuery('#wpadminbar').length) ? jQuery('#wpadminbar').outerHeight() : 0, + nav_bar_height = (jQuery('#w3tc-top-nav-bar').length) ? jQuery('#w3tc-top-nav-bar').outerHeight() : 0, + options_menu_height = (jQuery('#w3tc > #w3tc-options-menu').length) ? jQuery('#w3tc > #w3tc-options-menu').outerHeight() : 0, + form_bar_height = (jQuery('.w3tc_form_bar').length) ? jQuery('.w3tc_form_bar').outerHeight() : 0; + // Scroll to taget after .5 seconds + setTimeout( + function() { + jQuery('html, body').animate({ + scrollTop: jQuery(hash.replace(/\./g, '\\.')).offset().top - wpadminbar_height - nav_bar_height - options_menu_height - form_bar_height + }, + 600 + ); + }, + 500 + ); + } + + jQuery(window).resize( + debounce( + function() { + console.log('resize'); + set_sticky_bar_positions(); + set_footer_position(); + } + ) + ); + + set_sticky_bar_positions(); + set_footer_position(); }); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/setup-guide.js b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/setup-guide.js index b57b2d86..c3c3d8b4 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/setup-guide.js +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/setup-guide.js @@ -17,8 +17,14 @@ jQuery(function() { // GA. if ( w3tc_enable_ga ) { - w3tc_ga( 'create', W3TC_SetupGuide.ga_profile, 'auto' ); - w3tc_ga( 'send', 'event', 'button', 'w3tc_setup_guide', 'w3tc-wizard-step-welcome' ); + w3tc_ga( + 'event', + 'button', + { + eventCategory: 'w3tc_setup_guide', + eventLabel: 'w3tc-wizard-step-welcome' + } + ); } // Handle the terms of service notice. @@ -54,28 +60,36 @@ jQuery(function() { if ( 'accept' === choice ) { W3TC_SetupGuide.tos_choice = choice; - (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ - (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), - m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) - })(window,document,'script','https://api.w3-edge.com/v1/analytics','w3tc_ga'); + var gaScript = document.createElement( 'script' ); + gaScript.type = 'text/javascript'; + gaScript.setAttribute( 'async', 'true' ); + gaScript.setAttribute( 'src', 'https://www.googletagmanager.com/gtag/js?id=' + W3TC_SetupGuide.ga_profile ); + document.documentElement.firstChild.appendChild( gaScript ); + + window.dataLayer = window.dataLayer || []; + + const w3tc_ga = function() { dataLayer.push( arguments ); } if (window.w3tc_ga) { - w3tc_ga( 'create', W3TC_SetupGuide.ga_profile, 'auto' ); - w3tc_ga( 'set', { - 'dimension1': 'w3-total-cache', - 'dimension2': W3TC_SetupGuide.w3tc_version, - 'dimension3': W3TC_SetupGuide.wp_version, - 'dimension4': W3TC_SetupGuide.php_version, - 'dimension5': W3TC_SetupGuide.server_software, - 'dimension6': W3TC_SetupGuide.db_version, - 'dimension7': W3TC_SetupGuide.home_url_host, - 'dimension9': W3TC_SetupGuide.install_version, - 'dimension10': W3TC_SetupGuide.w3tc_edition, - 'dimension11': W3TC_SetupGuide.list_widgets, - 'page': W3TC_SetupGuide.page - }); + w3tc_enable_ga = true; - w3tc_ga( 'send', 'pageview' ); + w3tc_ga( 'js', new Date() ); + + w3tc_ga( 'config', W3TC_SetupGuide.ga_profile, { + 'user_properties': { + 'plugin': 'w3-total-cache', + 'w3tc_version': W3TC_SetupGuide.w3tc_version, + 'wp_version': W3TC_SetupGuide.wp_version, + 'php_version': W3TC_SetupGuide.php_version, + 'server_software': W3TC_SetupGuide.server_software, + 'wpdb_version': W3TC_SetupGuide.db_version, + 'home_url': W3TC_SetupGuide.home_url_host, + 'w3tc_install_version': W3TC_SetupGuide.install_version, + 'w3tc_edition': W3TC_SetupGuide.w3tc_edition, + 'w3tc_widgets': W3TC_SetupGuide.list_widgets, + 'page': W3TC_SetupGuide.page + } + }); } } }); @@ -110,6 +124,9 @@ function w3tc_wizard_actions( $slide ) { browsercacheSettings = { enabled: null }, + imageserviceSettings = { + enabled: null + }, lazyloadSettings = { enabled: null }, @@ -320,6 +337,52 @@ function w3tc_wizard_actions( $slide ) { }); } + /** + * Configure Image Service. + * + * @since 2.3.4 + * + * @param int enable Enable browser cache. + * @return jqXHR + */ + function configImageservice( enable ) { + configSuccess = null; + + return jQuery.ajax({ + method: 'POST', + url: ajaxurl, + data: { + _wpnonce: nonce, + action: 'w3tc_config_imageservice', + enable: enable + } + }) + .done(function( response ) { + configSuccess = response.data.success; + }); + } + + /** + * Get Image Service settings. + * + * @since 2.3.4 + * + * @return jqXHR + */ + function getImageserviceSettings() { + return jQuery.ajax({ + method: 'POST', + url: ajaxurl, + data: { + _wpnonce: nonce, + action: 'w3tc_get_imageservice_settings' + } + }) + .done(function( response ) { + imageserviceSettings = response.data; + }); + } + /** * Configure Lazy Load. * @@ -400,7 +463,14 @@ function w3tc_wizard_actions( $slide ) { // GA. if ( w3tc_enable_ga ) { - w3tc_ga( 'send', 'event', 'button', 'w3tc_setup_guide', slideId ); + w3tc_ga( + 'event', + 'button', + { + eventCategory: 'w3tc_setup_guide', + eventLabel: slideId + } + ); } switch ( slideId ) { @@ -833,7 +903,7 @@ function w3tc_wizard_actions( $slide ) { $container.find( '#w3tc-options-menu li' ).removeClass( 'is-active' ); $container.find( '#w3tc-wizard-step-objectcache' ).addClass( 'is-active' ); - if ( ! $container.find( '#test-results' ).data( 'oc-none' ) ) { + if ( ! $container.find( '#test-results' ).data( 'oc-none' ) && ! W3TC_SetupGuide.objcache_disabled ) { $nextButton.prop( 'disabled', 'disabled' ); } @@ -1181,7 +1251,7 @@ function w3tc_wizard_actions( $slide ) { break; - case 'w3tc-wizard-slide-ll1': + case 'w3tc-wizard-slide-io1': // Save the browser cache setting from the previous slide. var browsercacheEnabled = $container.find( 'input:checked[name="browsercache_enable"]' ).val(); @@ -1198,6 +1268,38 @@ function w3tc_wizard_actions( $slide ) { jQuery( '#w3tc-wizard-step-browsercache' ).append( '' ); } + // Present the Image Service slide. + $container.find( '#w3tc-options-menu li' ).removeClass( 'is-active' ); + $container.find( '#w3tc-wizard-step-imageservice' ).addClass( 'is-active' ); + $dashboardButton.closest( 'span' ).hide(); + $nextButton.closest( 'span' ).show(); + $nextButton.prop( 'disabled', 'disabled' ); + + // Update the Image Service enable chackbox from saved config. + getImageserviceSettings() + .then( function() { + $container.find( 'input#imageservice-enable' ).prop( 'checked', imageserviceSettings.enabled ); + $nextButton.prop( 'disabled', false ); + }, configFailed ); + + break; + + case 'w3tc-wizard-slide-ll1': + // Save the image service setting from the previous slide. + var imageserviceEnabled = $container.find( 'input:checked#imageservice-enable' ).val(); + configImageservice( ( '1' === imageserviceEnabled ? 1 : 0 ) ) + .fail( function() { + $slide.append( + '

        ' + + W3TC_SetupGuide.config_error_msg + + '

        ' + ); + }); + + if ( ! jQuery( '#w3tc-wizard-step-imageservice .dashicons-yes' ).length ) { + jQuery( '#w3tc-wizard-step-imageservice' ).append( '' ); + } + // Present the Lazy Load slide. $container.find( '#w3tc-options-menu li' ).removeClass( 'is-active' ); $container.find( '#w3tc-wizard-step-lazyload' ).addClass( 'is-active' ); @@ -1228,9 +1330,10 @@ function w3tc_wizard_actions( $slide ) { objcacheEngineLabel = $container.find( 'input:checked[name="objcache_engine"]' ) .closest('td').next('td').text(), browsercacheEnabled = $container.find( 'input:checked[name="browsercache_enable"]' ).val(), + imageserviceEnabled = $container.find( 'input#imageservice-enable' ).val(), lazyloadEnabled = $container.find( 'input:checked#lazyload-enable' ).val(); - // Save the lazyload setting from the previous slide. + // Save the lazy load setting from the previous slide. configLazyload( ( '1' === lazyloadEnabled ? 1 : 0 ) ) .fail( function() { $slide.append( @@ -1268,8 +1371,12 @@ function w3tc_wizard_actions( $slide ) { browsercacheEnabled ? W3TC_SetupGuide.enabled : W3TC_SetupGuide.none ); + $container.find( '#w3tc-imageservice-setting' ).html( + imageserviceEnabled ? W3TC_SetupGuide.enabled : W3TC_SetupGuide.notEnabled + ); + $container.find( '#w3tc-lazyload-setting' ).html( - lazyloadEnabled ? W3TC_SetupGuide.enabled : W3TC_SetupGuide.none + lazyloadEnabled ? W3TC_SetupGuide.enabled : W3TC_SetupGuide.notEnabled ); if ( ! jQuery( '#test-results' ).data( 'completed' ) ) { diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/wizard.js b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/wizard.js index 3a78b04c..4f034eeb 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/wizard.js +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/pub/js/wizard.js @@ -13,13 +13,14 @@ $nextButton = $container.find( '#w3tc-wizard-next '), $previousButton = $container.find( '#w3tc-wizard-previous '); - jQuery( '.button-buy-plugin' ).parent().remove(); - $skipLink.on( 'click', skipFunction ); $skipButton.on( 'click', skipFunction ); jQuery( window ).on( 'beforeunload', function() { - return W3TC_Wizard.beforeunloadText; + var $previousSlide = $container.find( '.w3tc-wizard-slides:visible' ).prev( '.w3tc-wizard-slides' ); + if ( $previousSlide.length ) { + return W3TC_Wizard.beforeunloadText; + } }); // Listen for clicks to go to the W3TC Dashboard. @@ -51,7 +52,14 @@ // GA. if ( window.w3tc_ga ) { - w3tc_ga( 'send', 'event', 'button', page, 'skip' ); + w3tc_ga( + 'event', + 'button', + { + eventCategory: page, + eventLabel: 'skip' + } + ); } jQuery.ajax({ diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/readme.txt b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/readme.txt index f5d8666c..e04a0970 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/readme.txt +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/readme.txt @@ -2,8 +2,8 @@ Contributors: boldgrid, fredericktownes, maxicusc, gidomanders, bwmarkle, harryjackson1221, joemoto, vmarko, jacobd91 Tags: seo, cache, CDN, pagespeed, caching, performance, compression, optimize, cloudflare, nginx, apache, varnish, redis, aws, amazon web services, s3, cloudfront, azure Requires at least: 5.3 -Tested up to: 6.2 -Stable tag: 2.3.3 +Tested up to: 6.3 +Stable tag: 2.5.0 License: GPLv2 or later License URI: http://www.gnu.org/licenses/gpl-2.0.html @@ -61,7 +61,7 @@ https://youtu.be/7AsNSSrZq4Y * Caching statistics for performance insights of any enabled feature * Extension framework for customization or extensibility for Cloudflare, WPML and much more * Reverse proxy integration via Nginx or Varnish -* Image Service API extension provides WebP image format conversion from common image formats (on upload and on demand) +* WebP Converter extension provides WebP image format conversion from common image formats (on upload and on demand) Speed up your site tremendously, improve core web vitals and the overall user experience for your visitors without having to change your WordPress host, theme, plugins or your content production workflow. @@ -222,11 +222,11 @@ Typically, you should tell your web host about the permission issue and they sho You can however try adding define('FS_METHOD', 'direct'); to wp-config.php to circumvent the file and folder checks. -= Does the Image Service extension use a lot of resources to convert images to WebP? = += Does the WebP Converter extension use a lot of resources to convert images to WebP? = -No. The Image Service extension converts common image file formats to the modern WebP format using our API services. The conversions occur on our API service, so that resource usage does not impact your website server. +No. The WebP Converter extension converts common image file formats to the modern WebP format using our API services. The conversions occur on our API service, so that resource usage does not impact your website server. -= Is image data retained by the Total Cache Image Service API? = += Is image data retained by the Total Cache WebP Converter API? = Image data received by our API is destroyed after a converted image is generated. The converted iamges are destroyed once picked-up/downloaded to your website by the Total Cache plugin. @@ -285,6 +285,34 @@ Please reach out to all of these people and support their projects if you're so == Changelog == += 2.5.0 = +* Feature: Added Delay Scripts (Pro) +* Fix: Several PHP 8 warnings +* Fix: Fragment Cache extension PHP warnings when no engine was selected +* Fix: Fragment Cache engine selection disabled for pro license under certain conditions +* Fix: Added Database Cluster compatiblity for older db.php files +* Fix: Fixed one PageSpeed tool metric not outputting data and adjusted a few labels +* Fix: Multiple anchor links for PageSpeed block on General Settings page +* Fix: Cache Groups validation on save +* Fix: Cache Groups delete button not working for added groups +* Update: Renamed Image Service feature to WebP Converter +* Update: Added WebP Converter block to General Settings page along with link to navigation bar +* Update: StackPath CDN prices (Service ending November 22, 2023 and will be replaced by Bunny CDN in future update) + += 2.4.1 = +* Fix: Add a fallback for the older version of wp-content/db.php + += 2.4.0 = +* Feature: Added filter "w3tc_config_item_objectcache.enabled" to allow for disabling W3TC object cache +* Fix: Auto-apply W3TC Pro license after purchase via in-plugin purchase/upgrade buttons +* Fix: PHP 8 warnings for Page and Fragment caches +* Fix: Replaced delete_blog deprecated hook with wp_uninitialize_site and wp_update_site +* Fix: Database Cluster configuration file save issue +* Fix: Fragment cache will now be disabled for non-pro users instead of being only disabled on the front-end +* Fix: Premium services widget list is now synced with the support page +* Update: User interface updated for cleaner appearance and easier navigation and control +* Update: Added support for get/set/add/delete wp_xxx_multiple methods to Object cache + = 2.3.3 = * Fix: Fragment Cache: Fatal error when displaying registered groups * Fix: PHP 8 deprecation warnings in the SNS Message Bus and NuSOAP libraries @@ -425,7 +453,7 @@ Please reach out to all of these people and support their projects if you're so * Enhancement: Improved handling of Image Service rate-limiting and error messages = 2.2.0 = -* Feature: Image Service API extension: WebP conversion options +* Feature: Image Service extension: WebP conversion options = 2.1.9 = * Fix: Cloudflare Dashboard Widget: Updated to use GraphQL diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/autoload.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/autoload.php index 6d99adaa..467eba84 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/autoload.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/autoload.php @@ -4,4 +4,4 @@ require_once __DIR__ . '/composer/autoload_real.php'; -return ComposerAutoloaderInit0ee4571b977b8bb5c07fd4829a0db478::getLoader(); +return ComposerAutoloaderInit81e756b29c31a6c9f87bd8a321bf7531::getLoader(); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/composer/autoload_real.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/composer/autoload_real.php index d9b0359d..47572752 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/composer/autoload_real.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/composer/autoload_real.php @@ -2,7 +2,7 @@ // autoload_real.php @generated by Composer -class ComposerAutoloaderInit0ee4571b977b8bb5c07fd4829a0db478 +class ComposerAutoloaderInit81e756b29c31a6c9f87bd8a321bf7531 { private static $loader; @@ -22,15 +22,15 @@ class ComposerAutoloaderInit0ee4571b977b8bb5c07fd4829a0db478 return self::$loader; } - spl_autoload_register(array('ComposerAutoloaderInit0ee4571b977b8bb5c07fd4829a0db478', 'loadClassLoader'), true, true); + spl_autoload_register(array('ComposerAutoloaderInit81e756b29c31a6c9f87bd8a321bf7531', 'loadClassLoader'), true, true); self::$loader = $loader = new \Composer\Autoload\ClassLoader(); - spl_autoload_unregister(array('ComposerAutoloaderInit0ee4571b977b8bb5c07fd4829a0db478', 'loadClassLoader')); + spl_autoload_unregister(array('ComposerAutoloaderInit81e756b29c31a6c9f87bd8a321bf7531', 'loadClassLoader')); $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded()); if ($useStaticLoader) { require_once __DIR__ . '/autoload_static.php'; - call_user_func(\Composer\Autoload\ComposerStaticInit0ee4571b977b8bb5c07fd4829a0db478::getInitializer($loader)); + call_user_func(\Composer\Autoload\ComposerStaticInit81e756b29c31a6c9f87bd8a321bf7531::getInitializer($loader)); } else { $map = require __DIR__ . '/autoload_namespaces.php'; foreach ($map as $namespace => $path) { @@ -51,19 +51,19 @@ class ComposerAutoloaderInit0ee4571b977b8bb5c07fd4829a0db478 $loader->register(true); if ($useStaticLoader) { - $includeFiles = Composer\Autoload\ComposerStaticInit0ee4571b977b8bb5c07fd4829a0db478::$files; + $includeFiles = Composer\Autoload\ComposerStaticInit81e756b29c31a6c9f87bd8a321bf7531::$files; } else { $includeFiles = require __DIR__ . '/autoload_files.php'; } foreach ($includeFiles as $fileIdentifier => $file) { - composerRequire0ee4571b977b8bb5c07fd4829a0db478($fileIdentifier, $file); + composerRequire81e756b29c31a6c9f87bd8a321bf7531($fileIdentifier, $file); } return $loader; } } -function composerRequire0ee4571b977b8bb5c07fd4829a0db478($fileIdentifier, $file) +function composerRequire81e756b29c31a6c9f87bd8a321bf7531($fileIdentifier, $file) { if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { require $file; diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/composer/autoload_static.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/composer/autoload_static.php index 8e2ee38e..6720a2a2 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/composer/autoload_static.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/composer/autoload_static.php @@ -4,7 +4,7 @@ namespace Composer\Autoload; -class ComposerStaticInit0ee4571b977b8bb5c07fd4829a0db478 +class ComposerStaticInit81e756b29c31a6c9f87bd8a321bf7531 { public static $files = array ( '7b11c4dc42b3b3023073cb14e519683c' => __DIR__ . '/..' . '/ralouphie/getallheaders/src/getallheaders.php', @@ -986,9 +986,9 @@ class ComposerStaticInit0ee4571b977b8bb5c07fd4829a0db478 public static function getInitializer(ClassLoader $loader) { return \Closure::bind(function () use ($loader) { - $loader->prefixLengthsPsr4 = ComposerStaticInit0ee4571b977b8bb5c07fd4829a0db478::$prefixLengthsPsr4; - $loader->prefixDirsPsr4 = ComposerStaticInit0ee4571b977b8bb5c07fd4829a0db478::$prefixDirsPsr4; - $loader->classMap = ComposerStaticInit0ee4571b977b8bb5c07fd4829a0db478::$classMap; + $loader->prefixLengthsPsr4 = ComposerStaticInit81e756b29c31a6c9f87bd8a321bf7531::$prefixLengthsPsr4; + $loader->prefixDirsPsr4 = ComposerStaticInit81e756b29c31a6c9f87bd8a321bf7531::$prefixDirsPsr4; + $loader->classMap = ComposerStaticInit81e756b29c31a6c9f87bd8a321bf7531::$classMap; }, null, ClassLoader::class); } diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/composer/installed.json b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/composer/installed.json index 13468e78..5d7485fc 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/composer/installed.json +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/composer/installed.json @@ -178,7 +178,7 @@ "dev-master": "6.5-dev" } }, - "installation-source": "source", + "installation-source": "dist", "autoload": { "files": [ "src/functions_include.php" @@ -363,7 +363,7 @@ }, "time": "2023-04-17T16:00:37+00:00", "type": "library", - "installation-source": "source", + "installation-source": "dist", "autoload": { "files": [ "src/functions_include.php" diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.editorconfig b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.editorconfig deleted file mode 100644 index eab48ccf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.editorconfig +++ /dev/null @@ -1,11 +0,0 @@ -# EditorConfig is awesome: http://EditorConfig.org - -# top-most EditorConfig file -root = true - -# Unix-style newlines with a newline ending for every file -# Indent with 4 spaces -[php] -end_of_line = lf -indent_style = space -indent_size = 4 diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.gitattributes b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.gitattributes deleted file mode 100644 index ba1c92ba..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.gitattributes +++ /dev/null @@ -1,11 +0,0 @@ -.editorconfig export-ignore -.gitattributes export-ignore -/.github/ export-ignore -.gitignore export-ignore -/build/ export-ignore -/docs/ export-ignore -/Makefile export-ignore -/phpstan-baseline.neon export-ignore -/phpstan.neon.dist export-ignore -/phpunit.xml.dist export-ignore -/tests/ export-ignore diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/CONTRIBUTING.md b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/CONTRIBUTING.md deleted file mode 100644 index 6d92b01e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/CONTRIBUTING.md +++ /dev/null @@ -1,3 +0,0 @@ -# Contributing - -Please see our [contributing guide](http://docs.guzzlephp.org/en/latest/overview.html#contributing). diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/ISSUE_TEMPLATE.md b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/ISSUE_TEMPLATE.md deleted file mode 100644 index f822c0dd..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/ISSUE_TEMPLATE.md +++ /dev/null @@ -1 +0,0 @@ -Please consider using one of the issue templates (bug report, feature request). diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/ISSUE_TEMPLATE/bug_report.md b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/ISSUE_TEMPLATE/bug_report.md deleted file mode 100644 index 37bc0296..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/ISSUE_TEMPLATE/bug_report.md +++ /dev/null @@ -1,18 +0,0 @@ ---- -name: 🐛 Bug Report -about: Report errors and problems ---- - -**Guzzle version(s) affected**: x.y.z - -**Description** - - -**How to reproduce** - - -**Possible Solution** - - -**Additional context** - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/ISSUE_TEMPLATE/feature_request.md b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/ISSUE_TEMPLATE/feature_request.md deleted file mode 100644 index 981f4f67..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/ISSUE_TEMPLATE/feature_request.md +++ /dev/null @@ -1,14 +0,0 @@ ---- -name: 🚀 Feature Request -about: RFC and ideas for new features and improvements ---- - -**Description** - - -**Example** - - -**Additional context** - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/ISSUE_TEMPLATE/security_issue.md b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/ISSUE_TEMPLATE/security_issue.md deleted file mode 100644 index 84ae4e55..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/ISSUE_TEMPLATE/security_issue.md +++ /dev/null @@ -1,10 +0,0 @@ ---- -name: ⛔ Security Issue -about: See the description to report security-related issues ---- - -⚠ PLEASE DON'T DISCLOSE SECURITY-RELATED ISSUES PUBLICLY, SEE BELOW. - -If you have found a security issue in Guzzle, please send the details to -security [at] guzzlephp.org and don't disclose it publicly until we can provide a -fix for it. diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/ISSUE_TEMPLATE/support_question.md b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/ISSUE_TEMPLATE/support_question.md deleted file mode 100644 index 383c6f40..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/ISSUE_TEMPLATE/support_question.md +++ /dev/null @@ -1,10 +0,0 @@ ---- -name: ⛔ Support Question -about: See https://github.com/guzzle/guzzle/blob/master/.github/SUPPORT.md for questions about using Guzzle and its components ---- - -We use GitHub issues only to discuss about Guzzle bugs and new features. -For this kind of questions about using Guzzle, -please use any of the support alternatives shown in https://github.com/guzzle/guzzle/blob/master/.github/SUPPORT.md - -Thanks! diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/SUPPORT.md b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/SUPPORT.md deleted file mode 100644 index 0abc5933..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/SUPPORT.md +++ /dev/null @@ -1,18 +0,0 @@ -# Support - -If you're looking for support for Guzzle, here are a few options: - -- [Documentation](http://guzzlephp.org/) -- [Gitter](https://gitter.im/guzzle/guzzle) -- [#guzzle](https://php-http.slack.com/messages/CE6UAAKL4/) channel in [PHP-HTTP](http://php-http.org) Slack team - -Guzzle is a relatively old project, so chances are you will find -much about them on Google or Stack Overflow: - -- [guzzle](https://stackoverflow.com/questions/tagged/guzzle) tag on Stack Overflow (recommended) -- [guzzlehttp](https://stackoverflow.com/questions/tagged/guzzlehttp) tag on Stack Overflow -- [guzzle6](https://stackoverflow.com/questions/tagged/guzzle6) tag on Stack Overflow - - -You can also browse the issue tracker for support requests, -but we encourage everyone to use the channels above instead. diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/workflows/bc.entrypoint b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/workflows/bc.entrypoint deleted file mode 100644 index 04436e67..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/workflows/bc.entrypoint +++ /dev/null @@ -1,37 +0,0 @@ -#!/bin/sh -l - -# -# This file is a hack to suppress warnings from Roave BC check -# - -composer install - -# Capture output to variable AND print it -exec 4711>&1 -OUTPUT=$(/composer/vendor/bin/roave-backward-compatibility-check 2>&1 | tee /dev/fd/4711) - -# Remove rows we want to suppress -OUTPUT=`echo "$OUTPUT" | sed '/GuzzleHttp\\\ClientInterface::VERSION/'d` -OUTPUT=`echo "$OUTPUT" | sed '/Roave\\\BetterReflection\\\Reflection\\\ReflectionClass "Psr\\\Log\\\LogLevel" could not be found in the located source/'d` - -# Number of rows we found with "[BC]" in them -BC_BREAKS=`echo "$OUTPUT" | grep -o '\[BC\]' | wc -l | awk '{ print $1 }'` - -# The last row of the output is "X backwards-incompatible changes detected". Find X. -STATED_BREAKS=`echo "$OUTPUT" | tail -n 1 | awk -F' ' '{ print $1 }'` - -# If -# We found "[BC]" in the command output after we removed suppressed lines -# OR -# We have suppressed X number of BC breaks. If $STATED_BREAKS is larger than X -# THEN -# exit 1 - -if [ $BC_BREAKS -gt 0 ] || [ $STATED_BREAKS -gt 2 ]; then - echo "EXIT 1" - exit 1 -fi - -# No BC breaks found -echo "EXIT 0" -exit 0 diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/workflows/checks.yml b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/workflows/checks.yml deleted file mode 100644 index 4a248d14..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/workflows/checks.yml +++ /dev/null @@ -1,21 +0,0 @@ -name: Checks - -on: - push: - branches: - - master - pull_request: - -jobs: - roave-bc-check: - name: Roave BC Check - runs-on: ubuntu-latest - - steps: - - name: Checkout code - uses: actions/checkout@v2 - - - name: Roave BC Check - uses: docker://nyholm/roave-bc-check-ga - with: - entrypoint: ./.github/workflows/bc.entrypoint diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/workflows/ci.yml b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/workflows/ci.yml deleted file mode 100644 index 88649df2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/.github/workflows/ci.yml +++ /dev/null @@ -1,70 +0,0 @@ -name: CI - -on: - push: - branches: - - master - pull_request: - -jobs: - build-lowest: - name: Build lowest - runs-on: ubuntu-latest - - steps: - - name: Set up PHP - uses: shivammathur/setup-php@v2 - with: - php-version: '5.5' - coverage: none - extensions: mbstring, intl - - - name: Set up Node - uses: actions/setup-node@v1 - with: - node-version: '14.x' - - - name: Setup Problem Matchers for PHPUnit - run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json" - - - name: Checkout code - uses: actions/checkout@v2 - - - name: Download dependencies - run: composer update --no-interaction --no-progress --prefer-stable --prefer-lowest - - - name: Run tests - run: make test - - build: - name: Build - runs-on: ubuntu-latest - strategy: - max-parallel: 10 - matrix: - php: ['5.5', '5.6', '7.0', '7.1', '7.2', '7.3', '7.4'] - - steps: - - name: Set up PHP - uses: shivammathur/setup-php@v2 - with: - php-version: ${{ matrix.php }} - coverage: none - extensions: mbstring, intl - - - name: Set up Node - uses: actions/setup-node@v1 - with: - node-version: '14.x' - - - name: Setup Problem Matchers for PHPUnit - run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json" - - - name: Checkout code - uses: actions/checkout@v2 - - - name: Download dependencies - run: composer update --no-interaction --no-progress - - - name: Run tests - run: make test diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/Makefile b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/Makefile deleted file mode 100644 index 387a46d2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/Makefile +++ /dev/null @@ -1,78 +0,0 @@ -help: - @echo "Please use \`make ' where is one of" - @echo " start-server to start the test server" - @echo " stop-server to stop the test server" - @echo " test to perform unit tests. Provide TEST to perform a specific test." - @echo " coverage to perform unit tests with code coverage. Provide TEST to perform a specific test." - @echo " coverage-show to show the code coverage report" - @echo " clean to remove build artifacts" - @echo " docs to build the Sphinx docs" - @echo " docs-show to view the Sphinx docs" - @echo " tag to modify the version, update changelog, and chag tag" - @echo " package to build the phar and zip files" - @echo " static to run phpstan and php-cs-fixer on the codebase" - @echo " static-phpstan to run phpstan on the codebase" - @echo " static-phpstan-update-baseline to regenerate the phpstan baseline file" - @echo " static-codestyle-fix to run php-cs-fixer on the codebase, writing the changes" - @echo " static-codestyle-check to run php-cs-fixer on the codebase" - -start-server: stop-server - node tests/server.js &> /dev/null & - -stop-server: - @PID=$(shell ps axo pid,command \ - | grep 'tests/server.js' \ - | grep -v grep \ - | cut -f 1 -d " "\ - ) && [ -n "$$PID" ] && kill $$PID || true - -test: start-server - vendor/bin/phpunit - $(MAKE) stop-server - -coverage: start-server - vendor/bin/phpunit --coverage-html=build/artifacts/coverage - $(MAKE) stop-server - -coverage-show: view-coverage - -view-coverage: - open build/artifacts/coverage/index.html - -clean: - rm -rf artifacts/* - -docs: - cd docs && make html && cd .. - -docs-show: - open docs/_build/html/index.html - -tag: - $(if $(TAG),,$(error TAG is not defined. Pass via "make tag TAG=4.2.1")) - @echo Tagging $(TAG) - chag update $(TAG) - sed -i '' -e "s/VERSION = '.*'/VERSION = '$(TAG)'/" src/ClientInterface.php - php -l src/ClientInterface.php - git add -A - git commit -m '$(TAG) release' - chag tag - -package: - php build/packager.php - -static: static-phpstan static-codestyle-check - -static-phpstan: - docker run --rm -it -e REQUIRE_DEV=true -v ${PWD}:/app -w /app oskarstark/phpstan-ga:0.12.28 analyze $(PHPSTAN_PARAMS) - -static-phpstan-update-baseline: - $(MAKE) static-phpstan PHPSTAN_PARAMS="--generate-baseline" - -static-codestyle-fix: - docker run --rm -it -v ${PWD}:/app -w /app oskarstark/php-cs-fixer-ga:2.16.3.1 --diff-format udiff $(CS_PARAMS) - -static-codestyle-check: - $(MAKE) static-codestyle-fix CS_PARAMS="--dry-run" - -.PHONY: docs burgomaster coverage-show view-coverage diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/build/Burgomaster.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/build/Burgomaster.php deleted file mode 100644 index 0ed6c336..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/build/Burgomaster.php +++ /dev/null @@ -1,385 +0,0 @@ -startSection('setting_up'); - $this->stageDir = $stageDir; - $this->projectRoot = $projectRoot; - - if (!$this->stageDir || $this->stageDir == '/') { - throw new \InvalidArgumentException('Invalid base directory'); - } - - if (is_dir($this->stageDir)) { - $this->debug("Removing existing directory: $this->stageDir"); - echo $this->exec("rm -rf $this->stageDir"); - } - - $this->debug("Creating staging directory: $this->stageDir"); - - if (!mkdir($this->stageDir, 0777, true)) { - throw new \RuntimeException("Could not create {$this->stageDir}"); - } - - $this->stageDir = realpath($this->stageDir); - $this->debug("Creating staging directory at: {$this->stageDir}"); - - if (!is_dir($this->projectRoot)) { - throw new \InvalidArgumentException( - "Project root not found: $this->projectRoot" - ); - } - - $this->endSection(); - $this->startSection('staging'); - - chdir($this->projectRoot); - } - - /** - * Cleanup if the last section was not already closed. - */ - public function __destruct() - { - if ($this->sections) { - $this->endSection(); - } - } - - /** - * Call this method when starting a specific section of the packager. - * - * This makes the debug messages used in your script more meaningful and - * adds context when things go wrong. Be sure to call endSection() when - * you have finished a section of your packaging script. - * - * @param string $section Part of the packager that is running - */ - public function startSection($section) - { - $this->sections[] = $section; - $this->debug('Starting'); - } - - /** - * Call this method when leaving the last pushed section of the packager. - */ - public function endSection() - { - if ($this->sections) { - $this->debug('Completed'); - array_pop($this->sections); - } - } - - /** - * Prints a debug message to STDERR bound to the current section. - * - * @param string $message Message to echo to STDERR - */ - public function debug($message) - { - $prefix = date('c') . ': '; - - if ($this->sections) { - $prefix .= '[' . end($this->sections) . '] '; - } - - fwrite(STDERR, $prefix . $message . "\n"); - } - - /** - * Copies a file and creates the destination directory if needed. - * - * @param string $from File to copy - * @param string $to Destination to copy the file to, relative to the - * base staging directory. - * @throws \InvalidArgumentException if the file cannot be found - * @throws \RuntimeException if the directory cannot be created. - * @throws \RuntimeException if the file cannot be copied. - */ - public function deepCopy($from, $to) - { - if (!is_file($from)) { - throw new \InvalidArgumentException("File not found: {$from}"); - } - - $to = str_replace('//', '/', $this->stageDir . '/' . $to); - $dir = dirname($to); - - if (!is_dir($dir)) { - if (!mkdir($dir, 0777, true)) { - throw new \RuntimeException("Unable to create directory: $dir"); - } - } - - if (!copy($from, $to)) { - throw new \RuntimeException("Unable to copy $from to $to"); - } - } - - /** - * Recursively copy one folder to another. - * - * Any LICENSE file is automatically copied. - * - * @param string $sourceDir Source directory to copy from - * @param string $destDir Directory to copy the files to that is relative - * to the the stage base directory. - * @param array $extensions File extensions to copy from the $sourceDir. - * Defaults to "php" files only (e.g., ['php']). - * @throws \InvalidArgumentException if the source directory is invalid. - */ - public function recursiveCopy( - $sourceDir, - $destDir, - $extensions = array('php') - ) { - if (!realpath($sourceDir)) { - throw new \InvalidArgumentException("$sourceDir not found"); - } - - if (!$extensions) { - throw new \InvalidArgumentException('$extensions is empty!'); - } - - $sourceDir = realpath($sourceDir); - $exts = array_fill_keys($extensions, true); - $iter = new \RecursiveDirectoryIterator($sourceDir); - $iter = new \RecursiveIteratorIterator($iter); - $total = 0; - - $this->startSection('copy'); - $this->debug("Starting to copy files from $sourceDir"); - - foreach ($iter as $file) { - if (isset($exts[$file->getExtension()]) - || $file->getBaseName() == 'LICENSE' - ) { - // Remove the source directory from the destination path - $toPath = str_replace($sourceDir, '', (string) $file); - $toPath = $destDir . '/' . $toPath; - $toPath = str_replace('//', '/', $toPath); - $this->deepCopy((string) $file, $toPath); - $total++; - } - } - - $this->debug("Copied $total files from $sourceDir"); - $this->endSection(); - } - - /** - * Execute a command and throw an exception if the return code is not 0. - * - * @param string $command Command to execute - * - * @return string Returns the output of the command as a string - * @throws \RuntimeException on error. - */ - public function exec($command) - { - $this->debug("Executing: $command"); - $output = $returnValue = null; - exec($command, $output, $returnValue); - - if ($returnValue != 0) { - throw new \RuntimeException('Error executing command: ' - . $command . ' : ' . implode("\n", $output)); - } - - return implode("\n", $output); - } - - /** - * Creates a class-map autoloader to the staging directory in a file - * named autoloader.php - * - * @param array $files Files to explicitly require in the autoloader. This - * is similar to Composer's "files" "autoload" section. - * @param string $filename Name of the autoloader file. - * @throws \RuntimeException if the file cannot be written - */ - public function createAutoloader($files = array(), $filename = 'autoloader.php') - { - $sourceDir = realpath($this->stageDir); - $iter = new \RecursiveDirectoryIterator($sourceDir); - $iter = new \RecursiveIteratorIterator($iter); - - $this->startSection('autoloader'); - $this->debug('Creating classmap autoloader'); - $this->debug("Collecting valid PHP files from {$this->stageDir}"); - - $classMap = array(); - foreach ($iter as $file) { - if ($file->getExtension() == 'php') { - $location = str_replace($this->stageDir . '/', '', (string) $file); - $className = str_replace('/', '\\', $location); - $className = substr($className, 0, -4); - - // Remove "src\" or "lib\" - if (strpos($className, 'src\\') === 0 - || strpos($className, 'lib\\') === 0 - ) { - $className = substr($className, 4); - } - - $classMap[$className] = "__DIR__ . '/$location'"; - $this->debug("Found $className"); - } - } - - $destFile = $this->stageDir . '/' . $filename; - $this->debug("Writing autoloader to {$destFile}"); - - if (!($h = fopen($destFile, 'w'))) { - throw new \RuntimeException('Unable to open file for writing'); - } - - $this->debug('Writing classmap files'); - fwrite($h, " $f) { - fwrite($h, " '$c' => $f,\n"); - } - fwrite($h, ");\n\n"); - fwrite($h, <<debug('Writing automatically included files'); - foreach ($files as $file) { - fwrite($h, "require __DIR__ . '/$file';\n"); - } - - fclose($h); - - $this->endSection(); - } - - /** - * Creates a default stub for the phar that includeds the generated - * autoloader. - * - * This phar also registers a constant that can be used to check if you - * are running the phar. The constant is the basename of the $dest variable - * without the extension, with "_PHAR" appended, then converted to all - * caps (e.g., "/foo/guzzle.phar" gets a contant defined as GUZZLE_PHAR. - * - * @param $dest - * @param string $autoloaderFilename Name of the autoloader file. - * - * @return string - */ - private function createStub($dest, $autoloaderFilename = 'autoloader.php') - { - $this->startSection('stub'); - $this->debug("Creating phar stub at $dest"); - - $alias = basename($dest); - $constName = str_replace('.phar', '', strtoupper($alias)) . '_PHAR'; - $stub = "endSection(); - - return $stub; - } - - /** - * Creates a phar that automatically registers an autoloader. - * - * Call this only after your staging directory is built. - * - * @param string $dest Where to save the file. The basename of the file - * is also used as the alias name in the phar - * (e.g., /path/to/guzzle.phar => guzzle.phar). - * @param string|bool|null $stub The path to the phar stub file. Pass or - * leave null to automatically have one created for you. Pass false - * to no use a stub in the generated phar. - * @param string $autoloaderFilename Name of the autolaoder filename. - */ - public function createPhar( - $dest, - $stub = null, - $autoloaderFilename = 'autoloader.php' - ) { - $this->startSection('phar'); - $this->debug("Creating phar file at $dest"); - $this->createDirIfNeeded(dirname($dest)); - $phar = new \Phar($dest, 0, basename($dest)); - $phar->buildFromDirectory($this->stageDir); - - if ($stub !== false) { - if (!$stub) { - $stub = $this->createStub($dest, $autoloaderFilename); - } - $phar->setStub($stub); - } - - $this->debug("Created phar at $dest"); - $this->endSection(); - } - - /** - * Creates a zip file containing the staged files of your project. - * - * Call this only after your staging directory is built. - * - * @param string $dest Where to save the zip file - */ - public function createZip($dest) - { - $this->startSection('zip'); - $this->debug("Creating a zip file at $dest"); - $this->createDirIfNeeded(dirname($dest)); - chdir($this->stageDir); - $this->exec("zip -r $dest ./"); - $this->debug(" > Created at $dest"); - chdir(__DIR__); - $this->endSection(); - } - - private function createDirIfNeeded($dir) - { - if (!is_dir($dir) && !mkdir($dir, 0755, true)) { - throw new \RuntimeException("Could not create dir: $dir"); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/build/packager.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/build/packager.php deleted file mode 100644 index f0316e23..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/build/packager.php +++ /dev/null @@ -1,27 +0,0 @@ -deepCopy($file, $file); -} - -// Copy each dependency to the staging directory. Copy *.php and *.pem files. -$packager->recursiveCopy('src', 'GuzzleHttp', ['php']); -$packager->recursiveCopy('vendor/guzzlehttp/promises/src', 'GuzzleHttp/Promise'); -$packager->recursiveCopy('vendor/guzzlehttp/psr7/src', 'GuzzleHttp/Psr7'); -$packager->recursiveCopy('vendor/psr/http-message/src', 'Psr/Http/Message'); - -$packager->createAutoloader([ - 'GuzzleHttp/functions_include.php', - 'GuzzleHttp/Psr7/functions_include.php', - 'GuzzleHttp/Promise/functions_include.php', -]); - -$packager->createPhar(__DIR__ . '/artifacts/guzzle.phar'); -$packager->createZip(__DIR__ . '/artifacts/guzzle.zip'); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/Makefile b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/Makefile deleted file mode 100644 index d92e03f9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/Makefile +++ /dev/null @@ -1,153 +0,0 @@ -# Makefile for Sphinx documentation -# - -# You can set these variables from the command line. -SPHINXOPTS = -SPHINXBUILD = sphinx-build -PAPER = -BUILDDIR = _build - -# Internal variables. -PAPEROPT_a4 = -D latex_paper_size=a4 -PAPEROPT_letter = -D latex_paper_size=letter -ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) . -# the i18n builder cannot share the environment and doctrees with the others -I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) . - -.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest gettext - -help: - @echo "Please use \`make ' where is one of" - @echo " html to make standalone HTML files" - @echo " dirhtml to make HTML files named index.html in directories" - @echo " singlehtml to make a single large HTML file" - @echo " pickle to make pickle files" - @echo " json to make JSON files" - @echo " htmlhelp to make HTML files and a HTML help project" - @echo " qthelp to make HTML files and a qthelp project" - @echo " devhelp to make HTML files and a Devhelp project" - @echo " epub to make an epub" - @echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter" - @echo " latexpdf to make LaTeX files and run them through pdflatex" - @echo " text to make text files" - @echo " man to make manual pages" - @echo " texinfo to make Texinfo files" - @echo " info to make Texinfo files and run them through makeinfo" - @echo " gettext to make PO message catalogs" - @echo " changes to make an overview of all changed/added/deprecated items" - @echo " linkcheck to check all external links for integrity" - @echo " doctest to run all doctests embedded in the documentation (if enabled)" - -clean: - -rm -rf $(BUILDDIR)/* - -html: - $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html - @echo - @echo "Build finished. The HTML pages are in $(BUILDDIR)/html." - -dirhtml: - $(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml - @echo - @echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml." - -singlehtml: - $(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml - @echo - @echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml." - -pickle: - $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle - @echo - @echo "Build finished; now you can process the pickle files." - -json: - $(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json - @echo - @echo "Build finished; now you can process the JSON files." - -htmlhelp: - $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp - @echo - @echo "Build finished; now you can run HTML Help Workshop with the" \ - ".hhp project file in $(BUILDDIR)/htmlhelp." - -qthelp: - $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp - @echo - @echo "Build finished; now you can run "qcollectiongenerator" with the" \ - ".qhcp project file in $(BUILDDIR)/qthelp, like this:" - @echo "# qcollectiongenerator $(BUILDDIR)/qthelp/Guzzle.qhcp" - @echo "To view the help file:" - @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/Guzzle.qhc" - -devhelp: - $(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp - @echo - @echo "Build finished." - @echo "To view the help file:" - @echo "# mkdir -p $$HOME/.local/share/devhelp/Guzzle" - @echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/Guzzle" - @echo "# devhelp" - -epub: - $(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub - @echo - @echo "Build finished. The epub file is in $(BUILDDIR)/epub." - -latex: - $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex - @echo - @echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex." - @echo "Run \`make' in that directory to run these through (pdf)latex" \ - "(use \`make latexpdf' here to do that automatically)." - -latexpdf: - $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex - @echo "Running LaTeX files through pdflatex..." - $(MAKE) -C $(BUILDDIR)/latex all-pdf - @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex." - -text: - $(SPHINXBUILD) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text - @echo - @echo "Build finished. The text files are in $(BUILDDIR)/text." - -man: - $(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man - @echo - @echo "Build finished. The manual pages are in $(BUILDDIR)/man." - -texinfo: - $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo - @echo - @echo "Build finished. The Texinfo files are in $(BUILDDIR)/texinfo." - @echo "Run \`make' in that directory to run these through makeinfo" \ - "(use \`make info' here to do that automatically)." - -info: - $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo - @echo "Running Texinfo files through makeinfo..." - make -C $(BUILDDIR)/texinfo info - @echo "makeinfo finished; the Info files are in $(BUILDDIR)/texinfo." - -gettext: - $(SPHINXBUILD) -b gettext $(I18NSPHINXOPTS) $(BUILDDIR)/locale - @echo - @echo "Build finished. The message catalogs are in $(BUILDDIR)/locale." - -changes: - $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes - @echo - @echo "The overview file is in $(BUILDDIR)/changes." - -linkcheck: - $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck - @echo - @echo "Link check complete; look for any errors in the above output " \ - "or in $(BUILDDIR)/linkcheck/output.txt." - -doctest: - $(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest - @echo "Testing of doctests in the sources finished, look at the " \ - "results in $(BUILDDIR)/doctest/output.txt." diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/_static/guzzle-icon.png b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/_static/guzzle-icon.png deleted file mode 100644 index f1017f7e..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/_static/guzzle-icon.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/_static/logo.png b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/_static/logo.png deleted file mode 100644 index 965a4ef4..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/_static/logo.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/conf.py b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/conf.py deleted file mode 100644 index 689576c2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/conf.py +++ /dev/null @@ -1,68 +0,0 @@ -import sys, os -from sphinx.highlighting import lexers -from pygments.lexers.web import PhpLexer - - -lexers['php'] = PhpLexer(startinline=True, linenos=1) -lexers['php-annotations'] = PhpLexer(startinline=True, linenos=1) -primary_domain = 'php' - -extensions = [] -templates_path = ['_templates'] -source_suffix = '.rst' -master_doc = 'index' -project = u'Guzzle' -copyright = u'2015, Michael Dowling' -version = '6' -html_title = "Guzzle Documentation" -html_short_title = "Guzzle 6" - -exclude_patterns = ['_build'] -html_static_path = ['_static'] - -##### Guzzle sphinx theme - -import guzzle_sphinx_theme -html_translator_class = 'guzzle_sphinx_theme.HTMLTranslator' -html_theme_path = guzzle_sphinx_theme.html_theme_path() -html_theme = 'guzzle_sphinx_theme' - -# Custom sidebar templates, maps document names to template names. -html_sidebars = { - '**': ['logo-text.html', 'globaltoc.html', 'searchbox.html'] -} - -# Register the theme as an extension to generate a sitemap.xml -extensions.append("guzzle_sphinx_theme") - -# Guzzle theme options (see theme.conf for more information) -html_theme_options = { - - # Set the path to a special layout to include for the homepage - # "index_template": "homepage.html", - - # Allow a separate homepage from the master_doc - # homepage = index - - # Set the name of the project to appear in the nav menu - # "project_nav_name": "Guzzle", - - # Set your Disqus short name to enable comments - # "disqus_comments_shortname": "my_disqus_comments_short_name", - - # Set you GA account ID to enable tracking - # "google_analytics_account": "my_ga_account", - - # Path to a touch icon - # "touch_icon": "", - - # Specify a base_url used to generate sitemap.xml links. If not - # specified, then no sitemap will be built. - "base_url": "http://guzzlephp.org" - - # Allow the "Table of Contents" page to be defined separately from "master_doc" - # tocpage = Contents - - # Allow the project link to be overriden to a custom URL. - # projectlink = http://myproject.url -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/faq.rst b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/faq.rst deleted file mode 100644 index e94b1035..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/faq.rst +++ /dev/null @@ -1,193 +0,0 @@ -=== -FAQ -=== - -Does Guzzle require cURL? -========================= - -No. Guzzle can use any HTTP handler to send requests. This means that Guzzle -can be used with cURL, PHP's stream wrapper, sockets, and non-blocking libraries -like `React `_. You just need to configure an HTTP handler -to use a different method of sending requests. - -.. note:: - - Guzzle has historically only utilized cURL to send HTTP requests. cURL is - an amazing HTTP client (arguably the best), and Guzzle will continue to use - it by default when it is available. It is rare, but some developers don't - have cURL installed on their systems or run into version specific issues. - By allowing swappable HTTP handlers, Guzzle is now much more customizable - and able to adapt to fit the needs of more developers. - - -Can Guzzle send asynchronous requests? -====================================== - -Yes. You can use the ``requestAsync``, ``sendAsync``, ``getAsync``, -``headAsync``, ``putAsync``, ``postAsync``, ``deleteAsync``, and ``patchAsync`` -methods of a client to send an asynchronous request. The client will return a -``GuzzleHttp\Promise\PromiseInterface`` object. You can chain ``then`` -functions off of the promise. - -.. code-block:: php - - $promise = $client->requestAsync('GET', 'http://httpbin.org/get'); - $promise->then(function ($response) { - echo 'Got a response! ' . $response->getStatusCode(); - }); - -You can force an asynchronous response to complete using the ``wait()`` method -of the returned promise. - -.. code-block:: php - - $promise = $client->requestAsync('GET', 'http://httpbin.org/get'); - $response = $promise->wait(); - - -How can I add custom cURL options? -================================== - -cURL offers a huge number of `customizable options `_. -While Guzzle normalizes many of these options across different handlers, there -are times when you need to set custom cURL options. This can be accomplished -by passing an associative array of cURL settings in the **curl** key of a -request. - -For example, let's say you need to customize the outgoing network interface -used with a client. - -.. code-block:: php - - $client->request('GET', '/', [ - 'curl' => [ - CURLOPT_INTERFACE => 'xxx.xxx.xxx.xxx' - ] - ]); - -If you use asynchronous requests with cURL multi handler and want to tweak it, -additional options can be specified as an associative array in the -**options** key of the ``CurlMultiHandler`` constructor. - -.. code-block:: php - - use \GuzzleHttp\Client; - use \GuzzleHttp\HandlerStack; - use \GuzzleHttp\Handler\CurlMultiHandler; - - $client = new Client(['handler' => HandlerStack::create(new CurlMultiHandler([ - 'options' => [ - CURLMOPT_MAX_TOTAL_CONNECTIONS => 50, - CURLMOPT_MAX_HOST_CONNECTIONS => 5, - ] - ]))]); - - -How can I add custom stream context options? -============================================ - -You can pass custom `stream context options `_ -using the **stream_context** key of the request option. The **stream_context** -array is an associative array where each key is a PHP transport, and each value -is an associative array of transport options. - -For example, let's say you need to customize the outgoing network interface -used with a client and allow self-signed certificates. - -.. code-block:: php - - $client->request('GET', '/', [ - 'stream' => true, - 'stream_context' => [ - 'ssl' => [ - 'allow_self_signed' => true - ], - 'socket' => [ - 'bindto' => 'xxx.xxx.xxx.xxx' - ] - ] - ]); - - -Why am I getting an SSL verification error? -=========================================== - -You need to specify the path on disk to the CA bundle used by Guzzle for -verifying the peer certificate. See :ref:`verify-option`. - - -What is this Maximum function nesting error? -============================================ - - Maximum function nesting level of '100' reached, aborting - -You could run into this error if you have the XDebug extension installed and -you execute a lot of requests in callbacks. This error message comes -specifically from the XDebug extension. PHP itself does not have a function -nesting limit. Change this setting in your php.ini to increase the limit:: - - xdebug.max_nesting_level = 1000 - - -Why am I getting a 417 error response? -====================================== - -This can occur for a number of reasons, but if you are sending PUT, POST, or -PATCH requests with an ``Expect: 100-Continue`` header, a server that does not -support this header will return a 417 response. You can work around this by -setting the ``expect`` request option to ``false``: - -.. code-block:: php - - $client = new GuzzleHttp\Client(); - - // Disable the expect header on a single request - $response = $client->request('PUT', '/', ['expect' => false]); - - // Disable the expect header on all client requests - $client = new GuzzleHttp\Client(['expect' => false]); - -How can I track redirected requests? -==================================== - -You can enable tracking of redirected URIs and status codes via the -`track_redirects` option. Each redirected URI and status code will be stored in the -``X-Guzzle-Redirect-History`` and the ``X-Guzzle-Redirect-Status-History`` -header respectively. - -The initial request's URI and the final status code will be excluded from the results. -With this in mind you should be able to easily track a request's full redirect path. - -For example, let's say you need to track redirects and provide both results -together in a single report: - -.. code-block:: php - - // First you configure Guzzle with redirect tracking and make a request - $client = new Client([ - RequestOptions::ALLOW_REDIRECTS => [ - 'max' => 10, // allow at most 10 redirects. - 'strict' => true, // use "strict" RFC compliant redirects. - 'referer' => true, // add a Referer header - 'track_redirects' => true, - ], - ]); - $initialRequest = '/redirect/3'; // Store the request URI for later use - $response = $client->request('GET', $initialRequest); // Make your request - - // Retrieve both Redirect History headers - $redirectUriHistory = $response->getHeader('X-Guzzle-Redirect-History')[0]; // retrieve Redirect URI history - $redirectCodeHistory = $response->getHeader('X-Guzzle-Redirect-Status-History')[0]; // retrieve Redirect HTTP Status history - - // Add the initial URI requested to the (beginning of) URI history - array_unshift($redirectUriHistory, $initialRequest); - - // Add the final HTTP status code to the end of HTTP response history - array_push($redirectCodeHistory, $response->getStatusCode()); - - // (Optional) Combine the items of each array into a single result set - $fullRedirectReport = []; - foreach ($redirectUriHistory as $key => $value) { - $fullRedirectReport[$key] = ['location' => $value, 'code' => $redirectCodeHistory[$key]]; - } - echo json_encode($fullRedirectReport); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/handlers-and-middleware.rst b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/handlers-and-middleware.rst deleted file mode 100644 index be81063c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/handlers-and-middleware.rst +++ /dev/null @@ -1,303 +0,0 @@ -======================= -Handlers and Middleware -======================= - -Guzzle clients use a handler and middleware system to send HTTP requests. - -Handlers -======== - -A handler function accepts a ``Psr\Http\Message\RequestInterface`` and array of -request options and returns a ``GuzzleHttp\Promise\PromiseInterface`` that is -fulfilled with a ``Psr\Http\Message\ResponseInterface`` or rejected with an -exception. - -You can provide a custom handler to a client using the ``handler`` option of -a client constructor. It is important to understand that several request -options used by Guzzle require that specific middlewares wrap the handler used -by the client. You can ensure that the handler you provide to a client uses the -default middlewares by wrapping the handler in the -``GuzzleHttp\HandlerStack::create(callable $handler = null)`` static method. - -.. code-block:: php - - use GuzzleHttp\Client; - use GuzzleHttp\HandlerStack; - use GuzzleHttp\Handler\CurlHandler; - - $handler = new CurlHandler(); - $stack = HandlerStack::create($handler); // Wrap w/ middleware - $client = new Client(['handler' => $stack]); - -The ``create`` method adds default handlers to the ``HandlerStack``. When the -``HandlerStack`` is resolved, the handlers will execute in the following order: - -1. Sending request: - - 1. ``http_errors`` - No op when sending a request. The response status code - is checked in the response processing when returning a response promise up - the stack. - 2. ``allow_redirects`` - No op when sending a request. Following redirects - occurs when a response promise is being returned up the stack. - 3. ``cookies`` - Adds cookies to requests. - 4. ``prepare_body`` - The body of an HTTP request will be prepared (e.g., - add default headers like Content-Length, Content-Type, etc.). - 5. - -2. Processing response: - - 1. ``prepare_body`` - no op on response processing. - 2. ``cookies`` - extracts response cookies into the cookie jar. - 3. ``allow_redirects`` - Follows redirects. - 4. ``http_errors`` - throws exceptions when the response status code ``>=`` - 400. - -When provided no ``$handler`` argument, ``GuzzleHttp\HandlerStack::create()`` -will choose the most appropriate handler based on the extensions available on -your system. - -.. important:: - - The handler provided to a client determines how request options are applied - and utilized for each request sent by a client. For example, if you do not - have a cookie middleware associated with a client, then setting the - ``cookies`` request option will have no effect on the request. - - -Middleware -========== - -Middleware augments the functionality of handlers by invoking them in the -process of generating responses. Middleware is implemented as a higher order -function that takes the following form. - -.. code-block:: php - - use Psr\Http\Message\RequestInterface; - - function my_middleware() - { - return function (callable $handler) { - return function (RequestInterface $request, array $options) use ($handler) { - return $handler($request, $options); - }; - }; - } - -Middleware functions return a function that accepts the next handler to invoke. -This returned function then returns another function that acts as a composed -handler-- it accepts a request and options, and returns a promise that is -fulfilled with a response. Your composed middleware can modify the request, -add custom request options, and modify the promise returned by the downstream -handler. - -Here's an example of adding a header to each request. - -.. code-block:: php - - use Psr\Http\Message\RequestInterface; - - function add_header($header, $value) - { - return function (callable $handler) use ($header, $value) { - return function ( - RequestInterface $request, - array $options - ) use ($handler, $header, $value) { - $request = $request->withHeader($header, $value); - return $handler($request, $options); - }; - }; - } - -Once a middleware has been created, you can add it to a client by either -wrapping the handler used by the client or by decorating a handler stack. - -.. code-block:: php - - use GuzzleHttp\HandlerStack; - use GuzzleHttp\Handler\CurlHandler; - use GuzzleHttp\Client; - - $stack = new HandlerStack(); - $stack->setHandler(new CurlHandler()); - $stack->push(add_header('X-Foo', 'bar')); - $client = new Client(['handler' => $stack]); - -Now when you send a request, the client will use a handler composed with your -added middleware, adding a header to each request. - -Here's an example of creating a middleware that modifies the response of the -downstream handler. This example adds a header to the response. - -.. code-block:: php - - use Psr\Http\Message\RequestInterface; - use Psr\Http\Message\ResponseInterface; - use GuzzleHttp\HandlerStack; - use GuzzleHttp\Handler\CurlHandler; - use GuzzleHttp\Client; - - function add_response_header($header, $value) - { - return function (callable $handler) use ($header, $value) { - return function ( - RequestInterface $request, - array $options - ) use ($handler, $header, $value) { - $promise = $handler($request, $options); - return $promise->then( - function (ResponseInterface $response) use ($header, $value) { - return $response->withHeader($header, $value); - } - ); - }; - }; - } - - $stack = new HandlerStack(); - $stack->setHandler(new CurlHandler()); - $stack->push(add_response_header('X-Foo', 'bar')); - $client = new Client(['handler' => $stack]); - -Creating a middleware that modifies a request is made much simpler using the -``GuzzleHttp\Middleware::mapRequest()`` middleware. This middleware accepts -a function that takes the request argument and returns the request to send. - -.. code-block:: php - - use Psr\Http\Message\RequestInterface; - use GuzzleHttp\HandlerStack; - use GuzzleHttp\Handler\CurlHandler; - use GuzzleHttp\Client; - use GuzzleHttp\Middleware; - - $stack = new HandlerStack(); - $stack->setHandler(new CurlHandler()); - - $stack->push(Middleware::mapRequest(function (RequestInterface $request) { - return $request->withHeader('X-Foo', 'bar'); - })); - - $client = new Client(['handler' => $stack]); - -Modifying a response is also much simpler using the -``GuzzleHttp\Middleware::mapResponse()`` middleware. - -.. code-block:: php - - use Psr\Http\Message\ResponseInterface; - use GuzzleHttp\HandlerStack; - use GuzzleHttp\Handler\CurlHandler; - use GuzzleHttp\Client; - use GuzzleHttp\Middleware; - - $stack = new HandlerStack(); - $stack->setHandler(new CurlHandler()); - - $stack->push(Middleware::mapResponse(function (ResponseInterface $response) { - return $response->withHeader('X-Foo', 'bar'); - })); - - $client = new Client(['handler' => $stack]); - - -HandlerStack -============ - -A handler stack represents a stack of middleware to apply to a base handler -function. You can push middleware to the stack to add to the top of the stack, -and unshift middleware onto the stack to add to the bottom of the stack. When -the stack is resolved, the handler is pushed onto the stack. Each value is -then popped off of the stack, wrapping the previous value popped off of the -stack. - -.. code-block:: php - - use Psr\Http\Message\RequestInterface; - use GuzzleHttp\HandlerStack; - use GuzzleHttp\Middleware; - use GuzzleHttp\Client; - - $stack = new HandlerStack(); - $stack->setHandler(\GuzzleHttp\choose_handler()); - - $stack->push(Middleware::mapRequest(function (RequestInterface $r) { - echo 'A'; - return $r; - }); - - $stack->push(Middleware::mapRequest(function (RequestInterface $r) { - echo 'B'; - return $r; - }); - - $stack->push(Middleware::mapRequest(function (RequestInterface $r) { - echo 'C'; - return $r; - }); - - $client->request('GET', 'http://httpbin.org/'); - // echoes 'ABC'; - - $stack->unshift(Middleware::mapRequest(function (RequestInterface $r) { - echo '0'; - return $r; - }); - - $client = new Client(['handler' => $stack]); - $client->request('GET', 'http://httpbin.org/'); - // echoes '0ABC'; - -You can give middleware a name, which allows you to add middleware before -other named middleware, after other named middleware, or remove middleware -by name. - -.. code-block:: php - - use Psr\Http\Message\RequestInterface; - use GuzzleHttp\Middleware; - - // Add a middleware with a name - $stack->push(Middleware::mapRequest(function (RequestInterface $r) { - return $r->withHeader('X-Foo', 'Bar'); - }, 'add_foo'); - - // Add a middleware before a named middleware (unshift before). - $stack->before('add_foo', Middleware::mapRequest(function (RequestInterface $r) { - return $r->withHeader('X-Baz', 'Qux'); - }, 'add_baz'); - - // Add a middleware after a named middleware (pushed after). - $stack->after('add_baz', Middleware::mapRequest(function (RequestInterface $r) { - return $r->withHeader('X-Lorem', 'Ipsum'); - }); - - // Remove a middleware by name - $stack->remove('add_foo'); - - -Creating a Handler -================== - -As stated earlier, a handler is a function accepts a -``Psr\Http\Message\RequestInterface`` and array of request options and returns -a ``GuzzleHttp\Promise\PromiseInterface`` that is fulfilled with a -``Psr\Http\Message\ResponseInterface`` or rejected with an exception. - -A handler is responsible for applying the following :doc:`request-options`. -These request options are a subset of request options called -"transfer options". - -- :ref:`cert-option` -- :ref:`connect_timeout-option` -- :ref:`debug-option` -- :ref:`delay-option` -- :ref:`decode_content-option` -- :ref:`expect-option` -- :ref:`proxy-option` -- :ref:`sink-option` -- :ref:`timeout-option` -- :ref:`ssl_key-option` -- :ref:`stream-option` -- :ref:`verify-option` diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/index.rst b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/index.rst deleted file mode 100644 index fba46f06..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/index.rst +++ /dev/null @@ -1,54 +0,0 @@ -.. title:: Guzzle, PHP HTTP client - -==================== -Guzzle Documentation -==================== - -Guzzle is a PHP HTTP client that makes it easy to send HTTP requests and -trivial to integrate with web services. - -- Simple interface for building query strings, POST requests, streaming large - uploads, streaming large downloads, using HTTP cookies, uploading JSON data, - etc... -- Can send both synchronous and asynchronous requests using the same interface. -- Uses PSR-7 interfaces for requests, responses, and streams. This allows you - to utilize other PSR-7 compatible libraries with Guzzle. -- Abstracts away the underlying HTTP transport, allowing you to write - environment and transport agnostic code; i.e., no hard dependency on cURL, - PHP streams, sockets, or non-blocking event loops. -- Middleware system allows you to augment and compose client behavior. - -.. code-block:: php - - $client = new GuzzleHttp\Client(); - $res = $client->request('GET', 'https://api.github.com/user', [ - 'auth' => ['user', 'pass'] - ]); - echo $res->getStatusCode(); - // "200" - echo $res->getHeader('content-type')[0]; - // 'application/json; charset=utf8' - echo $res->getBody(); - // {"type":"User"...' - - // Send an asynchronous request. - $request = new \GuzzleHttp\Psr7\Request('GET', 'http://httpbin.org'); - $promise = $client->sendAsync($request)->then(function ($response) { - echo 'I completed! ' . $response->getBody(); - }); - $promise->wait(); - - -User Guide -========== - -.. toctree:: - :maxdepth: 3 - - overview - quickstart - request-options - psr7 - handlers-and-middleware - testing - faq diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/overview.rst b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/overview.rst deleted file mode 100644 index 6d3fa07e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/overview.rst +++ /dev/null @@ -1,161 +0,0 @@ -======== -Overview -======== - -Requirements -============ - -#. PHP 5.5.0 -#. To use the PHP stream handler, ``allow_url_fopen`` must be enabled in your - system's php.ini. -#. To use the cURL handler, you must have a recent version of cURL >= 7.19.4 - compiled with OpenSSL and zlib. - -.. note:: - - Guzzle no longer requires cURL in order to send HTTP requests. Guzzle will - use the PHP stream wrapper to send HTTP requests if cURL is not installed. - Alternatively, you can provide your own HTTP handler used to send requests. - Keep in mind that cURL is still required for sending concurrent requests. - - -.. _installation: - - -Installation -============ - -The recommended way to install Guzzle is with -`Composer `_. Composer is a dependency management tool -for PHP that allows you to declare the dependencies your project needs and -installs them into your project. - -.. code-block:: bash - - # Install Composer - curl -sS https://getcomposer.org/installer | php - -You can add Guzzle as a dependency using the composer.phar CLI: - -.. code-block:: bash - - php composer.phar require guzzlehttp/guzzle:~6.0 - -Alternatively, you can specify Guzzle as a dependency in your project's -existing composer.json file: - -.. code-block:: js - - { - "require": { - "guzzlehttp/guzzle": "~6.0" - } - } - -After installing, you need to require Composer's autoloader: - -.. code-block:: php - - require 'vendor/autoload.php'; - -You can find out more on how to install Composer, configure autoloading, and -other best-practices for defining dependencies at `getcomposer.org `_. - - -Bleeding edge -------------- - -During your development, you can keep up with the latest changes on the master -branch by setting the version requirement for Guzzle to ``~6.0@dev``. - -.. code-block:: js - - { - "require": { - "guzzlehttp/guzzle": "~6.0@dev" - } - } - - -License -======= - -Licensed using the `MIT license `_. - - Copyright (c) 2015 Michael Dowling - - 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. - - -Contributing -============ - - -Guidelines ----------- - -1. Guzzle utilizes PSR-1, PSR-2, PSR-4, and PSR-7. -2. Guzzle is meant to be lean and fast with very few dependencies. This means - that not every feature request will be accepted. -3. Guzzle has a minimum PHP version requirement of PHP 5.5. Pull requests must - not require a PHP version greater than PHP 5.5 unless the feature is only - utilized conditionally. -4. All pull requests must include unit tests to ensure the change works as - expected and to prevent regressions. - - -Running the tests ------------------ - -In order to contribute, you'll need to checkout the source from GitHub and -install Guzzle's dependencies using Composer: - -.. code-block:: bash - - git clone https://github.com/guzzle/guzzle.git - cd guzzle && curl -s http://getcomposer.org/installer | php && ./composer.phar install --dev - -Guzzle is unit tested with PHPUnit. Run the tests using the Makefile: - -.. code-block:: bash - - make test - -.. note:: - - You'll need to install node.js v0.5.0 or newer in order to perform - integration tests on Guzzle's HTTP handlers. - - -Reporting a security vulnerability -================================== - -We want to ensure that Guzzle is a secure HTTP client library for everyone. If -you've discovered a security vulnerability in Guzzle, we appreciate your help -in disclosing it to us in a `responsible manner `_. - -Publicly disclosing a vulnerability can put the entire community at risk. If -you've discovered a security concern, please email us at -security@guzzlephp.org. We'll work with you to make sure that we understand the -scope of the issue, and that we fully address your concern. We consider -correspondence sent to security@guzzlephp.org our highest priority, and work to -address any issues that arise as quickly as possible. - -After a security vulnerability has been corrected, a security hotfix release will -be deployed as soon as possible. diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/psr7.rst b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/psr7.rst deleted file mode 100644 index 3766aaa8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/psr7.rst +++ /dev/null @@ -1,456 +0,0 @@ -================ -Guzzle and PSR-7 -================ - -Guzzle utilizes PSR-7 as the HTTP message interface. This allows Guzzle to work -with any other library that utilizes PSR-7 message interfaces. - -Guzzle is an HTTP client that sends HTTP requests to a server and receives HTTP -responses. Both requests and responses are referred to as messages. - -Guzzle relies on the ``guzzlehttp/psr7`` Composer package for its message -implementation of PSR-7. - -You can create a request using the ``GuzzleHttp\Psr7\Request`` class: - -.. code-block:: php - - use GuzzleHttp\Psr7\Request; - - $request = new Request('GET', 'http://httpbin.org/get'); - - // You can provide other optional constructor arguments. - $headers = ['X-Foo' => 'Bar']; - $body = 'hello!'; - $request = new Request('PUT', 'http://httpbin.org/put', $headers, $body); - -You can create a response using the ``GuzzleHttp\Psr7\Response`` class: - -.. code-block:: php - - use GuzzleHttp\Psr7\Response; - - // The constructor requires no arguments. - $response = new Response(); - echo $response->getStatusCode(); // 200 - echo $response->getProtocolVersion(); // 1.1 - - // You can supply any number of optional arguments. - $status = 200; - $headers = ['X-Foo' => 'Bar']; - $body = 'hello!'; - $protocol = '1.1'; - $response = new Response($status, $headers, $body, $protocol); - - -Headers -======= - -Both request and response messages contain HTTP headers. - - -Accessing Headers ------------------ - -You can check if a request or response has a specific header using the -``hasHeader()`` method. - -.. code-block:: php - - use GuzzleHttp\Psr7; - - $request = new Psr7\Request('GET', '/', ['X-Foo' => 'bar']); - - if ($request->hasHeader('X-Foo')) { - echo 'It is there'; - } - -You can retrieve all the header values as an array of strings using -``getHeader()``. - -.. code-block:: php - - $request->getHeader('X-Foo'); // ['bar'] - - // Retrieving a missing header returns an empty array. - $request->getHeader('X-Bar'); // [] - -You can iterate over the headers of a message using the ``getHeaders()`` -method. - -.. code-block:: php - - foreach ($request->getHeaders() as $name => $values) { - echo $name . ': ' . implode(', ', $values) . "\r\n"; - } - - -Complex Headers ---------------- - -Some headers contain additional key value pair information. For example, Link -headers contain a link and several key value pairs: - -:: - - ; rel="thing"; type="image/jpeg" - -Guzzle provides a convenience feature that can be used to parse these types of -headers: - -.. code-block:: php - - use GuzzleHttp\Psr7; - - $request = new Psr7\Request('GET', '/', [ - 'Link' => '; rel="front"; type="image/jpeg"' - ]); - - $parsed = Psr7\parse_header($request->getHeader('Link')); - var_export($parsed); - -Will output: - -.. code-block:: php - - array ( - 0 => - array ( - 0 => '', - 'rel' => 'front', - 'type' => 'image/jpeg', - ), - ) - -The result contains a hash of key value pairs. Header values that have no key -(i.e., the link) are indexed numerically while headers parts that form a key -value pair are added as a key value pair. - - -Body -==== - -Both request and response messages can contain a body. - -You can retrieve the body of a message using the ``getBody()`` method: - -.. code-block:: php - - $response = GuzzleHttp\get('http://httpbin.org/get'); - echo $response->getBody(); - // JSON string: { ... } - -The body used in request and response objects is a -``Psr\Http\Message\StreamInterface``. This stream is used for both -uploading data and downloading data. Guzzle will, by default, store the body of -a message in a stream that uses PHP temp streams. When the size of the body -exceeds 2 MB, the stream will automatically switch to storing data on disk -rather than in memory (protecting your application from memory exhaustion). - -The easiest way to create a body for a message is using the ``stream_for`` -function from the ``GuzzleHttp\Psr7`` namespace -- -``GuzzleHttp\Psr7\stream_for``. This function accepts strings, resources, -callables, iterators, other streamables, and returns an instance of -``Psr\Http\Message\StreamInterface``. - -The body of a request or response can be cast to a string or you can read and -write bytes off of the stream as needed. - -.. code-block:: php - - use GuzzleHttp\Stream\Stream; - $response = $client->request('GET', 'http://httpbin.org/get'); - - echo $response->getBody()->read(4); - echo $response->getBody()->read(4); - echo $response->getBody()->read(1024); - var_export($response->eof()); - - -Requests -======== - -Requests are sent from a client to a server. Requests include the method to -be applied to a resource, the identifier of the resource, and the protocol -version to use. - - -Request Methods ---------------- - -When creating a request, you are expected to provide the HTTP method you wish -to perform. You can specify any method you'd like, including a custom method -that might not be part of RFC 7231 (like "MOVE"). - -.. code-block:: php - - // Create a request using a completely custom HTTP method - $request = new \GuzzleHttp\Psr7\Request('MOVE', 'http://httpbin.org/move'); - - echo $request->getMethod(); - // MOVE - -You can create and send a request using methods on a client that map to the -HTTP method you wish to use. - -:GET: ``$client->get('http://httpbin.org/get', [/** options **/])`` -:POST: ``$client->post('http://httpbin.org/post', [/** options **/])`` -:HEAD: ``$client->head('http://httpbin.org/get', [/** options **/])`` -:PUT: ``$client->put('http://httpbin.org/put', [/** options **/])`` -:DELETE: ``$client->delete('http://httpbin.org/delete', [/** options **/])`` -:OPTIONS: ``$client->options('http://httpbin.org/get', [/** options **/])`` -:PATCH: ``$client->patch('http://httpbin.org/put', [/** options **/])`` - -For example: - -.. code-block:: php - - $response = $client->patch('http://httpbin.org/patch', ['body' => 'content']); - - -Request URI ------------ - -The request URI is represented by a ``Psr\Http\Message\UriInterface`` object. -Guzzle provides an implementation of this interface using the -``GuzzleHttp\Psr7\Uri`` class. - -When creating a request, you can provide the URI as a string or an instance of -``Psr\Http\Message\UriInterface``. - -.. code-block:: php - - $response = $client->request('GET', 'http://httpbin.org/get?q=foo'); - - -Scheme ------- - -The `scheme `_ of a request -specifies the protocol to use when sending the request. When using Guzzle, the -scheme can be set to "http" or "https". - -.. code-block:: php - - $request = new Request('GET', 'http://httpbin.org'); - echo $request->getUri()->getScheme(); // http - echo $request->getUri(); // http://httpbin.org - - -Host ----- - -The host is accessible using the URI owned by the request or by accessing the -Host header. - -.. code-block:: php - - $request = new Request('GET', 'http://httpbin.org'); - echo $request->getUri()->getHost(); // httpbin.org - echo $request->getHeader('Host'); // httpbin.org - - -Port ----- - -No port is necessary when using the "http" or "https" schemes. - -.. code-block:: php - - $request = new Request('GET', 'http://httpbin.org:8080'); - echo $request->getUri()->getPort(); // 8080 - echo $request->getUri(); // http://httpbin.org:8080 - - -Path ----- - -The path of a request is accessible via the URI object. - -.. code-block:: php - - $request = new Request('GET', 'http://httpbin.org/get'); - echo $request->getUri()->getPath(); // /get - -The contents of the path will be automatically filtered to ensure that only -allowed characters are present in the path. Any characters that are not allowed -in the path will be percent-encoded according to -`RFC 3986 section 3.3 `_ - - -Query string ------------- - -The query string of a request can be accessed using the ``getQuery()`` of the -URI object owned by the request. - -.. code-block:: php - - $request = new Request('GET', 'http://httpbin.org/?foo=bar'); - echo $request->getUri()->getQuery(); // foo=bar - -The contents of the query string will be automatically filtered to ensure that -only allowed characters are present in the query string. Any characters that -are not allowed in the query string will be percent-encoded according to -`RFC 3986 section 3.4 `_ - - -Responses -========= - -Responses are the HTTP messages a client receives from a server after sending -an HTTP request message. - - -Start-Line ----------- - -The start-line of a response contains the protocol and protocol version, -status code, and reason phrase. - -.. code-block:: php - - $client = new \GuzzleHttp\Client(); - $response = $client->request('GET', 'http://httpbin.org/get'); - - echo $response->getStatusCode(); // 200 - echo $response->getReasonPhrase(); // OK - echo $response->getProtocolVersion(); // 1.1 - - -Body ----- - -As described earlier, you can get the body of a response using the -``getBody()`` method. - -.. code-block:: php - - $body = $response->getBody(); - echo $body; - // Cast to a string: { ... } - $body->seek(0); - // Rewind the body - $body->read(1024); - // Read bytes of the body - - -Streams -======= - -Guzzle uses PSR-7 stream objects to represent request and response message -bodies. These stream objects allow you to work with various types of data all -using a common interface. - -HTTP messages consist of a start-line, headers, and a body. The body of an HTTP -message can be very small or extremely large. Attempting to represent the body -of a message as a string can easily consume more memory than intended because -the body must be stored completely in memory. Attempting to store the body of a -request or response in memory would preclude the use of that implementation from -being able to work with large message bodies. The StreamInterface is used in -order to hide the implementation details of where a stream of data is read from -or written to. - -The PSR-7 ``Psr\Http\Message\StreamInterface`` exposes several methods -that enable streams to be read from, written to, and traversed effectively. - -Streams expose their capabilities using three methods: ``isReadable()``, -``isWritable()``, and ``isSeekable()``. These methods can be used by stream -collaborators to determine if a stream is capable of their requirements. - -Each stream instance has various capabilities: they can be read-only, -write-only, read-write, allow arbitrary random access (seeking forwards or -backwards to any location), or only allow sequential access (for example in the -case of a socket or pipe). - -Guzzle uses the ``guzzlehttp/psr7`` package to provide stream support. More -information on using streams, creating streams, converting streams to PHP -stream resource, and stream decorators can be found in the -`Guzzle PSR-7 documentation `_. - - -Creating Streams ----------------- - -The best way to create a stream is using the ``GuzzleHttp\Psr7\stream_for`` -function. This function accepts strings, resources returned from ``fopen()``, -an object that implements ``__toString()``, iterators, callables, and instances -of ``Psr\Http\Message\StreamInterface``. - -.. code-block:: php - - use GuzzleHttp\Psr7; - - $stream = Psr7\stream_for('string data'); - echo $stream; - // string data - echo $stream->read(3); - // str - echo $stream->getContents(); - // ing data - var_export($stream->eof()); - // true - var_export($stream->tell()); - // 11 - -You can create streams from iterators. The iterator can yield any number of -bytes per iteration. Any excess bytes returned by the iterator that were not -requested by a stream consumer will be buffered until a subsequent read. - -.. code-block:: php - - use GuzzleHttp\Psr7; - - $generator = function ($bytes) { - for ($i = 0; $i < $bytes; $i++) { - yield '.'; - } - }; - - $iter = $generator(1024); - $stream = Psr7\stream_for($iter); - echo $stream->read(3); // ... - - -Metadata --------- - -Streams expose stream metadata through the ``getMetadata()`` method. This -method provides the data you would retrieve when calling PHP's -`stream_get_meta_data() function `_, -and can optionally expose other custom data. - -.. code-block:: php - - use GuzzleHttp\Psr7; - - $resource = fopen('/path/to/file', 'r'); - $stream = Psr7\stream_for($resource); - echo $stream->getMetadata('uri'); - // /path/to/file - var_export($stream->isReadable()); - // true - var_export($stream->isWritable()); - // false - var_export($stream->isSeekable()); - // true - - -Stream Decorators ------------------ - -Adding custom functionality to streams is very simple with stream decorators. -Guzzle provides several built-in decorators that provide additional stream -functionality. - -- `AppendStream `_ -- `BufferStream `_ -- `CachingStream `_ -- `DroppingStream `_ -- `FnStream `_ -- `InflateStream `_ -- `LazyOpenStream `_ -- `LimitStream `_ -- `MultipartStream `_ -- `NoSeekStream `_ -- `PumpStream `_ diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/quickstart.rst b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/quickstart.rst deleted file mode 100644 index 7a3f35fb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/quickstart.rst +++ /dev/null @@ -1,624 +0,0 @@ -========== -Quickstart -========== - -This page provides a quick introduction to Guzzle and introductory examples. -If you have not already installed, Guzzle, head over to the :ref:`installation` -page. - - -Making a Request -================ - -You can send requests with Guzzle using a ``GuzzleHttp\ClientInterface`` -object. - - -Creating a Client ------------------ - -.. code-block:: php - - use GuzzleHttp\Client; - - $client = new Client([ - // Base URI is used with relative requests - 'base_uri' => 'http://httpbin.org', - // You can set any number of default request options. - 'timeout' => 2.0, - ]); - -Clients are immutable in Guzzle 6, which means that you cannot change the defaults used by a client after it's created. - -The client constructor accepts an associative array of options: - -``base_uri`` - (string|UriInterface) Base URI of the client that is merged into relative - URIs. Can be a string or instance of UriInterface. When a relative URI - is provided to a client, the client will combine the base URI with the - relative URI using the rules described in - `RFC 3986, section 2 `_. - - .. code-block:: php - - // Create a client with a base URI - $client = new GuzzleHttp\Client(['base_uri' => 'https://foo.com/api/']); - // Send a request to https://foo.com/api/test - $response = $client->request('GET', 'test'); - // Send a request to https://foo.com/root - $response = $client->request('GET', '/root'); - - Don't feel like reading RFC 3986? Here are some quick examples on how a - ``base_uri`` is resolved with another URI. - - ======================= ================== =============================== - base_uri URI Result - ======================= ================== =============================== - ``http://foo.com`` ``/bar`` ``http://foo.com/bar`` - ``http://foo.com/foo`` ``/bar`` ``http://foo.com/bar`` - ``http://foo.com/foo`` ``bar`` ``http://foo.com/bar`` - ``http://foo.com/foo/`` ``bar`` ``http://foo.com/foo/bar`` - ``http://foo.com`` ``http://baz.com`` ``http://baz.com`` - ``http://foo.com/?bar`` ``bar`` ``http://foo.com/bar`` - ======================= ================== =============================== - -``handler`` - (callable) Function that transfers HTTP requests over the wire. The - function is called with a ``Psr7\Http\Message\RequestInterface`` and array - of transfer options, and must return a - ``GuzzleHttp\Promise\PromiseInterface`` that is fulfilled with a - ``Psr7\Http\Message\ResponseInterface`` on success. - -``...`` - (mixed) All other options passed to the constructor are used as default - request options with every request created by the client. - - -Sending Requests ----------------- - -Magic methods on the client make it easy to send synchronous requests: - -.. code-block:: php - - $response = $client->get('http://httpbin.org/get'); - $response = $client->delete('http://httpbin.org/delete'); - $response = $client->head('http://httpbin.org/get'); - $response = $client->options('http://httpbin.org/get'); - $response = $client->patch('http://httpbin.org/patch'); - $response = $client->post('http://httpbin.org/post'); - $response = $client->put('http://httpbin.org/put'); - -You can create a request and then send the request with the client when you're -ready: - -.. code-block:: php - - use GuzzleHttp\Psr7\Request; - - $request = new Request('PUT', 'http://httpbin.org/put'); - $response = $client->send($request, ['timeout' => 2]); - -Client objects provide a great deal of flexibility in how request are -transferred including default request options, default handler stack middleware -that are used by each request, and a base URI that allows you to send requests -with relative URIs. - -You can find out more about client middleware in the -:doc:`handlers-and-middleware` page of the documentation. - - -Async Requests --------------- - -You can send asynchronous requests using the magic methods provided by a client: - -.. code-block:: php - - $promise = $client->getAsync('http://httpbin.org/get'); - $promise = $client->deleteAsync('http://httpbin.org/delete'); - $promise = $client->headAsync('http://httpbin.org/get'); - $promise = $client->optionsAsync('http://httpbin.org/get'); - $promise = $client->patchAsync('http://httpbin.org/patch'); - $promise = $client->postAsync('http://httpbin.org/post'); - $promise = $client->putAsync('http://httpbin.org/put'); - -You can also use the `sendAsync()` and `requestAsync()` methods of a client: - -.. code-block:: php - - use GuzzleHttp\Psr7\Request; - - // Create a PSR-7 request object to send - $headers = ['X-Foo' => 'Bar']; - $body = 'Hello!'; - $request = new Request('HEAD', 'http://httpbin.org/head', $headers, $body); - $promise = $client->sendAsync($request); - - // Or, if you don't need to pass in a request instance: - $promise = $client->requestAsync('GET', 'http://httpbin.org/get'); - -The promise returned by these methods implements the -`Promises/A+ spec `_, provided by the -`Guzzle promises library `_. This means -that you can chain ``then()`` calls off of the promise. These then calls are -either fulfilled with a successful ``Psr\Http\Message\ResponseInterface`` or -rejected with an exception. - -.. code-block:: php - - use Psr\Http\Message\ResponseInterface; - use GuzzleHttp\Exception\RequestException; - - $promise = $client->requestAsync('GET', 'http://httpbin.org/get'); - $promise->then( - function (ResponseInterface $res) { - echo $res->getStatusCode() . "\n"; - }, - function (RequestException $e) { - echo $e->getMessage() . "\n"; - echo $e->getRequest()->getMethod(); - } - ); - - -Concurrent requests -------------------- - -You can send multiple requests concurrently using promises and asynchronous -requests. - -.. code-block:: php - - use GuzzleHttp\Client; - use GuzzleHttp\Promise; - - $client = new Client(['base_uri' => 'http://httpbin.org/']); - - // Initiate each request but do not block - $promises = [ - 'image' => $client->getAsync('/image'), - 'png' => $client->getAsync('/image/png'), - 'jpeg' => $client->getAsync('/image/jpeg'), - 'webp' => $client->getAsync('/image/webp') - ]; - - // Wait for the requests to complete; throws a ConnectException - // if any of the requests fail - $responses = Promise\unwrap($promises); - - // Wait for the requests to complete, even if some of them fail - $responses = Promise\settle($promises)->wait(); - - // You can access each response using the key of the promise - echo $responses['image']->getHeader('Content-Length')[0]; - echo $responses['png']->getHeader('Content-Length')[0]; - -You can use the ``GuzzleHttp\Pool`` object when you have an indeterminate -amount of requests you wish to send. - -.. code-block:: php - - use GuzzleHttp\Client; - use GuzzleHttp\Exception\RequestException; - use GuzzleHttp\Pool; - use GuzzleHttp\Psr7\Request; - use GuzzleHttp\Psr7\Response; - - $client = new Client(); - - $requests = function ($total) { - $uri = 'http://127.0.0.1:8126/guzzle-server/perf'; - for ($i = 0; $i < $total; $i++) { - yield new Request('GET', $uri); - } - }; - - $pool = new Pool($client, $requests(100), [ - 'concurrency' => 5, - 'fulfilled' => function (Response $response, $index) { - // this is delivered each successful response - }, - 'rejected' => function (RequestException $reason, $index) { - // this is delivered each failed request - }, - ]); - - // Initiate the transfers and create a promise - $promise = $pool->promise(); - - // Force the pool of requests to complete. - $promise->wait(); - -Or using a closure that will return a promise once the pool calls the closure. - -.. code-block:: php - - $client = new Client(); - - $requests = function ($total) use ($client) { - $uri = 'http://127.0.0.1:8126/guzzle-server/perf'; - for ($i = 0; $i < $total; $i++) { - yield function() use ($client, $uri) { - return $client->getAsync($uri); - }; - } - }; - - $pool = new Pool($client, $requests(100)); - - -Using Responses -=============== - -In the previous examples, we retrieved a ``$response`` variable or we were -delivered a response from a promise. The response object implements a PSR-7 -response, ``Psr\Http\Message\ResponseInterface``, and contains lots of -helpful information. - -You can get the status code and reason phrase of the response: - -.. code-block:: php - - $code = $response->getStatusCode(); // 200 - $reason = $response->getReasonPhrase(); // OK - -You can retrieve headers from the response: - -.. code-block:: php - - // Check if a header exists. - if ($response->hasHeader('Content-Length')) { - echo "It exists"; - } - - // Get a header from the response. - echo $response->getHeader('Content-Length')[0]; - - // Get all of the response headers. - foreach ($response->getHeaders() as $name => $values) { - echo $name . ': ' . implode(', ', $values) . "\r\n"; - } - -The body of a response can be retrieved using the ``getBody`` method. The body -can be used as a string, cast to a string, or used as a stream like object. - -.. code-block:: php - - $body = $response->getBody(); - // Implicitly cast the body to a string and echo it - echo $body; - // Explicitly cast the body to a string - $stringBody = (string) $body; - // Read 10 bytes from the body - $tenBytes = $body->read(10); - // Read the remaining contents of the body as a string - $remainingBytes = $body->getContents(); - - -Query String Parameters -======================= - -You can provide query string parameters with a request in several ways. - -You can set query string parameters in the request's URI: - -.. code-block:: php - - $response = $client->request('GET', 'http://httpbin.org?foo=bar'); - -You can specify the query string parameters using the ``query`` request -option as an array. - -.. code-block:: php - - $client->request('GET', 'http://httpbin.org', [ - 'query' => ['foo' => 'bar'] - ]); - -Providing the option as an array will use PHP's ``http_build_query`` function -to format the query string. - -And finally, you can provide the ``query`` request option as a string. - -.. code-block:: php - - $client->request('GET', 'http://httpbin.org', ['query' => 'foo=bar']); - - -Uploading Data -============== - -Guzzle provides several methods for uploading data. - -You can send requests that contain a stream of data by passing a string, -resource returned from ``fopen``, or an instance of a -``Psr\Http\Message\StreamInterface`` to the ``body`` request option. - -.. code-block:: php - - // Provide the body as a string. - $r = $client->request('POST', 'http://httpbin.org/post', [ - 'body' => 'raw data' - ]); - - // Provide an fopen resource. - $body = fopen('/path/to/file', 'r'); - $r = $client->request('POST', 'http://httpbin.org/post', ['body' => $body]); - - // Use the stream_for() function to create a PSR-7 stream. - $body = \GuzzleHttp\Psr7\stream_for('hello!'); - $r = $client->request('POST', 'http://httpbin.org/post', ['body' => $body]); - -An easy way to upload JSON data and set the appropriate header is using the -``json`` request option: - -.. code-block:: php - - $r = $client->request('PUT', 'http://httpbin.org/put', [ - 'json' => ['foo' => 'bar'] - ]); - - -POST/Form Requests ------------------- - -In addition to specifying the raw data of a request using the ``body`` request -option, Guzzle provides helpful abstractions over sending POST data. - - -Sending form fields -~~~~~~~~~~~~~~~~~~~ - -Sending ``application/x-www-form-urlencoded`` POST requests requires that you -specify the POST fields as an array in the ``form_params`` request options. - -.. code-block:: php - - $response = $client->request('POST', 'http://httpbin.org/post', [ - 'form_params' => [ - 'field_name' => 'abc', - 'other_field' => '123', - 'nested_field' => [ - 'nested' => 'hello' - ] - ] - ]); - - -Sending form files -~~~~~~~~~~~~~~~~~~ - -You can send files along with a form (``multipart/form-data`` POST requests), -using the ``multipart`` request option. ``multipart`` accepts an array of -associative arrays, where each associative array contains the following keys: - -- name: (required, string) key mapping to the form field name. -- contents: (required, mixed) Provide a string to send the contents of the - file as a string, provide an fopen resource to stream the contents from a - PHP stream, or provide a ``Psr\Http\Message\StreamInterface`` to stream - the contents from a PSR-7 stream. - -.. code-block:: php - - $response = $client->request('POST', 'http://httpbin.org/post', [ - 'multipart' => [ - [ - 'name' => 'field_name', - 'contents' => 'abc' - ], - [ - 'name' => 'file_name', - 'contents' => fopen('/path/to/file', 'r') - ], - [ - 'name' => 'other_file', - 'contents' => 'hello', - 'filename' => 'filename.txt', - 'headers' => [ - 'X-Foo' => 'this is an extra header to include' - ] - ] - ] - ]); - - -Cookies -======= - -Guzzle can maintain a cookie session for you if instructed using the -``cookies`` request option. When sending a request, the ``cookies`` option -must be set to an instance of ``GuzzleHttp\Cookie\CookieJarInterface``. - -.. code-block:: php - - // Use a specific cookie jar - $jar = new \GuzzleHttp\Cookie\CookieJar; - $r = $client->request('GET', 'http://httpbin.org/cookies', [ - 'cookies' => $jar - ]); - -You can set ``cookies`` to ``true`` in a client constructor if you would like -to use a shared cookie jar for all requests. - -.. code-block:: php - - // Use a shared client cookie jar - $client = new \GuzzleHttp\Client(['cookies' => true]); - $r = $client->request('GET', 'http://httpbin.org/cookies'); - -Different implementations exist for the ``GuzzleHttp\Cookie\CookieJarInterface`` -: - -- The ``GuzzleHttp\Cookie\CookieJar`` class stores cookies as an array. -- The ``GuzzleHttp\Cookie\FileCookieJar`` class persists non-session cookies - using a JSON formatted file. -- The ``GuzzleHttp\Cookie\SessionCookieJar`` class persists cookies in the - client session. - -You can manually set cookies into a cookie jar with the named constructor -``fromArray(array $cookies, $domain)``. - -.. code-block:: php - - $jar = \GuzzleHttp\Cookie\CookieJar::fromArray( - [ - 'some_cookie' => 'foo', - 'other_cookie' => 'barbaz1234' - ], - 'example.org' - ); - -You can get a cookie by its name with the ``getCookieByName($name)`` method -which returns a ``GuzzleHttp\Cookie\SetCookie`` instance. - -.. code-block:: php - - $cookie = $jar->getCookieByName('some_cookie'); - - $cookie->getValue(); // 'foo' - $cookie->getDomain(); // 'example.org' - $cookie->getExpires(); // expiration date as a Unix timestamp - -The cookies can be also fetched into an array thanks to the `toArray()` method. -The ``GuzzleHttp\Cookie\CookieJarInterface`` interface extends -``Traversable`` so it can be iterated in a foreach loop. - - -Redirects -========= - -Guzzle will automatically follow redirects unless you tell it not to. You can -customize the redirect behavior using the ``allow_redirects`` request option. - -- Set to ``true`` to enable normal redirects with a maximum number of 5 - redirects. This is the default setting. -- Set to ``false`` to disable redirects. -- Pass an associative array containing the 'max' key to specify the maximum - number of redirects and optionally provide a 'strict' key value to specify - whether or not to use strict RFC compliant redirects (meaning redirect POST - requests with POST requests vs. doing what most browsers do which is - redirect POST requests with GET requests). - -.. code-block:: php - - $response = $client->request('GET', 'http://github.com'); - echo $response->getStatusCode(); - // 200 - -The following example shows that redirects can be disabled. - -.. code-block:: php - - $response = $client->request('GET', 'http://github.com', [ - 'allow_redirects' => false - ]); - echo $response->getStatusCode(); - // 301 - - -Exceptions -========== - -**Tree View** - -The following tree view describes how the Guzzle Exceptions depend -on each other. - -.. code-block:: none - - . \RuntimeException - ├── SeekException (implements GuzzleException) - └── TransferException (implements GuzzleException) - └── RequestException - ├── BadResponseException - │   ├── ServerException - │ └── ClientException - ├── ConnectException - └── TooManyRedirectsException - -Guzzle throws exceptions for errors that occur during a transfer. - -- In the event of a networking error (connection timeout, DNS errors, etc.), - a ``GuzzleHttp\Exception\RequestException`` is thrown. This exception - extends from ``GuzzleHttp\Exception\TransferException``. Catching this - exception will catch any exception that can be thrown while transferring - requests. - - .. code-block:: php - - use GuzzleHttp\Psr7; - use GuzzleHttp\Exception\RequestException; - - try { - $client->request('GET', 'https://github.com/_abc_123_404'); - } catch (RequestException $e) { - echo Psr7\str($e->getRequest()); - if ($e->hasResponse()) { - echo Psr7\str($e->getResponse()); - } - } - -- A ``GuzzleHttp\Exception\ConnectException`` exception is thrown in the - event of a networking error. This exception extends from - ``GuzzleHttp\Exception\RequestException``. - -- A ``GuzzleHttp\Exception\ClientException`` is thrown for 400 - level errors if the ``http_errors`` request option is set to true. This - exception extends from ``GuzzleHttp\Exception\BadResponseException`` and - ``GuzzleHttp\Exception\BadResponseException`` extends from - ``GuzzleHttp\Exception\RequestException``. - - .. code-block:: php - - use GuzzleHttp\Psr7; - use GuzzleHttp\Exception\ClientException; - - try { - $client->request('GET', 'https://github.com/_abc_123_404'); - } catch (ClientException $e) { - echo Psr7\str($e->getRequest()); - echo Psr7\str($e->getResponse()); - } - -- A ``GuzzleHttp\Exception\ServerException`` is thrown for 500 level - errors if the ``http_errors`` request option is set to true. This - exception extends from ``GuzzleHttp\Exception\BadResponseException``. - -- A ``GuzzleHttp\Exception\TooManyRedirectsException`` is thrown when too - many redirects are followed. This exception extends from ``GuzzleHttp\Exception\RequestException``. - -All of the above exceptions extend from -``GuzzleHttp\Exception\TransferException``. - - -Environment Variables -===================== - -Guzzle exposes a few environment variables that can be used to customize the -behavior of the library. - -``GUZZLE_CURL_SELECT_TIMEOUT`` - Controls the duration in seconds that a curl_multi_* handler will use when - selecting on curl handles using ``curl_multi_select()``. Some systems - have issues with PHP's implementation of ``curl_multi_select()`` where - calling this function always results in waiting for the maximum duration of - the timeout. -``HTTP_PROXY`` - Defines the proxy to use when sending requests using the "http" protocol. - - Note: because the HTTP_PROXY variable may contain arbitrary user input on some (CGI) environments, the variable is only used on the CLI SAPI. See https://httpoxy.org for more information. -``HTTPS_PROXY`` - Defines the proxy to use when sending requests using the "https" protocol. -``NO_PROXY`` - Defines URLs for which a proxy should not be used. See :ref:`proxy-option` for usage. - - -Relevant ini Settings ---------------------- - -Guzzle can utilize PHP ini settings when configuring clients. - -``openssl.cafile`` - Specifies the path on disk to a CA file in PEM format to use when sending - requests over "https". See: https://wiki.php.net/rfc/tls-peer-verification#phpini_defaults diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/request-options.rst b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/request-options.rst deleted file mode 100644 index a822f58a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/request-options.rst +++ /dev/null @@ -1,1085 +0,0 @@ -=============== -Request Options -=============== - -You can customize requests created and transferred by a client using -**request options**. Request options control various aspects of a request -including, headers, query string parameters, timeout settings, the body of a -request, and much more. - -All of the following examples use the following client: - -.. code-block:: php - - $client = new GuzzleHttp\Client(['base_uri' => 'http://httpbin.org']); - - -.. _allow_redirects-option: - -allow_redirects ---------------- - -:Summary: Describes the redirect behavior of a request -:Types: - - bool - - array -:Default: - - :: - - [ - 'max' => 5, - 'strict' => false, - 'referer' => false, - 'protocols' => ['http', 'https'], - 'track_redirects' => false - ] - -:Constant: ``GuzzleHttp\RequestOptions::ALLOW_REDIRECTS`` - -Set to ``false`` to disable redirects. - -.. code-block:: php - - $res = $client->request('GET', '/redirect/3', ['allow_redirects' => false]); - echo $res->getStatusCode(); - // 302 - -Set to ``true`` (the default setting) to enable normal redirects with a maximum -number of 5 redirects. - -.. code-block:: php - - $res = $client->request('GET', '/redirect/3'); - echo $res->getStatusCode(); - // 200 - -You can also pass an associative array containing the following key value -pairs: - -- max: (int, default=5) maximum number of allowed redirects. -- strict: (bool, default=false) Set to true to use strict redirects. - Strict RFC compliant redirects mean that POST redirect requests are sent as - POST requests vs. doing what most browsers do which is redirect POST requests - with GET requests. -- referer: (bool, default=false) Set to true to enable adding the Referer - header when redirecting. -- protocols: (array, default=['http', 'https']) Specified which protocols are - allowed for redirect requests. -- on_redirect: (callable) PHP callable that is invoked when a redirect - is encountered. The callable is invoked with the original request and the - redirect response that was received. Any return value from the on_redirect - function is ignored. -- track_redirects: (bool) When set to ``true``, each redirected URI and status - code encountered will be tracked in the ``X-Guzzle-Redirect-History`` and - ``X-Guzzle-Redirect-Status-History`` headers respectively. All URIs and - status codes will be stored in the order which the redirects were encountered. - - Note: When tracking redirects the ``X-Guzzle-Redirect-History`` header will - exclude the initial request's URI and the ``X-Guzzle-Redirect-Status-History`` - header will exclude the final status code. - -.. code-block:: php - - use Psr\Http\Message\RequestInterface; - use Psr\Http\Message\ResponseInterface; - use Psr\Http\Message\UriInterface; - - $onRedirect = function( - RequestInterface $request, - ResponseInterface $response, - UriInterface $uri - ) { - echo 'Redirecting! ' . $request->getUri() . ' to ' . $uri . "\n"; - }; - - $res = $client->request('GET', '/redirect/3', [ - 'allow_redirects' => [ - 'max' => 10, // allow at most 10 redirects. - 'strict' => true, // use "strict" RFC compliant redirects. - 'referer' => true, // add a Referer header - 'protocols' => ['https'], // only allow https URLs - 'on_redirect' => $onRedirect, - 'track_redirects' => true - ] - ]); - - echo $res->getStatusCode(); - // 200 - - echo $res->getHeaderLine('X-Guzzle-Redirect-History'); - // http://first-redirect, http://second-redirect, etc... - - echo $res->getHeaderLine('X-Guzzle-Redirect-Status-History'); - // 301, 302, etc... - -.. warning:: - - This option only has an effect if your handler has the - ``GuzzleHttp\Middleware::redirect`` middleware. This middleware is added - by default when a client is created with no handler, and is added by - default when creating a handler with ``GuzzleHttp\HandlerStack::create``. - - -auth ----- - -:Summary: Pass an array of HTTP authentication parameters to use with the - request. The array must contain the username in index [0], the password in - index [1], and you can optionally provide a built-in authentication type in - index [2]. Pass ``null`` to disable authentication for a request. -:Types: - - array - - string - - null -:Default: None -:Constant: ``GuzzleHttp\RequestOptions::AUTH`` - -The built-in authentication types are as follows: - -basic - Use `basic HTTP authentication `_ - in the ``Authorization`` header (the default setting used if none is - specified). - -.. code-block:: php - - $client->request('GET', '/get', ['auth' => ['username', 'password']]); - -digest - Use `digest authentication `_ - (must be supported by the HTTP handler). - -.. code-block:: php - - $client->request('GET', '/get', [ - 'auth' => ['username', 'password', 'digest'] - ]); - -.. note:: - - This is currently only supported when using the cURL handler, but - creating a replacement that can be used with any HTTP handler is - planned. - -ntlm - Use `Microsoft NTLM authentication `_ - (must be supported by the HTTP handler). - -.. code-block:: php - - $client->request('GET', '/get', [ - 'auth' => ['username', 'password', 'ntlm'] - ]); - -.. note:: - - This is currently only supported when using the cURL handler. - - -body ----- - -:Summary: The ``body`` option is used to control the body of an entity - enclosing request (e.g., PUT, POST, PATCH). -:Types: - - string - - ``fopen()`` resource - - ``Psr\Http\Message\StreamInterface`` -:Default: None -:Constant: ``GuzzleHttp\RequestOptions::BODY`` - -This setting can be set to any of the following types: - -- string - - .. code-block:: php - - // You can send requests that use a string as the message body. - $client->request('PUT', '/put', ['body' => 'foo']); - -- resource returned from ``fopen()`` - - .. code-block:: php - - // You can send requests that use a stream resource as the body. - $resource = fopen('http://httpbin.org', 'r'); - $client->request('PUT', '/put', ['body' => $resource]); - -- ``Psr\Http\Message\StreamInterface`` - - .. code-block:: php - - // You can send requests that use a Guzzle stream object as the body - $stream = GuzzleHttp\Psr7\stream_for('contents...'); - $client->request('POST', '/post', ['body' => $stream]); - -.. note:: - - This option cannot be used with ``form_params``, ``multipart``, or ``json`` - - -.. _cert-option: - -cert ----- - -:Summary: Set to a string to specify the path to a file containing a PEM - formatted client side certificate. If a password is required, then set to - an array containing the path to the PEM file in the first array element - followed by the password required for the certificate in the second array - element. -:Types: - - string - - array -:Default: None -:Constant: ``GuzzleHttp\RequestOptions::CERT`` - -.. code-block:: php - - $client->request('GET', '/', ['cert' => ['/path/server.pem', 'password']]); - - -.. _cookies-option: - -cookies -------- - -:Summary: Specifies whether or not cookies are used in a request or what cookie - jar to use or what cookies to send. -:Types: ``GuzzleHttp\Cookie\CookieJarInterface`` -:Default: None -:Constant: ``GuzzleHttp\RequestOptions::COOKIES`` - -You must specify the cookies option as a -``GuzzleHttp\Cookie\CookieJarInterface`` or ``false``. - -.. code-block:: php - - $jar = new \GuzzleHttp\Cookie\CookieJar(); - $client->request('GET', '/get', ['cookies' => $jar]); - -.. warning:: - - This option only has an effect if your handler has the - ``GuzzleHttp\Middleware::cookies`` middleware. This middleware is added - by default when a client is created with no handler, and is added by - default when creating a handler with ``GuzzleHttp\default_handler``. - -.. tip:: - - When creating a client, you can set the default cookie option to ``true`` - to use a shared cookie session associated with the client. - - -.. _connect_timeout-option: - -connect_timeout ---------------- - -:Summary: Float describing the number of seconds to wait while trying to connect - to a server. Use ``0`` to wait indefinitely (the default behavior). -:Types: float -:Default: ``0`` -:Constant: ``GuzzleHttp\RequestOptions::CONNECT_TIMEOUT`` - -.. code-block:: php - - // Timeout if the client fails to connect to the server in 3.14 seconds. - $client->request('GET', '/delay/5', ['connect_timeout' => 3.14]); - -.. note:: - - This setting must be supported by the HTTP handler used to send a request. - ``connect_timeout`` is currently only supported by the built-in cURL - handler. - - -.. _debug-option: - -debug ------ - -:Summary: Set to ``true`` or set to a PHP stream returned by ``fopen()`` to - enable debug output with the handler used to send a request. For example, - when using cURL to transfer requests, cURL's verbose of ``CURLOPT_VERBOSE`` - will be emitted. When using the PHP stream wrapper, stream wrapper - notifications will be emitted. If set to true, the output is written to - PHP's STDOUT. If a PHP stream is provided, output is written to the stream. -:Types: - - bool - - ``fopen()`` resource -:Default: None -:Constant: ``GuzzleHttp\RequestOptions::DEBUG`` - -.. code-block:: php - - $client->request('GET', '/get', ['debug' => true]); - -Running the above example would output something like the following: - -:: - - * About to connect() to httpbin.org port 80 (#0) - * Trying 107.21.213.98... * Connected to httpbin.org (107.21.213.98) port 80 (#0) - > GET /get HTTP/1.1 - Host: httpbin.org - User-Agent: Guzzle/4.0 curl/7.21.4 PHP/5.5.7 - - < HTTP/1.1 200 OK - < Access-Control-Allow-Origin: * - < Content-Type: application/json - < Date: Sun, 16 Feb 2014 06:50:09 GMT - < Server: gunicorn/0.17.4 - < Content-Length: 335 - < Connection: keep-alive - < - * Connection #0 to host httpbin.org left intact - - -.. _decode_content-option: - -decode_content --------------- - -:Summary: Specify whether or not ``Content-Encoding`` responses (gzip, - deflate, etc.) are automatically decoded. -:Types: - - string - - bool -:Default: ``true`` -:Constant: ``GuzzleHttp\RequestOptions::DECODE_CONTENT`` - -This option can be used to control how content-encoded response bodies are -handled. By default, ``decode_content`` is set to true, meaning any gzipped -or deflated response will be decoded by Guzzle. - -When set to ``false``, the body of a response is never decoded, meaning the -bytes pass through the handler unchanged. - -.. code-block:: php - - // Request gzipped data, but do not decode it while downloading - $client->request('GET', '/foo.js', [ - 'headers' => ['Accept-Encoding' => 'gzip'], - 'decode_content' => false - ]); - -When set to a string, the bytes of a response are decoded and the string value -provided to the ``decode_content`` option is passed as the ``Accept-Encoding`` -header of the request. - -.. code-block:: php - - // Pass "gzip" as the Accept-Encoding header. - $client->request('GET', '/foo.js', ['decode_content' => 'gzip']); - - -.. _delay-option: - -delay ------ - -:Summary: The number of milliseconds to delay before sending the request. -:Types: - - integer - - float -:Default: null -:Constant: ``GuzzleHttp\RequestOptions::DELAY`` - - -.. _expect-option: - -expect ------- - -:Summary: Controls the behavior of the "Expect: 100-Continue" header. -:Types: - - bool - - integer -:Default: ``1048576`` -:Constant: ``GuzzleHttp\RequestOptions::EXPECT`` - -Set to ``true`` to enable the "Expect: 100-Continue" header for all requests -that sends a body. Set to ``false`` to disable the "Expect: 100-Continue" -header for all requests. Set to a number so that the size of the payload must -be greater than the number in order to send the Expect header. Setting to a -number will send the Expect header for all requests in which the size of the -payload cannot be determined or where the body is not rewindable. - -By default, Guzzle will add the "Expect: 100-Continue" header when the size of -the body of a request is greater than 1 MB and a request is using HTTP/1.1. - -.. note:: - - This option only takes effect when using HTTP/1.1. The HTTP/1.0 and - HTTP/2.0 protocols do not support the "Expect: 100-Continue" header. - Support for handling the "Expect: 100-Continue" workflow must be - implemented by Guzzle HTTP handlers used by a client. - - -force_ip_resolve ----------------- - -:Summary: Set to "v4" if you want the HTTP handlers to use only ipv4 protocol or "v6" for ipv6 protocol. -:Types: string -:Default: null -:Constant: ``GuzzleHttp\RequestOptions::FORCE_IP_RESOLVE`` - -.. code-block:: php - - // Force ipv4 protocol - $client->request('GET', '/foo', ['force_ip_resolve' => 'v4']); - - // Force ipv6 protocol - $client->request('GET', '/foo', ['force_ip_resolve' => 'v6']); - -.. note:: - - This setting must be supported by the HTTP handler used to send a request. - ``force_ip_resolve`` is currently only supported by the built-in cURL - and stream handlers. - - -form_params ------------ - -:Summary: Used to send an `application/x-www-form-urlencoded` POST request. -:Types: array -:Constant: ``GuzzleHttp\RequestOptions::FORM_PARAMS`` - -Associative array of form field names to values where each value is a string or -array of strings. Sets the Content-Type header to -application/x-www-form-urlencoded when no Content-Type header is already -present. - -.. code-block:: php - - $client->request('POST', '/post', [ - 'form_params' => [ - 'foo' => 'bar', - 'baz' => ['hi', 'there!'] - ] - ]); - -.. note:: - - ``form_params`` cannot be used with the ``multipart`` option. You will need to use - one or the other. Use ``form_params`` for ``application/x-www-form-urlencoded`` - requests, and ``multipart`` for ``multipart/form-data`` requests. - - This option cannot be used with ``body``, ``multipart``, or ``json`` - - -headers -------- - -:Summary: Associative array of headers to add to the request. Each key is the - name of a header, and each value is a string or array of strings - representing the header field values. -:Types: array -:Defaults: None -:Constant: ``GuzzleHttp\RequestOptions::HEADERS`` - -.. code-block:: php - - // Set various headers on a request - $client->request('GET', '/get', [ - 'headers' => [ - 'User-Agent' => 'testing/1.0', - 'Accept' => 'application/json', - 'X-Foo' => ['Bar', 'Baz'] - ] - ]); - -Headers may be added as default options when creating a client. When headers -are used as default options, they are only applied if the request being created -does not already contain the specific header. This includes both requests passed -to the client in the ``send()`` and ``sendAsync()`` methods, and requests -created by the client (e.g., ``request()`` and ``requestAsync()``). - -.. code-block:: php - - $client = new GuzzleHttp\Client(['headers' => ['X-Foo' => 'Bar']]); - - // Will send a request with the X-Foo header. - $client->request('GET', '/get'); - - // Sets the X-Foo header to "test", which prevents the default header - // from being applied. - $client->request('GET', '/get', ['headers' => ['X-Foo' => 'test']]); - - // Will disable adding in default headers. - $client->request('GET', '/get', ['headers' => null]); - - // Will not overwrite the X-Foo header because it is in the message. - use GuzzleHttp\Psr7\Request; - $request = new Request('GET', 'http://foo.com', ['X-Foo' => 'test']); - $client->send($request); - - // Will overwrite the X-Foo header with the request option provided in the - // send method. - use GuzzleHttp\Psr7\Request; - $request = new Request('GET', 'http://foo.com', ['X-Foo' => 'test']); - $client->send($request, ['headers' => ['X-Foo' => 'overwrite']]); - - -.. _http-errors-option: - -http_errors ------------ - -:Summary: Set to ``false`` to disable throwing exceptions on an HTTP protocol - errors (i.e., 4xx and 5xx responses). Exceptions are thrown by default when - HTTP protocol errors are encountered. -:Types: bool -:Default: ``true`` -:Constant: ``GuzzleHttp\RequestOptions::HTTP_ERRORS`` - -.. code-block:: php - - $client->request('GET', '/status/500'); - // Throws a GuzzleHttp\Exception\ServerException - - $res = $client->request('GET', '/status/500', ['http_errors' => false]); - echo $res->getStatusCode(); - // 500 - -.. warning:: - - This option only has an effect if your handler has the - ``GuzzleHttp\Middleware::httpErrors`` middleware. This middleware is added - by default when a client is created with no handler, and is added by - default when creating a handler with ``GuzzleHttp\default_handler``. - - -idn_conversion --------------- - -:Summary: Internationalized Domain Name (IDN) support (enabled by default if - ``intl`` extension is available). -:Types: - - bool - - int -:Default: ``true`` if ``intl`` extension is available (and ICU library is 4.6+ for PHP 7.2+), ``false`` otherwise -:Constant: ``GuzzleHttp\RequestOptions::IDN_CONVERSION`` - -.. code-block:: php - - $client->request('GET', 'https://яндекс.рф'); - // яндекс.рф is translated to xn--d1acpjx3f.xn--p1ai before passing it to the handler - - $res = $client->request('GET', 'https://яндекс.рф', ['idn_conversion' => false]); - // The domain part (яндекс.рф) stays unmodified - -Enables/disables IDN support, can also be used for precise control by combining -IDNA_* constants (except IDNA_ERROR_*), see ``$options`` parameter in -`idn_to_ascii() `_ -documentation for more details. - - -json ----- - -:Summary: The ``json`` option is used to easily upload JSON encoded data as the - body of a request. A Content-Type header of ``application/json`` will be - added if no Content-Type header is already present on the message. -:Types: - Any PHP type that can be operated on by PHP's ``json_encode()`` function. -:Default: None -:Constant: ``GuzzleHttp\RequestOptions::JSON`` - -.. code-block:: php - - $response = $client->request('PUT', '/put', ['json' => ['foo' => 'bar']]); - -Here's an example of using the ``tap`` middleware to see what request is sent -over the wire. - -.. code-block:: php - - use GuzzleHttp\Middleware; - - // Grab the client's handler instance. - $clientHandler = $client->getConfig('handler'); - // Create a middleware that echoes parts of the request. - $tapMiddleware = Middleware::tap(function ($request) { - echo $request->getHeaderLine('Content-Type'); - // application/json - echo $request->getBody(); - // {"foo":"bar"} - }); - - $response = $client->request('PUT', '/put', [ - 'json' => ['foo' => 'bar'], - 'handler' => $tapMiddleware($clientHandler) - ]); - -.. note:: - - This request option does not support customizing the Content-Type header - or any of the options from PHP's `json_encode() `_ - function. If you need to customize these settings, then you must pass the - JSON encoded data into the request yourself using the ``body`` request - option and you must specify the correct Content-Type header using the - ``headers`` request option. - - This option cannot be used with ``body``, ``form_params``, or ``multipart`` - - -multipart ---------- - -:Summary: Sets the body of the request to a `multipart/form-data` form. -:Types: array -:Constant: ``GuzzleHttp\RequestOptions::MULTIPART`` - -The value of ``multipart`` is an array of associative arrays, each containing -the following key value pairs: - -- ``name``: (string, required) the form field name -- ``contents``: (StreamInterface/resource/string, required) The data to use in - the form element. -- ``headers``: (array) Optional associative array of custom headers to use with - the form element. -- ``filename``: (string) Optional string to send as the filename in the part. - -.. code-block:: php - - $client->request('POST', '/post', [ - 'multipart' => [ - [ - 'name' => 'foo', - 'contents' => 'data', - 'headers' => ['X-Baz' => 'bar'] - ], - [ - 'name' => 'baz', - 'contents' => fopen('/path/to/file', 'r') - ], - [ - 'name' => 'qux', - 'contents' => fopen('/path/to/file', 'r'), - 'filename' => 'custom_filename.txt' - ], - ] - ]); - -.. note:: - - ``multipart`` cannot be used with the ``form_params`` option. You will need to - use one or the other. Use ``form_params`` for ``application/x-www-form-urlencoded`` - requests, and ``multipart`` for ``multipart/form-data`` requests. - - This option cannot be used with ``body``, ``form_params``, or ``json`` - - -.. _on-headers: - -on_headers ----------- - -:Summary: A callable that is invoked when the HTTP headers of the response have - been received but the body has not yet begun to download. -:Types: - callable -:Constant: ``GuzzleHttp\RequestOptions::ON_HEADERS`` - -The callable accepts a ``Psr\Http\ResponseInterface`` object. If an exception -is thrown by the callable, then the promise associated with the response will -be rejected with a ``GuzzleHttp\Exception\RequestException`` that wraps the -exception that was thrown. - -You may need to know what headers and status codes were received before data -can be written to the sink. - -.. code-block:: php - - // Reject responses that are greater than 1024 bytes. - $client->request('GET', 'http://httpbin.org/stream/1024', [ - 'on_headers' => function (ResponseInterface $response) { - if ($response->getHeaderLine('Content-Length') > 1024) { - throw new \Exception('The file is too big!'); - } - } - ]); - -.. note:: - - When writing HTTP handlers, the ``on_headers`` function must be invoked - before writing data to the body of the response. - - -.. _on_stats: - -on_stats --------- - -:Summary: ``on_stats`` allows you to get access to transfer statistics of a - request and access the lower level transfer details of the handler - associated with your client. ``on_stats`` is a callable that is invoked - when a handler has finished sending a request. The callback is invoked - with transfer statistics about the request, the response received, or the - error encountered. Included in the data is the total amount of time taken - to send the request. -:Types: - callable -:Constant: ``GuzzleHttp\RequestOptions::ON_STATS`` - -The callable accepts a ``GuzzleHttp\TransferStats`` object. - -.. code-block:: php - - use GuzzleHttp\TransferStats; - - $client = new GuzzleHttp\Client(); - - $client->request('GET', 'http://httpbin.org/stream/1024', [ - 'on_stats' => function (TransferStats $stats) { - echo $stats->getEffectiveUri() . "\n"; - echo $stats->getTransferTime() . "\n"; - var_dump($stats->getHandlerStats()); - - // You must check if a response was received before using the - // response object. - if ($stats->hasResponse()) { - echo $stats->getResponse()->getStatusCode(); - } else { - // Error data is handler specific. You will need to know what - // type of error data your handler uses before using this - // value. - var_dump($stats->getHandlerErrorData()); - } - } - ]); - - -progress --------- - -:Summary: Defines a function to invoke when transfer progress is made. -:Types: - callable -:Default: None -:Constant: ``GuzzleHttp\RequestOptions::PROGRESS`` - -The function accepts the following positional arguments: - -- the total number of bytes expected to be downloaded, zero if unknown -- the number of bytes downloaded so far -- the total number of bytes expected to be uploaded -- the number of bytes uploaded so far - -.. code-block:: php - - // Send a GET request to /get?foo=bar - $result = $client->request( - 'GET', - '/', - [ - 'progress' => function( - $downloadTotal, - $downloadedBytes, - $uploadTotal, - $uploadedBytes - ) { - //do something - }, - ] - ); - - -.. _proxy-option: - -proxy ------ - -:Summary: Pass a string to specify an HTTP proxy, or an array to specify - different proxies for different protocols. -:Types: - - string - - array -:Default: None -:Constant: ``GuzzleHttp\RequestOptions::PROXY`` - -Pass a string to specify a proxy for all protocols. - -.. code-block:: php - - $client->request('GET', '/', ['proxy' => 'tcp://localhost:8125']); - -Pass an associative array to specify HTTP proxies for specific URI schemes -(i.e., "http", "https"). Provide a ``no`` key value pair to provide a list of -host names that should not be proxied to. - -.. note:: - - Guzzle will automatically populate this value with your environment's - ``NO_PROXY`` environment variable. However, when providing a ``proxy`` - request option, it is up to you to provide the ``no`` value parsed from - the ``NO_PROXY`` environment variable - (e.g., ``explode(',', getenv('NO_PROXY'))``). - -.. code-block:: php - - $client->request('GET', '/', [ - 'proxy' => [ - 'http' => 'tcp://localhost:8125', // Use this proxy with "http" - 'https' => 'tcp://localhost:9124', // Use this proxy with "https", - 'no' => ['.mit.edu', 'foo.com'] // Don't use a proxy with these - ] - ]); - -.. note:: - - You can provide proxy URLs that contain a scheme, username, and password. - For example, ``"http://username:password@192.168.16.1:10"``. - - -query ------ - -:Summary: Associative array of query string values or query string to add to - the request. -:Types: - - array - - string -:Default: None -:Constant: ``GuzzleHttp\RequestOptions::QUERY`` - -.. code-block:: php - - // Send a GET request to /get?foo=bar - $client->request('GET', '/get', ['query' => ['foo' => 'bar']]); - -Query strings specified in the ``query`` option will overwrite all query string -values supplied in the URI of a request. - -.. code-block:: php - - // Send a GET request to /get?foo=bar - $client->request('GET', '/get?abc=123', ['query' => ['foo' => 'bar']]); - -read_timeout ------------- - -:Summary: Float describing the timeout to use when reading a streamed body -:Types: float -:Default: Defaults to the value of the ``default_socket_timeout`` PHP ini setting -:Constant: ``GuzzleHttp\RequestOptions::READ_TIMEOUT`` - -The timeout applies to individual read operations on a streamed body (when the ``stream`` option is enabled). - -.. code-block:: php - - $response = $client->request('GET', '/stream', [ - 'stream' => true, - 'read_timeout' => 10, - ]); - - $body = $response->getBody(); - - // Returns false on timeout - $data = $body->read(1024); - - // Returns false on timeout - $line = fgets($body->detach()); - -.. _sink-option: - -sink ----- - -:Summary: Specify where the body of a response will be saved. -:Types: - - string (path to file on disk) - - ``fopen()`` resource - - ``Psr\Http\Message\StreamInterface`` - -:Default: PHP temp stream -:Constant: ``GuzzleHttp\RequestOptions::SINK`` - -Pass a string to specify the path to a file that will store the contents of the -response body: - -.. code-block:: php - - $client->request('GET', '/stream/20', ['sink' => '/path/to/file']); - -Pass a resource returned from ``fopen()`` to write the response to a PHP stream: - -.. code-block:: php - - $resource = fopen('/path/to/file', 'w'); - $client->request('GET', '/stream/20', ['sink' => $resource]); - -Pass a ``Psr\Http\Message\StreamInterface`` object to stream the response -body to an open PSR-7 stream. - -.. code-block:: php - - $resource = fopen('/path/to/file', 'w'); - $stream = GuzzleHttp\Psr7\stream_for($resource); - $client->request('GET', '/stream/20', ['save_to' => $stream]); - -.. note:: - - The ``save_to`` request option has been deprecated in favor of the - ``sink`` request option. Providing the ``save_to`` option is now an alias - of ``sink``. - - -.. _ssl_key-option: - -ssl_key -------- - -:Summary: Specify the path to a file containing a private SSL key in PEM - format. If a password is required, then set to an array containing the path - to the SSL key in the first array element followed by the password required - for the certificate in the second element. -:Types: - - string - - array -:Default: None -:Constant: ``GuzzleHttp\RequestOptions::SSL_KEY`` - -.. note:: - - ``ssl_key`` is implemented by HTTP handlers. This is currently only - supported by the cURL handler, but might be supported by other third-part - handlers. - - -.. _stream-option: - -stream ------- - -:Summary: Set to ``true`` to stream a response rather than download it all - up-front. -:Types: bool -:Default: ``false`` -:Constant: ``GuzzleHttp\RequestOptions::STREAM`` - -.. code-block:: php - - $response = $client->request('GET', '/stream/20', ['stream' => true]); - // Read bytes off of the stream until the end of the stream is reached - $body = $response->getBody(); - while (!$body->eof()) { - echo $body->read(1024); - } - -.. note:: - - Streaming response support must be implemented by the HTTP handler used by - a client. This option might not be supported by every HTTP handler, but the - interface of the response object remains the same regardless of whether or - not it is supported by the handler. - - -synchronous ------------ - -:Summary: Set to true to inform HTTP handlers that you intend on waiting on the - response. This can be useful for optimizations. -:Types: bool -:Default: none -:Constant: ``GuzzleHttp\RequestOptions::SYNCHRONOUS`` - - -.. _verify-option: - -verify ------- - -:Summary: Describes the SSL certificate verification behavior of a request. - - - Set to ``true`` to enable SSL certificate verification and use the default - CA bundle provided by operating system. - - Set to ``false`` to disable certificate verification (this is insecure!). - - Set to a string to provide the path to a CA bundle to enable verification - using a custom certificate. -:Types: - - bool - - string -:Default: ``true`` -:Constant: ``GuzzleHttp\RequestOptions::VERIFY`` - -.. code-block:: php - - // Use the system's CA bundle (this is the default setting) - $client->request('GET', '/', ['verify' => true]); - - // Use a custom SSL certificate on disk. - $client->request('GET', '/', ['verify' => '/path/to/cert.pem']); - - // Disable validation entirely (don't do this!). - $client->request('GET', '/', ['verify' => false]); - -Not all system's have a known CA bundle on disk. For example, Windows and -OS X do not have a single common location for CA bundles. When setting -"verify" to ``true``, Guzzle will do its best to find the most appropriate -CA bundle on your system. When using cURL or the PHP stream wrapper on PHP -versions >= 5.6, this happens by default. When using the PHP stream -wrapper on versions < 5.6, Guzzle tries to find your CA bundle in the -following order: - -1. Check if ``openssl.cafile`` is set in your php.ini file. -2. Check if ``curl.cainfo`` is set in your php.ini file. -3. Check if ``/etc/pki/tls/certs/ca-bundle.crt`` exists (Red Hat, CentOS, - Fedora; provided by the ca-certificates package) -4. Check if ``/etc/ssl/certs/ca-certificates.crt`` exists (Ubuntu, Debian; - provided by the ca-certificates package) -5. Check if ``/usr/local/share/certs/ca-root-nss.crt`` exists (FreeBSD; - provided by the ca_root_nss package) -6. Check if ``/usr/local/etc/openssl/cert.pem`` (OS X; provided by homebrew) -7. Check if ``C:\windows\system32\curl-ca-bundle.crt`` exists (Windows) -8. Check if ``C:\windows\curl-ca-bundle.crt`` exists (Windows) - -The result of this lookup is cached in memory so that subsequent calls -in the same process will return very quickly. However, when sending only -a single request per-process in something like Apache, you should consider -setting the ``openssl.cafile`` environment variable to the path on disk -to the file so that this entire process is skipped. - -If you do not need a specific certificate bundle, then Mozilla provides a -commonly used CA bundle which can be downloaded -`here `_ -(provided by the maintainer of cURL). Once you have a CA bundle available on -disk, you can set the "openssl.cafile" PHP ini setting to point to the path to -the file, allowing you to omit the "verify" request option. Much more detail on -SSL certificates can be found on the -`cURL website `_. - - -.. _timeout-option: - -timeout -------- - -:Summary: Float describing the timeout of the request in seconds. Use ``0`` - to wait indefinitely (the default behavior). -:Types: float -:Default: ``0`` -:Constant: ``GuzzleHttp\RequestOptions::TIMEOUT`` - -.. code-block:: php - - // Timeout if a server does not return a response in 3.14 seconds. - $client->request('GET', '/delay/5', ['timeout' => 3.14]); - // PHP Fatal error: Uncaught exception 'GuzzleHttp\Exception\RequestException' - - -.. _version-option: - -version -------- - -:Summary: Protocol version to use with the request. -:Types: string, float -:Default: ``1.1`` -:Constant: ``GuzzleHttp\RequestOptions::VERSION`` - -.. code-block:: php - - // Force HTTP/1.0 - $request = $client->request('GET', '/get', ['version' => 1.0]); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/requirements.txt b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/requirements.txt deleted file mode 100644 index 06fc8973..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/requirements.txt +++ /dev/null @@ -1,2 +0,0 @@ -Sphinx>=1.3.0,<1.4.0 -guzzle_sphinx_theme>=0.7.0,<0.8.0 diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/testing.rst b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/testing.rst deleted file mode 100644 index 0598a215..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/docs/testing.rst +++ /dev/null @@ -1,196 +0,0 @@ -====================== -Testing Guzzle Clients -====================== - -Guzzle provides several tools that will enable you to easily mock the HTTP -layer without needing to send requests over the internet. - -* Mock handler -* History middleware -* Node.js web server for integration testing - - -Mock Handler -============ - -When testing HTTP clients, you often need to simulate specific scenarios like -returning a successful response, returning an error, or returning specific -responses in a certain order. Because unit tests need to be predictable, easy -to bootstrap, and fast, hitting an actual remote API is a test smell. - -Guzzle provides a mock handler that can be used to fulfill HTTP requests with -a response or exception by shifting return values off of a queue. - -.. code-block:: php - - use GuzzleHttp\Client; - use GuzzleHttp\Handler\MockHandler; - use GuzzleHttp\HandlerStack; - use GuzzleHttp\Psr7\Response; - use GuzzleHttp\Psr7\Request; - use GuzzleHttp\Exception\RequestException; - - // Create a mock and queue two responses. - $mock = new MockHandler([ - new Response(200, ['X-Foo' => 'Bar'], 'Hello, World'), - new Response(202, ['Content-Length' => 0]), - new RequestException('Error Communicating with Server', new Request('GET', 'test')) - ]); - - $handlerStack = HandlerStack::create($mock); - $client = new Client(['handler' => $handlerStack]); - - // The first request is intercepted with the first response. - $response = $client->request('GET', '/'); - echo $response->getStatusCode(); - //> 200 - echo $response->getBody(); - //> Hello, World - // The second request is intercepted with the second response. - echo $client->request('GET', '/')->getStatusCode(); - //> 202 - - // Reset the queue and queue up a new response - $mock->reset(); - $mock->append(new Response(201)); - - // As the mock was reset, the new response is the 201 CREATED, - // instead of the previously queued RequestException - echo $client->request('GET', '/')->getStatusCode(); - //> 201 - - -When no more responses are in the queue and a request is sent, an -``OutOfBoundsException`` is thrown. - -History Middleware -================== - -When using things like the ``Mock`` handler, you often need to know if the -requests you expected to send were sent exactly as you intended. While the mock -handler responds with mocked responses, the history middleware maintains a -history of the requests that were sent by a client. - -.. code-block:: php - - use GuzzleHttp\Client; - use GuzzleHttp\HandlerStack; - use GuzzleHttp\Middleware; - - $container = []; - $history = Middleware::history($container); - - $handlerStack = HandlerStack::create(); - // or $handlerStack = HandlerStack::create($mock); if using the Mock handler. - - // Add the history middleware to the handler stack. - $handlerStack->push($history); - - $client = new Client(['handler' => $handlerStack]); - - $client->request('GET', 'http://httpbin.org/get'); - $client->request('HEAD', 'http://httpbin.org/get'); - - // Count the number of transactions - echo count($container); - //> 2 - - // Iterate over the requests and responses - foreach ($container as $transaction) { - echo $transaction['request']->getMethod(); - //> GET, HEAD - if ($transaction['response']) { - echo $transaction['response']->getStatusCode(); - //> 200, 200 - } elseif ($transaction['error']) { - echo $transaction['error']; - //> exception - } - var_dump($transaction['options']); - //> dumps the request options of the sent request. - } - - -Test Web Server -=============== - -Using mock responses is almost always enough when testing a web service client. -When implementing custom :doc:`HTTP handlers `, you'll -need to send actual HTTP requests in order to sufficiently test the handler. -However, a best practice is to contact a local web server rather than a server -over the internet. - -- Tests are more reliable -- Tests do not require a network connection -- Tests have no external dependencies - - -Using the test server ---------------------- - -.. warning:: - - The following functionality is provided to help developers of Guzzle - develop HTTP handlers. There is no promise of backwards compatibility - when it comes to the node.js test server or the ``GuzzleHttp\Tests\Server`` - class. If you are using the test server or ``Server`` class outside of - guzzlehttp/guzzle, then you will need to configure autoloading and - ensure the web server is started manually. - -.. hint:: - - You almost never need to use this test web server. You should only ever - consider using it when developing HTTP handlers. The test web server - is not necessary for mocking requests. For that, please use the - Mock handler and history middleware. - -Guzzle ships with a node.js test server that receives requests and returns -responses from a queue. The test server exposes a simple API that is used to -enqueue responses and inspect the requests that it has received. - -Any operation on the ``Server`` object will ensure that -the server is running and wait until it is able to receive requests before -returning. - -``GuzzleHttp\Tests\Server`` provides a static interface to the test server. You -can queue an HTTP response or an array of responses by calling -``Server::enqueue()``. This method accepts an array of -``Psr\Http\Message\ResponseInterface`` and ``Exception`` objects. - -.. code-block:: php - - use GuzzleHttp\Client; - use GuzzleHttp\Psr7\Response; - use GuzzleHttp\Tests\Server; - - // Start the server and queue a response - Server::enqueue([ - new Response(200, ['Content-Length' => 0]) - ]); - - $client = new Client(['base_uri' => Server::$url]); - echo $client->request('GET', '/foo')->getStatusCode(); - // 200 - -When a response is queued on the test server, the test server will remove any -previously queued responses. As the server receives requests, queued responses -are dequeued and returned to the request. When the queue is empty, the server -will return a 500 response. - -You can inspect the requests that the server has retrieved by calling -``Server::received()``. - -.. code-block:: php - - foreach (Server::received() as $response) { - echo $response->getStatusCode(); - } - -You can clear the list of received requests from the web server using the -``Server::flush()`` method. - -.. code-block:: php - - Server::flush(); - echo count(Server::received()); - // 0 diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/phpstan-baseline.neon b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/phpstan-baseline.neon deleted file mode 100644 index 6f81f285..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/phpstan-baseline.neon +++ /dev/null @@ -1,1352 +0,0 @@ -parameters: - ignoreErrors: - - - message: "#^Property GuzzleHttp\\\\Client\\:\\:\\$config type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Method GuzzleHttp\\\\Client\\:\\:__construct\\(\\) has parameter \\$config with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Method GuzzleHttp\\\\Client\\:\\:__call\\(\\) has parameter \\$args with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Method GuzzleHttp\\\\Client\\:\\:__call\\(\\) should return GuzzleHttp\\\\Promise\\\\PromiseInterface but returns GuzzleHttp\\\\Promise\\\\PromiseInterface\\|Psr\\\\Http\\\\Message\\\\ResponseInterface\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Method GuzzleHttp\\\\Client\\:\\:sendAsync\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Method GuzzleHttp\\\\Client\\:\\:send\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Method GuzzleHttp\\\\Client\\:\\:requestAsync\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Method GuzzleHttp\\\\Client\\:\\:request\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Method GuzzleHttp\\\\Client\\:\\:buildUri\\(\\) has parameter \\$config with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Method GuzzleHttp\\\\Client\\:\\:configureDefaults\\(\\) has parameter \\$config with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Parameter \\#1 \\$str of function strtolower expects string, int\\|string given\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Method GuzzleHttp\\\\Client\\:\\:prepareDefaults\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Method GuzzleHttp\\\\Client\\:\\:prepareDefaults\\(\\) return type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Method GuzzleHttp\\\\Client\\:\\:transfer\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Method GuzzleHttp\\\\Client\\:\\:applyOptions\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Parameter \\#2 \\$prefix of function http_build_query expects string, null given\\.$#" - count: 1 - path: src/Client.php - - - - message: "#^Method GuzzleHttp\\\\ClientInterface\\:\\:send\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/ClientInterface.php - - - - message: "#^Method GuzzleHttp\\\\ClientInterface\\:\\:sendAsync\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/ClientInterface.php - - - - message: "#^Method GuzzleHttp\\\\ClientInterface\\:\\:request\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/ClientInterface.php - - - - message: "#^Method GuzzleHttp\\\\ClientInterface\\:\\:requestAsync\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/ClientInterface.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJar\\:\\:__construct\\(\\) has parameter \\$cookieArray with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJar\\:\\:fromArray\\(\\) has parameter \\$cookies with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJar\\:\\:fromArray\\(\\) return type has no value type specified in iterable type GuzzleHttp\\\\Cookie\\\\CookieJar\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJar\\:\\:getCookieValue\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJar\\:\\:getCookieValue\\(\\) has parameter \\$value with no typehint specified\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Result of \\|\\| is always false\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Strict comparison using \\=\\=\\= between string and null will always evaluate to false\\.$#" - count: 2 - path: src/Cookie/CookieJar.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJar\\:\\:toArray\\(\\) return type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Call to an undefined method Traversable\\\\:\\:getArrayCopy\\(\\)\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJar\\:\\:clear\\(\\) return type has no value type specified in iterable type GuzzleHttp\\\\Cookie\\\\CookieJarInterface\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJar\\:\\:clear\\(\\) should return GuzzleHttp\\\\Cookie\\\\CookieJarInterface but return statement is missing\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJar\\:\\:clear\\(\\) should return GuzzleHttp\\\\Cookie\\\\CookieJarInterface but empty return statement found\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJar\\:\\:clearSessionCookies\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJar\\:\\:getIterator\\(\\) return type has no value type specified in iterable type Traversable\\\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJar\\:\\:extractCookies\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Parameter \\#3 \\$length of function substr expects int, int\\|false given\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJar\\:\\:removeCookieIfEmpty\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/CookieJar.php - - - - message: "#^Interface GuzzleHttp\\\\Cookie\\\\CookieJarInterface extends generic interface IteratorAggregate but does not specify its types\\: TKey, TValue$#" - count: 1 - path: src/Cookie/CookieJarInterface.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJarInterface\\:\\:extractCookies\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/CookieJarInterface.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJarInterface\\:\\:clear\\(\\) return type has no value type specified in iterable type GuzzleHttp\\\\Cookie\\\\CookieJarInterface\\.$#" - count: 1 - path: src/Cookie/CookieJarInterface.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJarInterface\\:\\:clearSessionCookies\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/CookieJarInterface.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\CookieJarInterface\\:\\:toArray\\(\\) return type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/Cookie/CookieJarInterface.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\FileCookieJar\\:\\:save\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/FileCookieJar.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\FileCookieJar\\:\\:load\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/FileCookieJar.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\SessionCookieJar\\:\\:save\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/SessionCookieJar.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\SessionCookieJar\\:\\:load\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/SessionCookieJar.php - - - - message: "#^Property GuzzleHttp\\\\Cookie\\\\SetCookie\\:\\:\\$defaults type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Property GuzzleHttp\\\\Cookie\\\\SetCookie\\:\\:\\$data type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\SetCookie\\:\\:__construct\\(\\) has parameter \\$data with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Parameter \\#1 \\$timestamp of method GuzzleHttp\\\\Cookie\\\\SetCookie\\:\\:setExpires\\(\\) expects int, mixed given\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\SetCookie\\:\\:toArray\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\SetCookie\\:\\:setName\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\SetCookie\\:\\:setValue\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\SetCookie\\:\\:setDomain\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\SetCookie\\:\\:setPath\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\SetCookie\\:\\:setMaxAge\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\SetCookie\\:\\:setExpires\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Else branch is unreachable because ternary operator condition is always true\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\SetCookie\\:\\:setSecure\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\SetCookie\\:\\:setDiscard\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Method GuzzleHttp\\\\Cookie\\\\SetCookie\\:\\:setHttpOnly\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Parameter \\#1 \\$str of function ltrim expects string, string\\|null given\\.$#" - count: 1 - path: src/Cookie/SetCookie.php - - - - message: "#^Method GuzzleHttp\\\\Exception\\\\BadResponseException\\:\\:__construct\\(\\) has parameter \\$handlerContext with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Exception/BadResponseException.php - - - - message: "#^Method GuzzleHttp\\\\Exception\\\\ConnectException\\:\\:__construct\\(\\) has parameter \\$handlerContext with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Exception/ConnectException.php - - - - message: "#^Property GuzzleHttp\\\\Exception\\\\RequestException\\:\\:\\$handlerContext type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/Exception/RequestException.php - - - - message: "#^Method GuzzleHttp\\\\Exception\\\\RequestException\\:\\:__construct\\(\\) has parameter \\$handlerContext with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Exception/RequestException.php - - - - message: "#^Method GuzzleHttp\\\\Exception\\\\RequestException\\:\\:create\\(\\) has parameter \\$ctx with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Exception/RequestException.php - - - - message: "#^Method GuzzleHttp\\\\Exception\\\\RequestException\\:\\:getHandlerContext\\(\\) return type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/Exception/RequestException.php - - - - message: "#^Property GuzzleHttp\\\\Exception\\\\SeekException\\:\\:\\$stream has no typehint specified\\.$#" - count: 1 - path: src/Exception/SeekException.php - - - - message: "#^Method GuzzleHttp\\\\Exception\\\\SeekException\\:\\:__construct\\(\\) has parameter \\$msg with no typehint specified\\.$#" - count: 1 - path: src/Exception/SeekException.php - - - - message: "#^Method GuzzleHttp\\\\Exception\\\\SeekException\\:\\:__construct\\(\\) has parameter \\$pos with no typehint specified\\.$#" - count: 1 - path: src/Exception/SeekException.php - - - - message: "#^Property GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:\\$handles type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:create\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:release\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Negated boolean expression is always false\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:invokeStats\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:finishError\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:createRejection\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:createRejection\\(\\) has parameter \\$ctx with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^If condition is always true\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Unreachable statement \\- code above always terminates\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:getDefaultConf\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:applyMethod\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:applyMethod\\(\\) has parameter \\$conf with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:applyBody\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:applyBody\\(\\) has parameter \\$conf with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:applyBody\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:applyHeaders\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:applyHeaders\\(\\) has parameter \\$conf with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:removeHeader\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:removeHeader\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Parameter \\#1 \\$str1 of function strcasecmp expects string, int\\|string given\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:applyHandlerOptions\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:applyHandlerOptions\\(\\) has parameter \\$conf with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Parameter \\#1 \\$filename of function is_dir expects string, string\\|false given\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:retryFailedRewind\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:retryFailedRewind\\(\\) has parameter \\$ctx with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactory\\:\\:createHeaderFn\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlFactory.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactoryInterface\\:\\:create\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlFactoryInterface.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlFactoryInterface\\:\\:release\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlFactoryInterface.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlHandler\\:\\:__construct\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlHandler\\:\\:__invoke\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlHandler\\:\\:__invoke\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlHandler.php - - - - message: "#^Property GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:\\$selectTimeout has no typehint specified\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Property GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:\\$active has no typehint specified\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Property GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:\\$handles has no typehint specified\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Property GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:\\$delays has no typehint specified\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Property GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:\\$options has no typehint specified\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:__construct\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:__get\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:__get\\(\\) has parameter \\$name with no typehint specified\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Property GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:\\$_mh \\(resource\\) does not accept resource\\|false\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Parameter \\#1 \\$mh of function curl_multi_setopt expects resource, resource\\|false given\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:__invoke\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:__invoke\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:tick\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:execute\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:addRequest\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:addRequest\\(\\) has parameter \\$entry with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:processMessages\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\CurlMultiHandler\\:\\:timeToNext\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/CurlMultiHandler.php - - - - message: "#^Property GuzzleHttp\\\\Handler\\\\EasyHandle\\:\\:\\$headers type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/EasyHandle.php - - - - message: "#^Property GuzzleHttp\\\\Handler\\\\EasyHandle\\:\\:\\$options type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/EasyHandle.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\EasyHandle\\:\\:createResponse\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/EasyHandle.php - - - - message: "#^Parameter \\#1 \\$status of class GuzzleHttp\\\\Psr7\\\\Response constructor expects int, string given\\.$#" - count: 1 - path: src/Handler/EasyHandle.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\EasyHandle\\:\\:__get\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/EasyHandle.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\EasyHandle\\:\\:__get\\(\\) has parameter \\$name with no typehint specified\\.$#" - count: 1 - path: src/Handler/EasyHandle.php - - - - message: "#^Property GuzzleHttp\\\\Handler\\\\MockHandler\\:\\:\\$queue has no typehint specified\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Property GuzzleHttp\\\\Handler\\\\MockHandler\\:\\:\\$lastRequest has no typehint specified\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Property GuzzleHttp\\\\Handler\\\\MockHandler\\:\\:\\$lastOptions has no typehint specified\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Property GuzzleHttp\\\\Handler\\\\MockHandler\\:\\:\\$onFulfilled has no typehint specified\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Property GuzzleHttp\\\\Handler\\\\MockHandler\\:\\:\\$onRejected has no typehint specified\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\MockHandler\\:\\:createWithMiddleware\\(\\) has parameter \\$queue with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\MockHandler\\:\\:__construct\\(\\) has parameter \\$queue with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Parameter \\#2 \\$parameters of function call_user_func_array expects array\\, array given\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\MockHandler\\:\\:__invoke\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\MockHandler\\:\\:__invoke\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Binary operation \"\\*\" between float\\|int\\|string and 1000 results in an error\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\MockHandler\\:\\:append\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\MockHandler\\:\\:getLastOptions\\(\\) return type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\MockHandler\\:\\:reset\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\MockHandler\\:\\:invokeStats\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\MockHandler\\:\\:invokeStats\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\MockHandler\\:\\:invokeStats\\(\\) has parameter \\$reason with no typehint specified\\.$#" - count: 1 - path: src/Handler/MockHandler.php - - - - message: "#^Property GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:\\$lastHeaders has no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:__invoke\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:invokeStats\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:invokeStats\\(\\) has parameter \\$error with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:invokeStats\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:invokeStats\\(\\) has parameter \\$startTime with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:createResponse\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:createResponse\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:createResponse\\(\\) has parameter \\$startTime with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:createResponse\\(\\) has parameter \\$stream with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Parameter \\#1 \\$status of class GuzzleHttp\\\\Psr7\\\\Response constructor expects int, string given\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:createSink\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:createSink\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:checkDecode\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:checkDecode\\(\\) has parameter \\$headers with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:checkDecode\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:checkDecode\\(\\) has parameter \\$stream with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Argument of an invalid type array\\\\>\\|null supplied for foreach, only iterables are supported\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:createStream\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:createStream\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Parameter \\#3 \\$use_include_path of function fopen expects bool, null given\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Parameter \\#1 \\$stream of function stream_set_timeout expects resource, resource\\|false given\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:resolveHost\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:resolveHost\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Cannot access offset 0 on array\\|false\\.$#" - count: 2 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:getDefaultContext\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_proxy\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_proxy\\(\\) has parameter \\$options with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_proxy\\(\\) has parameter \\$params with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_proxy\\(\\) has parameter \\$value with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_timeout\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_timeout\\(\\) has parameter \\$options with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_timeout\\(\\) has parameter \\$params with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_timeout\\(\\) has parameter \\$value with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_verify\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_verify\\(\\) has parameter \\$options with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_verify\\(\\) has parameter \\$params with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_verify\\(\\) has parameter \\$value with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_cert\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_cert\\(\\) has parameter \\$options with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_cert\\(\\) has parameter \\$params with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_cert\\(\\) has parameter \\$value with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_progress\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_progress\\(\\) has parameter \\$options with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_progress\\(\\) has parameter \\$params with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_progress\\(\\) has parameter \\$value with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_debug\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_debug\\(\\) has parameter \\$options with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_debug\\(\\) has parameter \\$params with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:add_debug\\(\\) has parameter \\$value with no typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:addNotification\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:addNotification\\(\\) has parameter \\$params with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:callArray\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Method GuzzleHttp\\\\Handler\\\\StreamHandler\\:\\:callArray\\(\\) has parameter \\$functions with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Handler/StreamHandler.php - - - - message: "#^Property GuzzleHttp\\\\HandlerStack\\:\\:\\$stack type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/HandlerStack.php - - - - message: "#^Method GuzzleHttp\\\\HandlerStack\\:\\:__invoke\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/HandlerStack.php - - - - message: "#^Method GuzzleHttp\\\\HandlerStack\\:\\:setHandler\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/HandlerStack.php - - - - message: "#^Method GuzzleHttp\\\\HandlerStack\\:\\:unshift\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/HandlerStack.php - - - - message: "#^Method GuzzleHttp\\\\HandlerStack\\:\\:push\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/HandlerStack.php - - - - message: "#^Method GuzzleHttp\\\\HandlerStack\\:\\:before\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/HandlerStack.php - - - - message: "#^Method GuzzleHttp\\\\HandlerStack\\:\\:after\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/HandlerStack.php - - - - message: "#^Method GuzzleHttp\\\\HandlerStack\\:\\:remove\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/HandlerStack.php - - - - message: "#^Method GuzzleHttp\\\\HandlerStack\\:\\:splice\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/HandlerStack.php - - - - message: "#^Method GuzzleHttp\\\\HandlerStack\\:\\:debugCallable\\(\\) has parameter \\$fn with no value type specified in iterable type array\\.$#" - count: 1 - path: src/HandlerStack.php - - - - message: "#^Parameter \\#1 \\$obj of function spl_object_hash expects object, callable given\\.$#" - count: 1 - path: src/HandlerStack.php - - - - message: "#^Method GuzzleHttp\\\\MessageFormatter\\:\\:format\\(\\) should return string but returns string\\|null\\.$#" - count: 1 - path: src/MessageFormatter.php - - - - message: "#^Method GuzzleHttp\\\\Middleware\\:\\:history\\(\\) has parameter \\$container with generic interface ArrayAccess but does not specify its types\\: TKey, TValue$#" - count: 1 - path: src/Middleware.php - - - - message: "#^Method GuzzleHttp\\\\Middleware\\:\\:history\\(\\) has parameter \\$container with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Middleware.php - - - - message: "#^Result of && is always false\\.$#" - count: 1 - path: src/Middleware.php - - - - message: "#^Method GuzzleHttp\\\\Pool\\:\\:__construct\\(\\) has parameter \\$config with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Pool.php - - - - message: "#^Method GuzzleHttp\\\\Pool\\:\\:__construct\\(\\) has parameter \\$requests with no value type specified in iterable type array\\|Iterator\\.$#" - count: 1 - path: src/Pool.php - - - - message: "#^Method GuzzleHttp\\\\Pool\\:\\:batch\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Pool.php - - - - message: "#^Method GuzzleHttp\\\\Pool\\:\\:batch\\(\\) has parameter \\$requests with no value type specified in iterable type array\\|Iterator\\.$#" - count: 1 - path: src/Pool.php - - - - message: "#^Method GuzzleHttp\\\\Pool\\:\\:batch\\(\\) return type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/Pool.php - - - - message: "#^Unsafe usage of new static\\(\\)\\.$#" - count: 1 - path: src/Pool.php - - - - message: "#^Method GuzzleHttp\\\\Pool\\:\\:cmpCallback\\(\\) has parameter \\$name with no typehint specified\\.$#" - count: 1 - path: src/Pool.php - - - - message: "#^Method GuzzleHttp\\\\Pool\\:\\:cmpCallback\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Pool.php - - - - message: "#^Method GuzzleHttp\\\\Pool\\:\\:cmpCallback\\(\\) has parameter \\$results with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Pool.php - - - - message: "#^Method GuzzleHttp\\\\PrepareBodyMiddleware\\:\\:__invoke\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/PrepareBodyMiddleware.php - - - - message: "#^Method GuzzleHttp\\\\PrepareBodyMiddleware\\:\\:addExpectHeader\\(\\) has parameter \\$modify with no value type specified in iterable type array\\.$#" - count: 1 - path: src/PrepareBodyMiddleware.php - - - - message: "#^Method GuzzleHttp\\\\PrepareBodyMiddleware\\:\\:addExpectHeader\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/PrepareBodyMiddleware.php - - - - message: "#^Property GuzzleHttp\\\\RedirectMiddleware\\:\\:\\$defaultSettings has no typehint specified\\.$#" - count: 1 - path: src/RedirectMiddleware.php - - - - message: "#^Method GuzzleHttp\\\\RedirectMiddleware\\:\\:__invoke\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/RedirectMiddleware.php - - - - message: "#^Method GuzzleHttp\\\\RedirectMiddleware\\:\\:checkRedirect\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/RedirectMiddleware.php - - - - message: "#^Parameter \\#1 \\$str of function substr expects string, int given\\.$#" - count: 1 - path: src/RedirectMiddleware.php - - - - message: "#^Parameter \\#1 \\$promise of method GuzzleHttp\\\\RedirectMiddleware\\:\\:withTracking\\(\\) expects GuzzleHttp\\\\Promise\\\\PromiseInterface, GuzzleHttp\\\\Promise\\\\PromiseInterface\\|Psr\\\\Http\\\\Message\\\\ResponseInterface given\\.$#" - count: 1 - path: src/RedirectMiddleware.php - - - - message: "#^Method GuzzleHttp\\\\RedirectMiddleware\\:\\:withTracking\\(\\) has parameter \\$statusCode with no typehint specified\\.$#" - count: 1 - path: src/RedirectMiddleware.php - - - - message: "#^Method GuzzleHttp\\\\RedirectMiddleware\\:\\:withTracking\\(\\) has parameter \\$uri with no typehint specified\\.$#" - count: 1 - path: src/RedirectMiddleware.php - - - - message: "#^Parameter \\#2 \\$value of method Psr\\\\Http\\\\Message\\\\MessageInterface\\:\\:withHeader\\(\\) expects array\\\\|string, array given\\.$#" - count: 2 - path: src/RedirectMiddleware.php - - - - message: "#^Method GuzzleHttp\\\\RedirectMiddleware\\:\\:guardMax\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/RedirectMiddleware.php - - - - message: "#^Method GuzzleHttp\\\\RedirectMiddleware\\:\\:modifyRequest\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/RedirectMiddleware.php - - - - message: "#^Method GuzzleHttp\\\\RedirectMiddleware\\:\\:redirectUri\\(\\) has parameter \\$protocols with no value type specified in iterable type array\\.$#" - count: 1 - path: src/RedirectMiddleware.php - - - - message: "#^Method GuzzleHttp\\\\RetryMiddleware\\:\\:__invoke\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/RetryMiddleware.php - - - - message: "#^Method GuzzleHttp\\\\RetryMiddleware\\:\\:onFulfilled\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/RetryMiddleware.php - - - - message: "#^Method GuzzleHttp\\\\RetryMiddleware\\:\\:onRejected\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/RetryMiddleware.php - - - - message: "#^Method GuzzleHttp\\\\RetryMiddleware\\:\\:doRetry\\(\\) has parameter \\$options with no value type specified in iterable type array\\.$#" - count: 1 - path: src/RetryMiddleware.php - - - - message: "#^Method GuzzleHttp\\\\RetryMiddleware\\:\\:doRetry\\(\\) should return GuzzleHttp\\\\RetryMiddleware but returns GuzzleHttp\\\\Promise\\\\PromiseInterface\\.$#" - count: 1 - path: src/RetryMiddleware.php - - - - message: "#^Property GuzzleHttp\\\\TransferStats\\:\\:\\$request has no typehint specified\\.$#" - count: 1 - path: src/TransferStats.php - - - - message: "#^Property GuzzleHttp\\\\TransferStats\\:\\:\\$response has no typehint specified\\.$#" - count: 1 - path: src/TransferStats.php - - - - message: "#^Property GuzzleHttp\\\\TransferStats\\:\\:\\$transferTime has no typehint specified\\.$#" - count: 1 - path: src/TransferStats.php - - - - message: "#^Property GuzzleHttp\\\\TransferStats\\:\\:\\$handlerStats has no typehint specified\\.$#" - count: 1 - path: src/TransferStats.php - - - - message: "#^Property GuzzleHttp\\\\TransferStats\\:\\:\\$handlerErrorData has no typehint specified\\.$#" - count: 1 - path: src/TransferStats.php - - - - message: "#^Method GuzzleHttp\\\\TransferStats\\:\\:__construct\\(\\) has parameter \\$handlerStats with no value type specified in iterable type array\\.$#" - count: 1 - path: src/TransferStats.php - - - - message: "#^Method GuzzleHttp\\\\TransferStats\\:\\:getHandlerStats\\(\\) return type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/TransferStats.php - - - - message: "#^Property GuzzleHttp\\\\UriTemplate\\:\\:\\$variables type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/UriTemplate.php - - - - message: "#^Property GuzzleHttp\\\\UriTemplate\\:\\:\\$operatorHash type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/UriTemplate.php - - - - message: "#^Property GuzzleHttp\\\\UriTemplate\\:\\:\\$delims type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/UriTemplate.php - - - - message: "#^Property GuzzleHttp\\\\UriTemplate\\:\\:\\$delimsPct type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/UriTemplate.php - - - - message: "#^Method GuzzleHttp\\\\UriTemplate\\:\\:expand\\(\\) has no return typehint specified\\.$#" - count: 1 - path: src/UriTemplate.php - - - - message: "#^Method GuzzleHttp\\\\UriTemplate\\:\\:expand\\(\\) has parameter \\$template with no typehint specified\\.$#" - count: 1 - path: src/UriTemplate.php - - - - message: "#^Method GuzzleHttp\\\\UriTemplate\\:\\:expand\\(\\) has parameter \\$variables with no value type specified in iterable type array\\.$#" - count: 1 - path: src/UriTemplate.php - - - - message: "#^Method GuzzleHttp\\\\UriTemplate\\:\\:parseExpression\\(\\) return type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/UriTemplate.php - - - - message: "#^Method GuzzleHttp\\\\UriTemplate\\:\\:expandMatch\\(\\) has parameter \\$matches with no value type specified in iterable type array\\.$#" - count: 1 - path: src/UriTemplate.php - - - - message: "#^Method GuzzleHttp\\\\UriTemplate\\:\\:isAssoc\\(\\) has parameter \\$array with no value type specified in iterable type array\\.$#" - count: 1 - path: src/UriTemplate.php - - - - message: "#^Method GuzzleHttp\\\\Utils\\:\\:idnToAsci\\(\\) has parameter \\$info with no value type specified in iterable type array\\.$#" - count: 1 - path: src/Utils.php - - - - message: "#^Function GuzzleHttp\\\\uri_template\\(\\) has parameter \\$variables with no value type specified in iterable type array\\.$#" - count: 1 - path: src/functions.php - - - - message: "#^Function uri_template not found\\.$#" - count: 1 - path: src/functions.php - - - - message: "#^Parameter \\#1 \\$str of function rtrim expects string, string\\|false given\\.$#" - count: 1 - path: src/functions.php - - - - message: "#^Function GuzzleHttp\\\\headers_from_lines\\(\\) has parameter \\$lines with no value type specified in iterable type iterable\\.$#" - count: 1 - path: src/functions.php - - - - message: "#^Function GuzzleHttp\\\\headers_from_lines\\(\\) return type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/functions.php - - - - message: "#^Function GuzzleHttp\\\\debug_resource\\(\\) should return resource but returns resource\\|false\\.$#" - count: 1 - path: src/functions.php - - - - message: "#^Function GuzzleHttp\\\\normalize_header_keys\\(\\) has parameter \\$headers with no value type specified in iterable type array\\.$#" - count: 1 - path: src/functions.php - - - - message: "#^Function GuzzleHttp\\\\normalize_header_keys\\(\\) return type has no value type specified in iterable type array\\.$#" - count: 1 - path: src/functions.php - - - - message: "#^Function GuzzleHttp\\\\is_host_in_noproxy\\(\\) has parameter \\$noProxyArray with no value type specified in iterable type array\\.$#" - count: 1 - path: src/functions.php - - - - message: "#^Cannot access offset 0 on array\\\\|false\\.$#" - count: 1 - path: src/functions.php - - - - message: "#^Function GuzzleHttp\\\\json_encode\\(\\) should return string but returns string\\|false\\.$#" - count: 1 - path: src/functions.php - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/phpstan.neon.dist b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/phpstan.neon.dist deleted file mode 100644 index 2d83c984..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/phpstan.neon.dist +++ /dev/null @@ -1,7 +0,0 @@ -includes: - - phpstan-baseline.neon - -parameters: - level: max - paths: - - src diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/phpunit.xml.dist b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/phpunit.xml.dist deleted file mode 100644 index 6316581c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/phpunit.xml.dist +++ /dev/null @@ -1,22 +0,0 @@ - - - - - tests - - - - - src - - src/ - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/ClientTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/ClientTest.php deleted file mode 100644 index 65f09bd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/ClientTest.php +++ /dev/null @@ -1,811 +0,0 @@ - 0])]); - $response = $client->get(Server::$url); - self::assertSame(200, $response->getStatusCode()); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage Magic request methods require a URI and optional options array - */ - public function testValidatesArgsForMagicMethods() - { - $client = new Client(); - $client->get(); - } - - public function testCanSendMagicAsyncRequests() - { - $client = new Client(); - Server::flush(); - Server::enqueue([new Response(200, ['Content-Length' => 2], 'hi')]); - $p = $client->getAsync(Server::$url, ['query' => ['test' => 'foo']]); - self::assertInstanceOf(PromiseInterface::class, $p); - self::assertSame(200, $p->wait()->getStatusCode()); - $received = Server::received(true); - self::assertCount(1, $received); - self::assertSame('test=foo', $received[0]->getUri()->getQuery()); - } - - public function testCanSendSynchronously() - { - $client = new Client(['handler' => new MockHandler([new Response()])]); - $request = new Request('GET', 'http://example.com'); - $r = $client->send($request); - self::assertInstanceOf(ResponseInterface::class, $r); - self::assertSame(200, $r->getStatusCode()); - } - - public function testClientHasOptions() - { - $client = new Client([ - 'base_uri' => 'http://foo.com', - 'timeout' => 2, - 'headers' => ['bar' => 'baz'], - 'handler' => new MockHandler() - ]); - $base = $client->getConfig('base_uri'); - self::assertSame('http://foo.com', (string) $base); - self::assertInstanceOf(Uri::class, $base); - self::assertNotNull($client->getConfig('handler')); - self::assertSame(2, $client->getConfig('timeout')); - self::assertArrayHasKey('timeout', $client->getConfig()); - self::assertArrayHasKey('headers', $client->getConfig()); - } - - public function testCanMergeOnBaseUri() - { - $mock = new MockHandler([new Response()]); - $client = new Client([ - 'base_uri' => 'http://foo.com/bar/', - 'handler' => $mock - ]); - $client->get('baz'); - self::assertSame( - 'http://foo.com/bar/baz', - (string)$mock->getLastRequest()->getUri() - ); - } - - public function testCanMergeOnBaseUriWithRequest() - { - $mock = new MockHandler([new Response(), new Response()]); - $client = new Client([ - 'handler' => $mock, - 'base_uri' => 'http://foo.com/bar/' - ]); - $client->request('GET', new Uri('baz')); - self::assertSame( - 'http://foo.com/bar/baz', - (string) $mock->getLastRequest()->getUri() - ); - - $client->request('GET', new Uri('baz'), ['base_uri' => 'http://example.com/foo/']); - self::assertSame( - 'http://example.com/foo/baz', - (string) $mock->getLastRequest()->getUri(), - 'Can overwrite the base_uri through the request options' - ); - } - - public function testCanUseRelativeUriWithSend() - { - $mock = new MockHandler([new Response()]); - $client = new Client([ - 'handler' => $mock, - 'base_uri' => 'http://bar.com' - ]); - self::assertSame('http://bar.com', (string) $client->getConfig('base_uri')); - $request = new Request('GET', '/baz'); - $client->send($request); - self::assertSame( - 'http://bar.com/baz', - (string) $mock->getLastRequest()->getUri() - ); - } - - public function testMergesDefaultOptionsAndDoesNotOverwriteUa() - { - $c = new Client(['headers' => ['User-agent' => 'foo']]); - self::assertSame(['User-agent' => 'foo'], $c->getConfig('headers')); - self::assertInternalType('array', $c->getConfig('allow_redirects')); - self::assertTrue($c->getConfig('http_errors')); - self::assertTrue($c->getConfig('decode_content')); - self::assertTrue($c->getConfig('verify')); - } - - public function testDoesNotOverwriteHeaderWithDefault() - { - $mock = new MockHandler([new Response()]); - $c = new Client([ - 'headers' => ['User-agent' => 'foo'], - 'handler' => $mock - ]); - $c->get('http://example.com', ['headers' => ['User-Agent' => 'bar']]); - self::assertSame('bar', $mock->getLastRequest()->getHeaderLine('User-Agent')); - } - - public function testDoesNotOverwriteHeaderWithDefaultInRequest() - { - $mock = new MockHandler([new Response()]); - $c = new Client([ - 'headers' => ['User-agent' => 'foo'], - 'handler' => $mock - ]); - $request = new Request('GET', Server::$url, ['User-Agent' => 'bar']); - $c->send($request); - self::assertSame('bar', $mock->getLastRequest()->getHeaderLine('User-Agent')); - } - - public function testDoesOverwriteHeaderWithSetRequestOption() - { - $mock = new MockHandler([new Response()]); - $c = new Client([ - 'headers' => ['User-agent' => 'foo'], - 'handler' => $mock - ]); - $request = new Request('GET', Server::$url, ['User-Agent' => 'bar']); - $c->send($request, ['headers' => ['User-Agent' => 'YO']]); - self::assertSame('YO', $mock->getLastRequest()->getHeaderLine('User-Agent')); - } - - public function testCanUnsetRequestOptionWithNull() - { - $mock = new MockHandler([new Response()]); - $c = new Client([ - 'headers' => ['foo' => 'bar'], - 'handler' => $mock - ]); - $c->get('http://example.com', ['headers' => null]); - self::assertFalse($mock->getLastRequest()->hasHeader('foo')); - } - - public function testRewriteExceptionsToHttpErrors() - { - $client = new Client(['handler' => new MockHandler([new Response(404)])]); - $res = $client->get('http://foo.com', ['exceptions' => false]); - self::assertSame(404, $res->getStatusCode()); - } - - public function testRewriteSaveToToSink() - { - $r = Psr7\stream_for(fopen('php://temp', 'r+')); - $mock = new MockHandler([new Response(200, [], 'foo')]); - $client = new Client(['handler' => $mock]); - $client->get('http://foo.com', ['save_to' => $r]); - self::assertSame($r, $mock->getLastOptions()['sink']); - } - - public function testAllowRedirectsCanBeTrue() - { - $mock = new MockHandler([new Response(200, [], 'foo')]); - $handler = HandlerStack::create($mock); - $client = new Client(['handler' => $handler]); - $client->get('http://foo.com', ['allow_redirects' => true]); - self::assertInternalType('array', $mock->getLastOptions()['allow_redirects']); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage allow_redirects must be true, false, or array - */ - public function testValidatesAllowRedirects() - { - $mock = new MockHandler([new Response(200, [], 'foo')]); - $handler = HandlerStack::create($mock); - $client = new Client(['handler' => $handler]); - $client->get('http://foo.com', ['allow_redirects' => 'foo']); - } - - /** - * @expectedException \GuzzleHttp\Exception\ClientException - */ - public function testThrowsHttpErrorsByDefault() - { - $mock = new MockHandler([new Response(404)]); - $handler = HandlerStack::create($mock); - $client = new Client(['handler' => $handler]); - $client->get('http://foo.com'); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage cookies must be an instance of GuzzleHttp\Cookie\CookieJarInterface - */ - public function testValidatesCookies() - { - $mock = new MockHandler([new Response(200, [], 'foo')]); - $handler = HandlerStack::create($mock); - $client = new Client(['handler' => $handler]); - $client->get('http://foo.com', ['cookies' => 'foo']); - } - - public function testSetCookieToTrueUsesSharedJar() - { - $mock = new MockHandler([ - new Response(200, ['Set-Cookie' => 'foo=bar']), - new Response() - ]); - $handler = HandlerStack::create($mock); - $client = new Client(['handler' => $handler, 'cookies' => true]); - $client->get('http://foo.com'); - $client->get('http://foo.com'); - self::assertSame('foo=bar', $mock->getLastRequest()->getHeaderLine('Cookie')); - } - - public function testSetCookieToJar() - { - $mock = new MockHandler([ - new Response(200, ['Set-Cookie' => 'foo=bar']), - new Response() - ]); - $handler = HandlerStack::create($mock); - $client = new Client(['handler' => $handler]); - $jar = new CookieJar(); - $client->get('http://foo.com', ['cookies' => $jar]); - $client->get('http://foo.com', ['cookies' => $jar]); - self::assertSame('foo=bar', $mock->getLastRequest()->getHeaderLine('Cookie')); - } - - public function testCanDisableContentDecoding() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $client->get('http://foo.com', ['decode_content' => false]); - $last = $mock->getLastRequest(); - self::assertFalse($last->hasHeader('Accept-Encoding')); - self::assertFalse($mock->getLastOptions()['decode_content']); - } - - public function testCanSetContentDecodingToValue() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $client->get('http://foo.com', ['decode_content' => 'gzip']); - $last = $mock->getLastRequest(); - self::assertSame('gzip', $last->getHeaderLine('Accept-Encoding')); - self::assertSame('gzip', $mock->getLastOptions()['decode_content']); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testValidatesHeaders() - { - $mock = new MockHandler(); - $client = new Client(['handler' => $mock]); - $client->get('http://foo.com', ['headers' => 'foo']); - } - - public function testAddsBody() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $request = new Request('PUT', 'http://foo.com'); - $client->send($request, ['body' => 'foo']); - $last = $mock->getLastRequest(); - self::assertSame('foo', (string) $last->getBody()); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testValidatesQuery() - { - $mock = new MockHandler(); - $client = new Client(['handler' => $mock]); - $request = new Request('PUT', 'http://foo.com'); - $client->send($request, ['query' => false]); - } - - public function testQueryCanBeString() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $request = new Request('PUT', 'http://foo.com'); - $client->send($request, ['query' => 'foo']); - self::assertSame('foo', $mock->getLastRequest()->getUri()->getQuery()); - } - - public function testQueryCanBeArray() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $request = new Request('PUT', 'http://foo.com'); - $client->send($request, ['query' => ['foo' => 'bar baz']]); - self::assertSame('foo=bar%20baz', $mock->getLastRequest()->getUri()->getQuery()); - } - - public function testCanAddJsonData() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $request = new Request('PUT', 'http://foo.com'); - $client->send($request, ['json' => ['foo' => 'bar']]); - $last = $mock->getLastRequest(); - self::assertSame('{"foo":"bar"}', (string) $mock->getLastRequest()->getBody()); - self::assertSame('application/json', $last->getHeaderLine('Content-Type')); - } - - public function testCanAddJsonDataWithoutOverwritingContentType() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $request = new Request('PUT', 'http://foo.com'); - $client->send($request, [ - 'headers' => ['content-type' => 'foo'], - 'json' => 'a' - ]); - $last = $mock->getLastRequest(); - self::assertSame('"a"', (string) $mock->getLastRequest()->getBody()); - self::assertSame('foo', $last->getHeaderLine('Content-Type')); - } - - public function testCanAddJsonDataWithNullHeader() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $request = new Request('PUT', 'http://foo.com'); - $client->send($request, [ - 'headers' => null, - 'json' => 'a' - ]); - $last = $mock->getLastRequest(); - self::assertSame('"a"', (string) $mock->getLastRequest()->getBody()); - self::assertSame('application/json', $last->getHeaderLine('Content-Type')); - } - - public function testAuthCanBeTrue() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $client->get('http://foo.com', ['auth' => false]); - $last = $mock->getLastRequest(); - self::assertFalse($last->hasHeader('Authorization')); - } - - public function testAuthCanBeArrayForBasicAuth() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $client->get('http://foo.com', ['auth' => ['a', 'b']]); - $last = $mock->getLastRequest(); - self::assertSame('Basic YTpi', $last->getHeaderLine('Authorization')); - } - - public function testAuthCanBeArrayForDigestAuth() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $client->get('http://foo.com', ['auth' => ['a', 'b', 'digest']]); - $last = $mock->getLastOptions(); - self::assertSame([ - CURLOPT_HTTPAUTH => 2, - CURLOPT_USERPWD => 'a:b' - ], $last['curl']); - } - - public function testAuthCanBeArrayForNtlmAuth() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $client->get('http://foo.com', ['auth' => ['a', 'b', 'ntlm']]); - $last = $mock->getLastOptions(); - self::assertSame([ - CURLOPT_HTTPAUTH => 8, - CURLOPT_USERPWD => 'a:b' - ], $last['curl']); - } - - public function testAuthCanBeCustomType() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $client->get('http://foo.com', ['auth' => 'foo']); - $last = $mock->getLastOptions(); - self::assertSame('foo', $last['auth']); - } - - public function testCanAddFormParams() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $client->post('http://foo.com', [ - 'form_params' => [ - 'foo' => 'bar bam', - 'baz' => ['boo' => 'qux'] - ] - ]); - $last = $mock->getLastRequest(); - self::assertSame( - 'application/x-www-form-urlencoded', - $last->getHeaderLine('Content-Type') - ); - self::assertSame( - 'foo=bar+bam&baz%5Bboo%5D=qux', - (string) $last->getBody() - ); - } - - public function testFormParamsEncodedProperly() - { - $separator = ini_get('arg_separator.output'); - ini_set('arg_separator.output', '&'); - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $client->post('http://foo.com', [ - 'form_params' => [ - 'foo' => 'bar bam', - 'baz' => ['boo' => 'qux'] - ] - ]); - $last = $mock->getLastRequest(); - self::assertSame( - 'foo=bar+bam&baz%5Bboo%5D=qux', - (string) $last->getBody() - ); - - ini_set('arg_separator.output', $separator); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testEnsuresThatFormParamsAndMultipartAreExclusive() - { - $client = new Client(['handler' => function () { - }]); - $client->post('http://foo.com', [ - 'form_params' => ['foo' => 'bar bam'], - 'multipart' => [] - ]); - } - - public function testCanSendMultipart() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $client->post('http://foo.com', [ - 'multipart' => [ - [ - 'name' => 'foo', - 'contents' => 'bar' - ], - [ - 'name' => 'test', - 'contents' => fopen(__FILE__, 'r') - ] - ] - ]); - - $last = $mock->getLastRequest(); - self::assertContains( - 'multipart/form-data; boundary=', - $last->getHeaderLine('Content-Type') - ); - - self::assertContains( - 'Content-Disposition: form-data; name="foo"', - (string) $last->getBody() - ); - - self::assertContains('bar', (string) $last->getBody()); - self::assertContains( - 'Content-Disposition: form-data; name="foo"' . "\r\n", - (string) $last->getBody() - ); - self::assertContains( - 'Content-Disposition: form-data; name="test"; filename="ClientTest.php"', - (string) $last->getBody() - ); - } - - public function testCanSendMultipartWithExplicitBody() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $client->send( - new Request( - 'POST', - 'http://foo.com', - [], - new Psr7\MultipartStream( - [ - [ - 'name' => 'foo', - 'contents' => 'bar', - ], - [ - 'name' => 'test', - 'contents' => fopen(__FILE__, 'r'), - ], - ] - ) - ) - ); - - $last = $mock->getLastRequest(); - self::assertContains( - 'multipart/form-data; boundary=', - $last->getHeaderLine('Content-Type') - ); - - self::assertContains( - 'Content-Disposition: form-data; name="foo"', - (string) $last->getBody() - ); - - self::assertContains('bar', (string) $last->getBody()); - self::assertContains( - 'Content-Disposition: form-data; name="foo"' . "\r\n", - (string) $last->getBody() - ); - self::assertContains( - 'Content-Disposition: form-data; name="test"; filename="ClientTest.php"', - (string) $last->getBody() - ); - } - - public function testUsesProxyEnvironmentVariables() - { - $http = getenv('HTTP_PROXY'); - $https = getenv('HTTPS_PROXY'); - $no = getenv('NO_PROXY'); - $client = new Client(); - self::assertNull($client->getConfig('proxy')); - putenv('HTTP_PROXY=127.0.0.1'); - $client = new Client(); - self::assertSame( - ['http' => '127.0.0.1'], - $client->getConfig('proxy') - ); - putenv('HTTPS_PROXY=127.0.0.2'); - putenv('NO_PROXY=127.0.0.3, 127.0.0.4'); - $client = new Client(); - self::assertSame( - ['http' => '127.0.0.1', 'https' => '127.0.0.2', 'no' => ['127.0.0.3','127.0.0.4']], - $client->getConfig('proxy') - ); - putenv("HTTP_PROXY=$http"); - putenv("HTTPS_PROXY=$https"); - putenv("NO_PROXY=$no"); - } - - public function testRequestSendsWithSync() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $client->request('GET', 'http://foo.com'); - self::assertTrue($mock->getLastOptions()['synchronous']); - } - - public function testSendSendsWithSync() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $client->send(new Request('GET', 'http://foo.com')); - self::assertTrue($mock->getLastOptions()['synchronous']); - } - - public function testCanSetCustomHandler() - { - $mock = new MockHandler([new Response(500)]); - $client = new Client(['handler' => $mock]); - $mock2 = new MockHandler([new Response(200)]); - self::assertSame( - 200, - $client->send(new Request('GET', 'http://foo.com'), [ - 'handler' => $mock2 - ])->getStatusCode() - ); - } - - public function testProperlyBuildsQuery() - { - $mock = new MockHandler([new Response()]); - $client = new Client(['handler' => $mock]); - $request = new Request('PUT', 'http://foo.com'); - $client->send($request, ['query' => ['foo' => 'bar', 'john' => 'doe']]); - self::assertSame('foo=bar&john=doe', $mock->getLastRequest()->getUri()->getQuery()); - } - - public function testSendSendsWithIpAddressAndPortAndHostHeaderInRequestTheHostShouldBePreserved() - { - $mockHandler = new MockHandler([new Response()]); - $client = new Client(['base_uri' => 'http://127.0.0.1:8585', 'handler' => $mockHandler]); - $request = new Request('GET', '/test', ['Host'=>'foo.com']); - - $client->send($request); - - self::assertSame('foo.com', $mockHandler->getLastRequest()->getHeader('Host')[0]); - } - - public function testSendSendsWithDomainAndHostHeaderInRequestTheHostShouldBePreserved() - { - $mockHandler = new MockHandler([new Response()]); - $client = new Client(['base_uri' => 'http://foo2.com', 'handler' => $mockHandler]); - $request = new Request('GET', '/test', ['Host'=>'foo.com']); - - $client->send($request); - - self::assertSame('foo.com', $mockHandler->getLastRequest()->getHeader('Host')[0]); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testValidatesSink() - { - $mockHandler = new MockHandler([new Response()]); - $client = new Client(['handler' => $mockHandler]); - $client->get('http://test.com', ['sink' => true]); - } - - public function testHttpDefaultSchemeIfUriHasNone() - { - $mockHandler = new MockHandler([new Response()]); - $client = new Client(['handler' => $mockHandler]); - - $client->request('GET', '//example.org/test'); - - self::assertSame('http://example.org/test', (string) $mockHandler->getLastRequest()->getUri()); - } - - public function testOnlyAddSchemeWhenHostIsPresent() - { - $mockHandler = new MockHandler([new Response()]); - $client = new Client(['handler' => $mockHandler]); - - $client->request('GET', 'baz'); - self::assertSame( - 'baz', - (string) $mockHandler->getLastRequest()->getUri() - ); - } - - /** - * @expectedException InvalidArgumentException - */ - public function testHandlerIsCallable() - { - new Client(['handler' => 'not_cllable']); - } - - public function testResponseBodyAsString() - { - $responseBody = '{ "package": "guzzle" }'; - $mock = new MockHandler([new Response(200, ['Content-Type' => 'application/json'], $responseBody)]); - $client = new Client(['handler' => $mock]); - $request = new Request('GET', 'http://foo.com'); - $response = $client->send($request, ['json' => ['a' => 'b']]); - - self::assertSame($responseBody, (string) $response->getBody()); - } - - public function testResponseContent() - { - $responseBody = '{ "package": "guzzle" }'; - $mock = new MockHandler([new Response(200, ['Content-Type' => 'application/json'], $responseBody)]); - $client = new Client(['handler' => $mock]); - $request = new Request('POST', 'http://foo.com'); - $response = $client->send($request, ['json' => ['a' => 'b']]); - - self::assertSame($responseBody, $response->getBody()->getContents()); - } - - public function testIdnSupportDefaultValue() - { - $mockHandler = new MockHandler([new Response()]); - $client = new Client(['handler' => $mockHandler]); - - $config = $client->getConfig(); - - self::assertTrue($config['idn_conversion']); - } - - public function testIdnIsTranslatedToAsciiWhenConversionIsEnabled() - { - $mockHandler = new MockHandler([new Response()]); - $client = new Client(['handler' => $mockHandler]); - - $client->request('GET', 'https://яндекс.рф/images', ['idn_conversion' => true]); - - $request = $mockHandler->getLastRequest(); - - self::assertSame('https://xn--d1acpjx3f.xn--p1ai/images', (string) $request->getUri()); - self::assertSame('xn--d1acpjx3f.xn--p1ai', (string) $request->getHeaderLine('Host')); - } - - public function testIdnStaysTheSameWhenConversionIsDisabled() - { - $mockHandler = new MockHandler([new Response()]); - $client = new Client(['handler' => $mockHandler]); - - $client->request('GET', 'https://яндекс.рф/images', ['idn_conversion' => false]); - - $request = $mockHandler->getLastRequest(); - - self::assertSame('https://яндекс.рф/images', (string) $request->getUri()); - self::assertSame('яндекс.рф', (string) $request->getHeaderLine('Host')); - } - - /** - * @expectedException \GuzzleHttp\Exception\InvalidArgumentException - * @expectedExceptionMessage IDN conversion failed - */ - public function testExceptionOnInvalidIdn() - { - $mockHandler = new MockHandler([new Response()]); - $client = new Client(['handler' => $mockHandler]); - - $client->request('GET', 'https://-яндекс.рф/images', ['idn_conversion' => true]); - } - - /** - * @depends testCanUseRelativeUriWithSend - * @depends testIdnSupportDefaultValue - */ - public function testIdnBaseUri() - { - $mock = new MockHandler([new Response()]); - $client = new Client([ - 'handler' => $mock, - 'base_uri' => 'http://яндекс.рф', - ]); - self::assertSame('http://яндекс.рф', (string) $client->getConfig('base_uri')); - $request = new Request('GET', '/baz'); - $client->send($request); - self::assertSame('http://xn--d1acpjx3f.xn--p1ai/baz', (string) $mock->getLastRequest()->getUri()); - self::assertSame('xn--d1acpjx3f.xn--p1ai', (string) $mock->getLastRequest()->getHeaderLine('Host')); - } - - public function testIdnWithRedirect() - { - $mockHandler = new MockHandler([ - new Response(302, ['Location' => 'http://www.tést.com/whatever']), - new Response() - ]); - $handler = HandlerStack::create($mockHandler); - $requests = []; - $handler->push(Middleware::history($requests)); - $client = new Client(['handler' => $handler]); - - $client->request('GET', 'https://яндекс.рф/images', [ - RequestOptions::ALLOW_REDIRECTS => [ - 'referer' => true, - 'track_redirects' => true - ], - 'idn_conversion' => true - ]); - - $request = $mockHandler->getLastRequest(); - - self::assertSame('http://www.xn--tst-bma.com/whatever', (string) $request->getUri()); - self::assertSame('www.xn--tst-bma.com', (string) $request->getHeaderLine('Host')); - - $request = $requests[0]['request']; - self::assertSame('https://xn--d1acpjx3f.xn--p1ai/images', (string) $request->getUri()); - self::assertSame('xn--d1acpjx3f.xn--p1ai', (string) $request->getHeaderLine('Host')); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Cookie/CookieJarTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Cookie/CookieJarTest.php deleted file mode 100644 index 1e9c84c9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Cookie/CookieJarTest.php +++ /dev/null @@ -1,449 +0,0 @@ -jar = new CookieJar(); - } - - protected function getTestCookies() - { - return [ - new SetCookie(['Name' => 'foo', 'Value' => 'bar', 'Domain' => 'foo.com', 'Path' => '/', 'Discard' => true]), - new SetCookie(['Name' => 'test', 'Value' => '123', 'Domain' => 'baz.com', 'Path' => '/foo', 'Expires' => 2]), - new SetCookie(['Name' => 'you', 'Value' => '123', 'Domain' => 'bar.com', 'Path' => '/boo', 'Expires' => time() + 1000]) - ]; - } - - public function testCreatesFromArray() - { - $jar = CookieJar::fromArray([ - 'foo' => 'bar', - 'baz' => 'bam' - ], 'example.com'); - self::assertCount(2, $jar); - } - - public function testEmptyJarIsCountable() - { - self::assertCount(0, new CookieJar()); - } - - public function testGetsCookiesByName() - { - $cookies = $this->getTestCookies(); - foreach ($this->getTestCookies() as $cookie) { - $this->jar->setCookie($cookie); - } - - $testCookie = $cookies[0]; - self::assertEquals($testCookie, $this->jar->getCookieByName($testCookie->getName())); - self::assertNull($this->jar->getCookieByName("doesnotexist")); - self::assertNull($this->jar->getCookieByName("")); - } - - /** - * Provides test data for cookie cookieJar retrieval - */ - public function getCookiesDataProvider() - { - return [ - [['foo', 'baz', 'test', 'muppet', 'googoo'], '', '', '', false], - [['foo', 'baz', 'muppet', 'googoo'], '', '', '', true], - [['googoo'], 'www.example.com', '', '', false], - [['muppet', 'googoo'], 'test.y.example.com', '', '', false], - [['foo', 'baz'], 'example.com', '', '', false], - [['muppet'], 'x.y.example.com', '/acme/', '', false], - [['muppet'], 'x.y.example.com', '/acme/test/', '', false], - [['googoo'], 'x.y.example.com', '/test/acme/test/', '', false], - [['foo', 'baz'], 'example.com', '', '', false], - [['baz'], 'example.com', '', 'baz', false], - ]; - } - - public function testStoresAndRetrievesCookies() - { - $cookies = $this->getTestCookies(); - foreach ($cookies as $cookie) { - self::assertTrue($this->jar->setCookie($cookie)); - } - - self::assertCount(3, $this->jar); - self::assertCount(3, $this->jar->getIterator()); - self::assertEquals($cookies, $this->jar->getIterator()->getArrayCopy()); - } - - public function testRemovesTemporaryCookies() - { - $cookies = $this->getTestCookies(); - foreach ($this->getTestCookies() as $cookie) { - $this->jar->setCookie($cookie); - } - $this->jar->clearSessionCookies(); - self::assertEquals( - [$cookies[1], $cookies[2]], - $this->jar->getIterator()->getArrayCopy() - ); - } - - public function testRemovesSelectively() - { - foreach ($this->getTestCookies() as $cookie) { - $this->jar->setCookie($cookie); - } - - // Remove foo.com cookies - $this->jar->clear('foo.com'); - self::assertCount(2, $this->jar); - // Try again, removing no further cookies - $this->jar->clear('foo.com'); - self::assertCount(2, $this->jar); - - // Remove bar.com cookies with path of /boo - $this->jar->clear('bar.com', '/boo'); - self::assertCount(1, $this->jar); - - // Remove cookie by name - $this->jar->clear(null, null, 'test'); - self::assertCount(0, $this->jar); - } - - public function testDoesNotAddIncompleteCookies() - { - self::assertFalse($this->jar->setCookie(new SetCookie())); - self::assertFalse($this->jar->setCookie(new SetCookie([ - 'Name' => 'foo' - ]))); - self::assertFalse($this->jar->setCookie(new SetCookie([ - 'Name' => false - ]))); - self::assertFalse($this->jar->setCookie(new SetCookie([ - 'Name' => true - ]))); - self::assertFalse($this->jar->setCookie(new SetCookie([ - 'Name' => 'foo', - 'Domain' => 'foo.com' - ]))); - } - - public function testDoesNotAddEmptyCookies() - { - self::assertFalse($this->jar->setCookie(new SetCookie([ - 'Name' => '', - 'Domain' => 'foo.com', - 'Value' => 0 - ]))); - } - - public function testDoesAddValidCookies() - { - self::assertTrue($this->jar->setCookie(new SetCookie([ - 'Name' => '0', - 'Domain' => 'foo.com', - 'Value' => 0 - ]))); - self::assertTrue($this->jar->setCookie(new SetCookie([ - 'Name' => 'foo', - 'Domain' => 'foo.com', - 'Value' => 0 - ]))); - self::assertTrue($this->jar->setCookie(new SetCookie([ - 'Name' => 'foo', - 'Domain' => 'foo.com', - 'Value' => 0.0 - ]))); - self::assertTrue($this->jar->setCookie(new SetCookie([ - 'Name' => 'foo', - 'Domain' => 'foo.com', - 'Value' => '0' - ]))); - } - - public function testOverwritesCookiesThatAreOlderOrDiscardable() - { - $t = time() + 1000; - $data = [ - 'Name' => 'foo', - 'Value' => 'bar', - 'Domain' => '.example.com', - 'Path' => '/', - 'Max-Age' => '86400', - 'Secure' => true, - 'Discard' => true, - 'Expires' => $t - ]; - - // Make sure that the discard cookie is overridden with the non-discard - self::assertTrue($this->jar->setCookie(new SetCookie($data))); - self::assertCount(1, $this->jar); - - $data['Discard'] = false; - self::assertTrue($this->jar->setCookie(new SetCookie($data))); - self::assertCount(1, $this->jar); - - $c = $this->jar->getIterator()->getArrayCopy(); - self::assertFalse($c[0]->getDiscard()); - - // Make sure it doesn't duplicate the cookie - $this->jar->setCookie(new SetCookie($data)); - self::assertCount(1, $this->jar); - - // Make sure the more future-ful expiration date supersede the other - $data['Expires'] = time() + 2000; - self::assertTrue($this->jar->setCookie(new SetCookie($data))); - self::assertCount(1, $this->jar); - $c = $this->jar->getIterator()->getArrayCopy(); - self::assertNotEquals($t, $c[0]->getExpires()); - } - - public function testOverwritesCookiesThatHaveChanged() - { - $t = time() + 1000; - $data = [ - 'Name' => 'foo', - 'Value' => 'bar', - 'Domain' => '.example.com', - 'Path' => '/', - 'Max-Age' => '86400', - 'Secure' => true, - 'Discard' => true, - 'Expires' => $t - ]; - - // Make sure that the discard cookie is overridden with the non-discard - self::assertTrue($this->jar->setCookie(new SetCookie($data))); - - $data['Value'] = 'boo'; - self::assertTrue($this->jar->setCookie(new SetCookie($data))); - self::assertCount(1, $this->jar); - - // Changing the value plus a parameter also must overwrite the existing one - $data['Value'] = 'zoo'; - $data['Secure'] = false; - self::assertTrue($this->jar->setCookie(new SetCookie($data))); - self::assertCount(1, $this->jar); - - $c = $this->jar->getIterator()->getArrayCopy(); - self::assertSame('zoo', $c[0]->getValue()); - } - - public function testAddsCookiesFromResponseWithRequest() - { - $response = new Response(200, [ - 'Set-Cookie' => "fpc=d=.Hm.yh4.1XmJWjJfs4orLQzKzPImxklQoxXSHOZATHUSEFciRueW_7704iYUtsXNEXq0M92Px2glMdWypmJ7HIQl6XIUvrZimWjQ3vIdeuRbI.FNQMAfcxu_XN1zSx7l.AcPdKL6guHc2V7hIQFhnjRW0rxm2oHY1P4bGQxFNz7f.tHm12ZD3DbdMDiDy7TBXsuP4DM-&v=2; expires=Fri, 02-Mar-2019 02:17:40 GMT;" - ]); - $request = new Request('GET', 'http://www.example.com'); - $this->jar->extractCookies($request, $response); - self::assertCount(1, $this->jar); - } - - public function getMatchingCookiesDataProvider() - { - return [ - ['https://example.com', 'foo=bar; baz=foobar'], - ['http://example.com', ''], - ['https://example.com:8912', 'foo=bar; baz=foobar'], - ['https://foo.example.com', 'foo=bar; baz=foobar'], - ['http://foo.example.com/test/acme/', 'googoo=gaga'] - ]; - } - - /** - * @dataProvider getMatchingCookiesDataProvider - */ - public function testReturnsCookiesMatchingRequests($url, $cookies) - { - $bag = [ - new SetCookie([ - 'Name' => 'foo', - 'Value' => 'bar', - 'Domain' => 'example.com', - 'Path' => '/', - 'Max-Age' => '86400', - 'Secure' => true - ]), - new SetCookie([ - 'Name' => 'baz', - 'Value' => 'foobar', - 'Domain' => 'example.com', - 'Path' => '/', - 'Max-Age' => '86400', - 'Secure' => true - ]), - new SetCookie([ - 'Name' => 'test', - 'Value' => '123', - 'Domain' => 'www.foobar.com', - 'Path' => '/path/', - 'Discard' => true - ]), - new SetCookie([ - 'Name' => 'muppet', - 'Value' => 'cookie_monster', - 'Domain' => '.y.example.com', - 'Path' => '/acme/', - 'Expires' => time() + 86400 - ]), - new SetCookie([ - 'Name' => 'googoo', - 'Value' => 'gaga', - 'Domain' => '.example.com', - 'Path' => '/test/acme/', - 'Max-Age' => 1500 - ]) - ]; - - foreach ($bag as $cookie) { - $this->jar->setCookie($cookie); - } - - $request = new Request('GET', $url); - $request = $this->jar->withCookieHeader($request); - self::assertSame($cookies, $request->getHeaderLine('Cookie')); - } - - /** - * @expectedException \RuntimeException - * @expectedExceptionMessage Invalid cookie: Cookie name must not contain invalid characters: ASCII Control characters (0-31;127), space, tab and the following characters: ()<>@,;:\"/?={} - */ - public function testThrowsExceptionWithStrictMode() - { - $a = new CookieJar(true); - $a->setCookie(new SetCookie(['Name' => "abc\n", 'Value' => 'foo', 'Domain' => 'bar'])); - } - - public function testDeletesCookiesByName() - { - $cookies = $this->getTestCookies(); - $cookies[] = new SetCookie([ - 'Name' => 'other', - 'Value' => '123', - 'Domain' => 'bar.com', - 'Path' => '/boo', - 'Expires' => time() + 1000 - ]); - $jar = new CookieJar(); - foreach ($cookies as $cookie) { - $jar->setCookie($cookie); - } - self::assertCount(4, $jar); - $jar->clear('bar.com', '/boo', 'other'); - self::assertCount(3, $jar); - $names = array_map(function (SetCookie $c) { - return $c->getName(); - }, $jar->getIterator()->getArrayCopy()); - self::assertSame(['foo', 'test', 'you'], $names); - } - - public function testCanConvertToAndLoadFromArray() - { - $jar = new CookieJar(true); - foreach ($this->getTestCookies() as $cookie) { - $jar->setCookie($cookie); - } - self::assertCount(3, $jar); - $arr = $jar->toArray(); - self::assertCount(3, $arr); - $newCookieJar = new CookieJar(false, $arr); - self::assertCount(3, $newCookieJar); - self::assertSame($jar->toArray(), $newCookieJar->toArray()); - } - - public function testAddsCookiesWithEmptyPathFromResponse() - { - $response = new Response(200, [ - 'Set-Cookie' => "fpc=foobar; expires={$this->futureExpirationDate()}; path=;" - ]); - $request = new Request('GET', 'http://www.example.com'); - $this->jar->extractCookies($request, $response); - $newRequest = $this->jar->withCookieHeader(new Request('GET', 'http://www.example.com/foo')); - self::assertTrue($newRequest->hasHeader('Cookie')); - } - - public function getCookiePathsDataProvider() - { - return [ - ['', '/'], - ['/', '/'], - ['/foo', '/'], - ['/foo/bar', '/foo'], - ['/foo/bar/', '/foo/bar'], - ]; - } - - /** - * @dataProvider getCookiePathsDataProvider - */ - public function testCookiePathWithEmptySetCookiePath($uriPath, $cookiePath) - { - $response = (new Response(200)) - ->withAddedHeader( - 'Set-Cookie', - "foo=bar; expires={$this->futureExpirationDate()}; domain=www.example.com; path=;" - ) - ->withAddedHeader( - 'Set-Cookie', - "bar=foo; expires={$this->futureExpirationDate()}; domain=www.example.com; path=foobar;" - ) - ; - $request = (new Request('GET', "https://www.example.com{$uriPath}")); - $this->jar->extractCookies($request, $response); - - self::assertSame($cookiePath, $this->jar->toArray()[0]['Path']); - self::assertSame($cookiePath, $this->jar->toArray()[1]['Path']); - } - - public function getDomainMatchesProvider() - { - return [ - ['www.example.com', 'www.example.com', true], - ['www.example.com', 'www.EXAMPLE.com', true], - ['www.example.com', 'www.example.net', false], - ['www.example.com', 'ftp.example.com', false], - ['www.example.com', 'example.com', true], - ['www.example.com', 'EXAMPLE.com', true], - ['fra.de.example.com', 'EXAMPLE.com', true], - ['www.EXAMPLE.com', 'www.example.com', true], - ['www.EXAMPLE.com', 'www.example.COM', true], - ]; - } - - /** - * @dataProvider getDomainMatchesProvider - */ - public function testIgnoresCookiesForMismatchingDomains($requestHost, $domainAttribute, $matches) - { - $response = (new Response(200)) - ->withAddedHeader( - 'Set-Cookie', - "foo=bar; expires={$this->futureExpirationDate()}; domain={$domainAttribute}; path=/;" - ) - ; - $request = (new Request('GET', "https://{$requestHost}/")); - $this->jar->extractCookies($request, $response); - - self::assertCount($matches ? 1 : 0, $this->jar->toArray()); - } - - private function futureExpirationDate() - { - return (new DateTimeImmutable)->add(new DateInterval('P1D'))->format(DateTime::COOKIE); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Cookie/FileCookieJarTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Cookie/FileCookieJarTest.php deleted file mode 100644 index 6391c201..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Cookie/FileCookieJarTest.php +++ /dev/null @@ -1,88 +0,0 @@ -file = tempnam('/tmp', 'file-cookies'); - } - - /** - * @expectedException \RuntimeException - */ - public function testValidatesCookieFile() - { - file_put_contents($this->file, 'true'); - new FileCookieJar($this->file); - } - - public function testLoadsFromFile() - { - $jar = new FileCookieJar($this->file); - self::assertSame([], $jar->getIterator()->getArrayCopy()); - unlink($this->file); - } - - /** - * @dataProvider providerPersistsToFileFileParameters - */ - public function testPersistsToFile($testSaveSessionCookie = false) - { - $jar = new FileCookieJar($this->file, $testSaveSessionCookie); - $jar->setCookie(new SetCookie([ - 'Name' => 'foo', - 'Value' => 'bar', - 'Domain' => 'foo.com', - 'Expires' => time() + 1000 - ])); - $jar->setCookie(new SetCookie([ - 'Name' => 'baz', - 'Value' => 'bar', - 'Domain' => 'foo.com', - 'Expires' => time() + 1000 - ])); - $jar->setCookie(new SetCookie([ - 'Name' => 'boo', - 'Value' => 'bar', - 'Domain' => 'foo.com', - ])); - - self::assertCount(3, $jar); - unset($jar); - - // Make sure it wrote to the file - $contents = file_get_contents($this->file); - self::assertNotEmpty($contents); - - // Load the cookieJar from the file - $jar = new FileCookieJar($this->file); - - if ($testSaveSessionCookie) { - self::assertCount(3, $jar); - } else { - // Weeds out temporary and session cookies - self::assertCount(2, $jar); - } - - unset($jar); - unlink($this->file); - } - - public function providerPersistsToFileFileParameters() - { - return [ - [false], - [true] - ]; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Cookie/SessionCookieJarTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Cookie/SessionCookieJarTest.php deleted file mode 100644 index 2f29bdc1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Cookie/SessionCookieJarTest.php +++ /dev/null @@ -1,92 +0,0 @@ -sessionVar = 'sessionKey'; - - if (!isset($_SESSION)) { - $_SESSION = []; - } - } - - /** - * @expectedException \RuntimeException - */ - public function testValidatesCookieSession() - { - $_SESSION[$this->sessionVar] = 'true'; - new SessionCookieJar($this->sessionVar); - } - - public function testLoadsFromSession() - { - $jar = new SessionCookieJar($this->sessionVar); - self::assertSame([], $jar->getIterator()->getArrayCopy()); - unset($_SESSION[$this->sessionVar]); - } - - /** - * @dataProvider providerPersistsToSessionParameters - */ - public function testPersistsToSession($testSaveSessionCookie = false) - { - $jar = new SessionCookieJar($this->sessionVar, $testSaveSessionCookie); - $jar->setCookie(new SetCookie([ - 'Name' => 'foo', - 'Value' => 'bar', - 'Domain' => 'foo.com', - 'Expires' => time() + 1000 - ])); - $jar->setCookie(new SetCookie([ - 'Name' => 'baz', - 'Value' => 'bar', - 'Domain' => 'foo.com', - 'Expires' => time() + 1000 - ])); - $jar->setCookie(new SetCookie([ - 'Name' => 'boo', - 'Value' => 'bar', - 'Domain' => 'foo.com', - ])); - - self::assertCount(3, $jar); - unset($jar); - - // Make sure it wrote to the sessionVar in $_SESSION - $contents = $_SESSION[$this->sessionVar]; - self::assertNotEmpty($contents); - - // Load the cookieJar from the file - $jar = new SessionCookieJar($this->sessionVar); - - if ($testSaveSessionCookie) { - self::assertCount(3, $jar); - } else { - // Weeds out temporary and session cookies - self::assertCount(2, $jar); - } - - unset($jar); - unset($_SESSION[$this->sessionVar]); - } - - public function providerPersistsToSessionParameters() - { - return [ - [false], - [true] - ]; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Cookie/SetCookieTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Cookie/SetCookieTest.php deleted file mode 100644 index 335e44ba..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Cookie/SetCookieTest.php +++ /dev/null @@ -1,445 +0,0 @@ -getPath()); - } - - public function testConvertsDateTimeMaxAgeToUnixTimestamp() - { - $cookie = new SetCookie(['Expires' => 'November 20, 1984']); - self::assertInternalType('integer', $cookie->getExpires()); - } - - public function testAddsExpiresBasedOnMaxAge() - { - $t = time(); - $cookie = new SetCookie(['Max-Age' => 100]); - self::assertEquals($t + 100, $cookie->getExpires()); - } - - public function testHoldsValues() - { - $t = time(); - $data = [ - 'Name' => 'foo', - 'Value' => 'baz', - 'Path' => '/bar', - 'Domain' => 'baz.com', - 'Expires' => $t, - 'Max-Age' => 100, - 'Secure' => true, - 'Discard' => true, - 'HttpOnly' => true, - 'foo' => 'baz', - 'bar' => 'bam' - ]; - - $cookie = new SetCookie($data); - self::assertEquals($data, $cookie->toArray()); - - self::assertSame('foo', $cookie->getName()); - self::assertSame('baz', $cookie->getValue()); - self::assertSame('baz.com', $cookie->getDomain()); - self::assertSame('/bar', $cookie->getPath()); - self::assertSame($t, $cookie->getExpires()); - self::assertSame(100, $cookie->getMaxAge()); - self::assertTrue($cookie->getSecure()); - self::assertTrue($cookie->getDiscard()); - self::assertTrue($cookie->getHttpOnly()); - self::assertSame('baz', $cookie->toArray()['foo']); - self::assertSame('bam', $cookie->toArray()['bar']); - - $cookie->setName('a'); - $cookie->setValue('b'); - $cookie->setPath('c'); - $cookie->setDomain('bar.com'); - $cookie->setExpires(10); - $cookie->setMaxAge(200); - $cookie->setSecure(false); - $cookie->setHttpOnly(false); - $cookie->setDiscard(false); - - self::assertSame('a', $cookie->getName()); - self::assertSame('b', $cookie->getValue()); - self::assertSame('c', $cookie->getPath()); - self::assertSame('bar.com', $cookie->getDomain()); - self::assertSame(10, $cookie->getExpires()); - self::assertSame(200, $cookie->getMaxAge()); - self::assertFalse($cookie->getSecure()); - self::assertFalse($cookie->getDiscard()); - self::assertFalse($cookie->getHttpOnly()); - } - - public function testDeterminesIfExpired() - { - $c = new SetCookie(); - $c->setExpires(10); - self::assertTrue($c->isExpired()); - $c->setExpires(time() + 10000); - self::assertFalse($c->isExpired()); - } - - public function testMatchesDomain() - { - $cookie = new SetCookie(); - self::assertTrue($cookie->matchesDomain('baz.com')); - - $cookie->setDomain('baz.com'); - self::assertTrue($cookie->matchesDomain('baz.com')); - self::assertFalse($cookie->matchesDomain('bar.com')); - - $cookie->setDomain('.baz.com'); - self::assertTrue($cookie->matchesDomain('.baz.com')); - self::assertTrue($cookie->matchesDomain('foo.baz.com')); - self::assertFalse($cookie->matchesDomain('baz.bar.com')); - self::assertTrue($cookie->matchesDomain('baz.com')); - - $cookie->setDomain('.127.0.0.1'); - self::assertTrue($cookie->matchesDomain('127.0.0.1')); - - $cookie->setDomain('127.0.0.1'); - self::assertTrue($cookie->matchesDomain('127.0.0.1')); - - $cookie->setDomain('.com.'); - self::assertFalse($cookie->matchesDomain('baz.com')); - - $cookie->setDomain('.local'); - self::assertTrue($cookie->matchesDomain('example.local')); - - $cookie->setDomain('example.com/'); // malformed domain - self::assertFalse($cookie->matchesDomain('example.com')); - } - - public function pathMatchProvider() - { - return [ - ['/foo', '/foo', true], - ['/foo', '/Foo', false], - ['/foo', '/fo', false], - ['/foo', '/foo/bar', true], - ['/foo', '/foo/bar/baz', true], - ['/foo', '/foo/bar//baz', true], - ['/foo', '/foobar', false], - ['/foo/bar', '/foo', false], - ['/foo/bar', '/foobar', false], - ['/foo/bar', '/foo/bar', true], - ['/foo/bar', '/foo/bar/', true], - ['/foo/bar', '/foo/bar/baz', true], - ['/foo/bar/', '/foo/bar', false], - ['/foo/bar/', '/foo/bar/', true], - ['/foo/bar/', '/foo/bar/baz', true], - ]; - } - - /** - * @dataProvider pathMatchProvider - */ - public function testMatchesPath($cookiePath, $requestPath, $isMatch) - { - $cookie = new SetCookie(); - $cookie->setPath($cookiePath); - self::assertSame($isMatch, $cookie->matchesPath($requestPath)); - } - - public function cookieValidateProvider() - { - return [ - ['foo', 'baz', 'bar', true], - ['0', '0', '0', true], - ['foo[bar]', 'baz', 'bar', true], - ['', 'baz', 'bar', 'The cookie name must not be empty'], - ['foo', '', 'bar', 'The cookie value must not be empty'], - ['foo', 'baz', '', 'The cookie domain must not be empty'], - ["foo\r", 'baz', '0', 'Cookie name must not contain invalid characters: ASCII Control characters (0-31;127), space, tab and the following characters: ()<>@,;:\"/?={}'], - ]; - } - - /** - * @dataProvider cookieValidateProvider - */ - public function testValidatesCookies($name, $value, $domain, $result) - { - $cookie = new SetCookie([ - 'Name' => $name, - 'Value' => $value, - 'Domain' => $domain, - ]); - self::assertSame($result, $cookie->validate()); - } - - public function testDoesNotMatchIp() - { - $cookie = new SetCookie(['Domain' => '192.168.16.']); - self::assertFalse($cookie->matchesDomain('192.168.16.121')); - } - - public function testConvertsToString() - { - $t = 1382916008; - $cookie = new SetCookie([ - 'Name' => 'test', - 'Value' => '123', - 'Domain' => 'foo.com', - 'Expires' => $t, - 'Path' => '/abc', - 'HttpOnly' => true, - 'Secure' => true - ]); - self::assertSame( - 'test=123; Domain=foo.com; Path=/abc; Expires=Sun, 27 Oct 2013 23:20:08 GMT; Secure; HttpOnly', - (string) $cookie - ); - } - - /** - * Provides the parsed information from a cookie - * - * @return array - */ - public function cookieParserDataProvider() - { - return [ - [ - 'ASIHTTPRequestTestCookie=This+is+the+value; expires=Sat, 26-Jul-2008 17:00:42 GMT; path=/tests; domain=allseeing-i.com; PHPSESSID=6c951590e7a9359bcedde25cda73e43c; path=/;', - [ - 'Domain' => 'allseeing-i.com', - 'Path' => '/', - 'PHPSESSID' => '6c951590e7a9359bcedde25cda73e43c', - 'Max-Age' => null, - 'Expires' => 'Sat, 26-Jul-2008 17:00:42 GMT', - 'Secure' => null, - 'Discard' => null, - 'Name' => 'ASIHTTPRequestTestCookie', - 'Value' => 'This+is+the+value', - 'HttpOnly' => false - ] - ], - ['', []], - ['foo', []], - ['; foo', []], - [ - 'foo="bar"', - [ - 'Name' => 'foo', - 'Value' => '"bar"', - 'Discard' => null, - 'Domain' => null, - 'Expires' => null, - 'Max-Age' => null, - 'Path' => '/', - 'Secure' => null, - 'HttpOnly' => false - ] - ], - // Test setting a blank value for a cookie - [[ - 'foo=', 'foo =', 'foo =;', 'foo= ;', 'foo =', 'foo= '], - [ - 'Name' => 'foo', - 'Value' => '', - 'Discard' => null, - 'Domain' => null, - 'Expires' => null, - 'Max-Age' => null, - 'Path' => '/', - 'Secure' => null, - 'HttpOnly' => false - ] - ], - // Test setting a value and removing quotes - [[ - 'foo=1', 'foo =1', 'foo =1;', 'foo=1 ;', 'foo =1', 'foo= 1', 'foo = 1 ;'], - [ - 'Name' => 'foo', - 'Value' => '1', - 'Discard' => null, - 'Domain' => null, - 'Expires' => null, - 'Max-Age' => null, - 'Path' => '/', - 'Secure' => null, - 'HttpOnly' => false - ] - ], - // Some of the following tests are based on http://framework.zend.com/svn/framework/standard/trunk/tests/Zend/Http/CookieTest.php - [ - 'justacookie=foo; domain=example.com', - [ - 'Name' => 'justacookie', - 'Value' => 'foo', - 'Domain' => 'example.com', - 'Discard' => null, - 'Expires' => null, - 'Max-Age' => null, - 'Path' => '/', - 'Secure' => null, - 'HttpOnly' => false - ] - ], - [ - 'expires=tomorrow; secure; path=/Space Out/; expires=Tue, 21-Nov-2006 08:33:44 GMT; domain=.example.com', - [ - 'Name' => 'expires', - 'Value' => 'tomorrow', - 'Domain' => '.example.com', - 'Path' => '/Space Out/', - 'Expires' => 'Tue, 21-Nov-2006 08:33:44 GMT', - 'Discard' => null, - 'Secure' => true, - 'Max-Age' => null, - 'HttpOnly' => false - ] - ], - [ - 'domain=unittests; expires=Tue, 21-Nov-2006 08:33:44 GMT; domain=example.com; path=/some value/', - [ - 'Name' => 'domain', - 'Value' => 'unittests', - 'Domain' => 'example.com', - 'Path' => '/some value/', - 'Expires' => 'Tue, 21-Nov-2006 08:33:44 GMT', - 'Secure' => false, - 'Discard' => null, - 'Max-Age' => null, - 'HttpOnly' => false - ] - ], - [ - 'path=indexAction; path=/; domain=.foo.com; expires=Tue, 21-Nov-2006 08:33:44 GMT', - [ - 'Name' => 'path', - 'Value' => 'indexAction', - 'Domain' => '.foo.com', - 'Path' => '/', - 'Expires' => 'Tue, 21-Nov-2006 08:33:44 GMT', - 'Secure' => false, - 'Discard' => null, - 'Max-Age' => null, - 'HttpOnly' => false - ] - ], - [ - 'secure=sha1; secure; SECURE; domain=some.really.deep.domain.com; version=1; Max-Age=86400', - [ - 'Name' => 'secure', - 'Value' => 'sha1', - 'Domain' => 'some.really.deep.domain.com', - 'Path' => '/', - 'Secure' => true, - 'Discard' => null, - 'Expires' => time() + 86400, - 'Max-Age' => 86400, - 'HttpOnly' => false, - 'version' => '1' - ] - ], - [ - 'PHPSESSID=123456789+abcd%2Cef; secure; discard; domain=.localdomain; path=/foo/baz; expires=Tue, 21-Nov-2006 08:33:44 GMT;', - [ - 'Name' => 'PHPSESSID', - 'Value' => '123456789+abcd%2Cef', - 'Domain' => '.localdomain', - 'Path' => '/foo/baz', - 'Expires' => 'Tue, 21-Nov-2006 08:33:44 GMT', - 'Secure' => true, - 'Discard' => true, - 'Max-Age' => null, - 'HttpOnly' => false - ] - ], - ]; - } - - /** - * @dataProvider cookieParserDataProvider - */ - public function testParseCookie($cookie, $parsed) - { - foreach ((array) $cookie as $v) { - $c = SetCookie::fromString($v); - $p = $c->toArray(); - - if (isset($p['Expires'])) { - // Remove expires values from the assertion if they are relatively equal - if (abs($p['Expires'] != strtotime($parsed['Expires'])) < 40) { - unset($p['Expires']); - unset($parsed['Expires']); - } - } - - if (!empty($parsed)) { - foreach ($parsed as $key => $value) { - self::assertEquals($parsed[$key], $p[$key], 'Comparing ' . $key . ' ' . var_export($value, true) . ' : ' . var_export($parsed, true) . ' | ' . var_export($p, true)); - } - foreach ($p as $key => $value) { - self::assertEquals($p[$key], $parsed[$key], 'Comparing ' . $key . ' ' . var_export($value, true) . ' : ' . var_export($parsed, true) . ' | ' . var_export($p, true)); - } - } else { - self::assertSame([ - 'Name' => null, - 'Value' => null, - 'Domain' => null, - 'Path' => '/', - 'Max-Age' => null, - 'Expires' => null, - 'Secure' => false, - 'Discard' => false, - 'HttpOnly' => false, - ], $p); - } - } - } - - /** - * Provides the data for testing isExpired - * - * @return array - */ - public function isExpiredProvider() - { - return [ - [ - 'FOO=bar; expires=Thu, 01 Jan 1970 00:00:00 GMT;', - true, - ], - [ - 'FOO=bar; expires=Thu, 01 Jan 1970 00:00:01 GMT;', - true, - ], - [ - 'FOO=bar; expires=' . date(\DateTime::RFC1123, time()+10) . ';', - false, - ], - [ - 'FOO=bar; expires=' . date(\DateTime::RFC1123, time()-10) . ';', - true, - ], - [ - 'FOO=bar;', - false, - ], - ]; - } - - /** - * @dataProvider isExpiredProvider - */ - public function testIsExpired($cookie, $expired) - { - self::assertSame( - $expired, - SetCookie::fromString($cookie)->isExpired() - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Exception/ConnectExceptionTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Exception/ConnectExceptionTest.php deleted file mode 100644 index 553af403..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Exception/ConnectExceptionTest.php +++ /dev/null @@ -1,25 +0,0 @@ - 'bar']); - self::assertSame($req, $e->getRequest()); - self::assertNull($e->getResponse()); - self::assertFalse($e->hasResponse()); - self::assertSame('foo', $e->getMessage()); - self::assertSame('bar', $e->getHandlerContext()['foo']); - self::assertSame($prev, $e->getPrevious()); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Exception/RequestExceptionTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Exception/RequestExceptionTest.php deleted file mode 100644 index 64d50d67..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Exception/RequestExceptionTest.php +++ /dev/null @@ -1,195 +0,0 @@ -getRequest()); - self::assertSame($res, $e->getResponse()); - self::assertTrue($e->hasResponse()); - self::assertSame('foo', $e->getMessage()); - } - - public function testCreatesGenerateException() - { - $e = RequestException::create(new Request('GET', '/')); - self::assertSame('Error completing request', $e->getMessage()); - self::assertInstanceOf('GuzzleHttp\Exception\RequestException', $e); - } - - public function testCreatesClientErrorResponseException() - { - $e = RequestException::create(new Request('GET', '/'), new Response(400)); - self::assertContains( - 'GET /', - $e->getMessage() - ); - self::assertContains( - '400 Bad Request', - $e->getMessage() - ); - self::assertInstanceOf('GuzzleHttp\Exception\ClientException', $e); - } - - public function testCreatesServerErrorResponseException() - { - $e = RequestException::create(new Request('GET', '/'), new Response(500)); - self::assertContains( - 'GET /', - $e->getMessage() - ); - self::assertContains( - '500 Internal Server Error', - $e->getMessage() - ); - self::assertInstanceOf('GuzzleHttp\Exception\ServerException', $e); - } - - public function testCreatesGenericErrorResponseException() - { - $e = RequestException::create(new Request('GET', '/'), new Response(300)); - self::assertContains( - 'GET /', - $e->getMessage() - ); - self::assertContains( - '300 ', - $e->getMessage() - ); - self::assertInstanceOf('GuzzleHttp\Exception\RequestException', $e); - } - - /** - * @expectedException InvalidArgumentException - * @expectedExceptionMessage Status code must be an integer value between 1xx and 5xx. - */ - public function testThrowsInvalidArgumentExceptionOnOutOfBoundsResponseCode() - { - throw RequestException::create(new Request('GET', '/'), new Response(600)); - } - - public function dataPrintableResponses() - { - return [ - ['You broke the test!'], - ['

        zlomený zkouška

        '], - ['{"tester": "Philépe Gonzalez"}'], - ["\n\tYour friendly test\n"], - ['document.body.write("here comes a test");'], - ["body:before {\n\tcontent: 'test style';\n}"], - ]; - } - - /** - * @dataProvider dataPrintableResponses - */ - public function testCreatesExceptionWithPrintableBodySummary($content) - { - $response = new Response( - 500, - [], - $content - ); - $e = RequestException::create(new Request('GET', '/'), $response); - self::assertContains( - $content, - $e->getMessage() - ); - self::assertInstanceOf('GuzzleHttp\Exception\RequestException', $e); - } - - public function testCreatesExceptionWithTruncatedSummary() - { - $content = str_repeat('+', 121); - $response = new Response(500, [], $content); - $e = RequestException::create(new Request('GET', '/'), $response); - $expected = str_repeat('+', 120) . ' (truncated...)'; - self::assertContains($expected, $e->getMessage()); - } - - public function testExceptionMessageIgnoresEmptyBody() - { - $e = RequestException::create(new Request('GET', '/'), new Response(500)); - self::assertStringEndsWith('response', $e->getMessage()); - } - - public function testHasStatusCodeAsExceptionCode() - { - $e = RequestException::create(new Request('GET', '/'), new Response(442)); - self::assertSame(442, $e->getCode()); - } - - public function testWrapsRequestExceptions() - { - $e = new \Exception('foo'); - $r = new Request('GET', 'http://www.oo.com'); - $ex = RequestException::wrapException($r, $e); - self::assertInstanceOf('GuzzleHttp\Exception\RequestException', $ex); - self::assertSame($e, $ex->getPrevious()); - } - - public function testDoesNotWrapExistingRequestExceptions() - { - $r = new Request('GET', 'http://www.oo.com'); - $e = new RequestException('foo', $r); - $e2 = RequestException::wrapException($r, $e); - self::assertSame($e, $e2); - } - - public function testCanProvideHandlerContext() - { - $r = new Request('GET', 'http://www.oo.com'); - $e = new RequestException('foo', $r, null, null, ['bar' => 'baz']); - self::assertSame(['bar' => 'baz'], $e->getHandlerContext()); - } - - public function testObfuscateUrlWithUsername() - { - $r = new Request('GET', 'http://username@www.oo.com'); - $e = RequestException::create($r, new Response(500)); - self::assertContains('http://username@www.oo.com', $e->getMessage()); - } - - public function testObfuscateUrlWithUsernameAndPassword() - { - $r = new Request('GET', 'http://user:password@www.oo.com'); - $e = RequestException::create($r, new Response(500)); - self::assertContains('http://user:***@www.oo.com', $e->getMessage()); - } - - public function testGetResponseBodySummaryOfNonReadableStream() - { - self::assertNull(RequestException::getResponseBodySummary(new Response(500, [], new ReadSeekOnlyStream()))); - } -} - -final class ReadSeekOnlyStream extends Stream -{ - public function __construct() - { - parent::__construct(fopen('php://memory', 'wb')); - } - - public function isSeekable() - { - return true; - } - - public function isReadable() - { - return false; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Exception/SeekExceptionTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Exception/SeekExceptionTest.php deleted file mode 100644 index f12ac590..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Exception/SeekExceptionTest.php +++ /dev/null @@ -1,17 +0,0 @@ -getStream()); - self::assertContains('10', $e->getMessage()); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/CurlFactoryTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/CurlFactoryTest.php deleted file mode 100644 index a4cb3c4e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/CurlFactoryTest.php +++ /dev/null @@ -1,770 +0,0 @@ - 'Bar', - 'Baz' => 'bam', - 'Content-Length' => 2, - ], 'hi') - ]); - $stream = Psr7\stream_for(); - $request = new Psr7\Request('PUT', Server::$url, [ - 'Hi' => ' 123', - 'Content-Length' => '7' - ], 'testing'); - $f = new Handler\CurlFactory(3); - $result = $f->create($request, ['sink' => $stream]); - self::assertInstanceOf(EasyHandle::class, $result); - self::assertInternalType('resource', $result->handle); - self::assertInternalType('array', $result->headers); - self::assertSame($stream, $result->sink); - curl_close($result->handle); - self::assertSame('PUT', $_SERVER['_curl'][CURLOPT_CUSTOMREQUEST]); - self::assertSame( - 'http://127.0.0.1:8126/', - $_SERVER['_curl'][CURLOPT_URL] - ); - // Sends via post fields when the request is small enough - self::assertSame('testing', $_SERVER['_curl'][CURLOPT_POSTFIELDS]); - self::assertEquals(0, $_SERVER['_curl'][CURLOPT_RETURNTRANSFER]); - self::assertEquals(0, $_SERVER['_curl'][CURLOPT_HEADER]); - self::assertSame(150, $_SERVER['_curl'][CURLOPT_CONNECTTIMEOUT]); - self::assertInstanceOf('Closure', $_SERVER['_curl'][CURLOPT_HEADERFUNCTION]); - if (defined('CURLOPT_PROTOCOLS')) { - self::assertSame( - CURLPROTO_HTTP | CURLPROTO_HTTPS, - $_SERVER['_curl'][CURLOPT_PROTOCOLS] - ); - } - self::assertContains('Expect:', $_SERVER['_curl'][CURLOPT_HTTPHEADER]); - self::assertContains('Accept:', $_SERVER['_curl'][CURLOPT_HTTPHEADER]); - self::assertContains('Content-Type:', $_SERVER['_curl'][CURLOPT_HTTPHEADER]); - self::assertContains('Hi: 123', $_SERVER['_curl'][CURLOPT_HTTPHEADER]); - self::assertContains('Host: 127.0.0.1:8126', $_SERVER['_curl'][CURLOPT_HTTPHEADER]); - } - - public function testSendsHeadRequests() - { - Server::flush(); - Server::enqueue([new Psr7\Response()]); - $a = new Handler\CurlMultiHandler(); - $response = $a(new Psr7\Request('HEAD', Server::$url), []); - $response->wait(); - self::assertEquals(true, $_SERVER['_curl'][CURLOPT_NOBODY]); - $checks = [CURLOPT_WRITEFUNCTION, CURLOPT_READFUNCTION, CURLOPT_INFILE]; - foreach ($checks as $check) { - self::assertArrayNotHasKey($check, $_SERVER['_curl']); - } - self::assertEquals('HEAD', Server::received()[0]->getMethod()); - } - - public function testCanAddCustomCurlOptions() - { - Server::flush(); - Server::enqueue([new Psr7\Response()]); - $a = new Handler\CurlMultiHandler(); - $req = new Psr7\Request('GET', Server::$url); - $a($req, ['curl' => [CURLOPT_LOW_SPEED_LIMIT => 10]]); - self::assertEquals(10, $_SERVER['_curl'][CURLOPT_LOW_SPEED_LIMIT]); - } - - public function testCanChangeCurlOptions() - { - Server::flush(); - Server::enqueue([new Psr7\Response()]); - $a = new Handler\CurlMultiHandler(); - $req = new Psr7\Request('GET', Server::$url); - $a($req, ['curl' => [CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_0]]); - self::assertEquals(CURL_HTTP_VERSION_1_0, $_SERVER['_curl'][CURLOPT_HTTP_VERSION]); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage SSL CA bundle not found: /does/not/exist - */ - public function testValidatesVerify() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', Server::$url), ['verify' => '/does/not/exist']); - } - - public function testCanSetVerifyToFile() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', 'http://foo.com'), ['verify' => __FILE__]); - self::assertEquals(__FILE__, $_SERVER['_curl'][CURLOPT_CAINFO]); - self::assertEquals(2, $_SERVER['_curl'][CURLOPT_SSL_VERIFYHOST]); - self::assertEquals(true, $_SERVER['_curl'][CURLOPT_SSL_VERIFYPEER]); - } - - public function testCanSetVerifyToDir() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', 'http://foo.com'), ['verify' => __DIR__]); - self::assertEquals(__DIR__, $_SERVER['_curl'][CURLOPT_CAPATH]); - self::assertEquals(2, $_SERVER['_curl'][CURLOPT_SSL_VERIFYHOST]); - self::assertEquals(true, $_SERVER['_curl'][CURLOPT_SSL_VERIFYPEER]); - } - - public function testAddsVerifyAsTrue() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', Server::$url), ['verify' => true]); - self::assertEquals(2, $_SERVER['_curl'][CURLOPT_SSL_VERIFYHOST]); - self::assertEquals(true, $_SERVER['_curl'][CURLOPT_SSL_VERIFYPEER]); - self::assertArrayNotHasKey(CURLOPT_CAINFO, $_SERVER['_curl']); - } - - public function testCanDisableVerify() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', Server::$url), ['verify' => false]); - self::assertEquals(0, $_SERVER['_curl'][CURLOPT_SSL_VERIFYHOST]); - self::assertEquals(false, $_SERVER['_curl'][CURLOPT_SSL_VERIFYPEER]); - } - - public function testAddsProxy() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', Server::$url), ['proxy' => 'http://bar.com']); - self::assertEquals('http://bar.com', $_SERVER['_curl'][CURLOPT_PROXY]); - } - - public function testAddsViaScheme() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', Server::$url), [ - 'proxy' => ['http' => 'http://bar.com', 'https' => 'https://t'], - ]); - self::assertEquals('http://bar.com', $_SERVER['_curl'][CURLOPT_PROXY]); - $this->checkNoProxyForHost('http://test.test.com', ['test.test.com'], false); - $this->checkNoProxyForHost('http://test.test.com', ['.test.com'], false); - $this->checkNoProxyForHost('http://test.test.com', ['*.test.com'], true); - $this->checkNoProxyForHost('http://test.test.com', ['*'], false); - $this->checkNoProxyForHost('http://127.0.0.1', ['127.0.0.*'], true); - } - - private function checkNoProxyForHost($url, $noProxy, $assertUseProxy) - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', $url), [ - 'proxy' => [ - 'http' => 'http://bar.com', - 'https' => 'https://t', - 'no' => $noProxy - ], - ]); - if ($assertUseProxy) { - self::assertArrayHasKey(CURLOPT_PROXY, $_SERVER['_curl']); - } else { - self::assertArrayNotHasKey(CURLOPT_PROXY, $_SERVER['_curl']); - } - } - - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage SSL private key not found: /does/not/exist - */ - public function testValidatesSslKey() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', Server::$url), ['ssl_key' => '/does/not/exist']); - } - - public function testAddsSslKey() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', Server::$url), ['ssl_key' => __FILE__]); - self::assertEquals(__FILE__, $_SERVER['_curl'][CURLOPT_SSLKEY]); - } - - public function testAddsSslKeyWithPassword() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', Server::$url), ['ssl_key' => [__FILE__, 'test']]); - self::assertEquals(__FILE__, $_SERVER['_curl'][CURLOPT_SSLKEY]); - self::assertEquals('test', $_SERVER['_curl'][CURLOPT_SSLKEYPASSWD]); - } - - public function testAddsSslKeyWhenUsingArraySyntaxButNoPassword() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', Server::$url), ['ssl_key' => [__FILE__]]); - - self::assertEquals(__FILE__, $_SERVER['_curl'][CURLOPT_SSLKEY]); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage SSL certificate not found: /does/not/exist - */ - public function testValidatesCert() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', Server::$url), ['cert' => '/does/not/exist']); - } - - public function testAddsCert() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', Server::$url), ['cert' => __FILE__]); - self::assertEquals(__FILE__, $_SERVER['_curl'][CURLOPT_SSLCERT]); - } - - public function testAddsCertWithPassword() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', Server::$url), ['cert' => [__FILE__, 'test']]); - self::assertEquals(__FILE__, $_SERVER['_curl'][CURLOPT_SSLCERT]); - self::assertEquals('test', $_SERVER['_curl'][CURLOPT_SSLCERTPASSWD]); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage progress client option must be callable - */ - public function testValidatesProgress() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', Server::$url), ['progress' => 'foo']); - } - - public function testEmitsDebugInfoToStream() - { - $res = fopen('php://memory', 'r+'); - Server::flush(); - Server::enqueue([new Psr7\Response()]); - $a = new Handler\CurlMultiHandler(); - $response = $a(new Psr7\Request('HEAD', Server::$url), ['debug' => $res]); - $response->wait(); - rewind($res); - $output = str_replace("\r", '', stream_get_contents($res)); - self::assertContains("> HEAD / HTTP/1.1", $output); - self::assertContains("< HTTP/1.1 200", $output); - fclose($res); - } - - public function testEmitsProgressToFunction() - { - Server::flush(); - Server::enqueue([new Psr7\Response()]); - $a = new Handler\CurlMultiHandler(); - $called = []; - $request = new Psr7\Request('HEAD', Server::$url); - $response = $a($request, [ - 'progress' => function () use (&$called) { - $called[] = func_get_args(); - }, - ]); - $response->wait(); - self::assertNotEmpty($called); - foreach ($called as $call) { - self::assertCount(4, $call); - } - } - - private function addDecodeResponse($withEncoding = true) - { - $content = gzencode('test'); - $headers = ['Content-Length' => strlen($content)]; - if ($withEncoding) { - $headers['Content-Encoding'] = 'gzip'; - } - $response = new Psr7\Response(200, $headers, $content); - Server::flush(); - Server::enqueue([$response]); - return $content; - } - - public function testDecodesGzippedResponses() - { - $this->addDecodeResponse(); - $handler = new Handler\CurlMultiHandler(); - $request = new Psr7\Request('GET', Server::$url); - $response = $handler($request, ['decode_content' => true]); - $response = $response->wait(); - self::assertEquals('test', (string) $response->getBody()); - self::assertEquals('', $_SERVER['_curl'][CURLOPT_ENCODING]); - $sent = Server::received()[0]; - self::assertFalse($sent->hasHeader('Accept-Encoding')); - } - - public function testReportsOriginalSizeAndContentEncodingAfterDecoding() - { - $this->addDecodeResponse(); - $handler = new Handler\CurlMultiHandler(); - $request = new Psr7\Request('GET', Server::$url); - $response = $handler($request, ['decode_content' => true]); - $response = $response->wait(); - self::assertSame( - 'gzip', - $response->getHeaderLine('x-encoded-content-encoding') - ); - self::assertSame( - strlen(gzencode('test')), - (int) $response->getHeaderLine('x-encoded-content-length') - ); - } - - public function testDecodesGzippedResponsesWithHeader() - { - $this->addDecodeResponse(); - $handler = new Handler\CurlMultiHandler(); - $request = new Psr7\Request('GET', Server::$url, ['Accept-Encoding' => 'gzip']); - $response = $handler($request, ['decode_content' => true]); - $response = $response->wait(); - self::assertEquals('gzip', $_SERVER['_curl'][CURLOPT_ENCODING]); - $sent = Server::received()[0]; - self::assertEquals('gzip', $sent->getHeaderLine('Accept-Encoding')); - self::assertEquals('test', (string) $response->getBody()); - self::assertFalse($response->hasHeader('content-encoding')); - self::assertTrue( - !$response->hasHeader('content-length') || - $response->getHeaderLine('content-length') == $response->getBody()->getSize() - ); - } - - public function testDoesNotForceDecode() - { - $content = $this->addDecodeResponse(); - $handler = new Handler\CurlMultiHandler(); - $request = new Psr7\Request('GET', Server::$url); - $response = $handler($request, ['decode_content' => false]); - $response = $response->wait(); - $sent = Server::received()[0]; - self::assertFalse($sent->hasHeader('Accept-Encoding')); - self::assertEquals($content, (string) $response->getBody()); - } - - public function testProtocolVersion() - { - Server::flush(); - Server::enqueue([new Psr7\Response()]); - $a = new Handler\CurlMultiHandler(); - $request = new Psr7\Request('GET', Server::$url, [], null, '1.0'); - $a($request, []); - self::assertEquals(CURL_HTTP_VERSION_1_0, $_SERVER['_curl'][CURLOPT_HTTP_VERSION]); - } - - public function testSavesToStream() - { - $stream = fopen('php://memory', 'r+'); - $this->addDecodeResponse(); - $handler = new Handler\CurlMultiHandler(); - $request = new Psr7\Request('GET', Server::$url); - $response = $handler($request, [ - 'decode_content' => true, - 'sink' => $stream, - ]); - $response->wait(); - rewind($stream); - self::assertEquals('test', stream_get_contents($stream)); - } - - public function testSavesToGuzzleStream() - { - $stream = Psr7\stream_for(); - $this->addDecodeResponse(); - $handler = new Handler\CurlMultiHandler(); - $request = new Psr7\Request('GET', Server::$url); - $response = $handler($request, [ - 'decode_content' => true, - 'sink' => $stream, - ]); - $response->wait(); - self::assertEquals('test', (string) $stream); - } - - public function testSavesToFileOnDisk() - { - $tmpfile = tempnam(sys_get_temp_dir(), 'testfile'); - $this->addDecodeResponse(); - $handler = new Handler\CurlMultiHandler(); - $request = new Psr7\Request('GET', Server::$url); - $response = $handler($request, [ - 'decode_content' => true, - 'sink' => $tmpfile, - ]); - $response->wait(); - self::assertStringEqualsFile($tmpfile, 'test'); - unlink($tmpfile); - } - - public function testDoesNotAddMultipleContentLengthHeaders() - { - $this->addDecodeResponse(); - $handler = new Handler\CurlMultiHandler(); - $request = new Psr7\Request('PUT', Server::$url, ['Content-Length' => 3], 'foo'); - $response = $handler($request, []); - $response->wait(); - $sent = Server::received()[0]; - self::assertEquals(3, $sent->getHeaderLine('Content-Length')); - self::assertFalse($sent->hasHeader('Transfer-Encoding')); - self::assertEquals('foo', (string) $sent->getBody()); - } - - public function testSendsPostWithNoBodyOrDefaultContentType() - { - Server::flush(); - Server::enqueue([new Psr7\Response()]); - $handler = new Handler\CurlMultiHandler(); - $request = new Psr7\Request('POST', Server::$url); - $response = $handler($request, []); - $response->wait(); - $received = Server::received()[0]; - self::assertEquals('POST', $received->getMethod()); - self::assertFalse($received->hasHeader('content-type')); - self::assertSame('0', $received->getHeaderLine('content-length')); - } - - /** - * @expectedException \GuzzleHttp\Exception\RequestException - * @expectedExceptionMessage but attempting to rewind the request body failed - */ - public function testFailsWhenCannotRewindRetryAfterNoResponse() - { - $factory = new Handler\CurlFactory(1); - $stream = Psr7\stream_for('abc'); - $stream->read(1); - $stream = new Psr7\NoSeekStream($stream); - $request = new Psr7\Request('PUT', Server::$url, [], $stream); - $fn = function ($request, $options) use (&$fn, $factory) { - $easy = $factory->create($request, $options); - return Handler\CurlFactory::finish($fn, $easy, $factory); - }; - $fn($request, [])->wait(); - } - - public function testRetriesWhenBodyCanBeRewound() - { - $callHandler = $called = false; - - $fn = function ($r, $options) use (&$callHandler) { - $callHandler = true; - return \GuzzleHttp\Promise\promise_for(new Psr7\Response()); - }; - - $bd = Psr7\FnStream::decorate(Psr7\stream_for('test'), [ - 'tell' => function () { - return 1; - }, - 'rewind' => function () use (&$called) { - $called = true; - } - ]); - - $factory = new Handler\CurlFactory(1); - $req = new Psr7\Request('PUT', Server::$url, [], $bd); - $easy = $factory->create($req, []); - $res = Handler\CurlFactory::finish($fn, $easy, $factory); - $res = $res->wait(); - self::assertTrue($callHandler); - self::assertTrue($called); - self::assertEquals('200', $res->getStatusCode()); - } - - /** - * @expectedException \GuzzleHttp\Exception\RequestException - * @expectedExceptionMessage The cURL request was retried 3 times - */ - public function testFailsWhenRetryMoreThanThreeTimes() - { - $factory = new Handler\CurlFactory(1); - $call = 0; - $fn = function ($request, $options) use (&$mock, &$call, $factory) { - $call++; - $easy = $factory->create($request, $options); - return Handler\CurlFactory::finish($mock, $easy, $factory); - }; - $mock = new Handler\MockHandler([$fn, $fn, $fn]); - $p = $mock(new Psr7\Request('PUT', Server::$url, [], 'test'), []); - $p->wait(false); - self::assertEquals(3, $call); - $p->wait(true); - } - - public function testHandles100Continue() - { - Server::flush(); - Server::enqueue([ - new Psr7\Response(200, ['Test' => 'Hello', 'Content-Length' => 4], 'test'), - ]); - $request = new Psr7\Request('PUT', Server::$url, [ - 'Expect' => '100-Continue' - ], 'test'); - $handler = new Handler\CurlMultiHandler(); - $response = $handler($request, [])->wait(); - self::assertSame(200, $response->getStatusCode()); - self::assertSame('OK', $response->getReasonPhrase()); - self::assertSame('Hello', $response->getHeaderLine('Test')); - self::assertSame('4', $response->getHeaderLine('Content-Length')); - self::assertSame('test', (string) $response->getBody()); - } - - /** - * @expectedException \GuzzleHttp\Exception\ConnectException - */ - public function testCreatesConnectException() - { - $m = new \ReflectionMethod(CurlFactory::class, 'finishError'); - $m->setAccessible(true); - $factory = new Handler\CurlFactory(1); - $easy = $factory->create(new Psr7\Request('GET', Server::$url), []); - $easy->errno = CURLE_COULDNT_CONNECT; - $response = $m->invoke( - null, - function () { - }, - $easy, - $factory - ); - $response->wait(); - } - - public function testAddsTimeouts() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', Server::$url), [ - 'timeout' => 0.1, - 'connect_timeout' => 0.2 - ]); - self::assertEquals(100, $_SERVER['_curl'][CURLOPT_TIMEOUT_MS]); - self::assertEquals(200, $_SERVER['_curl'][CURLOPT_CONNECTTIMEOUT_MS]); - } - - public function testAddsStreamingBody() - { - $f = new Handler\CurlFactory(3); - $bd = Psr7\FnStream::decorate(Psr7\stream_for('foo'), [ - 'getSize' => function () { - return null; - } - ]); - $request = new Psr7\Request('PUT', Server::$url, [], $bd); - $f->create($request, []); - self::assertEquals(1, $_SERVER['_curl'][CURLOPT_UPLOAD]); - self::assertInternalType('callable', $_SERVER['_curl'][CURLOPT_READFUNCTION]); - } - - /** - * @expectedException \RuntimeException - * @expectedExceptionMessage Directory /does/not/exist/so does not exist for sink value of /does/not/exist/so/error.txt - */ - public function testEnsuresDirExistsBeforeThrowingWarning() - { - $f = new Handler\CurlFactory(3); - $f->create(new Psr7\Request('GET', Server::$url), [ - 'sink' => '/does/not/exist/so/error.txt' - ]); - } - - public function testClosesIdleHandles() - { - $f = new Handler\CurlFactory(3); - $req = new Psr7\Request('GET', Server::$url); - $easy = $f->create($req, []); - $h1 = $easy->handle; - $f->release($easy); - self::assertCount(1, self::readAttribute($f, 'handles')); - $easy = $f->create($req, []); - self::assertSame($easy->handle, $h1); - $easy2 = $f->create($req, []); - $easy3 = $f->create($req, []); - $easy4 = $f->create($req, []); - $f->release($easy); - self::assertCount(1, self::readAttribute($f, 'handles')); - $f->release($easy2); - self::assertCount(2, self::readAttribute($f, 'handles')); - $f->release($easy3); - self::assertCount(3, self::readAttribute($f, 'handles')); - $f->release($easy4); - self::assertCount(3, self::readAttribute($f, 'handles')); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testEnsuresOnHeadersIsCallable() - { - $req = new Psr7\Request('GET', Server::$url); - $handler = new Handler\CurlHandler(); - $handler($req, ['on_headers' => 'error!']); - } - - /** - * @expectedException \GuzzleHttp\Exception\RequestException - * @expectedExceptionMessage An error was encountered during the on_headers event - * @expectedExceptionMessage test - */ - public function testRejectsPromiseWhenOnHeadersFails() - { - Server::flush(); - Server::enqueue([ - new Psr7\Response(200, ['X-Foo' => 'bar'], 'abc 123') - ]); - $req = new Psr7\Request('GET', Server::$url); - $handler = new Handler\CurlHandler(); - $promise = $handler($req, [ - 'on_headers' => function () { - throw new \Exception('test'); - } - ]); - $promise->wait(); - } - - public function testSuccessfullyCallsOnHeadersBeforeWritingToSink() - { - Server::flush(); - Server::enqueue([ - new Psr7\Response(200, ['X-Foo' => 'bar'], 'abc 123') - ]); - $req = new Psr7\Request('GET', Server::$url); - $got = null; - - $stream = Psr7\stream_for(); - $stream = Psr7\FnStream::decorate($stream, [ - 'write' => function ($data) use ($stream, &$got) { - self::assertNotNull($got); - return $stream->write($data); - } - ]); - - $handler = new Handler\CurlHandler(); - $promise = $handler($req, [ - 'sink' => $stream, - 'on_headers' => function (ResponseInterface $res) use (&$got) { - $got = $res; - self::assertEquals('bar', $res->getHeaderLine('X-Foo')); - } - ]); - - $response = $promise->wait(); - self::assertSame(200, $response->getStatusCode()); - self::assertSame('bar', $response->getHeaderLine('X-Foo')); - self::assertSame('abc 123', (string) $response->getBody()); - } - - public function testInvokesOnStatsOnSuccess() - { - Server::flush(); - Server::enqueue([new Psr7\Response(200)]); - $req = new Psr7\Request('GET', Server::$url); - $gotStats = null; - $handler = new Handler\CurlHandler(); - $promise = $handler($req, [ - 'on_stats' => function (TransferStats $stats) use (&$gotStats) { - $gotStats = $stats; - } - ]); - $response = $promise->wait(); - self::assertSame(200, $response->getStatusCode()); - self::assertSame(200, $gotStats->getResponse()->getStatusCode()); - self::assertSame( - Server::$url, - (string) $gotStats->getEffectiveUri() - ); - self::assertSame( - Server::$url, - (string) $gotStats->getRequest()->getUri() - ); - self::assertGreaterThan(0, $gotStats->getTransferTime()); - self::assertArrayHasKey('appconnect_time', $gotStats->getHandlerStats()); - } - - public function testInvokesOnStatsOnError() - { - $req = new Psr7\Request('GET', 'http://127.0.0.1:123'); - $gotStats = null; - $handler = new Handler\CurlHandler(); - $promise = $handler($req, [ - 'connect_timeout' => 0.001, - 'timeout' => 0.001, - 'on_stats' => function (TransferStats $stats) use (&$gotStats) { - $gotStats = $stats; - } - ]); - $promise->wait(false); - self::assertFalse($gotStats->hasResponse()); - self::assertSame( - 'http://127.0.0.1:123', - (string) $gotStats->getEffectiveUri() - ); - self::assertSame( - 'http://127.0.0.1:123', - (string) $gotStats->getRequest()->getUri() - ); - self::assertInternalType('float', $gotStats->getTransferTime()); - self::assertInternalType('int', $gotStats->getHandlerErrorData()); - self::assertArrayHasKey('appconnect_time', $gotStats->getHandlerStats()); - } - - public function testRewindsBodyIfPossible() - { - $body = Psr7\stream_for(str_repeat('x', 1024 * 1024 * 2)); - $body->seek(1024 * 1024); - self::assertSame(1024 * 1024, $body->tell()); - - $req = new Psr7\Request('POST', 'https://www.example.com', [ - 'Content-Length' => 1024 * 1024 * 2, - ], $body); - $factory = new CurlFactory(1); - $factory->create($req, []); - - self::assertSame(0, $body->tell()); - } - - public function testDoesNotRewindUnseekableBody() - { - $body = Psr7\stream_for(str_repeat('x', 1024 * 1024 * 2)); - $body->seek(1024 * 1024); - $body = new Psr7\NoSeekStream($body); - self::assertSame(1024 * 1024, $body->tell()); - - $req = new Psr7\Request('POST', 'https://www.example.com', [ - 'Content-Length' => 1024 * 1024, - ], $body); - $factory = new CurlFactory(1); - $factory->create($req, []); - - self::assertSame(1024 * 1024, $body->tell()); - } - - public function testRelease() - { - $factory = new CurlFactory(1); - $easyHandle = new EasyHandle(); - $easyHandle->handle = curl_init(); - - self::assertEmpty($factory->release($easyHandle)); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/CurlHandlerTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/CurlHandlerTest.php deleted file mode 100644 index 189a0a96..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/CurlHandlerTest.php +++ /dev/null @@ -1,87 +0,0 @@ - 0.001, 'connect_timeout' => 0.001])->wait(); - } - - public function testReusesHandles() - { - Server::flush(); - $response = new response(200); - Server::enqueue([$response, $response]); - $a = new CurlHandler(); - $request = new Request('GET', Server::$url); - self::assertInstanceOf('GuzzleHttp\Promise\FulfilledPromise', $a($request, [])); - self::assertInstanceOf('GuzzleHttp\Promise\FulfilledPromise', $a($request, [])); - } - - public function testDoesSleep() - { - $response = new response(200); - Server::enqueue([$response]); - $a = new CurlHandler(); - $request = new Request('GET', Server::$url); - $s = Utils::currentTime(); - $a($request, ['delay' => 0.1])->wait(); - self::assertGreaterThan(0.0001, Utils::currentTime() - $s); - } - - public function testCreatesCurlErrorsWithContext() - { - $handler = new CurlHandler(); - $request = new Request('GET', 'http://localhost:123'); - $called = false; - $p = $handler($request, ['timeout' => 0.001, 'connect_timeout' => 0.001]) - ->otherwise(function (ConnectException $e) use (&$called) { - $called = true; - self::assertArrayHasKey('errno', $e->getHandlerContext()); - }); - $p->wait(); - self::assertTrue($called); - } - - public function testUsesContentLengthWhenOverInMemorySize() - { - Server::flush(); - Server::enqueue([new Response()]); - $stream = Psr7\stream_for(str_repeat('.', 1000000)); - $handler = new CurlHandler(); - $request = new Request( - 'PUT', - Server::$url, - ['Content-Length' => 1000000], - $stream - ); - $handler($request, [])->wait(); - $received = Server::received()[0]; - self::assertEquals(1000000, $received->getHeaderLine('Content-Length')); - self::assertFalse($received->hasHeader('Transfer-Encoding')); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/CurlMultiHandlerTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/CurlMultiHandlerTest.php deleted file mode 100644 index 8e2d499a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/CurlMultiHandlerTest.php +++ /dev/null @@ -1,123 +0,0 @@ - [ - CURLMOPT_MAXCONNECTS => 5, - ]]); - $request = new Request('GET', Server::$url); - $a($request, []); - self::assertEquals(5, $_SERVER['_curl_multi'][CURLMOPT_MAXCONNECTS]); - } - - public function testSendsRequest() - { - Server::enqueue([new Response()]); - $a = new CurlMultiHandler(); - $request = new Request('GET', Server::$url); - $response = $a($request, [])->wait(); - self::assertSame(200, $response->getStatusCode()); - } - - /** - * @expectedException \GuzzleHttp\Exception\ConnectException - * @expectedExceptionMessage cURL error - */ - public function testCreatesExceptions() - { - $a = new CurlMultiHandler(); - $a(new Request('GET', 'http://localhost:123'), [])->wait(); - } - - public function testCanSetSelectTimeout() - { - $a = new CurlMultiHandler(['select_timeout' => 2]); - self::assertEquals(2, self::readAttribute($a, 'selectTimeout')); - } - - public function testCanCancel() - { - Server::flush(); - $response = new Response(200); - Server::enqueue(array_fill_keys(range(0, 10), $response)); - $a = new CurlMultiHandler(); - $responses = []; - for ($i = 0; $i < 10; $i++) { - $response = $a(new Request('GET', Server::$url), []); - $response->cancel(); - $responses[] = $response; - } - - foreach ($responses as $r) { - self::assertSame('rejected', $response->getState()); - } - } - - public function testCannotCancelFinished() - { - Server::flush(); - Server::enqueue([new Response(200)]); - $a = new CurlMultiHandler(); - $response = $a(new Request('GET', Server::$url), []); - $response->wait(); - $response->cancel(); - self::assertSame('fulfilled', $response->getState()); - } - - public function testDelaysConcurrently() - { - Server::flush(); - Server::enqueue([new Response()]); - $a = new CurlMultiHandler(); - $expected = Utils::currentTime() + (100 / 1000); - $response = $a(new Request('GET', Server::$url), ['delay' => 100]); - $response->wait(); - self::assertGreaterThanOrEqual($expected, Utils::currentTime()); - } - - public function testUsesTimeoutEnvironmentVariables() - { - $a = new CurlMultiHandler(); - - //default if no options are given and no environment variable is set - self::assertEquals(1, self::readAttribute($a, 'selectTimeout')); - - putenv("GUZZLE_CURL_SELECT_TIMEOUT=3"); - $a = new CurlMultiHandler(); - $selectTimeout = getenv('GUZZLE_CURL_SELECT_TIMEOUT'); - //Handler reads from the environment if no options are given - self::assertEquals($selectTimeout, self::readAttribute($a, 'selectTimeout')); - } - - /** - * @expectedException \BadMethodCallException - */ - public function throwsWhenAccessingInvalidProperty() - { - $h = new CurlMultiHandler(); - $h->foo; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/EasyHandleTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/EasyHandleTest.php deleted file mode 100644 index 18ab8c05..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/EasyHandleTest.php +++ /dev/null @@ -1,23 +0,0 @@ -handle); - $easy->handle; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/MockHandlerTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/MockHandlerTest.php deleted file mode 100644 index b63ee46b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/MockHandlerTest.php +++ /dev/null @@ -1,261 +0,0 @@ -wait()); - } - - public function testIsCountable() - { - $res = new Response(); - $mock = new MockHandler([$res, $res]); - self::assertCount(2, $mock); - } - - public function testEmptyHandlerIsCountable() - { - self::assertCount(0, new MockHandler()); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testEnsuresEachAppendIsValid() - { - $mock = new MockHandler(['a']); - $request = new Request('GET', 'http://example.com'); - $mock($request, []); - } - - public function testCanQueueExceptions() - { - $e = new \Exception('a'); - $mock = new MockHandler([$e]); - $request = new Request('GET', 'http://example.com'); - $p = $mock($request, []); - try { - $p->wait(); - self::fail(); - } catch (\Exception $e2) { - self::assertSame($e, $e2); - } - } - - public function testCanGetLastRequestAndOptions() - { - $res = new Response(); - $mock = new MockHandler([$res]); - $request = new Request('GET', 'http://example.com'); - $mock($request, ['foo' => 'bar']); - self::assertSame($request, $mock->getLastRequest()); - self::assertSame(['foo' => 'bar'], $mock->getLastOptions()); - } - - public function testSinkFilename() - { - $filename = sys_get_temp_dir() . '/mock_test_' . uniqid(); - $res = new Response(200, [], 'TEST CONTENT'); - $mock = new MockHandler([$res]); - $request = new Request('GET', '/'); - $p = $mock($request, ['sink' => $filename]); - $p->wait(); - - self::assertFileExists($filename); - self::assertStringEqualsFile($filename, 'TEST CONTENT'); - - unlink($filename); - } - - public function testSinkResource() - { - $file = tmpfile(); - $meta = stream_get_meta_data($file); - $res = new Response(200, [], 'TEST CONTENT'); - $mock = new MockHandler([$res]); - $request = new Request('GET', '/'); - $p = $mock($request, ['sink' => $file]); - $p->wait(); - - self::assertFileExists($meta['uri']); - self::assertStringEqualsFile($meta['uri'], 'TEST CONTENT'); - } - - public function testSinkStream() - { - $stream = new \GuzzleHttp\Psr7\Stream(tmpfile()); - $res = new Response(200, [], 'TEST CONTENT'); - $mock = new MockHandler([$res]); - $request = new Request('GET', '/'); - $p = $mock($request, ['sink' => $stream]); - $p->wait(); - - self::assertFileExists($stream->getMetadata('uri')); - self::assertStringEqualsFile($stream->getMetadata('uri'), 'TEST CONTENT'); - } - - public function testCanEnqueueCallables() - { - $r = new Response(); - $fn = function ($req, $o) use ($r) { - return $r; - }; - $mock = new MockHandler([$fn]); - $request = new Request('GET', 'http://example.com'); - $p = $mock($request, ['foo' => 'bar']); - self::assertSame($r, $p->wait()); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testEnsuresOnHeadersIsCallable() - { - $res = new Response(); - $mock = new MockHandler([$res]); - $request = new Request('GET', 'http://example.com'); - $mock($request, ['on_headers' => 'error!']); - } - - /** - * @expectedException \GuzzleHttp\Exception\RequestException - * @expectedExceptionMessage An error was encountered during the on_headers event - * @expectedExceptionMessage test - */ - public function testRejectsPromiseWhenOnHeadersFails() - { - $res = new Response(); - $mock = new MockHandler([$res]); - $request = new Request('GET', 'http://example.com'); - $promise = $mock($request, [ - 'on_headers' => function () { - throw new \Exception('test'); - } - ]); - - $promise->wait(); - } - public function testInvokesOnFulfilled() - { - $res = new Response(); - $mock = new MockHandler([$res], function ($v) use (&$c) { - $c = $v; - }); - $request = new Request('GET', 'http://example.com'); - $mock($request, [])->wait(); - self::assertSame($res, $c); - } - - public function testInvokesOnRejected() - { - $e = new \Exception('a'); - $c = null; - $mock = new MockHandler([$e], null, function ($v) use (&$c) { - $c = $v; - }); - $request = new Request('GET', 'http://example.com'); - $mock($request, [])->wait(false); - self::assertSame($e, $c); - } - - /** - * @expectedException \OutOfBoundsException - */ - public function testThrowsWhenNoMoreResponses() - { - $mock = new MockHandler(); - $request = new Request('GET', 'http://example.com'); - $mock($request, []); - } - - /** - * @expectedException \GuzzleHttp\Exception\BadResponseException - */ - public function testCanCreateWithDefaultMiddleware() - { - $r = new Response(500); - $mock = MockHandler::createWithMiddleware([$r]); - $request = new Request('GET', 'http://example.com'); - $mock($request, ['http_errors' => true])->wait(); - } - - public function testInvokesOnStatsFunctionForResponse() - { - $res = new Response(); - $mock = new MockHandler([$res]); - $request = new Request('GET', 'http://example.com'); - /** @var TransferStats|null $stats */ - $stats = null; - $onStats = function (TransferStats $s) use (&$stats) { - $stats = $s; - }; - $p = $mock($request, ['on_stats' => $onStats]); - $p->wait(); - self::assertSame($res, $stats->getResponse()); - self::assertSame($request, $stats->getRequest()); - } - - public function testInvokesOnStatsFunctionForError() - { - $e = new \Exception('a'); - $c = null; - $mock = new MockHandler([$e], null, function ($v) use (&$c) { - $c = $v; - }); - $request = new Request('GET', 'http://example.com'); - - /** @var TransferStats|null $stats */ - $stats = null; - $onStats = function (TransferStats $s) use (&$stats) { - $stats = $s; - }; - $mock($request, ['on_stats' => $onStats])->wait(false); - self::assertSame($e, $stats->getHandlerErrorData()); - self::assertNull($stats->getResponse()); - self::assertSame($request, $stats->getRequest()); - } - - public function testTransferTime() - { - $e = new \Exception('a'); - $c = null; - $mock = new MockHandler([$e], null, function ($v) use (&$c) { - $c = $v; - }); - $request = new Request('GET', 'http://example.com'); - $stats = null; - $onStats = function (TransferStats $s) use (&$stats) { - $stats = $s; - }; - $mock($request, [ 'on_stats' => $onStats, 'transfer_time' => 0.4 ])->wait(false); - self::assertEquals(0.4, $stats->getTransferTime()); - } - - public function testResetQueue() - { - $mock = new MockHandler([new Response(200), new Response(204)]); - self::assertCount(2, $mock); - - $mock->reset(); - self::assertEmpty($mock); - - $mock->append(new Response(500)); - self::assertCount(1, $mock); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/ProxyTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/ProxyTest.php deleted file mode 100644 index c5e8b1e5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/ProxyTest.php +++ /dev/null @@ -1,74 +0,0 @@ - true]); - self::assertNull($a); - self::assertNotNull($b); - } - - public function testSendsToStreaming() - { - $a = $b = null; - $m1 = new MockHandler([function ($v) use (&$a) { - $a = $v; - }]); - $m2 = new MockHandler([function ($v) use (&$b) { - $b = $v; - }]); - $h = Proxy::wrapStreaming($m1, $m2); - $h(new Request('GET', 'http://foo.com'), []); - self::assertNotNull($a); - self::assertNull($b); - } - - public function testSendsToNonStreaming() - { - $a = $b = null; - $m1 = new MockHandler([function ($v) use (&$a) { - $a = $v; - }]); - $m2 = new MockHandler([function ($v) use (&$b) { - $b = $v; - }]); - $h = Proxy::wrapStreaming($m1, $m2); - $h(new Request('GET', 'http://foo.com'), ['stream' => true]); - self::assertNull($a); - self::assertNotNull($b); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/StreamHandlerTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/StreamHandlerTest.php deleted file mode 100644 index 674a4ad7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Handler/StreamHandlerTest.php +++ /dev/null @@ -1,689 +0,0 @@ - 'Bar', - 'Content-Length' => 8, - ], 'hi there') - ]); - } - - public function testReturnsResponseForSuccessfulRequest() - { - $this->queueRes(); - $handler = new StreamHandler(); - $response = $handler( - new Request('GET', Server::$url, ['Foo' => 'Bar']), - [] - )->wait(); - self::assertSame(200, $response->getStatusCode()); - self::assertSame('OK', $response->getReasonPhrase()); - self::assertSame('Bar', $response->getHeaderLine('Foo')); - self::assertSame('8', $response->getHeaderLine('Content-Length')); - self::assertSame('hi there', (string) $response->getBody()); - $sent = Server::received()[0]; - self::assertSame('GET', $sent->getMethod()); - self::assertSame('/', $sent->getUri()->getPath()); - self::assertSame('127.0.0.1:8126', $sent->getHeaderLine('Host')); - self::assertSame('Bar', $sent->getHeaderLine('foo')); - } - - /** - * @expectedException \GuzzleHttp\Exception\RequestException - */ - public function testAddsErrorToResponse() - { - $handler = new StreamHandler(); - $handler( - new Request('GET', 'http://localhost:123'), - ['timeout' => 0.01] - )->wait(); - } - - public function testStreamAttributeKeepsStreamOpen() - { - $this->queueRes(); - $handler = new StreamHandler(); - $request = new Request( - 'PUT', - Server::$url . 'foo?baz=bar', - ['Foo' => 'Bar'], - 'test' - ); - $response = $handler($request, ['stream' => true])->wait(); - self::assertSame(200, $response->getStatusCode()); - self::assertSame('OK', $response->getReasonPhrase()); - self::assertSame('8', $response->getHeaderLine('Content-Length')); - $body = $response->getBody(); - $stream = $body->detach(); - self::assertInternalType('resource', $stream); - self::assertSame('http', stream_get_meta_data($stream)['wrapper_type']); - self::assertSame('hi there', stream_get_contents($stream)); - fclose($stream); - $sent = Server::received()[0]; - self::assertSame('PUT', $sent->getMethod()); - self::assertSame('http://127.0.0.1:8126/foo?baz=bar', (string) $sent->getUri()); - self::assertSame('Bar', $sent->getHeaderLine('Foo')); - self::assertSame('test', (string) $sent->getBody()); - } - - public function testDrainsResponseIntoTempStream() - { - $this->queueRes(); - $handler = new StreamHandler(); - $request = new Request('GET', Server::$url); - $response = $handler($request, [])->wait(); - $body = $response->getBody(); - $stream = $body->detach(); - self::assertSame('php://temp', stream_get_meta_data($stream)['uri']); - self::assertSame('hi', fread($stream, 2)); - fclose($stream); - } - - public function testDrainsResponseIntoSaveToBody() - { - $r = fopen('php://temp', 'r+'); - $this->queueRes(); - $handler = new StreamHandler(); - $request = new Request('GET', Server::$url); - $response = $handler($request, ['sink' => $r])->wait(); - $body = $response->getBody()->detach(); - self::assertSame('php://temp', stream_get_meta_data($body)['uri']); - self::assertSame('hi', fread($body, 2)); - self::assertSame(' there', stream_get_contents($r)); - fclose($r); - } - - public function testDrainsResponseIntoSaveToBodyAtPath() - { - $tmpfname = tempnam('/tmp', 'save_to_path'); - $this->queueRes(); - $handler = new StreamHandler(); - $request = new Request('GET', Server::$url); - $response = $handler($request, ['sink' => $tmpfname])->wait(); - $body = $response->getBody(); - self::assertSame($tmpfname, $body->getMetadata('uri')); - self::assertSame('hi', $body->read(2)); - $body->close(); - unlink($tmpfname); - } - - public function testDrainsResponseIntoSaveToBodyAtNonExistentPath() - { - $tmpfname = tempnam('/tmp', 'save_to_path'); - unlink($tmpfname); - $this->queueRes(); - $handler = new StreamHandler(); - $request = new Request('GET', Server::$url); - $response = $handler($request, ['sink' => $tmpfname])->wait(); - $body = $response->getBody(); - self::assertSame($tmpfname, $body->getMetadata('uri')); - self::assertSame('hi', $body->read(2)); - $body->close(); - unlink($tmpfname); - } - - public function testDrainsResponseAndReadsOnlyContentLengthBytes() - { - Server::flush(); - Server::enqueue([ - new Response(200, [ - 'Foo' => 'Bar', - 'Content-Length' => 8, - ], 'hi there... This has way too much data!') - ]); - $handler = new StreamHandler(); - $request = new Request('GET', Server::$url); - $response = $handler($request, [])->wait(); - $body = $response->getBody(); - $stream = $body->detach(); - self::assertSame('hi there', stream_get_contents($stream)); - fclose($stream); - } - - public function testDoesNotDrainWhenHeadRequest() - { - Server::flush(); - // Say the content-length is 8, but return no response. - Server::enqueue([ - new Response(200, [ - 'Foo' => 'Bar', - 'Content-Length' => 8, - ], '') - ]); - $handler = new StreamHandler(); - $request = new Request('HEAD', Server::$url); - $response = $handler($request, [])->wait(); - $body = $response->getBody(); - $stream = $body->detach(); - self::assertSame('', stream_get_contents($stream)); - fclose($stream); - } - - public function testAutomaticallyDecompressGzip() - { - Server::flush(); - $content = gzencode('test'); - Server::enqueue([ - new Response(200, [ - 'Content-Encoding' => 'gzip', - 'Content-Length' => strlen($content), - ], $content) - ]); - $handler = new StreamHandler(); - $request = new Request('GET', Server::$url); - $response = $handler($request, ['decode_content' => true])->wait(); - self::assertSame('test', (string) $response->getBody()); - self::assertFalse($response->hasHeader('content-encoding')); - self::assertTrue(!$response->hasHeader('content-length') || $response->getHeaderLine('content-length') == $response->getBody()->getSize()); - } - - public function testReportsOriginalSizeAndContentEncodingAfterDecoding() - { - Server::flush(); - $content = gzencode('test'); - Server::enqueue([ - new Response(200, [ - 'Content-Encoding' => 'gzip', - 'Content-Length' => strlen($content), - ], $content) - ]); - $handler = new StreamHandler(); - $request = new Request('GET', Server::$url); - $response = $handler($request, ['decode_content' => true])->wait(); - - self::assertSame( - 'gzip', - $response->getHeaderLine('x-encoded-content-encoding') - ); - self::assertSame( - strlen($content), - (int) $response->getHeaderLine('x-encoded-content-length') - ); - } - - public function testDoesNotForceGzipDecode() - { - Server::flush(); - $content = gzencode('test'); - Server::enqueue([ - new Response(200, [ - 'Content-Encoding' => 'gzip', - 'Content-Length' => strlen($content), - ], $content) - ]); - $handler = new StreamHandler(); - $request = new Request('GET', Server::$url); - $response = $handler($request, ['decode_content' => false])->wait(); - self::assertSame($content, (string) $response->getBody()); - self::assertSame('gzip', $response->getHeaderLine('content-encoding')); - self::assertEquals(strlen($content), $response->getHeaderLine('content-length')); - } - - public function testProtocolVersion() - { - $this->queueRes(); - $handler = new StreamHandler(); - $request = new Request('GET', Server::$url, [], null, '1.0'); - $handler($request, []); - self::assertSame('1.0', Server::received()[0]->getProtocolVersion()); - } - - protected function getSendResult(array $opts) - { - $this->queueRes(); - $handler = new StreamHandler(); - $opts['stream'] = true; - $request = new Request('GET', Server::$url); - return $handler($request, $opts)->wait(); - } - - /** - * @expectedException \GuzzleHttp\Exception\ConnectException - * @expectedExceptionMessage Connection refused - */ - public function testAddsProxy() - { - $this->getSendResult(['proxy' => '127.0.0.1:8125']); - } - - public function testAddsProxyByProtocol() - { - $url = str_replace('http', 'tcp', Server::$url); - // Workaround until #1823 is fixed properly - $url = rtrim($url, '/'); - $res = $this->getSendResult(['proxy' => ['http' => $url]]); - $opts = stream_context_get_options($res->getBody()->detach()); - self::assertSame($url, $opts['http']['proxy']); - } - - public function testAddsProxyButHonorsNoProxy() - { - $url = str_replace('http', 'tcp', Server::$url); - $res = $this->getSendResult(['proxy' => [ - 'http' => $url, - 'no' => ['*'] - ]]); - $opts = stream_context_get_options($res->getBody()->detach()); - self::assertArrayNotHasKey('proxy', $opts['http']); - } - - public function testAddsTimeout() - { - $res = $this->getSendResult(['stream' => true, 'timeout' => 200]); - $opts = stream_context_get_options($res->getBody()->detach()); - self::assertEquals(200, $opts['http']['timeout']); - } - - /** - * @expectedException \GuzzleHttp\Exception\RequestException - * @expectedExceptionMessage SSL CA bundle not found: /does/not/exist - */ - public function testVerifiesVerifyIsValidIfPath() - { - $this->getSendResult(['verify' => '/does/not/exist']); - } - - public function testVerifyCanBeDisabled() - { - $handler = $this->getSendResult(['verify' => false]); - self::assertInstanceOf('GuzzleHttp\Psr7\Response', $handler); - } - - /** - * @expectedException \GuzzleHttp\Exception\RequestException - * @expectedExceptionMessage SSL certificate not found: /does/not/exist - */ - public function testVerifiesCertIfValidPath() - { - $this->getSendResult(['cert' => '/does/not/exist']); - } - - public function testVerifyCanBeSetToPath() - { - $path = $path = \GuzzleHttp\default_ca_bundle(); - $res = $this->getSendResult(['verify' => $path]); - $opts = stream_context_get_options($res->getBody()->detach()); - self::assertTrue($opts['ssl']['verify_peer']); - self::assertTrue($opts['ssl']['verify_peer_name']); - self::assertSame($path, $opts['ssl']['cafile']); - self::assertFileExists($opts['ssl']['cafile']); - } - - public function testUsesSystemDefaultBundle() - { - $path = $path = \GuzzleHttp\default_ca_bundle(); - $res = $this->getSendResult(['verify' => true]); - $opts = stream_context_get_options($res->getBody()->detach()); - if (PHP_VERSION_ID < 50600) { - self::assertSame($path, $opts['ssl']['cafile']); - } else { - self::assertArrayNotHasKey('cafile', $opts['ssl']); - } - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage Invalid verify request option - */ - public function testEnsuresVerifyOptionIsValid() - { - $this->getSendResult(['verify' => 10]); - } - - public function testCanSetPasswordWhenSettingCert() - { - $path = __FILE__; - $res = $this->getSendResult(['cert' => [$path, 'foo']]); - $opts = stream_context_get_options($res->getBody()->detach()); - self::assertSame($path, $opts['ssl']['local_cert']); - self::assertSame('foo', $opts['ssl']['passphrase']); - } - - public function testDebugAttributeWritesToStream() - { - $this->queueRes(); - $f = fopen('php://temp', 'w+'); - $this->getSendResult(['debug' => $f]); - fseek($f, 0); - $contents = stream_get_contents($f); - self::assertContains(' [CONNECT]', $contents); - self::assertContains(' [FILE_SIZE_IS]', $contents); - self::assertContains(' [PROGRESS]', $contents); - } - - public function testDebugAttributeWritesStreamInfoToBuffer() - { - $called = false; - $this->queueRes(); - $buffer = fopen('php://temp', 'r+'); - $this->getSendResult([ - 'progress' => function () use (&$called) { - $called = true; - }, - 'debug' => $buffer, - ]); - fseek($buffer, 0); - $contents = stream_get_contents($buffer); - self::assertContains(' [CONNECT]', $contents); - self::assertContains(' [FILE_SIZE_IS] message: "Content-Length: 8"', $contents); - self::assertContains(' [PROGRESS] bytes_max: "8"', $contents); - self::assertTrue($called); - } - - public function testEmitsProgressInformation() - { - $called = []; - $this->queueRes(); - $this->getSendResult([ - 'progress' => function () use (&$called) { - $called[] = func_get_args(); - }, - ]); - self::assertNotEmpty($called); - self::assertEquals(8, $called[0][0]); - self::assertEquals(0, $called[0][1]); - } - - public function testEmitsProgressInformationAndDebugInformation() - { - $called = []; - $this->queueRes(); - $buffer = fopen('php://memory', 'w+'); - $this->getSendResult([ - 'debug' => $buffer, - 'progress' => function () use (&$called) { - $called[] = func_get_args(); - }, - ]); - self::assertNotEmpty($called); - self::assertEquals(8, $called[0][0]); - self::assertEquals(0, $called[0][1]); - rewind($buffer); - self::assertNotEmpty(stream_get_contents($buffer)); - fclose($buffer); - } - - public function testPerformsShallowMergeOfCustomContextOptions() - { - $res = $this->getSendResult([ - 'stream_context' => [ - 'http' => [ - 'request_fulluri' => true, - 'method' => 'HEAD', - ], - 'socket' => [ - 'bindto' => '127.0.0.1:0', - ], - 'ssl' => [ - 'verify_peer' => false, - ], - ], - ]); - $opts = stream_context_get_options($res->getBody()->detach()); - self::assertSame('HEAD', $opts['http']['method']); - self::assertTrue($opts['http']['request_fulluri']); - self::assertSame('127.0.0.1:0', $opts['socket']['bindto']); - self::assertFalse($opts['ssl']['verify_peer']); - } - - /** - * @expectedException \InvalidArgumentException - * @expectedExceptionMessage stream_context must be an array - */ - public function testEnsuresThatStreamContextIsAnArray() - { - $this->getSendResult(['stream_context' => 'foo']); - } - - public function testDoesNotAddContentTypeByDefault() - { - $this->queueRes(); - $handler = new StreamHandler(); - $request = new Request('PUT', Server::$url, ['Content-Length' => 3], 'foo'); - $handler($request, []); - $req = Server::received()[0]; - self::assertEquals('', $req->getHeaderLine('Content-Type')); - self::assertEquals(3, $req->getHeaderLine('Content-Length')); - } - - public function testAddsContentLengthByDefault() - { - $this->queueRes(); - $handler = new StreamHandler(); - $request = new Request('PUT', Server::$url, [], 'foo'); - $handler($request, []); - $req = Server::received()[0]; - self::assertEquals(3, $req->getHeaderLine('Content-Length')); - } - - public function testAddsContentLengthEvenWhenEmpty() - { - $this->queueRes(); - $handler = new StreamHandler(); - $request = new Request('PUT', Server::$url, [], ''); - $handler($request, []); - $req = Server::received()[0]; - self::assertEquals(0, $req->getHeaderLine('Content-Length')); - } - - public function testSupports100Continue() - { - Server::flush(); - $response = new Response(200, ['Test' => 'Hello', 'Content-Length' => '4'], 'test'); - Server::enqueue([$response]); - $request = new Request('PUT', Server::$url, ['Expect' => '100-Continue'], 'test'); - $handler = new StreamHandler(); - $response = $handler($request, [])->wait(); - self::assertSame(200, $response->getStatusCode()); - self::assertSame('Hello', $response->getHeaderLine('Test')); - self::assertSame('4', $response->getHeaderLine('Content-Length')); - self::assertSame('test', (string) $response->getBody()); - } - - public function testDoesSleep() - { - $response = new response(200); - Server::enqueue([$response]); - $a = new StreamHandler(); - $request = new Request('GET', Server::$url); - $s = Utils::currentTime(); - $a($request, ['delay' => 0.1])->wait(); - self::assertGreaterThan(0.0001, Utils::currentTime() - $s); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testEnsuresOnHeadersIsCallable() - { - $req = new Request('GET', Server::$url); - $handler = new StreamHandler(); - $handler($req, ['on_headers' => 'error!']); - } - - /** - * @expectedException \GuzzleHttp\Exception\RequestException - * @expectedExceptionMessage An error was encountered during the on_headers event - * @expectedExceptionMessage test - */ - public function testRejectsPromiseWhenOnHeadersFails() - { - Server::flush(); - Server::enqueue([ - new Response(200, ['X-Foo' => 'bar'], 'abc 123') - ]); - $req = new Request('GET', Server::$url); - $handler = new StreamHandler(); - $promise = $handler($req, [ - 'on_headers' => function () { - throw new \Exception('test'); - } - ]); - $promise->wait(); - } - - public function testSuccessfullyCallsOnHeadersBeforeWritingToSink() - { - Server::flush(); - Server::enqueue([ - new Response(200, ['X-Foo' => 'bar'], 'abc 123') - ]); - $req = new Request('GET', Server::$url); - $got = null; - - $stream = Psr7\stream_for(); - $stream = FnStream::decorate($stream, [ - 'write' => function ($data) use ($stream, &$got) { - self::assertNotNull($got); - return $stream->write($data); - } - ]); - - $handler = new StreamHandler(); - $promise = $handler($req, [ - 'sink' => $stream, - 'on_headers' => function (ResponseInterface $res) use (&$got) { - $got = $res; - self::assertSame('bar', $res->getHeaderLine('X-Foo')); - } - ]); - - $response = $promise->wait(); - self::assertSame(200, $response->getStatusCode()); - self::assertSame('bar', $response->getHeaderLine('X-Foo')); - self::assertSame('abc 123', (string) $response->getBody()); - } - - public function testInvokesOnStatsOnSuccess() - { - Server::flush(); - Server::enqueue([new Psr7\Response(200)]); - $req = new Psr7\Request('GET', Server::$url); - $gotStats = null; - $handler = new StreamHandler(); - $promise = $handler($req, [ - 'on_stats' => function (TransferStats $stats) use (&$gotStats) { - $gotStats = $stats; - } - ]); - $response = $promise->wait(); - self::assertSame(200, $response->getStatusCode()); - self::assertSame(200, $gotStats->getResponse()->getStatusCode()); - self::assertSame( - Server::$url, - (string) $gotStats->getEffectiveUri() - ); - self::assertSame( - Server::$url, - (string) $gotStats->getRequest()->getUri() - ); - self::assertGreaterThan(0, $gotStats->getTransferTime()); - } - - public function testInvokesOnStatsOnError() - { - $req = new Psr7\Request('GET', 'http://127.0.0.1:123'); - $gotStats = null; - $handler = new StreamHandler(); - $promise = $handler($req, [ - 'connect_timeout' => 0.001, - 'timeout' => 0.001, - 'on_stats' => function (TransferStats $stats) use (&$gotStats) { - $gotStats = $stats; - } - ]); - $promise->wait(false); - self::assertFalse($gotStats->hasResponse()); - self::assertSame( - 'http://127.0.0.1:123', - (string) $gotStats->getEffectiveUri() - ); - self::assertSame( - 'http://127.0.0.1:123', - (string) $gotStats->getRequest()->getUri() - ); - self::assertInternalType('float', $gotStats->getTransferTime()); - self::assertInstanceOf( - ConnectException::class, - $gotStats->getHandlerErrorData() - ); - } - - public function testStreamIgnoresZeroTimeout() - { - Server::flush(); - Server::enqueue([new Psr7\Response(200)]); - $req = new Psr7\Request('GET', Server::$url); - $gotStats = null; - $handler = new StreamHandler(); - $promise = $handler($req, [ - 'connect_timeout' => 10, - 'timeout' => 0 - ]); - $response = $promise->wait(); - self::assertSame(200, $response->getStatusCode()); - } - - public function testDrainsResponseAndReadsAllContentWhenContentLengthIsZero() - { - Server::flush(); - Server::enqueue([ - new Response(200, [ - 'Foo' => 'Bar', - 'Content-Length' => '0', - ], 'hi there... This has a lot of data!') - ]); - $handler = new StreamHandler(); - $request = new Request('GET', Server::$url); - $response = $handler($request, [])->wait(); - $body = $response->getBody(); - $stream = $body->detach(); - self::assertSame('hi there... This has a lot of data!', stream_get_contents($stream)); - fclose($stream); - } - - public function testHonorsReadTimeout() - { - Server::flush(); - $handler = new StreamHandler(); - $response = $handler( - new Request('GET', Server::$url . 'guzzle-server/read-timeout'), - [ - RequestOptions::READ_TIMEOUT => 1, - RequestOptions::STREAM => true, - ] - )->wait(); - self::assertSame(200, $response->getStatusCode()); - self::assertSame('OK', $response->getReasonPhrase()); - $body = $response->getBody()->detach(); - $line = fgets($body); - self::assertSame("sleeping 60 seconds ...\n", $line); - $line = fgets($body); - self::assertFalse($line); - self::assertTrue(stream_get_meta_data($body)['timed_out']); - self::assertFalse(feof($body)); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/HandlerStackTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/HandlerStackTest.php deleted file mode 100644 index af7ba8c3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/HandlerStackTest.php +++ /dev/null @@ -1,214 +0,0 @@ -hasHandler()); - } - - /** - * @doesNotPerformAssertions - */ - public function testCanSetDifferentHandlerAfterConstruction() - { - $f = function () { - }; - $h = new HandlerStack(); - $h->setHandler($f); - $h->resolve(); - } - - /** - * @expectedException \LogicException - */ - public function testEnsuresHandlerIsSet() - { - $h = new HandlerStack(); - $h->resolve(); - } - - public function testPushInOrder() - { - $meths = $this->getFunctions(); - $builder = new HandlerStack(); - $builder->setHandler($meths[1]); - $builder->push($meths[2]); - $builder->push($meths[3]); - $builder->push($meths[4]); - $composed = $builder->resolve(); - self::assertSame('Hello - test123', $composed('test')); - self::assertSame( - [['a', 'test'], ['b', 'test1'], ['c', 'test12']], - $meths[0] - ); - } - - public function testUnshiftsInReverseOrder() - { - $meths = $this->getFunctions(); - $builder = new HandlerStack(); - $builder->setHandler($meths[1]); - $builder->unshift($meths[2]); - $builder->unshift($meths[3]); - $builder->unshift($meths[4]); - $composed = $builder->resolve(); - self::assertSame('Hello - test321', $composed('test')); - self::assertSame( - [['c', 'test'], ['b', 'test3'], ['a', 'test32']], - $meths[0] - ); - } - - public function testCanRemoveMiddlewareByInstance() - { - $meths = $this->getFunctions(); - $builder = new HandlerStack(); - $builder->setHandler($meths[1]); - $builder->push($meths[2]); - $builder->push($meths[2]); - $builder->push($meths[3]); - $builder->push($meths[4]); - $builder->push($meths[2]); - $builder->remove($meths[3]); - $composed = $builder->resolve(); - self::assertSame('Hello - test1131', $composed('test')); - } - - public function testCanPrintMiddleware() - { - $meths = $this->getFunctions(); - $builder = new HandlerStack(); - $builder->setHandler($meths[1]); - $builder->push($meths[2], 'a'); - $builder->push([__CLASS__, 'foo']); - $builder->push([$this, 'bar']); - $builder->push(__CLASS__ . '::' . 'foo'); - $lines = explode("\n", (string) $builder); - self::assertContains("> 4) Name: 'a', Function: callable(", $lines[0]); - self::assertContains("> 3) Name: '', Function: callable(GuzzleHttp\\Tests\\HandlerStackTest::foo)", $lines[1]); - self::assertContains("> 2) Name: '', Function: callable(['GuzzleHttp\\Tests\\HandlerStackTest', 'bar'])", $lines[2]); - self::assertContains("> 1) Name: '', Function: callable(GuzzleHttp\\Tests\\HandlerStackTest::foo)", $lines[3]); - self::assertContains("< 0) Handler: callable(", $lines[4]); - self::assertContains("< 1) Name: '', Function: callable(GuzzleHttp\\Tests\\HandlerStackTest::foo)", $lines[5]); - self::assertContains("< 2) Name: '', Function: callable(['GuzzleHttp\\Tests\\HandlerStackTest', 'bar'])", $lines[6]); - self::assertContains("< 3) Name: '', Function: callable(GuzzleHttp\\Tests\\HandlerStackTest::foo)", $lines[7]); - self::assertContains("< 4) Name: 'a', Function: callable(", $lines[8]); - } - - public function testCanAddBeforeByName() - { - $meths = $this->getFunctions(); - $builder = new HandlerStack(); - $builder->setHandler($meths[1]); - $builder->push($meths[2], 'foo'); - $builder->before('foo', $meths[3], 'baz'); - $builder->before('baz', $meths[4], 'bar'); - $builder->before('baz', $meths[4], 'qux'); - $lines = explode("\n", (string) $builder); - self::assertContains('> 4) Name: \'bar\'', $lines[0]); - self::assertContains('> 3) Name: \'qux\'', $lines[1]); - self::assertContains('> 2) Name: \'baz\'', $lines[2]); - self::assertContains('> 1) Name: \'foo\'', $lines[3]); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testEnsuresHandlerExistsByName() - { - $builder = new HandlerStack(); - $builder->before('foo', function () { - }); - } - - public function testCanAddAfterByName() - { - $meths = $this->getFunctions(); - $builder = new HandlerStack(); - $builder->setHandler($meths[1]); - $builder->push($meths[2], 'a'); - $builder->push($meths[3], 'b'); - $builder->after('a', $meths[4], 'c'); - $builder->after('b', $meths[4], 'd'); - $lines = explode("\n", (string) $builder); - self::assertContains('4) Name: \'a\'', $lines[0]); - self::assertContains('3) Name: \'c\'', $lines[1]); - self::assertContains('2) Name: \'b\'', $lines[2]); - self::assertContains('1) Name: \'d\'', $lines[3]); - } - - public function testPicksUpCookiesFromRedirects() - { - $mock = new MockHandler([ - new Response(301, [ - 'Location' => 'http://foo.com/baz', - 'Set-Cookie' => 'foo=bar; Domain=foo.com' - ]), - new Response(200) - ]); - $handler = HandlerStack::create($mock); - $request = new Request('GET', 'http://foo.com/bar'); - $jar = new CookieJar(); - $response = $handler($request, [ - 'allow_redirects' => true, - 'cookies' => $jar - ])->wait(); - self::assertSame(200, $response->getStatusCode()); - $lastRequest = $mock->getLastRequest(); - self::assertSame('http://foo.com/baz', (string) $lastRequest->getUri()); - self::assertSame('foo=bar', $lastRequest->getHeaderLine('Cookie')); - } - - private function getFunctions() - { - $calls = []; - - $a = function (callable $next) use (&$calls) { - return function ($v) use ($next, &$calls) { - $calls[] = ['a', $v]; - return $next($v . '1'); - }; - }; - - $b = function (callable $next) use (&$calls) { - return function ($v) use ($next, &$calls) { - $calls[] = ['b', $v]; - return $next($v . '2'); - }; - }; - - $c = function (callable $next) use (&$calls) { - return function ($v) use ($next, &$calls) { - $calls[] = ['c', $v]; - return $next($v . '3'); - }; - }; - - $handler = function ($v) { - return 'Hello - ' . $v; - }; - - return [&$calls, $handler, $a, $b, $c]; - } - - public static function foo() - { - } - public function bar() - { - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/InternalUtilsTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/InternalUtilsTest.php deleted file mode 100644 index b465ff04..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/InternalUtilsTest.php +++ /dev/null @@ -1,21 +0,0 @@ -getHost()); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/MessageFormatterTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/MessageFormatterTest.php deleted file mode 100644 index 44d4e5a5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/MessageFormatterTest.php +++ /dev/null @@ -1,93 +0,0 @@ -format($request); - self::assertRegExp($pattern, $result); - } - - public function formatProvider() - { - $request = new Request('PUT', '/', ['x-test' => 'abc'], Psr7\stream_for('foo')); - $response = new Response(200, ['X-Baz' => 'Bar'], Psr7\stream_for('baz')); - $err = new RequestException('Test', $request, $response); - - return [ - ['{request}', [$request], Psr7\str($request)], - ['{response}', [$request, $response], Psr7\str($response)], - ['{request} {response}', [$request, $response], Psr7\str($request) . ' ' . Psr7\str($response)], - // Empty response yields no value - ['{request} {response}', [$request], Psr7\str($request) . ' '], - ['{req_headers}', [$request], "PUT / HTTP/1.1\r\nx-test: abc"], - ['{res_headers}', [$request, $response], "HTTP/1.1 200 OK\r\nX-Baz: Bar"], - ['{res_headers}', [$request], 'NULL'], - ['{req_body}', [$request], 'foo'], - ['{res_body}', [$request, $response], 'baz'], - ['{res_body}', [$request], 'NULL'], - ['{method}', [$request], $request->getMethod()], - ['{url}', [$request], $request->getUri()], - ['{target}', [$request], $request->getRequestTarget()], - ['{req_version}', [$request], $request->getProtocolVersion()], - ['{res_version}', [$request, $response], $response->getProtocolVersion()], - ['{res_version}', [$request], 'NULL'], - ['{host}', [$request], $request->getHeaderLine('Host')], - ['{hostname}', [$request, $response], gethostname()], - ['{hostname}{hostname}', [$request, $response], gethostname() . gethostname()], - ['{code}', [$request, $response], $response->getStatusCode()], - ['{code}', [$request], 'NULL'], - ['{phrase}', [$request, $response], $response->getReasonPhrase()], - ['{phrase}', [$request], 'NULL'], - ['{error}', [$request, $response, $err], 'Test'], - ['{error}', [$request], 'NULL'], - ['{req_header_x-test}', [$request], 'abc'], - ['{req_header_x-not}', [$request], ''], - ['{res_header_X-Baz}', [$request, $response], 'Bar'], - ['{res_header_x-not}', [$request, $response], ''], - ['{res_header_X-Baz}', [$request], 'NULL'], - ]; - } - - /** - * @dataProvider formatProvider - */ - public function testFormatsMessages($template, $args, $result) - { - $f = new MessageFormatter($template); - self::assertSame((string) $result, call_user_func_array([$f, 'format'], $args)); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/MiddlewareTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/MiddlewareTest.php deleted file mode 100644 index b80888e9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/MiddlewareTest.php +++ /dev/null @@ -1,217 +0,0 @@ - (string) new SetCookie([ - 'Name' => 'name', - 'Value' => 'value', - 'Domain' => 'foo.com' - ]) - ]); - } - ] - ); - $f = $m($h); - $f(new Request('GET', 'http://foo.com'), ['cookies' => $jar])->wait(); - self::assertCount(1, $jar); - } - - /** - * @expectedException \GuzzleHttp\Exception\ClientException - */ - public function testThrowsExceptionOnHttpClientError() - { - $m = Middleware::httpErrors(); - $h = new MockHandler([new Response(404)]); - $f = $m($h); - $p = $f(new Request('GET', 'http://foo.com'), ['http_errors' => true]); - self::assertSame('pending', $p->getState()); - $p->wait(); - self::assertSame('rejected', $p->getState()); - } - - /** - * @expectedException \GuzzleHttp\Exception\ServerException - */ - public function testThrowsExceptionOnHttpServerError() - { - $m = Middleware::httpErrors(); - $h = new MockHandler([new Response(500)]); - $f = $m($h); - $p = $f(new Request('GET', 'http://foo.com'), ['http_errors' => true]); - self::assertSame('pending', $p->getState()); - $p->wait(); - self::assertSame('rejected', $p->getState()); - } - - /** - * @dataProvider getHistoryUseCases - */ - public function testTracksHistory($container) - { - $m = Middleware::history($container); - $h = new MockHandler([new Response(200), new Response(201)]); - $f = $m($h); - $p1 = $f(new Request('GET', 'http://foo.com'), ['headers' => ['foo' => 'bar']]); - $p2 = $f(new Request('HEAD', 'http://foo.com'), ['headers' => ['foo' => 'baz']]); - $p1->wait(); - $p2->wait(); - self::assertCount(2, $container); - self::assertSame(200, $container[0]['response']->getStatusCode()); - self::assertSame(201, $container[1]['response']->getStatusCode()); - self::assertSame('GET', $container[0]['request']->getMethod()); - self::assertSame('HEAD', $container[1]['request']->getMethod()); - self::assertSame('bar', $container[0]['options']['headers']['foo']); - self::assertSame('baz', $container[1]['options']['headers']['foo']); - } - - public function getHistoryUseCases() - { - return [ - [[]], // 1. Container is an array - [new \ArrayObject()] // 2. Container is an ArrayObject - ]; - } - - public function testTracksHistoryForFailures() - { - $container = []; - $m = Middleware::history($container); - $request = new Request('GET', 'http://foo.com'); - $h = new MockHandler([new RequestException('error', $request)]); - $f = $m($h); - $f($request, [])->wait(false); - self::assertCount(1, $container); - self::assertSame('GET', $container[0]['request']->getMethod()); - self::assertInstanceOf(RequestException::class, $container[0]['error']); - } - - public function testTapsBeforeAndAfter() - { - $calls = []; - $m = function ($handler) use (&$calls) { - return function ($request, $options) use ($handler, &$calls) { - $calls[] = '2'; - return $handler($request, $options); - }; - }; - - $m2 = Middleware::tap( - function (RequestInterface $request, array $options) use (&$calls) { - $calls[] = '1'; - }, - function (RequestInterface $request, array $options, PromiseInterface $p) use (&$calls) { - $calls[] = '3'; - } - ); - - $h = new MockHandler([new Response()]); - $b = new HandlerStack($h); - $b->push($m2); - $b->push($m); - $comp = $b->resolve(); - $p = $comp(new Request('GET', 'http://foo.com'), []); - self::assertSame('123', implode('', $calls)); - self::assertInstanceOf(PromiseInterface::class, $p); - self::assertSame(200, $p->wait()->getStatusCode()); - } - - public function testMapsRequest() - { - $h = new MockHandler([ - function (RequestInterface $request, array $options) { - self::assertSame('foo', $request->getHeaderLine('Bar')); - return new Response(200); - } - ]); - $stack = new HandlerStack($h); - $stack->push(Middleware::mapRequest(function (RequestInterface $request) { - return $request->withHeader('Bar', 'foo'); - })); - $comp = $stack->resolve(); - $p = $comp(new Request('PUT', 'http://www.google.com'), []); - self::assertInstanceOf(PromiseInterface::class, $p); - } - - public function testMapsResponse() - { - $h = new MockHandler([new Response(200)]); - $stack = new HandlerStack($h); - $stack->push(Middleware::mapResponse(function (ResponseInterface $response) { - return $response->withHeader('Bar', 'foo'); - })); - $comp = $stack->resolve(); - $p = $comp(new Request('PUT', 'http://www.google.com'), []); - $p->wait(); - self::assertSame('foo', $p->wait()->getHeaderLine('Bar')); - } - - public function testLogsRequestsAndResponses() - { - $h = new MockHandler([new Response(200)]); - $stack = new HandlerStack($h); - $logger = new TestLogger(); - $formatter = new MessageFormatter(); - $stack->push(Middleware::log($logger, $formatter)); - $comp = $stack->resolve(); - $p = $comp(new Request('PUT', 'http://www.google.com'), []); - $p->wait(); - self::assertCount(1, $logger->records); - self::assertContains('"PUT / HTTP/1.1" 200', $logger->records[0]['message']); - } - - public function testLogsRequestsAndResponsesCustomLevel() - { - $h = new MockHandler([new Response(200)]); - $stack = new HandlerStack($h); - $logger = new TestLogger(); - $formatter = new MessageFormatter(); - $stack->push(Middleware::log($logger, $formatter, 'debug')); - $comp = $stack->resolve(); - $p = $comp(new Request('PUT', 'http://www.google.com'), []); - $p->wait(); - self::assertCount(1, $logger->records); - self::assertContains('"PUT / HTTP/1.1" 200', $logger->records[0]['message']); - self::assertSame('debug', $logger->records[0]['level']); - } - - public function testLogsRequestsAndErrors() - { - $h = new MockHandler([new Response(404)]); - $stack = new HandlerStack($h); - $logger = new TestLogger(); - $formatter = new MessageFormatter('{code} {error}'); - $stack->push(Middleware::log($logger, $formatter)); - $stack->push(Middleware::httpErrors()); - $comp = $stack->resolve(); - $p = $comp(new Request('PUT', 'http://www.google.com'), ['http_errors' => true]); - $p->wait(false); - self::assertCount(1, $logger->records); - self::assertContains('PUT http://www.google.com', $logger->records[0]['message']); - self::assertContains('404 Not Found', $logger->records[0]['message']); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/PoolTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/PoolTest.php deleted file mode 100644 index 43a0796e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/PoolTest.php +++ /dev/null @@ -1,193 +0,0 @@ -promise()->wait(); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testValidatesEachElement() - { - $c = new Client(); - $requests = ['foo']; - $p = new Pool($c, new \ArrayIterator($requests)); - $p->promise()->wait(); - } - - /** - * @doesNotPerformAssertions - */ - public function testSendsAndRealizesFuture() - { - $c = $this->getClient(); - $p = new Pool($c, [new Request('GET', 'http://example.com')]); - $p->promise()->wait(); - } - - /** - * @doesNotPerformAssertions - */ - public function testExecutesPendingWhenWaiting() - { - $r1 = new Promise(function () use (&$r1) { - $r1->resolve(new Response()); - }); - $r2 = new Promise(function () use (&$r2) { - $r2->resolve(new Response()); - }); - $r3 = new Promise(function () use (&$r3) { - $r3->resolve(new Response()); - }); - $handler = new MockHandler([$r1, $r2, $r3]); - $c = new Client(['handler' => $handler]); - $p = new Pool($c, [ - new Request('GET', 'http://example.com'), - new Request('GET', 'http://example.com'), - new Request('GET', 'http://example.com'), - ], ['pool_size' => 2]); - $p->promise()->wait(); - } - - public function testUsesRequestOptions() - { - $h = []; - $handler = new MockHandler([ - function (RequestInterface $request) use (&$h) { - $h[] = $request; - return new Response(); - } - ]); - $c = new Client(['handler' => $handler]); - $opts = ['options' => ['headers' => ['x-foo' => 'bar']]]; - $p = new Pool($c, [new Request('GET', 'http://example.com')], $opts); - $p->promise()->wait(); - self::assertCount(1, $h); - self::assertTrue($h[0]->hasHeader('x-foo')); - } - - public function testCanProvideCallablesThatReturnResponses() - { - $h = []; - $handler = new MockHandler([ - function (RequestInterface $request) use (&$h) { - $h[] = $request; - return new Response(); - } - ]); - $c = new Client(['handler' => $handler]); - $optHistory = []; - $fn = function (array $opts) use (&$optHistory, $c) { - $optHistory = $opts; - return $c->request('GET', 'http://example.com', $opts); - }; - $opts = ['options' => ['headers' => ['x-foo' => 'bar']]]; - $p = new Pool($c, [$fn], $opts); - $p->promise()->wait(); - self::assertCount(1, $h); - self::assertTrue($h[0]->hasHeader('x-foo')); - } - - public function testBatchesResults() - { - $requests = [ - new Request('GET', 'http://foo.com/200'), - new Request('GET', 'http://foo.com/201'), - new Request('GET', 'http://foo.com/202'), - new Request('GET', 'http://foo.com/404'), - ]; - $fn = function (RequestInterface $request) { - return new Response(substr($request->getUri()->getPath(), 1)); - }; - $mock = new MockHandler([$fn, $fn, $fn, $fn]); - $handler = HandlerStack::create($mock); - $client = new Client(['handler' => $handler]); - $results = Pool::batch($client, $requests); - self::assertCount(4, $results); - self::assertSame([0, 1, 2, 3], array_keys($results)); - self::assertSame(200, $results[0]->getStatusCode()); - self::assertSame(201, $results[1]->getStatusCode()); - self::assertSame(202, $results[2]->getStatusCode()); - self::assertInstanceOf(ClientException::class, $results[3]); - } - - public function testBatchesResultsWithCallbacks() - { - $requests = [ - new Request('GET', 'http://foo.com/200'), - new Request('GET', 'http://foo.com/201') - ]; - $mock = new MockHandler([ - function (RequestInterface $request) { - return new Response(substr($request->getUri()->getPath(), 1)); - } - ]); - $client = new Client(['handler' => $mock]); - $results = Pool::batch($client, $requests, [ - 'fulfilled' => function ($value) use (&$called) { - $called = true; - } - ]); - self::assertCount(2, $results); - self::assertTrue($called); - } - - public function testUsesYieldedKeyInFulfilledCallback() - { - $r1 = new Promise(function () use (&$r1) { - $r1->resolve(new Response()); - }); - $r2 = new Promise(function () use (&$r2) { - $r2->resolve(new Response()); - }); - $r3 = new Promise(function () use (&$r3) { - $r3->resolve(new Response()); - }); - $handler = new MockHandler([$r1, $r2, $r3]); - $c = new Client(['handler' => $handler]); - $keys = []; - $requests = [ - 'request_1' => new Request('GET', 'http://example.com'), - 'request_2' => new Request('GET', 'http://example.com'), - 'request_3' => new Request('GET', 'http://example.com'), - ]; - $p = new Pool($c, $requests, [ - 'pool_size' => 2, - 'fulfilled' => function ($res, $index) use (&$keys) { - $keys[] = $index; - } - ]); - $p->promise()->wait(); - self::assertCount(3, $keys); - self::assertSame($keys, array_keys($requests)); - } - - private function getClient($total = 1) - { - $queue = []; - for ($i = 0; $i < $total; $i++) { - $queue[] = new Response(); - } - $handler = new MockHandler($queue); - return new Client(['handler' => $handler]); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/PrepareBodyMiddlewareTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/PrepareBodyMiddlewareTest.php deleted file mode 100644 index 883c0771..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/PrepareBodyMiddlewareTest.php +++ /dev/null @@ -1,155 +0,0 @@ - 0) { - self::assertEquals($length, $request->getHeaderLine('Content-Length')); - } else { - self::assertFalse($request->hasHeader('Content-Length')); - } - return new Response(200); - } - ]); - $m = Middleware::prepareBody(); - $stack = new HandlerStack($h); - $stack->push($m); - $comp = $stack->resolve(); - $p = $comp(new Request($method, 'http://www.google.com', [], $body), []); - self::assertInstanceOf(PromiseInterface::class, $p); - $response = $p->wait(); - self::assertSame(200, $response->getStatusCode()); - } - - public function testAddsTransferEncodingWhenNoContentLength() - { - $body = FnStream::decorate(Psr7\stream_for('foo'), [ - 'getSize' => function () { - return null; - } - ]); - $h = new MockHandler([ - function (RequestInterface $request) { - self::assertFalse($request->hasHeader('Content-Length')); - self::assertSame('chunked', $request->getHeaderLine('Transfer-Encoding')); - return new Response(200); - } - ]); - $m = Middleware::prepareBody(); - $stack = new HandlerStack($h); - $stack->push($m); - $comp = $stack->resolve(); - $p = $comp(new Request('PUT', 'http://www.google.com', [], $body), []); - self::assertInstanceOf(PromiseInterface::class, $p); - $response = $p->wait(); - self::assertSame(200, $response->getStatusCode()); - } - - public function testAddsContentTypeWhenMissingAndPossible() - { - $bd = Psr7\stream_for(fopen(__DIR__ . '/../composer.json', 'r')); - $h = new MockHandler([ - function (RequestInterface $request) { - self::assertSame('application/json', $request->getHeaderLine('Content-Type')); - self::assertTrue($request->hasHeader('Content-Length')); - return new Response(200); - } - ]); - $m = Middleware::prepareBody(); - $stack = new HandlerStack($h); - $stack->push($m); - $comp = $stack->resolve(); - $p = $comp(new Request('PUT', 'http://www.google.com', [], $bd), []); - self::assertInstanceOf(PromiseInterface::class, $p); - $response = $p->wait(); - self::assertSame(200, $response->getStatusCode()); - } - - public function expectProvider() - { - return [ - [true, ['100-Continue']], - [false, []], - [10, ['100-Continue']], - [500000, []] - ]; - } - - /** - * @dataProvider expectProvider - */ - public function testAddsExpect($value, $result) - { - $bd = Psr7\stream_for(fopen(__DIR__ . '/../composer.json', 'r')); - - $h = new MockHandler([ - function (RequestInterface $request) use ($result) { - self::assertSame($result, $request->getHeader('Expect')); - return new Response(200); - } - ]); - - $m = Middleware::prepareBody(); - $stack = new HandlerStack($h); - $stack->push($m); - $comp = $stack->resolve(); - $p = $comp(new Request('PUT', 'http://www.google.com', [], $bd), [ - 'expect' => $value - ]); - self::assertInstanceOf(PromiseInterface::class, $p); - $response = $p->wait(); - self::assertSame(200, $response->getStatusCode()); - } - - public function testIgnoresIfExpectIsPresent() - { - $bd = Psr7\stream_for(fopen(__DIR__ . '/../composer.json', 'r')); - $h = new MockHandler([ - function (RequestInterface $request) { - self::assertSame(['Foo'], $request->getHeader('Expect')); - return new Response(200); - } - ]); - - $m = Middleware::prepareBody(); - $stack = new HandlerStack($h); - $stack->push($m); - $comp = $stack->resolve(); - $p = $comp( - new Request('PUT', 'http://www.google.com', ['Expect' => 'Foo'], $bd), - ['expect' => true] - ); - self::assertInstanceOf(PromiseInterface::class, $p); - $response = $p->wait(); - self::assertSame(200, $response->getStatusCode()); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/RedirectMiddlewareTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/RedirectMiddlewareTest.php deleted file mode 100644 index 73f333a2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/RedirectMiddlewareTest.php +++ /dev/null @@ -1,439 +0,0 @@ -push(Middleware::redirect()); - $handler = $stack->resolve(); - $request = new Request('GET', 'http://example.com'); - $promise = $handler($request, []); - $response = $promise->wait(); - self::assertSame(200, $response->getStatusCode()); - } - - public function testIgnoresWhenNoLocation() - { - $response = new Response(304); - $stack = new HandlerStack(new MockHandler([$response])); - $stack->push(Middleware::redirect()); - $handler = $stack->resolve(); - $request = new Request('GET', 'http://example.com'); - $promise = $handler($request, []); - $response = $promise->wait(); - self::assertSame(304, $response->getStatusCode()); - } - - public function testRedirectsWithAbsoluteUri() - { - $mock = new MockHandler([ - new Response(302, ['Location' => 'http://test.com']), - new Response(200) - ]); - $stack = new HandlerStack($mock); - $stack->push(Middleware::redirect()); - $handler = $stack->resolve(); - $request = new Request('GET', 'http://example.com?a=b'); - $promise = $handler($request, [ - 'allow_redirects' => ['max' => 2] - ]); - $response = $promise->wait(); - self::assertSame(200, $response->getStatusCode()); - self::assertSame('http://test.com', (string)$mock->getLastRequest()->getUri()); - } - - public function testRedirectsWithRelativeUri() - { - $mock = new MockHandler([ - new Response(302, ['Location' => '/foo']), - new Response(200) - ]); - $stack = new HandlerStack($mock); - $stack->push(Middleware::redirect()); - $handler = $stack->resolve(); - $request = new Request('GET', 'http://example.com?a=b'); - $promise = $handler($request, [ - 'allow_redirects' => ['max' => 2] - ]); - $response = $promise->wait(); - self::assertSame(200, $response->getStatusCode()); - self::assertSame('http://example.com/foo', (string)$mock->getLastRequest()->getUri()); - } - - /** - * @expectedException \GuzzleHttp\Exception\TooManyRedirectsException - * @expectedExceptionMessage Will not follow more than 3 redirects - */ - public function testLimitsToMaxRedirects() - { - $mock = new MockHandler([ - new Response(301, ['Location' => 'http://test.com']), - new Response(302, ['Location' => 'http://test.com']), - new Response(303, ['Location' => 'http://test.com']), - new Response(304, ['Location' => 'http://test.com']) - ]); - $stack = new HandlerStack($mock); - $stack->push(Middleware::redirect()); - $handler = $stack->resolve(); - $request = new Request('GET', 'http://example.com'); - $promise = $handler($request, ['allow_redirects' => ['max' => 3]]); - $promise->wait(); - } - - /** - * @expectedException \GuzzleHttp\Exception\BadResponseException - * @expectedExceptionMessage Redirect URI, - */ - public function testEnsuresProtocolIsValid() - { - $mock = new MockHandler([ - new Response(301, ['Location' => 'ftp://test.com']) - ]); - $stack = new HandlerStack($mock); - $stack->push(Middleware::redirect()); - $handler = $stack->resolve(); - $request = new Request('GET', 'http://example.com'); - $handler($request, ['allow_redirects' => ['max' => 3]])->wait(); - } - - public function testAddsRefererHeader() - { - $mock = new MockHandler([ - new Response(302, ['Location' => 'http://test.com']), - new Response(200) - ]); - $stack = new HandlerStack($mock); - $stack->push(Middleware::redirect()); - $handler = $stack->resolve(); - $request = new Request('GET', 'http://example.com?a=b'); - $promise = $handler($request, [ - 'allow_redirects' => ['max' => 2, 'referer' => true] - ]); - $promise->wait(); - self::assertSame( - 'http://example.com?a=b', - $mock->getLastRequest()->getHeaderLine('Referer') - ); - } - - public function testAddsRefererHeaderButClearsUserInfo() - { - $mock = new MockHandler([ - new Response(302, ['Location' => 'http://test.com']), - new Response(200) - ]); - $stack = new HandlerStack($mock); - $stack->push(Middleware::redirect()); - $handler = $stack->resolve(); - $request = new Request('GET', 'http://foo:bar@example.com?a=b'); - $promise = $handler($request, [ - 'allow_redirects' => ['max' => 2, 'referer' => true] - ]); - $promise->wait(); - self::assertSame( - 'http://example.com?a=b', - $mock->getLastRequest()->getHeaderLine('Referer') - ); - } - - public function testAddsGuzzleRedirectHeader() - { - $mock = new MockHandler([ - new Response(302, ['Location' => 'http://example.com']), - new Response(302, ['Location' => 'http://example.com/foo']), - new Response(302, ['Location' => 'http://example.com/bar']), - new Response(200) - ]); - - $stack = new HandlerStack($mock); - $stack->push(Middleware::redirect()); - $handler = $stack->resolve(); - $request = new Request('GET', 'http://example.com?a=b'); - $promise = $handler($request, [ - 'allow_redirects' => ['track_redirects' => true] - ]); - $response = $promise->wait(true); - self::assertSame( - [ - 'http://example.com', - 'http://example.com/foo', - 'http://example.com/bar', - ], - $response->getHeader(RedirectMiddleware::HISTORY_HEADER) - ); - } - - public function testAddsGuzzleRedirectStatusHeader() - { - $mock = new MockHandler([ - new Response(301, ['Location' => 'http://example.com']), - new Response(302, ['Location' => 'http://example.com/foo']), - new Response(301, ['Location' => 'http://example.com/bar']), - new Response(302, ['Location' => 'http://example.com/baz']), - new Response(200) - ]); - - $stack = new HandlerStack($mock); - $stack->push(Middleware::redirect()); - $handler = $stack->resolve(); - $request = new Request('GET', 'http://example.com?a=b'); - $promise = $handler($request, [ - 'allow_redirects' => ['track_redirects' => true] - ]); - $response = $promise->wait(true); - self::assertSame( - [ - '301', - '302', - '301', - '302', - ], - $response->getHeader(RedirectMiddleware::STATUS_HISTORY_HEADER) - ); - } - - public function testDoesNotAddRefererWhenGoingFromHttpsToHttp() - { - $mock = new MockHandler([ - new Response(302, ['Location' => 'http://test.com']), - new Response(200) - ]); - $stack = new HandlerStack($mock); - $stack->push(Middleware::redirect()); - $handler = $stack->resolve(); - $request = new Request('GET', 'https://example.com?a=b'); - $promise = $handler($request, [ - 'allow_redirects' => ['max' => 2, 'referer' => true] - ]); - $promise->wait(); - self::assertFalse($mock->getLastRequest()->hasHeader('Referer')); - } - - public function testInvokesOnRedirectForRedirects() - { - $mock = new MockHandler([ - new Response(302, ['Location' => 'http://test.com']), - new Response(200) - ]); - $stack = new HandlerStack($mock); - $stack->push(Middleware::redirect()); - $handler = $stack->resolve(); - $request = new Request('GET', 'http://example.com?a=b'); - $call = false; - $promise = $handler($request, [ - 'allow_redirects' => [ - 'max' => 2, - 'on_redirect' => function ($request, $response, $uri) use (&$call) { - self::assertSame(302, $response->getStatusCode()); - self::assertSame('GET', $request->getMethod()); - self::assertSame('http://test.com', (string) $uri); - $call = true; - } - ] - ]); - $promise->wait(); - self::assertTrue($call); - } - - /** - * @testWith ["digest"] - * ["ntlm"] - */ - public function testRemoveCurlAuthorizationOptionsOnRedirectCrossHost($auth) - { - if (!defined('\CURLOPT_HTTPAUTH')) { - self::markTestSkipped('ext-curl is required for this test'); - } - - $mock = new MockHandler([ - new Response(302, ['Location' => 'http://test.com']), - static function (RequestInterface $request, $options) { - self::assertFalse( - isset($options['curl'][\CURLOPT_HTTPAUTH]), - 'curl options still contain CURLOPT_HTTPAUTH entry' - ); - self::assertFalse( - isset($options['curl'][\CURLOPT_USERPWD]), - 'curl options still contain CURLOPT_USERPWD entry' - ); - return new Response(200); - } - ]); - $handler = HandlerStack::create($mock); - $client = new Client(['handler' => $handler]); - $client->get('http://example.com?a=b', ['auth' => ['testuser', 'testpass', $auth]]); - } - - /** - * @testWith ["digest"] - * ["ntlm"] - */ - public function testRemoveCurlAuthorizationOptionsOnRedirectCrossPort($auth) - { - if (!defined('\CURLOPT_HTTPAUTH')) { - self::markTestSkipped('ext-curl is required for this test'); - } - - $mock = new MockHandler([ - new Response(302, ['Location' => 'http://example.com:81/']), - static function (RequestInterface $request, $options) { - self::assertFalse( - isset($options['curl'][\CURLOPT_HTTPAUTH]), - 'curl options still contain CURLOPT_HTTPAUTH entry' - ); - self::assertFalse( - isset($options['curl'][\CURLOPT_USERPWD]), - 'curl options still contain CURLOPT_USERPWD entry' - ); - return new Response(200); - } - ]); - $handler = HandlerStack::create($mock); - $client = new Client(['handler' => $handler]); - $client->get('http://example.com?a=b', ['auth' => ['testuser', 'testpass', $auth]]); - } - - /** - * @testWith ["digest"] - * ["ntlm"] - */ - public function testRemoveCurlAuthorizationOptionsOnRedirectCrossScheme($auth) - { - if (!defined('\CURLOPT_HTTPAUTH')) { - self::markTestSkipped('ext-curl is required for this test'); - } - - $mock = new MockHandler([ - new Response(302, ['Location' => 'http://example.com?a=b']), - static function (RequestInterface $request, $options) { - self::assertFalse( - isset($options['curl'][\CURLOPT_HTTPAUTH]), - 'curl options still contain CURLOPT_HTTPAUTH entry' - ); - self::assertFalse( - isset($options['curl'][\CURLOPT_USERPWD]), - 'curl options still contain CURLOPT_USERPWD entry' - ); - return new Response(200); - } - ]); - $handler = HandlerStack::create($mock); - $client = new Client(['handler' => $handler]); - $client->get('https://example.com?a=b', ['auth' => ['testuser', 'testpass', $auth]]); - } - - /** - * @testWith ["digest"] - * ["ntlm"] - */ - public function testRemoveCurlAuthorizationOptionsOnRedirectCrossSchemeSamePort($auth) - { - if (!defined('\CURLOPT_HTTPAUTH')) { - self::markTestSkipped('ext-curl is required for this test'); - } - - $mock = new MockHandler([ - new Response(302, ['Location' => 'http://example.com:80?a=b']), - static function (RequestInterface $request, $options) { - self::assertFalse( - isset($options['curl'][\CURLOPT_HTTPAUTH]), - 'curl options still contain CURLOPT_HTTPAUTH entry' - ); - self::assertFalse( - isset($options['curl'][\CURLOPT_USERPWD]), - 'curl options still contain CURLOPT_USERPWD entry' - ); - return new Response(200); - } - ]); - $handler = HandlerStack::create($mock); - $client = new Client(['handler' => $handler]); - $client->get('https://example.com?a=b', ['auth' => ['testuser', 'testpass', $auth]]); - } - - /** - * @testWith ["digest"] - * ["ntlm"] - */ - public function testNotRemoveCurlAuthorizationOptionsOnRedirect($auth) - { - if (!defined('\CURLOPT_HTTPAUTH') || !defined('\CURLOPT_USERPWD')) { - self::markTestSkipped('ext-curl is required for this test'); - } - - $mock = new MockHandler([ - new Response(302, ['Location' => 'http://example.com/2']), - static function (RequestInterface $request, $options) { - self::assertTrue( - isset($options['curl'][\CURLOPT_HTTPAUTH]), - 'curl options does not contain expected CURLOPT_HTTPAUTH entry' - ); - self::assertTrue( - isset($options['curl'][\CURLOPT_USERPWD]), - 'curl options does not contain expected CURLOPT_USERPWD entry' - ); - return new Response(200); - } - ]); - $handler = HandlerStack::create($mock); - $client = new Client(['handler' => $handler]); - $client->get('http://example.com?a=b', ['auth' => ['testuser', 'testpass', $auth]]); - } - - public function crossOriginRedirectProvider() - { - return [ - ['http://example.com/123', 'http://example.com/', false], - ['http://example.com/123', 'http://example.com:80/', false], - ['http://example.com:80/123', 'http://example.com/', false], - ['http://example.com:80/123', 'http://example.com:80/', false], - ['http://example.com/123', 'https://example.com/', true], - ['http://example.com/123', 'http://www.example.com/', true], - ['http://example.com/123', 'http://example.com:81/', true], - ['http://example.com:80/123', 'http://example.com:81/', true], - ['https://example.com/123', 'https://example.com/', false], - ['https://example.com/123', 'https://example.com:443/', false], - ['https://example.com:443/123', 'https://example.com/', false], - ['https://example.com:443/123', 'https://example.com:443/', false], - ['https://example.com/123', 'http://example.com/', true], - ['https://example.com/123', 'https://www.example.com/', true], - ['https://example.com/123', 'https://example.com:444/', true], - ['https://example.com:443/123', 'https://example.com:444/', true], - ]; - } - - /** - * @dataProvider crossOriginRedirectProvider - */ - public function testHeadersTreatmentOnRedirect($originalUri, $targetUri, $isCrossOrigin) - { - $mock = new MockHandler([ - new Response(302, ['Location' => $targetUri]), - function (RequestInterface $request) use ($isCrossOrigin) { - self::assertSame(!$isCrossOrigin, $request->hasHeader('Authorization')); - self::assertSame(!$isCrossOrigin, $request->hasHeader('Cookie')); - - return new Response(200); - } - ]); - $handler = HandlerStack::create($mock); - $client = new Client(['handler' => $handler]); - $client->get($originalUri, ['auth' => ['testuser', 'testpass'], 'headers' => ['Cookie' => 'foo=bar']]); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/RetryMiddlewareTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/RetryMiddlewareTest.php deleted file mode 100644 index ed23c32a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/RetryMiddlewareTest.php +++ /dev/null @@ -1,81 +0,0 @@ - $f]); - $p = $c->sendAsync(new Request('GET', 'http://test.com'), []); - $p->wait(); - self::assertCount(3, $calls); - self::assertSame(2, $delayCalls); - self::assertSame(202, $p->wait()->getStatusCode()); - } - - public function testDoesNotRetryWhenDeciderReturnsFalse() - { - $decider = function () { - return false; - }; - $m = Middleware::retry($decider); - $h = new MockHandler([new Response(200)]); - $c = new Client(['handler' => $m($h)]); - $p = $c->sendAsync(new Request('GET', 'http://test.com'), []); - self::assertSame(200, $p->wait()->getStatusCode()); - } - - public function testCanRetryExceptions() - { - $calls = []; - $decider = function ($retries, $request, $response, $error) use (&$calls) { - $calls[] = func_get_args(); - return $error instanceof \Exception; - }; - $m = Middleware::retry($decider); - $h = new MockHandler([new \Exception(), new Response(201)]); - $c = new Client(['handler' => $m($h)]); - $p = $c->sendAsync(new Request('GET', 'http://test.com'), []); - self::assertSame(201, $p->wait()->getStatusCode()); - self::assertCount(2, $calls); - self::assertSame(0, $calls[0][0]); - self::assertNull($calls[0][2]); - self::assertInstanceOf('Exception', $calls[0][3]); - self::assertSame(1, $calls[1][0]); - self::assertInstanceOf(Response::class, $calls[1][2]); - self::assertNull($calls[1][3]); - } - - public function testBackoffCalculateDelay() - { - self::assertSame(0, RetryMiddleware::exponentialDelay(0)); - self::assertSame(1000, RetryMiddleware::exponentialDelay(1)); - self::assertSame(2000, RetryMiddleware::exponentialDelay(2)); - self::assertSame(4000, RetryMiddleware::exponentialDelay(3)); - self::assertSame(8000, RetryMiddleware::exponentialDelay(4)); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Server.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Server.php deleted file mode 100644 index 8d1fcb04..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/Server.php +++ /dev/null @@ -1,174 +0,0 @@ -request('DELETE', 'guzzle-server/requests'); - } - - /** - * Queue an array of responses or a single response on the server. - * - * Any currently queued responses will be overwritten. Subsequent requests - * on the server will return queued responses in FIFO order. - * - * @param array|ResponseInterface $responses A single or array of Responses - * to queue. - * @throws \Exception - */ - public static function enqueue($responses) - { - $data = []; - foreach ((array) $responses as $response) { - if (!($response instanceof ResponseInterface)) { - throw new \Exception('Invalid response given.'); - } - $headers = array_map(function ($h) { - return implode(' ,', $h); - }, $response->getHeaders()); - - $data[] = [ - 'status' => (string) $response->getStatusCode(), - 'reason' => $response->getReasonPhrase(), - 'headers' => $headers, - 'body' => base64_encode((string) $response->getBody()) - ]; - } - - self::getClient()->request('PUT', 'guzzle-server/responses', [ - 'json' => $data - ]); - } - - /** - * Get all of the received requests - * - * @return ResponseInterface[] - * @throws \RuntimeException - */ - public static function received() - { - if (!self::$started) { - return []; - } - - $response = self::getClient()->request('GET', 'guzzle-server/requests'); - $data = json_decode($response->getBody(), true); - - return array_map( - function ($message) { - $uri = $message['uri']; - if (isset($message['query_string'])) { - $uri .= '?' . $message['query_string']; - } - $response = new Psr7\Request( - $message['http_method'], - $uri, - $message['headers'], - $message['body'], - $message['version'] - ); - return $response->withUri( - $response->getUri() - ->withScheme('http') - ->withHost($response->getHeaderLine('host')) - ); - }, - $data - ); - } - - /** - * Stop running the node.js server - */ - public static function stop() - { - if (self::$started) { - self::getClient()->request('DELETE', 'guzzle-server'); - } - - self::$started = false; - } - - public static function wait($maxTries = 5) - { - $tries = 0; - while (!self::isListening() && ++$tries < $maxTries) { - usleep(100000); - } - - if (!self::isListening()) { - throw new \RuntimeException('Unable to contact node.js server'); - } - } - - public static function start() - { - if (self::$started) { - return; - } - - if (!self::isListening()) { - exec('node ' . __DIR__ . '/server.js ' - . self::$port . ' >> /tmp/server.log 2>&1 &'); - self::wait(); - } - - self::$started = true; - } - - private static function isListening() - { - try { - self::getClient()->request('GET', 'guzzle-server/perf', [ - 'connect_timeout' => 5, - 'timeout' => 5 - ]); - return true; - } catch (\Exception $e) { - return false; - } - } - - private static function getClient() - { - if (!self::$client) { - self::$client = new Client([ - 'base_uri' => self::$url, - 'sync' => true, - ]); - } - - return self::$client; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/TransferStatsTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/TransferStatsTest.php deleted file mode 100644 index f8bbe531..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/TransferStatsTest.php +++ /dev/null @@ -1,30 +0,0 @@ - 'bar'] - ); - self::assertSame($request, $stats->getRequest()); - self::assertSame($response, $stats->getResponse()); - self::assertTrue($stats->hasResponse()); - self::assertSame(['foo' => 'bar'], $stats->getHandlerStats()); - self::assertSame('bar', $stats->getHandlerStat('foo')); - self::assertSame($request->getUri(), $stats->getEffectiveUri()); - self::assertEquals(10.5, $stats->getTransferTime()); - self::assertNull($stats->getHandlerErrorData()); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/UriTemplateTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/UriTemplateTest.php deleted file mode 100644 index c06856e9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/UriTemplateTest.php +++ /dev/null @@ -1,202 +0,0 @@ - 'value', - 'hello' => 'Hello World!', - 'empty' => '', - 'path' => '/foo/bar', - 'x' => '1024', - 'y' => '768', - 'null' => null, - 'list' => ['red', 'green', 'blue'], - 'keys' => [ - "semi" => ';', - "dot" => '.', - "comma" => ',' - ], - 'empty_keys' => [], - ]; - - return array_map(function ($t) use ($params) { - $t[] = $params; - return $t; - }, [ - ['foo', 'foo'], - ['{var}', 'value'], - ['{hello}', 'Hello%20World%21'], - ['{+var}', 'value'], - ['{+hello}', 'Hello%20World!'], - ['{+path}/here', '/foo/bar/here'], - ['here?ref={+path}', 'here?ref=/foo/bar'], - ['X{#var}', 'X#value'], - ['X{#hello}', 'X#Hello%20World!'], - ['map?{x,y}', 'map?1024,768'], - ['{x,hello,y}', '1024,Hello%20World%21,768'], - ['{+x,hello,y}', '1024,Hello%20World!,768'], - ['{+path,x}/here', '/foo/bar,1024/here'], - ['{#x,hello,y}', '#1024,Hello%20World!,768'], - ['{#path,x}/here', '#/foo/bar,1024/here'], - ['X{.var}', 'X.value'], - ['X{.x,y}', 'X.1024.768'], - ['{/var}', '/value'], - ['{/var,x}/here', '/value/1024/here'], - ['{;x,y}', ';x=1024;y=768'], - ['{;x,y,empty}', ';x=1024;y=768;empty'], - ['{?x,y}', '?x=1024&y=768'], - ['{?x,y,empty}', '?x=1024&y=768&empty='], - ['?fixed=yes{&x}', '?fixed=yes&x=1024'], - ['{&x,y,empty}', '&x=1024&y=768&empty='], - ['{var:3}', 'val'], - ['{var:30}', 'value'], - ['{list}', 'red,green,blue'], - ['{list*}', 'red,green,blue'], - ['{keys}', 'semi,%3B,dot,.,comma,%2C'], - ['{keys*}', 'semi=%3B,dot=.,comma=%2C'], - ['{+path:6}/here', '/foo/b/here'], - ['{+list}', 'red,green,blue'], - ['{+list*}', 'red,green,blue'], - ['{+keys}', 'semi,;,dot,.,comma,,'], - ['{+keys*}', 'semi=;,dot=.,comma=,'], - ['{#path:6}/here', '#/foo/b/here'], - ['{#list}', '#red,green,blue'], - ['{#list*}', '#red,green,blue'], - ['{#keys}', '#semi,;,dot,.,comma,,'], - ['{#keys*}', '#semi=;,dot=.,comma=,'], - ['X{.var:3}', 'X.val'], - ['X{.list}', 'X.red,green,blue'], - ['X{.list*}', 'X.red.green.blue'], - ['X{.keys}', 'X.semi,%3B,dot,.,comma,%2C'], - ['X{.keys*}', 'X.semi=%3B.dot=..comma=%2C'], - ['{/var:1,var}', '/v/value'], - ['{/list}', '/red,green,blue'], - ['{/list*}', '/red/green/blue'], - ['{/list*,path:4}', '/red/green/blue/%2Ffoo'], - ['{/keys}', '/semi,%3B,dot,.,comma,%2C'], - ['{/keys*}', '/semi=%3B/dot=./comma=%2C'], - ['{;hello:5}', ';hello=Hello'], - ['{;list}', ';list=red,green,blue'], - ['{;list*}', ';list=red;list=green;list=blue'], - ['{;keys}', ';keys=semi,%3B,dot,.,comma,%2C'], - ['{;keys*}', ';semi=%3B;dot=.;comma=%2C'], - ['{?var:3}', '?var=val'], - ['{?list}', '?list=red,green,blue'], - ['{?list*}', '?list=red&list=green&list=blue'], - ['{?keys}', '?keys=semi,%3B,dot,.,comma,%2C'], - ['{?keys*}', '?semi=%3B&dot=.&comma=%2C'], - ['{&var:3}', '&var=val'], - ['{&list}', '&list=red,green,blue'], - ['{&list*}', '&list=red&list=green&list=blue'], - ['{&keys}', '&keys=semi,%3B,dot,.,comma,%2C'], - ['{&keys*}', '&semi=%3B&dot=.&comma=%2C'], - ['{.null}', ''], - ['{.null,var}', '.value'], - ['X{.empty_keys*}', 'X'], - ['X{.empty_keys}', 'X'], - // Test that missing expansions are skipped - ['test{&missing*}', 'test'], - // Test that multiple expansions can be set - ['http://{var}/{var:2}{?keys*}', 'http://value/va?semi=%3B&dot=.&comma=%2C'], - // Test more complex query string stuff - ['http://www.test.com{+path}{?var,keys*}', 'http://www.test.com/foo/bar?var=value&semi=%3B&dot=.&comma=%2C'] - ]); - } - - /** - * @dataProvider templateProvider - */ - public function testExpandsUriTemplates($template, $expansion, $params) - { - $uri = new UriTemplate(); - self::assertSame($expansion, $uri->expand($template, $params)); - } - - public function expressionProvider() - { - return [ - [ - '{+var*}', [ - 'operator' => '+', - 'values' => [ - ['modifier' => '*', 'value' => 'var'] - ] - ], - ], - [ - '{?keys,var,val}', [ - 'operator' => '?', - 'values' => [ - ['value' => 'keys', 'modifier' => ''], - ['value' => 'var', 'modifier' => ''], - ['value' => 'val', 'modifier' => ''] - ] - ], - ], - [ - '{+x,hello,y}', [ - 'operator' => '+', - 'values' => [ - ['value' => 'x', 'modifier' => ''], - ['value' => 'hello', 'modifier' => ''], - ['value' => 'y', 'modifier' => ''] - ] - ] - ] - ]; - } - - /** - * @dataProvider expressionProvider - */ - public function testParsesExpressions($exp, $data) - { - $template = new UriTemplate(); - - // Access the config object - $class = new \ReflectionClass($template); - $method = $class->getMethod('parseExpression'); - $method->setAccessible(true); - - $exp = substr($exp, 1, -1); - self::assertSame($data, $method->invokeArgs($template, [$exp])); - } - - /** - * @ticket https://github.com/guzzle/guzzle/issues/90 - */ - public function testAllowsNestedArrayExpansion() - { - $template = new UriTemplate(); - - $result = $template->expand('http://example.com{+path}{/segments}{?query,data*,foo*}', [ - 'path' => '/foo/bar', - 'segments' => ['one', 'two'], - 'query' => 'test', - 'data' => [ - 'more' => ['fun', 'ice cream'] - ], - 'foo' => [ - 'baz' => [ - 'bar' => 'fizz', - 'test' => 'buzz' - ], - 'bam' => 'boo' - ] - ]); - - self::assertSame('http://example.com/foo/bar/one,two?query=test&more%5B0%5D=fun&more%5B1%5D=ice%20cream&baz%5Bbar%5D=fizz&baz%5Btest%5D=buzz&bam=boo', $result); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/bootstrap.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/bootstrap.php deleted file mode 100644 index 1854520e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/bootstrap.php +++ /dev/null @@ -1,39 +0,0 @@ - '123']) - ); - } - public function noBodyProvider() - { - return [['get'], ['head'], ['delete']]; - } - - public function testProvidesDefaultUserAgent() - { - $ua = GuzzleHttp\default_user_agent(); - self::assertRegExp('#^GuzzleHttp/.+ curl/.+ PHP/.+$#', $ua); - } - - public function typeProvider() - { - return [ - ['foo', 'string(3) "foo"'], - [true, 'bool(true)'], - [false, 'bool(false)'], - [10, 'int(10)'], - [1.0, 'float(1)'], - [new StrClass(), 'object(GuzzleHttp\Test\StrClass)'], - [['foo'], 'array(1)'] - ]; - } - /** - * @dataProvider typeProvider - */ - public function testDescribesType($input, $output) - { - self::assertSame($output, GuzzleHttp\describe_type($input)); - } - - public function testParsesHeadersFromLines() - { - $lines = ['Foo: bar', 'Foo: baz', 'Abc: 123', 'Def: a, b']; - self::assertSame([ - 'Foo' => ['bar', 'baz'], - 'Abc' => ['123'], - 'Def' => ['a, b'], - ], GuzzleHttp\headers_from_lines($lines)); - } - - public function testParsesHeadersFromLinesWithMultipleLines() - { - $lines = ['Foo: bar', 'Foo: baz', 'Foo: 123']; - self::assertSame([ - 'Foo' => ['bar', 'baz', '123'], - ], GuzzleHttp\headers_from_lines($lines)); - } - - public function testReturnsDebugResource() - { - self::assertInternalType('resource', GuzzleHttp\debug_resource()); - } - - public function testProvidesDefaultCaBundler() - { - self::assertFileExists(GuzzleHttp\default_ca_bundle()); - } - - public function noProxyProvider() - { - return [ - ['mit.edu', ['.mit.edu'], false], - ['foo.mit.edu', ['.mit.edu'], true], - ['mit.edu', ['mit.edu'], true], - ['mit.edu', ['baz', 'mit.edu'], true], - ['mit.edu', ['', '', 'mit.edu'], true], - ['mit.edu', ['baz', '*'], true], - ]; - } - - /** - * @dataProvider noproxyProvider - */ - public function testChecksNoProxyList($host, $list, $result) - { - self::assertSame( - $result, - \GuzzleHttp\is_host_in_noproxy($host, $list) - ); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testEnsuresNoProxyCheckHostIsSet() - { - \GuzzleHttp\is_host_in_noproxy('', []); - } - - public function testEncodesJson() - { - self::assertSame('true', \GuzzleHttp\json_encode(true)); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testEncodesJsonAndThrowsOnError() - { - \GuzzleHttp\json_encode("\x99"); - } - - public function testDecodesJson() - { - self::assertTrue(\GuzzleHttp\json_decode('true')); - } - - /** - * @expectedException \InvalidArgumentException - */ - public function testDecodesJsonAndThrowsOnError() - { - \GuzzleHttp\json_decode('{{]]'); - } -} - -final class StrClass -{ - public function __toString() - { - return 'foo'; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/server.js b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/server.js deleted file mode 100644 index f6c336a5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/guzzle/tests/server.js +++ /dev/null @@ -1,250 +0,0 @@ -/** - * Guzzle node.js test server to return queued responses to HTTP requests and - * expose a RESTful API for enqueueing responses and retrieving the requests - * that have been received. - * - * - Delete all requests that have been received: - * > DELETE /guzzle-server/requests - * > Host: 127.0.0.1:8126 - * - * - Enqueue responses - * > PUT /guzzle-server/responses - * > Host: 127.0.0.1:8126 - * > - * > [{'status': 200, 'reason': 'OK', 'headers': {}, 'body': '' }] - * - * - Get the received requests - * > GET /guzzle-server/requests - * > Host: 127.0.0.1:8126 - * - * < HTTP/1.1 200 OK - * < - * < [{'http_method': 'GET', 'uri': '/', 'headers': {}, 'body': 'string'}] - * - * - Attempt access to the secure area - * > GET /secure/by-digest/qop-auth/guzzle-server/requests - * > Host: 127.0.0.1:8126 - * - * < HTTP/1.1 401 Unauthorized - * < WWW-Authenticate: Digest realm="Digest Test", qop="auth", nonce="0796e98e1aeef43141fab2a66bf4521a", algorithm="MD5", stale="false" - * < - * < 401 Unauthorized - * - * - Shutdown the server - * > DELETE /guzzle-server - * > Host: 127.0.0.1:8126 - * - * @package Guzzle PHP - * @license See the LICENSE file that was distributed with this source code. - */ - -var http = require('http'); -var url = require('url'); - -/** - * Guzzle node.js server - * @class - */ -var GuzzleServer = function(port, log) { - - this.port = port; - this.log = log; - this.responses = []; - this.requests = []; - var that = this; - - var md5 = function(input) { - var crypto = require('crypto'); - var hasher = crypto.createHash('md5'); - hasher.update(input); - return hasher.digest('hex'); - }; - - /** - * Node.js HTTP server authentication module. - * - * It is only initialized on demand (by loadAuthentifier). This avoids - * requiring the dependency to http-auth on standard operations, and the - * performance hit at startup. - */ - var auth; - - /** - * Provides authentication handlers (Basic, Digest). - */ - var loadAuthentifier = function(type, options) { - var typeId = type; - if (type == 'digest') { - typeId += '.'+(options && options.qop ? options.qop : 'none'); - } - if (!loadAuthentifier[typeId]) { - if (!auth) { - try { - auth = require('http-auth'); - } catch (e) { - if (e.code == 'MODULE_NOT_FOUND') { - return; - } - } - } - switch (type) { - case 'digest': - var digestParams = { - realm: 'Digest Test', - login: 'me', - password: 'test' - }; - if (options && options.qop) { - digestParams.qop = options.qop; - } - loadAuthentifier[typeId] = auth.digest(digestParams, function(username, callback) { - callback(md5(digestParams.login + ':' + digestParams.realm + ':' + digestParams.password)); - }); - break - } - } - return loadAuthentifier[typeId]; - }; - - var firewallRequest = function(request, req, res, requestHandlerCallback) { - var securedAreaUriParts = request.uri.match(/^\/secure\/by-(digest)(\/qop-([^\/]*))?(\/.*)$/); - if (securedAreaUriParts) { - var authentifier = loadAuthentifier(securedAreaUriParts[1], { qop: securedAreaUriParts[2] }); - if (!authentifier) { - res.writeHead(501, 'HTTP authentication not implemented', { 'Content-Length': 0 }); - res.end(); - return; - } - authentifier.check(req, res, function(req, res) { - req.url = securedAreaUriParts[4]; - requestHandlerCallback(request, req, res); - }); - } else { - requestHandlerCallback(request, req, res); - } - }; - - var controlRequest = function(request, req, res) { - if (req.url == '/guzzle-server/perf') { - res.writeHead(200, 'OK', {'Content-Length': 16}); - res.end('Body of response'); - } else if (req.method == 'DELETE') { - if (req.url == '/guzzle-server/requests') { - // Clear the received requests - that.requests = []; - res.writeHead(200, 'OK', { 'Content-Length': 0 }); - res.end(); - if (that.log) { - console.log('Flushing requests'); - } - } else if (req.url == '/guzzle-server') { - // Shutdown the server - res.writeHead(200, 'OK', { 'Content-Length': 0, 'Connection': 'close' }); - res.end(); - if (that.log) { - console.log('Shutting down'); - } - that.server.close(); - } - } else if (req.method == 'GET') { - if (req.url === '/guzzle-server/requests') { - if (that.log) { - console.log('Sending received requests'); - } - // Get received requests - var body = JSON.stringify(that.requests); - res.writeHead(200, 'OK', { 'Content-Length': body.length }); - res.end(body); - } else if (req.url == '/guzzle-server/read-timeout') { - if (that.log) { - console.log('Sleeping'); - } - res.writeHead(200, 'OK'); - res.write("sleeping 60 seconds ...\n"); - setTimeout(function () { - res.end("slept 60 seconds\n"); - }, 60*1000); - } - } else if (req.method == 'PUT' && req.url == '/guzzle-server/responses') { - if (that.log) { - console.log('Adding responses...'); - } - if (!request.body) { - if (that.log) { - console.log('No response data was provided'); - } - res.writeHead(400, 'NO RESPONSES IN REQUEST', { 'Content-Length': 0 }); - } else { - that.responses = JSON.parse(request.body); - for (var i = 0; i < that.responses.length; i++) { - if (that.responses[i].body) { - that.responses[i].body = Buffer.from(that.responses[i].body, 'base64'); - } - } - if (that.log) { - console.log(that.responses); - } - res.writeHead(200, 'OK', { 'Content-Length': 0 }); - } - res.end(); - } - }; - - var receivedRequest = function(request, req, res) { - if (req.url.indexOf('/guzzle-server') === 0) { - controlRequest(request, req, res); - } else if (req.url.indexOf('/guzzle-server') == -1 && !that.responses.length) { - res.writeHead(500); - res.end('No responses in queue'); - } else { - if (that.log) { - console.log('Returning response from queue and adding request'); - } - that.requests.push(request); - var response = that.responses.shift(); - res.writeHead(response.status, response.reason, response.headers); - res.end(response.body); - } - }; - - this.start = function() { - - that.server = http.createServer(function(req, res) { - - var parts = url.parse(req.url, false); - var request = { - http_method: req.method, - scheme: parts.scheme, - uri: parts.pathname, - query_string: parts.query, - headers: req.headers, - version: req.httpVersion, - body: '' - }; - - // Receive each chunk of the request body - req.addListener('data', function(chunk) { - request.body += chunk; - }); - - // Called when the request completes - req.addListener('end', function() { - firewallRequest(request, req, res, receivedRequest); - }); - }); - - that.server.listen(this.port, '127.0.0.1'); - - if (this.log) { - console.log('Server running at http://127.0.0.1:8126/'); - } - }; -}; - -// Get the port from the arguments -port = process.argv.length >= 3 ? process.argv[2] : 8126; -log = process.argv.length >= 4 ? process.argv[3] : false; - -// Start the server -server = new GuzzleServer(port, log); -server.start(); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/.editorconfig b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/.editorconfig deleted file mode 100644 index 677e36e2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/.editorconfig +++ /dev/null @@ -1,9 +0,0 @@ -root = true - -[*] -charset = utf-8 -end_of_line = lf -indent_size = 4 -indent_style = space -insert_final_newline = true -trim_trailing_whitespace = true diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/.gitattributes b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/.gitattributes deleted file mode 100644 index b72a8a90..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/.gitattributes +++ /dev/null @@ -1,7 +0,0 @@ -/tests export-ignore -.editorconfig export-ignore -.gitattributes export-ignore -.gitignore export-ignore -.travis.yml export-ignore -Makefile export-ignore -phpunit.xml.dist export-ignore diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/.github/workflows/.editorconfig b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/.github/workflows/.editorconfig deleted file mode 100644 index 7bd3346f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/.github/workflows/.editorconfig +++ /dev/null @@ -1,2 +0,0 @@ -[*.yml] -indent_size = 2 diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/.travis.yml b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/.travis.yml deleted file mode 100644 index 77d260ec..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/.travis.yml +++ /dev/null @@ -1,26 +0,0 @@ -language: php - -matrix: - include: - - php: hhvm-3.24 - dist: trusty - - php: 5.4 - dist: trusty - env: COMPOSER_FLAGS="--prefer-stable --prefer-lowest" - - php: 5.4 - dist: trusty - - php: 5.5.9 - dist: trusty - env: COMPOSER_FLAGS="--prefer-stable --prefer-lowest" - fast_finish: true - -before_install: - - if [[ "$TRAVIS_PHP_VERSION" != "hhvm-3.24" ]]; then echo "xdebug.overload_var_dump = 1" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini; fi - - if [[ "$TRAVIS_PHP_VERSION" == "hhvm-3.24" ]]; then travis_retry composer require "phpunit/phpunit:^5.7.27" --dev --no-update -n; fi - -install: - - if [[ "$TRAVIS_PHP_VERSION" != "nightly" ]]; then travis_retry composer update; fi - - if [[ "$TRAVIS_PHP_VERSION" == "nightly" ]]; then travis_retry composer update --ignore-platform-reqs; fi - -script: - - make test diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/Makefile b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/Makefile deleted file mode 100644 index 8b00b43e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/Makefile +++ /dev/null @@ -1,29 +0,0 @@ -all: clean test - -test: - vendor/bin/phpunit $(TEST) - -coverage: - vendor/bin/phpunit --coverage-html=artifacts/coverage $(TEST) - -view-coverage: - open artifacts/coverage/index.html - -check-tag: - $(if $(TAG),,$(error TAG is not defined. Pass via "make tag TAG=4.2.1")) - -tag: check-tag - @echo Tagging $(TAG) - chag update $(TAG) - git commit -a -m '$(TAG) release' - chag tag - @echo "Release has been created. Push using 'make release'" - @echo "Changes made in the release commit" - git diff HEAD~1 HEAD - -release: check-tag - git push origin master - git push origin $(TAG) - -clean: - rm -rf artifacts/* diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/phpunit.xml.dist b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/phpunit.xml.dist deleted file mode 100644 index e2819aa1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/phpunit.xml.dist +++ /dev/null @@ -1,24 +0,0 @@ - - - - - tests/ - tests/Integration - - - tests/Integration - - - - - - src/ - - - diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/AppendStreamTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/AppendStreamTest.php deleted file mode 100644 index 2f3febc0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/AppendStreamTest.php +++ /dev/null @@ -1,213 +0,0 @@ -getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['isReadable']) - ->getMockForAbstractClass(); - $s->expects(self::once()) - ->method('isReadable') - ->will(self::returnValue(false)); - - $this->expectExceptionGuzzle('InvalidArgumentException', 'Each stream must be readable'); - - $a->addStream($s); - } - - public function testValidatesSeekType() - { - $a = new AppendStream(); - - $this->expectExceptionGuzzle('RuntimeException', 'The AppendStream can only seek with SEEK_SET'); - - $a->seek(100, SEEK_CUR); - } - - public function testTriesToRewindOnSeek() - { - $a = new AppendStream(); - $s = $this->getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['isReadable', 'rewind', 'isSeekable']) - ->getMockForAbstractClass(); - $s->expects(self::once()) - ->method('isReadable') - ->will(self::returnValue(true)); - $s->expects(self::once()) - ->method('isSeekable') - ->will(self::returnValue(true)); - $s->expects(self::once()) - ->method('rewind') - ->will(self::throwException(new \RuntimeException())); - $a->addStream($s); - - $this->expectExceptionGuzzle('RuntimeException', 'Unable to seek stream 0 of the AppendStream'); - - $a->seek(10); - } - - public function testSeeksToPositionByReading() - { - $a = new AppendStream([ - Psr7\Utils::streamFor('foo'), - Psr7\Utils::streamFor('bar'), - Psr7\Utils::streamFor('baz'), - ]); - - $a->seek(3); - self::assertSame(3, $a->tell()); - self::assertSame('bar', $a->read(3)); - - $a->seek(6); - self::assertSame(6, $a->tell()); - self::assertSame('baz', $a->read(3)); - } - - public function testDetachWithoutStreams() - { - $s = new AppendStream(); - $s->detach(); - - self::assertSame(0, $s->getSize()); - self::assertTrue($s->eof()); - self::assertTrue($s->isReadable()); - self::assertSame('', (string) $s); - self::assertTrue($s->isSeekable()); - self::assertFalse($s->isWritable()); - } - - public function testDetachesEachStream() - { - $handle = fopen('php://temp', 'r'); - - $s1 = Psr7\Utils::streamFor($handle); - $s2 = Psr7\Utils::streamFor('bar'); - $a = new AppendStream([$s1, $s2]); - - $a->detach(); - - self::assertSame(0, $a->getSize()); - self::assertTrue($a->eof()); - self::assertTrue($a->isReadable()); - self::assertSame('', (string) $a); - self::assertTrue($a->isSeekable()); - self::assertFalse($a->isWritable()); - - self::assertNull($s1->detach()); - $this->assertInternalTypeGuzzle('resource', $handle, 'resource is not closed when detaching'); - fclose($handle); - } - - public function testClosesEachStream() - { - $handle = fopen('php://temp', 'r'); - - $s1 = Psr7\Utils::streamFor($handle); - $s2 = Psr7\Utils::streamFor('bar'); - $a = new AppendStream([$s1, $s2]); - - $a->close(); - - self::assertSame(0, $a->getSize()); - self::assertTrue($a->eof()); - self::assertTrue($a->isReadable()); - self::assertSame('', (string) $a); - self::assertTrue($a->isSeekable()); - self::assertFalse($a->isWritable()); - - self::assertFalse(is_resource($handle)); - } - - public function testIsNotWritable() - { - $a = new AppendStream([Psr7\Utils::streamFor('foo')]); - self::assertFalse($a->isWritable()); - self::assertTrue($a->isSeekable()); - self::assertTrue($a->isReadable()); - - $this->expectExceptionGuzzle('RuntimeException', 'Cannot write to an AppendStream'); - - $a->write('foo'); - } - - public function testDoesNotNeedStreams() - { - $a = new AppendStream(); - self::assertSame('', (string) $a); - } - - public function testCanReadFromMultipleStreams() - { - $a = new AppendStream([ - Psr7\Utils::streamFor('foo'), - Psr7\Utils::streamFor('bar'), - Psr7\Utils::streamFor('baz'), - ]); - self::assertFalse($a->eof()); - self::assertSame(0, $a->tell()); - self::assertSame('foo', $a->read(3)); - self::assertSame('bar', $a->read(3)); - self::assertSame('baz', $a->read(3)); - self::assertSame('', $a->read(1)); - self::assertTrue($a->eof()); - self::assertSame(9, $a->tell()); - self::assertSame('foobarbaz', (string) $a); - } - - public function testCanDetermineSizeFromMultipleStreams() - { - $a = new AppendStream([ - Psr7\Utils::streamFor('foo'), - Psr7\Utils::streamFor('bar') - ]); - self::assertSame(6, $a->getSize()); - - $s = $this->getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['isSeekable', 'isReadable']) - ->getMockForAbstractClass(); - $s->expects(self::once()) - ->method('isSeekable') - ->will(self::returnValue(null)); - $s->expects(self::once()) - ->method('isReadable') - ->will(self::returnValue(true)); - $a->addStream($s); - self::assertNull($a->getSize()); - } - - public function testCatchesExceptionsWhenCastingToString() - { - $s = $this->getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['isSeekable', 'read', 'isReadable', 'eof']) - ->getMockForAbstractClass(); - $s->expects(self::once()) - ->method('isSeekable') - ->will(self::returnValue(true)); - $s->expects(self::once()) - ->method('read') - ->will(self::throwException(new \RuntimeException('foo'))); - $s->expects(self::once()) - ->method('isReadable') - ->will(self::returnValue(true)); - $s->expects(self::any()) - ->method('eof') - ->will(self::returnValue(false)); - $a = new AppendStream([$s]); - self::assertFalse($a->eof()); - self::assertSame('', (string) $a); - } - - public function testReturnsEmptyMetadata() - { - $s = new AppendStream(); - self::assertSame([], $s->getMetadata()); - self::assertNull($s->getMetadata('foo')); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/BaseTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/BaseTest.php deleted file mode 100644 index f0ad99c5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/BaseTest.php +++ /dev/null @@ -1,139 +0,0 @@ -setExpectedException($exception, $message); - } else { - $this->expectException($exception); - if (null !== $message) { - $this->expectExceptionMessage($message); - } - } - } - - public function expectWarningGuzzle() - { - if (method_exists($this, 'expectWarning')) { - $this->expectWarning(); - } elseif (class_exists('PHPUnit\Framework\Error\Warning')) { - $this->expectExceptionGuzzle('PHPUnit\Framework\Error\Warning'); - } else { - $this->expectExceptionGuzzle('PHPUnit_Framework_Error_Warning'); - } - } - - /** - * @param string $type - * @param mixed $input - */ - public function assertInternalTypeGuzzle($type, $input) - { - switch ($type) { - case 'array': - if (method_exists($this, 'assertIsArray')) { - self::assertIsArray($input); - } else { - self::assertInternalType('array', $input); - } - break; - case 'bool': - case 'boolean': - if (method_exists($this, 'assertIsBool')) { - self::assertIsBool($input); - } else { - self::assertInternalType('bool', $input); - } - break; - case 'double': - case 'float': - case 'real': - if (method_exists($this, 'assertIsFloat')) { - self::assertIsFloat($input); - } else { - self::assertInternalType('float', $input); - } - break; - case 'int': - case 'integer': - if (method_exists($this, 'assertIsInt')) { - self::assertIsInt($input); - } else { - self::assertInternalType('int', $input); - } - break; - case 'numeric': - if (method_exists($this, 'assertIsNumeric')) { - self::assertIsNumeric($input); - } else { - self::assertInternalType('numeric', $input); - } - break; - case 'object': - if (method_exists($this, 'assertIsObject')) { - self::assertIsObject($input); - } else { - self::assertInternalType('object', $input); - } - break; - case 'resource': - if (method_exists($this, 'assertIsResource')) { - self::assertIsResource($input); - } else { - self::assertInternalType('resource', $input); - } - break; - case 'string': - if (method_exists($this, 'assertIsString')) { - self::assertIsString($input); - } else { - self::assertInternalType('string', $input); - } - break; - case 'scalar': - if (method_exists($this, 'assertIsScalar')) { - self::assertIsScalar($input); - } else { - self::assertInternalType('scalar', $input); - } - break; - case 'callable': - if (method_exists($this, 'assertIsCallable')) { - self::assertIsCallable($input); - } else { - self::assertInternalType('callable', $input); - } - break; - case 'iterable': - if (method_exists($this, 'assertIsIterable')) { - self::assertIsIterable($input); - } else { - self::assertInternalType('iterable', $input); - } - break; - } - } - - /** - * @param string $needle - * @param string $haystack - */ - public function assertStringContainsStringGuzzle($needle, $haystack) - { - if (method_exists($this, 'assertStringContainsString')) { - self::assertStringContainsString($needle, $haystack); - } else { - self::assertContains($needle, $haystack); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/BufferStreamTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/BufferStreamTest.php deleted file mode 100644 index 804a4260..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/BufferStreamTest.php +++ /dev/null @@ -1,63 +0,0 @@ -isReadable()); - self::assertTrue($b->isWritable()); - self::assertFalse($b->isSeekable()); - self::assertSame(null, $b->getMetadata('foo')); - self::assertSame(10, $b->getMetadata('hwm')); - self::assertSame([], $b->getMetadata()); - } - - public function testRemovesReadDataFromBuffer() - { - $b = new BufferStream(); - self::assertSame(3, $b->write('foo')); - self::assertSame(3, $b->getSize()); - self::assertFalse($b->eof()); - self::assertSame('foo', $b->read(10)); - self::assertTrue($b->eof()); - self::assertSame('', $b->read(10)); - } - - public function testCanCastToStringOrGetContents() - { - $b = new BufferStream(); - $b->write('foo'); - $b->write('baz'); - self::assertSame('foo', $b->read(3)); - $b->write('bar'); - self::assertSame('bazbar', (string) $b); - - $this->expectExceptionGuzzle('RuntimeException', 'Cannot determine the position of a BufferStream'); - - $b->tell(); - } - - public function testDetachClearsBuffer() - { - $b = new BufferStream(); - $b->write('foo'); - $b->detach(); - self::assertTrue($b->eof()); - self::assertSame(3, $b->write('abc')); - self::assertSame('abc', $b->read(10)); - } - - public function testExceedingHighwaterMarkReturnsFalseButStillBuffers() - { - $b = new BufferStream(5); - self::assertSame(3, $b->write('hi ')); - self::assertFalse($b->write('hello')); - self::assertSame('hi hello', (string) $b); - self::assertSame(4, $b->write('test')); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/CachingStreamTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/CachingStreamTest.php deleted file mode 100644 index a1fa04ae..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/CachingStreamTest.php +++ /dev/null @@ -1,212 +0,0 @@ -decorated = Psr7\Utils::streamFor('testing'); - $this->body = new CachingStream($this->decorated); - } - - /** - * @after - */ - public function tearDownTest() - { - $this->decorated->close(); - $this->body->close(); - } - - public function testUsesRemoteSizeIfAvailable() - { - $body = Psr7\Utils::streamFor('test'); - $caching = new CachingStream($body); - self::assertSame(4, $caching->getSize()); - } - - public function testUsesRemoteSizeIfNotAvailable() - { - $body = new Psr7\PumpStream(function () { - return 'a'; - }); - $caching = new CachingStream($body); - self::assertNull($caching->getSize()); - } - - public function testReadsUntilCachedToByte() - { - $this->body->seek(5); - self::assertSame('n', $this->body->read(1)); - $this->body->seek(0); - self::assertSame('t', $this->body->read(1)); - } - - public function testCanSeekNearEndWithSeekEnd() - { - $baseStream = Psr7\Utils::streamFor(implode('', range('a', 'z'))); - $cached = new CachingStream($baseStream); - $cached->seek(-1, SEEK_END); - self::assertSame(25, $baseStream->tell()); - self::assertSame('z', $cached->read(1)); - self::assertSame(26, $cached->getSize()); - } - - public function testCanSeekToEndWithSeekEnd() - { - $baseStream = Psr7\Utils::streamFor(implode('', range('a', 'z'))); - $cached = new CachingStream($baseStream); - $cached->seek(0, SEEK_END); - self::assertSame(26, $baseStream->tell()); - self::assertSame('', $cached->read(1)); - self::assertSame(26, $cached->getSize()); - } - - public function testCanUseSeekEndWithUnknownSize() - { - $baseStream = Psr7\Utils::streamFor('testing'); - $decorated = Psr7\FnStream::decorate($baseStream, [ - 'getSize' => function () { - return null; - } - ]); - $cached = new CachingStream($decorated); - $cached->seek(-1, SEEK_END); - self::assertSame('g', $cached->read(1)); - } - - public function testRewindUsesSeek() - { - $a = Psr7\Utils::streamFor('foo'); - $d = $this->getMockBuilder('GuzzleHttp\Psr7\CachingStream') - ->setMethods(['seek']) - ->setConstructorArgs([$a]) - ->getMock(); - $d->expects(self::once()) - ->method('seek') - ->with(0) - ->will(self::returnValue(true)); - $d->seek(0); - } - - public function testCanSeekToReadBytes() - { - self::assertSame('te', $this->body->read(2)); - $this->body->seek(0); - self::assertSame('test', $this->body->read(4)); - self::assertSame(4, $this->body->tell()); - $this->body->seek(2); - self::assertSame(2, $this->body->tell()); - $this->body->seek(2, SEEK_CUR); - self::assertSame(4, $this->body->tell()); - self::assertSame('ing', $this->body->read(3)); - } - - public function testCanSeekToReadBytesWithPartialBodyReturned() - { - $stream = fopen('php://temp', 'r+'); - fwrite($stream, 'testing'); - fseek($stream, 0); - - $this->decorated = $this->getMockBuilder('\GuzzleHttp\Psr7\Stream') - ->setConstructorArgs([$stream]) - ->setMethods(['read']) - ->getMock(); - - $this->decorated->expects(self::exactly(2)) - ->method('read') - ->willReturnCallback(function ($length) use ($stream) { - return fread($stream, 2); - }); - - $this->body = new CachingStream($this->decorated); - - self::assertSame(0, $this->body->tell()); - $this->body->seek(4, SEEK_SET); - self::assertSame(4, $this->body->tell()); - - $this->body->seek(0); - self::assertSame('test', $this->body->read(4)); - } - - public function testWritesToBufferStream() - { - $this->body->read(2); - $this->body->write('hi'); - $this->body->seek(0); - self::assertSame('tehiing', (string) $this->body); - } - - public function testSkipsOverwrittenBytes() - { - $decorated = Psr7\Utils::streamFor( - implode("\n", array_map(function ($n) { - return str_pad($n, 4, '0', STR_PAD_LEFT); - }, range(0, 25))) - ); - - $body = new CachingStream($decorated); - - self::assertSame("0000\n", Psr7\Utils::readLine($body)); - self::assertSame("0001\n", Psr7\Utils::readLine($body)); - // Write over part of the body yet to be read, so skip some bytes - self::assertSame(5, $body->write("TEST\n")); - self::assertSame(5, Helpers::readObjectAttribute($body, 'skipReadBytes')); - // Read, which skips bytes, then reads - self::assertSame("0003\n", Psr7\Utils::readLine($body)); - self::assertSame(0, Helpers::readObjectAttribute($body, 'skipReadBytes')); - self::assertSame("0004\n", Psr7\Utils::readLine($body)); - self::assertSame("0005\n", Psr7\Utils::readLine($body)); - - // Overwrite part of the cached body (so don't skip any bytes) - $body->seek(5); - self::assertSame(5, $body->write("ABCD\n")); - self::assertSame(0, Helpers::readObjectAttribute($body, 'skipReadBytes')); - self::assertSame("TEST\n", Psr7\Utils::readLine($body)); - self::assertSame("0003\n", Psr7\Utils::readLine($body)); - self::assertSame("0004\n", Psr7\Utils::readLine($body)); - self::assertSame("0005\n", Psr7\Utils::readLine($body)); - self::assertSame("0006\n", Psr7\Utils::readLine($body)); - self::assertSame(5, $body->write("1234\n")); - self::assertSame(5, Helpers::readObjectAttribute($body, 'skipReadBytes')); - - // Seek to 0 and ensure the overwritten bit is replaced - $body->seek(0); - self::assertSame("0000\nABCD\nTEST\n0003\n0004\n0005\n0006\n1234\n0008\n0009\n", $body->read(50)); - - // Ensure that casting it to a string does not include the bit that was overwritten - $this->assertStringContainsStringGuzzle("0000\nABCD\nTEST\n0003\n0004\n0005\n0006\n1234\n0008\n0009\n", (string) $body); - } - - public function testClosesBothStreams() - { - $s = fopen('php://temp', 'r'); - $a = Psr7\Utils::streamFor($s); - $d = new CachingStream($a); - $d->close(); - self::assertFalse(is_resource($s)); - } - - public function testEnsuresValidWhence() - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - - $this->body->seek(10, -123456); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/DroppingStreamTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/DroppingStreamTest.php deleted file mode 100644 index 15dd3015..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/DroppingStreamTest.php +++ /dev/null @@ -1,27 +0,0 @@ -write('hel')); - self::assertSame(2, $drop->write('lo')); - self::assertSame(5, $drop->getSize()); - self::assertSame('hello', $drop->read(5)); - self::assertSame(0, $drop->getSize()); - $drop->write('12345678910'); - self::assertSame(5, $stream->getSize()); - self::assertSame(5, $drop->getSize()); - self::assertSame('12345', (string) $drop); - self::assertSame(0, $drop->getSize()); - $drop->write('hello'); - self::assertSame(0, $drop->write('test')); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/FnStreamTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/FnStreamTest.php deleted file mode 100644 index 530a8161..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/FnStreamTest.php +++ /dev/null @@ -1,98 +0,0 @@ -expectExceptionGuzzle('BadMethodCallException', 'seek() is not implemented in the FnStream'); - - (new FnStream([]))->seek(1); - } - - public function testProxiesToFunction() - { - $s = new FnStream([ - 'read' => function ($len) { - $this->assertSame(3, $len); - return 'foo'; - } - ]); - - self::assertSame('foo', $s->read(3)); - } - - public function testCanCloseOnDestruct() - { - $called = false; - $s = new FnStream([ - 'close' => function () use (&$called) { - $called = true; - } - ]); - unset($s); - self::assertTrue($called); - } - - public function testDoesNotRequireClose() - { - $s = new FnStream([]); - unset($s); - self::assertTrue(true); // strict mode requires an assertion - } - - public function testDecoratesStream() - { - $a = Psr7\Utils::streamFor('foo'); - $b = FnStream::decorate($a, []); - self::assertSame(3, $b->getSize()); - self::assertSame($b->isWritable(), true); - self::assertSame($b->isReadable(), true); - self::assertSame($b->isSeekable(), true); - self::assertSame($b->read(3), 'foo'); - self::assertSame($b->tell(), 3); - self::assertSame($a->tell(), 3); - self::assertSame('', $a->read(1)); - self::assertSame($b->eof(), true); - self::assertSame($a->eof(), true); - $b->seek(0); - self::assertSame('foo', (string) $b); - $b->seek(0); - self::assertSame('foo', $b->getContents()); - self::assertSame($a->getMetadata(), $b->getMetadata()); - $b->seek(0, SEEK_END); - $b->write('bar'); - self::assertSame('foobar', (string) $b); - $this->assertInternalTypeGuzzle('resource', $b->detach()); - $b->close(); - } - - public function testDecoratesWithCustomizations() - { - $called = false; - $a = Psr7\Utils::streamFor('foo'); - $b = FnStream::decorate($a, [ - 'read' => function ($len) use (&$called, $a) { - $called = true; - return $a->read($len); - } - ]); - self::assertSame('foo', $b->read(3)); - self::assertTrue($called); - } - - public function testDoNotAllowUnserialization() - { - $a = new FnStream([]); - $b = serialize($a); - $this->expectExceptionGuzzle('\LogicException', 'FnStream should never be unserialized'); - unserialize($b); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/HasToString.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/HasToString.php deleted file mode 100644 index 7a9d7374..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/HasToString.php +++ /dev/null @@ -1,11 +0,0 @@ -', - 'rel' => 'front', - 'type' => 'image/jpeg', - ], - [ - '', - 'rel' => 'back', - 'type' => 'image/jpeg', - ], - ]; - return [ - [ - '; rel="front"; type="image/jpeg", ; rel=back; type="image/jpeg"', - $res1, - ], - [ - '; rel="front"; type="image/jpeg",; rel=back; type="image/jpeg"', - $res1, - ], - [ - 'foo="baz"; bar=123, boo, test="123", foobar="foo;bar"', - [ - ['foo' => 'baz', 'bar' => '123'], - ['boo'], - ['test' => '123'], - ['foobar' => 'foo;bar'], - ], - ], - [ - '; rel="side"; type="image/jpeg",; rel=side; type="image/jpeg"', - [ - ['', 'rel' => 'side', 'type' => 'image/jpeg'], - ['', 'rel' => 'side', 'type' => 'image/jpeg'], - ], - ], - [ - '', - [], - ], - ]; - } - - /** - * @dataProvider parseParamsProvider - */ - public function testParseParams($header, $result) - { - self::assertSame($result, Psr7\Header::parse($header)); - } - - public function testParsesArrayHeaders() - { - $header = ['a, b', 'c', 'd, e']; - self::assertSame(['a', 'b', 'c', 'd', 'e'], Psr7\Header::normalize($header)); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/Helpers.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/Helpers.php deleted file mode 100644 index 6ff31a69..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/Helpers.php +++ /dev/null @@ -1,35 +0,0 @@ -getProperty($attributeName); - - if (!$attribute || $attribute->isPublic()) { - return $object->$attributeName; - } - - $attribute->setAccessible(true); - - return $attribute->getValue($object); - } catch (\ReflectionException $e) { - // do nothing - } - } while ($reflector = $reflector->getParentClass()); - - throw new \Exception( - sprintf('Attribute "%s" not found in object.', $attributeName) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/InflateStreamTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/InflateStreamTest.php deleted file mode 100644 index a97b2874..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/InflateStreamTest.php +++ /dev/null @@ -1,51 +0,0 @@ -getGzipStringWithFilename('test'); - $a = Psr7\Utils::streamFor($content); - $b = new InflateStream($a); - self::assertSame('test', (string) $b); - } - - public function testInflatesStreamsPreserveSeekable() - { - $content = $this->getGzipStringWithFilename('test'); - $seekable = Psr7\Utils::streamFor($content); - $nonSeekable = new NoSeekStream(Psr7\Utils::streamFor($content)); - - self::assertTrue((new InflateStream($seekable))->isSeekable()); - self::assertFalse((new InflateStream($nonSeekable))->isSeekable()); - } - - private function getGzipStringWithFilename($original_string) - { - $gzipped = bin2hex(gzencode($original_string)); - - $header = substr($gzipped, 0, 20); - // set FNAME flag - $header[6]=0; - $header[7]=8; - // make a dummy filename - $filename = '64756d6d7900'; - $rest = substr($gzipped, 20); - - return hex2bin($header . $filename . $rest); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/Integration/ServerRequestFromGlobalsTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/Integration/ServerRequestFromGlobalsTest.php deleted file mode 100644 index ff95b73e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/Integration/ServerRequestFromGlobalsTest.php +++ /dev/null @@ -1,45 +0,0 @@ -getServerUri()) { - self::markTestSkipped(); - } - parent::setUp(); - } - - public function testBodyExists() - { - $curl = curl_init(); - - curl_setopt($curl, CURLOPT_URL, $this->getServerUri()); - curl_setopt($curl, CURLOPT_POST, 1); - curl_setopt($curl, CURLOPT_POSTFIELDS, 'foobar'); - curl_setopt($curl, CURLOPT_RETURNTRANSFER, true); - $response = curl_exec($curl); - curl_close($curl); - - self::assertNotFalse($response); - $data = json_decode($response, true); - self::assertIsArray($data); - self::assertArrayHasKey('method', $data); - self::assertArrayHasKey('uri', $data); - self::assertArrayHasKey('body', $data); - - self::assertEquals('foobar', $data['body']); - } - - private function getServerUri() - { - return isset($_SERVER['TEST_SERVER']) ? $_SERVER['TEST_SERVER'] : false; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/Integration/server.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/Integration/server.php deleted file mode 100644 index 9539e626..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/Integration/server.php +++ /dev/null @@ -1,13 +0,0 @@ - $request->getMethod(), - 'uri' => $request->getUri()->__toString(), - 'body' => $request->getBody()->__toString(), -]; - -echo json_encode($output); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/LazyOpenStreamTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/LazyOpenStreamTest.php deleted file mode 100644 index 0eca3c59..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/LazyOpenStreamTest.php +++ /dev/null @@ -1,71 +0,0 @@ -fname = tempnam(sys_get_temp_dir(), 'tfile'); - - if (file_exists($this->fname)) { - unlink($this->fname); - } - } - - /** - * @after - */ - public function tearDownTest() - { - if (file_exists($this->fname)) { - unlink($this->fname); - } - } - - public function testOpensLazily() - { - $l = new LazyOpenStream($this->fname, 'w+'); - $l->write('foo'); - $this->assertInternalTypeGuzzle('array', $l->getMetadata()); - self::assertFileExists($this->fname); - self::assertSame('foo', file_get_contents($this->fname)); - self::assertSame('foo', (string) $l); - } - - public function testProxiesToFile() - { - file_put_contents($this->fname, 'foo'); - $l = new LazyOpenStream($this->fname, 'r'); - self::assertSame('foo', $l->read(4)); - self::assertTrue($l->eof()); - self::assertSame(3, $l->tell()); - self::assertTrue($l->isReadable()); - self::assertTrue($l->isSeekable()); - self::assertFalse($l->isWritable()); - $l->seek(1); - self::assertSame('oo', $l->getContents()); - self::assertSame('foo', (string) $l); - self::assertSame(3, $l->getSize()); - $this->assertInternalTypeGuzzle('array', $l->getMetadata()); - $l->close(); - } - - public function testDetachesUnderlyingStream() - { - file_put_contents($this->fname, 'foo'); - $l = new LazyOpenStream($this->fname, 'r'); - $r = $l->detach(); - $this->assertInternalTypeGuzzle('resource', $r); - fseek($r, 0); - self::assertSame('foo', stream_get_contents($r)); - fclose($r); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/LimitStreamTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/LimitStreamTest.php deleted file mode 100644 index 62dc0b26..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/LimitStreamTest.php +++ /dev/null @@ -1,166 +0,0 @@ -decorated = Psr7\Utils::streamFor(fopen(__FILE__, 'r')); - $this->body = new LimitStream($this->decorated, 10, 3); - } - - public function testReturnsSubset() - { - $body = new LimitStream(Psr7\Utils::streamFor('foo'), -1, 1); - self::assertSame('oo', (string) $body); - self::assertTrue($body->eof()); - $body->seek(0); - self::assertFalse($body->eof()); - self::assertSame('oo', $body->read(100)); - self::assertSame('', $body->read(1)); - self::assertTrue($body->eof()); - } - - public function testReturnsSubsetWhenCastToString() - { - $body = Psr7\Utils::streamFor('foo_baz_bar'); - $limited = new LimitStream($body, 3, 4); - self::assertSame('baz', (string) $limited); - } - - public function testReturnsSubsetOfEmptyBodyWhenCastToString() - { - $body = Psr7\Utils::streamFor('01234567891234'); - $limited = new LimitStream($body, 0, 10); - self::assertSame('', (string) $limited); - } - - public function testReturnsSpecificSubsetOBodyWhenCastToString() - { - $body = Psr7\Utils::streamFor('0123456789abcdef'); - $limited = new LimitStream($body, 3, 10); - self::assertSame('abc', (string) $limited); - } - - public function testSeeksWhenConstructed() - { - self::assertSame(0, $this->body->tell()); - self::assertSame(3, $this->decorated->tell()); - } - - public function testAllowsBoundedSeek() - { - $this->body->seek(100); - self::assertSame(10, $this->body->tell()); - self::assertSame(13, $this->decorated->tell()); - $this->body->seek(0); - self::assertSame(0, $this->body->tell()); - self::assertSame(3, $this->decorated->tell()); - try { - $this->body->seek(-10); - self::fail(); - } catch (\RuntimeException $e) { - } - self::assertSame(0, $this->body->tell()); - self::assertSame(3, $this->decorated->tell()); - $this->body->seek(5); - self::assertSame(5, $this->body->tell()); - self::assertSame(8, $this->decorated->tell()); - // Fail - try { - $this->body->seek(1000, SEEK_END); - self::fail(); - } catch (\RuntimeException $e) { - } - } - - public function testReadsOnlySubsetOfData() - { - $data = $this->body->read(100); - self::assertSame(10, strlen($data)); - self::assertSame('', $this->body->read(1000)); - - $this->body->setOffset(10); - $newData = $this->body->read(100); - self::assertSame(10, strlen($newData)); - self::assertNotSame($data, $newData); - } - - public function testThrowsWhenCurrentGreaterThanOffsetSeek() - { - $a = Psr7\Utils::streamFor('foo_bar'); - $b = new NoSeekStream($a); - $c = new LimitStream($b); - $a->getContents(); - - $this->expectExceptionGuzzle('RuntimeException', 'Could not seek to stream offset 2'); - - $c->setOffset(2); - } - - public function testCanGetContentsWithoutSeeking() - { - $a = Psr7\Utils::streamFor('foo_bar'); - $b = new NoSeekStream($a); - $c = new LimitStream($b); - self::assertSame('foo_bar', $c->getContents()); - } - - public function testClaimsConsumedWhenReadLimitIsReached() - { - self::assertFalse($this->body->eof()); - $this->body->read(1000); - self::assertTrue($this->body->eof()); - } - - public function testContentLengthIsBounded() - { - self::assertSame(10, $this->body->getSize()); - } - - public function testGetContentsIsBasedOnSubset() - { - $body = new LimitStream(Psr7\Utils::streamFor('foobazbar'), 3, 3); - self::assertSame('baz', $body->getContents()); - } - - public function testReturnsNullIfSizeCannotBeDetermined() - { - $a = new FnStream([ - 'getSize' => function () { - return null; - }, - 'tell' => function () { - return 0; - }, - ]); - $b = new LimitStream($a); - self::assertNull($b->getSize()); - } - - public function testLengthLessOffsetWhenNoLimitSize() - { - $a = Psr7\Utils::streamFor('foo_bar'); - $b = new LimitStream($a, -1, 4); - self::assertSame(3, $b->getSize()); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/MessageTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/MessageTest.php deleted file mode 100644 index 339b3ab3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/MessageTest.php +++ /dev/null @@ -1,266 +0,0 @@ - 'bar', - 'Qux' => 'ipsum', - ], 'hello', '1.0'); - self::assertSame( - "PUT /hi?123 HTTP/1.0\r\nHost: foo.com\r\nBaz: bar\r\nQux: ipsum\r\n\r\nhello", - Psr7\Message::toString($request) - ); - } - - public function testConvertsResponsesToStrings() - { - $response = new Psr7\Response(200, [ - 'Baz' => 'bar', - 'Qux' => 'ipsum', - ], 'hello', '1.0', 'FOO'); - self::assertSame( - "HTTP/1.0 200 FOO\r\nBaz: bar\r\nQux: ipsum\r\n\r\nhello", - Psr7\Message::toString($response) - ); - } - - public function testCorrectlyRendersSetCookieHeadersToString() - { - $response = new Psr7\Response(200, [ - 'Set-Cookie' => ['bar','baz','qux'] - ], 'hello', '1.0', 'FOO'); - self::assertSame( - "HTTP/1.0 200 FOO\r\nSet-Cookie: bar\r\nSet-Cookie: baz\r\nSet-Cookie: qux\r\n\r\nhello", - Psr7\Message::toString($response) - ); - } - - public function testRewindsBody() - { - $body = Psr7\Utils::streamFor('abc'); - $res = new Psr7\Response(200, [], $body); - Psr7\Message::rewindBody($res); - self::assertSame(0, $body->tell()); - $body->rewind(); - Psr7\Message::rewindBody($res); - self::assertSame(0, $body->tell()); - } - - public function testThrowsWhenBodyCannotBeRewound() - { - $body = Psr7\Utils::streamFor('abc'); - $body->read(1); - $body = FnStream::decorate($body, [ - 'rewind' => function () { - throw new \RuntimeException('a'); - }, - ]); - $res = new Psr7\Response(200, [], $body); - - $this->expectExceptionGuzzle('RuntimeException'); - - Psr7\Message::rewindBody($res); - } - - public function testParsesRequestMessages() - { - $req = "GET /abc HTTP/1.0\r\nHost: foo.com\r\nFoo: Bar\r\nBaz: Bam\r\nBaz: Qux\r\n\r\nTest"; - $request = Psr7\Message::parseRequest($req); - self::assertSame('GET', $request->getMethod()); - self::assertSame('/abc', $request->getRequestTarget()); - self::assertSame('1.0', $request->getProtocolVersion()); - self::assertSame('foo.com', $request->getHeaderLine('Host')); - self::assertSame('Bar', $request->getHeaderLine('Foo')); - self::assertSame('Bam, Qux', $request->getHeaderLine('Baz')); - self::assertSame('Test', (string)$request->getBody()); - self::assertSame('http://foo.com/abc', (string)$request->getUri()); - } - - public function testParsesRequestMessagesWithHttpsScheme() - { - $req = "PUT /abc?baz=bar HTTP/1.1\r\nHost: foo.com:443\r\n\r\n"; - $request = Psr7\Message::parseRequest($req); - self::assertSame('PUT', $request->getMethod()); - self::assertSame('/abc?baz=bar', $request->getRequestTarget()); - self::assertSame('1.1', $request->getProtocolVersion()); - self::assertSame('foo.com:443', $request->getHeaderLine('Host')); - self::assertSame('', (string)$request->getBody()); - self::assertSame('https://foo.com/abc?baz=bar', (string)$request->getUri()); - } - - public function testParsesRequestMessagesWithUriWhenHostIsNotFirst() - { - $req = "PUT / HTTP/1.1\r\nFoo: Bar\r\nHost: foo.com\r\n\r\n"; - $request = Psr7\Message::parseRequest($req); - self::assertSame('PUT', $request->getMethod()); - self::assertSame('/', $request->getRequestTarget()); - self::assertSame('http://foo.com/', (string)$request->getUri()); - } - - public function testParsesRequestMessagesWithFullUri() - { - $req = "GET https://www.google.com:443/search?q=foobar HTTP/1.1\r\nHost: www.google.com\r\n\r\n"; - $request = Psr7\Message::parseRequest($req); - self::assertSame('GET', $request->getMethod()); - self::assertSame('https://www.google.com:443/search?q=foobar', $request->getRequestTarget()); - self::assertSame('1.1', $request->getProtocolVersion()); - self::assertSame('www.google.com', $request->getHeaderLine('Host')); - self::assertSame('', (string)$request->getBody()); - self::assertSame('https://www.google.com/search?q=foobar', (string)$request->getUri()); - } - - public function testParsesRequestMessagesWithCustomMethod() - { - $req = "GET_DATA / HTTP/1.1\r\nFoo: Bar\r\nHost: foo.com\r\n\r\n"; - $request = Psr7\Message::parseRequest($req); - self::assertSame('GET_DATA', $request->getMethod()); - } - - public function testParsesRequestMessagesWithFoldedHeadersOnHttp10() - { - $req = "PUT / HTTP/1.0\r\nFoo: Bar\r\n Bam\r\n\r\n"; - $request = Psr7\Message::parseRequest($req); - self::assertSame('PUT', $request->getMethod()); - self::assertSame('/', $request->getRequestTarget()); - self::assertSame('Bar Bam', $request->getHeaderLine('Foo')); - } - - public function testRequestParsingFailsWithFoldedHeadersOnHttp11() - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'Invalid header syntax: Obsolete line folding'); - - Psr7\Message::parseResponse("GET_DATA / HTTP/1.1\r\nFoo: Bar\r\n Biz: Bam\r\n\r\n"); - } - - public function testParsesRequestMessagesWhenHeaderDelimiterIsOnlyALineFeed() - { - $req = "PUT / HTTP/1.0\nFoo: Bar\nBaz: Bam\n\n"; - $request = Psr7\Message::parseRequest($req); - self::assertSame('PUT', $request->getMethod()); - self::assertSame('/', $request->getRequestTarget()); - self::assertSame('Bar', $request->getHeaderLine('Foo')); - self::assertSame('Bam', $request->getHeaderLine('Baz')); - } - - public function testValidatesRequestMessages() - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - - Psr7\Message::parseRequest("HTTP/1.1 200 OK\r\n\r\n"); - } - - public function testParsesResponseMessages() - { - $res = "HTTP/1.0 200 OK\r\nFoo: Bar\r\nBaz: Bam\r\nBaz: Qux\r\n\r\nTest"; - $response = Psr7\Message::parseResponse($res); - self::assertSame(200, $response->getStatusCode()); - self::assertSame('OK', $response->getReasonPhrase()); - self::assertSame('1.0', $response->getProtocolVersion()); - self::assertSame('Bar', $response->getHeaderLine('Foo')); - self::assertSame('Bam, Qux', $response->getHeaderLine('Baz')); - self::assertSame('Test', (string)$response->getBody()); - } - - public function testParsesResponseWithoutReason() - { - $res = "HTTP/1.0 200\r\nFoo: Bar\r\nBaz: Bam\r\nBaz: Qux\r\n\r\nTest"; - $response = Psr7\Message::parseResponse($res); - self::assertSame(200, $response->getStatusCode()); - self::assertSame('OK', $response->getReasonPhrase()); - self::assertSame('1.0', $response->getProtocolVersion()); - self::assertSame('Bar', $response->getHeaderLine('Foo')); - self::assertSame('Bam, Qux', $response->getHeaderLine('Baz')); - self::assertSame('Test', (string)$response->getBody()); - } - - public function testParsesResponseWithLeadingDelimiter() - { - $res = "\r\nHTTP/1.0 200\r\nFoo: Bar\r\n\r\nTest"; - $response = Psr7\Message::parseResponse($res); - self::assertSame(200, $response->getStatusCode()); - self::assertSame('OK', $response->getReasonPhrase()); - self::assertSame('1.0', $response->getProtocolVersion()); - self::assertSame('Bar', $response->getHeaderLine('Foo')); - self::assertSame('Test', (string)$response->getBody()); - } - - public function testParsesResponseWithFoldedHeadersOnHttp10() - { - $res = "HTTP/1.0 200\r\nFoo: Bar\r\n Bam\r\n\r\nTest"; - $response = Psr7\Message::parseResponse($res); - self::assertSame(200, $response->getStatusCode()); - self::assertSame('OK', $response->getReasonPhrase()); - self::assertSame('1.0', $response->getProtocolVersion()); - self::assertSame('Bar Bam', $response->getHeaderLine('Foo')); - self::assertSame('Test', (string)$response->getBody()); - } - - public function testResponseParsingFailsWithFoldedHeadersOnHttp11() - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'Invalid header syntax: Obsolete line folding'); - - Psr7\Message::parseResponse("HTTP/1.1 200\r\nFoo: Bar\r\n Biz: Bam\r\nBaz: Qux\r\n\r\nTest"); - } - - public function testParsesResponseWhenHeaderDelimiterIsOnlyALineFeed() - { - $res = "HTTP/1.0 200\nFoo: Bar\nBaz: Bam\n\nTest\n\nOtherTest"; - $response = Psr7\Message::parseResponse($res); - self::assertSame(200, $response->getStatusCode()); - self::assertSame('OK', $response->getReasonPhrase()); - self::assertSame('1.0', $response->getProtocolVersion()); - self::assertSame('Bar', $response->getHeaderLine('Foo')); - self::assertSame('Bam', $response->getHeaderLine('Baz')); - self::assertSame("Test\n\nOtherTest", (string)$response->getBody()); - } - - public function testResponseParsingFailsWithoutHeaderDelimiter() - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'Invalid message: Missing header delimiter'); - - Psr7\Message::parseResponse("HTTP/1.0 200\r\nFoo: Bar\r\n Baz: Bam\r\nBaz: Qux\r\n"); - } - - public function testValidatesResponseMessages() - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - - Psr7\Message::parseResponse("GET / HTTP/1.1\r\n\r\n"); - } - - public function testMessageBodySummaryWithSmallBody() - { - $message = new Psr7\Response(200, [], 'Lorem ipsum dolor sit amet, consectetur adipiscing elit.'); - self::assertSame('Lorem ipsum dolor sit amet, consectetur adipiscing elit.', Psr7\Message::bodySummary($message)); - } - - public function testMessageBodySummaryWithLargeBody() - { - $message = new Psr7\Response(200, [], 'Lorem ipsum dolor sit amet, consectetur adipiscing elit.'); - self::assertSame('Lorem ipsu (truncated...)', Psr7\Message::bodySummary($message, 10)); - } - - public function testMessageBodySummaryWithSpecialUTF8Characters() - { - $message = new Psr7\Response(200, [], '’é€௵ဪ‱'); - self::assertSame('’é€௵ဪ‱', Psr7\Message::bodySummary($message)); - } - - public function testMessageBodySummaryWithEmptyBody() - { - $message = new Psr7\Response(200, [], ''); - self::assertNull(Psr7\Message::bodySummary($message)); - } - - public function testGetResponseBodySummaryOfNonReadableStream() - { - self::assertNull(Psr7\Message::bodySummary(new Psr7\Response(500, [], new ReadSeekOnlyStream()))); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/MimeTypeTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/MimeTypeTest.php deleted file mode 100644 index 169e20b5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/MimeTypeTest.php +++ /dev/null @@ -1,22 +0,0 @@ -getBoundary()); - } - - public function testCanProvideBoundary() - { - $b = new MultipartStream([], 'foo'); - self::assertSame('foo', $b->getBoundary()); - } - - public function testIsNotWritable() - { - $b = new MultipartStream(); - self::assertFalse($b->isWritable()); - } - - public function testCanCreateEmptyStream() - { - $b = new MultipartStream(); - $boundary = $b->getBoundary(); - self::assertSame("--{$boundary}--\r\n", $b->getContents()); - self::assertSame(strlen($boundary) + 6, $b->getSize()); - } - - public function testValidatesFilesArrayElement() - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - - new MultipartStream([['foo' => 'bar']]); - } - - public function testEnsuresFileHasName() - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - - new MultipartStream([['contents' => 'bar']]); - } - - public function testSerializesFields() - { - $b = new MultipartStream([ - [ - 'name' => 'foo', - 'contents' => 'bar' - ], - [ - 'name' => 'baz', - 'contents' => 'bam' - ] - ], 'boundary'); - self::assertSame( - "--boundary\r\nContent-Disposition: form-data; name=\"foo\"\r\nContent-Length: 3\r\n\r\n" - . "bar\r\n--boundary\r\nContent-Disposition: form-data; name=\"baz\"\r\nContent-Length: 3" - . "\r\n\r\nbam\r\n--boundary--\r\n", - (string) $b - ); - } - - public function testSerializesNonStringFields() - { - $b = new MultipartStream([ - [ - 'name' => 'int', - 'contents' => (int) 1 - ], - [ - 'name' => 'bool', - 'contents' => (boolean) false - ], - [ - 'name' => 'bool2', - 'contents' => (boolean) true - ], - [ - 'name' => 'float', - 'contents' => (float) 1.1 - ] - ], 'boundary'); - self::assertSame( - "--boundary\r\nContent-Disposition: form-data; name=\"int\"\r\nContent-Length: 1\r\n\r\n" - . "1\r\n--boundary\r\nContent-Disposition: form-data; name=\"bool\"\r\n\r\n\r\n--boundary" - . "\r\nContent-Disposition: form-data; name=\"bool2\"\r\nContent-Length: 1\r\n\r\n" - . "1\r\n--boundary\r\nContent-Disposition: form-data; name=\"float\"\r\nContent-Length: 3" - . "\r\n\r\n1.1\r\n--boundary--\r\n", - (string) $b - ); - } - - public function testSerializesFiles() - { - $f1 = Psr7\FnStream::decorate(Psr7\Utils::streamFor('foo'), [ - 'getMetadata' => function () { - return '/foo/bar.txt'; - } - ]); - - $f2 = Psr7\FnStream::decorate(Psr7\Utils::streamFor('baz'), [ - 'getMetadata' => function () { - return '/foo/baz.jpg'; - } - ]); - - $f3 = Psr7\FnStream::decorate(Psr7\Utils::streamFor('bar'), [ - 'getMetadata' => function () { - return '/foo/bar.gif'; - } - ]); - - $b = new MultipartStream([ - [ - 'name' => 'foo', - 'contents' => $f1 - ], - [ - 'name' => 'qux', - 'contents' => $f2 - ], - [ - 'name' => 'qux', - 'contents' => $f3 - ], - ], 'boundary'); - - $expected = << function () { - return '/foo/bar.txt'; - } - ]); - - $b = new MultipartStream([ - [ - 'name' => 'foo', - 'contents' => $f1, - 'headers' => [ - 'x-foo' => 'bar', - 'content-disposition' => 'custom' - ] - ] - ], 'boundary'); - - $expected = << function () { - return '/foo/bar.txt'; - } - ]); - - $f2 = Psr7\FnStream::decorate(Psr7\Utils::streamFor('baz'), [ - 'getMetadata' => function () { - return '/foo/baz.jpg'; - } - ]); - - $b = new MultipartStream([ - [ - 'name' => 'foo', - 'contents' => $f1, - 'headers' => [ - 'x-foo' => 'bar', - 'content-disposition' => 'custom' - ] - ], - [ - 'name' => 'foo', - 'contents' => $f2, - 'headers' => ['cOntenT-Type' => 'custom'], - ] - ], 'boundary'); - - $expected = <<getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['isSeekable', 'seek']) - ->getMockForAbstractClass(); - $s->expects(self::never())->method('seek'); - $s->expects(self::never())->method('isSeekable'); - $wrapped = new NoSeekStream($s); - self::assertFalse($wrapped->isSeekable()); - - $this->expectExceptionGuzzle('RuntimeException', 'Cannot seek a NoSeekStream'); - - $wrapped->seek(2); - } - - public function testToStringDoesNotSeek() - { - $s = \GuzzleHttp\Psr7\Utils::streamFor('foo'); - $s->seek(1); - $wrapped = new NoSeekStream($s); - self::assertSame('oo', (string) $wrapped); - - $wrapped->close(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/PumpStreamTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/PumpStreamTest.php deleted file mode 100644 index 31d2cba9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/PumpStreamTest.php +++ /dev/null @@ -1,78 +0,0 @@ - ['foo' => 'bar'], - 'size' => 100 - ]); - - self::assertSame('bar', $p->getMetadata('foo')); - self::assertSame(['foo' => 'bar'], $p->getMetadata()); - self::assertSame(100, $p->getSize()); - } - - public function testCanReadFromCallable() - { - $p = Psr7\Utils::streamFor(function ($size) { - return 'a'; - }); - self::assertSame('a', $p->read(1)); - self::assertSame(1, $p->tell()); - self::assertSame('aaaaa', $p->read(5)); - self::assertSame(6, $p->tell()); - } - - public function testStoresExcessDataInBuffer() - { - $called = []; - $p = Psr7\Utils::streamFor(function ($size) use (&$called) { - $called[] = $size; - return 'abcdef'; - }); - self::assertSame('a', $p->read(1)); - self::assertSame('b', $p->read(1)); - self::assertSame('cdef', $p->read(4)); - self::assertSame('abcdefabc', $p->read(9)); - self::assertSame([1, 9, 3], $called); - } - - public function testInifiniteStreamWrappedInLimitStream() - { - $p = Psr7\Utils::streamFor(function () { - return 'a'; - }); - $s = new LimitStream($p, 5); - self::assertSame('aaaaa', (string) $s); - } - - public function testDescribesCapabilities() - { - $p = Psr7\Utils::streamFor(function () { - }); - self::assertTrue($p->isReadable()); - self::assertFalse($p->isSeekable()); - self::assertFalse($p->isWritable()); - self::assertNull($p->getSize()); - self::assertSame('', $p->getContents()); - self::assertSame('', (string) $p); - $p->close(); - self::assertSame('', $p->read(10)); - self::assertTrue($p->eof()); - - try { - self::assertFalse($p->write('aa')); - self::fail(); - } catch (\RuntimeException $e) { - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/QueryTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/QueryTest.php deleted file mode 100644 index 6047fb02..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/QueryTest.php +++ /dev/null @@ -1,98 +0,0 @@ - ['a', 'b']]], - // Can parse multi-valued items that use numeric indices - ['q[0]=a&q[1]=b', ['q[0]' => 'a', 'q[1]' => 'b']], - // Can parse duplicates and does not include numeric indices - ['q[]=a&q[]=b', ['q[]' => ['a', 'b']]], - // Ensures that the value of "q" is an array even though one value - ['q[]=a', ['q[]' => 'a']], - // Does not modify "." to "_" like PHP's parse_str() - ['q.a=a&q.b=b', ['q.a' => 'a', 'q.b' => 'b']], - // Can decode %20 to " " - ['q%20a=a%20b', ['q a' => 'a b']], - // Can parse funky strings with no values by assigning each to null - ['q&a', ['q' => null, 'a' => null]], - // Does not strip trailing equal signs - ['data=abc=', ['data' => 'abc=']], - // Can store duplicates without affecting other values - ['foo=a&foo=b&?µ=c', ['foo' => ['a', 'b'], '?µ' => 'c']], - // Sets value to null when no "=" is present - ['foo', ['foo' => null]], - // Preserves "0" keys. - ['0', ['0' => null]], - // Sets the value to an empty string when "=" is present - ['0=', ['0' => '']], - // Preserves falsey keys - ['var=0', ['var' => '0']], - ['a[b][c]=1&a[b][c]=2', ['a[b][c]' => ['1', '2']]], - ['a[b]=c&a[d]=e', ['a[b]' => 'c', 'a[d]' => 'e']], - // Ensure it doesn't leave things behind with repeated values - // Can parse mult-values items - ['q=a&q=b&q=c', ['q' => ['a', 'b', 'c']]], - ]; - } - - /** - * @dataProvider parseQueryProvider - */ - public function testParsesQueries($input, $output) - { - $result = Psr7\Query::parse($input); - self::assertSame($output, $result); - } - - public function testDoesNotDecode() - { - $str = 'foo%20=bar'; - $data = Psr7\Query::parse($str, false); - self::assertSame(['foo%20' => 'bar'], $data); - } - - /** - * @dataProvider parseQueryProvider - */ - public function testParsesAndBuildsQueries($input) - { - $result = Psr7\Query::parse($input, false); - self::assertSame($input, Psr7\Query::build($result, false)); - } - - public function testEncodesWithRfc1738() - { - $str = Psr7\Query::build(['foo bar' => 'baz+'], PHP_QUERY_RFC1738); - self::assertSame('foo+bar=baz%2B', $str); - } - - public function testEncodesWithRfc3986() - { - $str = Psr7\Query::build(['foo bar' => 'baz+'], PHP_QUERY_RFC3986); - self::assertSame('foo%20bar=baz%2B', $str); - } - - public function testDoesNotEncode() - { - $str = Psr7\Query::build(['foo bar' => 'baz+'], false); - self::assertSame('foo bar=baz+', $str); - } - - public function testCanControlDecodingType() - { - $result = Psr7\Query::parse('var=foo+bar', PHP_QUERY_RFC3986); - self::assertSame('foo+bar', $result['var']); - $result = Psr7\Query::parse('var=foo+bar', PHP_QUERY_RFC1738); - self::assertSame('foo bar', $result['var']); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/ReadSeekOnlyStream.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/ReadSeekOnlyStream.php deleted file mode 100644 index 27409ece..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/ReadSeekOnlyStream.php +++ /dev/null @@ -1,23 +0,0 @@ -getUri()); - } - - public function testRequestUriMayBeUri() - { - $uri = new Uri('/'); - $r = new Request('GET', $uri); - self::assertSame($uri, $r->getUri()); - } - - public function testValidateRequestUri() - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - - new Request('GET', '///'); - } - - public function testCanConstructWithBody() - { - $r = new Request('GET', '/', [], 'baz'); - self::assertInstanceOf('Psr\Http\Message\StreamInterface', $r->getBody()); - self::assertSame('baz', (string) $r->getBody()); - } - - public function testNullBody() - { - $r = new Request('GET', '/', [], null); - self::assertInstanceOf('Psr\Http\Message\StreamInterface', $r->getBody()); - self::assertSame('', (string) $r->getBody()); - } - - public function testFalseyBody() - { - $r = new Request('GET', '/', [], '0'); - self::assertInstanceOf('Psr\Http\Message\StreamInterface', $r->getBody()); - self::assertSame('0', (string) $r->getBody()); - } - - public function testConstructorDoesNotReadStreamBody() - { - $streamIsRead = false; - $body = Psr7\FnStream::decorate(Psr7\Utils::streamFor(''), [ - '__toString' => function () use (&$streamIsRead) { - $streamIsRead = true; - return ''; - } - ]); - - $r = new Request('GET', '/', [], $body); - self::assertFalse($streamIsRead); - self::assertSame($body, $r->getBody()); - } - - public function testCapitalizesMethod() - { - $r = new Request('get', '/'); - self::assertSame('GET', $r->getMethod()); - } - - public function testCapitalizesWithMethod() - { - $r = new Request('GET', '/'); - self::assertSame('PUT', $r->withMethod('put')->getMethod()); - } - - public function testWithUri() - { - $r1 = new Request('GET', '/'); - $u1 = $r1->getUri(); - $u2 = new Uri('http://www.example.com'); - $r2 = $r1->withUri($u2); - self::assertNotSame($r1, $r2); - self::assertSame($u2, $r2->getUri()); - self::assertSame($u1, $r1->getUri()); - } - - /** - * @dataProvider invalidMethodsProvider - */ - public function testConstructWithInvalidMethods($method) - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - new Request($method, '/'); - } - - /** - * @dataProvider invalidMethodsProvider - */ - public function testWithInvalidMethods($method) - { - $r = new Request('get', '/'); - $this->expectExceptionGuzzle('InvalidArgumentException'); - $r->withMethod($method); - } - - public function invalidMethodsProvider() - { - return [ - [null], - [false], - [['foo']], - [new \stdClass()], - ]; - } - - public function testSameInstanceWhenSameUri() - { - $r1 = new Request('GET', 'http://foo.com'); - $r2 = $r1->withUri($r1->getUri()); - self::assertSame($r1, $r2); - } - - public function testWithRequestTarget() - { - $r1 = new Request('GET', '/'); - $r2 = $r1->withRequestTarget('*'); - self::assertSame('*', $r2->getRequestTarget()); - self::assertSame('/', $r1->getRequestTarget()); - } - - public function testRequestTargetDoesNotAllowSpaces() - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - - $r1 = new Request('GET', '/'); - $r1->withRequestTarget('/foo bar'); - } - - public function testRequestTargetDefaultsToSlash() - { - $r1 = new Request('GET', ''); - self::assertSame('/', $r1->getRequestTarget()); - $r2 = new Request('GET', '*'); - self::assertSame('*', $r2->getRequestTarget()); - $r3 = new Request('GET', 'http://foo.com/bar baz/'); - self::assertSame('/bar%20baz/', $r3->getRequestTarget()); - } - - public function testBuildsRequestTarget() - { - $r1 = new Request('GET', 'http://foo.com/baz?bar=bam'); - self::assertSame('/baz?bar=bam', $r1->getRequestTarget()); - } - - public function testBuildsRequestTargetWithFalseyQuery() - { - $r1 = new Request('GET', 'http://foo.com/baz?0'); - self::assertSame('/baz?0', $r1->getRequestTarget()); - } - - public function testHostIsAddedFirst() - { - $r = new Request('GET', 'http://foo.com/baz?bar=bam', ['Foo' => 'Bar']); - self::assertSame([ - 'Host' => ['foo.com'], - 'Foo' => ['Bar'] - ], $r->getHeaders()); - } - - public function testHeaderValueWithWhitespace() - { - $r = new Request('GET', 'https://example.com/', [ - 'User-Agent' => 'Linux f0f489981e90 5.10.104-linuxkit 1 SMP Wed Mar 9 19:05:23 UTC 2022 x86_64' - ]); - self::assertSame([ - 'Host' => ['example.com'], - 'User-Agent' => ['Linux f0f489981e90 5.10.104-linuxkit 1 SMP Wed Mar 9 19:05:23 UTC 2022 x86_64'] - ], $r->getHeaders()); - } - - public function testCanGetHeaderAsCsv() - { - $r = new Request('GET', 'http://foo.com/baz?bar=bam', [ - 'Foo' => ['a', 'b', 'c'] - ]); - self::assertSame('a, b, c', $r->getHeaderLine('Foo')); - self::assertSame('', $r->getHeaderLine('Bar')); - } - - public function testHostIsNotOverwrittenWhenPreservingHost() - { - $r = new Request('GET', 'http://foo.com/baz?bar=bam', ['Host' => 'a.com']); - self::assertSame(['Host' => ['a.com']], $r->getHeaders()); - $r2 = $r->withUri(new Uri('http://www.foo.com/bar'), true); - self::assertSame('a.com', $r2->getHeaderLine('Host')); - } - - public function testWithUriSetsHostIfNotSet() - { - $r = (new Request('GET', 'http://foo.com/baz?bar=bam'))->withoutHeader('Host'); - self::assertSame([], $r->getHeaders()); - $r2 = $r->withUri(new Uri('http://www.baz.com/bar'), true); - self::assertSame('www.baz.com', $r2->getHeaderLine('Host')); - } - - public function testOverridesHostWithUri() - { - $r = new Request('GET', 'http://foo.com/baz?bar=bam'); - self::assertSame(['Host' => ['foo.com']], $r->getHeaders()); - $r2 = $r->withUri(new Uri('http://www.baz.com/bar')); - self::assertSame('www.baz.com', $r2->getHeaderLine('Host')); - } - - public function testAggregatesHeaders() - { - $r = new Request('GET', '', [ - 'ZOO' => 'zoobar', - 'zoo' => ['foobar', 'zoobar'] - ]); - self::assertSame(['ZOO' => ['zoobar', 'foobar', 'zoobar']], $r->getHeaders()); - self::assertSame('zoobar, foobar, zoobar', $r->getHeaderLine('zoo')); - } - - public function testAddsPortToHeader() - { - $r = new Request('GET', 'http://foo.com:8124/bar'); - self::assertSame('foo.com:8124', $r->getHeaderLine('host')); - } - - public function testAddsPortToHeaderAndReplacePreviousPort() - { - $r = new Request('GET', 'http://foo.com:8124/bar'); - $r = $r->withUri(new Uri('http://foo.com:8125/bar')); - self::assertSame('foo.com:8125', $r->getHeaderLine('host')); - } - - /** - * @dataProvider provideHeaderValuesContainingNotAllowedChars - */ - public function testContainsNotAllowedCharsOnHeaderValue($value) - { - $this->expectExceptionGuzzle('InvalidArgumentException', sprintf('"%s" is not valid header value', $value)); - $r = new Request( - 'GET', - 'http://foo.com/baz?bar=bam', - [ - 'testing' => $value - ] - ); - } - - /** - * @return iterable - */ - public function provideHeaderValuesContainingNotAllowedChars() - { - // Explicit tests for newlines as the most common exploit vector. - $tests = [ - ["new\nline"], - ["new\r\nline"], - ["new\rline"], - // Line folding is technically allowed, but deprecated. - // We don't support it. - ["new\r\n line"], - ["newline\n"], - ["\nnewline"], - ["newline\r\n"], - ["\r\nnewline"], - ]; - - for ($i = 0; $i <= 0xff; $i++) { - if (\chr($i) == "\t") { - continue; - } - if (\chr($i) == " ") { - continue; - } - if ($i >= 0x21 && $i <= 0x7e) { - continue; - } - if ($i >= 0x80) { - continue; - } - - $tests[] = ["foo" . \chr($i) . "bar"]; - $tests[] = ["foo" . \chr($i)]; - } - - return $tests; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/ResponseTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/ResponseTest.php deleted file mode 100644 index 204015a9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/ResponseTest.php +++ /dev/null @@ -1,384 +0,0 @@ -getStatusCode()); - self::assertSame('1.1', $r->getProtocolVersion()); - self::assertSame('OK', $r->getReasonPhrase()); - self::assertSame([], $r->getHeaders()); - self::assertInstanceOf('Psr\Http\Message\StreamInterface', $r->getBody()); - self::assertSame('', (string) $r->getBody()); - } - - public function testCanConstructWithStatusCode() - { - $r = new Response(404); - self::assertSame(404, $r->getStatusCode()); - self::assertSame('Not Found', $r->getReasonPhrase()); - } - - public function testConstructorDoesNotReadStreamBody() - { - $streamIsRead = false; - $body = Psr7\FnStream::decorate(Psr7\Utils::streamFor(''), [ - '__toString' => function () use (&$streamIsRead) { - $streamIsRead = true; - return ''; - } - ]); - - $r = new Response(200, [], $body); - self::assertFalse($streamIsRead); - self::assertSame($body, $r->getBody()); - } - - public function testStatusCanBeNumericString() - { - $r = new Response('404'); - $r2 = $r->withStatus('201'); - self::assertSame(404, $r->getStatusCode()); - self::assertSame('Not Found', $r->getReasonPhrase()); - self::assertSame(201, $r2->getStatusCode()); - self::assertSame('Created', $r2->getReasonPhrase()); - } - - public function testCanConstructWithHeaders() - { - $r = new Response(200, ['Foo' => 'Bar']); - self::assertSame(['Foo' => ['Bar']], $r->getHeaders()); - self::assertSame('Bar', $r->getHeaderLine('Foo')); - self::assertSame(['Bar'], $r->getHeader('Foo')); - } - - public function testCanConstructWithHeadersAsArray() - { - $r = new Response(200, [ - 'Foo' => ['baz', 'bar'] - ]); - self::assertSame(['Foo' => ['baz', 'bar']], $r->getHeaders()); - self::assertSame('baz, bar', $r->getHeaderLine('Foo')); - self::assertSame(['baz', 'bar'], $r->getHeader('Foo')); - } - - public function testCanConstructWithBody() - { - $r = new Response(200, [], 'baz'); - self::assertInstanceOf('Psr\Http\Message\StreamInterface', $r->getBody()); - self::assertSame('baz', (string) $r->getBody()); - } - - public function testNullBody() - { - $r = new Response(200, [], null); - self::assertInstanceOf('Psr\Http\Message\StreamInterface', $r->getBody()); - self::assertSame('', (string) $r->getBody()); - } - - public function testFalseyBody() - { - $r = new Response(200, [], '0'); - self::assertInstanceOf('Psr\Http\Message\StreamInterface', $r->getBody()); - self::assertSame('0', (string) $r->getBody()); - } - - public function testCanConstructWithReason() - { - $r = new Response(200, [], null, '1.1', 'bar'); - self::assertSame('bar', $r->getReasonPhrase()); - - $r = new Response(200, [], null, '1.1', '0'); - self::assertSame('0', $r->getReasonPhrase(), 'Falsey reason works'); - } - - public function testCanConstructWithProtocolVersion() - { - $r = new Response(200, [], null, '1000'); - self::assertSame('1000', $r->getProtocolVersion()); - } - - public function testWithStatusCodeAndNoReason() - { - $r = (new Response())->withStatus(201); - self::assertSame(201, $r->getStatusCode()); - self::assertSame('Created', $r->getReasonPhrase()); - } - - public function testWithStatusCodeAndReason() - { - $r = (new Response())->withStatus(201, 'Foo'); - self::assertSame(201, $r->getStatusCode()); - self::assertSame('Foo', $r->getReasonPhrase()); - - $r = (new Response())->withStatus(201, '0'); - self::assertSame(201, $r->getStatusCode()); - self::assertSame('0', $r->getReasonPhrase(), 'Falsey reason works'); - } - - public function testWithProtocolVersion() - { - $r = (new Response())->withProtocolVersion('1000'); - self::assertSame('1000', $r->getProtocolVersion()); - } - - public function testSameInstanceWhenSameProtocol() - { - $r = new Response(); - self::assertSame($r, $r->withProtocolVersion('1.1')); - } - - public function testWithBody() - { - $b = Psr7\Utils::streamFor('0'); - $r = (new Response())->withBody($b); - self::assertInstanceOf('Psr\Http\Message\StreamInterface', $r->getBody()); - self::assertSame('0', (string) $r->getBody()); - } - - public function testSameInstanceWhenSameBody() - { - $r = new Response(); - $b = $r->getBody(); - self::assertSame($r, $r->withBody($b)); - } - - public function testWithHeader() - { - $r = new Response(200, ['Foo' => 'Bar']); - $r2 = $r->withHeader('baZ', 'Bam'); - self::assertSame(['Foo' => ['Bar']], $r->getHeaders()); - self::assertSame(['Foo' => ['Bar'], 'baZ' => ['Bam']], $r2->getHeaders()); - self::assertSame('Bam', $r2->getHeaderLine('baz')); - self::assertSame(['Bam'], $r2->getHeader('baz')); - } - - public function testNumericHeaderValue() - { - $r = (new Response())->withHeader('Api-Version', 1); - self::assertSame(['Api-Version' => ['1']], $r->getHeaders()); - } - - public function testWithHeaderAsArray() - { - $r = new Response(200, ['Foo' => 'Bar']); - $r2 = $r->withHeader('baZ', ['Bam', 'Bar']); - self::assertSame(['Foo' => ['Bar']], $r->getHeaders()); - self::assertSame(['Foo' => ['Bar'], 'baZ' => ['Bam', 'Bar']], $r2->getHeaders()); - self::assertSame('Bam, Bar', $r2->getHeaderLine('baz')); - self::assertSame(['Bam', 'Bar'], $r2->getHeader('baz')); - } - - public function testWithHeaderReplacesDifferentCase() - { - $r = new Response(200, ['Foo' => 'Bar']); - $r2 = $r->withHeader('foO', 'Bam'); - self::assertSame(['Foo' => ['Bar']], $r->getHeaders()); - self::assertSame(['foO' => ['Bam']], $r2->getHeaders()); - self::assertSame('Bam', $r2->getHeaderLine('foo')); - self::assertSame(['Bam'], $r2->getHeader('foo')); - } - - public function testWithAddedHeader() - { - $r = new Response(200, ['Foo' => 'Bar']); - $r2 = $r->withAddedHeader('foO', 'Baz'); - self::assertSame(['Foo' => ['Bar']], $r->getHeaders()); - self::assertSame(['Foo' => ['Bar', 'Baz']], $r2->getHeaders()); - self::assertSame('Bar, Baz', $r2->getHeaderLine('foo')); - self::assertSame(['Bar', 'Baz'], $r2->getHeader('foo')); - } - - public function testWithAddedHeaderAsArray() - { - $r = new Response(200, ['Foo' => 'Bar']); - $r2 = $r->withAddedHeader('foO', ['Baz', 'Bam']); - self::assertSame(['Foo' => ['Bar']], $r->getHeaders()); - self::assertSame(['Foo' => ['Bar', 'Baz', 'Bam']], $r2->getHeaders()); - self::assertSame('Bar, Baz, Bam', $r2->getHeaderLine('foo')); - self::assertSame(['Bar', 'Baz', 'Bam'], $r2->getHeader('foo')); - } - - public function testWithAddedHeaderThatDoesNotExist() - { - $r = new Response(200, ['Foo' => 'Bar']); - $r2 = $r->withAddedHeader('nEw', 'Baz'); - self::assertSame(['Foo' => ['Bar']], $r->getHeaders()); - self::assertSame(['Foo' => ['Bar'], 'nEw' => ['Baz']], $r2->getHeaders()); - self::assertSame('Baz', $r2->getHeaderLine('new')); - self::assertSame(['Baz'], $r2->getHeader('new')); - } - - public function testWithoutHeaderThatExists() - { - $r = new Response(200, ['Foo' => 'Bar', 'Baz' => 'Bam']); - $r2 = $r->withoutHeader('foO'); - self::assertTrue($r->hasHeader('foo')); - self::assertSame(['Foo' => ['Bar'], 'Baz' => ['Bam']], $r->getHeaders()); - self::assertFalse($r2->hasHeader('foo')); - self::assertSame(['Baz' => ['Bam']], $r2->getHeaders()); - } - - public function testWithoutHeaderThatDoesNotExist() - { - $r = new Response(200, ['Baz' => 'Bam']); - $r2 = $r->withoutHeader('foO'); - self::assertSame($r, $r2); - self::assertFalse($r2->hasHeader('foo')); - self::assertSame(['Baz' => ['Bam']], $r2->getHeaders()); - } - - public function testSameInstanceWhenRemovingMissingHeader() - { - $r = new Response(); - self::assertSame($r, $r->withoutHeader('foo')); - } - - public function testPassNumericHeaderNameInConstructor() - { - $r = new Response(200, ['Location' => 'foo', '123' => 'bar']); - self::assertSame('bar', $r->getHeaderLine('123')); - } - - /** - * @dataProvider invalidHeaderProvider - */ - public function testConstructResponseInvalidHeader($header, $headerValue, $expectedMessage) - { - $this->expectExceptionGuzzle('InvalidArgumentException', $expectedMessage); - new Response(200, [$header => $headerValue]); - } - - public function invalidHeaderProvider() - { - return [ - ['foo', [], 'Header value can not be an empty array.'], - ['', '', 'Header name can not be empty.'], - ['foo', new \stdClass(), 'Header value must be scalar or null but stdClass provided.'], - ]; - } - - /** - * @dataProvider invalidWithHeaderProvider - */ - public function testWithInvalidHeader($header, $headerValue, $expectedMessage) - { - $r = new Response(); - $this->expectExceptionGuzzle('InvalidArgumentException', $expectedMessage); - $r->withHeader($header, $headerValue); - } - - public function invalidWithHeaderProvider() - { - return array_merge($this->invalidHeaderProvider(), [ - [[], 'foo', 'Header name must be a string but array provided.'], - [false, 'foo', 'Header name must be a string but boolean provided.'], - [new \stdClass(), 'foo', 'Header name must be a string but stdClass provided.'], - ["", 'foo', "Header name can not be empty."], - ["Content-Type\r\n\r\n", 'foo', "\"Content-Type\r\n\r\n\" is not valid header name."], - ["Content-Type\r\n", 'foo', "\"Content-Type\r\n\" is not valid header name."], - ["Content-Type\n", 'foo', "\"Content-Type\n\" is not valid header name."], - ["\r\nContent-Type", 'foo', "\"\r\nContent-Type\" is not valid header name."], - ["\nContent-Type", 'foo', "\"\nContent-Type\" is not valid header name."], - ["\n", 'foo', "\"\n\" is not valid header name."], - ["\r\n", 'foo', "\"\r\n\" is not valid header name."], - ["\t", 'foo', "\"\t\" is not valid header name."], - ]); - } - - public function testHeaderValuesAreTrimmed() - { - $r1 = new Response(200, ['OWS' => " \t \tFoo\t \t "]); - $r2 = (new Response())->withHeader('OWS', " \t \tFoo\t \t "); - $r3 = (new Response())->withAddedHeader('OWS', " \t \tFoo\t \t "); - - foreach ([$r1, $r2, $r3] as $r) { - self::assertSame(['OWS' => ['Foo']], $r->getHeaders()); - self::assertSame('Foo', $r->getHeaderLine('OWS')); - self::assertSame(['Foo'], $r->getHeader('OWS')); - } - } - - public function testWithAddedHeaderArrayValueAndKeys() - { - $message = (new Response())->withAddedHeader('list', ['foo' => 'one']); - $message = $message->withAddedHeader('list', ['foo' => 'two', 'bar' => 'three']); - - $headerLine = $message->getHeaderLine('list'); - self::assertSame('one, two, three', $headerLine); - } - - /** - * @dataProvider nonIntegerStatusCodeProvider - * - * @param mixed $invalidValues - */ - public function testConstructResponseWithNonIntegerStatusCode($invalidValues) - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'Status code must be an integer value.'); - new Response($invalidValues); - } - - /** - * @dataProvider nonIntegerStatusCodeProvider - * - * @param mixed $invalidValues - */ - public function testResponseChangeStatusCodeWithNonInteger($invalidValues) - { - $response = new Response(); - $this->expectExceptionGuzzle('InvalidArgumentException', 'Status code must be an integer value.'); - $response->withStatus($invalidValues); - } - - public function nonIntegerStatusCodeProvider() - { - return [ - ['whatever'], - ['1.01'], - [1.01], - [new \stdClass()], - ]; - } - - /** - * @dataProvider invalidStatusCodeRangeProvider - * - * @param mixed $invalidValues - */ - public function testConstructResponseWithInvalidRangeStatusCode($invalidValues) - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'Status code must be an integer value between 1xx and 5xx.'); - new Response($invalidValues); - } - - /** - * @dataProvider invalidStatusCodeRangeProvider - * - * @param mixed $invalidValues - */ - public function testResponseChangeStatusCodeWithWithInvalidRange($invalidValues) - { - $response = new Response(); - $this->expectExceptionGuzzle('InvalidArgumentException', 'Status code must be an integer value between 1xx and 5xx.'); - $response->withStatus($invalidValues); - } - - public function invalidStatusCodeRangeProvider() - { - return [ - [600], - [99], - ]; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/ServerRequestTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/ServerRequestTest.php deleted file mode 100644 index 10f46b4a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/ServerRequestTest.php +++ /dev/null @@ -1,544 +0,0 @@ - [ - [ - 'file' => [ - 'name' => 'MyFile.txt', - 'type' => 'text/plain', - 'tmp_name' => '/tmp/php/php1h4j1o', - 'error' => '0', - 'size' => '123' - ] - ], - [ - 'file' => new UploadedFile( - '/tmp/php/php1h4j1o', - 123, - UPLOAD_ERR_OK, - 'MyFile.txt', - 'text/plain' - ) - ] - ], - 'Empty file' => [ - [ - 'image_file' => [ - 'name' => '', - 'type' => '', - 'tmp_name' => '', - 'error' => '4', - 'size' => '0' - ] - ], - [ - 'image_file' => new UploadedFile( - '', - 0, - UPLOAD_ERR_NO_FILE, - '', - '' - ) - ] - ], - 'Already Converted' => [ - [ - 'file' => new UploadedFile( - '/tmp/php/php1h4j1o', - 123, - UPLOAD_ERR_OK, - 'MyFile.txt', - 'text/plain' - ) - ], - [ - 'file' => new UploadedFile( - '/tmp/php/php1h4j1o', - 123, - UPLOAD_ERR_OK, - 'MyFile.txt', - 'text/plain' - ) - ] - ], - 'Already Converted array' => [ - [ - 'file' => [ - new UploadedFile( - '/tmp/php/php1h4j1o', - 123, - UPLOAD_ERR_OK, - 'MyFile.txt', - 'text/plain' - ), - new UploadedFile( - '', - 0, - UPLOAD_ERR_NO_FILE, - '', - '' - ) - ], - ], - [ - 'file' => [ - new UploadedFile( - '/tmp/php/php1h4j1o', - 123, - UPLOAD_ERR_OK, - 'MyFile.txt', - 'text/plain' - ), - new UploadedFile( - '', - 0, - UPLOAD_ERR_NO_FILE, - '', - '' - ) - ], - ] - ], - 'Multiple files' => [ - [ - 'text_file' => [ - 'name' => 'MyFile.txt', - 'type' => 'text/plain', - 'tmp_name' => '/tmp/php/php1h4j1o', - 'error' => '0', - 'size' => '123' - ], - 'image_file' => [ - 'name' => '', - 'type' => '', - 'tmp_name' => '', - 'error' => '4', - 'size' => '0' - ] - ], - [ - 'text_file' => new UploadedFile( - '/tmp/php/php1h4j1o', - 123, - UPLOAD_ERR_OK, - 'MyFile.txt', - 'text/plain' - ), - 'image_file' => new UploadedFile( - '', - 0, - UPLOAD_ERR_NO_FILE, - '', - '' - ) - ] - ], - 'Nested files' => [ - [ - 'file' => [ - 'name' => [ - 0 => 'MyFile.txt', - 1 => 'Image.png', - ], - 'type' => [ - 0 => 'text/plain', - 1 => 'image/png', - ], - 'tmp_name' => [ - 0 => '/tmp/php/hp9hskjhf', - 1 => '/tmp/php/php1h4j1o', - ], - 'error' => [ - 0 => '0', - 1 => '0', - ], - 'size' => [ - 0 => '123', - 1 => '7349', - ], - ], - 'nested' => [ - 'name' => [ - 'other' => 'Flag.txt', - 'test' => [ - 0 => 'Stuff.txt', - 1 => '', - ], - ], - 'type' => [ - 'other' => 'text/plain', - 'test' => [ - 0 => 'text/plain', - 1 => '', - ], - ], - 'tmp_name' => [ - 'other' => '/tmp/php/hp9hskjhf', - 'test' => [ - 0 => '/tmp/php/asifu2gp3', - 1 => '', - ], - ], - 'error' => [ - 'other' => '0', - 'test' => [ - 0 => '0', - 1 => '4', - ], - ], - 'size' => [ - 'other' => '421', - 'test' => [ - 0 => '32', - 1 => '0', - ] - ] - ], - ], - [ - 'file' => [ - 0 => new UploadedFile( - '/tmp/php/hp9hskjhf', - 123, - UPLOAD_ERR_OK, - 'MyFile.txt', - 'text/plain' - ), - 1 => new UploadedFile( - '/tmp/php/php1h4j1o', - 7349, - UPLOAD_ERR_OK, - 'Image.png', - 'image/png' - ), - ], - 'nested' => [ - 'other' => new UploadedFile( - '/tmp/php/hp9hskjhf', - 421, - UPLOAD_ERR_OK, - 'Flag.txt', - 'text/plain' - ), - 'test' => [ - 0 => new UploadedFile( - '/tmp/php/asifu2gp3', - 32, - UPLOAD_ERR_OK, - 'Stuff.txt', - 'text/plain' - ), - 1 => new UploadedFile( - '', - 0, - UPLOAD_ERR_NO_FILE, - '', - '' - ), - ] - ] - ] - ] - ]; - } - - /** - * @dataProvider dataNormalizeFiles - */ - public function testNormalizeFiles($files, $expected) - { - $result = ServerRequest::normalizeFiles($files); - - self::assertEquals($expected, $result); - } - - public function testNormalizeFilesRaisesException() - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'Invalid value in files specification'); - ServerRequest::normalizeFiles(['test' => 'something']); - } - - public function dataGetUriFromGlobals() - { - $server = [ - 'REQUEST_URI' => '/blog/article.php?id=10&user=foo', - 'SERVER_PORT' => '443', - 'SERVER_ADDR' => '217.112.82.20', - 'SERVER_NAME' => 'www.example.org', - 'SERVER_PROTOCOL' => 'HTTP/1.1', - 'REQUEST_METHOD' => 'POST', - 'QUERY_STRING' => 'id=10&user=foo', - 'DOCUMENT_ROOT' => '/path/to/your/server/root/', - 'HTTP_HOST' => 'www.example.org', - 'HTTPS' => 'on', - 'REMOTE_ADDR' => '193.60.168.69', - 'REMOTE_PORT' => '5390', - 'SCRIPT_NAME' => '/blog/article.php', - 'SCRIPT_FILENAME' => '/path/to/your/server/root/blog/article.php', - 'PHP_SELF' => '/blog/article.php', - ]; - - return [ - 'HTTPS request' => [ - 'https://www.example.org/blog/article.php?id=10&user=foo', - $server, - ], - 'HTTPS request with different on value' => [ - 'https://www.example.org/blog/article.php?id=10&user=foo', - array_merge($server, ['HTTPS' => '1']), - ], - 'HTTP request' => [ - 'http://www.example.org/blog/article.php?id=10&user=foo', - array_merge($server, ['HTTPS' => 'off', 'SERVER_PORT' => '80']), - ], - 'HTTP_HOST missing -> fallback to SERVER_NAME' => [ - 'https://www.example.org/blog/article.php?id=10&user=foo', - array_merge($server, ['HTTP_HOST' => null]), - ], - 'HTTP_HOST and SERVER_NAME missing -> fallback to SERVER_ADDR' => [ - 'https://217.112.82.20/blog/article.php?id=10&user=foo', - array_merge($server, ['HTTP_HOST' => null, 'SERVER_NAME' => null]), - ], - 'Query string with ?' => [ - 'https://www.example.org/path?continue=https://example.com/path?param=1', - array_merge($server, ['REQUEST_URI' => '/path?continue=https://example.com/path?param=1', 'QUERY_STRING' => '']), - ], - 'No query String' => [ - 'https://www.example.org/blog/article.php', - array_merge($server, ['REQUEST_URI' => '/blog/article.php', 'QUERY_STRING' => '']), - ], - 'Host header with port' => [ - 'https://www.example.org:8324/blog/article.php?id=10&user=foo', - array_merge($server, ['HTTP_HOST' => 'www.example.org:8324']), - ], - 'IPv6 local loopback address' => [ - 'https://[::1]:8000/blog/article.php?id=10&user=foo', - array_merge($server, ['HTTP_HOST' => '[::1]:8000']), - ], - 'Invalid host' => [ - 'https://localhost/blog/article.php?id=10&user=foo', - array_merge($server, ['HTTP_HOST' => 'a:b']), - ], - 'Different port with SERVER_PORT' => [ - 'https://www.example.org:8324/blog/article.php?id=10&user=foo', - array_merge($server, ['SERVER_PORT' => '8324']), - ], - 'REQUEST_URI missing query string' => [ - 'https://www.example.org/blog/article.php?id=10&user=foo', - array_merge($server, ['REQUEST_URI' => '/blog/article.php']), - ], - 'Empty server variable' => [ - 'http://localhost', - [], - ], - ]; - } - - /** - * @dataProvider dataGetUriFromGlobals - */ - public function testGetUriFromGlobals($expected, $serverParams) - { - $_SERVER = $serverParams; - - self::assertEquals(new Uri($expected), ServerRequest::getUriFromGlobals()); - } - - public function testFromGlobals() - { - $_SERVER = [ - 'REQUEST_URI' => '/blog/article.php?id=10&user=foo', - 'SERVER_PORT' => '443', - 'SERVER_ADDR' => '217.112.82.20', - 'SERVER_NAME' => 'www.example.org', - 'SERVER_PROTOCOL' => 'HTTP/1.1', - 'REQUEST_METHOD' => 'POST', - 'QUERY_STRING' => 'id=10&user=foo', - 'DOCUMENT_ROOT' => '/path/to/your/server/root/', - 'CONTENT_TYPE' => 'text/plain', - 'HTTP_HOST' => 'www.example.org', - 'HTTP_ACCEPT' => 'text/html', - 'HTTP_REFERRER' => 'https://example.com', - 'HTTP_USER_AGENT' => 'My User Agent', - 'HTTPS' => 'on', - 'REMOTE_ADDR' => '193.60.168.69', - 'REMOTE_PORT' => '5390', - 'SCRIPT_NAME' => '/blog/article.php', - 'SCRIPT_FILENAME' => '/path/to/your/server/root/blog/article.php', - 'PHP_SELF' => '/blog/article.php', - ]; - - $_COOKIE = [ - 'logged-in' => 'yes!' - ]; - - $_POST = [ - 'name' => 'Pesho', - 'email' => 'pesho@example.com', - ]; - - $_GET = [ - 'id' => 10, - 'user' => 'foo', - ]; - - $_FILES = [ - 'file' => [ - 'name' => 'MyFile.txt', - 'type' => 'text/plain', - 'tmp_name' => '/tmp/php/php1h4j1o', - 'error' => UPLOAD_ERR_OK, - 'size' => 123, - ] - ]; - - $server = ServerRequest::fromGlobals(); - - self::assertSame('POST', $server->getMethod()); - self::assertEquals([ - 'Host' => ['www.example.org'], - 'Content-Type' => ['text/plain'], - 'Accept' => ['text/html'], - 'Referrer' => ['https://example.com'], - 'User-Agent' => ['My User Agent'], - ], $server->getHeaders()); - self::assertSame('', (string) $server->getBody()); - self::assertSame('1.1', $server->getProtocolVersion()); - self::assertSame($_COOKIE, $server->getCookieParams()); - self::assertSame($_POST, $server->getParsedBody()); - self::assertSame($_GET, $server->getQueryParams()); - - self::assertEquals( - new Uri('https://www.example.org/blog/article.php?id=10&user=foo'), - $server->getUri() - ); - - $expectedFiles = [ - 'file' => new UploadedFile( - '/tmp/php/php1h4j1o', - 123, - UPLOAD_ERR_OK, - 'MyFile.txt', - 'text/plain' - ), - ]; - - self::assertEquals($expectedFiles, $server->getUploadedFiles()); - } - - public function testUploadedFiles() - { - $request1 = new ServerRequest('GET', '/'); - - $files = [ - 'file' => new UploadedFile('test', 123, UPLOAD_ERR_OK) - ]; - - $request2 = $request1->withUploadedFiles($files); - - self::assertNotSame($request2, $request1); - self::assertSame([], $request1->getUploadedFiles()); - self::assertSame($files, $request2->getUploadedFiles()); - } - - public function testServerParams() - { - $params = ['name' => 'value']; - - $request = new ServerRequest('GET', '/', [], null, '1.1', $params); - self::assertSame($params, $request->getServerParams()); - } - - public function testCookieParams() - { - $request1 = new ServerRequest('GET', '/'); - - $params = ['name' => 'value']; - - $request2 = $request1->withCookieParams($params); - - self::assertNotSame($request2, $request1); - self::assertEmpty($request1->getCookieParams()); - self::assertSame($params, $request2->getCookieParams()); - } - - public function testQueryParams() - { - $request1 = new ServerRequest('GET', '/'); - - $params = ['name' => 'value']; - - $request2 = $request1->withQueryParams($params); - - self::assertNotSame($request2, $request1); - self::assertEmpty($request1->getQueryParams()); - self::assertSame($params, $request2->getQueryParams()); - } - - public function testParsedBody() - { - $request1 = new ServerRequest('GET', '/'); - - $params = ['name' => 'value']; - - $request2 = $request1->withParsedBody($params); - - self::assertNotSame($request2, $request1); - self::assertEmpty($request1->getParsedBody()); - self::assertSame($params, $request2->getParsedBody()); - } - - public function testAttributes() - { - $request1 = new ServerRequest('GET', '/'); - - $request2 = $request1->withAttribute('name', 'value'); - $request3 = $request2->withAttribute('other', 'otherValue'); - $request4 = $request3->withoutAttribute('other'); - $request5 = $request3->withoutAttribute('unknown'); - - self::assertNotSame($request2, $request1); - self::assertNotSame($request3, $request2); - self::assertNotSame($request4, $request3); - self::assertSame($request5, $request3); - - self::assertSame([], $request1->getAttributes()); - self::assertNull($request1->getAttribute('name')); - self::assertSame( - 'something', - $request1->getAttribute('name', 'something'), - 'Should return the default value' - ); - - self::assertSame('value', $request2->getAttribute('name')); - self::assertSame(['name' => 'value'], $request2->getAttributes()); - self::assertEquals(['name' => 'value', 'other' => 'otherValue'], $request3->getAttributes()); - self::assertSame(['name' => 'value'], $request4->getAttributes()); - } - - public function testNullAttribute() - { - $request = (new ServerRequest('GET', '/'))->withAttribute('name', null); - - self::assertSame(['name' => null], $request->getAttributes()); - self::assertNull($request->getAttribute('name', 'different-default')); - - $requestWithoutAttribute = $request->withoutAttribute('name'); - - self::assertSame([], $requestWithoutAttribute->getAttributes()); - self::assertSame('different-default', $requestWithoutAttribute->getAttribute('name', 'different-default')); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/StreamDecoratorTraitTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/StreamDecoratorTraitTest.php deleted file mode 100644 index 365e7f37..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/StreamDecoratorTraitTest.php +++ /dev/null @@ -1,147 +0,0 @@ -c = fopen('php://temp', 'r+'); - fwrite($this->c, 'foo'); - fseek($this->c, 0); - $this->a = Psr7\Utils::streamFor($this->c); - $this->b = new Str($this->a); - } - - public function testCatchesExceptionsWhenCastingToString() - { - $s = $this->getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['read']) - ->getMockForAbstractClass(); - $s->expects(self::once()) - ->method('read') - ->will(self::throwException(new \Exception('foo'))); - $msg = ''; - set_error_handler(function ($errNo, $str) use (&$msg) { - $msg = $str; - }); - echo new Str($s); - restore_error_handler(); - $this->assertStringContainsStringGuzzle('foo', $msg); - } - - public function testToString() - { - self::assertSame('foo', (string) $this->b); - } - - public function testHasSize() - { - self::assertSame(3, $this->b->getSize()); - } - - public function testReads() - { - self::assertSame('foo', $this->b->read(10)); - } - - public function testCheckMethods() - { - self::assertSame($this->a->isReadable(), $this->b->isReadable()); - self::assertSame($this->a->isWritable(), $this->b->isWritable()); - self::assertSame($this->a->isSeekable(), $this->b->isSeekable()); - } - - public function testSeeksAndTells() - { - $this->b->seek(1); - self::assertSame(1, $this->a->tell()); - self::assertSame(1, $this->b->tell()); - $this->b->seek(0); - self::assertSame(0, $this->a->tell()); - self::assertSame(0, $this->b->tell()); - $this->b->seek(0, SEEK_END); - self::assertSame(3, $this->a->tell()); - self::assertSame(3, $this->b->tell()); - } - - public function testGetsContents() - { - self::assertSame('foo', $this->b->getContents()); - self::assertSame('', $this->b->getContents()); - $this->b->seek(1); - self::assertSame('oo', $this->b->getContents()); - } - - public function testCloses() - { - $this->b->close(); - self::assertFalse(is_resource($this->c)); - } - - public function testDetaches() - { - $this->b->detach(); - self::assertFalse($this->b->isReadable()); - } - - public function testWrapsMetadata() - { - self::assertSame($this->b->getMetadata(), $this->a->getMetadata()); - self::assertSame($this->b->getMetadata('uri'), $this->a->getMetadata('uri')); - } - - public function testWrapsWrites() - { - $this->b->seek(0, SEEK_END); - $this->b->write('foo'); - self::assertSame('foofoo', (string) $this->a); - } - - public function testThrowsWithInvalidGetter() - { - $this->expectExceptionGuzzle('UnexpectedValueException'); - - $this->b->foo; - } - - public function testThrowsWhenGetterNotImplemented() - { - $s = new BadStream(); - - $this->expectExceptionGuzzle('BadMethodCallException'); - - $s->stream; - } -} - -class BadStream -{ - use StreamDecoratorTrait; - - public function __construct() - { - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/StreamTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/StreamTest.php deleted file mode 100644 index 3cd2a504..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/StreamTest.php +++ /dev/null @@ -1,403 +0,0 @@ -expectExceptionGuzzle('InvalidArgumentException'); - - new Stream(true); - } - - public function testConstructorInitializesProperties() - { - $handle = fopen('php://temp', 'r+'); - fwrite($handle, 'data'); - $stream = new Stream($handle); - self::assertTrue($stream->isReadable()); - self::assertTrue($stream->isWritable()); - self::assertTrue($stream->isSeekable()); - self::assertSame('php://temp', $stream->getMetadata('uri')); - $this->assertInternalTypeGuzzle('array', $stream->getMetadata()); - self::assertSame(4, $stream->getSize()); - self::assertFalse($stream->eof()); - $stream->close(); - } - - public function testConstructorInitializesPropertiesWithRbPlus() - { - $handle = fopen('php://temp', 'rb+'); - fwrite($handle, 'data'); - $stream = new Stream($handle); - self::assertTrue($stream->isReadable()); - self::assertTrue($stream->isWritable()); - self::assertTrue($stream->isSeekable()); - self::assertSame('php://temp', $stream->getMetadata('uri')); - $this->assertInternalTypeGuzzle('array', $stream->getMetadata()); - self::assertSame(4, $stream->getSize()); - self::assertFalse($stream->eof()); - $stream->close(); - } - - public function testStreamClosesHandleOnDestruct() - { - $handle = fopen('php://temp', 'r'); - $stream = new Stream($handle); - unset($stream); - self::assertFalse(is_resource($handle)); - } - - public function testConvertsToString() - { - $handle = fopen('php://temp', 'w+'); - fwrite($handle, 'data'); - $stream = new Stream($handle); - self::assertSame('data', (string) $stream); - self::assertSame('data', (string) $stream); - $stream->close(); - } - - public function testConvertsToStringNonSeekableStream() - { - if (defined('HHVM_VERSION')) { - self::markTestSkipped('This does not work on HHVM.'); - } - - $handle = popen('echo foo', 'r'); - $stream = new Stream($handle); - self::assertFalse($stream->isSeekable()); - self::assertSame('foo', trim((string) $stream)); - } - - public function testConvertsToStringNonSeekablePartiallyReadStream() - { - if (defined('HHVM_VERSION')) { - self::markTestSkipped('This does not work on HHVM.'); - } - - $handle = popen('echo bar', 'r'); - $stream = new Stream($handle); - $firstLetter = $stream->read(1); - self::assertFalse($stream->isSeekable()); - self::assertSame('b', $firstLetter); - self::assertSame('ar', trim((string) $stream)); - } - - public function testGetsContents() - { - $handle = fopen('php://temp', 'w+'); - fwrite($handle, 'data'); - $stream = new Stream($handle); - self::assertSame('', $stream->getContents()); - $stream->seek(0); - self::assertSame('data', $stream->getContents()); - self::assertSame('', $stream->getContents()); - $stream->close(); - } - - public function testChecksEof() - { - $handle = fopen('php://temp', 'w+'); - fwrite($handle, 'data'); - $stream = new Stream($handle); - self::assertSame(4, $stream->tell(), 'Stream cursor already at the end'); - self::assertFalse($stream->eof(), 'Stream still not eof'); - self::assertSame('', $stream->read(1), 'Need to read one more byte to reach eof'); - self::assertTrue($stream->eof()); - $stream->close(); - } - - public function testGetSize() - { - $size = filesize(__FILE__); - $handle = fopen(__FILE__, 'r'); - $stream = new Stream($handle); - self::assertSame($size, $stream->getSize()); - // Load from cache - self::assertSame($size, $stream->getSize()); - $stream->close(); - } - - public function testEnsuresSizeIsConsistent() - { - $h = fopen('php://temp', 'w+'); - self::assertSame(3, fwrite($h, 'foo')); - $stream = new Stream($h); - self::assertSame(3, $stream->getSize()); - self::assertSame(4, $stream->write('test')); - self::assertSame(7, $stream->getSize()); - self::assertSame(7, $stream->getSize()); - $stream->close(); - } - - public function testProvidesStreamPosition() - { - $handle = fopen('php://temp', 'w+'); - $stream = new Stream($handle); - self::assertSame(0, $stream->tell()); - $stream->write('foo'); - self::assertSame(3, $stream->tell()); - $stream->seek(1); - self::assertSame(1, $stream->tell()); - self::assertSame(ftell($handle), $stream->tell()); - $stream->close(); - } - - public function testDetachStreamAndClearProperties() - { - $handle = fopen('php://temp', 'r'); - $stream = new Stream($handle); - self::assertSame($handle, $stream->detach()); - $this->assertInternalTypeGuzzle('resource', $handle, 'Stream is not closed'); - self::assertNull($stream->detach()); - - $this->assertStreamStateAfterClosedOrDetached($stream); - - $stream->close(); - } - - public function testCloseResourceAndClearProperties() - { - $handle = fopen('php://temp', 'r'); - $stream = new Stream($handle); - $stream->close(); - - self::assertFalse(is_resource($handle)); - - $this->assertStreamStateAfterClosedOrDetached($stream); - } - - private function assertStreamStateAfterClosedOrDetached(Stream $stream) - { - self::assertFalse($stream->isReadable()); - self::assertFalse($stream->isWritable()); - self::assertFalse($stream->isSeekable()); - self::assertNull($stream->getSize()); - self::assertSame([], $stream->getMetadata()); - self::assertNull($stream->getMetadata('foo')); - - $throws = function (callable $fn) { - try { - $fn(); - } catch (\Exception $e) { - $this->assertStringContainsStringGuzzle('Stream is detached', $e->getMessage()); - - return; - } - - $this->fail('Exception should be thrown after the stream is detached.'); - }; - - $throws(function () use ($stream) { - $stream->read(10); - }); - $throws(function () use ($stream) { - $stream->write('bar'); - }); - $throws(function () use ($stream) { - $stream->seek(10); - }); - $throws(function () use ($stream) { - $stream->tell(); - }); - $throws(function () use ($stream) { - $stream->eof(); - }); - $throws(function () use ($stream) { - $stream->getContents(); - }); - self::assertSame('', (string) $stream); - } - - public function testStreamReadingWithZeroLength() - { - $r = fopen('php://temp', 'r'); - $stream = new Stream($r); - - self::assertSame('', $stream->read(0)); - - $stream->close(); - } - - public function testStreamReadingWithNegativeLength() - { - $r = fopen('php://temp', 'r'); - $stream = new Stream($r); - - $this->expectExceptionGuzzle('RuntimeException', 'Length parameter cannot be negative'); - - try { - $stream->read(-1); - } catch (\Exception $e) { - $stream->close(); - throw $e; - } - - $stream->close(); - } - - public function testStreamReadingFreadError() - { - self::$isFReadError = true; - $r = fopen('php://temp', 'r'); - $stream = new Stream($r); - - $this->expectExceptionGuzzle('RuntimeException', 'Unable to read from stream'); - - try { - $stream->read(1); - } catch (\Exception $e) { - self::$isFReadError = false; - $stream->close(); - throw $e; - } - - self::$isFReadError = false; - $stream->close(); - } - - /** - * @dataProvider gzipModeProvider - * - * @param string $mode - * @param bool $readable - * @param bool $writable - */ - public function testGzipStreamModes($mode, $readable, $writable) - { - if (defined('HHVM_VERSION')) { - self::markTestSkipped('This does not work on HHVM.'); - } - - $r = gzopen('php://temp', $mode); - $stream = new Stream($r); - - self::assertSame($readable, $stream->isReadable()); - self::assertSame($writable, $stream->isWritable()); - - $stream->close(); - } - - public function gzipModeProvider() - { - return [ - ['mode' => 'rb9', 'readable' => true, 'writable' => false], - ['mode' => 'wb2', 'readable' => false, 'writable' => true], - ]; - } - - /** - * @dataProvider readableModeProvider - * - * @param string $mode - */ - public function testReadableStream($mode) - { - $r = fopen('php://temp', $mode); - $stream = new Stream($r); - - self::assertTrue($stream->isReadable()); - - $stream->close(); - } - - public function readableModeProvider() - { - return [ - ['r'], - ['w+'], - ['r+'], - ['x+'], - ['c+'], - ['rb'], - ['w+b'], - ['r+b'], - ['x+b'], - ['c+b'], - ['rt'], - ['w+t'], - ['r+t'], - ['x+t'], - ['c+t'], - ['a+'], - ['rb+'], - ]; - } - - public function testWriteOnlyStreamIsNotReadable() - { - $r = fopen('php://output', 'w'); - $stream = new Stream($r); - - self::assertFalse($stream->isReadable()); - - $stream->close(); - } - - /** - * @dataProvider writableModeProvider - * - * @param string $mode - */ - public function testWritableStream($mode) - { - $r = fopen('php://temp', $mode); - $stream = new Stream($r); - - self::assertTrue($stream->isWritable()); - - $stream->close(); - } - - public function writableModeProvider() - { - return [ - ['w'], - ['w+'], - ['rw'], - ['r+'], - ['x+'], - ['c+'], - ['wb'], - ['w+b'], - ['r+b'], - ['rb+'], - ['x+b'], - ['c+b'], - ['w+t'], - ['r+t'], - ['x+t'], - ['c+t'], - ['a'], - ['a+'], - ]; - } - - public function testReadOnlyStreamIsNotWritable() - { - $r = fopen('php://input', 'r'); - $stream = new Stream($r); - - self::assertFalse($stream->isWritable()); - - $stream->close(); - } -} - -namespace GuzzleHttp\Psr7; - -use GuzzleHttp\Tests\Psr7\StreamTest; - -function fread($handle, $length) -{ - return StreamTest::$isFReadError ? false : \fread($handle, $length); -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/StreamWrapperTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/StreamWrapperTest.php deleted file mode 100644 index e6a8ae64..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/StreamWrapperTest.php +++ /dev/null @@ -1,200 +0,0 @@ - 0, - 1 => 0, - 2 => 33206, - 3 => 0, - 4 => 0, - 5 => 0, - 6 => 0, - 7 => 6, - 8 => 0, - 9 => 0, - 10 => 0, - 11 => $stBlksize, - 12 => $stBlksize, - 'dev' => 0, - 'ino' => 0, - 'mode' => 33206, - 'nlink' => 0, - 'uid' => 0, - 'gid' => 0, - 'rdev' => 0, - 'size' => 6, - 'atime' => 0, - 'mtime' => 0, - 'ctime' => 0, - 'blksize' => $stBlksize, - 'blocks' => $stBlksize, - ], fstat($handle)); - } - - self::assertTrue(fclose($handle)); - self::assertSame('foobar', (string) $stream); - } - - public function testStreamContext() - { - $stream = Psr7\Utils::streamFor('foo'); - - self::assertSame('foo', file_get_contents('guzzle://stream', false, StreamWrapper::createStreamContext($stream))); - } - - public function testStreamCast() - { - $streams = [ - StreamWrapper::getResource(Psr7\Utils::streamFor('foo')), - StreamWrapper::getResource(Psr7\Utils::streamFor('bar')) - ]; - $write = null; - $except = null; - $this->assertInternalTypeGuzzle('integer', stream_select($streams, $write, $except, 0)); - } - - public function testValidatesStream() - { - $stream = $this->getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['isReadable', 'isWritable']) - ->getMockForAbstractClass(); - $stream->expects(self::once()) - ->method('isReadable') - ->will(self::returnValue(false)); - $stream->expects(self::once()) - ->method('isWritable') - ->will(self::returnValue(false)); - - $this->expectExceptionGuzzle('InvalidArgumentException'); - - StreamWrapper::getResource($stream); - } - - public function testReturnsFalseWhenStreamDoesNotExist() - { - $this->expectWarningGuzzle(); - - fopen('guzzle://foo', 'r'); - } - - public function testCanOpenReadonlyStream() - { - $stream = $this->getMockBuilder('Psr\Http\Message\StreamInterface') - ->setMethods(['isReadable', 'isWritable']) - ->getMockForAbstractClass(); - $stream->expects(self::once()) - ->method('isReadable') - ->will(self::returnValue(false)); - $stream->expects(self::once()) - ->method('isWritable') - ->will(self::returnValue(true)); - $r = StreamWrapper::getResource($stream); - $this->assertInternalTypeGuzzle('resource', $r); - fclose($r); - } - - public function testUrlStat() - { - StreamWrapper::register(); - - $stBlksize = defined('PHP_WINDOWS_VERSION_BUILD') ? -1 : 0; - - self::assertSame([ - 0 => 0, - 1 => 0, - 2 => 0, - 3 => 0, - 4 => 0, - 5 => 0, - 6 => 0, - 7 => 0, - 8 => 0, - 9 => 0, - 10 => 0, - 11 => $stBlksize, - 12 => $stBlksize, - 'dev' => 0, - 'ino' => 0, - 'mode' => 0, - 'nlink' => 0, - 'uid' => 0, - 'gid' => 0, - 'rdev' => 0, - 'size' => 0, - 'atime' => 0, - 'mtime' => 0, - 'ctime' => 0, - 'blksize' => $stBlksize, - 'blocks' => $stBlksize, - ], stat('guzzle://stream')); - } - - public function testXmlReaderWithStream() - { - if (!class_exists('XMLReader')) { - self::markTestSkipped('XML Reader is not available.'); - } - if (defined('HHVM_VERSION')) { - self::markTestSkipped('This does not work on HHVM.'); - } - - $stream = Psr7\Utils::streamFor(''); - - StreamWrapper::register(); - libxml_set_streams_context(StreamWrapper::createStreamContext($stream)); - $reader = new \XMLReader(); - - self::assertTrue($reader->open('guzzle://stream')); - self::assertTrue($reader->read()); - self::assertSame('foo', $reader->name); - } - - public function testXmlWriterWithStream() - { - if (!class_exists('XMLWriter')) { - self::markTestSkipped('XML Writer is not available.'); - } - if (defined('HHVM_VERSION')) { - self::markTestSkipped('This does not work on HHVM.'); - } - - $stream = Psr7\Utils::streamFor(fopen('php://memory', 'wb')); - - StreamWrapper::register(); - libxml_set_streams_context(StreamWrapper::createStreamContext($stream)); - $writer = new \XMLWriter(); - - self::assertTrue($writer->openURI('guzzle://stream')); - self::assertTrue($writer->startDocument()); - self::assertTrue($writer->writeElement('foo')); - self::assertTrue($writer->endDocument()); - - $stream->rewind(); - self::assertXmlStringEqualsXmlString('', (string) $stream); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/UploadedFileTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/UploadedFileTest.php deleted file mode 100644 index d41dee52..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/UploadedFileTest.php +++ /dev/null @@ -1,287 +0,0 @@ -cleanup = []; - } - - /** - * @after - */ - public function tearDownTest() - { - foreach ($this->cleanup as $file) { - if (is_scalar($file) && file_exists($file)) { - unlink($file); - } - } - } - - public function invalidStreams() - { - return [ - 'null' => [null], - 'true' => [true], - 'false' => [false], - 'int' => [1], - 'float' => [1.1], - 'array' => [['filename']], - 'object' => [(object) ['filename']], - ]; - } - - /** - * @dataProvider invalidStreams - */ - public function testRaisesExceptionOnInvalidStreamOrFile($streamOrFile) - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - - new UploadedFile($streamOrFile, 0, UPLOAD_ERR_OK); - } - - public function invalidSizes() - { - return [ - 'null' => [null], - 'float' => [1.1], - 'array' => [[1]], - 'object' => [(object) [1]], - ]; - } - - /** - * @dataProvider invalidSizes - */ - public function testRaisesExceptionOnInvalidSize($size) - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'size'); - - new UploadedFile(fopen('php://temp', 'wb+'), $size, UPLOAD_ERR_OK); - } - - public function invalidErrorStatuses() - { - return [ - 'null' => [null], - 'true' => [true], - 'false' => [false], - 'float' => [1.1], - 'string' => ['1'], - 'array' => [[1]], - 'object' => [(object) [1]], - 'negative' => [-1], - 'too-big' => [9], - ]; - } - - /** - * @dataProvider invalidErrorStatuses - */ - public function testRaisesExceptionOnInvalidErrorStatus($status) - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'status'); - - new UploadedFile(fopen('php://temp', 'wb+'), 0, $status); - } - - public function invalidFilenamesAndMediaTypes() - { - return [ - 'true' => [true], - 'false' => [false], - 'int' => [1], - 'float' => [1.1], - 'array' => [['string']], - 'object' => [(object) ['string']], - ]; - } - - /** - * @dataProvider invalidFilenamesAndMediaTypes - */ - public function testRaisesExceptionOnInvalidClientFilename($filename) - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'filename'); - - new UploadedFile(fopen('php://temp', 'wb+'), 0, UPLOAD_ERR_OK, $filename); - } - - /** - * @dataProvider invalidFilenamesAndMediaTypes - */ - public function testRaisesExceptionOnInvalidClientMediaType($mediaType) - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'media type'); - - new UploadedFile(fopen('php://temp', 'wb+'), 0, UPLOAD_ERR_OK, 'foobar.baz', $mediaType); - } - - public function testGetStreamReturnsOriginalStreamObject() - { - $stream = new Stream(fopen('php://temp', 'r')); - $upload = new UploadedFile($stream, 0, UPLOAD_ERR_OK); - - self::assertSame($stream, $upload->getStream()); - } - - public function testGetStreamReturnsWrappedPhpStream() - { - $stream = fopen('php://temp', 'wb+'); - $upload = new UploadedFile($stream, 0, UPLOAD_ERR_OK); - $uploadStream = $upload->getStream()->detach(); - - self::assertSame($stream, $uploadStream); - } - - public function testGetStreamReturnsStreamForFile() - { - $this->cleanup[] = $stream = tempnam(sys_get_temp_dir(), 'stream_file'); - $upload = new UploadedFile($stream, 0, UPLOAD_ERR_OK); - $uploadStream = $upload->getStream(); - $r = new ReflectionProperty($uploadStream, 'filename'); - $r->setAccessible(true); - - self::assertSame($stream, $r->getValue($uploadStream)); - } - - public function testSuccessful() - { - $stream = \GuzzleHttp\Psr7\Utils::streamFor('Foo bar!'); - $upload = new UploadedFile($stream, $stream->getSize(), UPLOAD_ERR_OK, 'filename.txt', 'text/plain'); - - self::assertSame($stream->getSize(), $upload->getSize()); - self::assertSame('filename.txt', $upload->getClientFilename()); - self::assertSame('text/plain', $upload->getClientMediaType()); - - $this->cleanup[] = $to = tempnam(sys_get_temp_dir(), 'successful'); - $upload->moveTo($to); - self::assertFileExists($to); - self::assertSame($stream->__toString(), file_get_contents($to)); - } - - public function invalidMovePaths() - { - return [ - 'null' => [null], - 'true' => [true], - 'false' => [false], - 'int' => [1], - 'float' => [1.1], - 'empty' => [''], - 'array' => [['filename']], - 'object' => [(object) ['filename']], - ]; - } - - /** - * @dataProvider invalidMovePaths - */ - public function testMoveRaisesExceptionForInvalidPath($path) - { - $stream = \GuzzleHttp\Psr7\Utils::streamFor('Foo bar!'); - $upload = new UploadedFile($stream, 0, UPLOAD_ERR_OK); - - $this->cleanup[] = $path; - - $this->expectExceptionGuzzle('InvalidArgumentException', 'path'); - $upload->moveTo($path); - } - - public function testMoveCannotBeCalledMoreThanOnce() - { - $stream = \GuzzleHttp\Psr7\Utils::streamFor('Foo bar!'); - $upload = new UploadedFile($stream, 0, UPLOAD_ERR_OK); - - $this->cleanup[] = $to = tempnam(sys_get_temp_dir(), 'diac'); - $upload->moveTo($to); - self::assertFileExists($to); - - $this->expectExceptionGuzzle('RuntimeException', 'moved'); - $upload->moveTo($to); - } - - public function testCannotRetrieveStreamAfterMove() - { - $stream = \GuzzleHttp\Psr7\Utils::streamFor('Foo bar!'); - $upload = new UploadedFile($stream, 0, UPLOAD_ERR_OK); - - $this->cleanup[] = $to = tempnam(sys_get_temp_dir(), 'diac'); - $upload->moveTo($to); - self::assertFileExists($to); - - $this->expectExceptionGuzzle('RuntimeException', 'moved'); - $upload->getStream(); - } - - public function nonOkErrorStatus() - { - return [ - 'UPLOAD_ERR_INI_SIZE' => [ UPLOAD_ERR_INI_SIZE ], - 'UPLOAD_ERR_FORM_SIZE' => [ UPLOAD_ERR_FORM_SIZE ], - 'UPLOAD_ERR_PARTIAL' => [ UPLOAD_ERR_PARTIAL ], - 'UPLOAD_ERR_NO_FILE' => [ UPLOAD_ERR_NO_FILE ], - 'UPLOAD_ERR_NO_TMP_DIR' => [ UPLOAD_ERR_NO_TMP_DIR ], - 'UPLOAD_ERR_CANT_WRITE' => [ UPLOAD_ERR_CANT_WRITE ], - 'UPLOAD_ERR_EXTENSION' => [ UPLOAD_ERR_EXTENSION ], - ]; - } - - /** - * @dataProvider nonOkErrorStatus - */ - public function testConstructorDoesNotRaiseExceptionForInvalidStreamWhenErrorStatusPresent($status) - { - $uploadedFile = new UploadedFile('not ok', 0, $status); - self::assertSame($status, $uploadedFile->getError()); - } - - /** - * @dataProvider nonOkErrorStatus - */ - public function testMoveToRaisesExceptionWhenErrorStatusPresent($status) - { - $uploadedFile = new UploadedFile('not ok', 0, $status); - $this->expectExceptionGuzzle('RuntimeException', 'upload error'); - $uploadedFile->moveTo(__DIR__ . '/' . sha1(uniqid('', true))); - } - - /** - * @dataProvider nonOkErrorStatus - */ - public function testGetStreamRaisesExceptionWhenErrorStatusPresent($status) - { - $uploadedFile = new UploadedFile('not ok', 0, $status); - $this->expectExceptionGuzzle('RuntimeException', 'upload error'); - $uploadedFile->getStream(); - } - - public function testMoveToCreatesStreamIfOnlyAFilenameWasProvided() - { - $this->cleanup[] = $from = tempnam(sys_get_temp_dir(), 'copy_from'); - $this->cleanup[] = $to = tempnam(sys_get_temp_dir(), 'copy_to'); - - copy(__FILE__, $from); - - $uploadedFile = new UploadedFile($from, 100, UPLOAD_ERR_OK, basename($from), 'text/plain'); - $uploadedFile->moveTo($to); - - self::assertFileEquals(__FILE__, $to); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/UriComparatorTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/UriComparatorTest.php deleted file mode 100644 index ccfdd7b7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/UriComparatorTest.php +++ /dev/null @@ -1,42 +0,0 @@ -withPath("/$actualEncoding")->withQuery($actualEncoding); - - self::assertSame("/$actualEncoding?$actualEncoding", (string) $uri, 'Not normalized automatically beforehand'); - - $normalizedUri = UriNormalizer::normalize($uri, UriNormalizer::CAPITALIZE_PERCENT_ENCODING); - - self::assertInstanceOf('Psr\Http\Message\UriInterface', $normalizedUri); - self::assertSame("/$expectEncoding?$expectEncoding", (string) $normalizedUri); - } - - /** - * @dataProvider getUnreservedCharacters - */ - public function testDecodeUnreservedCharacters($char) - { - $percentEncoded = '%' . bin2hex($char); - // Add encoded reserved characters to test that those are not decoded and include the percent-encoded - // unreserved character both in lower and upper case to test the decoding is case-insensitive. - $encodedChars = $percentEncoded . '%2F%5B' . strtoupper($percentEncoded); - $uri = (new Uri())->withPath("/$encodedChars")->withQuery($encodedChars); - - self::assertSame("/$encodedChars?$encodedChars", (string) $uri, 'Not normalized automatically beforehand'); - - $normalizedUri = UriNormalizer::normalize($uri, UriNormalizer::DECODE_UNRESERVED_CHARACTERS); - - self::assertInstanceOf('Psr\Http\Message\UriInterface', $normalizedUri); - self::assertSame("/$char%2F%5B$char?$char%2F%5B$char", (string) $normalizedUri); - } - - public function getUnreservedCharacters() - { - $unreservedChars = array_merge(range('a', 'z'), range('A', 'Z'), range('0', '9'), ['-', '.', '_', '~']); - - return array_map(function ($char) { - return [$char]; - }, $unreservedChars); - } - - /** - * @dataProvider getEmptyPathTestCases - */ - public function testConvertEmptyPath($uri, $expected) - { - $normalizedUri = UriNormalizer::normalize(new Uri($uri), UriNormalizer::CONVERT_EMPTY_PATH); - - self::assertInstanceOf('Psr\Http\Message\UriInterface', $normalizedUri); - self::assertSame($expected, (string) $normalizedUri); - } - - public function getEmptyPathTestCases() - { - return [ - ['http://example.org', 'http://example.org/'], - ['https://example.org', 'https://example.org/'], - ['urn://example.org', 'urn://example.org'], - ]; - } - - public function testRemoveDefaultHost() - { - $uri = new Uri('file://localhost/myfile'); - $normalizedUri = UriNormalizer::normalize($uri, UriNormalizer::REMOVE_DEFAULT_HOST); - - self::assertInstanceOf('Psr\Http\Message\UriInterface', $normalizedUri); - self::assertSame('file:///myfile', (string) $normalizedUri); - } - - public function testRemoveDefaultPort() - { - $uri = $this->getMockBuilder('Psr\Http\Message\UriInterface')->getMock(); - $uri->expects(self::any())->method('getScheme')->will(self::returnValue('http')); - $uri->expects(self::any())->method('getPort')->will(self::returnValue(80)); - $uri->expects(self::once())->method('withPort')->with(null)->will(self::returnValue(new Uri('http://example.org'))); - - $normalizedUri = UriNormalizer::normalize($uri, UriNormalizer::REMOVE_DEFAULT_PORT); - - self::assertInstanceOf('Psr\Http\Message\UriInterface', $normalizedUri); - self::assertNull($normalizedUri->getPort()); - } - - public function testRemoveDotSegments() - { - $uri = new Uri('http://example.org/../a/b/../c/./d.html'); - $normalizedUri = UriNormalizer::normalize($uri, UriNormalizer::REMOVE_DOT_SEGMENTS); - - self::assertInstanceOf('Psr\Http\Message\UriInterface', $normalizedUri); - self::assertSame('http://example.org/a/c/d.html', (string) $normalizedUri); - } - - public function testRemoveDotSegmentsOfAbsolutePathReference() - { - $uri = new Uri('/../a/b/../c/./d.html'); - $normalizedUri = UriNormalizer::normalize($uri, UriNormalizer::REMOVE_DOT_SEGMENTS); - - self::assertInstanceOf('Psr\Http\Message\UriInterface', $normalizedUri); - self::assertSame('/a/c/d.html', (string) $normalizedUri); - } - - public function testRemoveDotSegmentsOfRelativePathReference() - { - $uri = new Uri('../c/./d.html'); - $normalizedUri = UriNormalizer::normalize($uri, UriNormalizer::REMOVE_DOT_SEGMENTS); - - self::assertInstanceOf('Psr\Http\Message\UriInterface', $normalizedUri); - self::assertSame('../c/./d.html', (string) $normalizedUri); - } - - public function testRemoveDuplicateSlashes() - { - $uri = new Uri('http://example.org//foo///bar/bam.html'); - $normalizedUri = UriNormalizer::normalize($uri, UriNormalizer::REMOVE_DUPLICATE_SLASHES); - - self::assertInstanceOf('Psr\Http\Message\UriInterface', $normalizedUri); - self::assertSame('http://example.org/foo/bar/bam.html', (string) $normalizedUri); - } - - public function testSortQueryParameters() - { - $uri = new Uri('?lang=en&article=fred'); - $normalizedUri = UriNormalizer::normalize($uri, UriNormalizer::SORT_QUERY_PARAMETERS); - - self::assertInstanceOf('Psr\Http\Message\UriInterface', $normalizedUri); - self::assertSame('?article=fred&lang=en', (string) $normalizedUri); - } - - public function testSortQueryParametersWithSameKeys() - { - $uri = new Uri('?a=b&b=c&a=a&a&b=a&b=b&a=d&a=c'); - $normalizedUri = UriNormalizer::normalize($uri, UriNormalizer::SORT_QUERY_PARAMETERS); - - self::assertInstanceOf('Psr\Http\Message\UriInterface', $normalizedUri); - self::assertSame('?a&a=a&a=b&a=c&a=d&b=a&b=b&b=c', (string) $normalizedUri); - } - - /** - * @dataProvider getEquivalentTestCases - */ - public function testIsEquivalent($uri1, $uri2, $expected) - { - $equivalent = UriNormalizer::isEquivalent(new Uri($uri1), new Uri($uri2)); - - self::assertSame($expected, $equivalent); - } - - public function getEquivalentTestCases() - { - return [ - ['http://example.org', 'http://example.org', true], - ['hTTp://eXaMpLe.org', 'http://example.org', true], - ['http://example.org/path?#', 'http://example.org/path', true], - ['http://example.org:80', 'http://example.org/', true], - ['http://example.org/../a/.././p%61th?%7a=%5e', 'http://example.org/path?z=%5E', true], - ['https://example.org/', 'http://example.org/', false], - ['https://example.org/', '//example.org/', false], - ['//example.org/', '//example.org/', true], - ['file:/myfile', 'file:///myfile', true], - ['file:///myfile', 'file://localhost/myfile', true], - ]; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/UriResolverTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/UriResolverTest.php deleted file mode 100644 index 6f41409b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/UriResolverTest.php +++ /dev/null @@ -1,204 +0,0 @@ -getScheme()); - self::assertSame('user:pass@example.com:8080', $uri->getAuthority()); - self::assertSame('user:pass', $uri->getUserInfo()); - self::assertSame('example.com', $uri->getHost()); - self::assertSame(8080, $uri->getPort()); - self::assertSame('/path/123', $uri->getPath()); - self::assertSame('q=abc', $uri->getQuery()); - self::assertSame('test', $uri->getFragment()); - self::assertSame('https://user:pass@example.com:8080/path/123?q=abc#test', (string) $uri); - } - - public function testCanTransformAndRetrievePartsIndividually() - { - $uri = (new Uri()) - ->withScheme('https') - ->withUserInfo('user', 'pass') - ->withHost('example.com') - ->withPort(8080) - ->withPath('/path/123') - ->withQuery('q=abc') - ->withFragment('test'); - - self::assertSame('https', $uri->getScheme()); - self::assertSame('user:pass@example.com:8080', $uri->getAuthority()); - self::assertSame('user:pass', $uri->getUserInfo()); - self::assertSame('example.com', $uri->getHost()); - self::assertSame(8080, $uri->getPort()); - self::assertSame('/path/123', $uri->getPath()); - self::assertSame('q=abc', $uri->getQuery()); - self::assertSame('test', $uri->getFragment()); - self::assertSame('https://user:pass@example.com:8080/path/123?q=abc#test', (string) $uri); - } - - /** - * @dataProvider getValidUris - */ - public function testValidUrisStayValid($input) - { - $uri = new Uri($input); - - self::assertSame($input, (string) $uri); - } - - /** - * @dataProvider getValidUris - */ - public function testFromParts($input) - { - $uri = Uri::fromParts(parse_url($input)); - - self::assertSame($input, (string) $uri); - } - - public function getValidUris() - { - return [ - ['urn:path-rootless'], - ['urn:path:with:colon'], - ['urn:/path-absolute'], - ['urn:/'], - // only scheme with empty path - ['urn:'], - // only path - ['/'], - ['relative/'], - ['0'], - // same document reference - [''], - // network path without scheme - ['//example.org'], - ['//example.org/'], - ['//example.org?q#h'], - // only query - ['?q'], - ['?q=abc&foo=bar'], - // only fragment - ['#fragment'], - // dot segments are not removed automatically - ['./foo/../bar'], - ]; - } - - /** - * @dataProvider getInvalidUris - */ - public function testInvalidUrisThrowException($invalidUri) - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'Unable to parse URI'); - - new Uri($invalidUri); - } - - public function getInvalidUris() - { - return [ - // parse_url() requires the host component which makes sense for http(s) - // but not when the scheme is not known or different. So '//' or '///' is - // currently invalid as well but should not according to RFC 3986. - ['http://'], - ['urn://host:with:colon'], // host cannot contain ":" - ]; - } - - public function testPortMustBeValid() - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'Must be between 0 and 65535'); - - (new Uri())->withPort(100000); - } - - public function testWithPortCannotBeNegative() - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'Invalid port: -1. Must be between 0 and 65535'); - - (new Uri())->withPort(-1); - } - - public function testParseUriPortCannotBeNegative() - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'Unable to parse URI'); - - new Uri('//example.com:-1'); - } - - public function testSchemeMustHaveCorrectType() - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - - (new Uri())->withScheme([]); - } - - public function testHostMustHaveCorrectType() - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - - (new Uri())->withHost([]); - } - - public function testPathMustHaveCorrectType() - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - - (new Uri())->withPath([]); - } - - public function testQueryMustHaveCorrectType() - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - - (new Uri())->withQuery([]); - } - - public function testFragmentMustHaveCorrectType() - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - - (new Uri())->withFragment([]); - } - - public function testCanParseFalseyUriParts() - { - $uri = new Uri('0://0:0@0/0?0#0'); - - self::assertSame('0', $uri->getScheme()); - self::assertSame('0:0@0', $uri->getAuthority()); - self::assertSame('0:0', $uri->getUserInfo()); - self::assertSame('0', $uri->getHost()); - self::assertSame('/0', $uri->getPath()); - self::assertSame('0', $uri->getQuery()); - self::assertSame('0', $uri->getFragment()); - self::assertSame('0://0:0@0/0?0#0', (string) $uri); - } - - public function testCanConstructFalseyUriParts() - { - $uri = (new Uri()) - ->withScheme('0') - ->withUserInfo('0', '0') - ->withHost('0') - ->withPath('/0') - ->withQuery('0') - ->withFragment('0'); - - self::assertSame('0', $uri->getScheme()); - self::assertSame('0:0@0', $uri->getAuthority()); - self::assertSame('0:0', $uri->getUserInfo()); - self::assertSame('0', $uri->getHost()); - self::assertSame('/0', $uri->getPath()); - self::assertSame('0', $uri->getQuery()); - self::assertSame('0', $uri->getFragment()); - self::assertSame('0://0:0@0/0?0#0', (string) $uri); - } - - /** - * @dataProvider getPortTestCases - */ - public function testIsDefaultPort($scheme, $port, $isDefaultPort) - { - $uri = $this->getMockBuilder('Psr\Http\Message\UriInterface')->getMock(); - $uri->expects(self::any())->method('getScheme')->will(self::returnValue($scheme)); - $uri->expects(self::any())->method('getPort')->will(self::returnValue($port)); - - self::assertSame($isDefaultPort, Uri::isDefaultPort($uri)); - } - - public function getPortTestCases() - { - return [ - ['http', null, true], - ['http', 80, true], - ['http', 8080, false], - ['https', null, true], - ['https', 443, true], - ['https', 444, false], - ['ftp', 21, true], - ['gopher', 70, true], - ['nntp', 119, true], - ['news', 119, true], - ['telnet', 23, true], - ['tn3270', 23, true], - ['imap', 143, true], - ['pop', 110, true], - ['ldap', 389, true], - ]; - } - - public function testIsAbsolute() - { - self::assertTrue(Uri::isAbsolute(new Uri('http://example.org'))); - self::assertFalse(Uri::isAbsolute(new Uri('//example.org'))); - self::assertFalse(Uri::isAbsolute(new Uri('/abs-path'))); - self::assertFalse(Uri::isAbsolute(new Uri('rel-path'))); - } - - public function testIsNetworkPathReference() - { - self::assertFalse(Uri::isNetworkPathReference(new Uri('http://example.org'))); - self::assertTrue(Uri::isNetworkPathReference(new Uri('//example.org'))); - self::assertFalse(Uri::isNetworkPathReference(new Uri('/abs-path'))); - self::assertFalse(Uri::isNetworkPathReference(new Uri('rel-path'))); - } - - public function testIsAbsolutePathReference() - { - self::assertFalse(Uri::isAbsolutePathReference(new Uri('http://example.org'))); - self::assertFalse(Uri::isAbsolutePathReference(new Uri('//example.org'))); - self::assertTrue(Uri::isAbsolutePathReference(new Uri('/abs-path'))); - self::assertTrue(Uri::isAbsolutePathReference(new Uri('/'))); - self::assertFalse(Uri::isAbsolutePathReference(new Uri('rel-path'))); - } - - public function testIsRelativePathReference() - { - self::assertFalse(Uri::isRelativePathReference(new Uri('http://example.org'))); - self::assertFalse(Uri::isRelativePathReference(new Uri('//example.org'))); - self::assertFalse(Uri::isRelativePathReference(new Uri('/abs-path'))); - self::assertTrue(Uri::isRelativePathReference(new Uri('rel-path'))); - self::assertTrue(Uri::isRelativePathReference(new Uri(''))); - } - - public function testIsSameDocumentReference() - { - self::assertFalse(Uri::isSameDocumentReference(new Uri('http://example.org'))); - self::assertFalse(Uri::isSameDocumentReference(new Uri('//example.org'))); - self::assertFalse(Uri::isSameDocumentReference(new Uri('/abs-path'))); - self::assertFalse(Uri::isSameDocumentReference(new Uri('rel-path'))); - self::assertFalse(Uri::isSameDocumentReference(new Uri('?query'))); - self::assertTrue(Uri::isSameDocumentReference(new Uri(''))); - self::assertTrue(Uri::isSameDocumentReference(new Uri('#fragment'))); - - $baseUri = new Uri('http://example.org/path?foo=bar'); - - self::assertTrue(Uri::isSameDocumentReference(new Uri('#fragment'), $baseUri)); - self::assertTrue(Uri::isSameDocumentReference(new Uri('?foo=bar#fragment'), $baseUri)); - self::assertTrue(Uri::isSameDocumentReference(new Uri('/path?foo=bar#fragment'), $baseUri)); - self::assertTrue(Uri::isSameDocumentReference(new Uri('path?foo=bar#fragment'), $baseUri)); - self::assertTrue(Uri::isSameDocumentReference(new Uri('//example.org/path?foo=bar#fragment'), $baseUri)); - self::assertTrue(Uri::isSameDocumentReference(new Uri('http://example.org/path?foo=bar#fragment'), $baseUri)); - - self::assertFalse(Uri::isSameDocumentReference(new Uri('https://example.org/path?foo=bar'), $baseUri)); - self::assertFalse(Uri::isSameDocumentReference(new Uri('http://example.com/path?foo=bar'), $baseUri)); - self::assertFalse(Uri::isSameDocumentReference(new Uri('http://example.org/'), $baseUri)); - self::assertFalse(Uri::isSameDocumentReference(new Uri('http://example.org'), $baseUri)); - - self::assertFalse(Uri::isSameDocumentReference(new Uri('urn:/path'), new Uri('urn://example.com/path'))); - } - - public function testAddAndRemoveQueryValues() - { - $uri = new Uri(); - $uri = Uri::withQueryValue($uri, 'a', 'b'); - $uri = Uri::withQueryValue($uri, 'c', 'd'); - $uri = Uri::withQueryValue($uri, 'e', null); - self::assertSame('a=b&c=d&e', $uri->getQuery()); - - $uri = Uri::withoutQueryValue($uri, 'c'); - self::assertSame('a=b&e', $uri->getQuery()); - $uri = Uri::withoutQueryValue($uri, 'e'); - self::assertSame('a=b', $uri->getQuery()); - $uri = Uri::withoutQueryValue($uri, 'a'); - self::assertSame('', $uri->getQuery()); - } - - public function testNumericQueryValue() - { - $uri = Uri::withQueryValue(new Uri(), 'version', 1); - self::assertSame('version=1', $uri->getQuery()); - } - - public function testWithQueryValues() - { - $uri = new Uri(); - $uri = Uri::withQueryValues($uri, [ - 'key1' => 'value1', - 'key2' => 'value2' - ]); - - self::assertSame('key1=value1&key2=value2', $uri->getQuery()); - } - - public function testWithQueryValuesReplacesSameKeys() - { - $uri = new Uri(); - - $uri = Uri::withQueryValues($uri, [ - 'key1' => 'value1', - 'key2' => 'value2' - ]); - - $uri = Uri::withQueryValues($uri, [ - 'key2' => 'newvalue' - ]); - - self::assertSame('key1=value1&key2=newvalue', $uri->getQuery()); - } - - public function testWithQueryValueReplacesSameKeys() - { - $uri = new Uri(); - $uri = Uri::withQueryValue($uri, 'a', 'b'); - $uri = Uri::withQueryValue($uri, 'c', 'd'); - $uri = Uri::withQueryValue($uri, 'a', 'e'); - self::assertSame('c=d&a=e', $uri->getQuery()); - } - - public function testWithoutQueryValueRemovesAllSameKeys() - { - $uri = (new Uri())->withQuery('a=b&c=d&a=e'); - $uri = Uri::withoutQueryValue($uri, 'a'); - self::assertSame('c=d', $uri->getQuery()); - } - - public function testRemoveNonExistingQueryValue() - { - $uri = new Uri(); - $uri = Uri::withQueryValue($uri, 'a', 'b'); - $uri = Uri::withoutQueryValue($uri, 'c'); - self::assertSame('a=b', $uri->getQuery()); - } - - public function testWithQueryValueHandlesEncoding() - { - $uri = new Uri(); - $uri = Uri::withQueryValue($uri, 'E=mc^2', 'ein&stein'); - self::assertSame('E%3Dmc%5E2=ein%26stein', $uri->getQuery(), 'Decoded key/value get encoded'); - - $uri = new Uri(); - $uri = Uri::withQueryValue($uri, 'E%3Dmc%5e2', 'ein%26stein'); - self::assertSame('E%3Dmc%5e2=ein%26stein', $uri->getQuery(), 'Encoded key/value do not get double-encoded'); - } - - public function testWithoutQueryValueHandlesEncoding() - { - // It also tests that the case of the percent-encoding does not matter, - // i.e. both lowercase "%3d" and uppercase "%5E" can be removed. - $uri = (new Uri())->withQuery('E%3dmc%5E2=einstein&foo=bar'); - $uri = Uri::withoutQueryValue($uri, 'E=mc^2'); - self::assertSame('foo=bar', $uri->getQuery(), 'Handles key in decoded form'); - - $uri = (new Uri())->withQuery('E%3dmc%5E2=einstein&foo=bar'); - $uri = Uri::withoutQueryValue($uri, 'E%3Dmc%5e2'); - self::assertSame('foo=bar', $uri->getQuery(), 'Handles key in encoded form'); - } - - public function testSchemeIsNormalizedToLowercase() - { - $uri = new Uri('HTTP://example.com'); - - self::assertSame('http', $uri->getScheme()); - self::assertSame('http://example.com', (string) $uri); - - $uri = (new Uri('//example.com'))->withScheme('HTTP'); - - self::assertSame('http', $uri->getScheme()); - self::assertSame('http://example.com', (string) $uri); - } - - public function testHostIsNormalizedToLowercase() - { - $uri = new Uri('//eXaMpLe.CoM'); - - self::assertSame('example.com', $uri->getHost()); - self::assertSame('//example.com', (string) $uri); - - $uri = (new Uri())->withHost('eXaMpLe.CoM'); - - self::assertSame('example.com', $uri->getHost()); - self::assertSame('//example.com', (string) $uri); - } - - public function testPortIsNullIfStandardPortForScheme() - { - // HTTPS standard port - $uri = new Uri('https://example.com:443'); - self::assertNull($uri->getPort()); - self::assertSame('example.com', $uri->getAuthority()); - - $uri = (new Uri('https://example.com'))->withPort(443); - self::assertNull($uri->getPort()); - self::assertSame('example.com', $uri->getAuthority()); - - // HTTP standard port - $uri = new Uri('http://example.com:80'); - self::assertNull($uri->getPort()); - self::assertSame('example.com', $uri->getAuthority()); - - $uri = (new Uri('http://example.com'))->withPort(80); - self::assertNull($uri->getPort()); - self::assertSame('example.com', $uri->getAuthority()); - } - - public function testPortIsReturnedIfSchemeUnknown() - { - $uri = (new Uri('//example.com'))->withPort(80); - - self::assertSame(80, $uri->getPort()); - self::assertSame('example.com:80', $uri->getAuthority()); - } - - public function testStandardPortIsNullIfSchemeChanges() - { - $uri = new Uri('http://example.com:443'); - self::assertSame('http', $uri->getScheme()); - self::assertSame(443, $uri->getPort()); - - $uri = $uri->withScheme('https'); - self::assertNull($uri->getPort()); - } - - public function testPortPassedAsStringIsCastedToInt() - { - $uri = (new Uri('//example.com'))->withPort('8080'); - - self::assertSame(8080, $uri->getPort(), 'Port is returned as integer'); - self::assertSame('example.com:8080', $uri->getAuthority()); - } - - public function testPortCanBeRemoved() - { - $uri = (new Uri('http://example.com:8080'))->withPort(null); - - self::assertNull($uri->getPort()); - self::assertSame('http://example.com', (string) $uri); - } - - /** - * In RFC 8986 the host is optional and the authority can only - * consist of the user info and port. - */ - public function testAuthorityWithUserInfoOrPortButWithoutHost() - { - $uri = (new Uri())->withUserInfo('user', 'pass'); - - self::assertSame('user:pass', $uri->getUserInfo()); - self::assertSame('user:pass@', $uri->getAuthority()); - - $uri = $uri->withPort(8080); - self::assertSame(8080, $uri->getPort()); - self::assertSame('user:pass@:8080', $uri->getAuthority()); - self::assertSame('//user:pass@:8080', (string) $uri); - - $uri = $uri->withUserInfo(''); - self::assertSame(':8080', $uri->getAuthority()); - } - - public function testHostInHttpUriDefaultsToLocalhost() - { - $uri = (new Uri())->withScheme('http'); - - self::assertSame('localhost', $uri->getHost()); - self::assertSame('localhost', $uri->getAuthority()); - self::assertSame('http://localhost', (string) $uri); - } - - public function testHostInHttpsUriDefaultsToLocalhost() - { - $uri = (new Uri())->withScheme('https'); - - self::assertSame('localhost', $uri->getHost()); - self::assertSame('localhost', $uri->getAuthority()); - self::assertSame('https://localhost', (string) $uri); - } - - public function testFileSchemeWithEmptyHostReconstruction() - { - $uri = new Uri('file:///tmp/filename.ext'); - - self::assertSame('', $uri->getHost()); - self::assertSame('', $uri->getAuthority()); - self::assertSame('file:///tmp/filename.ext', (string) $uri); - } - - public function uriComponentsEncodingProvider() - { - $unreserved = 'a-zA-Z0-9.-_~!$&\'()*+,;=:@'; - - return [ - // Percent encode spaces - ['/pa th?q=va lue#frag ment', '/pa%20th', 'q=va%20lue', 'frag%20ment', '/pa%20th?q=va%20lue#frag%20ment'], - // Percent encode multibyte - ['/€?€#€', '/%E2%82%AC', '%E2%82%AC', '%E2%82%AC', '/%E2%82%AC?%E2%82%AC#%E2%82%AC'], - // Don't encode something that's already encoded - ['/pa%20th?q=va%20lue#frag%20ment', '/pa%20th', 'q=va%20lue', 'frag%20ment', '/pa%20th?q=va%20lue#frag%20ment'], - // Percent encode invalid percent encodings - ['/pa%2-th?q=va%2-lue#frag%2-ment', '/pa%252-th', 'q=va%252-lue', 'frag%252-ment', '/pa%252-th?q=va%252-lue#frag%252-ment'], - // Don't encode path segments - ['/pa/th//two?q=va/lue#frag/ment', '/pa/th//two', 'q=va/lue', 'frag/ment', '/pa/th//two?q=va/lue#frag/ment'], - // Don't encode unreserved chars or sub-delimiters - ["/$unreserved?$unreserved#$unreserved", "/$unreserved", $unreserved, $unreserved, "/$unreserved?$unreserved#$unreserved"], - // Encoded unreserved chars are not decoded - ['/p%61th?q=v%61lue#fr%61gment', '/p%61th', 'q=v%61lue', 'fr%61gment', '/p%61th?q=v%61lue#fr%61gment'], - ]; - } - - /** - * @dataProvider uriComponentsEncodingProvider - */ - public function testUriComponentsGetEncodedProperly($input, $path, $query, $fragment, $output) - { - $uri = new Uri($input); - self::assertSame($path, $uri->getPath()); - self::assertSame($query, $uri->getQuery()); - self::assertSame($fragment, $uri->getFragment()); - self::assertSame($output, (string) $uri); - } - - public function testWithPathEncodesProperly() - { - $uri = (new Uri())->withPath('/baz?#€/b%61r'); - // Query and fragment delimiters and multibyte chars are encoded. - self::assertSame('/baz%3F%23%E2%82%AC/b%61r', $uri->getPath()); - self::assertSame('/baz%3F%23%E2%82%AC/b%61r', (string) $uri); - } - - public function testWithQueryEncodesProperly() - { - $uri = (new Uri())->withQuery('?=#&€=/&b%61r'); - // A query starting with a "?" is valid and must not be magically removed. Otherwise it would be impossible to - // construct such an URI. Also the "?" and "/" does not need to be encoded in the query. - self::assertSame('?=%23&%E2%82%AC=/&b%61r', $uri->getQuery()); - self::assertSame('??=%23&%E2%82%AC=/&b%61r', (string) $uri); - } - - public function testWithFragmentEncodesProperly() - { - $uri = (new Uri())->withFragment('#€?/b%61r'); - // A fragment starting with a "#" is valid and must not be magically removed. Otherwise it would be impossible to - // construct such an URI. Also the "?" and "/" does not need to be encoded in the fragment. - self::assertSame('%23%E2%82%AC?/b%61r', $uri->getFragment()); - self::assertSame('#%23%E2%82%AC?/b%61r', (string) $uri); - } - - public function testAllowsForRelativeUri() - { - $uri = (new Uri)->withPath('foo'); - self::assertSame('foo', $uri->getPath()); - self::assertSame('foo', (string) $uri); - } - - public function testRelativePathAndAuhorityIsAutomagicallyFixed() - { - // concatenating a relative path with a host doesn't work: "//example.comfoo" would be wrong - $uri = (new Uri)->withPath('foo')->withHost('example.com'); - self::assertSame('/foo', $uri->getPath()); - self::assertSame('//example.com/foo', (string) $uri); - } - - public function testPathStartingWithTwoSlashesAndNoAuthorityIsInvalid() - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'The path of a URI without an authority must not start with two slashes "//"'); - - // URI "//foo" would be interpreted as network reference and thus change the original path to the host - (new Uri)->withPath('//foo'); - } - - public function testPathStartingWithTwoSlashes() - { - $uri = new Uri('http://example.org//path-not-host.com'); - self::assertSame('//path-not-host.com', $uri->getPath()); - - $uri = $uri->withScheme(''); - self::assertSame('//example.org//path-not-host.com', (string) $uri); // This is still valid - $this->expectExceptionGuzzle('\InvalidArgumentException'); - $uri->withHost(''); // Now it becomes invalid - } - - public function testRelativeUriWithPathBeginngWithColonSegmentIsInvalid() - { - $this->expectExceptionGuzzle('InvalidArgumentException', 'A relative URI must not have a path beginning with a segment containing a colon'); - - (new Uri)->withPath('mailto:foo'); - } - - public function testRelativeUriWithPathHavingColonSegment() - { - $uri = (new Uri('urn:/mailto:foo'))->withScheme(''); - self::assertSame('/mailto:foo', $uri->getPath()); - - $this->expectExceptionGuzzle('\InvalidArgumentException'); - (new Uri('urn:mailto:foo'))->withScheme(''); - } - - public function testDefaultReturnValuesOfGetters() - { - $uri = new Uri(); - - self::assertSame('', $uri->getScheme()); - self::assertSame('', $uri->getAuthority()); - self::assertSame('', $uri->getUserInfo()); - self::assertSame('', $uri->getHost()); - self::assertNull($uri->getPort()); - self::assertSame('', $uri->getPath()); - self::assertSame('', $uri->getQuery()); - self::assertSame('', $uri->getFragment()); - } - - public function testImmutability() - { - $uri = new Uri(); - - self::assertNotSame($uri, $uri->withScheme('https')); - self::assertNotSame($uri, $uri->withUserInfo('user', 'pass')); - self::assertNotSame($uri, $uri->withHost('example.com')); - self::assertNotSame($uri, $uri->withPort(8080)); - self::assertNotSame($uri, $uri->withPath('/path/123')); - self::assertNotSame($uri, $uri->withQuery('q=abc')); - self::assertNotSame($uri, $uri->withFragment('test')); - } - - public function testExtendingClassesInstantiates() - { - // The non-standard port triggers a cascade of private methods which - // should not use late static binding to access private static members. - // If they do, this will fatal. - self::assertInstanceOf( - 'GuzzleHttp\Tests\Psr7\ExtendedUriTest', - new ExtendedUriTest('http://h:9/') - ); - } - - public function testSpecialCharsOfUserInfo() - { - // The `userInfo` must always be URL-encoded. - $uri = (new Uri)->withUserInfo('foo@bar.com', 'pass#word'); - self::assertSame('foo%40bar.com:pass%23word', $uri->getUserInfo()); - - // The `userInfo` can already be URL-encoded: it should not be encoded twice. - $uri = (new Uri)->withUserInfo('foo%40bar.com', 'pass%23word'); - self::assertSame('foo%40bar.com:pass%23word', $uri->getUserInfo()); - } - - public function testInternationalizedDomainName() - { - $uri = new Uri('https://яндекс.рф'); - self::assertSame('яндекс.рф', $uri->getHost()); - - $uri = new Uri('https://яндекAс.рф'); - self::assertSame('яндекaс.рф', $uri->getHost()); - } - - public function testIPv6Host() - { - $uri = new Uri('https://[2a00:f48:1008::212:183:10]'); - self::assertSame('[2a00:f48:1008::212:183:10]', $uri->getHost()); - - $uri = new Uri('http://[2a00:f48:1008::212:183:10]:56?foo=bar'); - self::assertSame('[2a00:f48:1008::212:183:10]', $uri->getHost()); - self::assertSame(56, $uri->getPort()); - self::assertSame('foo=bar', $uri->getQuery()); - } -} - -class ExtendedUriTest extends Uri -{ -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/UtilsTest.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/UtilsTest.php deleted file mode 100644 index 4f62e3a3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/vendor/guzzlehttp/psr7/tests/UtilsTest.php +++ /dev/null @@ -1,469 +0,0 @@ -seek(0); - self::assertSame('foo', Psr7\Utils::copyToString($s, 3)); - self::assertSame('baz', Psr7\Utils::copyToString($s, 3)); - self::assertSame('', Psr7\Utils::copyToString($s)); - } - - public function testCopiesToStringStopsWhenReadFails() - { - $s1 = Psr7\Utils::streamFor('foobaz'); - $s1 = FnStream::decorate($s1, [ - 'read' => function () { - return ''; - }, - ]); - $result = Psr7\Utils::copyToString($s1); - self::assertSame('', $result); - } - - public function testCopiesToStream() - { - $s1 = Psr7\Utils::streamFor('foobaz'); - $s2 = Psr7\Utils::streamFor(''); - Psr7\Utils::copyToStream($s1, $s2); - self::assertSame('foobaz', (string)$s2); - $s2 = Psr7\Utils::streamFor(''); - $s1->seek(0); - Psr7\Utils::copyToStream($s1, $s2, 3); - self::assertSame('foo', (string)$s2); - Psr7\Utils::copyToStream($s1, $s2, 3); - self::assertSame('foobaz', (string)$s2); - } - - public function testStopsCopyToStreamWhenWriteFails() - { - $s1 = Psr7\Utils::streamFor('foobaz'); - $s2 = Psr7\Utils::streamFor(''); - $s2 = FnStream::decorate($s2, [ - 'write' => function () { - return 0; - }, - ]); - Psr7\Utils::copyToStream($s1, $s2); - self::assertSame('', (string)$s2); - } - - public function testStopsCopyToSteamWhenWriteFailsWithMaxLen() - { - $s1 = Psr7\Utils::streamFor('foobaz'); - $s2 = Psr7\Utils::streamFor(''); - $s2 = FnStream::decorate($s2, [ - 'write' => function () { - return 0; - }, - ]); - Psr7\Utils::copyToStream($s1, $s2, 10); - self::assertSame('', (string)$s2); - } - - public function testCopyToStreamReadsInChunksInsteadOfAllInMemory() - { - $sizes = []; - $s1 = new Psr7\FnStream([ - 'eof' => function () { - return false; - }, - 'read' => function ($size) use (&$sizes) { - $sizes[] = $size; - return str_repeat('.', $size); - }, - ]); - $s2 = Psr7\Utils::streamFor(''); - Psr7\Utils::copyToStream($s1, $s2, 16394); - $s2->seek(0); - self::assertSame(16394, strlen($s2->getContents())); - self::assertSame(8192, $sizes[0]); - self::assertSame(8192, $sizes[1]); - self::assertSame(10, $sizes[2]); - } - - public function testStopsCopyToSteamWhenReadFailsWithMaxLen() - { - $s1 = Psr7\Utils::streamFor('foobaz'); - $s1 = FnStream::decorate($s1, [ - 'read' => function () { - return ''; - }, - ]); - $s2 = Psr7\Utils::streamFor(''); - Psr7\Utils::copyToStream($s1, $s2, 10); - self::assertSame('', (string)$s2); - } - - public function testReadsLines() - { - $s = Psr7\Utils::streamFor("foo\nbaz\nbar"); - self::assertSame("foo\n", Psr7\Utils::readLine($s)); - self::assertSame("baz\n", Psr7\Utils::readLine($s)); - self::assertSame('bar', Psr7\Utils::readLine($s)); - } - - public function testReadsLinesUpToMaxLength() - { - $s = Psr7\Utils::streamFor("12345\n"); - self::assertSame('123', Psr7\Utils::readLine($s, 4)); - self::assertSame("45\n", Psr7\Utils::readLine($s)); - } - - public function testReadLinesEof() - { - // Should return empty string on EOF - $s = Psr7\Utils::streamFor("foo\nbar"); - while (!$s->eof()) { - Psr7\Utils::readLine($s); - } - self::assertSame('', Psr7\Utils::readLine($s)); - } - - public function testReadsLineUntilFalseReturnedFromRead() - { - $s = $this->getMockBuilder('GuzzleHttp\Psr7\Stream') - ->setMethods(['read', 'eof']) - ->disableOriginalConstructor() - ->getMock(); - $s->expects(self::exactly(2)) - ->method('read') - ->will(self::returnCallback(function () { - static $c = false; - if ($c) { - return false; - } - $c = true; - return 'h'; - })); - $s->expects(self::exactly(2)) - ->method('eof') - ->will(self::returnValue(false)); - self::assertSame('h', Psr7\Utils::readLine($s)); - } - - public function testCalculatesHash() - { - $s = Psr7\Utils::streamFor('foobazbar'); - self::assertSame(md5('foobazbar'), Psr7\Utils::hash($s, 'md5')); - } - - public function testCalculatesHashThrowsWhenSeekFails() - { - $s = new NoSeekStream(Psr7\Utils::streamFor('foobazbar')); - $s->read(2); - - $this->expectExceptionGuzzle('RuntimeException'); - - Psr7\Utils::hash($s, 'md5'); - } - - public function testCalculatesHashSeeksToOriginalPosition() - { - $s = Psr7\Utils::streamFor('foobazbar'); - $s->seek(4); - self::assertSame(md5('foobazbar'), Psr7\Utils::hash($s, 'md5')); - self::assertSame(4, $s->tell()); - } - - public function testOpensFilesSuccessfully() - { - $r = Psr7\Utils::tryFopen(__FILE__, 'r'); - $this->assertInternalTypeGuzzle('resource', $r); - fclose($r); - } - - public function testThrowsExceptionNotWarning() - { - $this->expectExceptionGuzzle('RuntimeException', 'Unable to open "/path/to/does/not/exist" using mode "r"'); - - Psr7\Utils::tryFopen('/path/to/does/not/exist', 'r'); - } - - public function testThrowsExceptionNotValueError() - { - $this->expectExceptionGuzzle('RuntimeException', 'Unable to open "" using mode "r"'); - - Psr7\Utils::tryFopen('', 'r'); - } - - public function testCreatesUriForValue() - { - self::assertInstanceOf('GuzzleHttp\Psr7\Uri', Psr7\Utils::uriFor('/foo')); - self::assertInstanceOf( - 'GuzzleHttp\Psr7\Uri', - Psr7\Utils::uriFor(new Psr7\Uri('/foo')) - ); - } - - public function testValidatesUri() - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - - Psr7\Utils::uriFor([]); - } - - public function testKeepsPositionOfResource() - { - $h = fopen(__FILE__, 'r'); - fseek($h, 10); - $stream = Psr7\Utils::streamFor($h); - self::assertSame(10, $stream->tell()); - $stream->close(); - } - - public function testCreatesWithFactory() - { - $stream = Psr7\Utils::streamFor('foo'); - self::assertInstanceOf('GuzzleHttp\Psr7\Stream', $stream); - self::assertSame('foo', $stream->getContents()); - $stream->close(); - } - - public function testFactoryCreatesFromEmptyString() - { - $s = Psr7\Utils::streamFor(); - self::assertInstanceOf('GuzzleHttp\Psr7\Stream', $s); - } - - public function testFactoryCreatesFromNull() - { - $s = Psr7\Utils::streamFor(null); - self::assertInstanceOf('GuzzleHttp\Psr7\Stream', $s); - } - - public function testFactoryCreatesFromResource() - { - $r = fopen(__FILE__, 'r'); - $s = Psr7\Utils::streamFor($r); - self::assertInstanceOf('GuzzleHttp\Psr7\Stream', $s); - self::assertSame(file_get_contents(__FILE__), (string)$s); - } - - public function testFactoryCreatesFromObjectWithToString() - { - $r = new HasToString(); - $s = Psr7\Utils::streamFor($r); - self::assertInstanceOf('GuzzleHttp\Psr7\Stream', $s); - self::assertSame('foo', (string)$s); - } - - public function testCreatePassesThrough() - { - $s = Psr7\Utils::streamFor('foo'); - self::assertSame($s, Psr7\Utils::streamFor($s)); - } - - public function testThrowsExceptionForUnknown() - { - $this->expectExceptionGuzzle('InvalidArgumentException'); - - Psr7\Utils::streamFor(new \stdClass()); - } - - public function testReturnsCustomMetadata() - { - $s = Psr7\Utils::streamFor('foo', ['metadata' => ['hwm' => 3]]); - self::assertSame(3, $s->getMetadata('hwm')); - self::assertArrayHasKey('hwm', $s->getMetadata()); - } - - public function testCanSetSize() - { - $s = Psr7\Utils::streamFor('', ['size' => 10]); - self::assertSame(10, $s->getSize()); - } - - public function testCanCreateIteratorBasedStream() - { - $a = new \ArrayIterator(['foo', 'bar', '123']); - $p = Psr7\Utils::streamFor($a); - self::assertInstanceOf('GuzzleHttp\Psr7\PumpStream', $p); - self::assertSame('foo', $p->read(3)); - self::assertFalse($p->eof()); - self::assertSame('b', $p->read(1)); - self::assertSame('a', $p->read(1)); - self::assertSame('r12', $p->read(3)); - self::assertFalse($p->eof()); - self::assertSame('3', $p->getContents()); - self::assertTrue($p->eof()); - self::assertSame(9, $p->tell()); - } - - public function testConvertsRequestsToStrings() - { - $request = new Psr7\Request('PUT', 'http://foo.com/hi?123', [ - 'Baz' => 'bar', - 'Qux' => 'ipsum', - ], 'hello', '1.0'); - self::assertSame( - "PUT /hi?123 HTTP/1.0\r\nHost: foo.com\r\nBaz: bar\r\nQux: ipsum\r\n\r\nhello", - Psr7\Message::toString($request) - ); - } - - public function testConvertsResponsesToStrings() - { - $response = new Psr7\Response(200, [ - 'Baz' => 'bar', - 'Qux' => 'ipsum', - ], 'hello', '1.0', 'FOO'); - self::assertSame( - "HTTP/1.0 200 FOO\r\nBaz: bar\r\nQux: ipsum\r\n\r\nhello", - Psr7\Message::toString($response) - ); - } - - public function testCorrectlyRendersSetCookieHeadersToString() - { - $response = new Psr7\Response(200, [ - 'Set-Cookie' => ['bar','baz','qux'] - ], 'hello', '1.0', 'FOO'); - self::assertSame( - "HTTP/1.0 200 FOO\r\nSet-Cookie: bar\r\nSet-Cookie: baz\r\nSet-Cookie: qux\r\n\r\nhello", - Psr7\Message::toString($response) - ); - } - - public function testCanModifyRequestWithUri() - { - $r1 = new Psr7\Request('GET', 'http://foo.com'); - $r2 = Psr7\Utils::modifyRequest($r1, [ - 'uri' => new Psr7\Uri('http://www.foo.com'), - ]); - self::assertSame('http://www.foo.com', (string)$r2->getUri()); - self::assertSame('www.foo.com', (string)$r2->getHeaderLine('host')); - } - - public function testCanModifyRequestWithUriAndPort() - { - $r1 = new Psr7\Request('GET', 'http://foo.com:8000'); - $r2 = Psr7\Utils::modifyRequest($r1, [ - 'uri' => new Psr7\Uri('http://www.foo.com:8000'), - ]); - self::assertSame('http://www.foo.com:8000', (string)$r2->getUri()); - self::assertSame('www.foo.com:8000', (string)$r2->getHeaderLine('host')); - } - - public function testCanModifyRequestWithCaseInsensitiveHeader() - { - $r1 = new Psr7\Request('GET', 'http://foo.com', ['User-Agent' => 'foo']); - $r2 = Psr7\Utils::modifyRequest($r1, ['set_headers' => ['User-agent' => 'bar']]); - self::assertSame('bar', $r2->getHeaderLine('User-Agent')); - self::assertSame('bar', $r2->getHeaderLine('User-agent')); - } - - public function testReturnsAsIsWhenNoChanges() - { - $r1 = new Psr7\Request('GET', 'http://foo.com'); - $r2 = Psr7\Utils::modifyRequest($r1, []); - self::assertInstanceOf('GuzzleHttp\Psr7\Request', $r2); - - $r1 = new Psr7\ServerRequest('GET', 'http://foo.com'); - $r2 = Psr7\Utils::modifyRequest($r1, []); - self::assertInstanceOf('Psr\Http\Message\ServerRequestInterface', $r2); - } - - public function testReturnsUriAsIsWhenNoChanges() - { - $r1 = new Psr7\Request('GET', 'http://foo.com'); - $r2 = Psr7\Utils::modifyRequest($r1, ['set_headers' => ['foo' => 'bar']]); - self::assertNotSame($r1, $r2); - self::assertSame('bar', $r2->getHeaderLine('foo')); - } - - public function testRemovesHeadersFromMessage() - { - $r1 = new Psr7\Request('GET', 'http://foo.com', ['foo' => 'bar']); - $r2 = Psr7\Utils::modifyRequest($r1, ['remove_headers' => ['foo']]); - self::assertNotSame($r1, $r2); - self::assertFalse($r2->hasHeader('foo')); - } - - public function testAddsQueryToUri() - { - $r1 = new Psr7\Request('GET', 'http://foo.com'); - $r2 = Psr7\Utils::modifyRequest($r1, ['query' => 'foo=bar']); - self::assertNotSame($r1, $r2); - self::assertSame('foo=bar', $r2->getUri()->getQuery()); - } - - public function testModifyRequestKeepInstanceOfRequest() - { - $r1 = new Psr7\Request('GET', 'http://foo.com'); - $r2 = Psr7\Utils::modifyRequest($r1, ['remove_headers' => ['non-existent']]); - self::assertInstanceOf('GuzzleHttp\Psr7\Request', $r2); - - $r1 = new Psr7\ServerRequest('GET', 'http://foo.com'); - $r2 = Psr7\Utils::modifyRequest($r1, ['remove_headers' => ['non-existent']]); - self::assertInstanceOf('Psr\Http\Message\ServerRequestInterface', $r2); - } - - public function testModifyServerRequestWithUploadedFiles() - { - $request = new Psr7\ServerRequest('GET', 'http://example.com/bla'); - $file = new Psr7\UploadedFile('Test', 100, \UPLOAD_ERR_OK); - $request = $request->withUploadedFiles([$file]); - - /** @var Psr7\ServerRequest $modifiedRequest */ - $modifiedRequest = Psr7\Utils::modifyRequest($request, ['set_headers' => ['foo' => 'bar']]); - - self::assertCount(1, $modifiedRequest->getUploadedFiles()); - - $files = $modifiedRequest->getUploadedFiles(); - self::assertInstanceOf('GuzzleHttp\Psr7\UploadedFile', $files[0]); - } - - public function testModifyServerRequestWithCookies() - { - $request = (new Psr7\ServerRequest('GET', 'http://example.com/bla')) - ->withCookieParams(['name' => 'value']); - - /** @var Psr7\ServerRequest $modifiedRequest */ - $modifiedRequest = Psr7\Utils::modifyRequest($request, ['set_headers' => ['foo' => 'bar']]); - - self::assertSame(['name' => 'value'], $modifiedRequest->getCookieParams()); - } - - public function testModifyServerRequestParsedBody() - { - $request = (new Psr7\ServerRequest('GET', 'http://example.com/bla')) - ->withParsedBody(['name' => 'value']); - - /** @var Psr7\ServerRequest $modifiedRequest */ - $modifiedRequest = Psr7\Utils::modifyRequest($request, ['set_headers' => ['foo' => 'bar']]); - - self::assertSame(['name' => 'value'], $modifiedRequest->getParsedBody()); - } - - public function testModifyServerRequestQueryParams() - { - $request = (new Psr7\ServerRequest('GET', 'http://example.com/bla')) - ->withQueryParams(['name' => 'value']); - - /** @var Psr7\ServerRequest $modifiedRequest */ - $modifiedRequest = Psr7\Utils::modifyRequest($request, ['set_headers' => ['foo' => 'bar']]); - - self::assertSame(['name' => 'value'], $modifiedRequest->getQueryParams()); - } - - public function testModifyServerRequestRetainsAttributes() - { - $request = (new Psr7\ServerRequest('GET', 'http://example.com/bla')) - ->withAttribute('foo', 'bar'); - - /** @var Psr7\ServerRequest $modifiedRequest */ - $modifiedRequest = Psr7\Utils::modifyRequest($request, []); - - self::assertSame(['foo' => 'bar'], $modifiedRequest->getAttributes()); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/w3-total-cache-api.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/w3-total-cache-api.php index 9a6a5541..fd031bbb 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/w3-total-cache-api.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/w3-total-cache-api.php @@ -12,7 +12,7 @@ if ( ! defined( 'ABSPATH' ) ) { } define( 'W3TC', true ); -define( 'W3TC_VERSION', '2.3.3' ); +define( 'W3TC_VERSION', '2.5.0' ); define( 'W3TC_POWERED_BY', 'W3 Total Cache' ); define( 'W3TC_EMAIL', 'w3tc@w3-edge.com' ); define( 'W3TC_TEXT_DOMAIN', 'w3-total-cache' ); @@ -32,11 +32,16 @@ define( 'W3TC_TERMS_URL', 'https://api.w3-edge.com/v1/redirects/policies-terms' define( 'W3TC_TERMS_ACCEPT_URL', 'https://api.w3-edge.com/v1/redirects/policies-accept' ); define( 'W3TC_MAILLINGLIST_SIGNUP_URL', 'https://api.w3-edge.com/v1/signup-newsletter' ); define( 'W3TC_NEWRELIC_SIGNUP_URL', 'https://api.w3-edge.com/v1/redirects/newrelic/signup' ); -define( 'W3TC_STACKPATH_SIGNUP_URL', 'https://api.w3-edge.com/v1/redirects/stackpath/signup' ); define( 'W3TC_STACKPATH_AUTHORIZE_URL', 'https://api.w3-edge.com/v1/redirects/stackpath/authorize' ); define( 'W3TC_STACKPATH2_AUTHORIZE_URL', 'https://api.w3-edge.com/v1/redirects/stackpath2/authorize' ); define( 'W3TC_GOOGLE_DRIVE_AUTHORIZE_URL', 'https://api.w3-edge.com/v1/googledrive/authorize' ); +// Image Service rate constants. +define( 'W3TC_IMAGE_SERVICE_FREE_HLIMIT', 100 ); +define( 'W3TC_IMAGE_SERVICE_FREE_MLIMIT', 1000 ); +define( 'W3TC_IMAGE_SERVICE_PRO_HLIMIT', 10000 ); +define( 'W3TC_IMAGE_SERVICE_PRO_MLIMIT', 0 ); + // this is the URL our updater / license checker pings. This should be the URL of the site with EDD installed. if ( ! defined( 'W3TC_LICENSE_API_URL' ) ) { define( 'W3TC_LICENSE_API_URL', 'https://www.w3-edge.com/' ); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/w3-total-cache.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/w3-total-cache.php index c03ff186..0b681280 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/w3-total-cache.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/w3-total-cache.php @@ -3,7 +3,7 @@ * Plugin Name: W3 Total Cache * Plugin URI: https://www.boldgrid.com/totalcache/ * Description: The highest rated and most complete WordPress performance plugin. Dramatically improve the speed and user experience of your site. Add browser, page, object and database caching as well as minify and content delivery network (CDN) to WordPress. - * Version: 2.3.3 + * Version: 2.5.0 * Requires at least: 5.3 * Requires PHP: 5.6 * Author: BoldGrid diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/wp-content/db.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/wp-content/db.php index 0284cb85..fd71a0fc 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/wp-content/db.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/wp-content/db.php @@ -53,7 +53,7 @@ if ( ! @is_dir( W3TC_DIR ) || ! file_exists( W3TC_DIR . '/w3-total-cache-api.php $is_installing = ( defined( 'WP_INSTALLING' ) && WP_INSTALLING ); $config = \W3TC\Dispatcher::config(); - if ( ( ! $is_installing && $config->get_boolean( 'dbcache.enabled' ) ) || \W3TC\Util_Environment::is_dbcluster() ) { + if ( ( ! $is_installing && $config->get_boolean( 'dbcache.enabled' ) ) || \W3TC\Util_Environment::is_dbcluster( $config ) ) { if ( defined( 'DB_TYPE' ) ) { $db_driver_path = sprintf( '%s/Db/%s.php', W3TC_LIB_DIR, DB_TYPE ); diff --git a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/wp-content/object-cache.php b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/wp-content/object-cache.php index ed63ff3a..22c2d75b 100644 --- a/wp-content/upgrade-temp-backup/plugins/w3-total-cache/wp-content/object-cache.php +++ b/wp-content/upgrade-temp-backup/plugins/w3-total-cache/wp-content/object-cache.php @@ -52,6 +52,25 @@ if ( !@is_dir( W3TC_DIR ) || !file_exists( W3TC_DIR . '/w3-total-cache-api.php' return $wp_object_cache->get( $id, $group, $force, $found ); } + /** + * Retrieves multiple values from the cache in one call. + * + * @since 2.2.8 + * + * @param array $ids Array of keys under which the cache contents are stored. + * @param string $group Optional. Where the cache contents are grouped. Default 'default'. + * @param bool $force Optional. Whether to force an update of the local cache + * from the persistent cache. Default false. + * + * @return array Array of return values, grouped by key. Each value is either + * the cache contents on success, or false on failure. + */ + function wp_cache_get_multiple( $ids, $group = 'default', $force = false ) { + global $wp_object_cache; + + return $wp_object_cache->get_multiple( $ids, $group, $force ); + } + /** * Set cache * @@ -67,6 +86,24 @@ if ( !@is_dir( W3TC_DIR ) || !file_exists( W3TC_DIR . '/w3-total-cache-api.php' return $wp_object_cache->set( $id, $data, $group, (int)$expire ); } + /** + * Sets multiple values to the cache in one call. + * + * @since 2.2.8 + * + * @param array $data Array of key and value to be set. + * @param string $group Optional. Where the cache contents are grouped. Default empty. + * @param int $expire Optional. When to expire the cache contents, in seconds. + * Default 0 (no expiration). + * + * @return bool[] Array of return values, grouped by key. Each value is always true. + */ + function wp_cache_set_multiple( $data, $group = 'default', $expire = 0 ) { + global $wp_object_cache; + + return $wp_object_cache->set_multiple( $data, $group, (int) $expire ); + } + /** * Delete from cache * @@ -80,6 +117,23 @@ if ( !@is_dir( W3TC_DIR ) || !file_exists( W3TC_DIR . '/w3-total-cache-api.php' return $wp_object_cache->delete( $id, $group ); } + /** + * Deletes multiple values from the cache in one call. + * + * @since 2.2.8 + * + * @param array $keys Array of keys to be deleted. + * @param string $group Optional. Where the cache contents are grouped. Default empty. + * + * @return bool[] Array of return values, grouped by key. Each value is either + * true on success, or false if the contents were not deleted. + */ + function wp_cache_delete_multiple( $keys, $group = 'default' ) { + global $wp_object_cache; + + return $wp_object_cache->delete_multiple( $keys, $group ); + } + /** * Add data to cache * @@ -95,6 +149,24 @@ if ( !@is_dir( W3TC_DIR ) || !file_exists( W3TC_DIR . '/w3-total-cache-api.php' return $wp_object_cache->add( $id, $data, $group, (int)$expire ); } + /** + * Adds multiple values to the cache in one call, if the cache keys don't already exist. + * + * @since 2.2.8 + * + * @param array $data Array of keys and values to be added. + * @param string $group Optional. Where the cache contents are grouped. Default empty. + * @param int $expire Optional. When to expire the cache contents, in seconds. + * Default 0 (no expiration). + * @return bool[] Array of return values, grouped by key. Each value is either + * true on success, or false if cache key and group already exist. + */ + function wp_cache_add_multiple( array $data, $group = '', $expire = 0 ) { + global $wp_object_cache; + + return $wp_object_cache->add_multiple( $data, $group, $expire ); + } + /** * Replace data in cache * diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/LICENSE b/wp-content/upgrade-temp-backup/plugins/wp-piwik/LICENSE deleted file mode 100644 index 733c0723..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/LICENSE +++ /dev/null @@ -1,675 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 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 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 6fdc77bf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/README.md +++ /dev/null @@ -1,9 +0,0 @@ -# WP-Matomo (former 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 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 1eddaa9c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik.php +++ /dev/null @@ -1,1366 +0,0 @@ - - * @package WP_Piwik - */ -class WP_Piwik { - - private static $revisionId = 2023052101, $version = '1.0.28', $blog_id, $pluginBasename = NULL, $logger, $settings, $request, $optionsPageId; - - /** - * 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 WP-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 WP-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 WP-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'] ); - if (self::$settings->getGlobalOption ( 'auto_site_config' ) && self::isConfigured ()) { - if ($this->isPHPMode () && ! defined ( 'PIWIK_INCLUDE_PATH' )) - self::definePiwikConstants (); - $siteId = $this->getPiwikSiteId (); - $trackingCode = $this->updateTrackingCode ( $siteId ); - self::$settings->setOption ( 'site_id', $siteId ); - } - 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) { - if (! $blogId && $this->isNetworkMode ()) - $blogId = get_current_blog_id (); - $result = self::$settings->getOption ( 'site_id', $blogId ); - self::$logger->log ( 'Database result: ' . $result ); - return (! empty ( $result ) ? $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 d06f5a1a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Admin/Settings.php +++ /dev/null @@ -1,731 +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(); - 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', sprintf ( '%s %s %s %s.', __ ( 'WP-Matomo is a WordPress plugin to show a selection of Matomo stats in your WordPress admin dashboard and to add and configure your Matomo tracking code. To use this you will need your own Matomo instance. If you do not already have a Matomo setup, you have two simple options: use either', 'wp-piwik' ), 'http://piwik.org/', __ ( 'a self-hosted Matomo', 'wp-piwik' ), __ ( 'or', 'wp-piwik' ), 'https://www.innocraft.cloud/?pk_campaign=WP-Matomo', __ ( 'a cloud-hosted Matomo by InnoCraft', '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; - ?> - - - - - - - - - - - - - - -
        -

        %s

        ', $id, $description ); - } - - /** - * Show a checkbox 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 boolean $hideDescription $hideDescription set to false to show description initially (default: true) - * @param string $onChange javascript for onchange event (default: empty) - */ - private function showCheckbox($id, $name, $description, $isHidden = false, $groupName = '', $hideDescription = true, $onChange = '') { - printf ( ':getGlobalOption ( $id ) ? ' checked="checked"' : '') . ' onchange="jQuery(\'#%s\').val(this.checked?1:0);%s" /> %s', $name, $id, $onChange, $this->getDescription ( $id, $description, $hideDescription ) ); - } - - /** - * Show a textarea option - * - * @param string $id option id - * @param string $name descriptive option name - * @param int $rows number of rows to show - * @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 boolean $hideDescription $hideDescription set to false to show description initially (default: true) - * @param string $onChange javascript for onchange event (default: empty) - * @param boolean $isReadonly set textarea to read only (default: false) - * @param boolean $global set to false if the textarea shows a site-specific option (default: true) - */ - private function showTextarea($id, $name, $rows, $description, $isHidden, $groupName, $hideDescription = true, $onChange = '', $isReadonly = false, $global = true) { - printf ( - ': %s', $name, $id, $onChange, ($global ? self::$settings->getGlobalOption ( $id ) : self::$settings->getOption ( $id )), $this->getDescription ( $id, $description, $hideDescription ) ); - } - - /** - * Show a simple text - * - * @param string $text Text to show - */ - private function showText($text) { - printf ( '

        %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) { - printf ( ' %s', $isHidden ? 'hidden ' : '', $groupName ? $groupName : '', $rowName ? ' id="' . $groupName . '-' . $rowName . '"' : '', $name, $id, htmlentities(self::$settings->getGlobalOption( $id ), ENT_QUOTES, 'UTF-8', false), !empty($description) ? $this->getDescription ( $id, $description, $hideDescription ) : '' ); - } - - /** - * Show a select box option - * - * @param string $id option id - * @param string $name descriptive option name - * @param array $options list of options to show array[](option 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) { - $optionList = ''; - $default = $global ? self::$settings->getGlobalOption ( $id ) : self::$settings->getOption ( $id ); - if (is_array ( $options )) - foreach ( $options as $key => $value ) - $optionList .= sprintf ( '', $key, $value ); - printf ( ' %s', $name, $id, $onChange, $optionList, $this->getDescription ( $id, $description, $hideDescription ) ); - } - - /** - * Show an info box - * - * @param string $type box style (e.g., updated, error) - * @param string $icon box icon, see https://developer.wordpress.org/resource/dashicons/ - * @param string $content box message - */ - private function showBox($type, $icon, $content) { - printf ( '

        %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 bbd4d38c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Request/Php.php +++ /dev/null @@ -1,55 +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; - } - } \ 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 f88613df..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' => 'WP-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 1abd3e46..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 deaf018e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/OptOut.php +++ /dev/null @@ -1,31 +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' ); - } - $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 1f95b2e8..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 "\"
        \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-ajax.php b/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-ajax.php deleted file mode 100644 index 878841f5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-ajax.php +++ /dev/null @@ -1,1243 +0,0 @@ -read(); - if(isset($data[base64_encode($publicKeyCredentialId)])){ - return PublicKeyCredentialSource::createFromArray($data[base64_encode($publicKeyCredentialId)]); - } - return null; - } - - // Get one credential's meta by credential ID - public function findOneMetaByCredentialId(string $publicKeyCredentialId): ?array { - $meta = json_decode(wwa_get_option("user_credentials_meta"), true); - if(isset($meta[base64_encode($publicKeyCredentialId)])){ - return $meta[base64_encode($publicKeyCredentialId)]; - } - return null; - } - - // Get all credentials of one user - public function findAllForUserEntity(PublicKeyCredentialUserEntity $publicKeyCredentialUserEntity): array { - $sources = []; - foreach($this->read() as $data){ - $source = PublicKeyCredentialSource::createFromArray($data); - if($source->getUserHandle() === $publicKeyCredentialUserEntity->getId()){ - $sources[] = $source; - } - } - return $sources; - } - - public function findCredentialsForUserEntityByType(PublicKeyCredentialUserEntity $publicKeyCredentialUserEntity, string $credentialType): array { - $credentialsForUserEntity = $this->findAllForUserEntity($publicKeyCredentialUserEntity); - $credentialsByType = []; - foreach($credentialsForUserEntity as $credential){ - if($this->findOneMetaByCredentialId($credential->getPublicKeyCredentialId())["authenticator_type"] === $credentialType){ - $credentialsByType[] = $credential; - } - } - return $credentialsByType; - } - - // Save credential into database - public function saveCredentialSource(PublicKeyCredentialSource $publicKeyCredentialSource, bool $usernameless = false): void { - $data = $this->read(); - $data_key = base64_encode($publicKeyCredentialSource->getPublicKeyCredentialId()); - $data[$data_key] = $publicKeyCredentialSource; - $this->write($data, $data_key, $usernameless); - } - - // Update credential's last used - public function updateCredentialLastUsed(string $publicKeyCredentialId): void { - $credential = $this->findOneMetaByCredentialId($publicKeyCredentialId); - if($credential !== null){ - $credential["last_used"] = date('Y-m-d H:i:s', current_time('timestamp')); - $meta = json_decode(wwa_get_option("user_credentials_meta"), true); - $meta[base64_encode($publicKeyCredentialId)] = $credential; - wwa_update_option("user_credentials_meta", json_encode($meta)); - } - } - - // List all authenticators - public function getShowList(PublicKeyCredentialUserEntity $publicKeyCredentialUserEntity): array { - $data = json_decode(wwa_get_option("user_credentials_meta"), true); - $arr = array(); - $user_id = $publicKeyCredentialUserEntity->getId(); - foreach($data as $key => $value){ - if($user_id === $value["user"]){ - array_push($arr, array( - "key" => rtrim(strtr(base64_encode($key), '+/', '-_'), '='), - "name" => base64_decode($value["human_name"]), - "type" => $value["authenticator_type"], - "added" => $value["added"], - "usernameless" => isset($value["usernameless"]) ? $value["usernameless"] : false, - "last_used" => isset($value["last_used"]) ? $value["last_used"] : "-" - )); - } - } - return array_map(function($item){return array("key" => $item["key"], "name" => $item["name"], "type" => $item["type"], "added" => $item["added"], "usernameless" => $item["usernameless"], "last_used" => $item["last_used"]);}, $arr); - } - - // Modify an authenticator - public function modifyAuthenticator(string $id, string $name, PublicKeyCredentialUserEntity $publicKeyCredentialUserEntity, string $action, string $res_id): string { - $keys = $this->findAllForUserEntity($publicKeyCredentialUserEntity); - $user_id = $publicKeyCredentialUserEntity->getId(); - - // Check if the user has the authenticator - foreach($keys as $item){ - if($item->getUserHandle() === $user_id){ - if(base64_encode($item->getPublicKeyCredentialId()) === base64_decode(str_pad(strtr($id, '-_', '+/'), strlen($id) % 4, '=', STR_PAD_RIGHT))){ - if($action === "rename"){ - $this->renameCredential(base64_encode($item->getPublicKeyCredentialId()), $name, $res_id); - }else if($action === "remove"){ - $this->removeCredential(base64_encode($item->getPublicKeyCredentialId()), $res_id); - } - wwa_add_log($res_id, "ajax_modify_authenticator: Done"); - return "true"; - } - } - } - wwa_add_log($res_id, "ajax_modify_authenticator: (ERROR)Authenticator not found, exit"); - return "Not Found."; - } - - // Rename a credential from database by credential ID - private function renameCredential(string $id, string $name, string $res_id): void { - $meta = json_decode(wwa_get_option("user_credentials_meta"), true); - wwa_add_log($res_id, "ajax_modify_authenticator: Rename \"".base64_decode($meta[$id]["human_name"])."\" -> \"".$name."\""); - $meta[$id]["human_name"] = base64_encode($name); - wwa_update_option("user_credentials_meta", json_encode($meta)); - } - - // Remove a credential from database by credential ID - private function removeCredential(string $id, string $res_id): void { - $data = $this->read(); - unset($data[$id]); - $this->write($data, ''); - $meta = json_decode(wwa_get_option("user_credentials_meta"), true); - wwa_add_log($res_id, "ajax_modify_authenticator: Remove \"".base64_decode($meta[$id]["human_name"])."\""); - unset($meta[$id]); - wwa_update_option("user_credentials_meta", json_encode($meta)); - } - - // Read credential database - private function read(): array { - if(wwa_get_option("user_credentials") !== NULL){ - try{ - return json_decode(wwa_get_option("user_credentials"), true); - }catch(\Throwable $exception) { - return []; - } - } - return []; - } - - // Save credentials data - private function write(array $data, string $key, bool $usernameless = false): void { - if(isset($_POST["type"]) && ($_POST["type"] === "platform" || $_POST["type"] == "cross-platform" || $_POST["type"] === "none") && $key !== ''){ - // Save credentials's meta separately - $source = $data[$key]->getUserHandle(); - $meta = json_decode(wwa_get_option("user_credentials_meta"), true); - $meta[$key] = array("human_name" => base64_encode(sanitize_text_field($_POST["name"])), "added" => date('Y-m-d H:i:s', current_time('timestamp')), "authenticator_type" => $_POST["type"], "user" => $source, "usernameless" => $usernameless, "last_used" => "-"); - wwa_update_option("user_credentials_meta", json_encode($meta)); - } - wwa_update_option("user_credentials", json_encode($data)); - } -} - -// Bind an authenticator -function wwa_ajax_create(){ - try{ - $res_id = wwa_generate_random_string(5); - $client_id = strval(time()).wwa_generate_random_string(24); - - wwa_init_new_options(); - - wwa_add_log($res_id, "ajax_create: Start"); - - if(!current_user_can("read")){ - wwa_add_log($res_id, "ajax_create: (ERROR)Permission denied, exit"); - wwa_wp_die("Something went wrong.", $client_id); - } - - if(wwa_get_option('website_name') === "" || wwa_get_option('website_domain') ===""){ - wwa_add_log($res_id, "ajax_create: (ERROR)Plugin not configured, exit"); - wwa_wp_die("Not configured.", $client_id); - } - - // Check queries - if(!isset($_GET["name"]) || !isset($_GET["type"]) || !isset($_GET["usernameless"])){ - wwa_add_log($res_id, "ajax_create: (ERROR)Missing parameters, exit"); - wwa_wp_die("Bad Request.", $client_id); - }else{ - // Sanitize the input - $wwa_get = array(); - $wwa_get["name"] = sanitize_text_field($_GET["name"]); - $wwa_get["type"] = sanitize_text_field($_GET["type"]); - $wwa_get["usernameless"] = sanitize_text_field($_GET["usernameless"]); - wwa_add_log($res_id, "ajax_create: name => \"".$wwa_get["name"]."\", type => \"".$wwa_get["type"]."\", usernameless => \"".$wwa_get["usernameless"]."\""); - } - - $user_info = wp_get_current_user(); - - if(isset($_GET["user_id"])){ - $user_id = intval(sanitize_text_field($_GET["user_id"])); - if($user_id <= 0){ - wwa_add_log($res_id, "ajax_create: (ERROR)Wrong parameters, exit"); - wwa_wp_die("Bad Request."); - } - - if($user_info->ID !== $user_id){ - if(!current_user_can("edit_user", $user_id)){ - wwa_add_log($res_id, "ajax_create: (ERROR)No permission, exit"); - wwa_wp_die("Something went wrong."); - } - $user_info = get_user_by('id', $user_id); - - if($user_info === false){ - wwa_add_log($res_id, "ajax_create: (ERROR)Wrong user ID, exit"); - wwa_wp_die("Something went wrong."); - } - } - } - - // Empty authenticator name - if($wwa_get["name"] === ""){ - wwa_add_log($res_id, "ajax_create: (ERROR)Empty name, exit"); - wwa_wp_die("Bad Request.", $client_id); - } - - // Usernameless authentication not allowed - if($wwa_get["usernameless"] === "true" && wwa_get_option("usernameless_login") !== "true"){ - wwa_add_log($res_id, "ajax_create: (ERROR)Usernameless authentication not allowed, exit"); - wwa_wp_die("Bad Request.", $client_id); - } - - // Check authenticator type - $allow_authenticator_type = wwa_get_option("allow_authenticator_type"); - if($allow_authenticator_type !== false && $allow_authenticator_type !== "none"){ - if($allow_authenticator_type != $wwa_get["type"]){ - wwa_add_log($res_id, "ajax_create: (ERROR)Credential type error, type => \"".$wwa_get["type"]."\", allow_authenticator_type => \"".$allow_authenticator_type."\", exit"); - wwa_wp_die("Bad Request.", $client_id); - } - } - - $rpEntity = new PublicKeyCredentialRpEntity( - wwa_get_option("website_name"), - wwa_get_option("website_domain") - ); - $publicKeyCredentialSourceRepository = new PublicKeyCredentialSourceRepository(); - - $server = new Server( - $rpEntity, - $publicKeyCredentialSourceRepository, - null - ); - - wwa_add_log($res_id, "ajax_create: user => \"".$user_info->user_login."\""); - - // Get user ID or create one - $user_key = ""; - if(!isset(wwa_get_option("user_id")[$user_info->user_login])){ - wwa_add_log($res_id, "ajax_create: User not initialized, initialize"); - $user_array = wwa_get_option("user_id"); - $user_key = hash("sha256", $user_info->user_login."-".$user_info->display_name."-".wwa_generate_random_string(10)); - $user_array[$user_info->user_login] = $user_key; - wwa_update_option("user_id", $user_array); - }else{ - $user_key = wwa_get_option("user_id")[$user_info->user_login]; - } - - $user = array( - "login" => $user_info->user_login, - "id" => $user_key, - "display" => $user_info->display_name, - "icon" => get_avatar_url($user_info->user_email, array("scheme" => "https")) - ); - - $userEntity = new PublicKeyCredentialUserEntity( - $user["login"], - $user["id"], - $user["display"], - $user["icon"] - ); - - $credentialSourceRepository = new PublicKeyCredentialSourceRepository(); - - $credentialSources = $credentialSourceRepository->findAllForUserEntity($userEntity); - - // Convert the Credential Sources into Public Key Credential Descriptors for excluding - $excludeCredentials = array_map(function (PublicKeyCredentialSource $credential) { - return $credential->getPublicKeyCredentialDescriptor(); - }, $credentialSources); - - wwa_add_log($res_id, "ajax_create: excludeCredentials => ".json_encode($excludeCredentials)); - - // Set authenticator type - if($wwa_get["type"] === "platform"){ - $authenticator_type = AuthenticatorSelectionCriteria::AUTHENTICATOR_ATTACHMENT_PLATFORM; - }else if($wwa_get["type"] === "cross-platform"){ - $authenticator_type = AuthenticatorSelectionCriteria::AUTHENTICATOR_ATTACHMENT_CROSS_PLATFORM; - }else{ - $authenticator_type = AuthenticatorSelectionCriteria::AUTHENTICATOR_ATTACHMENT_NO_PREFERENCE; - } - - // Set user verification - if(wwa_get_option("user_verification") === "true"){ - wwa_add_log($res_id, "ajax_create: user_verification => \"true\""); - $user_verification = AuthenticatorSelectionCriteria::USER_VERIFICATION_REQUIREMENT_REQUIRED; - }else{ - wwa_add_log($res_id, "ajax_create: user_verification => \"false\""); - $user_verification = AuthenticatorSelectionCriteria::USER_VERIFICATION_REQUIREMENT_DISCOURAGED; - } - - $resident_key = false; - // Set usernameless authentication - if($wwa_get["usernameless"] === "true"){ - wwa_add_log($res_id, "ajax_create: Usernameless set, user_verification => \"true\""); - $user_verification = AuthenticatorSelectionCriteria::USER_VERIFICATION_REQUIREMENT_REQUIRED; - $resident_key = true; - } - - // Create authenticator selection - $authenticatorSelectionCriteria = new AuthenticatorSelectionCriteria( - $authenticator_type, - $resident_key, - $user_verification - ); - - // Create a creation challenge - $publicKeyCredentialCreationOptions = $server->generatePublicKeyCredentialCreationOptions( - $userEntity, - PublicKeyCredentialCreationOptions::ATTESTATION_CONVEYANCE_PREFERENCE_NONE, - $excludeCredentials, - $authenticatorSelectionCriteria - ); - - // Save for future use - wwa_set_temp_val("pkcco", base64_encode(serialize($publicKeyCredentialCreationOptions)), $client_id); - wwa_set_temp_val("bind_config", array("name" => $wwa_get["name"], "type" => $wwa_get["type"], "usernameless" => $resident_key), $client_id); - - header("Content-Type: application/json"); - $publicKeyCredentialCreationOptions = json_decode(json_encode($publicKeyCredentialCreationOptions), true); - $publicKeyCredentialCreationOptions["clientID"] = $client_id; - echo json_encode($publicKeyCredentialCreationOptions); - wwa_add_log($res_id, "ajax_create: Challenge sent"); - exit; - }catch(\Exception $exception){ - wwa_add_log($res_id, "ajax_create: (ERROR)".$exception->getMessage()); - wwa_add_log($res_id, wwa_generate_call_trace($exception)); - wwa_add_log($res_id, "ajax_create: (ERROR)Unknown error, exit"); - wwa_wp_die("Something went wrong.", $client_id); - }catch(\Error $error){ - wwa_add_log($res_id, "ajax_create: (ERROR)".$error->getMessage()); - wwa_add_log($res_id, wwa_generate_call_trace($error)); - wwa_add_log($res_id, "ajax_create: (ERROR)Unknown error, exit"); - wwa_wp_die("Something went wrong.", $client_id); - } -} -add_action("wp_ajax_wwa_create" , "wwa_ajax_create"); - -// Verify the attestation -function wwa_ajax_create_response(){ - $client_id = false; - try{ - $res_id = wwa_generate_random_string(5); - - wwa_init_new_options(); - - wwa_add_log($res_id, "ajax_create_response: Client response received"); - - if(!isset($_POST["clientid"])){ - wwa_add_log($res_id, "ajax_create_response: (ERROR)Missing parameters, exit"); - wp_die("Bad Request."); - }else{ - if(strlen($_POST["clientid"]) < 34 || strlen($_POST["clientid"]) > 35){ - wwa_add_log($res_id, "ajax_create_response: (ERROR)Wrong client ID, exit"); - wwa_wp_die("Bad Request.", $client_id); - } - // Sanitize the input - $client_id = sanitize_text_field($_POST["clientid"]); - } - - if(!current_user_can("read")){ - wwa_add_log($res_id, "ajax_create_response: (ERROR)Permission denied, exit"); - wwa_wp_die("Something went wrong.", $client_id); - } - - // Check POST - if(!isset($_POST["data"]) || !isset($_POST["name"]) || !isset($_POST["type"]) || !isset($_POST["usernameless"])){ - wwa_add_log($res_id, "ajax_create_response: (ERROR)Missing parameters, exit"); - wwa_wp_die("Bad Request.", $client_id); - }else{ - // Sanitize the input - $wwa_post = array(); - $wwa_post["name"] = sanitize_text_field($_POST["name"]); - $wwa_post["type"] = sanitize_text_field($_POST["type"]); - $wwa_post["usernameless"] = sanitize_text_field($_POST["usernameless"]); - wwa_add_log($res_id, "ajax_create_response: name => \"".$wwa_post["name"]."\", type => \"".$wwa_post["type"]."\", usernameless => \"".$wwa_post["usernameless"]."\""); - wwa_add_log($res_id, "ajax_create_response: data => ".base64_decode($_POST["data"])); - } - - if(isset($_GET["user_id"])){ - $user_id = intval(sanitize_text_field($_POST["user_id"])); - if($user_id <= 0){ - wwa_add_log($res_id, "ajax_create_response: (ERROR)Wrong parameters, exit"); - wwa_wp_die("Bad Request."); - } - - if(wp_get_current_user()->ID !== $user_id){ - if(!current_user_can("edit_user", $user_id)){ - wwa_add_log($res_id, "ajax_create_response: (ERROR)No permission, exit"); - wwa_wp_die("Something went wrong."); - } - } - } - - $temp_val = array( - "pkcco" => wwa_get_temp_val("pkcco", $client_id), - "bind_config" => wwa_get_temp_val("bind_config", $client_id) - ); - - // May not get the challenge yet - if($temp_val["pkcco"] === false || $temp_val["bind_config"] === false){ - wwa_add_log($res_id, "ajax_create_response: (ERROR)Challenge not found in transient, exit"); - wwa_wp_die("Bad request.", $client_id); - } - - // Check parameters - if($temp_val["bind_config"]["type"] !== "platform" && $temp_val["bind_config"]["type"] !== "cross-platform" && $temp_val["bind_config"]["type"] !== "none"){ - wwa_add_log($res_id, "ajax_create_response: (ERROR)Wrong type, exit"); - wwa_wp_die("Bad request.", $client_id); - } - - if($temp_val["bind_config"]["type"] !== $wwa_post["type"] || $temp_val["bind_config"]["name"] !== $wwa_post["name"]){ - wwa_add_log($res_id, "ajax_create_response: (ERROR)Wrong parameters, exit"); - wwa_wp_die("Bad Request.", $client_id); - } - - // Check global unique credential ID - $credential_id = base64_decode(json_decode(base64_decode($_POST["data"]), true)["rawId"]); - $publicKeyCredentialSourceRepository = new PublicKeyCredentialSourceRepository(); - if($publicKeyCredentialSourceRepository->findOneMetaByCredentialId($credential_id) !== null){ - wwa_add_log($res_id, "ajax_create_response: (ERROR)Credential ID not unique, ID => \"".base64_encode($credential_id)."\" , exit"); - wwa_wp_die("Something went wrong.", $client_id); - }else{ - wwa_add_log($res_id, "ajax_create_response: Credential ID unique check passed"); - } - - $psr17Factory = new Psr17Factory(); - $creator = new ServerRequestCreator( - $psr17Factory, - $psr17Factory, - $psr17Factory, - $psr17Factory - ); - - $serverRequest = $creator->fromGlobals(); - - $rpEntity = new PublicKeyCredentialRpEntity( - wwa_get_option("website_name"), - wwa_get_option("website_domain") - ); - - $server = new Server( - $rpEntity, - $publicKeyCredentialSourceRepository, - null - ); - - // Allow to bypass scheme verification when under localhost - $current_domain = wwa_get_option('website_domain'); - if($current_domain === "localhost" || $current_domain === "127.0.0.1"){ - $server->setSecuredRelyingPartyId([$current_domain]); - wwa_add_log($res_id, "ajax_create_response: Localhost, bypass HTTPS check"); - } - - // Verify - try { - $publicKeyCredentialSource = $server->loadAndCheckAttestationResponse( - base64_decode($_POST["data"]), - unserialize(base64_decode($temp_val["pkcco"])), - $serverRequest - ); - - wwa_add_log($res_id, "ajax_create_response: Challenge verified"); - - $publicKeyCredentialSourceRepository->saveCredentialSource($publicKeyCredentialSource, $temp_val["bind_config"]["usernameless"]); - - if($temp_val["bind_config"]["usernameless"]){ - wwa_add_log($res_id, "ajax_create_response: Authenticator added with usernameless authentication feature"); - }else{ - wwa_add_log($res_id, "ajax_create_response: Authenticator added"); - } - - // Success - echo "true"; - }catch(\Throwable $exception){ - // Failed to verify - wwa_add_log($res_id, "ajax_create_response: (ERROR)".$exception->getMessage()); - wwa_add_log($res_id, wwa_generate_call_trace($exception)); - wwa_add_log($res_id, "ajax_create_response: (ERROR)Challenge not verified, exit"); - wwa_wp_die("Something went wrong.", $client_id); - } - - // Destroy transients - wwa_destroy_temp_val($client_id); - exit; - }catch(\Exception $exception){ - wwa_add_log($res_id, "ajax_create_response: (ERROR)".$exception->getMessage()); - wwa_add_log($res_id, wwa_generate_call_trace($exception)); - wwa_add_log($res_id, "ajax_create_response: (ERROR)Unknown error, exit"); - wwa_wp_die("Something went wrong.", $client_id); - }catch(\Error $error){ - wwa_add_log($res_id, "ajax_create_response: (ERROR)".$error->getMessage()); - wwa_add_log($res_id, wwa_generate_call_trace($error)); - wwa_add_log($res_id, "ajax_create_response: (ERROR)Unknown error, exit"); - wwa_wp_die("Something went wrong.", $client_id); - } -} -add_action("wp_ajax_wwa_create_response" , "wwa_ajax_create_response"); - -// Auth challenge -function wwa_ajax_auth_start(){ - try{ - $res_id = wwa_generate_random_string(5); - $client_id = strval(time()).wwa_generate_random_string(24); - - wwa_init_new_options(); - - wwa_add_log($res_id, "ajax_auth: Start"); - - // Check queries - if(!isset($_GET["type"])){ - wwa_add_log($res_id, "ajax_auth: (ERROR)Missing parameters, exit"); - wwa_wp_die("Bad Request.", $client_id); - }else{ - // Sanitize the input - $wwa_get = array(); - $wwa_get["type"] = sanitize_text_field($_GET["type"]); - if(isset($_GET["user"])){ - $wwa_get["user"] = sanitize_text_field($_GET["user"]); - } - if(isset($_GET["usernameless"])){ - $wwa_get["usernameless"] = sanitize_text_field($_GET["usernameless"]); - // Usernameless authentication not allowed - if($wwa_get["usernameless"] === "true" && wwa_get_option("usernameless_login") !== "true"){ - wwa_add_log($res_id, "ajax_auth: (ERROR)Usernameless authentication not allowed, exit"); - wwa_wp_die("Bad Request.", $client_id); - } - } - } - - if($wwa_get["type"] === "test" && !current_user_can('read')){ - // Test but not logged in - wwa_add_log($res_id, "ajax_auth: (ERROR)Permission denied, exit"); - wwa_wp_die("Bad request.", $client_id); - } - - $user_key = ""; - $usernameless_flag = false; - $user_icon = null; - if($wwa_get["type"] === "test"){ - if(isset($wwa_get["usernameless"])){ - if($wwa_get["usernameless"] !== "true"){ - // Logged in and testing, if the user haven't bound any authenticator yet, exit - $user_info = wp_get_current_user(); - - if(isset($_GET["user_id"])){ - $user_id = intval(sanitize_text_field($_GET["user_id"])); - if($user_id <= 0){ - wwa_add_log($res_id, "ajax_auth: (ERROR)Wrong parameters, exit"); - wwa_wp_die("Bad Request."); - } - - if($user_info->ID !== $user_id){ - if(!current_user_can("edit_user", $user_id)){ - wwa_add_log($res_id, "ajax_auth: (ERROR)No permission, exit"); - wwa_wp_die("Something went wrong."); - } - $user_info = get_user_by('id', $user_id); - - if($user_info === false){ - wwa_add_log($res_id, "ajax_auth: (ERROR)Wrong user ID, exit"); - wwa_wp_die("Something went wrong."); - } - } - } - - wwa_add_log($res_id, "ajax_auth: type => \"test\", user => \"".$user_info->user_login."\", usernameless => \"false\""); - - if(!isset(wwa_get_option("user_id")[$user_info->user_login])){ - wwa_add_log($res_id, "ajax_auth: (ERROR)User not initialized, exit"); - wwa_wp_die("User not inited.", $client_id); - }else{ - $user_key = wwa_get_option("user_id")[$user_info->user_login]; - $user_icon = get_avatar_url($user_info->user_email, array("scheme" => "https")); - } - }else{ - if(wwa_get_option("usernameless_login") === "true"){ - wwa_add_log($res_id, "ajax_auth: type => \"test\", usernameless => \"true\""); - $usernameless_flag = true; - }else{ - wwa_add_log($res_id, "ajax_auth: (ERROR)Wrong parameters, exit"); - wwa_wp_die("Bad Request.", $client_id); - } - } - }else{ - wwa_add_log($res_id, "ajax_auth: (ERROR)Missing parameters, exit"); - wwa_wp_die("Bad Request.", $client_id); - } - }else{ - // Not testing, create a fake user ID if the user does not exist or haven't bound any authenticator yet - if(isset($wwa_get["user"]) && $wwa_get["user"] !== ""){ - if(get_user_by('login', $wwa_get["user"])){ - $user_info = get_user_by('login', $wwa_get["user"]); - $user_icon = get_avatar_url($user_info->user_email, array("scheme" => "https")); - wwa_add_log($res_id, "ajax_auth: type => \"auth\", user => \"".$user_info->user_login."\""); - if(!isset(wwa_get_option("user_id")[$user_info->user_login])){ - wwa_add_log($res_id, "ajax_auth: User not initialized, initialize"); - $user_key = hash("sha256", $wwa_get["user"]."-".$wwa_get["user"]."-".wwa_generate_random_string(10)); - }else{ - $user_key = wwa_get_option("user_id")[$user_info->user_login]; - } - }else{ - $user_info = new stdClass(); - $user_info->user_login = $wwa_get["user"]; - $user_info->display_name = $wwa_get["user"]; - $user_key = hash("sha256", $wwa_get["user"]."-".$wwa_get["user"]."-".wwa_generate_random_string(10)); - wwa_add_log($res_id, "ajax_auth: type => \"auth\", user => \"".$wwa_get["user"]."\""); - wwa_add_log($res_id, "ajax_auth: User not exists, create a fake id"); - } - }else{ - if(wwa_get_option("usernameless_login") === "true"){ - $usernameless_flag = true; - wwa_add_log($res_id, "ajax_auth: Empty username, try usernameless authentication"); - }else{ - wwa_add_log($res_id, "ajax_auth: (ERROR)Missing parameters, exit"); - wwa_wp_die("Bad Request.", $client_id); - } - } - } - - if(!$usernameless_flag){ - $userEntity = new PublicKeyCredentialUserEntity( - $user_info->user_login, - $user_key, - $user_info->display_name, - $user_icon - ); - } - - $credentialSourceRepository = new PublicKeyCredentialSourceRepository(); - $rpEntity = new PublicKeyCredentialRpEntity( - wwa_get_option('website_name'), - wwa_get_option('website_domain') - ); - - $server = new Server( - $rpEntity, - $credentialSourceRepository, - null - ); - - if($usernameless_flag){ - // Usernameless authentication, return empty allowed credentials list - wwa_add_log($res_id, "ajax_auth: Usernameless authentication, allowedCredentials => []"); - $allowedCredentials = array(); - }else{ - // Get the list of authenticators associated to the user - // $credentialSources = $credentialSourceRepository->findAllForUserEntity($userEntity); - $allow_authenticator_type = wwa_get_option('allow_authenticator_type'); - if($allow_authenticator_type === false || $allow_authenticator_type === 'none'){ - $credentialSources = $credentialSourceRepository->findAllForUserEntity($userEntity); - }else if($allow_authenticator_type !== false && $allow_authenticator_type !== 'none'){ - wwa_add_log($res_id, "ajax_auth: allow_authenticator_type => \"".$allow_authenticator_type."\", filter authenticators"); - $credentialSources = $credentialSourceRepository->findCredentialsForUserEntityByType($userEntity, $allow_authenticator_type); - } - - // Logged in and testing, if the user haven't bind a authenticator yet, exit - if(count($credentialSources) === 0 && $wwa_get["type"] === "test" && current_user_can('read')){ - wwa_add_log($res_id, "ajax_auth: (ERROR)No authenticator, exit"); - wwa_wp_die("User not inited.", $client_id); - } - - // Convert the Credential Sources into Public Key Credential Descriptors for excluding - $allowedCredentials = array_map(function(PublicKeyCredentialSource $credential){ - return $credential->getPublicKeyCredentialDescriptor(); - }, $credentialSources); - - wwa_add_log($res_id, "ajax_auth: allowedCredentials => ".json_encode($allowedCredentials)); - } - - // Set user verification - if(wwa_get_option("user_verification") === "true"){ - wwa_add_log($res_id, "ajax_auth: user_verification => \"true\""); - $user_verification = AuthenticatorSelectionCriteria::USER_VERIFICATION_REQUIREMENT_REQUIRED; - }else{ - wwa_add_log($res_id, "ajax_auth: user_verification => \"false\""); - $user_verification = AuthenticatorSelectionCriteria::USER_VERIFICATION_REQUIREMENT_DISCOURAGED; - } - - if($usernameless_flag){ - wwa_add_log($res_id, "ajax_auth: Usernameless authentication, user_verification => \"true\""); - $user_verification = AuthenticatorSelectionCriteria::USER_VERIFICATION_REQUIREMENT_REQUIRED; - } - - // Create a auth challenge - $publicKeyCredentialRequestOptions = $server->generatePublicKeyCredentialRequestOptions( - $user_verification, - $allowedCredentials - ); - - // Save for future use - wwa_set_temp_val("pkcco_auth", base64_encode(serialize($publicKeyCredentialRequestOptions)), $client_id); - wwa_set_temp_val("auth_type", $wwa_get["type"], $client_id); - if(!$usernameless_flag){ - wwa_set_temp_val("user_name_auth", $user_info->user_login, $client_id); - } - wwa_set_temp_val("usernameless_auth", serialize($usernameless_flag), $client_id); - - // Save the user entity if is not logged in and not usernameless - if(!($wwa_get["type"] === "test" && current_user_can("read")) && !$usernameless_flag){ - wwa_set_temp_val("user_auth", serialize($userEntity), $client_id); - } - - header("Content-Type: application/json"); - $publicKeyCredentialRequestOptions = json_decode(json_encode($publicKeyCredentialRequestOptions), true); - $publicKeyCredentialRequestOptions["clientID"] = $client_id; - echo json_encode($publicKeyCredentialRequestOptions); - wwa_add_log($res_id, "ajax_auth: Challenge sent"); - exit; - }catch(\Exception $exception){ - wwa_add_log($res_id, "ajax_auth: (ERROR)".$exception->getMessage()); - wwa_add_log($res_id, wwa_generate_call_trace($exception)); - wwa_add_log($res_id, "ajax_auth: (ERROR)Unknown error, exit"); - wwa_wp_die("Something went wrong.", $client_id); - }catch(\Error $error){ - wwa_add_log($res_id, "ajax_auth: (ERROR)".$error->getMessage()); - wwa_add_log($res_id, wwa_generate_call_trace($error)); - wwa_add_log($res_id, "ajax_auth: (ERROR)Unknown error, exit"); - wwa_wp_die("Something went wrong.", $client_id); - } -} -add_action("wp_ajax_wwa_auth_start" , "wwa_ajax_auth_start"); -add_action("wp_ajax_nopriv_wwa_auth_start" , "wwa_ajax_auth_start"); - -function wwa_ajax_auth(){ - $client_id = false; - try{ - $res_id = wwa_generate_random_string(5); - - wwa_init_new_options(); - - wwa_add_log($res_id, "ajax_auth_response: Client response received"); - - if(!isset($_POST["clientid"])){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Missing parameters, exit"); - wp_die("Bad Request."); - }else{ - if(strlen($_POST["clientid"]) < 34 || strlen($_POST["clientid"]) > 35){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Wrong client ID, exit"); - wwa_wp_die("Bad Request.", $client_id); - } - // Sanitize the input - $client_id = sanitize_text_field($_POST["clientid"]); - } - - // Check POST - if(!isset($_POST["type"]) || !isset($_POST["data"]) || !isset($_POST["remember"])){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Missing parameters, exit"); - wwa_wp_die("Bad Request.", $client_id); - }else{ - // Sanitize the input - $wwa_post = array(); - $wwa_post["type"] = sanitize_text_field($_POST["type"]); - $wwa_post["remember"] = sanitize_text_field($_POST["remember"]); - } - - $temp_val = array( - "pkcco_auth" => wwa_get_temp_val("pkcco_auth", $client_id), - "auth_type" => wwa_get_temp_val("auth_type", $client_id), - "usernameless_auth" => wwa_get_temp_val("usernameless_auth", $client_id), - "user_auth" => wwa_get_temp_val("user_auth", $client_id), - "user_name_auth" => wwa_get_temp_val("user_name_auth", $client_id) - ); - - if($temp_val["auth_type"] === false || $wwa_post["type"] !== $temp_val["auth_type"]){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Wrong parameters, exit"); - wwa_wp_die("Bad Request.", $client_id); - } - - // Check remember me - if($wwa_post["remember"] !== "true" && $wwa_post["remember"] !== "false"){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Wrong parameters, exit"); - wwa_wp_die("Bad Request.", $client_id); - }else if(wwa_get_option('remember_me') !== 'true' && $wwa_post["remember"] === "true"){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Wrong parameters, exit"); - wwa_wp_die("Bad Request.", $client_id); - } - - // May not get the challenge yet - if($temp_val["pkcco_auth"] === false || $temp_val["usernameless_auth"] === false || ($wwa_post["type"] !== "test" && $wwa_post["type"] !== "auth")){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Challenge not found in transient, exit"); - wwa_wp_die("Bad request.", $client_id); - } - - $temp_val["usernameless_auth"] = unserialize($temp_val["usernameless_auth"]); - - if($temp_val["usernameless_auth"] === false && $temp_val["user_name_auth"] === false){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Username not found in transient, exit"); - wwa_wp_die("Bad request.", $client_id); - } - if($wwa_post["type"] === "test" && !current_user_can("read")){ - // Test but not logged in - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Permission denied, exit"); - wwa_wp_die("Bad request.", $client_id); - } - if(!($wwa_post["type"] === "test" && current_user_can("read")) && ($temp_val["usernameless_auth"] === false && $temp_val["user_auth"] === false)){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Permission denied, exit"); - wwa_wp_die("Bad request.", $client_id); - } - - $usernameless_flag = $temp_val["usernameless_auth"]; - - $psr17Factory = new Psr17Factory(); - $creator = new ServerRequestCreator( - $psr17Factory, - $psr17Factory, - $psr17Factory, - $psr17Factory - ); - - $serverRequest = $creator->fromGlobals(); - $publicKeyCredentialSourceRepository = new PublicKeyCredentialSourceRepository(); - - // If user entity is not saved, read from WordPress - $user_key = ""; - if($wwa_post["type"] === "test" && current_user_can('read') && !$usernameless_flag){ - $user_info = wp_get_current_user(); - - if(isset($_GET["user_id"])){ - $user_id = intval(sanitize_text_field($_POST["user_id"])); - if($user_id <= 0){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Wrong parameters, exit"); - wwa_wp_die("Bad Request."); - } - - if($user_info->ID !== $user_id){ - if(!current_user_can("edit_user", $user_id)){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)No permission, exit"); - wwa_wp_die("Something went wrong."); - } - $user_info = get_user_by('id', $user_id); - - if($user_info === false){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Wrong user ID, exit"); - wwa_wp_die("Something went wrong."); - } - } - } - - if(!isset(wwa_get_option("user_id")[$user_info->user_login])){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)User not initialized, exit"); - wwa_wp_die("User not inited.", $client_id); - }else{ - $user_key = wwa_get_option("user_id")[$user_info->user_login]; - $user_icon = get_avatar_url($user_info->user_email, array("scheme" => "https")); - } - - $userEntity = new PublicKeyCredentialUserEntity( - $user_info->user_login, - $user_key, - $user_info->display_name, - $user_icon - ); - - wwa_add_log($res_id, "ajax_auth_response: type => \"test\", user => \"".$user_info->user_login."\""); - }else{ - if($usernameless_flag){ - $data_array = json_decode(base64_decode($_POST["data"]), true); - if(!isset($data_array["response"]["userHandle"]) || !isset($data_array["rawId"])){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Client data not correct, exit"); - wwa_wp_die("Bad request.", $client_id); - } - - wwa_add_log($res_id, "ajax_auth_response: type => \"".$wwa_post["type"]."\""); - wwa_add_log($res_id, "ajax_auth_response: Usernameless authentication, try to find user by credential_id => \"".$data_array["rawId"]."\", userHandle => \"".$data_array["response"]["userHandle"]."\""); - - $credential_meta = $publicKeyCredentialSourceRepository->findOneMetaByCredentialId(base64_decode($data_array["rawId"])); - - if($credential_meta !== null){ - $allow_authenticator_type = wwa_get_option("allow_authenticator_type"); - if($allow_authenticator_type !== false && $allow_authenticator_type !== 'none'){ - if($credential_meta["authenticator_type"] !== $allow_authenticator_type){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Credential type error, authenticator_type => \"".$credential_meta["authenticator_type"]."\", allow_authenticator_type => \"".$allow_authenticator_type."\", exit"); - wwa_wp_die("Bad request.", $client_id); - } - } - if($credential_meta["usernameless"] === true){ - wwa_add_log($res_id, "ajax_auth_response: Credential found, usernameless => \"true\", user_key => \"".$credential_meta["user"]."\""); - - // Try to find user - $all_user = wwa_get_option("user_id"); - $user_login_name = false; - foreach($all_user as $user => $user_id){ - if($user_id === $credential_meta["user"]){ - $user_login_name = $user; - break; - } - } - - // Match userHandle - if($credential_meta["user"] === base64_decode($data_array["response"]["userHandle"])){ - // Found user - if($user_login_name !== false){ - wwa_add_log($res_id, "ajax_auth_response: Found user => \"".$user_login_name."\", user_key => \"".$credential_meta["user"]."\""); - - // Testing, verify user - if($wwa_post["type"] === "test" && current_user_can('read')){ - $user_wp = wp_get_current_user(); - if($user_login_name !== $user_wp->user_login){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Credential found, but user not match, exit"); - wwa_wp_die("Bad request.", $client_id); - } - } - - $user_info = get_user_by('login', $user_login_name); - - if($user_info === false){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Wrong user ID, exit"); - wwa_wp_die("Something went wrong."); - } - - $userEntity = new PublicKeyCredentialUserEntity( - $user_info->user_login, - $credential_meta["user"], - $user_info->display_name, - get_avatar_url($user_info->user_email, array("scheme" => "https")) - ); - }else{ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Credential found, but user not found, exit"); - wwa_wp_die("Bad request.", $client_id); - } - }else{ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Credential found, but userHandle not matched, exit"); - wwa_wp_die("Bad request.", $client_id); - } - }else{ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Credential found, but usernameless => \"false\", exit"); - wwa_wp_die("Bad request.", $client_id); - } - }else{ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Credential not found, exit"); - wwa_wp_die("Bad request.", $client_id); - } - }else{ - wwa_add_log($res_id, "ajax_auth_response: type => \"auth\", user => \"".$temp_val["user_name_auth"]."\""); - $userEntity = unserialize($temp_val["user_auth"]); - } - } - - wwa_add_log($res_id, "ajax_auth_response: data => ".base64_decode($_POST["data"])); - - $rpEntity = new PublicKeyCredentialRpEntity( - wwa_get_option("website_name"), - wwa_get_option("website_domain") - ); - - $server = new Server( - $rpEntity, - $publicKeyCredentialSourceRepository, - null - ); - - // Allow to bypass scheme verification when under localhost - $current_domain = wwa_get_option("website_domain"); - if($current_domain === "localhost" || $current_domain === "127.0.0.1"){ - $server->setSecuredRelyingPartyId([$current_domain]); - wwa_add_log($res_id, "ajax_auth_response: Localhost, bypass HTTPS check"); - } - - // Verify - try { - $server->loadAndCheckAssertionResponse( - base64_decode($_POST["data"]), - unserialize(base64_decode($temp_val["pkcco_auth"])), - $userEntity, - $serverRequest - ); - - wwa_add_log($res_id, "ajax_auth_response: Challenge verified"); - - // Success - $publicKeyCredentialSourceRepository->updateCredentialLastUsed(base64_decode(json_decode(base64_decode($_POST["data"]), true)["rawId"])); - if(!($wwa_post["type"] === "test" && current_user_can("read"))){ - // Log user in - if (!is_user_logged_in()) { - include("wwa-compatibility.php"); - - if(!$usernameless_flag){ - $user_login = $temp_val["user_name_auth"]; - }else{ - $user_login = $user_login_name; - } - - $user = get_user_by("login", $user_login); - - if($user_info === false){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Wrong user ID, exit"); - wwa_wp_die("Something went wrong."); - } - - $user_id = $user->ID; - - wwa_add_log($res_id, "ajax_auth_response: Log in user => \"".$user_login."\""); - - $remember_flag = false; - - if ($wwa_post["remember"] === "true" && (wwa_get_option("remember_me") === false ? "false" : wwa_get_option("remember_me")) !== "false") { - $remember_flag = true; - wwa_add_log($res_id, "ajax_auth_response: Remember login for 14 days"); - } - - wp_set_current_user($user_id, $user_login); - if(isset($_SERVER["HTTPS"]) && $_SERVER["HTTPS"] === "on"){ - wp_set_auth_cookie($user_id, $remember_flag, true); - }else{ - wp_set_auth_cookie($user_id, $remember_flag); - } - do_action("wp_login", $user_login, $user); - } - } - echo "true"; - }catch(\Throwable $exception){ - // Failed to verify - wwa_add_log($res_id, "ajax_auth_response: (ERROR)".$exception->getMessage()); - wwa_add_log($res_id, wwa_generate_call_trace($exception)); - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Challenge not verified, exit"); - wwa_wp_die("Something went wrong.", $client_id); - } - - // Destroy session - wwa_destroy_temp_val($client_id); - exit; - }catch(\Exception $exception){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)".$exception->getMessage()); - wwa_add_log($res_id, wwa_generate_call_trace($exception)); - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Unknown error, exit"); - wwa_wp_die("Something went wrong.", $client_id); - }catch(\Error $error){ - wwa_add_log($res_id, "ajax_auth_response: (ERROR)".$error->getMessage()); - wwa_add_log($res_id, wwa_generate_call_trace($error)); - wwa_add_log($res_id, "ajax_auth_response: (ERROR)Unknown error, exit"); - wwa_wp_die("Something went wrong.", $client_id); - } -} -add_action("wp_ajax_wwa_auth" , "wwa_ajax_auth"); -add_action("wp_ajax_nopriv_wwa_auth" , "wwa_ajax_auth"); - -// Get authenticator list -function wwa_ajax_authenticator_list(){ - $res_id = wwa_generate_random_string(5); - - wwa_init_new_options(); - - if(!current_user_can("read")){ - wwa_add_log($res_id, "ajax_ajax_authenticator_list: (ERROR)Missing parameters, exit"); - wwa_wp_die("Something went wrong."); - } - - $user_info = wp_get_current_user(); - - if(isset($_GET["user_id"])){ - $user_id = intval(sanitize_text_field($_GET["user_id"])); - if($user_id <= 0){ - wwa_add_log($res_id, "ajax_ajax_authenticator_list: (ERROR)Wrong parameters, exit"); - wwa_wp_die("Bad Request."); - } - - if($user_info->ID !== $user_id){ - if(!current_user_can("edit_user", $user_id)){ - wwa_add_log($res_id, "ajax_ajax_authenticator_list: (ERROR)No permission, exit"); - wwa_wp_die("Something went wrong."); - } - $user_info = get_user_by('id', $user_id); - - if($user_info === false){ - wwa_add_log($res_id, "ajax_ajax_authenticator_list: (ERROR)Wrong user ID, exit"); - wwa_wp_die("Something went wrong."); - } - } - } - - header('Content-Type: application/json'); - - $user_key = ""; - if(!isset(wwa_get_option("user_id")[$user_info->user_login])){ - wwa_add_log($res_id, "ajax_ajax_authenticator_list: Empty authenticator list"); - // The user haven't bound any authenticator, return empty list - echo "[]"; - exit; - }else{ - $user_key = wwa_get_option("user_id")[$user_info->user_login]; - } - - $userEntity = new PublicKeyCredentialUserEntity( - $user_info->user_login, - $user_key, - $user_info->display_name, - get_avatar_url($user_info->user_email, array("scheme" => "https")) - ); - - $publicKeyCredentialSourceRepository = new PublicKeyCredentialSourceRepository(); - echo json_encode($publicKeyCredentialSourceRepository->getShowList($userEntity)); - exit; -} -add_action("wp_ajax_wwa_authenticator_list" , "wwa_ajax_authenticator_list"); - -// Modify an authenticator -function wwa_ajax_modify_authenticator(){ - try{ - $res_id = wwa_generate_random_string(5); - - wwa_init_new_options(); - - wwa_add_log($res_id, "ajax_modify_authenticator: Start"); - - if(!current_user_can("read")){ - wwa_add_log($res_id, "ajax_modify_authenticator: (ERROR)Permission denied, exit"); - wwa_wp_die("Bad Request."); - } - - if(!isset($_GET["id"]) || !isset($_GET["target"])){ - wwa_add_log($res_id, "ajax_modify_authenticator: (ERROR)Missing parameters, exit"); - wwa_wp_die("Bad Request."); - } - - $user_info = wp_get_current_user(); - - if(isset($_GET["user_id"])){ - $user_id = intval(sanitize_text_field($_GET["user_id"])); - if($user_id <= 0){ - wwa_add_log($res_id, "ajax_modify_authenticator: (ERROR)Wrong parameters, exit"); - wwa_wp_die("Bad Request."); - } - - if($user_info->ID !== $user_id){ - if(!current_user_can("edit_user", $user_id)){ - wwa_add_log($res_id, "ajax_modify_authenticator: (ERROR)No permission, exit"); - wwa_wp_die("Something went wrong."); - } - $user_info = get_user_by('id', $user_id); - - if($user_info === false){ - wwa_add_log($res_id, "ajax_modify_authenticator: (ERROR)Wrong user ID, exit"); - wwa_wp_die("Something went wrong."); - } - } - } - - if($_GET["target"] !== "rename" && $_GET["target"] !== "remove"){ - wwa_add_log($res_id, "ajax_modify_authenticator: (ERROR)Wrong target, exit"); - wwa_wp_die("Bad Request."); - } - - if($_GET["target"] === "rename" && !isset($_GET["name"])){ - wwa_add_log($res_id, "ajax_modify_authenticator: (ERROR)Missing parameters, exit"); - wwa_wp_die("Bad Request."); - } - - $user_key = ""; - if(!isset(wwa_get_option("user_id")[$user_info->user_login])){ - // The user haven't bound any authenticator, exit - wwa_add_log($res_id, "ajax_modify_authenticator: (ERROR)User not initialized, exit"); - wwa_wp_die("User not inited."); - }else{ - $user_key = wwa_get_option("user_id")[$user_info->user_login]; - } - - $userEntity = new PublicKeyCredentialUserEntity( - $user_info->user_login, - $user_key, - $user_info->display_name, - get_avatar_url($user_info->user_email, array("scheme" => "https")) - ); - - wwa_add_log($res_id, "ajax_modify_authenticator: user => \"".$user_info->user_login."\""); - - $publicKeyCredentialSourceRepository = new PublicKeyCredentialSourceRepository(); - - if($_GET["target"] === "rename"){ - echo $publicKeyCredentialSourceRepository->modifyAuthenticator($_GET["id"], sanitize_text_field($_GET["name"]), $userEntity, "rename", $res_id); - }else if($_GET["target"] === "remove"){ - echo $publicKeyCredentialSourceRepository->modifyAuthenticator($_GET["id"], "", $userEntity, "remove", $res_id); - } - exit; - }catch(\Exception $exception){ - wwa_add_log($res_id, "ajax_modify_authenticator: (ERROR)".$exception->getMessage()); - wwa_add_log($res_id, wwa_generate_call_trace($exception)); - wwa_add_log($res_id, "ajax_modify_authenticator: (ERROR)Unknown error, exit"); - wwa_wp_die("Something went wrong."); - }catch(\Error $error){ - wwa_add_log($res_id, "ajax_modify_authenticator: (ERROR)".$error->getMessage()); - wwa_add_log($res_id, wwa_generate_call_trace($error)); - wwa_add_log($res_id, "ajax_modify_authenticator: (ERROR)Unknown error, exit"); - wwa_wp_die("Something went wrong."); - } -} -add_action("wp_ajax_wwa_modify_authenticator" , "wwa_ajax_modify_authenticator"); - -// Print log -function wwa_ajax_get_log(){ - if(!wwa_validate_privileges()){ - wwa_wp_die("Bad Request."); - } - - header('Content-Type: application/json'); - - $log = get_option("wwa_log"); - - if($log === false){ - echo "[]"; - }else{ - echo json_encode($log); - } - - exit; -} -add_action("wp_ajax_wwa_get_log" , "wwa_ajax_get_log"); - -// Clear log -function wwa_ajax_clear_log(){ - if(!wwa_validate_privileges()){ - wwa_wp_die("Bad Request."); - } - - $log = get_option("wwa_log"); - - if($log !== false){ - update_option("wwa_log", array()); - } - - echo "true"; - exit; -} -add_action("wp_ajax_wwa_clear_log" , "wwa_ajax_clear_log"); -?> \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-compatibility.php b/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-compatibility.php deleted file mode 100644 index 8c946c0c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-compatibility.php +++ /dev/null @@ -1,6 +0,0 @@ - \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-functions.php b/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-functions.php deleted file mode 100644 index 0e0b9aa4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-functions.php +++ /dev/null @@ -1,332 +0,0 @@ -getTraceAsString()); - $trace = array_reverse($trace); - array_shift($trace); - array_pop($trace); - $length = count($trace); - $result = array(); - - for($i = 0; $i < $length; $i++){ - $result[] = ($i + 1).')'.substr($trace[$i], strpos($trace[$i], ' ')); - } - - return "Traceback:\n ".implode("\n ", $result); -} - -// Delete all credentials when deleting user -function wwa_delete_user($user_id){ - $res_id = wwa_generate_random_string(5); - - $user_data = get_userdata($user_id); - $all_user_meta = wwa_get_option("user_id"); - $user_key = ""; - wwa_add_log($res_id, "Delete user => \"".$user_data->user_login."\""); - - // Delete user meta - foreach($all_user_meta as $user => $id){ - if($user === $user_data->user_login){ - $user_key = $id; - wwa_add_log($res_id, "Delete user_key => \"".$id."\""); - unset($all_user_meta[$user]); - } - } - - // Delete credentials - $all_credentials_meta = json_decode(wwa_get_option("user_credentials_meta"), true); - $all_credentials = json_decode(wwa_get_option("user_credentials"), true); - foreach($all_credentials_meta as $credential => $meta){ - if($user_key === $meta["user"]){ - wwa_add_log($res_id, "Delete credential => \"".$credential."\""); - unset($all_credentials_meta[$credential]); - unset($all_credentials[$credential]); - } - } - wwa_update_option("user_id", $all_user_meta); - wwa_update_option("user_credentials_meta", json_encode($all_credentials_meta)); - wwa_update_option("user_credentials", json_encode($all_credentials)); - wwa_add_log($res_id, "Done"); -} -add_action('delete_user', 'wwa_delete_user'); - -// Add CSS and JS in login page -function wwa_login_js(){ - $wwa_not_allowed = false; - if(!function_exists("mb_substr") || !function_exists("gmp_intval") || !wwa_check_ssl() && (parse_url(site_url(), PHP_URL_HOST) !== 'localhost' && parse_url(site_url(), PHP_URL_HOST) !== '127.0.0.1')){ - $wwa_not_allowed = true; - } - wp_enqueue_script('wwa_login', plugins_url('js/login.js', __FILE__), array(), get_option('wwa_version')['version'], true); - $first_choice = wwa_get_option('first_choice'); - wp_localize_script('wwa_login', 'php_vars', array( - 'ajax_url' => admin_url('admin-ajax.php'), - 'admin_url' => admin_url(), - 'usernameless' => (wwa_get_option('usernameless_login') === false ? 'false' : wwa_get_option('usernameless_login')), - 'remember_me' => (wwa_get_option('remember_me') === false ? 'false' : wwa_get_option('remember_me')), - 'allow_authenticator_type' => (wwa_get_option('allow_authenticator_type') === false ? "none" : wwa_get_option('allow_authenticator_type')), - 'webauthn_only' => ($first_choice === 'webauthn' && !$wwa_not_allowed) ? 'true' : 'false', - 'i18n_1' => __('Auth', 'wp-webauthn'), - 'i18n_2' => __('Authenticate with WebAuthn', 'wp-webauthn'), - 'i18n_3' => __('Hold on...', 'wp-webauthn'), - 'i18n_4' => __('Please proceed...', 'wp-webauthn'), - 'i18n_5' => __('Authenticating...', 'wp-webauthn'), - 'i18n_6' => ' '.__('Authenticated', 'wp-webauthn').'', - 'i18n_7' => ' '.__('Auth failed', 'wp-webauthn').'', - 'i18n_8' => __('It looks like your browser doesn\'t support WebAuthn, which means you may unable to login.', 'wp-webauthn'), - 'i18n_9' => __('Username', 'wp-webauthn'), - 'i18n_10' => __('Username or Email Address'), - 'i18n_11' => __('Error: The username field is empty.', 'wp-webauthn'), - 'i18n_12' => ''.__('Try to enter the username', 'wp-webauthn').'' - )); - if($first_choice === 'true' || $first_choice === 'webauthn'){ - wp_enqueue_script('wwa_default', plugins_url('js/default_wa.js', __FILE__), array(), get_option('wwa_version')['version'], true); - } - wp_enqueue_style('wwa_login_css', plugins_url('css/login.css', __FILE__), array(), get_option('wwa_version')['version']); -} -add_action('login_enqueue_scripts', 'wwa_login_js', 999); - -// Disable password login -function wwa_disable_password($user){ - if(!function_exists("mb_substr") || !function_exists("gmp_intval") || !wwa_check_ssl() && (parse_url(site_url(), PHP_URL_HOST) !== 'localhost' && parse_url(site_url(), PHP_URL_HOST) !== '127.0.0.1')){ - return $user; - } - if(wwa_get_option('first_choice') === 'webauthn'){ - return new WP_Error('wwa_password_disabled', __('Logging in with password has been disabled by the site manager.', 'wp-webauthn')); - } - if(is_wp_error($user)){ - return $user; - } - if(get_the_author_meta('webauthn_only', $user->ID) === 'true'){ - return new WP_Error('wwa_password_disabled_for_account', __('Logging in with password has been disabled for this account.', 'wp-webauthn')); - } - return $user; -} -add_filter('wp_authenticate_user', 'wwa_disable_password', 10, 1); - -// Show a notice in admin pages -function wwa_no_authenticator_warning(){ - $user_info = wp_get_current_user(); - $first_choice = wwa_get_option('first_choice'); - $check_self = true; - if($first_choice !== 'webauthn' && get_the_author_meta('webauthn_only', $user_info->ID ) !== 'true'){ - $check_self = false; - } - - if($check_self){ - // Check current user - $user_id = ''; - $show_notice_flag = false; - if(!isset(wwa_get_option('user_id')[$user_info->user_login])){ - $show_notice_flag = true; - }else{ - $user_id = wwa_get_option('user_id')[$user_info->user_login]; - } - - if(!$show_notice_flag){ - $show_notice_flag = true; - $data = json_decode(wwa_get_option('user_credentials_meta'), true); - foreach($data as $value){ - if($user_id === $value['user']){ - $show_notice_flag = false; - break; - } - } - } - - if($show_notice_flag){?> -
        -

        Register', 'wp-webauthn'), $first_choice === 'webauthn' ? __('the site', 'wp-webauthn') : __('your account', 'wp-webauthn'), admin_url('profile.php'));?>

        -
        - ID){ - $user_id_wp = intval($_GET['user_id']); - if($user_id_wp <= 0){ - return; - } - if(!current_user_can('edit_user', $user_id_wp)){ - return; - } - $user_info = get_user_by('id', $user_id_wp); - - if($user_info === false){ - return; - } - - if($first_choice !== 'webauthn' && get_the_author_meta('webauthn_only', $user_info->ID ) !== 'true'){ - return; - } - - $user_id = ''; - $show_notice_flag = false; - if(!isset(wwa_get_option('user_id')[$user_info->user_login])){ - $show_notice_flag = true; - }else{ - $user_id = wwa_get_option('user_id')[$user_info->user_login]; - } - - if(!$show_notice_flag){ - $show_notice_flag = true; - $data = json_decode(wwa_get_option('user_credentials_meta'), true); - foreach($data as $value){ - if($user_id === $value['user']){ - $show_notice_flag = false; - break; - } - } - } - - if($show_notice_flag){ ?> -
        -

        this account haven\'t register any WebAuthn authenticator yet. This user may unable to login.', 'wp-webauthn'), $first_choice === 'webauthn' ? __('the site', 'wp-webauthn') : __('this account', 'wp-webauthn'));?>

        -
        - '.__('Settings', 'wp-webauthn').''; - } - return $links_array; -} -add_filter('plugin_action_links', 'wwa_settings_link', 10, 2); - -function wwa_meta_link($links_array, $plugin_file_name){ - if($plugin_file_name === 'wp-webauthn/wp-webauthn.php'){ - $links_array[] = ''.__('GitHub', 'wp-webauthn').''; - $links_array[] = ''.__('Documentation', 'wp-webauthn').''; - } - return $links_array; -} -add_filter('plugin_row_meta', 'wwa_meta_link', 10, 2); - -// Check if we are under HTTPS -function wwa_check_ssl() { - if (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' && $_SERVER['HTTPS'] !== '') { - return true; - } - if (!empty($_SERVER['HTTP_X_FORWARDED_PROTO']) && $_SERVER['HTTP_X_FORWARDED_PROTO'] === 'https' || !empty($_SERVER['HTTP_X_FORWARDED_SSL']) && $_SERVER['HTTP_X_FORWARDED_SSL'] === 'on') { - return true; - } - if (isset($_SERVER['SERVER_PROTOCOL']) && $_SERVER['SERVER_PROTOCOL'] === 'HTTP/3.0') { - return true; - } - if (isset($_SERVER['REQUEST_SCHEME']) && ($_SERVER['REQUEST_SCHEME'] === 'quic' || $_SERVER['REQUEST_SCHEME'] === 'https')) { - return true; - } - return false; -} - -// Check user privileges -function wwa_validate_privileges() { - $user = wp_get_current_user(); - $allowed_roles = array( 'administrator' ); - if(array_intersect($allowed_roles, $user->roles)){ - return true; - } - return false; -} -?> diff --git a/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-menus.php b/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-menus.php deleted file mode 100644 index 83545651..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-menus.php +++ /dev/null @@ -1,50 +0,0 @@ - admin_url('admin-ajax.php'), - 'user_id' => $user->ID, - 'i18n_1' => __('Initializing...', 'wp-webauthn'), - 'i18n_2' => __('Please follow instructions to finish registration...', 'wp-webauthn'), - 'i18n_3' => ''._x('Registered', 'action', 'wp-webauthn').'', - 'i18n_4' => ''.__('Registration failed', 'wp-webauthn').'', - 'i18n_5' => __('Your browser does not support WebAuthn', 'wp-webauthn'), - 'i18n_6' => __('Registrating...', 'wp-webauthn'), - 'i18n_7' => __('Please enter the authenticator identifier', 'wp-webauthn'), - 'i18n_8' => __('Loading failed, maybe try refreshing?', 'wp-webauthn'), - 'i18n_9' => __('Any', 'wp-webauthn'), - 'i18n_10' => __('Platform authenticator', 'wp-webauthn'), - 'i18n_11' => __('Roaming authenticator', 'wp-webauthn'), - 'i18n_12' => __('Remove', 'wp-webauthn'), - 'i18n_13' => __('Please follow instructions to finish verification...', 'wp-webauthn'), - 'i18n_14' => __('Verifying...', 'wp-webauthn'), - 'i18n_15' => ''.__('Verification failed', 'wp-webauthn').'', - 'i18n_16' => ''.__('Verification passed! You can now log in through WebAuthn', 'wp-webauthn').'', - 'i18n_17' => __('No registered authenticators', 'wp-webauthn'), - 'i18n_18' => __('Confirm removal of authenticator: ', 'wp-webauthn'), - 'i18n_19' => __('Removing...', 'wp-webauthn'), - 'i18n_20' => __('Rename', 'wp-webauthn'), - 'i18n_21' => __('Rename the authenticator', 'wp-webauthn'), - 'i18n_22' => __('Renaming...', 'wp-webauthn'), - 'i18n_24' => __('Ready', 'wp-webauthn'), - 'i18n_25' => __('No', 'wp-webauthn'), - 'i18n_26' => __(' (Unavailable)', 'wp-webauthn'), - 'i18n_27' => __('The site administrator has disabled usernameless login feature.', 'wp-webauthn'), - 'i18n_28' => __('After removing this authenticator, you will not be able to login with WebAuthn', 'wp-webauthn'), - 'i18n_29' => __(' (Disabled)', 'wp-webauthn'), - 'i18n_30' => __('The site administrator only allow platform authenticators currently.', 'wp-webauthn'), - 'i18n_31' => __('The site administrator only allow roaming authenticators currently.', 'wp-webauthn') -)); -wp_enqueue_style('wwa_profile', plugins_url('css/admin.css', __FILE__)); -wp_localize_script('wwa_profile', 'configs', array('usernameless' => (wwa_get_option('usernameless_login') === false ? "false" : wwa_get_option('usernameless_login')), 'allow_authenticator_type' => (wwa_get_option('allow_authenticator_type') === false ? "none" : wwa_get_option('allow_authenticator_type')))); -?> -
        -

        WebAuthn

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


        -
        -

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

        -

        -   -
        - -

        -

        %s.
        You can register multiple authenticators for an account.', 'wp-webauthn'), $user->user_login);?>

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

        Regardless of the type, you can only log in with the very same authenticators you\'ve registered.', 'wp-webauthn');?>

        -
        - -

        DOES NOT affect the authentication process in anyway.', 'wp-webauthn');?>

        -
        -
        -
        -
        -

        Some authenticators like U2F-only authenticators and some browsers DO NOT support this feature.
        A record will be stored in the authenticator permanently untill you reset it.', 'wp-webauthn');?>

        -
        -
        -      -
        -
        - -

        -

        -      - -

              - -
        \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-shortcodes.php b/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-shortcodes.php deleted file mode 100644 index 293a92b9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-shortcodes.php +++ /dev/null @@ -1,181 +0,0 @@ - admin_url('admin-ajax.php'), - 'admin_url' => admin_url(), - 'usernameless' => (wwa_get_option('usernameless_login') === false ? "false" : wwa_get_option('usernameless_login')), - 'remember_me' => (wwa_get_option('remember_me') === false ? "false" : wwa_get_option('remember_me')), - 'allow_authenticator_type' => (wwa_get_option('allow_authenticator_type') === false ? "none" : wwa_get_option('allow_authenticator_type')), - 'i18n_1' => __('Ready', 'wp-webauthn'), - 'i18n_2' => __('Authenticate with WebAuthn', 'wp-webauthn'), - 'i18n_3' => __('Hold on...', 'wp-webauthn'), - 'i18n_4' => __('Please proceed...', 'wp-webauthn'), - 'i18n_5' => __('Authenticating...', 'wp-webauthn'), - 'i18n_6' => ''.__('Authenticated', 'wp-webauthn'), - 'i18n_7' => ''.__('Auth failed', 'wp-webauthn').'', - 'i18n_8' => __('No', 'wp-webauthn'), - 'i18n_9' => __(' (Unavailable)', 'wp-webauthn'), - 'i18n_10' => __('The site administrator has disabled usernameless login feature.', 'wp-webauthn'), - 'i18n_11' => __('Error: The username field is empty.', 'wp-webauthn'), - 'i18n_12' => __('Please enter the authenticator identifier', 'wp-webauthn'), - 'i18n_13' => __('Please follow instructions to finish verification...', 'wp-webauthn'), - 'i18n_14' => __('Verifying...', 'wp-webauthn'), - 'i18n_15' => ''.__('Verification failed', 'wp-webauthn').'', - 'i18n_16' => ''.__('Verification passed! You can now log in through WebAuthn', 'wp-webauthn').'', - 'i18n_17' => __('Loading failed, maybe try refreshing?', 'wp-webauthn'), - 'i18n_18' => __('Confirm removal of authenticator: ', 'wp-webauthn'), - 'i18n_19' => __('Removing...', 'wp-webauthn'), - 'i18n_20' => __('Rename', 'wp-webauthn'), - 'i18n_21' => __('Rename the authenticator', 'wp-webauthn'), - 'i18n_22' => __('Renaming...', 'wp-webauthn'), - 'i18n_23' => __('No registered authenticators', 'wp-webauthn'), - 'i18n_24' => __('Any', 'wp-webauthn'), - 'i18n_25' => __('Platform authenticator', 'wp-webauthn'), - 'i18n_26' => __('Roaming authenticator', 'wp-webauthn'), - 'i18n_27' => __('Remove', 'wp-webauthn'), - 'i18n_28' => __('Please follow instructions to finish registration...', 'wp-webauthn'), - 'i18n_29' => ''._x('Registered', 'action', 'wp-webauthn').'', - 'i18n_30' => ''.__('Registration failed', 'wp-webauthn').'', - 'i18n_31' => __('Your browser does not support WebAuthn', 'wp-webauthn'), - 'i18n_32' => __('Registrating...', 'wp-webauthn'), - 'i18n_33' => ''.__('Try to enter the username', 'wp-webauthn').'', - 'i18n_34' => __('After removing this authenticator, you will not be able to login with WebAuthn', 'wp-webauthn'), - 'i18n_35' => __(' (Disabled)', 'wp-webauthn'), - 'i18n_36' => __('The site administrator only allow platform authenticators currently.', 'wp-webauthn'), - 'i18n_37' => __('The site administrator only allow roaming authenticators currently.', 'wp-webauthn') - )); -} - -// Login form -function wwa_login_form_shortcode($vals){ - extract(shortcode_atts( - array( - 'traditional' => 'true', - 'username' => '', - 'auto_hide' => 'true', - 'to' => '' - ), $vals) - ); - - if($auto_hide === "true" && current_user_can("read")){ - return ''; - } - - // Load Javascript & CSS - if(!wp_script_is('wwa_frontend_js')){ - wwa_localize_frontend(); - } - wp_enqueue_style('wwa_frondend_css', plugins_url('css/frontend.css', __FILE__), array(), get_option('wwa_version')['version']); - - $html_form = ''; - - return $html_form; -} -add_shortcode('wwa_login_form', 'wwa_login_form_shortcode'); - -// Register form -function wwa_register_form_shortcode($vals){ - extract(shortcode_atts( - array( - 'display' => 'true' - ), $vals) - ); - - // If always display - if(!current_user_can("read")){ - if($display === "true"){ - return '

        '.__('You haven\'t logged in yet.', 'wp-webauthn').'

        '; - }else{ - return ''; - } - } - - // Load Javascript & CSS - if(!wp_script_is('wwa_frontend_js')){ - wwa_localize_frontend(); - } - wp_enqueue_style('wwa_frondend_css', plugins_url('css/frontend.css', __FILE__), array(), get_option('wwa_version')['version']); - - $allowed_type = wwa_get_option('allow_authenticator_type') === false ? 'none' : wwa_get_option('allow_authenticator_type'); - return '

        '.__('If a type is selected, the browser will only prompt for authenticators of selected type.
        Regardless of the type, you can only log in with the very same authenticators you\'ve registered.', 'wp-webauthn').'

        '.__('An easily identifiable name for the authenticator. DOES NOT affect the authentication process in anyway.', 'wp-webauthn').'

        '.((wwa_get_option('usernameless_login') === "true") ? '

        '.__('If registered authenticator with this feature, you can login without enter your username.
        Some authenticators like U2F-only authenticators and some browsers DO NOT support this feature.
        A record will be stored in the authenticator permanently untill you reset it.', 'wp-webauthn').'

        ' : '').'

             

        '; -} -add_shortcode('wwa_register_form', 'wwa_register_form_shortcode'); - -// Verify button -function wwa_verify_button_shortcode($vals){ - extract(shortcode_atts( - array( - 'display' => 'true' - ), $vals) - ); - - // If always display - if(!current_user_can("read")){ - if($display === "true"){ - return '

        '.__('You haven\'t logged in yet.', 'wp-webauthn').'

        '; - }else{ - return ''; - } - } - - // Load Javascript - if(!wp_script_is('wwa_frontend_js')){ - wwa_localize_frontend(); - } - - return '

             '.(wwa_get_option('usernameless_login') === "true" ? '
             ' : '').'

        '; -} -add_shortcode('wwa_verify_button', 'wwa_verify_button_shortcode'); - -// Authenticator list -function wwa_list_shortcode($vals){ - extract(shortcode_atts( - array( - 'display' => 'true' - ), $vals) - ); - - $thead = '
        '; - $tbody = ''; - $tfoot = '
        '.__('Identifier', 'wp-webauthn').''.__('Type', 'wp-webauthn').''._x('Registered', 'time', 'wp-webauthn').''.__('Last used', 'time', 'wp-webauthn').''.__('Usernameless', 'wp-webauthn').''.__('Action', 'wp-webauthn').'
        '.__('Loading...', 'wp-webauthn').'
        '.__('Identifier', 'wp-webauthn').''.__('Type', 'wp-webauthn').''._x('Registered', 'time', 'wp-webauthn').''.__('Last used', 'time', 'wp-webauthn').''.__('Usernameless', 'wp-webauthn').''.__('Action', 'wp-webauthn').'

        '; - - // If always display - if(!current_user_can("read")){ - if($display === "true"){ - // Load CSS - wp_enqueue_style('wwa_frondend_css', plugins_url('css/frontend.css', __FILE__), array(), get_option('wwa_version')['version']); - - return $thead.''.__('You haven\'t logged in yet.', 'wp-webauthn').''.$tfoot; - }else{ - return ''; - } - } - - // Load Javascript & CSS - if(!wp_script_is('wwa_frontend_js')){ - wwa_localize_frontend(); - } - wp_enqueue_style('wwa_frondend_css', plugins_url('css/frontend.css', __FILE__), array(), get_option('wwa_version')['version']); - - return $thead.$tbody.$tfoot; -} -add_shortcode('wwa_list', 'wwa_list_shortcode'); -?> \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-version.php b/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-version.php deleted file mode 100644 index 3aca94cf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-webauthn/wwa-version.php +++ /dev/null @@ -1,6 +0,0 @@ - '1.2.8', - 'commit' => '52a8892' -); -?> \ No newline at end of file