Version Description
Download this release
Release Info
Developer | creativethemeshq |
Plugin | Blocksy Companion |
Version | 1.8.35 |
Comparing to | |
See all releases |
Code changes from version 1.8.34 to 1.8.35
- blocksy-companion.php +1 -1
- framework/extensions/cookies-consent/extension.php +20 -6
- framework/extensions/cookies-consent/static/bundle/main.js +2 -8
- framework/extensions/cookies-consent/static/bundle/main.js.LICENSE.txt +7 -0
- framework/extensions/cookies-consent/static/bundle/main.min.css +115 -2
- framework/extensions/cookies-consent/static/bundle/sync.js +1 -1
- framework/extensions/newsletter-subscribe/admin-static/bundle/1.f588f19f53311c8b6a0a.js +0 -14
- framework/extensions/newsletter-subscribe/admin-static/bundle/2.b8cdca0a643ec9bd1ed2.js +0 -1
- framework/extensions/newsletter-subscribe/admin-static/bundle/486.2f466d7115021070874d.js +2 -0
- framework/extensions/newsletter-subscribe/admin-static/bundle/486.2f466d7115021070874d.js.LICENSE.txt +14 -0
- framework/extensions/newsletter-subscribe/admin-static/bundle/677.6d4bfe6dc9293cdd7f96.js +1 -0
- framework/extensions/newsletter-subscribe/admin-static/bundle/main.js +1 -1
- framework/extensions/newsletter-subscribe/admin-static/bundle/sync.js +1 -1
- framework/extensions/newsletter-subscribe/dashboard-static/bundle/main.js +2 -14
- framework/extensions/newsletter-subscribe/dashboard-static/bundle/main.js.LICENSE.txt +14 -0
- framework/extensions/newsletter-subscribe/extension.php +21 -6
- framework/extensions/newsletter-subscribe/static/bundle/main.js +1 -1
- framework/extensions/newsletter-subscribe/static/bundle/main.min.css +105 -2
- framework/extensions/product-reviews/extension.php +22 -6
- framework/extensions/product-reviews/static/bundle/dashboard.js +2 -6
- framework/extensions/product-reviews/static/bundle/dashboard.js.LICENSE.txt +5 -0
- framework/extensions/product-reviews/static/bundle/main-admin.min.css +6 -2
- framework/extensions/product-reviews/static/bundle/main.min.css +186 -2
- framework/extensions/product-reviews/static/bundle/sync.js +1 -1
- framework/extensions/trending/extension.php +20 -6
- framework/extensions/trending/static/bundle/main.js +1 -1
- framework/extensions/trending/static/bundle/main.min.css +139 -2
- framework/extensions/trending/static/bundle/sync.js +1 -1
- framework/extensions/widgets/static/bundle/main.min.css +237 -2
- framework/extensions/widgets/widgets/ct-posts/view.php +1 -1
- framework/features/demo-install/install-finish.php +46 -0
- framework/features/header.php +17 -0
- framework/theme-integration.php +3 -1
- framework/views/blocksy-posts.php +8 -2
- languages/blocksy-companion.pot +3117 -1032
- readme.txt +5 -1
- static/bundle/account-lazy.min.css +156 -2
- static/bundle/account.js +1 -1
- static/bundle/dark-mode.js +1 -1
- static/bundle/dashboard.js +2 -6
- static/bundle/dashboard.js.LICENSE.txt +5 -0
- static/bundle/dashboard.min.css +1108 -2
- static/bundle/options.js +2 -14
blocksy-companion.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/*
|
4 |
Plugin Name: Blocksy Companion
|
5 |
Description: This plugin is the companion for the Blocksy theme, it runs and adds its enhacements only if the Blocksy theme is installed and active.
|
6 |
-
Version: 1.8.
|
7 |
Author: CreativeThemes
|
8 |
Author URI: https://creativethemes.com
|
9 |
Text Domain: blocksy-companion
|
3 |
/*
|
4 |
Plugin Name: Blocksy Companion
|
5 |
Description: This plugin is the companion for the Blocksy theme, it runs and adds its enhacements only if the Blocksy theme is installed and active.
|
6 |
+
Version: 1.8.35
|
7 |
Author: CreativeThemes
|
8 |
Author URI: https://creativethemes.com
|
9 |
Text Domain: blocksy-companion
|
framework/extensions/cookies-consent/extension.php
CHANGED
@@ -77,12 +77,26 @@ class BlocksyExtensionCookiesConsent {
|
|
77 |
);
|
78 |
}, 50);
|
79 |
|
80 |
-
add_action(
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
86 |
}
|
87 |
|
88 |
public function add_options_panel($options) {
|
77 |
);
|
78 |
}, 50);
|
79 |
|
80 |
+
add_action(
|
81 |
+
'blocksy:global-dynamic-css:enqueue',
|
82 |
+
'BlocksyExtensionCookiesConsent::add_global_styles',
|
83 |
+
10, 3
|
84 |
+
);
|
85 |
+
}
|
86 |
+
|
87 |
+
static public function add_global_styles($args) {
|
88 |
+
blocksy_theme_get_dynamic_styles(array_merge([
|
89 |
+
'path' => dirname(__FILE__) . '/global.php',
|
90 |
+
'chunk' => 'global',
|
91 |
+
], $args));
|
92 |
+
}
|
93 |
+
|
94 |
+
static public function onDeactivation() {
|
95 |
+
remove_action(
|
96 |
+
'blocksy:global-dynamic-css:enqueue',
|
97 |
+
'BlocksyExtensionCookiesConsent::add_global_styles',
|
98 |
+
10, 3
|
99 |
+
);
|
100 |
}
|
101 |
|
102 |
public function add_options_panel($options) {
|
framework/extensions/cookies-consent/static/bundle/main.js
CHANGED
@@ -1,8 +1,2 @@
|
|
1 |
-
|
2 |
-
|
3 |
-
* JavaScript Cookie v2.2.1
|
4 |
-
* https://github.com/js-cookie/js-cookie
|
5 |
-
*
|
6 |
-
* Copyright 2006, 2015 Klaus Hartl & Fagner Brack
|
7 |
-
* Released under the MIT license
|
8 |
-
*/!function(i){if(void 0===(r="function"==typeof(o=i)?o.call(t,n,t,e):o)||(e.exports=r),!0,e.exports=i(),!!0){var c=window.Cookies,a=window.Cookies=i();a.noConflict=function(){return window.Cookies=c,a}}}((function(){function e(){for(var e=0,t={};e<arguments.length;e++){var n=arguments[e];for(var o in n)t[o]=n[o]}return t}function t(e){return e.replace(/(%[0-9A-Z]{2})+/g,decodeURIComponent)}return function n(o){function r(){}function i(t,n,i){if("undefined"!=typeof document){"number"==typeof(i=e({path:"/"},r.defaults,i)).expires&&(i.expires=new Date(1*new Date+864e5*i.expires)),i.expires=i.expires?i.expires.toUTCString():"";try{var c=JSON.stringify(n);/^[\{\[]/.test(c)&&(n=c)}catch(e){}n=o.write?o.write(n,t):encodeURIComponent(String(n)).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent),t=encodeURIComponent(String(t)).replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent).replace(/[\(\)]/g,escape);var a="";for(var u in i)i[u]&&(a+="; "+u,!0!==i[u]&&(a+="="+i[u].split(";")[0]));return document.cookie=t+"="+n+a}}function c(e,n){if("undefined"!=typeof document){for(var r={},i=document.cookie?document.cookie.split("; "):[],c=0;c<i.length;c++){var a=i[c].split("="),u=a.slice(1).join("=");n||'"'!==u.charAt(0)||(u=u.slice(1,-1));try{var s=t(a[0]);if(u=(o.read||o)(u,s)||t(u),n)try{u=JSON.parse(u)}catch(e){}if(r[s]=u,e===s)break}catch(e){}}return e?r[e]:r}}return r.set=i,r.get=function(e){return c(e,!1)},r.getJSON=function(e){return c(e,!0)},r.remove=function(t,n){i(t,"",e(n,{expires:-1}))},r.defaults={},r.withConverter=n,r}((function(){}))}))},function(e,t){e.exports=window.ctEvents},function(e,t,n){"use strict";n.r(t),n.d(t,"onDocumentLoaded",(function(){return d}));var o=n(1),r=n.n(o),i=n(0),c=n.n(i);function a(e){return function(e){if(Array.isArray(e))return u(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return u(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return u(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,o=new Array(t);n<t;n++)o[n]=e[n];return o}var s=function(e){27===e.keyCode&&f(document.querySelector(".cookie-notification"))},f=function(e){document.removeEventListener("keyup",s),e.classList.add("ct-fade-start"),requestAnimationFrame((function(){e.classList.remove("ct-fade-start"),e.classList.add("ct-fade-end"),p(e,(function(){e.parentNode.removeChild(e)}))}))},d=function(e){/comp|inter|loaded/.test(document.readyState)?e():document.addEventListener("DOMContentLoaded",e,!1)},l=function(){var e,t=document.querySelector(".cookie-notification");t&&(c.a.get("blocksy_cookies_consent_accepted")?t.remove():(e=t,document.addEventListener("keyup",s),requestAnimationFrame((function(){e.classList.remove("ct-fade-in-start"),e.classList.add("ct-fade-in-end"),p(e,(function(){e.classList.remove("ct-fade-in-end")}))})),a(t.querySelectorAll("button")).map((function(e){e.addEventListener("click",(function(n){if(n.preventDefault(),e.classList.contains("ct-cookies-accept-button")){c.a.set("blocksy_cookies_consent_accepted","true",{expires:new Date(1*new Date+{onehour:36e5,oneday:864e5,oneweek:6048e5,onemonth:26784e5,threemonths:80352e5,sixmonths:160704e5,oneyear:31536e6,forever:864e9}[e.closest("[data-period]").dataset.period]),sameSite:"lax"})}if(e.classList.contains("ct-cookies-decline-button")){c.a.set("blocksy_cookies_consent_accepted","no",{expires:new Date(1*new Date+{onehour:36e5,oneday:864e5,oneweek:6048e5,onemonth:26784e5,threemonths:80352e5,sixmonths:160704e5,oneyear:31536e6,forever:864e9}[e.closest("[data-period]").dataset.period]),sameSite:"lax"})}f(t)}))}))))};function p(e,t){setTimeout((function(){t()}),300)}d((function(){l(),r.a&&r.a.on("blocksy:cookies:init",(function(){l()}))}))}]);
|
1 |
+
/*! For license information please see main.js.LICENSE.txt */
|
2 |
+
(()=>{var e={808:(e,t,n)=>{var o,r,i;i=function(){function e(){for(var e=0,t={};e<arguments.length;e++){var n=arguments[e];for(var o in n)t[o]=n[o]}return t}function t(e){return e.replace(/(%[0-9A-Z]{2})+/g,decodeURIComponent)}return function n(o){function r(){}function i(t,n,i){if("undefined"!=typeof document){"number"==typeof(i=e({path:"/"},r.defaults,i)).expires&&(i.expires=new Date(1*new Date+864e5*i.expires)),i.expires=i.expires?i.expires.toUTCString():"";try{var c=JSON.stringify(n);/^[\{\[]/.test(c)&&(n=c)}catch(e){}n=o.write?o.write(n,t):encodeURIComponent(String(n)).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent),t=encodeURIComponent(String(t)).replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent).replace(/[\(\)]/g,escape);var a="";for(var s in i)i[s]&&(a+="; "+s,!0!==i[s]&&(a+="="+i[s].split(";")[0]));return document.cookie=t+"="+n+a}}function c(e,n){if("undefined"!=typeof document){for(var r={},i=document.cookie?document.cookie.split("; "):[],c=0;c<i.length;c++){var a=i[c].split("="),s=a.slice(1).join("=");n||'"'!==s.charAt(0)||(s=s.slice(1,-1));try{var u=t(a[0]);if(s=(o.read||o)(s,u)||t(s),n)try{s=JSON.parse(s)}catch(e){}if(r[u]=s,e===u)break}catch(e){}}return e?r[e]:r}}return r.set=i,r.get=function(e){return c(e,!1)},r.getJSON=function(e){return c(e,!0)},r.remove=function(t,n){i(t,"",e(n,{expires:-1}))},r.defaults={},r.withConverter=n,r}((function(){}))},void 0===(r="function"==typeof(o=i)?o.call(t,n,t,e):o)||(e.exports=r),e.exports=i()}},t={};function n(o){var r=t[o];if(void 0!==r)return r.exports;var i=t[o]={exports:{}};return e[o](i,i.exports,n),i.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var o in t)n.o(t,o)&&!n.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";const e=window.ctEvents;var t=n.n(e),o=n(808),r=n.n(o);function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,o=new Array(t);n<t;n++)o[n]=e[n];return o}var c,a=function(e){27===e.keyCode&&s(document.querySelector(".cookie-notification"))},s=function(e){document.removeEventListener("keyup",a),e.classList.add("ct-fade-start"),requestAnimationFrame((function(){e.classList.remove("ct-fade-start"),e.classList.add("ct-fade-end"),d(0,(function(){e.parentNode.removeChild(e)}))}))},u=function(){var e,t,n=document.querySelector(".cookie-notification");n&&(r().get("blocksy_cookies_consent_accepted")?n.remove():(e=n,document.addEventListener("keyup",a),requestAnimationFrame((function(){e.classList.remove("ct-fade-in-start"),e.classList.add("ct-fade-in-end"),d(0,(function(){e.classList.remove("ct-fade-in-end")}))})),(t=n.querySelectorAll("button"),function(e){if(Array.isArray(e))return i(e)}(t)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(t)||function(e,t){if(e){if("string"==typeof e)return i(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(e,t):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).map((function(e){e.addEventListener("click",(function(t){t.preventDefault(),e.classList.contains("ct-cookies-accept-button")&&r().set("blocksy_cookies_consent_accepted","true",{expires:new Date(1*new Date+{onehour:36e5,oneday:864e5,oneweek:6048e5,onemonth:26784e5,threemonths:80352e5,sixmonths:160704e5,oneyear:31536e6,forever:864e9}[e.closest("[data-period]").dataset.period]),sameSite:"lax"}),e.classList.contains("ct-cookies-decline-button")&&r().set("blocksy_cookies_consent_accepted","no",{expires:new Date(1*new Date+{onehour:36e5,oneday:864e5,oneweek:6048e5,onemonth:26784e5,threemonths:80352e5,sixmonths:160704e5,oneyear:31536e6,forever:864e9}[e.closest("[data-period]").dataset.period]),sameSite:"lax"}),s(n)}))}))))};function d(e,t){setTimeout((function(){t()}),300)}c=function(){u(),t()&&t().on("blocksy:cookies:init",(function(){u()}))},/comp|inter|loaded/.test(document.readyState)?c():document.addEventListener("DOMContentLoaded",c,!1)})()})();
|
|
|
|
|
|
|
|
|
|
|
|
framework/extensions/cookies-consent/static/bundle/main.js.LICENSE.txt
ADDED
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/*!
|
2 |
+
* JavaScript Cookie v2.2.1
|
3 |
+
* https://github.com/js-cookie/js-cookie
|
4 |
+
*
|
5 |
+
* Copyright 2006, 2015 Klaus Hartl & Fagner Brack
|
6 |
+
* Released under the MIT license
|
7 |
+
*/
|
framework/extensions/cookies-consent/static/bundle/main.min.css
CHANGED
@@ -1,8 +1,121 @@
|
|
1 |
/**
|
2 |
-
* - v1.8.
|
3 |
*
|
4 |
* Copyright (c) 2022
|
5 |
* Licensed GPLv2+
|
6 |
*/
|
7 |
|
8 |
-
.cookie-notification
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
/**
|
2 |
+
* - v1.8.35
|
3 |
*
|
4 |
* Copyright (c) 2022
|
5 |
* Licensed GPLv2+
|
6 |
*/
|
7 |
|
8 |
+
.cookie-notification {
|
9 |
+
position: fixed;
|
10 |
+
left: var(--frame-size, 0px);
|
11 |
+
bottom: var(--frame-size, 0px);
|
12 |
+
z-index: 999999;
|
13 |
+
color: var(--color);
|
14 |
+
}
|
15 |
+
.cookie-notification a:hover {
|
16 |
+
color: var(--colorHover);
|
17 |
+
}
|
18 |
+
@media (max-width: 689.98px) {
|
19 |
+
.cookie-notification {
|
20 |
+
right: var(--frame-size, 0px);
|
21 |
+
}
|
22 |
+
}
|
23 |
+
.cookie-notification > div {
|
24 |
+
display: flex;
|
25 |
+
flex-direction: column;
|
26 |
+
gap: 20px;
|
27 |
+
padding: 20px 0;
|
28 |
+
}
|
29 |
+
@media (max-width: 689.98px) {
|
30 |
+
.cookie-notification > div {
|
31 |
+
align-items: center;
|
32 |
+
}
|
33 |
+
}
|
34 |
+
@media (max-width: 689.98px) {
|
35 |
+
.cookie-notification[data-type=type-1] {
|
36 |
+
background: var(--backgroundColor);
|
37 |
+
}
|
38 |
+
}
|
39 |
+
@media (min-width: 690px) {
|
40 |
+
.cookie-notification[data-type=type-1] {
|
41 |
+
padding: 0 25px 25px 25px;
|
42 |
+
}
|
43 |
+
}
|
44 |
+
.cookie-notification[data-type=type-1] .container {
|
45 |
+
position: relative;
|
46 |
+
}
|
47 |
+
@media (max-width: 689.98px) {
|
48 |
+
.cookie-notification[data-type=type-1] .container {
|
49 |
+
width: 88%;
|
50 |
+
margin: 0 auto;
|
51 |
+
}
|
52 |
+
}
|
53 |
+
@media (min-width: 690px) {
|
54 |
+
.cookie-notification[data-type=type-1] .container {
|
55 |
+
background: var(--backgroundColor);
|
56 |
+
box-shadow: 0px 5px 30px -5px rgba(34, 56, 101, 0.15);
|
57 |
+
padding: 30px;
|
58 |
+
border-radius: 3px;
|
59 |
+
max-width: var(--maxWidth);
|
60 |
+
}
|
61 |
+
}
|
62 |
+
.cookie-notification[data-type=type-2] {
|
63 |
+
right: var(--frame-size, 0px);
|
64 |
+
padding-right: var(--scrollbar-width, 0px);
|
65 |
+
background: var(--backgroundColor);
|
66 |
+
}
|
67 |
+
@media (min-width: 690px) {
|
68 |
+
.cookie-notification[data-type=type-2] .ct-container {
|
69 |
+
flex-direction: initial;
|
70 |
+
align-items: center;
|
71 |
+
justify-content: center;
|
72 |
+
}
|
73 |
+
}
|
74 |
+
.cookie-notification .ct-cookies-content {
|
75 |
+
font-size: 14px;
|
76 |
+
line-height: 1.4;
|
77 |
+
}
|
78 |
+
.cookie-notification .ct-cookies-content > *:last-child {
|
79 |
+
margin-bottom: 0;
|
80 |
+
}
|
81 |
+
.cookie-notification .ct-cookies-content a {
|
82 |
+
text-decoration: underline;
|
83 |
+
color: var(--colorHover);
|
84 |
+
}
|
85 |
+
@media (max-width: 689.98px) {
|
86 |
+
.cookie-notification .ct-cookies-content {
|
87 |
+
text-align: center;
|
88 |
+
}
|
89 |
+
}
|
90 |
+
.cookie-notification .ct-button-group {
|
91 |
+
display: flex;
|
92 |
+
gap: 10px;
|
93 |
+
}
|
94 |
+
@media (max-width: 479.98px) {
|
95 |
+
.cookie-notification .ct-button-group {
|
96 |
+
width: 100%;
|
97 |
+
}
|
98 |
+
}
|
99 |
+
.cookie-notification .ct-button-group .ct-button {
|
100 |
+
--buttonFontSize: 13px;
|
101 |
+
--buttonMinHeight: 35px;
|
102 |
+
--padding: 0 20px;
|
103 |
+
--buttonShadow: none;
|
104 |
+
--buttonTransform: none;
|
105 |
+
}
|
106 |
+
@media (max-width: 479.98px) {
|
107 |
+
.cookie-notification .ct-button-group .ct-button {
|
108 |
+
flex: 1;
|
109 |
+
}
|
110 |
+
}
|
111 |
+
.cookie-notification.ct-fade-in-start, .cookie-notification.ct-fade-in-end, .cookie-notification.ct-fade-start, .cookie-notification.ct-fade-end {
|
112 |
+
transition: all 0.3s ease;
|
113 |
+
}
|
114 |
+
.cookie-notification.ct-fade-in-start {
|
115 |
+
opacity: 0;
|
116 |
+
transform: translate3d(0, 15px, 0);
|
117 |
+
}
|
118 |
+
.cookie-notification.ct-fade-end {
|
119 |
+
opacity: 0;
|
120 |
+
transform: translate3d(0, 15px, 0);
|
121 |
+
}
|
framework/extensions/cookies-consent/static/bundle/sync.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
|
1 |
+
(()=>{"use strict";var e={n:t=>{var o=t&&t.__esModule?()=>t.default:()=>t;return e.d(o,{a:o}),o},d:(t,o)=>{for(var r in o)e.o(o,r)&&!e.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:o[r]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t)};const t=window.ctEvents;var o=e.n(t);function r(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,r)}return o}function n(e){for(var t=1;t<arguments.length;t++){var o=null!=arguments[t]?arguments[t]:{};t%2?r(Object(o),!0).forEach((function(t){i(e,t,o[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):r(Object(o)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(o,t))}))}return e}function i(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}function c(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var o=[],r=!0,n=!1,i=void 0;try{for(var c,a=e[Symbol.iterator]();!(r=(c=a.next()).done)&&(o.push(c.value),!t||o.length!==t);r=!0);}catch(e){n=!0,i=e}finally{try{r||null==a.return||a.return()}finally{if(n)throw i}}return o}}(e,t)||l(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function a(e){return function(e){if(Array.isArray(e))return u(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||l(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function l(e,t){if(e){if("string"==typeof e)return u(e,t);var o=Object.prototype.toString.call(e).slice(8,-1);return"Object"===o&&e.constructor&&(o=e.constructor.name),"Map"===o||"Set"===o?Array.from(e):"Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o)?u(e,t):void 0}}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var o=0,r=new Array(t);o<t;o++)r[o]=e[o];return r}function s(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,r)}return o}function f(e){for(var t=1;t<arguments.length;t++){var o=null!=arguments[t]?arguments[t]:{};t%2?s(Object(o),!0).forEach((function(t){b(e,t,o[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):s(Object(o)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(o,t))}))}return e}function b(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}o().on("ct:customizer:sync:collect-variable-descriptors",(function(e){e.result=n(n({},e.result),{},{cookieContentColor:[{selector:".cookie-notification",variable:"color",type:"color:default"},{selector:".cookie-notification",variable:"colorHover",type:"color:hover"}],cookieBackground:{selector:".cookie-notification",variable:"backgroundColor",type:"color"},cookieButtonText:[{selector:".cookie-notification .ct-cookies-accept-button",variable:"buttonTextInitialColor",type:"color:default"},{selector:".cookie-notification .ct-cookies-accept-button",variable:"buttonTextHoverColor",type:"color:hover"}],cookieButtonBackground:[{selector:".cookie-notification .ct-cookies-accept-button",variable:"buttonInitialColor",type:"color:default"},{selector:".cookie-notification .ct-cookies-accept-button",variable:"buttonHoverColor",type:"color:hover"}],cookieDeclineButtonText:[{selector:".cookie-notification .ct-cookies-decline-button",variable:"buttonTextInitialColor",type:"color:default"},{selector:".cookie-notification .ct-cookies-decline-button",variable:"buttonTextHoverColor",type:"color:hover"}],cookieDeclineButtonBackground:[{selector:".cookie-notification .ct-cookies-decline-button",variable:"buttonInitialColor",type:"color:default"},{selector:".cookie-notification .ct-cookies-decline-button",variable:"buttonHoverColor",type:"color:hover"}],cookieMaxWidth:{selector:".cookie-notification",variable:"maxWidth",unit:"px"}})}));var p=function(){var e=document.createElement("div");return e.innerHTML=document.querySelector(".ct-customizer-preview-cache-container").value,e},y=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"id";if(t||(t=p()),t.querySelector(".ct-customizer-preview-cache [data-".concat(o,'="').concat(e,'"]'))){var r=t.querySelector(".ct-customizer-preview-cache [data-".concat(o,'="').concat(e,'"]')).innerHTML,n=document.createElement("div");return n.innerHTML=r,n}};function d(e,t){(null==t||t>e.length)&&(t=e.length);for(var o=0,r=new Array(t);o<t;o++)r[o]=e[o];return r}var m=function(){var e=function(e){if(!document.querySelector(".cookie-notification"))return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e=f({fragment_id:null,selector:null,parent_selector:null,strategy:"append",whenInserted:function(){},beforeInsert:function(e){},should_insert:!0},e);var t=document.querySelector(e.parent_selector);if(a(document.querySelectorAll("".concat(e.parent_selector," ").concat(e.selector))).map((function(e){return e.parentNode.removeChild(e)})),e.should_insert){var o=y(e.fragment_id);if(o){for(;o.firstElementChild;)if(e.beforeInsert(o.firstElementChild),"append"===e.strategy&&t.appendChild(o.firstElementChild),"firstChild"===e.strategy&&t.insertBefore(o.firstElementChild,t.firstElementChild),e.strategy.indexOf("maybeBefore")>-1){var r=c(e.strategy.split(":"),2),n=(r[0],r[1]);t.querySelector(n)?t.insertBefore(o.firstElementChild,t.querySelector(n)):t.appendChild(o.firstElementChild)}e.whenInserted()}}}({fragment_id:"blocksy-cookies-consent-section",selector:".cookie-notification",parent_selector:"#main-container"}),!0}(),t=document.querySelector(".cookie-notification");if(t){t.querySelector(".ct-cookies-content")&&(t.querySelector(".ct-cookies-content").innerHTML=wp.customize("cookie_consent_content")()),t.querySelector("button.ct-cookies-accept-button").innerHTML=wp.customize("cookie_consent_button_text")();var r=wp.customize("cookie_consent_type")();t.dataset.type=r,t.firstElementChild.classList.remove("ct-container","container"),t.firstElementChild.classList.add("type-1"===r?"container":"ct-container"),e&&setTimeout((function(){return o().trigger("blocksy:cookies:init")}))}};wp.customize("cookie_consent_content",(function(e){return e.bind((function(e){m()}))})),wp.customize("cookie_consent_button_text",(function(e){return e.bind((function(e){return m()}))})),wp.customize("cookie_consent_type",(function(e){return e.bind((function(e){return m()}))})),wp.customize("forms_cookie_consent_content",(function(e){return e.bind((function(e){return(t=document.querySelectorAll(".gdpr-confirm-policy label"),function(e){if(Array.isArray(e))return d(e)}(t)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(t)||function(e,t){if(e){if("string"==typeof e)return d(e,t);var o=Object.prototype.toString.call(e).slice(8,-1);return"Object"===o&&e.constructor&&(o=e.constructor.name),"Map"===o||"Set"===o?Array.from(e):"Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o)?d(e,t):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).map((function(t){return t.innerHTML=e}));var t}))}))})();
|
framework/extensions/newsletter-subscribe/admin-static/bundle/1.f588f19f53311c8b6a0a.js
DELETED
@@ -1,14 +0,0 @@
|
|
1 |
-
(window.blocksyNewsletterSubscribeExtJsonp=window.blocksyNewsletterSubscribeExtJsonp||[]).push([[1],[,,,,,,function(e,t,n){var o;
|
2 |
-
/*!
|
3 |
-
Copyright (c) 2017 Jed Watson.
|
4 |
-
Licensed under the MIT License (MIT), see
|
5 |
-
http://jedwatson.github.io/classnames
|
6 |
-
*/!function(){"use strict";var n={}.hasOwnProperty;function r(){for(var e=[],t=0;t<arguments.length;t++){var o=arguments[t];if(o){var i=typeof o;if("string"===i||"number"===i)e.push(o);else if(Array.isArray(o)&&o.length){var s=r.apply(null,o);s&&e.push(s)}else if("object"===i)for(var u in o)n.call(o,u)&&o[u]&&e.push(u)}}return e.join(" ")}e.exports?(r.default=r,e.exports=r):void 0===(o=function(){return r}.apply(t,[]))||(e.exports=o)}()},function(e,t,n){e.exports=n(8)()},function(e,t,n){"use strict";var o=n(9);function r(){}function i(){}i.resetWarningCache=r,e.exports=function(){function e(e,t,n,r,i,s){if(s!==o){var u=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 u.name="Invariant Violation",u}}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:i,resetWarningCache:r};return n.PropTypes=n,n}},function(e,t,n){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(e,t,n){"use strict";e.exports=n(11)},function(e,t,n){"use strict";
|
7 |
-
/** @license React v16.13.1
|
8 |
-
* react-is.production.min.js
|
9 |
-
*
|
10 |
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
11 |
-
*
|
12 |
-
* This source code is licensed under the MIT license found in the
|
13 |
-
* LICENSE file in the root directory of this source tree.
|
14 |
-
*/var o="function"==typeof Symbol&&Symbol.for,r=o?Symbol.for("react.element"):60103,i=o?Symbol.for("react.portal"):60106,s=o?Symbol.for("react.fragment"):60107,u=o?Symbol.for("react.strict_mode"):60108,a=o?Symbol.for("react.profiler"):60114,l=o?Symbol.for("react.provider"):60109,p=o?Symbol.for("react.context"):60110,d=o?Symbol.for("react.async_mode"):60111,c=o?Symbol.for("react.concurrent_mode"):60111,h=o?Symbol.for("react.forward_ref"):60112,f=o?Symbol.for("react.suspense"):60113,g=o?Symbol.for("react.suspense_list"):60120,m=o?Symbol.for("react.memo"):60115,v=o?Symbol.for("react.lazy"):60116,y=o?Symbol.for("react.block"):60121,I=o?Symbol.for("react.fundamental"):60117,S=o?Symbol.for("react.responder"):60118,b=o?Symbol.for("react.scope"):60119;function w(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case r:switch(e=e.type){case d:case c:case s:case a:case u:case f:return e;default:switch(e=e&&e.$$typeof){case p:case h:case v:case m:case l:return e;default:return t}}case i:return t}}}function x(e){return w(e)===c}t.AsyncMode=d,t.ConcurrentMode=c,t.ContextConsumer=p,t.ContextProvider=l,t.Element=r,t.ForwardRef=h,t.Fragment=s,t.Lazy=v,t.Memo=m,t.Portal=i,t.Profiler=a,t.StrictMode=u,t.Suspense=f,t.isAsyncMode=function(e){return x(e)||w(e)===d},t.isConcurrentMode=x,t.isContextConsumer=function(e){return w(e)===p},t.isContextProvider=function(e){return w(e)===l},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===r},t.isForwardRef=function(e){return w(e)===h},t.isFragment=function(e){return w(e)===s},t.isLazy=function(e){return w(e)===v},t.isMemo=function(e){return w(e)===m},t.isPortal=function(e){return w(e)===i},t.isProfiler=function(e){return w(e)===a},t.isStrictMode=function(e){return w(e)===u},t.isSuspense=function(e){return w(e)===f},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===s||e===c||e===a||e===u||e===f||e===g||"object"==typeof e&&null!==e&&(e.$$typeof===v||e.$$typeof===m||e.$$typeof===l||e.$$typeof===p||e.$$typeof===h||e.$$typeof===I||e.$$typeof===S||e.$$typeof===b||e.$$typeof===y)},t.typeOf=w},function(e,t,n){"use strict";function o(e,t){if(null==e)return{};var n,o,r={},i=Object.keys(e);for(o=0;o<i.length;o++)n=i[o],t.indexOf(n)>=0||(r[n]=e[n]);return r}function r(){return(r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o])}return e}).apply(this,arguments)}function i(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var s=n(7),u=n.n(s),a=n(1);n(10);function l(e){return null!=e&&"object"==typeof e&&1===e.nodeType}function p(e,t){return(!t||"hidden"!==e)&&("visible"!==e&&"clip"!==e)}function d(e,t){if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){var n=getComputedStyle(e,null);return p(n.overflowY,t)||p(n.overflowX,t)||function(e){var t=function(e){return e.ownerDocument&&e.ownerDocument.defaultView?e.ownerDocument.defaultView.frameElement:null}(e);return!!t&&(t.clientHeight<e.scrollHeight||t.clientWidth<e.scrollWidth)}(e)}return!1}function c(e,t,n,o,r,i,s,u){return i<e&&s>t||i>e&&s<t?0:i<=e&&u<=n||s>=t&&u>=n?i-e-o:s>t&&u<n||i<e&&u>n?s-t+r:0}var h=0;function f(e){return"function"==typeof e?e:g}function g(){}function m(e,t){null!==e&&function(e,t){var n=t.scrollMode,o=t.block,r=t.inline,i=t.boundary,s=t.skipOverflowHiddenElements,u="function"==typeof i?i:function(e){return e!==i};if(!l(e))throw new TypeError("Invalid target");for(var a=document.scrollingElement||document.documentElement,p=[],h=e;l(h)&&u(h);){if((h=h.parentNode)===a){p.push(h);break}h===document.body&&d(h)&&!d(document.documentElement)||d(h,s)&&p.push(h)}for(var f=window.visualViewport?visualViewport.width:innerWidth,g=window.visualViewport?visualViewport.height:innerHeight,m=window.scrollX||pageXOffset,v=window.scrollY||pageYOffset,y=e.getBoundingClientRect(),I=y.height,S=y.width,b=y.top,w=y.right,x=y.bottom,C=y.left,H="start"===o||"nearest"===o?b:"end"===o?x:b+I/2,O="center"===r?C+S/2:"end"===r?w:C,E=[],P=0;P<p.length;P++){var M=p[P],D=M.getBoundingClientRect(),T=D.height,k=D.width,R=D.top,A=D.right,V=D.bottom,K=D.left;if("if-needed"===n&&b>=0&&C>=0&&x<=g&&w<=f&&b>=R&&x<=V&&C>=K&&w<=A)return E;var _=getComputedStyle(M),L=parseInt(_.borderLeftWidth,10),$=parseInt(_.borderTopWidth,10),B=parseInt(_.borderRightWidth,10),j=parseInt(_.borderBottomWidth,10),W=0,N=0,U="offsetWidth"in M?M.offsetWidth-M.clientWidth-L-B:0,F="offsetHeight"in M?M.offsetHeight-M.clientHeight-$-j:0;if(a===M)W="start"===o?H:"end"===o?H-g:"nearest"===o?c(v,v+g,g,$,j,v+H,v+H+I,I):H-g/2,N="start"===r?O:"center"===r?O-f/2:"end"===r?O-f:c(m,m+f,f,L,B,m+O,m+O+S,S),W=Math.max(0,W+v),N=Math.max(0,N+m);else{W="start"===o?H-R-$:"end"===o?H-V+j+F:"nearest"===o?c(R,V,T,$,j+F,H,H+I,I):H-(R+T/2)+F/2,N="start"===r?O-K-L:"center"===r?O-(K+k/2)+U/2:"end"===r?O-A+B+U:c(K,A,k,L,B+U,O,O+S,S);var z=M.scrollLeft,Y=M.scrollTop;H+=Y-(W=Math.max(0,Math.min(Y+W,M.scrollHeight-T+F))),O+=z-(N=Math.max(0,Math.min(z+N,M.scrollWidth-k+U)))}E.push({el:M,top:W,left:N})}return E}(e,{boundary:t,block:"nearest",scrollMode:"if-needed"}).forEach((function(e){var t=e.el,n=e.top,o=e.left;t.scrollTop=n,t.scrollLeft=o}))}function v(e,t){return e===t||e.contains&&e.contains(t)}function y(e,t){var n;function o(){n&&clearTimeout(n)}function r(){for(var r=arguments.length,i=new Array(r),s=0;s<r;s++)i[s]=arguments[s];o(),n=setTimeout((function(){n=null,e.apply(void 0,i)}),t)}return r.cancel=o,r}function I(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){for(var n=arguments.length,o=new Array(n>1?n-1:0),r=1;r<n;r++)o[r-1]=arguments[r];return t.some((function(t){return t&&t.apply(void 0,[e].concat(o)),e.preventDownshiftDefault||e.hasOwnProperty("nativeEvent")&&e.nativeEvent.preventDownshiftDefault}))}}function S(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){t.forEach((function(t){"function"==typeof t?t(e):t&&(t.current=e)}))}}function b(e){var t=e.isOpen,n=e.selectedItem,o=e.resultCount,r=e.previousResultCount,i=e.itemToString;return t?o?o!==r?o+" result"+(1===o?" is":"s are")+" available, use up and down arrow keys to navigate. Press Enter key to select.":"":"No results are available.":n?i(n):""}function w(e,t){return!(e=Array.isArray(e)?e[0]:e)&&t?t:e}function x(e){return"string"==typeof e.type}function C(e){return e.props}var H=["highlightedIndex","inputValue","isOpen","selectedItem","type"];function O(e){void 0===e&&(e={});var t={};return H.forEach((function(n){e.hasOwnProperty(n)&&(t[n]=e[n])})),t}function E(e){var t=e.key,n=e.keyCode;return n>=37&&n<=40&&0!==t.indexOf("Arrow")?"Arrow"+t:t}function P(e,t,n){var o=n-1;("number"!=typeof t||t<0||t>=n)&&(t=e>0?-1:o+1);var r=t+e;return r<0?r=o:r>o&&(r=0),r}var M=y((function(){T().textContent=""}),500);function D(e,t){var n=T(t);e&&(n.textContent=e,M())}function T(e){void 0===e&&(e=document);var t=e.getElementById("a11y-status-message");return t||((t=e.createElement("div")).setAttribute("id","a11y-status-message"),t.setAttribute("role","status"),t.setAttribute("aria-live","polite"),t.setAttribute("aria-relevant","additions text"),Object.assign(t.style,{border:"0",clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:"0",position:"absolute",width:"1px"}),e.body.appendChild(t),t)}var k=Object.freeze({__proto__:null,unknown:0,mouseUp:1,itemMouseEnter:2,keyDownArrowUp:3,keyDownArrowDown:4,keyDownEscape:5,keyDownEnter:6,keyDownHome:7,keyDownEnd:8,clickItem:9,blurInput:10,changeInput:11,keyDownSpaceButton:12,clickButton:13,blurButton:14,controlledPropUpdatedSelectedItem:15,touchEnd:16}),R=function(){var e=function(e){var t,n;function s(t){var n=e.call(this,t)||this;n.id=n.props.id||"downshift-"+String(h++),n.menuId=n.props.menuId||n.id+"-menu",n.labelId=n.props.labelId||n.id+"-label",n.inputId=n.props.inputId||n.id+"-input",n.getItemId=n.props.getItemId||function(e){return n.id+"-item-"+e},n.input=null,n.items=[],n.itemCount=null,n.previousResultCount=0,n.timeoutIds=[],n.internalSetTimeout=function(e,t){var o=setTimeout((function(){n.timeoutIds=n.timeoutIds.filter((function(e){return e!==o})),e()}),t);n.timeoutIds.push(o)},n.setItemCount=function(e){n.itemCount=e},n.unsetItemCount=function(){n.itemCount=null},n.setHighlightedIndex=function(e,t){void 0===e&&(e=n.props.defaultHighlightedIndex),void 0===t&&(t={}),t=O(t),n.internalSetState(r({highlightedIndex:e},t))},n.clearSelection=function(e){n.internalSetState({selectedItem:null,inputValue:"",highlightedIndex:n.props.defaultHighlightedIndex,isOpen:n.props.defaultIsOpen},e)},n.selectItem=function(e,t,o){t=O(t),n.internalSetState(r({isOpen:n.props.defaultIsOpen,highlightedIndex:n.props.defaultHighlightedIndex,selectedItem:e,inputValue:n.props.itemToString(e)},t),o)},n.selectItemAtIndex=function(e,t,o){var r=n.items[e];null!=r&&n.selectItem(r,t,o)},n.selectHighlightedItem=function(e,t){return n.selectItemAtIndex(n.getState().highlightedIndex,e,t)},n.internalSetState=function(e,t){var o,i,s={},u="function"==typeof e;return!u&&e.hasOwnProperty("inputValue")&&n.props.onInputValueChange(e.inputValue,r({},n.getStateAndHelpers(),{},e)),n.setState((function(t){t=n.getState(t);var a=u?e(t):e;a=n.props.stateReducer(t,a),o=a.hasOwnProperty("selectedItem");var l={},p={};return o&&a.selectedItem!==t.selectedItem&&(i=a.selectedItem),a.type=a.type||0,Object.keys(a).forEach((function(e){t[e]!==a[e]&&(s[e]=a[e]),"type"!==e&&(p[e]=a[e],n.isControlledProp(e)||(l[e]=a[e]))})),u&&a.hasOwnProperty("inputValue")&&n.props.onInputValueChange(a.inputValue,r({},n.getStateAndHelpers(),{},a)),l}),(function(){f(t)(),Object.keys(s).length>1&&n.props.onStateChange(s,n.getStateAndHelpers()),o&&n.props.onSelect(e.selectedItem,n.getStateAndHelpers()),void 0!==i&&n.props.onChange(i,n.getStateAndHelpers()),n.props.onUserAction(s,n.getStateAndHelpers())}))},n.rootRef=function(e){return n._rootNode=e},n.getRootProps=function(e,t){var i,s=void 0===e?{}:e,u=s.refKey,a=void 0===u?"ref":u,l=s.ref,p=o(s,["refKey","ref"]),d=(void 0===t?{}:t).suppressRefError,c=void 0!==d&&d;n.getRootProps.called=!0,n.getRootProps.refKey=a,n.getRootProps.suppressRefError=c;var h=n.getState().isOpen;return r(((i={})[a]=S(l,n.rootRef),i.role="combobox",i["aria-expanded"]=h,i["aria-haspopup"]="listbox",i["aria-owns"]=h?n.menuId:null,i["aria-labelledby"]=n.labelId,i),p)},n.keyDownHandlers={ArrowDown:function(e){var t=this;if(e.preventDefault(),this.getState().isOpen){var n=e.shiftKey?5:1;this.moveHighlightedIndex(n,{type:4})}else this.internalSetState({isOpen:!0,type:4},(function(){var e=t.getItemCount();e>0&&t.setHighlightedIndex(P(1,t.getState().highlightedIndex,e),{type:4})}))},ArrowUp:function(e){var t=this;if(e.preventDefault(),this.getState().isOpen){var n=e.shiftKey?-5:-1;this.moveHighlightedIndex(n,{type:3})}else this.internalSetState({isOpen:!0,type:3},(function(){var e=t.getItemCount();e>0&&t.setHighlightedIndex(P(-1,t.getState().highlightedIndex,e),{type:4})}))},Enter:function(e){var t=this.getState(),n=t.isOpen,o=t.highlightedIndex;if(n&&null!=o){e.preventDefault();var r=this.items[o],i=this.getItemNodeFromIndex(o);if(null==r||i&&i.hasAttribute("disabled"))return;this.selectHighlightedItem({type:6})}},Escape:function(e){e.preventDefault(),this.reset({type:5,selectedItem:null,inputValue:""})}},n.buttonKeyDownHandlers=r({},n.keyDownHandlers,{" ":function(e){e.preventDefault(),this.toggleMenu({type:12})}}),n.inputKeyDownHandlers=r({},n.keyDownHandlers,{Home:function(e){this.highlightFirstOrLastIndex(e,!0,{type:7})},End:function(e){this.highlightFirstOrLastIndex(e,!1,{type:8})}}),n.getToggleButtonProps=function(e){var t=void 0===e?{}:e,i=t.onClick,s=(t.onPress,t.onKeyDown),u=t.onKeyUp,a=t.onBlur,l=o(t,["onClick","onPress","onKeyDown","onKeyUp","onBlur"]),p=n.getState().isOpen,d={onClick:I(i,n.buttonHandleClick),onKeyDown:I(s,n.buttonHandleKeyDown),onKeyUp:I(u,n.buttonHandleKeyUp),onBlur:I(a,n.buttonHandleBlur)};return r({type:"button",role:"button","aria-label":p?"close menu":"open menu","aria-haspopup":!0,"data-toggle":!0},l.disabled?{}:d,{},l)},n.buttonHandleKeyUp=function(e){e.preventDefault()},n.buttonHandleKeyDown=function(e){var t=E(e);n.buttonKeyDownHandlers[t]&&n.buttonKeyDownHandlers[t].call(i(n),e)},n.buttonHandleClick=function(e){e.preventDefault(),n.props.environment.document.activeElement===n.props.environment.document.body&&e.target.focus(),n.internalSetTimeout((function(){return n.toggleMenu({type:13})}))},n.buttonHandleBlur=function(e){var t=e.target;n.internalSetTimeout((function(){n.isMouseDown||null!=n.props.environment.document.activeElement&&n.props.environment.document.activeElement.id===n.inputId||n.props.environment.document.activeElement===t||n.reset({type:14})}))},n.getLabelProps=function(e){return r({htmlFor:n.inputId,id:n.labelId},e)},n.getInputProps=function(e){var t=void 0===e?{}:e,i=t.onKeyDown,s=t.onBlur,u=t.onChange,a=t.onInput,l=(t.onChangeText,o(t,["onKeyDown","onBlur","onChange","onInput","onChangeText"])),p={};var d,c=n.getState(),h=c.inputValue,f=c.isOpen,g=c.highlightedIndex;l.disabled||((d={}).onChange=I(u,a,n.inputHandleChange),d.onKeyDown=I(i,n.inputHandleKeyDown),d.onBlur=I(s,n.inputHandleBlur),p=d);return r({"aria-autocomplete":"list","aria-activedescendant":f&&"number"==typeof g&&g>=0?n.getItemId(g):null,"aria-controls":f?n.menuId:null,"aria-labelledby":n.labelId,autoComplete:"off",value:h,id:n.inputId},p,{},l)},n.inputHandleKeyDown=function(e){var t=E(e);t&&n.inputKeyDownHandlers[t]&&n.inputKeyDownHandlers[t].call(i(n),e)},n.inputHandleChange=function(e){n.internalSetState({type:11,isOpen:!0,inputValue:e.target.value,highlightedIndex:n.props.defaultHighlightedIndex})},n.inputHandleBlur=function(){n.internalSetTimeout((function(){var e=n.props.environment.document&&!!n.props.environment.document.activeElement&&!!n.props.environment.document.activeElement.dataset&&n.props.environment.document.activeElement.dataset.toggle&&n._rootNode&&n._rootNode.contains(n.props.environment.document.activeElement);n.isMouseDown||e||n.reset({type:10})}))},n.menuRef=function(e){n._menuNode=e},n.getMenuProps=function(e,t){var i,s=void 0===e?{}:e,u=s.refKey,a=void 0===u?"ref":u,l=s.ref,p=o(s,["refKey","ref"]),d=(void 0===t?{}:t).suppressRefError,c=void 0!==d&&d;return n.getMenuProps.called=!0,n.getMenuProps.refKey=a,n.getMenuProps.suppressRefError=c,r(((i={})[a]=S(l,n.menuRef),i.role="listbox",i["aria-labelledby"]=p&&p["aria-label"]?null:n.labelId,i.id=n.menuId,i),p)},n.getItemProps=function(e){var t,i=void 0===e?{}:e,s=i.onMouseMove,u=i.onMouseDown,a=i.onClick,l=(i.onPress,i.index),p=i.item,d=void 0===p?void 0:p,c=o(i,["onMouseMove","onMouseDown","onClick","onPress","index","item"]);void 0===l?(n.items.push(d),l=n.items.indexOf(d)):n.items[l]=d;var h=a,f=((t={onMouseMove:I(s,(function(){l!==n.getState().highlightedIndex&&(n.setHighlightedIndex(l,{type:2}),n.avoidScrolling=!0,n.internalSetTimeout((function(){return n.avoidScrolling=!1}),250))})),onMouseDown:I(u,(function(e){e.preventDefault()}))}).onClick=I(h,(function(){n.selectItemAtIndex(l,{type:9})})),t),g=c.disabled?{onMouseDown:f.onMouseDown}:f;return r({id:n.getItemId(l),role:"option","aria-selected":n.getState().highlightedIndex===l},g,{},c)},n.clearItems=function(){n.items=[]},n.reset=function(e,t){void 0===e&&(e={}),e=O(e),n.internalSetState((function(t){var o=t.selectedItem;return r({isOpen:n.props.defaultIsOpen,highlightedIndex:n.props.defaultHighlightedIndex,inputValue:n.props.itemToString(o)},e)}),t)},n.toggleMenu=function(e,t){void 0===e&&(e={}),e=O(e),n.internalSetState((function(t){var o=t.isOpen;return r({isOpen:!o},o&&{highlightedIndex:n.props.defaultHighlightedIndex},{},e)}),(function(){var o=n.getState(),r=o.isOpen,i=o.highlightedIndex;r&&n.getItemCount()>0&&"number"==typeof i&&n.setHighlightedIndex(i,e),f(t)()}))},n.openMenu=function(e){n.internalSetState({isOpen:!0},e)},n.closeMenu=function(e){n.internalSetState({isOpen:!1},e)},n.updateStatus=y((function(){var e=n.getState(),t=n.items[e.highlightedIndex],o=n.getItemCount(),i=n.props.getA11yStatusMessage(r({itemToString:n.props.itemToString,previousResultCount:n.previousResultCount,resultCount:o,highlightedItem:t},e));n.previousResultCount=o,D(i,n.props.environment.document)}),200);var s=n.props,u=s.defaultHighlightedIndex,a=s.initialHighlightedIndex,l=void 0===a?u:a,p=s.defaultIsOpen,d=s.initialIsOpen,c=void 0===d?p:d,g=s.initialInputValue,m=void 0===g?"":g,v=s.initialSelectedItem,b=void 0===v?null:v,w=n.getState({highlightedIndex:l,isOpen:c,inputValue:m,selectedItem:b});return null!=w.selectedItem&&void 0===n.props.initialInputValue&&(w.inputValue=n.props.itemToString(w.selectedItem)),n.state=w,n}n=e,(t=s).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var u=s.prototype;return u.internalClearTimeouts=function(){this.timeoutIds.forEach((function(e){clearTimeout(e)})),this.timeoutIds=[]},u.getState=function(e){var t=this;return void 0===e&&(e=this.state),Object.keys(e).reduce((function(n,o){return n[o]=t.isControlledProp(o)?t.props[o]:e[o],n}),{})},u.isControlledProp=function(e){return void 0!==this.props[e]},u.getItemCount=function(){var e=this.items.length;return null!=this.itemCount?e=this.itemCount:void 0!==this.props.itemCount&&(e=this.props.itemCount),e},u.getItemNodeFromIndex=function(e){return this.props.environment.document.getElementById(this.getItemId(e))},u.scrollHighlightedItemIntoView=function(){var e=this.getItemNodeFromIndex(this.getState().highlightedIndex);this.props.scrollIntoView(e,this._menuNode)},u.moveHighlightedIndex=function(e,t){var n=this.getItemCount();if(n>0){var o=P(e,this.getState().highlightedIndex,n);this.setHighlightedIndex(o,t)}},u.highlightFirstOrLastIndex=function(e,t,n){var o=this.getItemCount()-1;o<0||!this.getState().isOpen||(e.preventDefault(),this.setHighlightedIndex(t?0:o,n))},u.getStateAndHelpers=function(){var e=this.getState(),t=e.highlightedIndex,n=e.inputValue,o=e.selectedItem,r=e.isOpen,i=this.props.itemToString,s=this.id,u=this.getRootProps,a=this.getToggleButtonProps,l=this.getLabelProps,p=this.getMenuProps,d=this.getInputProps,c=this.getItemProps,h=this.openMenu,f=this.closeMenu,g=this.toggleMenu,m=this.selectItem,v=this.selectItemAtIndex,y=this.selectHighlightedItem,I=this.setHighlightedIndex,S=this.clearSelection,b=this.clearItems;return{getRootProps:u,getToggleButtonProps:a,getLabelProps:l,getMenuProps:p,getInputProps:d,getItemProps:c,reset:this.reset,openMenu:h,closeMenu:f,toggleMenu:g,selectItem:m,selectItemAtIndex:v,selectHighlightedItem:y,setHighlightedIndex:I,clearSelection:S,clearItems:b,setItemCount:this.setItemCount,unsetItemCount:this.unsetItemCount,setState:this.internalSetState,itemToString:i,id:s,highlightedIndex:t,inputValue:n,isOpen:r,selectedItem:o}},u.componentDidMount=function(){var e=this;var t=function(t,n){void 0===n&&(n=!0);var o=e.props.environment.document;return[e._rootNode,e._menuNode].some((function(e){return e&&(v(e,t)||n&&v(e,o.activeElement))}))},n=function(){e.isMouseDown=!0},o=function(n){e.isMouseDown=!1,!t(n.target)&&e.getState().isOpen&&e.reset({type:1},(function(){return e.props.onOuterClick(e.getStateAndHelpers())}))},r=function(){e.isTouchMove=!1},i=function(){e.isTouchMove=!0},s=function(n){var o=t(n.target,!1);e.isTouchMove||o||!e.getState().isOpen||e.reset({type:16},(function(){return e.props.onOuterClick(e.getStateAndHelpers())}))},u=this.props.environment;u.addEventListener("mousedown",n),u.addEventListener("mouseup",o),u.addEventListener("touchstart",r),u.addEventListener("touchmove",i),u.addEventListener("touchend",s),this.cleanup=function(){e.internalClearTimeouts(),e.updateStatus.cancel(),u.removeEventListener("mousedown",n),u.removeEventListener("mouseup",o),u.removeEventListener("touchstart",r),u.removeEventListener("touchmove",i),u.removeEventListener("touchend",s)}},u.shouldScroll=function(e,t){var n=(void 0===this.props.highlightedIndex?this.getState():this.props).highlightedIndex,o=(void 0===t.highlightedIndex?e:t).highlightedIndex;return n&&this.getState().isOpen&&!e.isOpen||n!==o},u.componentDidUpdate=function(e,t){this.isControlledProp("selectedItem")&&this.props.selectedItemChanged(e.selectedItem,this.props.selectedItem)&&this.internalSetState({type:15,inputValue:this.props.itemToString(this.props.selectedItem)}),!this.avoidScrolling&&this.shouldScroll(t,e)&&this.scrollHighlightedItemIntoView(),this.updateStatus()},u.componentWillUnmount=function(){this.cleanup()},u.render=function(){var e=w(this.props.children,g);this.clearItems(),this.getRootProps.called=!1,this.getRootProps.refKey=void 0,this.getRootProps.suppressRefError=void 0,this.getMenuProps.called=!1,this.getMenuProps.refKey=void 0,this.getMenuProps.suppressRefError=void 0,this.getLabelProps.called=!1,this.getInputProps.called=!1;var t=w(e(this.getStateAndHelpers()));return t?this.getRootProps.called||this.props.suppressRefError?t:x(t)?Object(a.cloneElement)(t,this.getRootProps(C(t))):void 0:null},s}(a.Component);return e.defaultProps={defaultHighlightedIndex:null,defaultIsOpen:!1,getA11yStatusMessage:b,itemToString:function(e){return null==e?"":String(e)},onStateChange:g,onInputValueChange:g,onUserAction:g,onChange:g,onSelect:g,onOuterClick:g,selectedItemChanged:function(e,t){return e!==t},environment:"undefined"==typeof window?{}:window,stateReducer:function(e,t){return t},suppressRefError:!1,scrollIntoView:m},e.stateChangeTypes=k,e}();u.a.array.isRequired,u.a.func,u.a.func,u.a.func,u.a.bool,u.a.number,u.a.number,u.a.number,u.a.bool,u.a.bool,u.a.bool,u.a.any,u.a.any,u.a.any,u.a.string,u.a.string,u.a.string,u.a.func,u.a.string,u.a.func,u.a.func,u.a.func,u.a.func,u.a.func,u.a.shape({addEventListener:u.a.func,removeEventListener:u.a.func,document:u.a.shape({getElementById:u.a.func,activeElement:u.a.any,body:u.a.any})});"undefined"==typeof window||window;t.a=R}]]);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
framework/extensions/newsletter-subscribe/admin-static/bundle/2.b8cdca0a643ec9bd1ed2.js
DELETED
@@ -1 +0,0 @@
|
|
1 |
-
(window.blocksyNewsletterSubscribeExtJsonp=window.blocksyNewsletterSubscribeExtJsonp||[]).push([[2],{13:function(e,t,n){"use strict";n.r(t);var r=n(0),a=n(12),c=n(2),o=n(6),i=n.n(o);function u(){return(u=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function s(e,t,n,r,a,c,o){try{var i=e[c](o),u=i.value}catch(e){return void n(e)}i.done?t(u):Promise.resolve(u).then(r,a)}function l(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,a=!1,c=void 0;try{for(var o,i=e[Symbol.iterator]();!(r=(o=i.next()).done)&&(n.push(o.value),!t||n.length!==t);r=!0);}catch(e){a=!0,c=e}finally{try{r||null==i.return||i.return()}finally{if(a)throw c}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return f(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return f(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function f(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var d=null;t.default=function(e){var t=e.value,n=e.onChange,o=l(Object(r.useState)(d||[]),2),f=o[0],p=o[1],b=l(Object(r.useState)(!d),2),m=b[0],v=b[1],y=function(){var e,t=(e=regeneratorRuntime.mark((function e(){var t,n,r,a=arguments;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return(!(a.length>0&&void 0!==a[0])||a[0])&&v(!0),(t=new FormData).append("action","blocksy_ext_newsletter_subscribe_get_actual_lists"),e.prev=4,e.next=7,fetch(ajaxurl,{method:"POST",body:t});case 7:if(200!==(n=e.sent).status){e.next=18;break}return e.next=11,n.json();case 11:if(!(r=e.sent).success){e.next=18;break}if("api_key_invalid"===r.data.result){e.next=18;break}return v(!1),p(r.data.result),d=r.data.result,e.abrupt("return");case 18:e.next=22;break;case 20:e.prev=20,e.t0=e.catch(4);case 22:v(!1);case 23:case"end":return e.stop()}}),e,null,[[4,20]])})),function(){var t=this,n=arguments;return new Promise((function(r,a){var c=e.apply(t,n);function o(e){s(c,r,a,o,i,"next",e)}function i(e){s(c,r,a,o,i,"throw",e)}o(void 0)}))});return function(){return t.apply(this,arguments)}}();return Object(r.useEffect)((function(){y(!d)}),[]),0===f.length?Object(r.createElement)("div",{className:"ct-select-input"},Object(r.createElement)("input",{disabled:!0,placeholder:m?Object(c.__)("Loading...","blocksy-companion"):Object(c.__)("Invalid API Key...","blocksy-companion")})):Object(r.createElement)(a.a,{selectedItem:t||f[0].id,onChange:function(e){return n(e)},itemToString:function(e){return e?(f.find((function(t){return t.id===e}))||{}).name:""}},(function(e){var t=e.getInputProps,n=e.getItemProps,a=(e.getLabelProps,e.getMenuProps),o=e.isOpen,s=(e.inputValue,e.highlightedIndex),l=e.selectedItem,d=e.openMenu;return Object(r.createElement)("div",{className:"ct-select-input"},Object(r.createElement)("input",u({},t({onFocus:function(){return d()},onClick:function(){return d()}}),{placeholder:Object(c.__)("Select list...","blocksy-companion"),readOnly:!0})),o&&Object(r.createElement)("div",a({className:"ct-select-dropdown"}),f.map((function(e,t){return Object(r.createElement)("div",n({key:e.id,index:t,item:e.id,className:i()("ct-select-dropdown-item",{active:s===t,selected:l===e.id})}),e.name)}))))}))}}}]);
|
|
framework/extensions/newsletter-subscribe/admin-static/bundle/486.2f466d7115021070874d.js
ADDED
@@ -0,0 +1,2 @@
|
|
|
|
|
1 |
+
/*! For license information please see 486.2f466d7115021070874d.js.LICENSE.txt */
|
2 |
+
(globalThis.blocksyNewsletterSubscribeExtJsonp=globalThis.blocksyNewsletterSubscribeExtJsonp||[]).push([[486],{184:(e,t)=>{var n;!function(){"use strict";var o={}.hasOwnProperty;function r(){for(var e=[],t=0;t<arguments.length;t++){var n=arguments[t];if(n){var i=typeof n;if("string"===i||"number"===i)e.push(n);else if(Array.isArray(n)&&n.length){var s=r.apply(null,n);s&&e.push(s)}else if("object"===i)for(var u in n)o.call(n,u)&&n[u]&&e.push(u)}}return e.join(" ")}e.exports?(r.default=r,e.exports=r):void 0===(n=function(){return r}.apply(t,[]))||(e.exports=n)}()},380:(e,t,n)=>{"use strict";function o(e,t){if(null==e)return{};var n,o,r={},i=Object.keys(e);for(o=0;o<i.length;o++)n=i[o],t.indexOf(n)>=0||(r[n]=e[n]);return r}function r(){return r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o])}return e},r.apply(this,arguments)}function i(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}n.d(t,{ZP:()=>T});var s=n(697),u=n.n(s),l=n(313);function a(e){return null!=e&&"object"==typeof e&&1===e.nodeType}function p(e,t){return(!t||"hidden"!==e)&&"visible"!==e&&"clip"!==e}function d(e,t){if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){var n=getComputedStyle(e,null);return p(n.overflowY,t)||p(n.overflowX,t)||function(e){var t=function(e){return e.ownerDocument&&e.ownerDocument.defaultView?e.ownerDocument.defaultView.frameElement:null}(e);return!!t&&(t.clientHeight<e.scrollHeight||t.clientWidth<e.scrollWidth)}(e)}return!1}function c(e,t,n,o,r,i,s,u){return i<e&&s>t||i>e&&s<t?0:i<=e&&u<=n||s>=t&&u>=n?i-e-o:s>t&&u<n||i<e&&u>n?s-t+r:0}n(864);var h=0;function f(e){return"function"==typeof e?e:g}function g(){}function m(e,t){if(null!==e){var n=function(e,t){var n=t.scrollMode,o=t.block,r=t.inline,i=t.boundary,s=t.skipOverflowHiddenElements,u="function"==typeof i?i:function(e){return e!==i};if(!a(e))throw new TypeError("Invalid target");for(var l=document.scrollingElement||document.documentElement,p=[],h=e;a(h)&&u(h);){if((h=h.parentNode)===l){p.push(h);break}h===document.body&&d(h)&&!d(document.documentElement)||d(h,s)&&p.push(h)}for(var f=window.visualViewport?visualViewport.width:innerWidth,g=window.visualViewport?visualViewport.height:innerHeight,m=window.scrollX||pageXOffset,v=window.scrollY||pageYOffset,I=e.getBoundingClientRect(),y=I.height,b=I.width,S=I.top,w=I.right,x=I.bottom,C=I.left,H="start"===o||"nearest"===o?S:"end"===o?x:S+y/2,O="center"===r?C+b/2:"end"===r?w:C,E=[],P=0;P<p.length;P++){var D=p[P],M=D.getBoundingClientRect(),T=M.height,k=M.width,R=M.top,A=M.right,V=M.bottom,K=M.left;if("if-needed"===n&&S>=0&&C>=0&&x<=g&&w<=f&&S>=R&&x<=V&&C>=K&&w<=A)return E;var _=getComputedStyle(D),L=parseInt(_.borderLeftWidth,10),B=parseInt(_.borderTopWidth,10),W=parseInt(_.borderRightWidth,10),N=parseInt(_.borderBottomWidth,10),U=0,j=0,F="offsetWidth"in D?D.offsetWidth-D.clientWidth-L-W:0,Y="offsetHeight"in D?D.offsetHeight-D.clientHeight-B-N:0;if(l===D)U="start"===o?H:"end"===o?H-g:"nearest"===o?c(v,v+g,g,B,N,v+H,v+H+y,y):H-g/2,j="start"===r?O:"center"===r?O-f/2:"end"===r?O-f:c(m,m+f,f,L,W,m+O,m+O+b,b),U=Math.max(0,U+v),j=Math.max(0,j+m);else{U="start"===o?H-R-B:"end"===o?H-V+N+Y:"nearest"===o?c(R,V,T,B,N+Y,H,H+y,y):H-(R+T/2)+Y/2,j="start"===r?O-K-L:"center"===r?O-(K+k/2)+F/2:"end"===r?O-A+W+F:c(K,A,k,L,W+F,O,O+b,b);var X=D.scrollLeft,q=D.scrollTop;H+=q-(U=Math.max(0,Math.min(q+U,D.scrollHeight-T+Y))),O+=X-(j=Math.max(0,Math.min(X+j,D.scrollWidth-k+F)))}E.push({el:D,top:U,left:j})}return E}(e,{boundary:t,block:"nearest",scrollMode:"if-needed"});n.forEach((function(e){var t=e.el,n=e.top,o=e.left;t.scrollTop=n,t.scrollLeft=o}))}}function v(e,t){return e===t||e.contains&&e.contains(t)}function I(e,t){var n;function o(){n&&clearTimeout(n)}function r(){for(var r=arguments.length,i=new Array(r),s=0;s<r;s++)i[s]=arguments[s];o(),n=setTimeout((function(){n=null,e.apply(void 0,i)}),t)}return r.cancel=o,r}function y(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){for(var n=arguments.length,o=new Array(n>1?n-1:0),r=1;r<n;r++)o[r-1]=arguments[r];return t.some((function(t){return t&&t.apply(void 0,[e].concat(o)),e.preventDownshiftDefault||e.hasOwnProperty("nativeEvent")&&e.nativeEvent.preventDownshiftDefault}))}}function b(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){t.forEach((function(t){"function"==typeof t?t(e):t&&(t.current=e)}))}}function S(e){var t=e.isOpen,n=e.selectedItem,o=e.resultCount,r=e.previousResultCount,i=e.itemToString;return t?o?o!==r?o+" result"+(1===o?" is":"s are")+" available, use up and down arrow keys to navigate. Press Enter key to select.":"":"No results are available.":n?i(n):""}function w(e,t){return!(e=Array.isArray(e)?e[0]:e)&&t?t:e}var x=["highlightedIndex","inputValue","isOpen","selectedItem","type"];function C(e){void 0===e&&(e={});var t={};return x.forEach((function(n){e.hasOwnProperty(n)&&(t[n]=e[n])})),t}function H(e){var t=e.key,n=e.keyCode;return n>=37&&n<=40&&0!==t.indexOf("Arrow")?"Arrow"+t:t}function O(e,t,n){var o=n-1;("number"!=typeof t||t<0||t>=n)&&(t=e>0?-1:o+1);var r=t+e;return r<0?r=o:r>o&&(r=0),r}var E=I((function(){P().textContent=""}),500);function P(e){void 0===e&&(e=document);var t=e.getElementById("a11y-status-message");return t||((t=e.createElement("div")).setAttribute("id","a11y-status-message"),t.setAttribute("role","status"),t.setAttribute("aria-live","polite"),t.setAttribute("aria-relevant","additions text"),Object.assign(t.style,{border:"0",clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:"0",position:"absolute",width:"1px"}),e.body.appendChild(t),t)}var D=Object.freeze({__proto__:null,unknown:0,mouseUp:1,itemMouseEnter:2,keyDownArrowUp:3,keyDownArrowDown:4,keyDownEscape:5,keyDownEnter:6,keyDownHome:7,keyDownEnd:8,clickItem:9,blurInput:10,changeInput:11,keyDownSpaceButton:12,clickButton:13,blurButton:14,controlledPropUpdatedSelectedItem:15,touchEnd:16}),M=function(){var e=function(e){var t,n;function s(t){var n=e.call(this,t)||this;n.id=n.props.id||"downshift-"+String(h++),n.menuId=n.props.menuId||n.id+"-menu",n.labelId=n.props.labelId||n.id+"-label",n.inputId=n.props.inputId||n.id+"-input",n.getItemId=n.props.getItemId||function(e){return n.id+"-item-"+e},n.input=null,n.items=[],n.itemCount=null,n.previousResultCount=0,n.timeoutIds=[],n.internalSetTimeout=function(e,t){var o=setTimeout((function(){n.timeoutIds=n.timeoutIds.filter((function(e){return e!==o})),e()}),t);n.timeoutIds.push(o)},n.setItemCount=function(e){n.itemCount=e},n.unsetItemCount=function(){n.itemCount=null},n.setHighlightedIndex=function(e,t){void 0===e&&(e=n.props.defaultHighlightedIndex),void 0===t&&(t={}),t=C(t),n.internalSetState(r({highlightedIndex:e},t))},n.clearSelection=function(e){n.internalSetState({selectedItem:null,inputValue:"",highlightedIndex:n.props.defaultHighlightedIndex,isOpen:n.props.defaultIsOpen},e)},n.selectItem=function(e,t,o){t=C(t),n.internalSetState(r({isOpen:n.props.defaultIsOpen,highlightedIndex:n.props.defaultHighlightedIndex,selectedItem:e,inputValue:n.props.itemToString(e)},t),o)},n.selectItemAtIndex=function(e,t,o){var r=n.items[e];null!=r&&n.selectItem(r,t,o)},n.selectHighlightedItem=function(e,t){return n.selectItemAtIndex(n.getState().highlightedIndex,e,t)},n.internalSetState=function(e,t){var o,i,s={},u="function"==typeof e;return!u&&e.hasOwnProperty("inputValue")&&n.props.onInputValueChange(e.inputValue,r({},n.getStateAndHelpers(),{},e)),n.setState((function(t){t=n.getState(t);var l=u?e(t):e;l=n.props.stateReducer(t,l),o=l.hasOwnProperty("selectedItem");var a={},p={};return o&&l.selectedItem!==t.selectedItem&&(i=l.selectedItem),l.type=l.type||0,Object.keys(l).forEach((function(e){t[e]!==l[e]&&(s[e]=l[e]),"type"!==e&&(p[e]=l[e],n.isControlledProp(e)||(a[e]=l[e]))})),u&&l.hasOwnProperty("inputValue")&&n.props.onInputValueChange(l.inputValue,r({},n.getStateAndHelpers(),{},l)),a}),(function(){f(t)(),Object.keys(s).length>1&&n.props.onStateChange(s,n.getStateAndHelpers()),o&&n.props.onSelect(e.selectedItem,n.getStateAndHelpers()),void 0!==i&&n.props.onChange(i,n.getStateAndHelpers()),n.props.onUserAction(s,n.getStateAndHelpers())}))},n.rootRef=function(e){return n._rootNode=e},n.getRootProps=function(e,t){var i,s=void 0===e?{}:e,u=s.refKey,l=void 0===u?"ref":u,a=s.ref,p=o(s,["refKey","ref"]),d=(void 0===t?{}:t).suppressRefError,c=void 0!==d&&d;n.getRootProps.called=!0,n.getRootProps.refKey=l,n.getRootProps.suppressRefError=c;var h=n.getState().isOpen;return r(((i={})[l]=b(a,n.rootRef),i.role="combobox",i["aria-expanded"]=h,i["aria-haspopup"]="listbox",i["aria-owns"]=h?n.menuId:null,i["aria-labelledby"]=n.labelId,i),p)},n.keyDownHandlers={ArrowDown:function(e){var t=this;if(e.preventDefault(),this.getState().isOpen){var n=e.shiftKey?5:1;this.moveHighlightedIndex(n,{type:4})}else this.internalSetState({isOpen:!0,type:4},(function(){var e=t.getItemCount();e>0&&t.setHighlightedIndex(O(1,t.getState().highlightedIndex,e),{type:4})}))},ArrowUp:function(e){var t=this;if(e.preventDefault(),this.getState().isOpen){var n=e.shiftKey?-5:-1;this.moveHighlightedIndex(n,{type:3})}else this.internalSetState({isOpen:!0,type:3},(function(){var e=t.getItemCount();e>0&&t.setHighlightedIndex(O(-1,t.getState().highlightedIndex,e),{type:4})}))},Enter:function(e){var t=this.getState(),n=t.isOpen,o=t.highlightedIndex;if(n&&null!=o){e.preventDefault();var r=this.items[o],i=this.getItemNodeFromIndex(o);if(null==r||i&&i.hasAttribute("disabled"))return;this.selectHighlightedItem({type:6})}},Escape:function(e){e.preventDefault(),this.reset({type:5,selectedItem:null,inputValue:""})}},n.buttonKeyDownHandlers=r({},n.keyDownHandlers,{" ":function(e){e.preventDefault(),this.toggleMenu({type:12})}}),n.inputKeyDownHandlers=r({},n.keyDownHandlers,{Home:function(e){this.highlightFirstOrLastIndex(e,!0,{type:7})},End:function(e){this.highlightFirstOrLastIndex(e,!1,{type:8})}}),n.getToggleButtonProps=function(e){var t=void 0===e?{}:e,i=t.onClick,s=(t.onPress,t.onKeyDown),u=t.onKeyUp,l=t.onBlur,a=o(t,["onClick","onPress","onKeyDown","onKeyUp","onBlur"]),p=n.getState().isOpen,d={onClick:y(i,n.buttonHandleClick),onKeyDown:y(s,n.buttonHandleKeyDown),onKeyUp:y(u,n.buttonHandleKeyUp),onBlur:y(l,n.buttonHandleBlur)};return r({type:"button",role:"button","aria-label":p?"close menu":"open menu","aria-haspopup":!0,"data-toggle":!0},a.disabled?{}:d,{},a)},n.buttonHandleKeyUp=function(e){e.preventDefault()},n.buttonHandleKeyDown=function(e){var t=H(e);n.buttonKeyDownHandlers[t]&&n.buttonKeyDownHandlers[t].call(i(n),e)},n.buttonHandleClick=function(e){e.preventDefault(),n.props.environment.document.activeElement===n.props.environment.document.body&&e.target.focus(),n.internalSetTimeout((function(){return n.toggleMenu({type:13})}))},n.buttonHandleBlur=function(e){var t=e.target;n.internalSetTimeout((function(){n.isMouseDown||null!=n.props.environment.document.activeElement&&n.props.environment.document.activeElement.id===n.inputId||n.props.environment.document.activeElement===t||n.reset({type:14})}))},n.getLabelProps=function(e){return r({htmlFor:n.inputId,id:n.labelId},e)},n.getInputProps=function(e){var t,i=void 0===e?{}:e,s=i.onKeyDown,u=i.onBlur,l=i.onChange,a=i.onInput,p=(i.onChangeText,o(i,["onKeyDown","onBlur","onChange","onInput","onChangeText"])),d={},c=n.getState(),h=c.inputValue,f=c.isOpen,g=c.highlightedIndex;return p.disabled||((t={}).onChange=y(l,a,n.inputHandleChange),t.onKeyDown=y(s,n.inputHandleKeyDown),t.onBlur=y(u,n.inputHandleBlur),d=t),r({"aria-autocomplete":"list","aria-activedescendant":f&&"number"==typeof g&&g>=0?n.getItemId(g):null,"aria-controls":f?n.menuId:null,"aria-labelledby":n.labelId,autoComplete:"off",value:h,id:n.inputId},d,{},p)},n.inputHandleKeyDown=function(e){var t=H(e);t&&n.inputKeyDownHandlers[t]&&n.inputKeyDownHandlers[t].call(i(n),e)},n.inputHandleChange=function(e){n.internalSetState({type:11,isOpen:!0,inputValue:e.target.value,highlightedIndex:n.props.defaultHighlightedIndex})},n.inputHandleBlur=function(){n.internalSetTimeout((function(){var e=n.props.environment.document&&!!n.props.environment.document.activeElement&&!!n.props.environment.document.activeElement.dataset&&n.props.environment.document.activeElement.dataset.toggle&&n._rootNode&&n._rootNode.contains(n.props.environment.document.activeElement);n.isMouseDown||e||n.reset({type:10})}))},n.menuRef=function(e){n._menuNode=e},n.getMenuProps=function(e,t){var i,s=void 0===e?{}:e,u=s.refKey,l=void 0===u?"ref":u,a=s.ref,p=o(s,["refKey","ref"]),d=(void 0===t?{}:t).suppressRefError,c=void 0!==d&&d;return n.getMenuProps.called=!0,n.getMenuProps.refKey=l,n.getMenuProps.suppressRefError=c,r(((i={})[l]=b(a,n.menuRef),i.role="listbox",i["aria-labelledby"]=p&&p["aria-label"]?null:n.labelId,i.id=n.menuId,i),p)},n.getItemProps=function(e){var t,i=void 0===e?{}:e,s=i.onMouseMove,u=i.onMouseDown,l=i.onClick,a=(i.onPress,i.index),p=i.item,d=void 0===p?void 0:p,c=o(i,["onMouseMove","onMouseDown","onClick","onPress","index","item"]);void 0===a?(n.items.push(d),a=n.items.indexOf(d)):n.items[a]=d;var h=l,f=((t={onMouseMove:y(s,(function(){a!==n.getState().highlightedIndex&&(n.setHighlightedIndex(a,{type:2}),n.avoidScrolling=!0,n.internalSetTimeout((function(){return n.avoidScrolling=!1}),250))})),onMouseDown:y(u,(function(e){e.preventDefault()}))}).onClick=y(h,(function(){n.selectItemAtIndex(a,{type:9})})),t),g=c.disabled?{onMouseDown:f.onMouseDown}:f;return r({id:n.getItemId(a),role:"option","aria-selected":n.getState().highlightedIndex===a},g,{},c)},n.clearItems=function(){n.items=[]},n.reset=function(e,t){void 0===e&&(e={}),e=C(e),n.internalSetState((function(t){var o=t.selectedItem;return r({isOpen:n.props.defaultIsOpen,highlightedIndex:n.props.defaultHighlightedIndex,inputValue:n.props.itemToString(o)},e)}),t)},n.toggleMenu=function(e,t){void 0===e&&(e={}),e=C(e),n.internalSetState((function(t){var o=t.isOpen;return r({isOpen:!o},o&&{highlightedIndex:n.props.defaultHighlightedIndex},{},e)}),(function(){var o=n.getState(),r=o.isOpen,i=o.highlightedIndex;r&&n.getItemCount()>0&&"number"==typeof i&&n.setHighlightedIndex(i,e),f(t)()}))},n.openMenu=function(e){n.internalSetState({isOpen:!0},e)},n.closeMenu=function(e){n.internalSetState({isOpen:!1},e)},n.updateStatus=I((function(){var e=n.getState(),t=n.items[e.highlightedIndex],o=n.getItemCount(),i=n.props.getA11yStatusMessage(r({itemToString:n.props.itemToString,previousResultCount:n.previousResultCount,resultCount:o,highlightedItem:t},e));n.previousResultCount=o,function(e,t){var n=P(t);e&&(n.textContent=e,E())}(i,n.props.environment.document)}),200);var s=n.props,u=s.defaultHighlightedIndex,l=s.initialHighlightedIndex,a=void 0===l?u:l,p=s.defaultIsOpen,d=s.initialIsOpen,c=void 0===d?p:d,g=s.initialInputValue,m=void 0===g?"":g,v=s.initialSelectedItem,S=void 0===v?null:v,w=n.getState({highlightedIndex:a,isOpen:c,inputValue:m,selectedItem:S});return null!=w.selectedItem&&void 0===n.props.initialInputValue&&(w.inputValue=n.props.itemToString(w.selectedItem)),n.state=w,n}n=e,(t=s).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var u=s.prototype;return u.internalClearTimeouts=function(){this.timeoutIds.forEach((function(e){clearTimeout(e)})),this.timeoutIds=[]},u.getState=function(e){var t=this;return void 0===e&&(e=this.state),Object.keys(e).reduce((function(n,o){return n[o]=t.isControlledProp(o)?t.props[o]:e[o],n}),{})},u.isControlledProp=function(e){return void 0!==this.props[e]},u.getItemCount=function(){var e=this.items.length;return null!=this.itemCount?e=this.itemCount:void 0!==this.props.itemCount&&(e=this.props.itemCount),e},u.getItemNodeFromIndex=function(e){return this.props.environment.document.getElementById(this.getItemId(e))},u.scrollHighlightedItemIntoView=function(){var e=this.getItemNodeFromIndex(this.getState().highlightedIndex);this.props.scrollIntoView(e,this._menuNode)},u.moveHighlightedIndex=function(e,t){var n=this.getItemCount();if(n>0){var o=O(e,this.getState().highlightedIndex,n);this.setHighlightedIndex(o,t)}},u.highlightFirstOrLastIndex=function(e,t,n){var o=this.getItemCount()-1;o<0||!this.getState().isOpen||(e.preventDefault(),this.setHighlightedIndex(t?0:o,n))},u.getStateAndHelpers=function(){var e=this.getState(),t=e.highlightedIndex,n=e.inputValue,o=e.selectedItem,r=e.isOpen,i=this.props.itemToString,s=this.id,u=this.getRootProps,l=this.getToggleButtonProps,a=this.getLabelProps,p=this.getMenuProps,d=this.getInputProps,c=this.getItemProps,h=this.openMenu,f=this.closeMenu,g=this.toggleMenu,m=this.selectItem,v=this.selectItemAtIndex,I=this.selectHighlightedItem,y=this.setHighlightedIndex,b=this.clearSelection,S=this.clearItems;return{getRootProps:u,getToggleButtonProps:l,getLabelProps:a,getMenuProps:p,getInputProps:d,getItemProps:c,reset:this.reset,openMenu:h,closeMenu:f,toggleMenu:g,selectItem:m,selectItemAtIndex:v,selectHighlightedItem:I,setHighlightedIndex:y,clearSelection:b,clearItems:S,setItemCount:this.setItemCount,unsetItemCount:this.unsetItemCount,setState:this.internalSetState,itemToString:i,id:s,highlightedIndex:t,inputValue:n,isOpen:r,selectedItem:o}},u.componentDidMount=function(){var e=this,t=function(t,n){void 0===n&&(n=!0);var o=e.props.environment.document;return[e._rootNode,e._menuNode].some((function(e){return e&&(v(e,t)||n&&v(e,o.activeElement))}))},n=function(){e.isMouseDown=!0},o=function(n){e.isMouseDown=!1,!t(n.target)&&e.getState().isOpen&&e.reset({type:1},(function(){return e.props.onOuterClick(e.getStateAndHelpers())}))},r=function(){e.isTouchMove=!1},i=function(){e.isTouchMove=!0},s=function(n){var o=t(n.target,!1);e.isTouchMove||o||!e.getState().isOpen||e.reset({type:16},(function(){return e.props.onOuterClick(e.getStateAndHelpers())}))},u=this.props.environment;u.addEventListener("mousedown",n),u.addEventListener("mouseup",o),u.addEventListener("touchstart",r),u.addEventListener("touchmove",i),u.addEventListener("touchend",s),this.cleanup=function(){e.internalClearTimeouts(),e.updateStatus.cancel(),u.removeEventListener("mousedown",n),u.removeEventListener("mouseup",o),u.removeEventListener("touchstart",r),u.removeEventListener("touchmove",i),u.removeEventListener("touchend",s)}},u.shouldScroll=function(e,t){var n=(void 0===this.props.highlightedIndex?this.getState():this.props).highlightedIndex,o=(void 0===t.highlightedIndex?e:t).highlightedIndex;return n&&this.getState().isOpen&&!e.isOpen||n!==o},u.componentDidUpdate=function(e,t){this.isControlledProp("selectedItem")&&this.props.selectedItemChanged(e.selectedItem,this.props.selectedItem)&&this.internalSetState({type:15,inputValue:this.props.itemToString(this.props.selectedItem)}),!this.avoidScrolling&&this.shouldScroll(t,e)&&this.scrollHighlightedItemIntoView(),this.updateStatus()},u.componentWillUnmount=function(){this.cleanup()},u.render=function(){var e=w(this.props.children,g);this.clearItems(),this.getRootProps.called=!1,this.getRootProps.refKey=void 0,this.getRootProps.suppressRefError=void 0,this.getMenuProps.called=!1,this.getMenuProps.refKey=void 0,this.getMenuProps.suppressRefError=void 0,this.getLabelProps.called=!1,this.getInputProps.called=!1;var t=w(e(this.getStateAndHelpers()));return t?this.getRootProps.called||this.props.suppressRefError?t:function(e){return"string"==typeof e.type}(t)?(0,l.cloneElement)(t,this.getRootProps(function(e){return e.props}(t))):void 0:null},s}(l.Component);return e.defaultProps={defaultHighlightedIndex:null,defaultIsOpen:!1,getA11yStatusMessage:S,itemToString:function(e){return null==e?"":String(e)},onStateChange:g,onInputValueChange:g,onUserAction:g,onChange:g,onSelect:g,onOuterClick:g,selectedItemChanged:function(e,t){return e!==t},environment:"undefined"==typeof window?{}:window,stateReducer:function(e,t){return t},suppressRefError:!1,scrollIntoView:m},e.stateChangeTypes=D,e}();u().array.isRequired,u().func,u().func,u().func,u().bool,u().number,u().number,u().number,u().bool,u().bool,u().bool,u().any,u().any,u().any,u().string,u().string,u().string,u().func,u().string,u().func,u().func,u().func,u().func,u().func,u().shape({addEventListener:u().func,removeEventListener:u().func,document:u().shape({getElementById:u().func,activeElement:u().any,body:u().any})}),"undefined"==typeof window||window;const T=M},703:(e,t,n)=>{"use strict";var o=n(414);function r(){}function i(){}i.resetWarningCache=r,e.exports=function(){function e(e,t,n,r,i,s){if(s!==o){var u=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 u.name="Invariant Violation",u}}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:i,resetWarningCache:r};return n.PropTypes=n,n}},697:(e,t,n)=>{e.exports=n(703)()},414:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},921:(e,t)=>{"use strict";var n="function"==typeof Symbol&&Symbol.for;n&&Symbol.for("react.element"),n&&Symbol.for("react.portal"),n&&Symbol.for("react.fragment"),n&&Symbol.for("react.strict_mode"),n&&Symbol.for("react.profiler"),n&&Symbol.for("react.provider"),n&&Symbol.for("react.context"),n&&Symbol.for("react.async_mode"),n&&Symbol.for("react.concurrent_mode"),n&&Symbol.for("react.forward_ref"),n&&Symbol.for("react.suspense"),n&&Symbol.for("react.suspense_list"),n&&Symbol.for("react.memo"),n&&Symbol.for("react.lazy"),n&&Symbol.for("react.block"),n&&Symbol.for("react.fundamental"),n&&Symbol.for("react.responder"),n&&Symbol.for("react.scope")},864:(e,t,n)=>{"use strict";n(921)}}]);
|
framework/extensions/newsletter-subscribe/admin-static/bundle/486.2f466d7115021070874d.js.LICENSE.txt
ADDED
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/*!
|
2 |
+
Copyright (c) 2017 Jed Watson.
|
3 |
+
Licensed under the MIT License (MIT), see
|
4 |
+
http://jedwatson.github.io/classnames
|
5 |
+
*/
|
6 |
+
|
7 |
+
/** @license React v16.13.1
|
8 |
+
* react-is.production.min.js
|
9 |
+
*
|
10 |
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
11 |
+
*
|
12 |
+
* This source code is licensed under the MIT license found in the
|
13 |
+
* LICENSE file in the root directory of this source tree.
|
14 |
+
*/
|
framework/extensions/newsletter-subscribe/admin-static/bundle/677.6d4bfe6dc9293cdd7f96.js
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
"use strict";(globalThis.blocksyNewsletterSubscribeExtJsonp=globalThis.blocksyNewsletterSubscribeExtJsonp||[]).push([[677],{677:(e,t,n)=>{n.r(t),n.d(t,{default:()=>p});var r=n(381),a=n(380),o=n(652),i=n(184),c=n.n(i);function u(){return u=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},u.apply(this,arguments)}function s(e,t,n,r,a,o,i){try{var c=e[o](i),u=c.value}catch(e){return void n(e)}c.done?t(u):Promise.resolve(u).then(r,a)}function l(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,a=!1,o=void 0;try{for(var i,c=e[Symbol.iterator]();!(r=(i=c.next()).done)&&(n.push(i.value),!t||n.length!==t);r=!0);}catch(e){a=!0,o=e}finally{try{r||null==c.return||c.return()}finally{if(a)throw o}}return n}}(e,t)||function(e,t){if(e){if("string"==typeof e)return d(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?d(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function d(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var f=null;const p=function(e){var t=e.value,n=e.onChange,i=l((0,r.useState)(f||[]),2),d=i[0],p=i[1],m=l((0,r.useState)(!f),2),v=m[0],b=m[1],y=function(){var e,t=(e=regeneratorRuntime.mark((function e(){var t,n,r,a=arguments;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return(!(a.length>0&&void 0!==a[0])||a[0])&&b(!0),(t=new FormData).append("action","blocksy_ext_newsletter_subscribe_get_actual_lists"),e.prev=4,e.next=7,fetch(ajaxurl,{method:"POST",body:t});case 7:if(200!==(n=e.sent).status){e.next=18;break}return e.next=11,n.json();case 11:if(!(r=e.sent).success){e.next=18;break}if("api_key_invalid"===r.data.result){e.next=18;break}return b(!1),p(r.data.result),f=r.data.result,e.abrupt("return");case 18:e.next=22;break;case 20:e.prev=20,e.t0=e.catch(4);case 22:b(!1);case 23:case"end":return e.stop()}}),e,null,[[4,20]])})),function(){var t=this,n=arguments;return new Promise((function(r,a){var o=e.apply(t,n);function i(e){s(o,r,a,i,c,"next",e)}function c(e){s(o,r,a,i,c,"throw",e)}i(void 0)}))});return function(){return t.apply(this,arguments)}}();return(0,r.useEffect)((function(){y(!f)}),[]),0===d.length?(0,r.createElement)("div",{className:"ct-select-input"},(0,r.createElement)("input",{disabled:!0,placeholder:v?(0,o.__)("Loading...","blocksy-companion"):(0,o.__)("Invalid API Key...","blocksy-companion")})):(0,r.createElement)(a.ZP,{selectedItem:t||d[0].id,onChange:function(e){return n(e)},itemToString:function(e){return e?(d.find((function(t){return t.id===e}))||{}).name:""}},(function(e){var t=e.getInputProps,n=e.getItemProps,a=(e.getLabelProps,e.getMenuProps),i=e.isOpen,s=(e.inputValue,e.highlightedIndex),l=e.selectedItem,f=e.openMenu;return(0,r.createElement)("div",{className:"ct-select-input"},(0,r.createElement)("input",u({},t({onFocus:function(){return f()},onClick:function(){return f()}}),{placeholder:(0,o.__)("Select list...","blocksy-companion"),readOnly:!0})),i&&(0,r.createElement)("div",a({className:"ct-select-dropdown"}),d.map((function(e,t){return(0,r.createElement)("div",n({key:e.id,index:t,item:e.id,className:c()("ct-select-dropdown-item",{active:s===t,selected:l===e.id})}),e.name)}))))}))}}}]);
|
framework/extensions/newsletter-subscribe/admin-static/bundle/main.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
|
1 |
+
(()=>{var e,t,r={466:(e,t,r)=>{r.p=blocksy_ext_newsletter_subscribe_localization.public_url},313:e=>{"use strict";e.exports=window.React},381:e=>{"use strict";e.exports=window.wp.element},652:e=>{"use strict";e.exports=window.wp.i18n}},n={};function o(e){var t=n[e];if(void 0!==t)return t.exports;var i=n[e]={exports:{}};return r[e](i,i.exports,o),i.exports}o.m=r,o.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return o.d(t,{a:t}),t},o.d=(e,t)=>{for(var r in t)o.o(t,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},o.f={},o.e=e=>Promise.all(Object.keys(o.f).reduce(((t,r)=>(o.f[r](e,t),t)),[])),o.u=e=>e+"."+{486:"2f466d7115021070874d",677:"6d4bfe6dc9293cdd7f96"}[e]+".js",o.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),e={},t="blocksy-companion:",o.l=(r,n,i,a)=>{if(e[r])e[r].push(n);else{var l,s;if(void 0!==i)for(var c=document.getElementsByTagName("script"),u=0;u<c.length;u++){var d=c[u];if(d.getAttribute("src")==r||d.getAttribute("data-webpack")==t+i){l=d;break}}l||(s=!0,(l=document.createElement("script")).charset="utf-8",l.timeout=120,o.nc&&l.setAttribute("nonce",o.nc),l.setAttribute("data-webpack",t+i),l.src=r),e[r]=[n];var p=(t,n)=>{l.onerror=l.onload=null,clearTimeout(b);var o=e[r];if(delete e[r],l.parentNode&&l.parentNode.removeChild(l),o&&o.forEach((e=>e(n))),t)return t(n)},b=setTimeout(p.bind(null,void 0,{type:"timeout",target:l}),12e4);l.onerror=p.bind(null,l.onerror),l.onload=p.bind(null,l.onload),s&&document.head.appendChild(l)}},o.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{var e;o.g.importScripts&&(e=o.g.location+"");var t=o.g.document;if(!e&&t&&(t.currentScript&&(e=t.currentScript.src),!e)){var r=t.getElementsByTagName("script");r.length&&(e=r[r.length-1].src)}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),o.p=e})(),(()=>{var e={179:0};o.f.j=(t,r)=>{var n=o.o(e,t)?e[t]:void 0;if(0!==n)if(n)r.push(n[2]);else{var i=new Promise(((r,o)=>n=e[t]=[r,o]));r.push(n[2]=i);var a=o.p+o.u(t),l=new Error;o.l(a,(r=>{if(o.o(e,t)&&(0!==(n=e[t])&&(e[t]=void 0),n)){var i=r&&("load"===r.type?"missing":r.type),a=r&&r.target&&r.target.src;l.message="Loading chunk "+t+" failed.\n("+i+": "+a+")",l.name="ChunkLoadError",l.type=i,l.request=a,n[1](l)}}),"chunk-"+t,t)}};var t=(t,r)=>{var n,i,[a,l,s]=r,c=0;if(a.some((t=>0!==e[t]))){for(n in l)o.o(l,n)&&(o.m[n]=l[n]);s&&s(o)}for(t&&t(r);c<a.length;c++)i=a[c],o.o(e,i)&&e[i]&&e[i][0](),e[i]=0},r=globalThis.blocksyNewsletterSubscribeExtJsonp=globalThis.blocksyNewsletterSubscribeExtJsonp||[];r.forEach(t.bind(null,0)),r.push=t.bind(null,r.push.bind(r))})(),(()=>{"use strict";o(466);var e=o(381),t=o(652),r=o(313),n=(0,r.lazy)((function(){return Promise.all([o.e(486),o.e(677)]).then(o.bind(o,677))}));const i=function(o){return(0,e.createElement)("div",null,(0,e.createElement)(r.Suspense,{fallback:(0,e.createElement)("div",{className:"ct-select-input"},(0,e.createElement)("input",{disabled:!0,placeholder:(0,t.__)("Loading...","blocksy-companion")}))},(0,e.createElement)(n,o)))},a=window.ctEvents;var l=o.n(a);document.addEventListener("DOMContentLoaded",(function(){return l().on("blocksy:options:register",(function(e){e["blocksy-newsletter-subscribe"]=i}))}))})()})();
|
framework/extensions/newsletter-subscribe/admin-static/bundle/sync.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
|
1 |
+
(()=>{"use strict";var e={n:t=>{var r=t&&t.__esModule?()=>t.default:()=>t;return e.d(r,{a:r}),r},d:(t,r)=>{for(var s in r)e.o(r,s)&&!e.o(t,s)&&Object.defineProperty(t,s,{enumerable:!0,get:r[s]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t)};const t=window.blocksyCustomizerSync,r=window.ctEvents;function s(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);t&&(s=s.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,s)}return r}function c(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?s(Object(r),!0).forEach((function(t){o(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):s(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function o(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}e.n(r)().on("ct:customizer:sync:collect-variable-descriptors",(function(e){e.result=c(c(c({},e.result),{},{newsletter_subscribe_title_color:{selector:".ct-newsletter-subscribe-block",variable:"heading-color",type:"color:default",responsive:!0},newsletter_subscribe_content:[{selector:".ct-newsletter-subscribe-block",variable:"color",type:"color:default"},{selector:".ct-newsletter-subscribe-block",variable:"linkHoverColor",type:"color:hover"}],newsletter_subscribe_button:[{selector:".ct-newsletter-subscribe-block",variable:"buttonInitialColor",type:"color:default"},{selector:".ct-newsletter-subscribe-block",variable:"buttonHoverColor",type:"color:hover"}],newsletter_subscribe_input_font_color:[{selector:".ct-newsletter-subscribe-block",variable:"form-text-initial-color",type:"color:default"},{selector:".ct-newsletter-subscribe-block",variable:"form-text-focus-color",type:"color:focus"}],newsletter_subscribe_border_color:[{selector:".ct-newsletter-subscribe-block",variable:"form-field-border-initial-color",type:"color:default"},{selector:".ct-newsletter-subscribe-block",variable:"form-field-border-focus-color",type:"color:focus"}],newsletter_subscribe_input_background:[{selector:".ct-newsletter-subscribe-block",variable:"form-field-initial-background",type:"color:default"},{selector:".ct-newsletter-subscribe-block",variable:"form-field-focus-background",type:"color:focus"}]},(0,t.handleBackgroundOptionFor)({id:"newsletter_subscribe_container_background",selector:".ct-newsletter-subscribe-block",responsive:!0})),{},{newsletter_subscribe_container_border:{selector:".ct-newsletter-subscribe-block",variable:"newsletter-container-border",type:"border",responsive:!0,skip_none:!0},newsletter_subscribe_shadow:{selector:".ct-newsletter-subscribe-block",type:"box-shadow",variable:"box-shadow",responsive:!0},newsletter_subscribe_container_spacing:{selector:".ct-newsletter-subscribe-block",type:"spacing",variable:"padding",responsive:!0},newsletter_subscribe_container_border_radius:{selector:".ct-newsletter-subscribe-block",type:"spacing",variable:"border-radius",responsive:!0}})})),wp.customize("newsletter_subscribe_subscribe_visibility",(function(e){return e.bind((function(e){var r=document.querySelector(".ct-newsletter-subscribe-block");(0,t.responsiveClassesFor)("newsletter_subscribe_subscribe_visibility",r)}))})),(document.body.classList.contains("single")||document.body.classList.contains("page"))&&(0,t.checkAndReplace)({id:"newsletter_subscribe_single_post_enabled",strategy:"append",parent_selector:".site-main article",selector:".ct-newsletter-subscribe-block",fragment_id:"blocksy-mailchimp-subscribe",watch:["has_newsletter_subscribe_name","newsletter_subscribe_button_text","newsletter_subscribe_title","newsletter_subscribe_text","newsletter_subscribe_name_label","newsletter_subscribe_mail_label"],whenInserted:function(){if(document.body.classList.contains("single")||document.body.classList.contains("page")){var e=document.querySelector(".ct-newsletter-subscribe-block");(0,t.responsiveClassesFor)("newsletter_subscribe_subscribe_visibility",e),"yes"!==wp.customize("has_newsletter_subscribe_name")()?(e.querySelector("[data-fields]").dataset.fields=1,e.querySelector('[name="FNAME"]').remove()):(e.querySelector("[data-fields]").dataset.fields=2,e.querySelector('[name="FNAME"]').setAttribute("placeholder","".concat(wp.customize("newsletter_subscribe_name_label")()))),e.querySelector('[name="EMAIL"]').setAttribute("placeholder","".concat(wp.customize("newsletter_subscribe_mail_label")()," *")),e.querySelector("button").innerHTML=wp.customize("newsletter_subscribe_button_text")(),e.querySelector("h3").innerHTML=wp.customize("newsletter_subscribe_title")(),e.querySelector(".ct-newsletter-subscribe-description").innerHTML=wp.customize("newsletter_subscribe_text")()}}})})();
|
framework/extensions/newsletter-subscribe/dashboard-static/bundle/main.js
CHANGED
@@ -1,14 +1,2 @@
|
|
1 |
-
|
2 |
-
/*!
|
3 |
-
Copyright (c) 2017 Jed Watson.
|
4 |
-
Licensed under the MIT License (MIT), see
|
5 |
-
http://jedwatson.github.io/classnames
|
6 |
-
*/!function(){"use strict";var n={}.hasOwnProperty;function o(){for(var e=[],t=0;t<arguments.length;t++){var r=arguments[t];if(r){var i=typeof r;if("string"===i||"number"===i)e.push(r);else if(Array.isArray(r)&&r.length){var a=o.apply(null,r);a&&e.push(a)}else if("object"===i)for(var u in r)n.call(r,u)&&r[u]&&e.push(u)}}return e.join(" ")}e.exports?(o.default=o,e.exports=o):void 0===(r=function(){return o}.apply(t,[]))||(e.exports=r)}()},function(e,t){e.exports=window.blocksyOptions},function(e,t,n){"use strict";e.exports=n(13)},function(e,t){e.exports=window.ctEvents},function(e,t,n){var r,o,i=n(11),a=n(12),u=(o=[],{activateTrap:function(e){if(o.length>0){var t=o[o.length-1];t!==e&&t.pause()}var n=o.indexOf(e);-1===n||o.splice(n,1),o.push(e)},deactivateTrap:function(e){var t=o.indexOf(e);-1!==t&&o.splice(t,1),o.length>0&&o[o.length-1].unpause()}});function c(e){return setTimeout(e,0)}e.exports=function(e,t){var n=document,o="string"==typeof e?n.querySelector(e):e,s=a({returnFocusOnDeactivate:!0,escapeDeactivates:!0},t),l={firstTabbableNode:null,lastTabbableNode:null,nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1},p={activate:function(e){if(l.active)return;I(),l.active=!0,l.paused=!1,l.nodeFocusedBeforeActivation=n.activeElement;var t=e&&e.onActivate?e.onActivate:s.onActivate;t&&t();return f(),p},deactivate:d,pause:function(){if(l.paused||!l.active)return;l.paused=!0,h()},unpause:function(){if(!l.paused||!l.active)return;l.paused=!1,I(),f()}};return p;function d(e){if(l.active){clearTimeout(r),h(),l.active=!1,l.paused=!1,u.deactivateTrap(p);var t=e&&void 0!==e.onDeactivate?e.onDeactivate:s.onDeactivate;return t&&t(),(e&&void 0!==e.returnFocus?e.returnFocus:s.returnFocusOnDeactivate)&&c((function(){var e;O((e=l.nodeFocusedBeforeActivation,m("setReturnFocus")||e))})),p}}function f(){if(l.active)return u.activateTrap(p),r=c((function(){O(v())})),n.addEventListener("focusin",y,!0),n.addEventListener("mousedown",g,{capture:!0,passive:!1}),n.addEventListener("touchstart",g,{capture:!0,passive:!1}),n.addEventListener("click",w,{capture:!0,passive:!1}),n.addEventListener("keydown",b,{capture:!0,passive:!1}),p}function h(){if(l.active)return n.removeEventListener("focusin",y,!0),n.removeEventListener("mousedown",g,!0),n.removeEventListener("touchstart",g,!0),n.removeEventListener("click",w,!0),n.removeEventListener("keydown",b,!0),p}function m(e){var t=s[e],r=t;if(!t)return null;if("string"==typeof t&&!(r=n.querySelector(t)))throw new Error("`"+e+"` refers to no known node");if("function"==typeof t&&!(r=t()))throw new Error("`"+e+"` did not return a node");return r}function v(){var e;if(!(e=null!==m("initialFocus")?m("initialFocus"):o.contains(n.activeElement)?n.activeElement:l.firstTabbableNode||m("fallbackFocus")))throw new Error("Your focus-trap needs to have at least one focusable element");return e}function g(e){o.contains(e.target)||(s.clickOutsideDeactivates?d({returnFocus:!i.isFocusable(e.target)}):s.allowOutsideClick&&s.allowOutsideClick(e)||e.preventDefault())}function y(e){o.contains(e.target)||e.target instanceof Document||(e.stopImmediatePropagation(),O(l.mostRecentlyFocusedNode||v()))}function b(e){if(!1!==s.escapeDeactivates&&function(e){return"Escape"===e.key||"Esc"===e.key||27===e.keyCode}(e))return e.preventDefault(),void d();(function(e){return"Tab"===e.key||9===e.keyCode})(e)&&function(e){if(I(),e.shiftKey&&e.target===l.firstTabbableNode)return e.preventDefault(),void O(l.lastTabbableNode);if(!e.shiftKey&&e.target===l.lastTabbableNode)e.preventDefault(),O(l.firstTabbableNode)}(e)}function w(e){s.clickOutsideDeactivates||o.contains(e.target)||s.allowOutsideClick&&s.allowOutsideClick(e)||(e.preventDefault(),e.stopImmediatePropagation())}function I(){var e=i(o);l.firstTabbableNode=e[0]||v(),l.lastTabbableNode=e[e.length-1]||v()}function O(e){e!==n.activeElement&&(e&&e.focus?(e.focus(),l.mostRecentlyFocusedNode=e,function(e){return e.tagName&&"input"===e.tagName.toLowerCase()&&"function"==typeof e.select}(e)&&e.select()):O(v()))}}},function(e,t,n){"use strict";var r=n(10);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,i,a){if(a!==r){var u=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 u.name="Invariant Violation",u}}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:i,resetWarningCache:o};return n.PropTypes=n,n}},function(e,t,n){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(e,t){var n=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'],r=n.join(","),o="undefined"==typeof Element?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector;function i(e,t){t=t||{};var n,i,u,c=[],p=[],d=e.querySelectorAll(r);for(t.includeContainer&&o.call(e,r)&&(d=Array.prototype.slice.apply(d)).unshift(e),n=0;n<d.length;n++)a(i=d[n])&&(0===(u=s(i))?c.push(i):p.push({documentOrder:n,tabIndex:u,node:i}));return p.sort(l).map((function(e){return e.node})).concat(c)}function a(e){return!(!u(e)||function(e){return function(e){return p(e)&&"radio"===e.type}(e)&&!function(e){if(!e.name)return!0;var t=function(e){for(var t=0;t<e.length;t++)if(e[t].checked)return e[t]}(e.ownerDocument.querySelectorAll('input[type="radio"][name="'+e.name+'"]'));return!t||t===e}(e)}(e)||s(e)<0)}function u(e){return!(e.disabled||function(e){return p(e)&&"hidden"===e.type}(e)||function(e){return null===e.offsetParent||"hidden"===getComputedStyle(e).visibility}(e))}i.isTabbable=function(e){if(!e)throw new Error("No node provided");return!1!==o.call(e,r)&&a(e)},i.isFocusable=function(e){if(!e)throw new Error("No node provided");return!1!==o.call(e,c)&&u(e)};var c=n.concat("iframe").join(",");function s(e){var t=parseInt(e.getAttribute("tabindex"),10);return isNaN(t)?function(e){return"true"===e.contentEditable}(e)?0:e.tabIndex:t}function l(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex}function p(e){return"INPUT"===e.tagName}e.exports=i},function(e,t){e.exports=function(){for(var e={},t=0;t<arguments.length;t++){var r=arguments[t];for(var o in r)n.call(r,o)&&(e[o]=r[o])}return e};var n=Object.prototype.hasOwnProperty},function(e,t,n){"use strict";
|
7 |
-
/** @license React v16.13.1
|
8 |
-
* react-is.production.min.js
|
9 |
-
*
|
10 |
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
11 |
-
*
|
12 |
-
* This source code is licensed under the MIT license found in the
|
13 |
-
* LICENSE file in the root directory of this source tree.
|
14 |
-
*/var r="function"==typeof Symbol&&Symbol.for,o=r?Symbol.for("react.element"):60103,i=r?Symbol.for("react.portal"):60106,a=r?Symbol.for("react.fragment"):60107,u=r?Symbol.for("react.strict_mode"):60108,c=r?Symbol.for("react.profiler"):60114,s=r?Symbol.for("react.provider"):60109,l=r?Symbol.for("react.context"):60110,p=r?Symbol.for("react.async_mode"):60111,d=r?Symbol.for("react.concurrent_mode"):60111,f=r?Symbol.for("react.forward_ref"):60112,h=r?Symbol.for("react.suspense"):60113,m=r?Symbol.for("react.suspense_list"):60120,v=r?Symbol.for("react.memo"):60115,g=r?Symbol.for("react.lazy"):60116,y=r?Symbol.for("react.block"):60121,b=r?Symbol.for("react.fundamental"):60117,w=r?Symbol.for("react.responder"):60118,I=r?Symbol.for("react.scope"):60119;function O(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case o:switch(e=e.type){case p:case d:case a:case c:case u:case h:return e;default:switch(e=e&&e.$$typeof){case l:case f:case g:case v:case s:return e;default:return t}}case i:return t}}}function S(e){return O(e)===d}t.AsyncMode=p,t.ConcurrentMode=d,t.ContextConsumer=l,t.ContextProvider=s,t.Element=o,t.ForwardRef=f,t.Fragment=a,t.Lazy=g,t.Memo=v,t.Portal=i,t.Profiler=c,t.StrictMode=u,t.Suspense=h,t.isAsyncMode=function(e){return S(e)||O(e)===p},t.isConcurrentMode=S,t.isContextConsumer=function(e){return O(e)===l},t.isContextProvider=function(e){return O(e)===s},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===o},t.isForwardRef=function(e){return O(e)===f},t.isFragment=function(e){return O(e)===a},t.isLazy=function(e){return O(e)===g},t.isMemo=function(e){return O(e)===v},t.isPortal=function(e){return O(e)===i},t.isProfiler=function(e){return O(e)===c},t.isStrictMode=function(e){return O(e)===u},t.isSuspense=function(e){return O(e)===h},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===a||e===d||e===c||e===u||e===h||e===m||"object"==typeof e&&null!==e&&(e.$$typeof===g||e.$$typeof===v||e.$$typeof===s||e.$$typeof===l||e.$$typeof===f||e.$$typeof===b||e.$$typeof===w||e.$$typeof===I||e.$$typeof===y)},t.typeOf=O},function(e,t,n){"use strict";n.r(t);var r=n(0),o=n(7),i=n.n(o),a=n(2),u=n(4),c=n.n(u),s=n(3),l=n.n(s),p=n(1),d=n.n(p);function f(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function h(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var m=function(e){e.initialState,e.getInitialState,e.refs,e.getRefs,e.didMount,e.didUpdate,e.willUnmount,e.getSnapshotBeforeUpdate,e.shouldUpdate,e.render;return function(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}(e,["initialState","getInitialState","refs","getRefs","didMount","didUpdate","willUnmount","getSnapshotBeforeUpdate","shouldUpdate","render"])},v=function(e){function t(){var n,r;f(this,t);for(var o=arguments.length,i=Array(o),a=0;a<o;a++)i[a]=arguments[a];return n=r=h(this,e.call.apply(e,[this].concat(i))),g.call(r),h(r,n)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),t.prototype.getArgs=function(){var e=this.state,t=this.props,n=this._setState,r=this._forceUpdate,o=this._refs;return{state:e,props:m(t),refs:o,setState:n,forceUpdate:r}},t.prototype.componentDidMount=function(){this.props.didMount&&this.props.didMount(this.getArgs())},t.prototype.shouldComponentUpdate=function(e,t){return!this.props.shouldUpdate||this.props.shouldUpdate({props:this.props,state:this.state,nextProps:m(e),nextState:t})},t.prototype.componentWillUnmount=function(){this.props.willUnmount&&this.props.willUnmount({state:this.state,props:m(this.props),refs:this._refs})},t.prototype.componentDidUpdate=function(e,t,n){this.props.didUpdate&&this.props.didUpdate(Object.assign(this.getArgs(),{prevProps:m(e),prevState:t}),n)},t.prototype.getSnapshotBeforeUpdate=function(e,t){return this.props.getSnapshotBeforeUpdate?this.props.getSnapshotBeforeUpdate(Object.assign(this.getArgs(),{prevProps:m(e),prevState:t})):null},t.prototype.render=function(){var e=this.props,t=e.children,n=e.render;return n?n(this.getArgs()):"function"==typeof t?t(this.getArgs()):t||null},t}(l.a.Component);v.defaultProps={getInitialState:function(){},getRefs:function(){return{}}};var g=function(){var e=this;this.state=this.props.initialState||this.props.getInitialState(this.props),this._refs=this.props.refs||this.props.getRefs(this.getArgs()),this._setState=function(){return e.setState.apply(e,arguments)},this._forceUpdate=function(){return e.forceUpdate.apply(e,arguments)}},y=v,b=function(e){var t=e.children,n=e.container,o=void 0===n?document.body:n,i=e.type,a=void 0===i?"reach-portal":i;return Object(r.createElement)(y,{getRefs:function(){return{node:null}},didMount:function(e){var t=e.refs,n=e.forceUpdate,r=o.hasOwnProperty("current")?o.current:o;t.node=document.createElement(a),r.appendChild(t.node),n()},willUnmount:function(e){var t=e.refs.node,n=o.hasOwnProperty("current")?o.current:o;n&&n.removeChild(t)},render:function(e){var n=e.refs.node;return n?Object(r.createPortal)(t,n):null}})};var w=function(e,t){return function(n){if(e&&e(n),!n.defaultPrevented)return t(n)}},I=n(8),O=n.n(I);function S(){return(S=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function x(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var E=function(){},j=function(){},_=function(e,t){var n,r,o;e.disposeAriaHider=(n=e.overlayNode,r=[],o=[],Array.prototype.forEach.call(document.querySelectorAll("body > *"),(function(e){if(e!==n.parentNode){var t=e.getAttribute("aria-hidden");null!==t&&"false"!==t||(r.push(t),o.push(e),e.setAttribute("aria-hidden","true"))}})),function(){o.forEach((function(e,t){var n=r[t];null===n?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",n)}))}),e.trap=O()(e.overlayNode,{initialFocus:t?function(){return t.current}:void 0,fallbackFocus:e.contentNode,escapeDeactivates:!1,clickOutsideDeactivates:!1})},C=function(e){var t=e.refs;t.trap.deactivate(),t.disposeAriaHider()},k=React.createContext(),P=React.forwardRef((function(e,t){var n=e.container,o=e.isOpen,i=void 0===o||o,a=e.onDismiss,u=void 0===a?E:a,c=e.initialFocusRef,s=e.onClick,l=e.onKeyDown,p=x(e,["container","isOpen","onDismiss","initialFocusRef","onClick","onKeyDown"]);return Object(r.createElement)(y,{didMount:j},i?Object(r.createElement)(b,{container:n,"data-reach-dialog-wrapper":!0},Object(r.createElement)(y,{refs:{overlayNode:null,contentNode:null},didMount:function(e){var t=e.refs;_(t,c)},willUnmount:C},(function(e){var n=e.refs;return Object(r.createElement)(k.Provider,{value:function(e){return n.contentNode=e}},Object(r.createElement)("div",S({"data-reach-dialog-overlay":!0,onClick:w(s,(function(e){e.stopPropagation(),u()})),onKeyDown:w(l,(function(e){"Escape"===e.key&&(e.stopPropagation(),u())})),ref:function(e){n.overlayNode=e,t&&t(e)}},p)))}))):null)}));P.propTypes={initialFocusRef:function(){}};var A=function(e){return e.stopPropagation()},D=React.forwardRef((function(e,t){var n=e.onClick,o=(e.onKeyDown,x(e,["onClick","onKeyDown"]));return Object(r.createElement)(k.Consumer,null,(function(e){return Object(r.createElement)("div",S({"aria-modal":"true","data-reach-dialog-content":!0,tabIndex:"-1",onClick:w(n,A),ref:function(n){e(n),t&&t(n)}},o))}))})),M=n(5),T=function(e){return!!e},H=function(e){var t=e.items,n=e.isVisible,o=void 0===n?T:n,i=e.render,a=e.className,u=e.onDismiss;return Object(r.createElement)(M.Transition,{items:t,onStart:function(){return document.body.classList[o(t)?"add":"remove"]("ct-dashboard-overlay-open")},config:{duration:200},from:{opacity:0,y:-10},enter:{opacity:1,y:0},leave:{opacity:0,y:10}},(function(e){return o(e)&&function(t){return Object(r.createElement)(P,{style:{opacity:t.opacity},container:document.querySelector("#wpbody"),onDismiss:function(){return u()}},Object(r.createElement)(D,{className:c()("ct-admin-modal",a),style:{transform:"translate3d(0px, ".concat(t.y,"px, 0px)")}},Object(r.createElement)("button",{className:"close-button",onClick:function(){return u()}},"×"),i(e,t)))}}))};function R(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,o=!1,i=void 0;try{for(var a,u=e[Symbol.iterator]();!(r=(a=u.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==u.return||u.return()}finally{if(o)throw i}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return N(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return N(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function N(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var L=function(e){var t=R(Object(r.useState)(!1),2),n=t[0],o=t[1];return[function(){return o(!0)},Object(r.createElement)(H,{items:n,onDismiss:function(){return o(!1)},render:function(){return Object(r.createElement)("div",{className:"ct-modal-content",dangerouslySetInnerHTML:{__html:e.readme}})}})]};function U(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}function K(){return(K=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function F(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}n(6);function V(e){return null!=e&&"object"==typeof e&&1===e.nodeType}function B(e,t){return(!t||"hidden"!==e)&&("visible"!==e&&"clip"!==e)}function $(e,t){if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){var n=getComputedStyle(e,null);return B(n.overflowY,t)||B(n.overflowX,t)||function(e){var t=function(e){return e.ownerDocument&&e.ownerDocument.defaultView?e.ownerDocument.defaultView.frameElement:null}(e);return!!t&&(t.clientHeight<e.scrollHeight||t.clientWidth<e.scrollWidth)}(e)}return!1}function W(e,t,n,r,o,i,a,u){return i<e&&a>t||i>e&&a<t?0:i<=e&&u<=n||a>=t&&u>=n?i-e-r:a>t&&u<n||i<e&&u>n?a-t+o:0}var z=0;function q(e){return"function"==typeof e?e:Y}function Y(){}function X(e,t){null!==e&&function(e,t){var n=t.scrollMode,r=t.block,o=t.inline,i=t.boundary,a=t.skipOverflowHiddenElements,u="function"==typeof i?i:function(e){return e!==i};if(!V(e))throw new TypeError("Invalid target");for(var c=document.scrollingElement||document.documentElement,s=[],l=e;V(l)&&u(l);){if((l=l.parentNode)===c){s.push(l);break}l===document.body&&$(l)&&!$(document.documentElement)||$(l,a)&&s.push(l)}for(var p=window.visualViewport?visualViewport.width:innerWidth,d=window.visualViewport?visualViewport.height:innerHeight,f=window.scrollX||pageXOffset,h=window.scrollY||pageYOffset,m=e.getBoundingClientRect(),v=m.height,g=m.width,y=m.top,b=m.right,w=m.bottom,I=m.left,O="start"===r||"nearest"===r?y:"end"===r?w:y+v/2,S="center"===o?I+g/2:"end"===o?b:I,x=[],E=0;E<s.length;E++){var j=s[E],_=j.getBoundingClientRect(),C=_.height,k=_.width,P=_.top,A=_.right,D=_.bottom,M=_.left;if("if-needed"===n&&y>=0&&I>=0&&w<=d&&b<=p&&y>=P&&w<=D&&I>=M&&b<=A)return x;var T=getComputedStyle(j),H=parseInt(T.borderLeftWidth,10),R=parseInt(T.borderTopWidth,10),N=parseInt(T.borderRightWidth,10),L=parseInt(T.borderBottomWidth,10),U=0,K=0,F="offsetWidth"in j?j.offsetWidth-j.clientWidth-H-N:0,B="offsetHeight"in j?j.offsetHeight-j.clientHeight-R-L:0;if(c===j)U="start"===r?O:"end"===r?O-d:"nearest"===r?W(h,h+d,d,R,L,h+O,h+O+v,v):O-d/2,K="start"===o?S:"center"===o?S-p/2:"end"===o?S-p:W(f,f+p,p,H,N,f+S,f+S+g,g),U=Math.max(0,U+h),K=Math.max(0,K+f);else{U="start"===r?O-P-R:"end"===r?O-D+L+B:"nearest"===r?W(P,D,C,R,L+B,O,O+v,v):O-(P+C/2)+B/2,K="start"===o?S-M-H:"center"===o?S-(M+k/2)+F/2:"end"===o?S-A+N+F:W(M,A,k,H,N+F,S,S+g,g);var z=j.scrollLeft,q=j.scrollTop;O+=q-(U=Math.max(0,Math.min(q+U,j.scrollHeight-C+B))),S+=z-(K=Math.max(0,Math.min(z+K,j.scrollWidth-k+F)))}x.push({el:j,top:U,left:K})}return x}(e,{boundary:t,block:"nearest",scrollMode:"if-needed"}).forEach((function(e){var t=e.el,n=e.top,r=e.left;t.scrollTop=n,t.scrollLeft=r}))}function G(e,t){return e===t||e.contains&&e.contains(t)}function J(e,t){var n;function r(){n&&clearTimeout(n)}function o(){for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];r(),n=setTimeout((function(){n=null,e.apply(void 0,i)}),t)}return o.cancel=r,o}function Q(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return t.some((function(t){return t&&t.apply(void 0,[e].concat(r)),e.preventDownshiftDefault||e.hasOwnProperty("nativeEvent")&&e.nativeEvent.preventDownshiftDefault}))}}function Z(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){t.forEach((function(t){"function"==typeof t?t(e):t&&(t.current=e)}))}}function ee(e){var t=e.isOpen,n=e.selectedItem,r=e.resultCount,o=e.previousResultCount,i=e.itemToString;return t?r?r!==o?r+" result"+(1===r?" is":"s are")+" available, use up and down arrow keys to navigate. Press Enter key to select.":"":"No results are available.":n?i(n):""}function te(e,t){return!(e=Array.isArray(e)?e[0]:e)&&t?t:e}function ne(e){return"string"==typeof e.type}function re(e){return e.props}var oe=["highlightedIndex","inputValue","isOpen","selectedItem","type"];function ie(e){void 0===e&&(e={});var t={};return oe.forEach((function(n){e.hasOwnProperty(n)&&(t[n]=e[n])})),t}function ae(e){var t=e.key,n=e.keyCode;return n>=37&&n<=40&&0!==t.indexOf("Arrow")?"Arrow"+t:t}function ue(e,t,n){var r=n-1;("number"!=typeof t||t<0||t>=n)&&(t=e>0?-1:r+1);var o=t+e;return o<0?o=r:o>r&&(o=0),o}var ce=J((function(){le().textContent=""}),500);function se(e,t){var n=le(t);e&&(n.textContent=e,ce())}function le(e){void 0===e&&(e=document);var t=e.getElementById("a11y-status-message");return t||((t=e.createElement("div")).setAttribute("id","a11y-status-message"),t.setAttribute("role","status"),t.setAttribute("aria-live","polite"),t.setAttribute("aria-relevant","additions text"),Object.assign(t.style,{border:"0",clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:"0",position:"absolute",width:"1px"}),e.body.appendChild(t),t)}var pe=Object.freeze({__proto__:null,unknown:0,mouseUp:1,itemMouseEnter:2,keyDownArrowUp:3,keyDownArrowDown:4,keyDownEscape:5,keyDownEnter:6,keyDownHome:7,keyDownEnd:8,clickItem:9,blurInput:10,changeInput:11,keyDownSpaceButton:12,clickButton:13,blurButton:14,controlledPropUpdatedSelectedItem:15,touchEnd:16}),de=function(){var e=function(e){var t,n;function r(t){var n=e.call(this,t)||this;n.id=n.props.id||"downshift-"+String(z++),n.menuId=n.props.menuId||n.id+"-menu",n.labelId=n.props.labelId||n.id+"-label",n.inputId=n.props.inputId||n.id+"-input",n.getItemId=n.props.getItemId||function(e){return n.id+"-item-"+e},n.input=null,n.items=[],n.itemCount=null,n.previousResultCount=0,n.timeoutIds=[],n.internalSetTimeout=function(e,t){var r=setTimeout((function(){n.timeoutIds=n.timeoutIds.filter((function(e){return e!==r})),e()}),t);n.timeoutIds.push(r)},n.setItemCount=function(e){n.itemCount=e},n.unsetItemCount=function(){n.itemCount=null},n.setHighlightedIndex=function(e,t){void 0===e&&(e=n.props.defaultHighlightedIndex),void 0===t&&(t={}),t=ie(t),n.internalSetState(K({highlightedIndex:e},t))},n.clearSelection=function(e){n.internalSetState({selectedItem:null,inputValue:"",highlightedIndex:n.props.defaultHighlightedIndex,isOpen:n.props.defaultIsOpen},e)},n.selectItem=function(e,t,r){t=ie(t),n.internalSetState(K({isOpen:n.props.defaultIsOpen,highlightedIndex:n.props.defaultHighlightedIndex,selectedItem:e,inputValue:n.props.itemToString(e)},t),r)},n.selectItemAtIndex=function(e,t,r){var o=n.items[e];null!=o&&n.selectItem(o,t,r)},n.selectHighlightedItem=function(e,t){return n.selectItemAtIndex(n.getState().highlightedIndex,e,t)},n.internalSetState=function(e,t){var r,o,i={},a="function"==typeof e;return!a&&e.hasOwnProperty("inputValue")&&n.props.onInputValueChange(e.inputValue,K({},n.getStateAndHelpers(),{},e)),n.setState((function(t){t=n.getState(t);var u=a?e(t):e;u=n.props.stateReducer(t,u),r=u.hasOwnProperty("selectedItem");var c={},s={};return r&&u.selectedItem!==t.selectedItem&&(o=u.selectedItem),u.type=u.type||0,Object.keys(u).forEach((function(e){t[e]!==u[e]&&(i[e]=u[e]),"type"!==e&&(s[e]=u[e],n.isControlledProp(e)||(c[e]=u[e]))})),a&&u.hasOwnProperty("inputValue")&&n.props.onInputValueChange(u.inputValue,K({},n.getStateAndHelpers(),{},u)),c}),(function(){q(t)(),Object.keys(i).length>1&&n.props.onStateChange(i,n.getStateAndHelpers()),r&&n.props.onSelect(e.selectedItem,n.getStateAndHelpers()),void 0!==o&&n.props.onChange(o,n.getStateAndHelpers()),n.props.onUserAction(i,n.getStateAndHelpers())}))},n.rootRef=function(e){return n._rootNode=e},n.getRootProps=function(e,t){var r,o=void 0===e?{}:e,i=o.refKey,a=void 0===i?"ref":i,u=o.ref,c=U(o,["refKey","ref"]),s=(void 0===t?{}:t).suppressRefError,l=void 0!==s&&s;n.getRootProps.called=!0,n.getRootProps.refKey=a,n.getRootProps.suppressRefError=l;var p=n.getState().isOpen;return K(((r={})[a]=Z(u,n.rootRef),r.role="combobox",r["aria-expanded"]=p,r["aria-haspopup"]="listbox",r["aria-owns"]=p?n.menuId:null,r["aria-labelledby"]=n.labelId,r),c)},n.keyDownHandlers={ArrowDown:function(e){var t=this;if(e.preventDefault(),this.getState().isOpen){var n=e.shiftKey?5:1;this.moveHighlightedIndex(n,{type:4})}else this.internalSetState({isOpen:!0,type:4},(function(){var e=t.getItemCount();e>0&&t.setHighlightedIndex(ue(1,t.getState().highlightedIndex,e),{type:4})}))},ArrowUp:function(e){var t=this;if(e.preventDefault(),this.getState().isOpen){var n=e.shiftKey?-5:-1;this.moveHighlightedIndex(n,{type:3})}else this.internalSetState({isOpen:!0,type:3},(function(){var e=t.getItemCount();e>0&&t.setHighlightedIndex(ue(-1,t.getState().highlightedIndex,e),{type:4})}))},Enter:function(e){var t=this.getState(),n=t.isOpen,r=t.highlightedIndex;if(n&&null!=r){e.preventDefault();var o=this.items[r],i=this.getItemNodeFromIndex(r);if(null==o||i&&i.hasAttribute("disabled"))return;this.selectHighlightedItem({type:6})}},Escape:function(e){e.preventDefault(),this.reset({type:5,selectedItem:null,inputValue:""})}},n.buttonKeyDownHandlers=K({},n.keyDownHandlers,{" ":function(e){e.preventDefault(),this.toggleMenu({type:12})}}),n.inputKeyDownHandlers=K({},n.keyDownHandlers,{Home:function(e){this.highlightFirstOrLastIndex(e,!0,{type:7})},End:function(e){this.highlightFirstOrLastIndex(e,!1,{type:8})}}),n.getToggleButtonProps=function(e){var t=void 0===e?{}:e,r=t.onClick,o=(t.onPress,t.onKeyDown),i=t.onKeyUp,a=t.onBlur,u=U(t,["onClick","onPress","onKeyDown","onKeyUp","onBlur"]),c=n.getState().isOpen,s={onClick:Q(r,n.buttonHandleClick),onKeyDown:Q(o,n.buttonHandleKeyDown),onKeyUp:Q(i,n.buttonHandleKeyUp),onBlur:Q(a,n.buttonHandleBlur)};return K({type:"button",role:"button","aria-label":c?"close menu":"open menu","aria-haspopup":!0,"data-toggle":!0},u.disabled?{}:s,{},u)},n.buttonHandleKeyUp=function(e){e.preventDefault()},n.buttonHandleKeyDown=function(e){var t=ae(e);n.buttonKeyDownHandlers[t]&&n.buttonKeyDownHandlers[t].call(F(n),e)},n.buttonHandleClick=function(e){e.preventDefault(),n.props.environment.document.activeElement===n.props.environment.document.body&&e.target.focus(),n.internalSetTimeout((function(){return n.toggleMenu({type:13})}))},n.buttonHandleBlur=function(e){var t=e.target;n.internalSetTimeout((function(){n.isMouseDown||null!=n.props.environment.document.activeElement&&n.props.environment.document.activeElement.id===n.inputId||n.props.environment.document.activeElement===t||n.reset({type:14})}))},n.getLabelProps=function(e){return K({htmlFor:n.inputId,id:n.labelId},e)},n.getInputProps=function(e){var t=void 0===e?{}:e,r=t.onKeyDown,o=t.onBlur,i=t.onChange,a=t.onInput,u=(t.onChangeText,U(t,["onKeyDown","onBlur","onChange","onInput","onChangeText"])),c={};var s,l=n.getState(),p=l.inputValue,d=l.isOpen,f=l.highlightedIndex;u.disabled||((s={}).onChange=Q(i,a,n.inputHandleChange),s.onKeyDown=Q(r,n.inputHandleKeyDown),s.onBlur=Q(o,n.inputHandleBlur),c=s);return K({"aria-autocomplete":"list","aria-activedescendant":d&&"number"==typeof f&&f>=0?n.getItemId(f):null,"aria-controls":d?n.menuId:null,"aria-labelledby":n.labelId,autoComplete:"off",value:p,id:n.inputId},c,{},u)},n.inputHandleKeyDown=function(e){var t=ae(e);t&&n.inputKeyDownHandlers[t]&&n.inputKeyDownHandlers[t].call(F(n),e)},n.inputHandleChange=function(e){n.internalSetState({type:11,isOpen:!0,inputValue:e.target.value,highlightedIndex:n.props.defaultHighlightedIndex})},n.inputHandleBlur=function(){n.internalSetTimeout((function(){var e=n.props.environment.document&&!!n.props.environment.document.activeElement&&!!n.props.environment.document.activeElement.dataset&&n.props.environment.document.activeElement.dataset.toggle&&n._rootNode&&n._rootNode.contains(n.props.environment.document.activeElement);n.isMouseDown||e||n.reset({type:10})}))},n.menuRef=function(e){n._menuNode=e},n.getMenuProps=function(e,t){var r,o=void 0===e?{}:e,i=o.refKey,a=void 0===i?"ref":i,u=o.ref,c=U(o,["refKey","ref"]),s=(void 0===t?{}:t).suppressRefError,l=void 0!==s&&s;return n.getMenuProps.called=!0,n.getMenuProps.refKey=a,n.getMenuProps.suppressRefError=l,K(((r={})[a]=Z(u,n.menuRef),r.role="listbox",r["aria-labelledby"]=c&&c["aria-label"]?null:n.labelId,r.id=n.menuId,r),c)},n.getItemProps=function(e){var t,r=void 0===e?{}:e,o=r.onMouseMove,i=r.onMouseDown,a=r.onClick,u=(r.onPress,r.index),c=r.item,s=void 0===c?void 0:c,l=U(r,["onMouseMove","onMouseDown","onClick","onPress","index","item"]);void 0===u?(n.items.push(s),u=n.items.indexOf(s)):n.items[u]=s;var p=a,d=((t={onMouseMove:Q(o,(function(){u!==n.getState().highlightedIndex&&(n.setHighlightedIndex(u,{type:2}),n.avoidScrolling=!0,n.internalSetTimeout((function(){return n.avoidScrolling=!1}),250))})),onMouseDown:Q(i,(function(e){e.preventDefault()}))}).onClick=Q(p,(function(){n.selectItemAtIndex(u,{type:9})})),t),f=l.disabled?{onMouseDown:d.onMouseDown}:d;return K({id:n.getItemId(u),role:"option","aria-selected":n.getState().highlightedIndex===u},f,{},l)},n.clearItems=function(){n.items=[]},n.reset=function(e,t){void 0===e&&(e={}),e=ie(e),n.internalSetState((function(t){var r=t.selectedItem;return K({isOpen:n.props.defaultIsOpen,highlightedIndex:n.props.defaultHighlightedIndex,inputValue:n.props.itemToString(r)},e)}),t)},n.toggleMenu=function(e,t){void 0===e&&(e={}),e=ie(e),n.internalSetState((function(t){var r=t.isOpen;return K({isOpen:!r},r&&{highlightedIndex:n.props.defaultHighlightedIndex},{},e)}),(function(){var r=n.getState(),o=r.isOpen,i=r.highlightedIndex;o&&n.getItemCount()>0&&"number"==typeof i&&n.setHighlightedIndex(i,e),q(t)()}))},n.openMenu=function(e){n.internalSetState({isOpen:!0},e)},n.closeMenu=function(e){n.internalSetState({isOpen:!1},e)},n.updateStatus=J((function(){var e=n.getState(),t=n.items[e.highlightedIndex],r=n.getItemCount(),o=n.props.getA11yStatusMessage(K({itemToString:n.props.itemToString,previousResultCount:n.previousResultCount,resultCount:r,highlightedItem:t},e));n.previousResultCount=r,se(o,n.props.environment.document)}),200);var r=n.props,o=r.defaultHighlightedIndex,i=r.initialHighlightedIndex,a=void 0===i?o:i,u=r.defaultIsOpen,c=r.initialIsOpen,s=void 0===c?u:c,l=r.initialInputValue,p=void 0===l?"":l,d=r.initialSelectedItem,f=void 0===d?null:d,h=n.getState({highlightedIndex:a,isOpen:s,inputValue:p,selectedItem:f});return null!=h.selectedItem&&void 0===n.props.initialInputValue&&(h.inputValue=n.props.itemToString(h.selectedItem)),n.state=h,n}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var o=r.prototype;return o.internalClearTimeouts=function(){this.timeoutIds.forEach((function(e){clearTimeout(e)})),this.timeoutIds=[]},o.getState=function(e){var t=this;return void 0===e&&(e=this.state),Object.keys(e).reduce((function(n,r){return n[r]=t.isControlledProp(r)?t.props[r]:e[r],n}),{})},o.isControlledProp=function(e){return void 0!==this.props[e]},o.getItemCount=function(){var e=this.items.length;return null!=this.itemCount?e=this.itemCount:void 0!==this.props.itemCount&&(e=this.props.itemCount),e},o.getItemNodeFromIndex=function(e){return this.props.environment.document.getElementById(this.getItemId(e))},o.scrollHighlightedItemIntoView=function(){var e=this.getItemNodeFromIndex(this.getState().highlightedIndex);this.props.scrollIntoView(e,this._menuNode)},o.moveHighlightedIndex=function(e,t){var n=this.getItemCount();if(n>0){var r=ue(e,this.getState().highlightedIndex,n);this.setHighlightedIndex(r,t)}},o.highlightFirstOrLastIndex=function(e,t,n){var r=this.getItemCount()-1;r<0||!this.getState().isOpen||(e.preventDefault(),this.setHighlightedIndex(t?0:r,n))},o.getStateAndHelpers=function(){var e=this.getState(),t=e.highlightedIndex,n=e.inputValue,r=e.selectedItem,o=e.isOpen,i=this.props.itemToString,a=this.id,u=this.getRootProps,c=this.getToggleButtonProps,s=this.getLabelProps,l=this.getMenuProps,p=this.getInputProps,d=this.getItemProps,f=this.openMenu,h=this.closeMenu,m=this.toggleMenu,v=this.selectItem,g=this.selectItemAtIndex,y=this.selectHighlightedItem,b=this.setHighlightedIndex,w=this.clearSelection,I=this.clearItems;return{getRootProps:u,getToggleButtonProps:c,getLabelProps:s,getMenuProps:l,getInputProps:p,getItemProps:d,reset:this.reset,openMenu:f,closeMenu:h,toggleMenu:m,selectItem:v,selectItemAtIndex:g,selectHighlightedItem:y,setHighlightedIndex:b,clearSelection:w,clearItems:I,setItemCount:this.setItemCount,unsetItemCount:this.unsetItemCount,setState:this.internalSetState,itemToString:i,id:a,highlightedIndex:t,inputValue:n,isOpen:o,selectedItem:r}},o.componentDidMount=function(){var e=this;var t=function(t,n){void 0===n&&(n=!0);var r=e.props.environment.document;return[e._rootNode,e._menuNode].some((function(e){return e&&(G(e,t)||n&&G(e,r.activeElement))}))},n=function(){e.isMouseDown=!0},r=function(n){e.isMouseDown=!1,!t(n.target)&&e.getState().isOpen&&e.reset({type:1},(function(){return e.props.onOuterClick(e.getStateAndHelpers())}))},o=function(){e.isTouchMove=!1},i=function(){e.isTouchMove=!0},a=function(n){var r=t(n.target,!1);e.isTouchMove||r||!e.getState().isOpen||e.reset({type:16},(function(){return e.props.onOuterClick(e.getStateAndHelpers())}))},u=this.props.environment;u.addEventListener("mousedown",n),u.addEventListener("mouseup",r),u.addEventListener("touchstart",o),u.addEventListener("touchmove",i),u.addEventListener("touchend",a),this.cleanup=function(){e.internalClearTimeouts(),e.updateStatus.cancel(),u.removeEventListener("mousedown",n),u.removeEventListener("mouseup",r),u.removeEventListener("touchstart",o),u.removeEventListener("touchmove",i),u.removeEventListener("touchend",a)}},o.shouldScroll=function(e,t){var n=(void 0===this.props.highlightedIndex?this.getState():this.props).highlightedIndex,r=(void 0===t.highlightedIndex?e:t).highlightedIndex;return n&&this.getState().isOpen&&!e.isOpen||n!==r},o.componentDidUpdate=function(e,t){this.isControlledProp("selectedItem")&&this.props.selectedItemChanged(e.selectedItem,this.props.selectedItem)&&this.internalSetState({type:15,inputValue:this.props.itemToString(this.props.selectedItem)}),!this.avoidScrolling&&this.shouldScroll(t,e)&&this.scrollHighlightedItemIntoView(),this.updateStatus()},o.componentWillUnmount=function(){this.cleanup()},o.render=function(){var e=te(this.props.children,Y);this.clearItems(),this.getRootProps.called=!1,this.getRootProps.refKey=void 0,this.getRootProps.suppressRefError=void 0,this.getMenuProps.called=!1,this.getMenuProps.refKey=void 0,this.getMenuProps.suppressRefError=void 0,this.getLabelProps.called=!1,this.getInputProps.called=!1;var t=te(e(this.getStateAndHelpers()));return t?this.getRootProps.called||this.props.suppressRefError?t:ne(t)?Object(s.cloneElement)(t,this.getRootProps(re(t))):void 0:null},r}(s.Component);return e.defaultProps={defaultHighlightedIndex:null,defaultIsOpen:!1,getA11yStatusMessage:ee,itemToString:function(e){return null==e?"":String(e)},onStateChange:Y,onInputValueChange:Y,onUserAction:Y,onChange:Y,onSelect:Y,onOuterClick:Y,selectedItemChanged:function(e,t){return e!==t},environment:"undefined"==typeof window?{}:window,stateReducer:function(e,t){return t},suppressRefError:!1,scrollIntoView:X},e.stateChangeTypes=pe,e}();d.a.array.isRequired,d.a.func,d.a.func,d.a.func,d.a.bool,d.a.number,d.a.number,d.a.number,d.a.bool,d.a.bool,d.a.bool,d.a.any,d.a.any,d.a.any,d.a.string,d.a.string,d.a.string,d.a.func,d.a.string,d.a.func,d.a.func,d.a.func,d.a.func,d.a.func,d.a.shape({addEventListener:d.a.func,removeEventListener:d.a.func,document:d.a.shape({getElementById:d.a.func,activeElement:d.a.any,body:d.a.any})});"undefined"==typeof window||window;var fe=de;function he(){return(he=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function me(e,t,n,r,o,i,a){try{var u=e[i](a),c=u.value}catch(e){return void n(e)}u.done?t(c):Promise.resolve(c).then(r,o)}function ve(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,o=!1,i=void 0;try{for(var a,u=e[Symbol.iterator]();!(r=(a=u.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==u.return||u.return()}finally{if(o)throw i}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return ge(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ge(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ge(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var ye=function(e){var t=e.listId,n=e.provider,o=e.apiKey,i=e.onChange,u=ve(Object(r.useState)([]),2),s=u[0],l=u[1],p=ve(Object(r.useState)(!1),2),d=p[0],f=p[1],h=ve(Object(r.useState)({controller:null}),2),m=h[0].controller,v=h[1],g=function(){var e,t=(e=regeneratorRuntime.mark((function e(){var t,r,i;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return m&&m.abort(),f(!0),"AbortController"in window&&(m=new AbortController,v({controller:m})),(t=new FormData).append("api_key",o),t.append("provider",n),t.append("action","blocksy_ext_newsletter_subscribe_maybe_get_lists"),e.prev=7,e.next=10,fetch(ctDashboardLocalizations.ajax_url,{method:"POST",signal:m.signal,body:t});case 10:if(200!==(r=e.sent).status){e.next=20;break}return e.next=14,r.json();case 14:if(!(i=e.sent).success){e.next=20;break}if("api_key_invalid"===i.data.result){e.next=20;break}return f(!1),l(i.data.result),e.abrupt("return");case 20:e.next=24;break;case 22:e.prev=22,e.t0=e.catch(7);case 24:l([]),f(!1);case 26:case"end":return e.stop()}}),e,null,[[7,22]])})),function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function a(e){me(i,r,o,a,u,"next",e)}function u(e){me(i,r,o,a,u,"throw",e)}a(void 0)}))});return function(){return t.apply(this,arguments)}}();return Object(r.useEffect)((function(){o?g():l([])}),[n,o]),0===s.length?Object(r.createElement)("div",{className:"ct-select-input"},Object(r.createElement)("input",{disabled:!0,placeholder:d?Object(a.__)("Loading","blocksy-companion"):Object(a.__)("Invalid API Key...","blocksy-companion")})):Object(r.createElement)(fe,{selectedItem:t||"",onChange:function(e){return i(e)},itemToString:function(e){return e?(s.find((function(t){return t.id===e}))||{}).name:""}},(function(e){var t=e.getInputProps,n=e.getItemProps,o=(e.getLabelProps,e.getMenuProps),i=e.isOpen,u=(e.inputValue,e.highlightedIndex),l=e.selectedItem,p=e.openMenu;return Object(r.createElement)("div",{className:"ct-select-input"},Object(r.createElement)("input",he({},t({onFocus:function(){return p()},onClick:function(){return p()}}),{placeholder:Object(a.__)("Select list...","blocksy-companion"),readOnly:!0})),i&&Object(r.createElement)("div",o({className:"ct-select-dropdown"}),s.map((function(e,t){return Object(r.createElement)("div",n({key:e.id,index:t,item:e.id,className:c()("ct-select-dropdown-item",{active:u===t,selected:l===e.id})}),e.name)}))))}))};function be(e,t,n,r,o,i,a){try{var u=e[i](a),c=u.value}catch(e){return void n(e)}u.done?t(c):Promise.resolve(c).then(r,o)}function we(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,o=!1,i=void 0;try{for(var a,u=e[Symbol.iterator]();!(r=(a=u.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==u.return||u.return()}finally{if(o)throw i}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return Ie(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Ie(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ie(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var Oe=function(e){var t=e.extension,n=e.isEditingCredentials,o=e.setIsEditingCredentials,i=e.onCredentialsValidated,u=we(Object(r.useState)(t.data.provider),2),s=u[0],l=u[1],p=we(Object(r.useState)(t.data.api_key),2),d=p[0],f=p[1],h=we(Object(r.useState)(t.data.list_id),2),m=h[0],v=h[1],g=we(Object(r.useState)(!1),2),y=g[0],b=g[1],w=we(Object(r.useState)(!1),2),I=w[0],O=w[1],S=function(){var e,t=(e=regeneratorRuntime.mark((function e(){var t,n,r;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return(t=new FormData).append("provider",s),t.append("api_key",d),t.append("list_id",m),t.append("action","blocksy_ext_newsletter_subscribe_maybe_save_credentials"),b(!0),e.prev=6,e.next=9,fetch(ctDashboardLocalizations.ajax_url,{method:"POST",body:t});case 9:if(200!==(n=e.sent).status){e.next=15;break}return e.next=13,n.json();case 13:(r=e.sent).success&&"api_key_invalid"!==r.data.result&&(i(),O(!1));case 15:O(!0),e.next=21;break;case 18:e.prev=18,e.t0=e.catch(6),O(!0);case 21:return e.next=23,new Promise((function(e){return setTimeout((function(){return e()}),1e3)}));case 23:b(!1);case 24:case"end":return e.stop()}}),e,null,[[6,18]])})),function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function a(e){be(i,r,o,a,u,"next",e)}function u(e){be(i,r,o,a,u,"throw",e)}a(void 0)}))});return function(){return t.apply(this,arguments)}}();return Object(r.createElement)(H,{items:n,onDismiss:function(){return o(!1)},className:"ct-mailchimp-modal",render:function(){return Object(r.createElement)("div",{className:c()("ct-modal-content",{"ct-key-invalid":I})},Object(r.createElement)("h2",null,Object(a.__)("API Credentials","blocksy-companion")),Object(r.createElement)("p",{dangerouslySetInnerHTML:{__html:Object(a.__)("Enter your Newsletter provider API credentials in the form below.","blocksy-companion")}}),Object(r.createElement)("div",{className:"ct-newsletter-select-provider"},Object(r.createElement)(r.Fragment,null,Object(r.createElement)("h4",null,Object(a.__)("Select Provider","blocksy-companion")),Object(r.createElement)(M.Select,{onChange:function(e){l(e)},option:{placeholder:Object(a.__)("Pick Mailing Service","blocksy-companion"),choices:[{key:"mailchimp",value:"Mailchimp"},{key:"mailerlite",value:"Mailerlite"}]},value:s})),!ctDashboardLocalizations.plugin_data.is_pro&&"mailchimp"!==s&&Object(r.createElement)("p",{dangerouslySetInnerHTML:{__html:Object(a.sprintf)(Object(a.__)("This option is available only in Blocksy premium %sversion%s.","blocksy-companion"),'<a target="_blank" href="https://creativethemes.com/blocksy/pricing/">',"</a>")}}),"mailchimp"===s&&Object(r.createElement)("p",{dangerouslySetInnerHTML:{__html:Object(a.sprintf)(Object(a.__)("More info on how to generate an API key for Mailchimp can be found %shere%s.","blocksy-companion"),'<a target="_blank" href="https://mailchimp.com/help/about-api-keys/">',"</a>")}}),ctDashboardLocalizations.plugin_data.is_pro&&"mailerlite"===s&&Object(r.createElement)("p",{dangerouslySetInnerHTML:{__html:Object(a.sprintf)(Object(a.__)("More info on how to generate an API key for Mailerlite can be found %shere%s. Please note that we require at least one group to be created in your account for the integration to work. More info on how to create a group %shere%s.","blocksy-companion"),'<a target="_blank" href="https://www.mailerlite.com/help/where-to-find-the-mailerlite-api-key-and-documentation">',"</a>",'<a target="_blank" href="https://www.mailerlite.com/help/how-to-create-and-use-groups">',"</a>")}})),("mailchimp"===s||ctDashboardLocalizations.plugin_data.is_pro)&&Object(r.createElement)("div",{className:"mailchimp-credentials"},Object(r.createElement)("section",null,Object(r.createElement)("label",null,Object(a.__)("API Key","blocksy-companion")),Object(r.createElement)("div",{className:"ct-option-input"},Object(r.createElement)("input",{type:"text",onChange:function(e){var t=e.target.value;return f(t)},value:d||""}))),Object(r.createElement)("section",null,Object(r.createElement)("label",null,Object(a.__)("List ID","blocksy-companion")),Object(r.createElement)(ye,{listId:m,onChange:function(e){return v(e)},provider:s,apiKey:d})),Object(r.createElement)("section",null,Object(r.createElement)("label",null," "),Object(r.createElement)("button",{className:"ct-button","data-button":"blue",disabled:!d||!m||y,onClick:function(){return S()}},y?Object(a.__)("Loading...","blocksy-companion"):t.__object?Object(a.__)("Save Settings","blocksy-companion"):Object(a.__)("Activate","blocksy-companion")))))}})};function Se(e,t,n,r,o,i,a){try{var u=e[i](a),c=u.value}catch(e){return void n(e)}u.done?t(c):Promise.resolve(c).then(r,o)}function xe(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function a(e){Se(i,r,o,a,u,"next",e)}function u(e){Se(i,r,o,a,u,"throw",e)}a(void 0)}))}}function Ee(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,o=!1,i=void 0;try{for(var a,u=e[Symbol.iterator]();!(r=(a=u.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==u.return||u.return()}finally{if(o)throw i}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return je(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return je(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function je(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var _e=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){},n=Object(r.useState)(!1),o=Ee(n,2),i=o[0],u=o[1],c=Object(r.useState)(!1),s=Ee(c,2),l=s[0],p=s[1],d=function(){var n=xe(regeneratorRuntime.mark((function n(){var r;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return(r=new FormData).append("ext",e.name),r.append("action",e.__object?"blocksy_extension_deactivate":"blocksy_extension_activate"),u(!0),n.prev=4,n.next=7,fetch(ctDashboardLocalizations.ajax_url,{method:"POST",body:r});case 7:t(),n.next=12;break;case 10:n.prev=10,n.t0=n.catch(4);case 12:u(!1);case 13:case"end":return n.stop()}}),n,null,[[4,10]])})));return function(){return n.apply(this,arguments)}}(),f=function(){e.__object||e.data.api_key?d():p(!0)};return[i,f,Object(r.createElement)(r.Fragment,null,e.__object&&e.data.api_key&&Object(r.createElement)("button",{className:"ct-button ct-config-btn","data-button":"white",title:"Edit Credentials",onClick:function(){return p(!0)}},Object(a.__)("Configure","blocksy-companion")),Object(r.createElement)(Oe,{isEditingCredentials:l,setIsEditingCredentials:p,extension:e,onCredentialsValidated:function(){e.__object||d(),p(!1)}}))]};function Ce(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,o=!1,i=void 0;try{for(var a,u=e[Symbol.iterator]();!(r=(a=u.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==u.return||u.return()}finally{if(o)throw i}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return ke(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ke(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ke(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var Pe=function(e){var t=e.extension,n=e.onExtsSync,o=Ce(_e(t,(function(){n()})),3),i=o[0],u=o[1],s=o[2],l=Ce(L(t),2),p=l[0],d=l[1];return Object(r.createElement)("li",{className:c()({active:!!t.__object})},Object(r.createElement)("h4",{className:"ct-extension-title"},t.config.name,i&&Object(r.createElement)("svg",{width:"15",height:"15",viewBox:"0 0 100 100"},Object(r.createElement)("g",{transform:"translate(50,50)"},Object(r.createElement)("g",{transform:"scale(1)"},Object(r.createElement)("circle",{cx:"0",cy:"0",r:"50",fill:"#687c93"}),Object(r.createElement)("circle",{cx:"0",cy:"-26",r:"12",fill:"#ffffff",transform:"rotate(161.634)"},Object(r.createElement)("animateTransform",{attributeName:"transform",type:"rotate",calcMode:"linear",values:"0 0 0;360 0 0",keyTimes:"0;1",dur:"1s",begin:"0s",repeatCount:"indefinite"})))))),t.config.description&&Object(r.createElement)("div",{className:"ct-extension-description"},t.config.description),Object(r.createElement)("div",{className:"ct-extension-actions"},Object(r.createElement)("button",{className:c()(t.__object?"ct-button":"ct-button-primary"),"data-button":"white",disabled:i,onClick:function(){return u()}},t.__object?Object(a.__)("Deactivate","blocksy-companion"):Object(a.__)("Activate","blocksy-companion")),s,t.readme&&Object(r.createElement)("button",{onClick:function(){return p()},"data-button":"white",className:"ct-minimal-button ct-instruction"},Object(r.createElement)("svg",{width:"16",height:"16",viewBox:"0 0 24 24"},Object(r.createElement)("path",{d:"M12,2C6.477,2,2,6.477,2,12s4.477,10,10,10s10-4.477,10-10S17.523,2,12,2z M12,17L12,17c-0.552,0-1-0.448-1-1v-4 c0-0.552,0.448-1,1-1h0c0.552,0,1,0.448,1,1v4C13,16.552,12.552,17,12,17z M12.5,9h-1C11.224,9,11,8.776,11,8.5v-1 C11,7.224,11.224,7,11.5,7h1C12.776,7,13,7.224,13,7.5v1C13,8.776,12.776,9,12.5,9z"})))),d)};i.a.on("ct:extensions:card",(function(e){var t=e.CustomComponent;"newsletter-subscribe"===e.extension.name&&(t.extension=Pe)}))}]);
|
1 |
+
/*! For license information please see main.js.LICENSE.txt */
|
2 |
+
(()=>{var e={184:(e,t)=>{var n;!function(){"use strict";var r={}.hasOwnProperty;function o(){for(var e=[],t=0;t<arguments.length;t++){var n=arguments[t];if(n){var i=typeof n;if("string"===i||"number"===i)e.push(n);else if(Array.isArray(n)&&n.length){var a=o.apply(null,n);a&&e.push(a)}else if("object"===i)for(var s in n)r.call(n,s)&&n[s]&&e.push(s)}}return e.join(" ")}e.exports?(o.default=o,e.exports=o):void 0===(n=function(){return o}.apply(t,[]))||(e.exports=n)}()},172:(e,t,n)=>{var r,o,i=n(760),a=n(529),s=(o=[],{activateTrap:function(e){if(o.length>0){var t=o[o.length-1];t!==e&&t.pause()}var n=o.indexOf(e);-1===n||o.splice(n,1),o.push(e)},deactivateTrap:function(e){var t=o.indexOf(e);-1!==t&&o.splice(t,1),o.length>0&&o[o.length-1].unpause()}});function u(e){return setTimeout(e,0)}e.exports=function(e,t){var n=document,o="string"==typeof e?n.querySelector(e):e,l=a({returnFocusOnDeactivate:!0,escapeDeactivates:!0},t),c={firstTabbableNode:null,lastTabbableNode:null,nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1},p={activate:function(e){if(!c.active){w(),c.active=!0,c.paused=!1,c.nodeFocusedBeforeActivation=n.activeElement;var t=e&&e.onActivate?e.onActivate:l.onActivate;return t&&t(),f(),p}},deactivate:d,pause:function(){!c.paused&&c.active&&(c.paused=!0,h())},unpause:function(){c.paused&&c.active&&(c.paused=!1,w(),f())}};return p;function d(e){if(c.active){clearTimeout(r),h(),c.active=!1,c.paused=!1,s.deactivateTrap(p);var t=e&&void 0!==e.onDeactivate?e.onDeactivate:l.onDeactivate;return t&&t(),(e&&void 0!==e.returnFocus?e.returnFocus:l.returnFocusOnDeactivate)&&u((function(){var e;S((e=c.nodeFocusedBeforeActivation,m("setReturnFocus")||e))})),p}}function f(){if(c.active)return s.activateTrap(p),r=u((function(){S(v())})),n.addEventListener("focusin",y,!0),n.addEventListener("mousedown",g,{capture:!0,passive:!1}),n.addEventListener("touchstart",g,{capture:!0,passive:!1}),n.addEventListener("click",I,{capture:!0,passive:!1}),n.addEventListener("keydown",b,{capture:!0,passive:!1}),p}function h(){if(c.active)return n.removeEventListener("focusin",y,!0),n.removeEventListener("mousedown",g,!0),n.removeEventListener("touchstart",g,!0),n.removeEventListener("click",I,!0),n.removeEventListener("keydown",b,!0),p}function m(e){var t=l[e],r=t;if(!t)return null;if("string"==typeof t&&!(r=n.querySelector(t)))throw new Error("`"+e+"` refers to no known node");if("function"==typeof t&&!(r=t()))throw new Error("`"+e+"` did not return a node");return r}function v(){var e;if(!(e=null!==m("initialFocus")?m("initialFocus"):o.contains(n.activeElement)?n.activeElement:c.firstTabbableNode||m("fallbackFocus")))throw new Error("Your focus-trap needs to have at least one focusable element");return e}function g(e){o.contains(e.target)||(l.clickOutsideDeactivates?d({returnFocus:!i.isFocusable(e.target)}):l.allowOutsideClick&&l.allowOutsideClick(e)||e.preventDefault())}function y(e){o.contains(e.target)||e.target instanceof Document||(e.stopImmediatePropagation(),S(c.mostRecentlyFocusedNode||v()))}function b(e){if(!1!==l.escapeDeactivates&&function(e){return"Escape"===e.key||"Esc"===e.key||27===e.keyCode}(e))return e.preventDefault(),void d();(function(e){return"Tab"===e.key||9===e.keyCode})(e)&&function(e){if(w(),e.shiftKey&&e.target===c.firstTabbableNode)return e.preventDefault(),void S(c.lastTabbableNode);e.shiftKey||e.target!==c.lastTabbableNode||(e.preventDefault(),S(c.firstTabbableNode))}(e)}function I(e){l.clickOutsideDeactivates||o.contains(e.target)||l.allowOutsideClick&&l.allowOutsideClick(e)||(e.preventDefault(),e.stopImmediatePropagation())}function w(){var e=i(o);c.firstTabbableNode=e[0]||v(),c.lastTabbableNode=e[e.length-1]||v()}function S(e){e!==n.activeElement&&(e&&e.focus?(e.focus(),c.mostRecentlyFocusedNode=e,function(e){return e.tagName&&"input"===e.tagName.toLowerCase()&&"function"==typeof e.select}(e)&&e.select()):S(v()))}}},703:(e,t,n)=>{"use strict";var r=n(414);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,i,a){if(a!==r){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function t(){return e}e.isRequired=e;var 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:i,resetWarningCache:o};return n.PropTypes=n,n}},697:(e,t,n)=>{e.exports=n(703)()},414:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},921:(e,t)=>{"use strict";var n="function"==typeof Symbol&&Symbol.for;n&&Symbol.for("react.element"),n&&Symbol.for("react.portal"),n&&Symbol.for("react.fragment"),n&&Symbol.for("react.strict_mode"),n&&Symbol.for("react.profiler"),n&&Symbol.for("react.provider"),n&&Symbol.for("react.context"),n&&Symbol.for("react.async_mode"),n&&Symbol.for("react.concurrent_mode"),n&&Symbol.for("react.forward_ref"),n&&Symbol.for("react.suspense"),n&&Symbol.for("react.suspense_list"),n&&Symbol.for("react.memo"),n&&Symbol.for("react.lazy"),n&&Symbol.for("react.block"),n&&Symbol.for("react.fundamental"),n&&Symbol.for("react.responder"),n&&Symbol.for("react.scope")},864:(e,t,n)=>{"use strict";n(921)},760:e=>{var t=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'],n=t.join(","),r="undefined"==typeof Element?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector;function o(e,t){t=t||{};var o,a,s,c=[],p=[],d=e.querySelectorAll(n);for(t.includeContainer&&r.call(e,n)&&(d=Array.prototype.slice.apply(d)).unshift(e),o=0;o<d.length;o++)i(a=d[o])&&(0===(s=u(a))?c.push(a):p.push({documentOrder:o,tabIndex:s,node:a}));return p.sort(l).map((function(e){return e.node})).concat(c)}function i(e){return!(!a(e)||function(e){return function(e){return c(e)&&"radio"===e.type}(e)&&!function(e){if(!e.name)return!0;var t=function(e){for(var t=0;t<e.length;t++)if(e[t].checked)return e[t]}(e.ownerDocument.querySelectorAll('input[type="radio"][name="'+e.name+'"]'));return!t||t===e}(e)}(e)||u(e)<0)}function a(e){return!(e.disabled||function(e){return c(e)&&"hidden"===e.type}(e)||function(e){return null===e.offsetParent||"hidden"===getComputedStyle(e).visibility}(e))}o.isTabbable=function(e){if(!e)throw new Error("No node provided");return!1!==r.call(e,n)&&i(e)},o.isFocusable=function(e){if(!e)throw new Error("No node provided");return!1!==r.call(e,s)&&a(e)};var s=t.concat("iframe").join(",");function u(e){var t=parseInt(e.getAttribute("tabindex"),10);return isNaN(t)?function(e){return"true"===e.contentEditable}(e)?0:e.tabIndex:t}function l(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex}function c(e){return"INPUT"===e.tagName}e.exports=o},529:e=>{e.exports=function(){for(var e={},n=0;n<arguments.length;n++){var r=arguments[n];for(var o in r)t.call(r,o)&&(e[o]=r[o])}return e};var t=Object.prototype.hasOwnProperty}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r](i,i.exports,n),i.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";const e=window.wp.element,t=window.ctEvents;var r=n.n(t);const o=window.wp.i18n;var i=n(184),a=n.n(i);const s=window.React;var u=n.n(s),l=n(697),c=n.n(l);function p(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function d(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var f=function(e){return e.initialState,e.getInitialState,e.refs,e.getRefs,e.didMount,e.didUpdate,e.willUnmount,e.getSnapshotBeforeUpdate,e.shouldUpdate,e.render,function(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}(e,["initialState","getInitialState","refs","getRefs","didMount","didUpdate","willUnmount","getSnapshotBeforeUpdate","shouldUpdate","render"])},h=function(e){function t(){var n,r;p(this,t);for(var o=arguments.length,i=Array(o),a=0;a<o;a++)i[a]=arguments[a];return n=r=d(this,e.call.apply(e,[this].concat(i))),m.call(r),d(r,n)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),t.prototype.getArgs=function(){var e=this.state,t=this.props,n=this._setState,r=this._forceUpdate,o=this._refs;return{state:e,props:f(t),refs:o,setState:n,forceUpdate:r}},t.prototype.componentDidMount=function(){this.props.didMount&&this.props.didMount(this.getArgs())},t.prototype.shouldComponentUpdate=function(e,t){return!this.props.shouldUpdate||this.props.shouldUpdate({props:this.props,state:this.state,nextProps:f(e),nextState:t})},t.prototype.componentWillUnmount=function(){this.props.willUnmount&&this.props.willUnmount({state:this.state,props:f(this.props),refs:this._refs})},t.prototype.componentDidUpdate=function(e,t,n){this.props.didUpdate&&this.props.didUpdate(Object.assign(this.getArgs(),{prevProps:f(e),prevState:t}),n)},t.prototype.getSnapshotBeforeUpdate=function(e,t){return this.props.getSnapshotBeforeUpdate?this.props.getSnapshotBeforeUpdate(Object.assign(this.getArgs(),{prevProps:f(e),prevState:t})):null},t.prototype.render=function(){var e=this.props,t=e.children,n=e.render;return n?n(this.getArgs()):"function"==typeof t?t(this.getArgs()):t||null},t}(u().Component);h.defaultProps={getInitialState:function(){},getRefs:function(){return{}}};var m=function(){var e=this;this.state=this.props.initialState||this.props.getInitialState(this.props),this._refs=this.props.refs||this.props.getRefs(this.getArgs()),this._setState=function(){return e.setState.apply(e,arguments)},this._forceUpdate=function(){return e.forceUpdate.apply(e,arguments)}};const v=h,g=function(t){var n=t.children,r=t.container,o=void 0===r?document.body:r,i=t.type,a=void 0===i?"reach-portal":i;return(0,e.createElement)(v,{getRefs:function(){return{node:null}},didMount:function(e){var t=e.refs,n=e.forceUpdate,r=o.hasOwnProperty("current")?o.current:o;t.node=document.createElement(a),r.appendChild(t.node),n()},willUnmount:function(e){var t=e.refs.node,n=o.hasOwnProperty("current")?o.current:o;n&&n.removeChild(t)},render:function(t){var r=t.refs.node;return r?(0,e.createPortal)(n,r):null}})};var y=function(e,t){return function(n){if(e&&e(n),!n.defaultPrevented)return t(n)}},b=n(172),I=n.n(b);function w(){return w=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},w.apply(this,arguments)}function S(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var E=function(){},x=function(){},_=function(e){var t=e.refs;t.trap.deactivate(),t.disposeAriaHider()},O=React.createContext(),k=React.forwardRef((function(t,n){var r=t.container,o=t.isOpen,i=void 0===o||o,a=t.onDismiss,s=void 0===a?E:a,u=t.initialFocusRef,l=t.onClick,c=t.onKeyDown,p=S(t,["container","isOpen","onDismiss","initialFocusRef","onClick","onKeyDown"]);return(0,e.createElement)(v,{didMount:x},i?(0,e.createElement)(g,{container:r,"data-reach-dialog-wrapper":!0},(0,e.createElement)(v,{refs:{overlayNode:null,contentNode:null},didMount:function(e){!function(e,t){var n,r,o;e.disposeAriaHider=(n=e.overlayNode,r=[],o=[],Array.prototype.forEach.call(document.querySelectorAll("body > *"),(function(e){if(e!==n.parentNode){var t=e.getAttribute("aria-hidden");null!==t&&"false"!==t||(r.push(t),o.push(e),e.setAttribute("aria-hidden","true"))}})),function(){o.forEach((function(e,t){var n=r[t];null===n?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",n)}))}),e.trap=I()(e.overlayNode,{initialFocus:t?function(){return t.current}:void 0,fallbackFocus:e.contentNode,escapeDeactivates:!1,clickOutsideDeactivates:!1})}(e.refs,u)},willUnmount:_},(function(t){var r=t.refs;return(0,e.createElement)(O.Provider,{value:function(e){return r.contentNode=e}},(0,e.createElement)("div",w({"data-reach-dialog-overlay":!0,onClick:y(l,(function(e){e.stopPropagation(),s()})),onKeyDown:y(c,(function(e){"Escape"===e.key&&(e.stopPropagation(),s())})),ref:function(e){r.overlayNode=e,n&&n(e)}},p)))}))):null)}));k.propTypes={initialFocusRef:function(){}};var C=function(e){return e.stopPropagation()},P=React.forwardRef((function(t,n){var r=t.onClick,o=(t.onKeyDown,S(t,["onClick","onKeyDown"]));return(0,e.createElement)(O.Consumer,null,(function(t){return(0,e.createElement)("div",w({"aria-modal":"true","data-reach-dialog-content":!0,tabIndex:"-1",onClick:y(r,C),ref:function(e){t(e),n&&n(e)}},o))}))}));const A=window.blocksyOptions;var D=function(e){return!!e};const M=function(t){var n=t.items,r=t.isVisible,o=void 0===r?D:r,i=t.render,s=t.className,u=t.onDismiss;return(0,e.createElement)(A.Transition,{items:n,onStart:function(){return document.body.classList[o(n)?"add":"remove"]("ct-dashboard-overlay-open")},config:{duration:200},from:{opacity:0,y:-10},enter:{opacity:1,y:0},leave:{opacity:0,y:10}},(function(t){return o(t)&&function(n){return(0,e.createElement)(k,{style:{opacity:n.opacity},container:document.querySelector("#wpbody"),onDismiss:function(){return u()}},(0,e.createElement)(P,{className:a()("ct-admin-modal",s),style:{transform:"translate3d(0px, ".concat(n.y,"px, 0px)")}},(0,e.createElement)("button",{className:"close-button",onClick:function(){return u()}},"×"),i(t,n)))}}))};function T(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}const H=function(t){var n,r,o=(n=(0,e.useState)(!1),r=2,function(e){if(Array.isArray(e))return e}(n)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==s.return||s.return()}finally{if(o)throw i}}return n}}(n,r)||function(e,t){if(e){if("string"==typeof e)return T(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?T(e,t):void 0}}(n,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),i=o[0],a=o[1];return[function(){return a(!0)},(0,e.createElement)(M,{items:i,onDismiss:function(){return a(!1)},render:function(){return(0,e.createElement)("div",{className:"ct-modal-content",dangerouslySetInnerHTML:{__html:t.readme}})}})]};function j(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}function R(){return R=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},R.apply(this,arguments)}function N(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function L(e){return null!=e&&"object"==typeof e&&1===e.nodeType}function U(e,t){return(!t||"hidden"!==e)&&"visible"!==e&&"clip"!==e}function K(e,t){if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){var n=getComputedStyle(e,null);return U(n.overflowY,t)||U(n.overflowX,t)||function(e){var t=function(e){return e.ownerDocument&&e.ownerDocument.defaultView?e.ownerDocument.defaultView.frameElement:null}(e);return!!t&&(t.clientHeight<e.scrollHeight||t.clientWidth<e.scrollWidth)}(e)}return!1}function F(e,t,n,r,o,i,a,s){return i<e&&a>t||i>e&&a<t?0:i<=e&&s<=n||a>=t&&s>=n?i-e-r:a>t&&s<n||i<e&&s>n?a-t+o:0}n(864);var V=0;function B(e){return"function"==typeof e?e:W}function W(){}function z(e,t){if(null!==e){var n=function(e,t){var n=t.scrollMode,r=t.block,o=t.inline,i=t.boundary,a=t.skipOverflowHiddenElements,s="function"==typeof i?i:function(e){return e!==i};if(!L(e))throw new TypeError("Invalid target");for(var u=document.scrollingElement||document.documentElement,l=[],c=e;L(c)&&s(c);){if((c=c.parentNode)===u){l.push(c);break}c===document.body&&K(c)&&!K(document.documentElement)||K(c,a)&&l.push(c)}for(var p=window.visualViewport?visualViewport.width:innerWidth,d=window.visualViewport?visualViewport.height:innerHeight,f=window.scrollX||pageXOffset,h=window.scrollY||pageYOffset,m=e.getBoundingClientRect(),v=m.height,g=m.width,y=m.top,b=m.right,I=m.bottom,w=m.left,S="start"===r||"nearest"===r?y:"end"===r?I:y+v/2,E="center"===o?w+g/2:"end"===o?b:w,x=[],_=0;_<l.length;_++){var O=l[_],k=O.getBoundingClientRect(),C=k.height,P=k.width,A=k.top,D=k.right,M=k.bottom,T=k.left;if("if-needed"===n&&y>=0&&w>=0&&I<=d&&b<=p&&y>=A&&I<=M&&w>=T&&b<=D)return x;var H=getComputedStyle(O),j=parseInt(H.borderLeftWidth,10),R=parseInt(H.borderTopWidth,10),N=parseInt(H.borderRightWidth,10),U=parseInt(H.borderBottomWidth,10),V=0,B=0,W="offsetWidth"in O?O.offsetWidth-O.clientWidth-j-N:0,z="offsetHeight"in O?O.offsetHeight-O.clientHeight-R-U:0;if(u===O)V="start"===r?S:"end"===r?S-d:"nearest"===r?F(h,h+d,d,R,U,h+S,h+S+v,v):S-d/2,B="start"===o?E:"center"===o?E-p/2:"end"===o?E-p:F(f,f+p,p,j,N,f+E,f+E+g,g),V=Math.max(0,V+h),B=Math.max(0,B+f);else{V="start"===r?S-A-R:"end"===r?S-M+U+z:"nearest"===r?F(A,M,C,R,U+z,S,S+v,v):S-(A+C/2)+z/2,B="start"===o?E-T-j:"center"===o?E-(T+P/2)+W/2:"end"===o?E-D+N+W:F(T,D,P,j,N+W,E,E+g,g);var q=O.scrollLeft,Y=O.scrollTop;S+=Y-(V=Math.max(0,Math.min(Y+V,O.scrollHeight-C+z))),E+=q-(B=Math.max(0,Math.min(q+B,O.scrollWidth-P+W)))}x.push({el:O,top:V,left:B})}return x}(e,{boundary:t,block:"nearest",scrollMode:"if-needed"});n.forEach((function(e){var t=e.el,n=e.top,r=e.left;t.scrollTop=n,t.scrollLeft=r}))}}function q(e,t){return e===t||e.contains&&e.contains(t)}function Y(e,t){var n;function r(){n&&clearTimeout(n)}function o(){for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];r(),n=setTimeout((function(){n=null,e.apply(void 0,i)}),t)}return o.cancel=r,o}function $(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return t.some((function(t){return t&&t.apply(void 0,[e].concat(r)),e.preventDownshiftDefault||e.hasOwnProperty("nativeEvent")&&e.nativeEvent.preventDownshiftDefault}))}}function X(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){t.forEach((function(t){"function"==typeof t?t(e):t&&(t.current=e)}))}}function G(e){var t=e.isOpen,n=e.selectedItem,r=e.resultCount,o=e.previousResultCount,i=e.itemToString;return t?r?r!==o?r+" result"+(1===r?" is":"s are")+" available, use up and down arrow keys to navigate. Press Enter key to select.":"":"No results are available.":n?i(n):""}function J(e,t){return!(e=Array.isArray(e)?e[0]:e)&&t?t:e}var Q=["highlightedIndex","inputValue","isOpen","selectedItem","type"];function Z(e){void 0===e&&(e={});var t={};return Q.forEach((function(n){e.hasOwnProperty(n)&&(t[n]=e[n])})),t}function ee(e){var t=e.key,n=e.keyCode;return n>=37&&n<=40&&0!==t.indexOf("Arrow")?"Arrow"+t:t}function te(e,t,n){var r=n-1;("number"!=typeof t||t<0||t>=n)&&(t=e>0?-1:r+1);var o=t+e;return o<0?o=r:o>r&&(o=0),o}var ne=Y((function(){re().textContent=""}),500);function re(e){void 0===e&&(e=document);var t=e.getElementById("a11y-status-message");return t||((t=e.createElement("div")).setAttribute("id","a11y-status-message"),t.setAttribute("role","status"),t.setAttribute("aria-live","polite"),t.setAttribute("aria-relevant","additions text"),Object.assign(t.style,{border:"0",clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:"0",position:"absolute",width:"1px"}),e.body.appendChild(t),t)}var oe=Object.freeze({__proto__:null,unknown:0,mouseUp:1,itemMouseEnter:2,keyDownArrowUp:3,keyDownArrowDown:4,keyDownEscape:5,keyDownEnter:6,keyDownHome:7,keyDownEnd:8,clickItem:9,blurInput:10,changeInput:11,keyDownSpaceButton:12,clickButton:13,blurButton:14,controlledPropUpdatedSelectedItem:15,touchEnd:16}),ie=function(){var e=function(e){var t,n;function r(t){var n=e.call(this,t)||this;n.id=n.props.id||"downshift-"+String(V++),n.menuId=n.props.menuId||n.id+"-menu",n.labelId=n.props.labelId||n.id+"-label",n.inputId=n.props.inputId||n.id+"-input",n.getItemId=n.props.getItemId||function(e){return n.id+"-item-"+e},n.input=null,n.items=[],n.itemCount=null,n.previousResultCount=0,n.timeoutIds=[],n.internalSetTimeout=function(e,t){var r=setTimeout((function(){n.timeoutIds=n.timeoutIds.filter((function(e){return e!==r})),e()}),t);n.timeoutIds.push(r)},n.setItemCount=function(e){n.itemCount=e},n.unsetItemCount=function(){n.itemCount=null},n.setHighlightedIndex=function(e,t){void 0===e&&(e=n.props.defaultHighlightedIndex),void 0===t&&(t={}),t=Z(t),n.internalSetState(R({highlightedIndex:e},t))},n.clearSelection=function(e){n.internalSetState({selectedItem:null,inputValue:"",highlightedIndex:n.props.defaultHighlightedIndex,isOpen:n.props.defaultIsOpen},e)},n.selectItem=function(e,t,r){t=Z(t),n.internalSetState(R({isOpen:n.props.defaultIsOpen,highlightedIndex:n.props.defaultHighlightedIndex,selectedItem:e,inputValue:n.props.itemToString(e)},t),r)},n.selectItemAtIndex=function(e,t,r){var o=n.items[e];null!=o&&n.selectItem(o,t,r)},n.selectHighlightedItem=function(e,t){return n.selectItemAtIndex(n.getState().highlightedIndex,e,t)},n.internalSetState=function(e,t){var r,o,i={},a="function"==typeof e;return!a&&e.hasOwnProperty("inputValue")&&n.props.onInputValueChange(e.inputValue,R({},n.getStateAndHelpers(),{},e)),n.setState((function(t){t=n.getState(t);var s=a?e(t):e;s=n.props.stateReducer(t,s),r=s.hasOwnProperty("selectedItem");var u={},l={};return r&&s.selectedItem!==t.selectedItem&&(o=s.selectedItem),s.type=s.type||0,Object.keys(s).forEach((function(e){t[e]!==s[e]&&(i[e]=s[e]),"type"!==e&&(l[e]=s[e],n.isControlledProp(e)||(u[e]=s[e]))})),a&&s.hasOwnProperty("inputValue")&&n.props.onInputValueChange(s.inputValue,R({},n.getStateAndHelpers(),{},s)),u}),(function(){B(t)(),Object.keys(i).length>1&&n.props.onStateChange(i,n.getStateAndHelpers()),r&&n.props.onSelect(e.selectedItem,n.getStateAndHelpers()),void 0!==o&&n.props.onChange(o,n.getStateAndHelpers()),n.props.onUserAction(i,n.getStateAndHelpers())}))},n.rootRef=function(e){return n._rootNode=e},n.getRootProps=function(e,t){var r,o=void 0===e?{}:e,i=o.refKey,a=void 0===i?"ref":i,s=o.ref,u=j(o,["refKey","ref"]),l=(void 0===t?{}:t).suppressRefError,c=void 0!==l&&l;n.getRootProps.called=!0,n.getRootProps.refKey=a,n.getRootProps.suppressRefError=c;var p=n.getState().isOpen;return R(((r={})[a]=X(s,n.rootRef),r.role="combobox",r["aria-expanded"]=p,r["aria-haspopup"]="listbox",r["aria-owns"]=p?n.menuId:null,r["aria-labelledby"]=n.labelId,r),u)},n.keyDownHandlers={ArrowDown:function(e){var t=this;if(e.preventDefault(),this.getState().isOpen){var n=e.shiftKey?5:1;this.moveHighlightedIndex(n,{type:4})}else this.internalSetState({isOpen:!0,type:4},(function(){var e=t.getItemCount();e>0&&t.setHighlightedIndex(te(1,t.getState().highlightedIndex,e),{type:4})}))},ArrowUp:function(e){var t=this;if(e.preventDefault(),this.getState().isOpen){var n=e.shiftKey?-5:-1;this.moveHighlightedIndex(n,{type:3})}else this.internalSetState({isOpen:!0,type:3},(function(){var e=t.getItemCount();e>0&&t.setHighlightedIndex(te(-1,t.getState().highlightedIndex,e),{type:4})}))},Enter:function(e){var t=this.getState(),n=t.isOpen,r=t.highlightedIndex;if(n&&null!=r){e.preventDefault();var o=this.items[r],i=this.getItemNodeFromIndex(r);if(null==o||i&&i.hasAttribute("disabled"))return;this.selectHighlightedItem({type:6})}},Escape:function(e){e.preventDefault(),this.reset({type:5,selectedItem:null,inputValue:""})}},n.buttonKeyDownHandlers=R({},n.keyDownHandlers,{" ":function(e){e.preventDefault(),this.toggleMenu({type:12})}}),n.inputKeyDownHandlers=R({},n.keyDownHandlers,{Home:function(e){this.highlightFirstOrLastIndex(e,!0,{type:7})},End:function(e){this.highlightFirstOrLastIndex(e,!1,{type:8})}}),n.getToggleButtonProps=function(e){var t=void 0===e?{}:e,r=t.onClick,o=(t.onPress,t.onKeyDown),i=t.onKeyUp,a=t.onBlur,s=j(t,["onClick","onPress","onKeyDown","onKeyUp","onBlur"]),u=n.getState().isOpen,l={onClick:$(r,n.buttonHandleClick),onKeyDown:$(o,n.buttonHandleKeyDown),onKeyUp:$(i,n.buttonHandleKeyUp),onBlur:$(a,n.buttonHandleBlur)};return R({type:"button",role:"button","aria-label":u?"close menu":"open menu","aria-haspopup":!0,"data-toggle":!0},s.disabled?{}:l,{},s)},n.buttonHandleKeyUp=function(e){e.preventDefault()},n.buttonHandleKeyDown=function(e){var t=ee(e);n.buttonKeyDownHandlers[t]&&n.buttonKeyDownHandlers[t].call(N(n),e)},n.buttonHandleClick=function(e){e.preventDefault(),n.props.environment.document.activeElement===n.props.environment.document.body&&e.target.focus(),n.internalSetTimeout((function(){return n.toggleMenu({type:13})}))},n.buttonHandleBlur=function(e){var t=e.target;n.internalSetTimeout((function(){n.isMouseDown||null!=n.props.environment.document.activeElement&&n.props.environment.document.activeElement.id===n.inputId||n.props.environment.document.activeElement===t||n.reset({type:14})}))},n.getLabelProps=function(e){return R({htmlFor:n.inputId,id:n.labelId},e)},n.getInputProps=function(e){var t,r=void 0===e?{}:e,o=r.onKeyDown,i=r.onBlur,a=r.onChange,s=r.onInput,u=(r.onChangeText,j(r,["onKeyDown","onBlur","onChange","onInput","onChangeText"])),l={},c=n.getState(),p=c.inputValue,d=c.isOpen,f=c.highlightedIndex;return u.disabled||((t={}).onChange=$(a,s,n.inputHandleChange),t.onKeyDown=$(o,n.inputHandleKeyDown),t.onBlur=$(i,n.inputHandleBlur),l=t),R({"aria-autocomplete":"list","aria-activedescendant":d&&"number"==typeof f&&f>=0?n.getItemId(f):null,"aria-controls":d?n.menuId:null,"aria-labelledby":n.labelId,autoComplete:"off",value:p,id:n.inputId},l,{},u)},n.inputHandleKeyDown=function(e){var t=ee(e);t&&n.inputKeyDownHandlers[t]&&n.inputKeyDownHandlers[t].call(N(n),e)},n.inputHandleChange=function(e){n.internalSetState({type:11,isOpen:!0,inputValue:e.target.value,highlightedIndex:n.props.defaultHighlightedIndex})},n.inputHandleBlur=function(){n.internalSetTimeout((function(){var e=n.props.environment.document&&!!n.props.environment.document.activeElement&&!!n.props.environment.document.activeElement.dataset&&n.props.environment.document.activeElement.dataset.toggle&&n._rootNode&&n._rootNode.contains(n.props.environment.document.activeElement);n.isMouseDown||e||n.reset({type:10})}))},n.menuRef=function(e){n._menuNode=e},n.getMenuProps=function(e,t){var r,o=void 0===e?{}:e,i=o.refKey,a=void 0===i?"ref":i,s=o.ref,u=j(o,["refKey","ref"]),l=(void 0===t?{}:t).suppressRefError,c=void 0!==l&&l;return n.getMenuProps.called=!0,n.getMenuProps.refKey=a,n.getMenuProps.suppressRefError=c,R(((r={})[a]=X(s,n.menuRef),r.role="listbox",r["aria-labelledby"]=u&&u["aria-label"]?null:n.labelId,r.id=n.menuId,r),u)},n.getItemProps=function(e){var t,r=void 0===e?{}:e,o=r.onMouseMove,i=r.onMouseDown,a=r.onClick,s=(r.onPress,r.index),u=r.item,l=void 0===u?void 0:u,c=j(r,["onMouseMove","onMouseDown","onClick","onPress","index","item"]);void 0===s?(n.items.push(l),s=n.items.indexOf(l)):n.items[s]=l;var p=a,d=((t={onMouseMove:$(o,(function(){s!==n.getState().highlightedIndex&&(n.setHighlightedIndex(s,{type:2}),n.avoidScrolling=!0,n.internalSetTimeout((function(){return n.avoidScrolling=!1}),250))})),onMouseDown:$(i,(function(e){e.preventDefault()}))}).onClick=$(p,(function(){n.selectItemAtIndex(s,{type:9})})),t),f=c.disabled?{onMouseDown:d.onMouseDown}:d;return R({id:n.getItemId(s),role:"option","aria-selected":n.getState().highlightedIndex===s},f,{},c)},n.clearItems=function(){n.items=[]},n.reset=function(e,t){void 0===e&&(e={}),e=Z(e),n.internalSetState((function(t){var r=t.selectedItem;return R({isOpen:n.props.defaultIsOpen,highlightedIndex:n.props.defaultHighlightedIndex,inputValue:n.props.itemToString(r)},e)}),t)},n.toggleMenu=function(e,t){void 0===e&&(e={}),e=Z(e),n.internalSetState((function(t){var r=t.isOpen;return R({isOpen:!r},r&&{highlightedIndex:n.props.defaultHighlightedIndex},{},e)}),(function(){var r=n.getState(),o=r.isOpen,i=r.highlightedIndex;o&&n.getItemCount()>0&&"number"==typeof i&&n.setHighlightedIndex(i,e),B(t)()}))},n.openMenu=function(e){n.internalSetState({isOpen:!0},e)},n.closeMenu=function(e){n.internalSetState({isOpen:!1},e)},n.updateStatus=Y((function(){var e=n.getState(),t=n.items[e.highlightedIndex],r=n.getItemCount(),o=n.props.getA11yStatusMessage(R({itemToString:n.props.itemToString,previousResultCount:n.previousResultCount,resultCount:r,highlightedItem:t},e));n.previousResultCount=r,function(e,t){var n=re(t);e&&(n.textContent=e,ne())}(o,n.props.environment.document)}),200);var r=n.props,o=r.defaultHighlightedIndex,i=r.initialHighlightedIndex,a=void 0===i?o:i,s=r.defaultIsOpen,u=r.initialIsOpen,l=void 0===u?s:u,c=r.initialInputValue,p=void 0===c?"":c,d=r.initialSelectedItem,f=void 0===d?null:d,h=n.getState({highlightedIndex:a,isOpen:l,inputValue:p,selectedItem:f});return null!=h.selectedItem&&void 0===n.props.initialInputValue&&(h.inputValue=n.props.itemToString(h.selectedItem)),n.state=h,n}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var o=r.prototype;return o.internalClearTimeouts=function(){this.timeoutIds.forEach((function(e){clearTimeout(e)})),this.timeoutIds=[]},o.getState=function(e){var t=this;return void 0===e&&(e=this.state),Object.keys(e).reduce((function(n,r){return n[r]=t.isControlledProp(r)?t.props[r]:e[r],n}),{})},o.isControlledProp=function(e){return void 0!==this.props[e]},o.getItemCount=function(){var e=this.items.length;return null!=this.itemCount?e=this.itemCount:void 0!==this.props.itemCount&&(e=this.props.itemCount),e},o.getItemNodeFromIndex=function(e){return this.props.environment.document.getElementById(this.getItemId(e))},o.scrollHighlightedItemIntoView=function(){var e=this.getItemNodeFromIndex(this.getState().highlightedIndex);this.props.scrollIntoView(e,this._menuNode)},o.moveHighlightedIndex=function(e,t){var n=this.getItemCount();if(n>0){var r=te(e,this.getState().highlightedIndex,n);this.setHighlightedIndex(r,t)}},o.highlightFirstOrLastIndex=function(e,t,n){var r=this.getItemCount()-1;r<0||!this.getState().isOpen||(e.preventDefault(),this.setHighlightedIndex(t?0:r,n))},o.getStateAndHelpers=function(){var e=this.getState(),t=e.highlightedIndex,n=e.inputValue,r=e.selectedItem,o=e.isOpen,i=this.props.itemToString,a=this.id,s=this.getRootProps,u=this.getToggleButtonProps,l=this.getLabelProps,c=this.getMenuProps,p=this.getInputProps,d=this.getItemProps,f=this.openMenu,h=this.closeMenu,m=this.toggleMenu,v=this.selectItem,g=this.selectItemAtIndex,y=this.selectHighlightedItem,b=this.setHighlightedIndex,I=this.clearSelection,w=this.clearItems;return{getRootProps:s,getToggleButtonProps:u,getLabelProps:l,getMenuProps:c,getInputProps:p,getItemProps:d,reset:this.reset,openMenu:f,closeMenu:h,toggleMenu:m,selectItem:v,selectItemAtIndex:g,selectHighlightedItem:y,setHighlightedIndex:b,clearSelection:I,clearItems:w,setItemCount:this.setItemCount,unsetItemCount:this.unsetItemCount,setState:this.internalSetState,itemToString:i,id:a,highlightedIndex:t,inputValue:n,isOpen:o,selectedItem:r}},o.componentDidMount=function(){var e=this,t=function(t,n){void 0===n&&(n=!0);var r=e.props.environment.document;return[e._rootNode,e._menuNode].some((function(e){return e&&(q(e,t)||n&&q(e,r.activeElement))}))},n=function(){e.isMouseDown=!0},r=function(n){e.isMouseDown=!1,!t(n.target)&&e.getState().isOpen&&e.reset({type:1},(function(){return e.props.onOuterClick(e.getStateAndHelpers())}))},o=function(){e.isTouchMove=!1},i=function(){e.isTouchMove=!0},a=function(n){var r=t(n.target,!1);e.isTouchMove||r||!e.getState().isOpen||e.reset({type:16},(function(){return e.props.onOuterClick(e.getStateAndHelpers())}))},s=this.props.environment;s.addEventListener("mousedown",n),s.addEventListener("mouseup",r),s.addEventListener("touchstart",o),s.addEventListener("touchmove",i),s.addEventListener("touchend",a),this.cleanup=function(){e.internalClearTimeouts(),e.updateStatus.cancel(),s.removeEventListener("mousedown",n),s.removeEventListener("mouseup",r),s.removeEventListener("touchstart",o),s.removeEventListener("touchmove",i),s.removeEventListener("touchend",a)}},o.shouldScroll=function(e,t){var n=(void 0===this.props.highlightedIndex?this.getState():this.props).highlightedIndex,r=(void 0===t.highlightedIndex?e:t).highlightedIndex;return n&&this.getState().isOpen&&!e.isOpen||n!==r},o.componentDidUpdate=function(e,t){this.isControlledProp("selectedItem")&&this.props.selectedItemChanged(e.selectedItem,this.props.selectedItem)&&this.internalSetState({type:15,inputValue:this.props.itemToString(this.props.selectedItem)}),!this.avoidScrolling&&this.shouldScroll(t,e)&&this.scrollHighlightedItemIntoView(),this.updateStatus()},o.componentWillUnmount=function(){this.cleanup()},o.render=function(){var e=J(this.props.children,W);this.clearItems(),this.getRootProps.called=!1,this.getRootProps.refKey=void 0,this.getRootProps.suppressRefError=void 0,this.getMenuProps.called=!1,this.getMenuProps.refKey=void 0,this.getMenuProps.suppressRefError=void 0,this.getLabelProps.called=!1,this.getInputProps.called=!1;var t=J(e(this.getStateAndHelpers()));return t?this.getRootProps.called||this.props.suppressRefError?t:function(e){return"string"==typeof e.type}(t)?(0,s.cloneElement)(t,this.getRootProps(function(e){return e.props}(t))):void 0:null},r}(s.Component);return e.defaultProps={defaultHighlightedIndex:null,defaultIsOpen:!1,getA11yStatusMessage:G,itemToString:function(e){return null==e?"":String(e)},onStateChange:W,onInputValueChange:W,onUserAction:W,onChange:W,onSelect:W,onOuterClick:W,selectedItemChanged:function(e,t){return e!==t},environment:"undefined"==typeof window?{}:window,stateReducer:function(e,t){return t},suppressRefError:!1,scrollIntoView:z},e.stateChangeTypes=oe,e}();c().array.isRequired,c().func,c().func,c().func,c().bool,c().number,c().number,c().number,c().bool,c().bool,c().bool,c().any,c().any,c().any,c().string,c().string,c().string,c().func,c().string,c().func,c().func,c().func,c().func,c().func,c().shape({addEventListener:c().func,removeEventListener:c().func,document:c().shape({getElementById:c().func,activeElement:c().any,body:c().any})}),"undefined"==typeof window||window;const ae=ie;function se(){return se=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},se.apply(this,arguments)}function ue(e,t,n,r,o,i,a){try{var s=e[i](a),u=s.value}catch(e){return void n(e)}s.done?t(u):Promise.resolve(u).then(r,o)}function le(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==s.return||s.return()}finally{if(o)throw i}}return n}}(e,t)||function(e,t){if(e){if("string"==typeof e)return ce(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?ce(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ce(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}const pe=function(t){var n=t.listId,r=t.provider,i=t.apiKey,s=t.onChange,u=le((0,e.useState)([]),2),l=u[0],c=u[1],p=le((0,e.useState)(!1),2),d=p[0],f=p[1],h=le((0,e.useState)({controller:null}),2),m=h[0].controller,v=h[1],g=function(){var e,t=(e=regeneratorRuntime.mark((function e(){var t,n,o;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return m&&m.abort(),f(!0),"AbortController"in window&&(m=new AbortController,v({controller:m})),(t=new FormData).append("api_key",i),t.append("provider",r),t.append("action","blocksy_ext_newsletter_subscribe_maybe_get_lists"),e.prev=7,e.next=10,fetch(ctDashboardLocalizations.ajax_url,{method:"POST",signal:m.signal,body:t});case 10:if(200!==(n=e.sent).status){e.next=20;break}return e.next=14,n.json();case 14:if(!(o=e.sent).success){e.next=20;break}if("api_key_invalid"===o.data.result){e.next=20;break}return f(!1),c(o.data.result),e.abrupt("return");case 20:e.next=24;break;case 22:e.prev=22,e.t0=e.catch(7);case 24:c([]),f(!1);case 26:case"end":return e.stop()}}),e,null,[[7,22]])})),function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function a(e){ue(i,r,o,a,s,"next",e)}function s(e){ue(i,r,o,a,s,"throw",e)}a(void 0)}))});return function(){return t.apply(this,arguments)}}();return(0,e.useEffect)((function(){i?g():c([])}),[r,i]),0===l.length?(0,e.createElement)("div",{className:"ct-select-input"},(0,e.createElement)("input",{disabled:!0,placeholder:d?(0,o.__)("Loading","blocksy-companion"):(0,o.__)("Invalid API Key...","blocksy-companion")})):(0,e.createElement)(ae,{selectedItem:n||"",onChange:function(e){return s(e)},itemToString:function(e){return e?(l.find((function(t){return t.id===e}))||{}).name:""}},(function(t){var n=t.getInputProps,r=t.getItemProps,i=(t.getLabelProps,t.getMenuProps),s=t.isOpen,u=(t.inputValue,t.highlightedIndex),c=t.selectedItem,p=t.openMenu;return(0,e.createElement)("div",{className:"ct-select-input"},(0,e.createElement)("input",se({},n({onFocus:function(){return p()},onClick:function(){return p()}}),{placeholder:(0,o.__)("Select list...","blocksy-companion"),readOnly:!0})),s&&(0,e.createElement)("div",i({className:"ct-select-dropdown"}),l.map((function(t,n){return(0,e.createElement)("div",r({key:t.id,index:n,item:t.id,className:a()("ct-select-dropdown-item",{active:u===n,selected:c===t.id})}),t.name)}))))}))};function de(e,t,n,r,o,i,a){try{var s=e[i](a),u=s.value}catch(e){return void n(e)}s.done?t(u):Promise.resolve(u).then(r,o)}function fe(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==s.return||s.return()}finally{if(o)throw i}}return n}}(e,t)||function(e,t){if(e){if("string"==typeof e)return he(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?he(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function he(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}const me=function(t){var n=t.extension,r=t.isEditingCredentials,i=t.setIsEditingCredentials,s=t.onCredentialsValidated,u=fe((0,e.useState)(n.data.provider),2),l=u[0],c=u[1],p=fe((0,e.useState)(n.data.api_key),2),d=p[0],f=p[1],h=fe((0,e.useState)(n.data.list_id),2),m=h[0],v=h[1],g=fe((0,e.useState)(!1),2),y=g[0],b=g[1],I=fe((0,e.useState)(!1),2),w=I[0],S=I[1],E=function(){var e,t=(e=regeneratorRuntime.mark((function e(){var t,n,r;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return(t=new FormData).append("provider",l),t.append("api_key",d),t.append("list_id",m),t.append("action","blocksy_ext_newsletter_subscribe_maybe_save_credentials"),b(!0),e.prev=6,e.next=9,fetch(ctDashboardLocalizations.ajax_url,{method:"POST",body:t});case 9:if(200!==(n=e.sent).status){e.next=15;break}return e.next=13,n.json();case 13:(r=e.sent).success&&"api_key_invalid"!==r.data.result&&(s(),S(!1));case 15:S(!0),e.next=21;break;case 18:e.prev=18,e.t0=e.catch(6),S(!0);case 21:return e.next=23,new Promise((function(e){return setTimeout((function(){return e()}),1e3)}));case 23:b(!1);case 24:case"end":return e.stop()}}),e,null,[[6,18]])})),function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function a(e){de(i,r,o,a,s,"next",e)}function s(e){de(i,r,o,a,s,"throw",e)}a(void 0)}))});return function(){return t.apply(this,arguments)}}();return(0,e.createElement)(M,{items:r,onDismiss:function(){return i(!1)},className:"ct-mailchimp-modal",render:function(){return(0,e.createElement)("div",{className:a()("ct-modal-content",{"ct-key-invalid":w})},(0,e.createElement)("h2",null,(0,o.__)("API Credentials","blocksy-companion")),(0,e.createElement)("p",{dangerouslySetInnerHTML:{__html:(0,o.__)("Enter your Newsletter provider API credentials in the form below.","blocksy-companion")}}),(0,e.createElement)("div",{className:"ct-newsletter-select-provider"},(0,e.createElement)(e.Fragment,null,(0,e.createElement)("h4",null,(0,o.__)("Select Provider","blocksy-companion")),(0,e.createElement)(A.Select,{onChange:function(e){c(e)},option:{placeholder:(0,o.__)("Pick Mailing Service","blocksy-companion"),choices:[{key:"mailchimp",value:"Mailchimp"},{key:"mailerlite",value:"Mailerlite"}]},value:l})),!ctDashboardLocalizations.plugin_data.is_pro&&"mailchimp"!==l&&(0,e.createElement)("p",{dangerouslySetInnerHTML:{__html:(0,o.sprintf)((0,o.__)("This option is available only in Blocksy premium %sversion%s.","blocksy-companion"),'<a target="_blank" href="https://creativethemes.com/blocksy/pricing/">',"</a>")}}),"mailchimp"===l&&(0,e.createElement)("p",{dangerouslySetInnerHTML:{__html:(0,o.sprintf)((0,o.__)("More info on how to generate an API key for Mailchimp can be found %shere%s.","blocksy-companion"),'<a target="_blank" href="https://mailchimp.com/help/about-api-keys/">',"</a>")}}),ctDashboardLocalizations.plugin_data.is_pro&&"mailerlite"===l&&(0,e.createElement)("p",{dangerouslySetInnerHTML:{__html:(0,o.sprintf)((0,o.__)("More info on how to generate an API key for Mailerlite can be found %shere%s. Please note that we require at least one group to be created in your account for the integration to work. More info on how to create a group %shere%s.","blocksy-companion"),'<a target="_blank" href="https://www.mailerlite.com/help/where-to-find-the-mailerlite-api-key-and-documentation">',"</a>",'<a target="_blank" href="https://www.mailerlite.com/help/how-to-create-and-use-groups">',"</a>")}})),("mailchimp"===l||ctDashboardLocalizations.plugin_data.is_pro)&&(0,e.createElement)("div",{className:"mailchimp-credentials"},(0,e.createElement)("section",null,(0,e.createElement)("label",null,(0,o.__)("API Key","blocksy-companion")),(0,e.createElement)("div",{className:"ct-option-input"},(0,e.createElement)("input",{type:"text",onChange:function(e){var t=e.target.value;return f(t)},value:d||""}))),(0,e.createElement)("section",null,(0,e.createElement)("label",null,(0,o.__)("List ID","blocksy-companion")),(0,e.createElement)(pe,{listId:m,onChange:function(e){return v(e)},provider:l,apiKey:d})),(0,e.createElement)("section",null,(0,e.createElement)("label",null," "),(0,e.createElement)("button",{className:"ct-button","data-button":"blue",disabled:!d||!m||y,onClick:function(){return E()}},y?(0,o.__)("Loading...","blocksy-companion"):n.__object?(0,o.__)("Save Settings","blocksy-companion"):(0,o.__)("Activate","blocksy-companion")))))}})};function ve(e,t,n,r,o,i,a){try{var s=e[i](a),u=s.value}catch(e){return void n(e)}s.done?t(u):Promise.resolve(u).then(r,o)}function ge(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function a(e){ve(i,r,o,a,s,"next",e)}function s(e){ve(i,r,o,a,s,"throw",e)}a(void 0)}))}}function ye(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==s.return||s.return()}finally{if(o)throw i}}return n}}(e,t)||function(e,t){if(e){if("string"==typeof e)return be(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?be(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function be(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Ie(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{r||null==s.return||s.return()}finally{if(o)throw i}}return n}}(e,t)||function(e,t){if(e){if("string"==typeof e)return we(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?we(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function we(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}const Se=function(t){var n=t.extension,r=t.onExtsSync,i=Ie(function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){},r=ye((0,e.useState)(!1),2),i=r[0],a=r[1],s=ye((0,e.useState)(!1),2),u=s[0],l=s[1],c=function(){var e=ge(regeneratorRuntime.mark((function e(){var r;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return(r=new FormData).append("ext",t.name),r.append("action",t.__object?"blocksy_extension_deactivate":"blocksy_extension_activate"),a(!0),e.prev=4,e.next=7,fetch(ctDashboardLocalizations.ajax_url,{method:"POST",body:r});case 7:n(),e.next=12;break;case 10:e.prev=10,e.t0=e.catch(4);case 12:a(!1);case 13:case"end":return e.stop()}}),e,null,[[4,10]])})));return function(){return e.apply(this,arguments)}}();return[i,function(){t.__object||t.data.api_key?c():l(!0)},(0,e.createElement)(e.Fragment,null,t.__object&&t.data.api_key&&(0,e.createElement)("button",{className:"ct-button ct-config-btn","data-button":"white",title:"Edit Credentials",onClick:function(){return l(!0)}},(0,o.__)("Configure","blocksy-companion")),(0,e.createElement)(me,{isEditingCredentials:u,setIsEditingCredentials:l,extension:t,onCredentialsValidated:function(){t.__object||c(),l(!1)}}))]}(n,(function(){r()})),3),s=i[0],u=i[1],l=i[2],c=Ie(H(n),2),p=c[0],d=c[1];return(0,e.createElement)("li",{className:a()({active:!!n.__object})},(0,e.createElement)("h4",{className:"ct-extension-title"},n.config.name,s&&(0,e.createElement)("svg",{width:"15",height:"15",viewBox:"0 0 100 100"},(0,e.createElement)("g",{transform:"translate(50,50)"},(0,e.createElement)("g",{transform:"scale(1)"},(0,e.createElement)("circle",{cx:"0",cy:"0",r:"50",fill:"#687c93"}),(0,e.createElement)("circle",{cx:"0",cy:"-26",r:"12",fill:"#ffffff",transform:"rotate(161.634)"},(0,e.createElement)("animateTransform",{attributeName:"transform",type:"rotate",calcMode:"linear",values:"0 0 0;360 0 0",keyTimes:"0;1",dur:"1s",begin:"0s",repeatCount:"indefinite"})))))),n.config.description&&(0,e.createElement)("div",{className:"ct-extension-description"},n.config.description),(0,e.createElement)("div",{className:"ct-extension-actions"},(0,e.createElement)("button",{className:a()(n.__object?"ct-button":"ct-button-primary"),"data-button":"white",disabled:s,onClick:function(){return u()}},n.__object?(0,o.__)("Deactivate","blocksy-companion"):(0,o.__)("Activate","blocksy-companion")),l,n.readme&&(0,e.createElement)("button",{onClick:function(){return p()},"data-button":"white",className:"ct-minimal-button ct-instruction"},(0,e.createElement)("svg",{width:"16",height:"16",viewBox:"0 0 24 24"},(0,e.createElement)("path",{d:"M12,2C6.477,2,2,6.477,2,12s4.477,10,10,10s10-4.477,10-10S17.523,2,12,2z M12,17L12,17c-0.552,0-1-0.448-1-1v-4 c0-0.552,0.448-1,1-1h0c0.552,0,1,0.448,1,1v4C13,16.552,12.552,17,12,17z M12.5,9h-1C11.224,9,11,8.776,11,8.5v-1 C11,7.224,11.224,7,11.5,7h1C12.776,7,13,7.224,13,7.5v1C13,8.776,12.776,9,12.5,9z"})))),d)};r().on("ct:extensions:card",(function(e){var t=e.CustomComponent;"newsletter-subscribe"===e.extension.name&&(t.extension=Se)}))})()})();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
framework/extensions/newsletter-subscribe/dashboard-static/bundle/main.js.LICENSE.txt
ADDED
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/*!
|
2 |
+
Copyright (c) 2017 Jed Watson.
|
3 |
+
Licensed under the MIT License (MIT), see
|
4 |
+
http://jedwatson.github.io/classnames
|
5 |
+
*/
|
6 |
+
|
7 |
+
/** @license React v16.13.1
|
8 |
+
* react-is.production.min.js
|
9 |
+
*
|
10 |
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
11 |
+
*
|
12 |
+
* This source code is licensed under the MIT license found in the
|
13 |
+
* LICENSE file in the root directory of this source tree.
|
14 |
+
*/
|
framework/extensions/newsletter-subscribe/extension.php
CHANGED
@@ -7,12 +7,6 @@ require_once dirname(__FILE__) . '/includes/BlocksyMailerliteManager.php';
|
|
7 |
|
8 |
class BlocksyExtensionNewsletterSubscribe {
|
9 |
public function __construct() {
|
10 |
-
add_action('blocksy:global-dynamic-css:enqueue', function ($args) {
|
11 |
-
blocksy_theme_get_dynamic_styles(array_merge([
|
12 |
-
'path' => dirname(__FILE__) . '/global.php',
|
13 |
-
'chunk' => 'global'
|
14 |
-
], $args));
|
15 |
-
}, 10, 3);
|
16 |
|
17 |
add_filter('blocksy-options-scripts-dependencies', function ($d) {
|
18 |
$d[] = 'blocksy-ext-newsletter-subscribe-admin-scripts';
|
@@ -194,6 +188,27 @@ class BlocksyExtensionNewsletterSubscribe {
|
|
194 |
|
195 |
return blc_ext_newsletter_subscribe_output_form($args);
|
196 |
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
197 |
}
|
198 |
|
199 |
public function newsletter_subscribe_process_mailerlite_subscribe() {
|
7 |
|
8 |
class BlocksyExtensionNewsletterSubscribe {
|
9 |
public function __construct() {
|
|
|
|
|
|
|
|
|
|
|
|
|
10 |
|
11 |
add_filter('blocksy-options-scripts-dependencies', function ($d) {
|
12 |
$d[] = 'blocksy-ext-newsletter-subscribe-admin-scripts';
|
188 |
|
189 |
return blc_ext_newsletter_subscribe_output_form($args);
|
190 |
});
|
191 |
+
|
192 |
+
add_action(
|
193 |
+
'blocksy:global-dynamic-css:enqueue',
|
194 |
+
'BlocksyExtensionNewsletterSubscribe::add_global_styles',
|
195 |
+
10, 3
|
196 |
+
);
|
197 |
+
}
|
198 |
+
|
199 |
+
static public function add_global_styles($args) {
|
200 |
+
blocksy_theme_get_dynamic_styles(array_merge([
|
201 |
+
'path' => dirname(__FILE__) . '/global.php',
|
202 |
+
'chunk' => 'global',
|
203 |
+
], $args));
|
204 |
+
}
|
205 |
+
|
206 |
+
static public function onDeactivation() {
|
207 |
+
remove_action(
|
208 |
+
'blocksy:global-dynamic-css:enqueue',
|
209 |
+
'BlocksyExtensionNewsletterSubscribe::add_global_styles',
|
210 |
+
10, 3
|
211 |
+
);
|
212 |
}
|
213 |
|
214 |
public function newsletter_subscribe_process_mailerlite_subscribe() {
|
framework/extensions/newsletter-subscribe/static/bundle/main.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
|
1 |
+
(()=>{"use strict";(0,window.ctFrontend.registerDynamicChunk)("blocksy_ext_newsletter_subscribe",{mount:function(e,s){var r=s.event.target;"mailchimp"===r.dataset.provider&&function(e){if(e.querySelector('[type="email"]').value.trim()){if(document.getElementById("js-validate-robot")&&""!==document.getElementById("js-validate-robot").value)return!1;for(var s=e.action.replace("subscribe","subscribe/post-json"),r="",t="mailchimpCallback",c=e.querySelectorAll("input"),i=0;i<c.length;i++)r+="&"+c[i].name+"="+encodeURIComponent(c[i].value);r+="&c=".concat(t);var a=document.createElement("script");a.src=s+r,document.body.appendChild(a),e.classList.remove("subscribe-error","subscribe-success"),e.classList.add("subscribe-loading"),window[t]=function(s){delete window[t],document.body.removeChild(a),e.classList.remove("subscribe-loading"),s&&(e.classList.add("error"===s.result?"subscribe-error":"subscribe-success"),e.querySelector(".ct-newsletter-subscribe-message").innerHTML=s.msg.replace("0 - ",""))}}}(r),r.dataset.provider.indexOf("mailerlite")>-1&&function(e){var s=new FormData(e);s.append("action","blc_newsletter_subscribe_process_mailerlite_subscribe"),s.append("GROUP",e.dataset.provider.split(":")[1]),e.classList.remove("subscribe-error","subscribe-success"),e.classList.add("subscribe-loading"),fetch(ct_localizations.ajax_url,{method:"POST",body:s}).then((function(e){return e.json()})).then((function(s){s.success;var r=s.data;e.classList.remove("subscribe-loading"),e.classList.add("no"===r.result?"subscribe-error":"subscribe-success"),e.querySelector(".ct-newsletter-subscribe-message").innerHTML=r.message}))}(r)}})})();
|
framework/extensions/newsletter-subscribe/static/bundle/main.min.css
CHANGED
@@ -1,8 +1,111 @@
|
|
1 |
/**
|
2 |
-
* - v1.8.
|
3 |
*
|
4 |
* Copyright (c) 2022
|
5 |
* Licensed GPLv2+
|
6 |
*/
|
7 |
|
8 |
-
.ct-widget-inner
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
/**
|
2 |
+
* - v1.8.35
|
3 |
*
|
4 |
* Copyright (c) 2022
|
5 |
* Licensed GPLv2+
|
6 |
*/
|
7 |
|
8 |
+
.ct-widget-inner {
|
9 |
+
border-radius: 3px;
|
10 |
+
}
|
11 |
+
.ct-widget-inner[data-alignment=center] {
|
12 |
+
text-align: center;
|
13 |
+
}
|
14 |
+
.ct-widget-inner[data-alignment=right] {
|
15 |
+
text-align: right;
|
16 |
+
}
|
17 |
+
|
18 |
+
.ct-newsletter-subscribe-widget-form > *:not(:first-child) {
|
19 |
+
margin-top: 10px;
|
20 |
+
}
|
21 |
+
|
22 |
+
[class*=ct-newsletter-subscribe] form [data-fields] {
|
23 |
+
display: grid;
|
24 |
+
grid-column-gap: 15px;
|
25 |
+
grid-row-gap: 15px;
|
26 |
+
}
|
27 |
+
@media (min-width: 690px) {
|
28 |
+
[class*=ct-newsletter-subscribe] form [data-fields="1"] {
|
29 |
+
grid-template-columns: 65% 1fr;
|
30 |
+
}
|
31 |
+
}
|
32 |
+
@media (min-width: 690px) {
|
33 |
+
[class*=ct-newsletter-subscribe] form [data-fields="2"] {
|
34 |
+
grid-template-columns: 32.5% 32.5% 1fr;
|
35 |
+
}
|
36 |
+
}
|
37 |
+
[class*=ct-newsletter-subscribe] form button {
|
38 |
+
width: 100%;
|
39 |
+
--padding: 0 15px;
|
40 |
+
--buttonMinHeight: var(--form-field-height, 40px);
|
41 |
+
}
|
42 |
+
[class*=ct-newsletter-subscribe] form .ct-newsletter-subscribe-description:not(:empty) {
|
43 |
+
margin-bottom: 1.5em;
|
44 |
+
}
|
45 |
+
[class*=ct-newsletter-subscribe] form .ct-newsletter-subscribe-message,
|
46 |
+
[class*=ct-newsletter-subscribe] form .gdpr-confirm-policy {
|
47 |
+
margin-top: 15px;
|
48 |
+
margin-bottom: 0;
|
49 |
+
}
|
50 |
+
|
51 |
+
.ct-newsletter-subscribe-block,
|
52 |
+
.ct-newsletter-subscribe-widget [data-container=boxed] {
|
53 |
+
padding: var(--padding, 30px);
|
54 |
+
box-shadow: var(--box-shadow, 0px 12px 18px -6px rgba(34, 56, 101, 0.04));
|
55 |
+
}
|
56 |
+
|
57 |
+
.ct-newsletter-subscribe-block {
|
58 |
+
margin-top: 60px;
|
59 |
+
text-align: center;
|
60 |
+
color: var(--color);
|
61 |
+
border: var(--newsletter-container-border, none);
|
62 |
+
border-radius: var(--border-radius, 0px);
|
63 |
+
--linkInitialColor: var(--color);
|
64 |
+
}
|
65 |
+
.ct-newsletter-subscribe-block > *:first-child {
|
66 |
+
margin-top: 20px;
|
67 |
+
}
|
68 |
+
.ct-newsletter-subscribe-block > *:last-child {
|
69 |
+
margin-bottom: 20px;
|
70 |
+
}
|
71 |
+
.ct-newsletter-subscribe-block > h3 {
|
72 |
+
--fontSize: 25px;
|
73 |
+
}
|
74 |
+
.ct-newsletter-subscribe-block form {
|
75 |
+
max-width: 550px;
|
76 |
+
margin: 0 auto;
|
77 |
+
}
|
78 |
+
@media (min-width: 690px) {
|
79 |
+
.ct-newsletter-subscribe-block form {
|
80 |
+
width: 85%;
|
81 |
+
}
|
82 |
+
}
|
83 |
+
|
84 |
+
form[class*=ct-newsletter-subscribe] .button {
|
85 |
+
--buttonFontWeight: 600;
|
86 |
+
}
|
87 |
+
|
88 |
+
.ct-newsletter-subscribe-message {
|
89 |
+
display: none;
|
90 |
+
font-size: 16px;
|
91 |
+
}
|
92 |
+
.ct-newsletter-subscribe-message a {
|
93 |
+
text-decoration: underline;
|
94 |
+
}
|
95 |
+
|
96 |
+
.subscribe-error .ct-newsletter-subscribe-message {
|
97 |
+
display: block;
|
98 |
+
font-size: 14px;
|
99 |
+
color: #e42b2b;
|
100 |
+
}
|
101 |
+
|
102 |
+
.subscribe-success button.button,
|
103 |
+
.subscribe-success input[type=text],
|
104 |
+
.subscribe-success input[type=email],
|
105 |
+
.subscribe-success .gdpr-confirm-policy,
|
106 |
+
.subscribe-success .ct-newsletter-subscribe-description {
|
107 |
+
display: none;
|
108 |
+
}
|
109 |
+
.subscribe-success .ct-newsletter-subscribe-message {
|
110 |
+
display: block;
|
111 |
+
}
|
framework/extensions/product-reviews/extension.php
CHANGED
@@ -164,12 +164,6 @@ class BlocksyExtensionProductReviews {
|
|
164 |
}
|
165 |
);
|
166 |
|
167 |
-
add_action('blocksy:global-dynamic-css:enqueue', function ($args) {
|
168 |
-
blocksy_theme_get_dynamic_styles(array_merge([
|
169 |
-
'path' => dirname( __FILE__ ) . '/global.php',
|
170 |
-
'chunk' => 'global'
|
171 |
-
], $args));
|
172 |
-
}, 10, 3);
|
173 |
|
174 |
add_action('init', [$this, 'declare_cpt']);
|
175 |
|
@@ -420,6 +414,27 @@ class BlocksyExtensionProductReviews {
|
|
420 |
|
421 |
return $options;
|
422 |
}, 10, 2);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
423 |
}
|
424 |
|
425 |
public function init_metabox() {
|
@@ -607,4 +622,5 @@ class BlocksyExtensionProductReviews {
|
|
607 |
public function set_settings($value) {
|
608 |
update_option('blocksy_ext_product_reviews_settings', $value);
|
609 |
}
|
|
|
610 |
}
|
164 |
}
|
165 |
);
|
166 |
|
|
|
|
|
|
|
|
|
|
|
|
|
167 |
|
168 |
add_action('init', [$this, 'declare_cpt']);
|
169 |
|
414 |
|
415 |
return $options;
|
416 |
}, 10, 2);
|
417 |
+
|
418 |
+
add_action(
|
419 |
+
'blocksy:global-dynamic-css:enqueue',
|
420 |
+
'BlocksyExtensionProductReviews::add_global_styles',
|
421 |
+
10, 3
|
422 |
+
);
|
423 |
+
}
|
424 |
+
|
425 |
+
static public function add_global_styles($args) {
|
426 |
+
blocksy_theme_get_dynamic_styles(array_merge([
|
427 |
+
'path' => dirname(__FILE__) . '/global.php',
|
428 |
+
'chunk' => 'global',
|
429 |
+
], $args));
|
430 |
+
}
|
431 |
+
|
432 |
+
static public function onDeactivation() {
|
433 |
+
remove_action(
|
434 |
+
'blocksy:global-dynamic-css:enqueue',
|
435 |
+
'BlocksyExtensionProductReviews::add_global_styles',
|
436 |
+
10, 3
|
437 |
+
);
|
438 |
}
|
439 |
|
440 |
public function init_metabox() {
|
622 |
public function set_settings($value) {
|
623 |
update_option('blocksy_ext_product_reviews_settings', $value);
|
624 |
}
|
625 |
+
|
626 |
}
|
framework/extensions/product-reviews/static/bundle/dashboard.js
CHANGED
@@ -1,6 +1,2 @@
|
|
1 |
-
|
2 |
-
/*!
|
3 |
-
Copyright (c) 2017 Jed Watson.
|
4 |
-
Licensed under the MIT License (MIT), see
|
5 |
-
http://jedwatson.github.io/classnames
|
6 |
-
*/!function(){"use strict";var n={}.hasOwnProperty;function o(){for(var e=[],t=0;t<arguments.length;t++){var r=arguments[t];if(r){var a=typeof r;if("string"===a||"number"===a)e.push(r);else if(Array.isArray(r)&&r.length){var i=o.apply(null,r);i&&e.push(i)}else if("object"===a)for(var c in r)n.call(r,c)&&r[c]&&e.push(c)}}return e.join(" ")}e.exports?(o.default=o,e.exports=o):void 0===(r=function(){return o}.apply(t,[]))||(e.exports=r)}()},function(e,t){e.exports=window.blocksyOptions},function(e,t){e.exports=window.ctEvents},function(e,t){e.exports=window.React},function(e,t,n){var r,o,a=n(10),i=n(11),c=(o=[],{activateTrap:function(e){if(o.length>0){var t=o[o.length-1];t!==e&&t.pause()}var n=o.indexOf(e);-1===n||o.splice(n,1),o.push(e)},deactivateTrap:function(e){var t=o.indexOf(e);-1!==t&&o.splice(t,1),o.length>0&&o[o.length-1].unpause()}});function u(e){return setTimeout(e,0)}e.exports=function(e,t){var n=document,o="string"==typeof e?n.querySelector(e):e,s=i({returnFocusOnDeactivate:!0,escapeDeactivates:!0},t),l={firstTabbableNode:null,lastTabbableNode:null,nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1},f={activate:function(e){if(l.active)return;j(),l.active=!0,l.paused=!1,l.nodeFocusedBeforeActivation=n.activeElement;var t=e&&e.onActivate?e.onActivate:s.onActivate;t&&t();return d(),f},deactivate:p,pause:function(){if(l.paused||!l.active)return;l.paused=!0,b()},unpause:function(){if(!l.paused||!l.active)return;l.paused=!1,j(),d()}};return f;function p(e){if(l.active){clearTimeout(r),b(),l.active=!1,l.paused=!1,c.deactivateTrap(f);var t=e&&void 0!==e.onDeactivate?e.onDeactivate:s.onDeactivate;return t&&t(),(e&&void 0!==e.returnFocus?e.returnFocus:s.returnFocusOnDeactivate)&&u((function(){var e;w((e=l.nodeFocusedBeforeActivation,m("setReturnFocus")||e))})),f}}function d(){if(l.active)return c.activateTrap(f),r=u((function(){w(v())})),n.addEventListener("focusin",h,!0),n.addEventListener("mousedown",y,{capture:!0,passive:!1}),n.addEventListener("touchstart",y,{capture:!0,passive:!1}),n.addEventListener("click",O,{capture:!0,passive:!1}),n.addEventListener("keydown",g,{capture:!0,passive:!1}),f}function b(){if(l.active)return n.removeEventListener("focusin",h,!0),n.removeEventListener("mousedown",y,!0),n.removeEventListener("touchstart",y,!0),n.removeEventListener("click",O,!0),n.removeEventListener("keydown",g,!0),f}function m(e){var t=s[e],r=t;if(!t)return null;if("string"==typeof t&&!(r=n.querySelector(t)))throw new Error("`"+e+"` refers to no known node");if("function"==typeof t&&!(r=t()))throw new Error("`"+e+"` did not return a node");return r}function v(){var e;if(!(e=null!==m("initialFocus")?m("initialFocus"):o.contains(n.activeElement)?n.activeElement:l.firstTabbableNode||m("fallbackFocus")))throw new Error("Your focus-trap needs to have at least one focusable element");return e}function y(e){o.contains(e.target)||(s.clickOutsideDeactivates?p({returnFocus:!a.isFocusable(e.target)}):s.allowOutsideClick&&s.allowOutsideClick(e)||e.preventDefault())}function h(e){o.contains(e.target)||e.target instanceof Document||(e.stopImmediatePropagation(),w(l.mostRecentlyFocusedNode||v()))}function g(e){if(!1!==s.escapeDeactivates&&function(e){return"Escape"===e.key||"Esc"===e.key||27===e.keyCode}(e))return e.preventDefault(),void p();(function(e){return"Tab"===e.key||9===e.keyCode})(e)&&function(e){if(j(),e.shiftKey&&e.target===l.firstTabbableNode)return e.preventDefault(),void w(l.lastTabbableNode);if(!e.shiftKey&&e.target===l.lastTabbableNode)e.preventDefault(),w(l.firstTabbableNode)}(e)}function O(e){s.clickOutsideDeactivates||o.contains(e.target)||s.allowOutsideClick&&s.allowOutsideClick(e)||(e.preventDefault(),e.stopImmediatePropagation())}function j(){var e=a(o);l.firstTabbableNode=e[0]||v(),l.lastTabbableNode=e[e.length-1]||v()}function w(e){e!==n.activeElement&&(e&&e.focus?(e.focus(),l.mostRecentlyFocusedNode=e,function(e){return e.tagName&&"input"===e.tagName.toLowerCase()&&"function"==typeof e.select}(e)&&e.select()):w(v()))}}},function(e,t,n){e.exports=n(8)()},function(e,t,n){"use strict";var r=n(9);function o(){}function a(){}a.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,a,i){if(i!==r){var c=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 c.name="Invariant Violation",c}}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:a,resetWarningCache:o};return n.PropTypes=n,n}},function(e,t,n){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(e,t){var n=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'],r=n.join(","),o="undefined"==typeof Element?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector;function a(e,t){t=t||{};var n,a,c,u=[],f=[],p=e.querySelectorAll(r);for(t.includeContainer&&o.call(e,r)&&(p=Array.prototype.slice.apply(p)).unshift(e),n=0;n<p.length;n++)i(a=p[n])&&(0===(c=s(a))?u.push(a):f.push({documentOrder:n,tabIndex:c,node:a}));return f.sort(l).map((function(e){return e.node})).concat(u)}function i(e){return!(!c(e)||function(e){return function(e){return f(e)&&"radio"===e.type}(e)&&!function(e){if(!e.name)return!0;var t=function(e){for(var t=0;t<e.length;t++)if(e[t].checked)return e[t]}(e.ownerDocument.querySelectorAll('input[type="radio"][name="'+e.name+'"]'));return!t||t===e}(e)}(e)||s(e)<0)}function c(e){return!(e.disabled||function(e){return f(e)&&"hidden"===e.type}(e)||function(e){return null===e.offsetParent||"hidden"===getComputedStyle(e).visibility}(e))}a.isTabbable=function(e){if(!e)throw new Error("No node provided");return!1!==o.call(e,r)&&i(e)},a.isFocusable=function(e){if(!e)throw new Error("No node provided");return!1!==o.call(e,u)&&c(e)};var u=n.concat("iframe").join(",");function s(e){var t=parseInt(e.getAttribute("tabindex"),10);return isNaN(t)?function(e){return"true"===e.contentEditable}(e)?0:e.tabIndex:t}function l(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex}function f(e){return"INPUT"===e.tagName}e.exports=a},function(e,t){e.exports=function(){for(var e={},t=0;t<arguments.length;t++){var r=arguments[t];for(var o in r)n.call(r,o)&&(e[o]=r[o])}return e};var n=Object.prototype.hasOwnProperty},function(e,t,n){"use strict";n.r(t);var r=n(0),o=n(1),a=n(2),i=n.n(a),c=n(4),u=n.n(c),s=n(3),l=n(5),f=n.n(l);n(7);function p(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function d(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var b=function(e){e.initialState,e.getInitialState,e.refs,e.getRefs,e.didMount,e.didUpdate,e.willUnmount,e.getSnapshotBeforeUpdate,e.shouldUpdate,e.render;return function(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}(e,["initialState","getInitialState","refs","getRefs","didMount","didUpdate","willUnmount","getSnapshotBeforeUpdate","shouldUpdate","render"])},m=function(e){function t(){var n,r;p(this,t);for(var o=arguments.length,a=Array(o),i=0;i<o;i++)a[i]=arguments[i];return n=r=d(this,e.call.apply(e,[this].concat(a))),v.call(r),d(r,n)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),t.prototype.getArgs=function(){var e=this.state,t=this.props,n=this._setState,r=this._forceUpdate,o=this._refs;return{state:e,props:b(t),refs:o,setState:n,forceUpdate:r}},t.prototype.componentDidMount=function(){this.props.didMount&&this.props.didMount(this.getArgs())},t.prototype.shouldComponentUpdate=function(e,t){return!this.props.shouldUpdate||this.props.shouldUpdate({props:this.props,state:this.state,nextProps:b(e),nextState:t})},t.prototype.componentWillUnmount=function(){this.props.willUnmount&&this.props.willUnmount({state:this.state,props:b(this.props),refs:this._refs})},t.prototype.componentDidUpdate=function(e,t,n){this.props.didUpdate&&this.props.didUpdate(Object.assign(this.getArgs(),{prevProps:b(e),prevState:t}),n)},t.prototype.getSnapshotBeforeUpdate=function(e,t){return this.props.getSnapshotBeforeUpdate?this.props.getSnapshotBeforeUpdate(Object.assign(this.getArgs(),{prevProps:b(e),prevState:t})):null},t.prototype.render=function(){var e=this.props,t=e.children,n=e.render;return n?n(this.getArgs()):"function"==typeof t?t(this.getArgs()):t||null},t}(f.a.Component);m.defaultProps={getInitialState:function(){},getRefs:function(){return{}}};var v=function(){var e=this;this.state=this.props.initialState||this.props.getInitialState(this.props),this._refs=this.props.refs||this.props.getRefs(this.getArgs()),this._setState=function(){return e.setState.apply(e,arguments)},this._forceUpdate=function(){return e.forceUpdate.apply(e,arguments)}},y=m,h=function(e){var t=e.children,n=e.container,o=void 0===n?document.body:n,a=e.type,i=void 0===a?"reach-portal":a;return Object(r.createElement)(y,{getRefs:function(){return{node:null}},didMount:function(e){var t=e.refs,n=e.forceUpdate,r=o.hasOwnProperty("current")?o.current:o;t.node=document.createElement(i),r.appendChild(t.node),n()},willUnmount:function(e){var t=e.refs.node,n=o.hasOwnProperty("current")?o.current:o;n&&n.removeChild(t)},render:function(e){var n=e.refs.node;return n?Object(r.createPortal)(t,n):null}})};var g=function(e,t){return function(n){if(e&&e(n),!n.defaultPrevented)return t(n)}},O=n(6),j=n.n(O);function w(){return(w=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function E(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var S=function(){},x=function(){},_=function(e,t){var n,r,o;e.disposeAriaHider=(n=e.overlayNode,r=[],o=[],Array.prototype.forEach.call(document.querySelectorAll("body > *"),(function(e){if(e!==n.parentNode){var t=e.getAttribute("aria-hidden");null!==t&&"false"!==t||(r.push(t),o.push(e),e.setAttribute("aria-hidden","true"))}})),function(){o.forEach((function(e,t){var n=r[t];null===n?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",n)}))}),e.trap=j()(e.overlayNode,{initialFocus:t?function(){return t.current}:void 0,fallbackFocus:e.contentNode,escapeDeactivates:!1,clickOutsideDeactivates:!1})},k=function(e){var t=e.refs;t.trap.deactivate(),t.disposeAriaHider()},C=React.createContext(),A=React.forwardRef((function(e,t){var n=e.container,o=e.isOpen,a=void 0===o||o,i=e.onDismiss,c=void 0===i?S:i,u=e.initialFocusRef,s=e.onClick,l=e.onKeyDown,f=E(e,["container","isOpen","onDismiss","initialFocusRef","onClick","onKeyDown"]);return Object(r.createElement)(y,{didMount:x},a?Object(r.createElement)(h,{container:n,"data-reach-dialog-wrapper":!0},Object(r.createElement)(y,{refs:{overlayNode:null,contentNode:null},didMount:function(e){var t=e.refs;_(t,u)},willUnmount:k},(function(e){var n=e.refs;return Object(r.createElement)(C.Provider,{value:function(e){return n.contentNode=e}},Object(r.createElement)("div",w({"data-reach-dialog-overlay":!0,onClick:g(s,(function(e){e.stopPropagation(),c()})),onKeyDown:g(l,(function(e){"Escape"===e.key&&(e.stopPropagation(),c())})),ref:function(e){n.overlayNode=e,t&&t(e)}},f)))}))):null)}));A.propTypes={initialFocusRef:function(){}};var N=function(e){return e.stopPropagation()},P=React.forwardRef((function(e,t){var n=e.onClick,o=(e.onKeyDown,E(e,["onClick","onKeyDown"]));return Object(r.createElement)(C.Consumer,null,(function(e){return Object(r.createElement)("div",w({"aria-modal":"true","data-reach-dialog-content":!0,tabIndex:"-1",onClick:g(n,N),ref:function(n){e(n),t&&t(n)}},o))}))})),D=function(e){return!!e},T=function(e){var t=e.items,n=e.isVisible,o=void 0===n?D:n,a=e.render,c=e.className,u=e.onDismiss;return Object(r.createElement)(s.Transition,{items:t,onStart:function(){return document.body.classList[o(t)?"add":"remove"]("ct-dashboard-overlay-open")},config:{duration:200},from:{opacity:0,y:-10},enter:{opacity:1,y:0},leave:{opacity:0,y:10}},(function(e){return o(e)&&function(t){return Object(r.createElement)(A,{style:{opacity:t.opacity},container:document.querySelector("#wpbody"),onDismiss:function(){return u()}},Object(r.createElement)(P,{className:i()("ct-admin-modal",c),style:{transform:"translate3d(0px, ".concat(t.y,"px, 0px)")}},Object(r.createElement)("button",{className:"close-button",onClick:function(){return u()}},"×"),a(e,t)))}}))};function U(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function I(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?U(Object(n),!0).forEach((function(t){M(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):U(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function M(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function R(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,o=!1,a=void 0;try{for(var i,c=e[Symbol.iterator]();!(r=(i=c.next()).done)&&(n.push(i.value),!t||n.length!==t);r=!0);}catch(e){o=!0,a=e}finally{try{r||null==c.return||c.return()}finally{if(o)throw a}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return F(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return F(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function F(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var L=function(e){var t=e.extsSyncLoading,n=e.extensionData,a=e.onExtsSync,c=R(Object(r.useState)(!1),2),u=c[0],l=c[1],f=R(Object(r.useState)(null),2),p=f[0],d=f[1];return Object(r.createElement)(r.Fragment,null,Object(r.createElement)("button",{className:"ct-button ct-config-btn","data-button":"white",onClick:function(){l(!0),d(n.settings)}},Object(o.__)("Configure","blocksy-companion")),Object(r.createElement)(T,{items:u,onDismiss:function(){return l(!1)},className:"ct-product-reviews-settings-modal",render:function(){return Object(r.createElement)("div",{className:i()("ct-modal-content")},Object(r.createElement)("h2",null,Object(o.__)("Product Reviews Settings","blocksy-companion")),Object(r.createElement)("p",{className:"ct-modal-description"},Object(o.__)("Configure the slugs for single and category pages of the product review custom post type.","blocksy-companion")),Object(r.createElement)("div",{className:"ct-controls-group"},Object(r.createElement)("section",{"data-columns":"medium:2"},Object(r.createElement)(s.OptionsPanel,{onChange:function(e,t){return d((function(n){return I(I({},n),{},M({},e,t))}))},options:{single_slug:{type:"text",value:"",label:Object(o.__)("Single Slug","blocksy-companion")},category_slug:{type:"text",value:"",label:Object(o.__)("Category Slug","blocksy-companion")}},value:p||{},hasRevertButton:!1}))),Object(r.createElement)("div",{className:"ct-modal-actions has-divider"},Object(r.createElement)("button",{className:"button-primary",disabled:t||!p,onClick:function(e){e.preventDefault(),p&&(a({extAction:{type:"persist",settings:p}}),l(!1))}},t?Object(r.createElement)("svg",{width:"15",height:"15",viewBox:"0 0 100 100"},Object(r.createElement)("g",{transform:"translate(50,50)"},Object(r.createElement)("g",{transform:"scale(1)"},Object(r.createElement)("circle",{cx:"0",cy:"0",r:"50",fill:"#687c93"}),Object(r.createElement)("circle",{cx:"0",cy:"-26",r:"12",fill:"#ffffff",transform:"rotate(161.634)"},Object(r.createElement)("animateTransform",{attributeName:"transform",type:"rotate",calcMode:"linear",values:"0 0 0;360 0 0",keyTimes:"0;1",dur:"1s",begin:"0s",repeatCount:"indefinite"}))))):Object(o.__)("Save","blocksy-companion"))))}}))};function B(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,o=!1,a=void 0;try{for(var i,c=e[Symbol.iterator]();!(r=(i=c.next()).done)&&(n.push(i.value),!t||n.length!==t);r=!0);}catch(e){o=!0,a=e}finally{try{r||null==c.return||c.return()}finally{if(o)throw a}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return z(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return z(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function z(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var q=function(e){var t=B(Object(r.useState)(!1),2),n=t[0],o=t[1];return[function(){return o(!0)},Object(r.createElement)(T,{items:n,onDismiss:function(){return o(!1)},render:function(){return Object(r.createElement)("div",{className:"ct-modal-content",dangerouslySetInnerHTML:{__html:e.readme}})}})]},K=window.ctDashboardLocalizations.DashboardContext,H=(K.Provider,K.Consumer,K);function W(e,t,n,r,o,a,i){try{var c=e[a](i),u=c.value}catch(e){return void n(e)}c.done?t(u):Promise.resolve(u).then(r,o)}function $(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var a=e.apply(t,n);function i(e){W(a,r,o,i,c,"next",e)}function c(e){W(a,r,o,i,c,"throw",e)}i(void 0)}))}}function V(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,o=!1,a=void 0;try{for(var i,c=e[Symbol.iterator]();!(r=(i=c.next()).done)&&(n.push(i.value),!t||n.length!==t);r=!0);}catch(e){o=!0,a=e}finally{try{r||null==c.return||c.return()}finally{if(o)throw a}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return Y(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Y(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Y(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var G=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){},n=Object(r.useState)(!1),a=V(n,2),i=a[0],c=a[1],u=Object(r.useState)(!1),s=V(u,2),l=s[0],f=s[1],p=Object(r.useContext)(H),d=(p.Link,p.history),b=ctDashboardLocalizations.plugin_data.is_pro,m=function(){var n=$(regeneratorRuntime.mark((function n(){var r;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(b||!e.config.pro){n.next=3;break}return f(!0),n.abrupt("return");case 3:return(r=new FormData).append("ext",e.name),r.append("action",e.__object?"blocksy_extension_deactivate":"blocksy_extension_activate"),c(!0),n.prev=7,n.next=10,fetch(ctDashboardLocalizations.ajax_url,{method:"POST",body:r});case 10:e.config.require_refresh&&location.reload(),t(),n.next=16;break;case 14:n.prev=14,n.t0=n.catch(7);case 16:c(!1);case 17:case"end":return n.stop()}}),n,null,[[7,14]])})));return function(){return n.apply(this,arguments)}}();return[i,m,!b&&e.config.pro?Object(r.createElement)(T,{items:l,className:"ct-onboarding-modal",onDismiss:function(){return f(!1)},render:function(){return Object(r.createElement)("div",{className:"ct-modal-content"},Object(r.createElement)("svg",{width:"55",height:"55",viewBox:"0 0 40.5 48.3"},Object(r.createElement)("path",{fill:"#2d82c8",d:"M33.4 29.4l7.1 12.3-7.4.6-4 6-7.3-12.9"}),Object(r.createElement)("path",{d:"M33.5 29.6L26 42.7l-4.2-7.3 11.6-6 .1.2zM0 41.7l7.5.6 3.9 6 7.2-12.4-11-7.3L0 41.7z",fill:"#2271b1"}),Object(r.createElement)("path",{d:"M39.5 18.7c0 1.6-2.4 2.8-2.7 4.3-.4 1.5 1 3.8.2 5.1-.8 1.3-3.4 1.2-4.5 2.3-1.1 1.1-1 3.7-2.3 4.5-1.3.8-3.6-.6-5.1-.2-1.5.4-2.7 2.7-4.3 2.7S18 35 16.5 34.7c-1.5-.4-3.8 1-5.1.2s-1.2-3.4-2.3-4.5-3.7-1-4.5-2.3.6-3.6.2-5.1-2.7-2.7-2.7-4.3 2.4-2.8 2.7-4.3c.4-1.5-1-3.8-.2-5.1C5.4 8 8.1 8.1 9.1 7c1.1-1.1 1-3.7 2.3-4.5s3.6.6 5.1.2C18 2.4 19.2 0 20.8 0c1.6 0 2.8 2.4 4.3 2.7 1.5.4 3.8-1 5.1-.2 1.3.8 1.2 3.4 2.3 4.5 1.1 1.1 3.7 1 4.5 2.3s-.6 3.6-.2 5.1c.3 1.5 2.7 2.7 2.7 4.3z",fill:"#599fd9"}),Object(r.createElement)("path",{d:"M23.6 7c-6.4-1.5-12.9 2.5-14.4 8.9-.7 3.1-.2 6.3 1.5 9.1 1.7 2.7 4.3 4.6 7.4 5.4.9.2 1.9.3 2.8.3 2.2 0 4.4-.6 6.3-1.8 2.7-1.7 4.6-4.3 5.4-7.5C34 15 30 8.5 23.6 7zm7 14c-.6 2.6-2.2 4.8-4.5 6.2-2.3 1.4-5 1.8-7.6 1.2-2.6-.6-4.8-2.2-6.2-4.5-1.4-2.3-1.8-5-1.2-7.6.6-2.6 2.2-4.8 4.5-6.2 1.6-1 3.4-1.5 5.2-1.5.8 0 1.5.1 2.3.3 5.4 1.3 8.7 6.7 7.5 12.1zm-8.2-4.5l3.7.5-2.7 2.7.7 3.7-3.4-1.8-3.3 1.8.6-3.7-2.7-2.7 3.8-.5 1.6-3.4 1.7 3.4z",fill:"#fff"})),Object(r.createElement)("h2",{className:"ct-modal-title"},"This is a Pro extension"),Object(r.createElement)("p",null,Object(o.__)("Upgrade to the Pro version and get instant access to all premium extensions, features and future updates.","blocksy-companion")),Object(r.createElement)("div",{className:"ct-modal-actions has-divider","data-buttons":"2"},Object(r.createElement)("a",{onClick:function(e){e.preventDefault(),f(!1),setTimeout((function(){d.navigate("/pro")}),300)},className:"button"},Object(o.__)("Free vs Pro","blocksy")),Object(r.createElement)("a",{href:"https://creativethemes.com/blocksy/pricing/",target:"_blank",className:"button button-primary"},Object(o.__)("Upgrade Now","blocksy-companion"))))}}):null]};function J(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,o=!1,a=void 0;try{for(var i,c=e[Symbol.iterator]();!(r=(i=c.next()).done)&&(n.push(i.value),!t||n.length!==t);r=!0);}catch(e){o=!0,a=e}finally{try{r||null==c.return||c.return()}finally{if(o)throw a}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return Q(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Q(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Q(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var X=function(e){var t=e.extsSyncLoading,n=e.extension,a=e.onExtsSync,c=J(G(n,(function(){return a()})),2),u=c[0],s=c[1],l=J(q(n),2),f=l[0],p=l[1];return Object(r.createElement)("li",{className:i()({active:!!n.__object})},Object(r.createElement)("h4",{className:"ct-extension-title"},n.config.name,u&&Object(r.createElement)("svg",{width:"15",height:"15",viewBox:"0 0 100 100"},Object(r.createElement)("g",{transform:"translate(50,50)"},Object(r.createElement)("g",{transform:"scale(1)"},Object(r.createElement)("circle",{cx:"0",cy:"0",r:"50",fill:"#687c93"}),Object(r.createElement)("circle",{cx:"0",cy:"-26",r:"12",fill:"#ffffff",transform:"rotate(161.634)"},Object(r.createElement)("animateTransform",{attributeName:"transform",type:"rotate",calcMode:"linear",values:"0 0 0;360 0 0",keyTimes:"0;1",dur:"1s",begin:"0s",repeatCount:"indefinite"})))))),n.config.description&&Object(r.createElement)("div",{className:"ct-extension-description"},n.config.description),Object(r.createElement)("div",{className:"ct-extension-actions"},Object(r.createElement)("button",{className:i()(n.__object?"ct-button":"ct-button-primary"),"data-button":"white",disabled:u,onClick:function(){s()}},n.__object?Object(o.__)("Deactivate","blocksy-companion"):Object(o.__)("Activate","blocksy-companion")),n.__object&&Object(r.createElement)(L,{extsSyncLoading:t,extensionData:n.data,onExtsSync:a}),n.readme&&Object(r.createElement)("button",{onClick:function(){return f()},"data-button":"white",className:"ct-minimal-button ct-instruction"},Object(r.createElement)("svg",{width:"16",height:"16",viewBox:"0 0 24 24"},Object(r.createElement)("path",{d:"M12,2C6.477,2,2,6.477,2,12s4.477,10,10,10s10-4.477,10-10S17.523,2,12,2z M12,17L12,17c-0.552,0-1-0.448-1-1v-4 c0-0.552,0.448-1,1-1h0c0.552,0,1,0.448,1,1v4C13,16.552,12.552,17,12,17z M12.5,9h-1C11.224,9,11,8.776,11,8.5v-1 C11,7.224,11.224,7,11.5,7h1C12.776,7,13,7.224,13,7.5v1C13,8.776,12.776,9,12.5,9z"})))),p)};u.a.on("ct:extensions:card",(function(e){var t=e.CustomComponent;"product-reviews"===e.extension.name&&(t.extension=X)}))}]);
|
1 |
+
/*! For license information please see dashboard.js.LICENSE.txt */
|
2 |
+
(()=>{var e={184:(e,t)=>{var n;!function(){"use strict";var r={}.hasOwnProperty;function o(){for(var e=[],t=0;t<arguments.length;t++){var n=arguments[t];if(n){var a=typeof n;if("string"===a||"number"===a)e.push(n);else if(Array.isArray(n)&&n.length){var i=o.apply(null,n);i&&e.push(i)}else if("object"===a)for(var c in n)r.call(n,c)&&n[c]&&e.push(c)}}return e.join(" ")}e.exports?(o.default=o,e.exports=o):void 0===(n=function(){return o}.apply(t,[]))||(e.exports=n)}()},172:(e,t,n)=>{var r,o,a=n(760),i=n(529),c=(o=[],{activateTrap:function(e){if(o.length>0){var t=o[o.length-1];t!==e&&t.pause()}var n=o.indexOf(e);-1===n||o.splice(n,1),o.push(e)},deactivateTrap:function(e){var t=o.indexOf(e);-1!==t&&o.splice(t,1),o.length>0&&o[o.length-1].unpause()}});function s(e){return setTimeout(e,0)}e.exports=function(e,t){var n=document,o="string"==typeof e?n.querySelector(e):e,u=i({returnFocusOnDeactivate:!0,escapeDeactivates:!0},t),l={firstTabbableNode:null,lastTabbableNode:null,nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1},f={activate:function(e){if(!l.active){E(),l.active=!0,l.paused=!1,l.nodeFocusedBeforeActivation=n.activeElement;var t=e&&e.onActivate?e.onActivate:u.onActivate;return t&&t(),d(),f}},deactivate:p,pause:function(){!l.paused&&l.active&&(l.paused=!0,m())},unpause:function(){l.paused&&l.active&&(l.paused=!1,E(),d())}};return f;function p(e){if(l.active){clearTimeout(r),m(),l.active=!1,l.paused=!1,c.deactivateTrap(f);var t=e&&void 0!==e.onDeactivate?e.onDeactivate:u.onDeactivate;return t&&t(),(e&&void 0!==e.returnFocus?e.returnFocus:u.returnFocusOnDeactivate)&&s((function(){var e;O((e=l.nodeFocusedBeforeActivation,v("setReturnFocus")||e))})),f}}function d(){if(l.active)return c.activateTrap(f),r=s((function(){O(y())})),n.addEventListener("focusin",b,!0),n.addEventListener("mousedown",h,{capture:!0,passive:!1}),n.addEventListener("touchstart",h,{capture:!0,passive:!1}),n.addEventListener("click",w,{capture:!0,passive:!1}),n.addEventListener("keydown",g,{capture:!0,passive:!1}),f}function m(){if(l.active)return n.removeEventListener("focusin",b,!0),n.removeEventListener("mousedown",h,!0),n.removeEventListener("touchstart",h,!0),n.removeEventListener("click",w,!0),n.removeEventListener("keydown",g,!0),f}function v(e){var t=u[e],r=t;if(!t)return null;if("string"==typeof t&&!(r=n.querySelector(t)))throw new Error("`"+e+"` refers to no known node");if("function"==typeof t&&!(r=t()))throw new Error("`"+e+"` did not return a node");return r}function y(){var e;if(!(e=null!==v("initialFocus")?v("initialFocus"):o.contains(n.activeElement)?n.activeElement:l.firstTabbableNode||v("fallbackFocus")))throw new Error("Your focus-trap needs to have at least one focusable element");return e}function h(e){o.contains(e.target)||(u.clickOutsideDeactivates?p({returnFocus:!a.isFocusable(e.target)}):u.allowOutsideClick&&u.allowOutsideClick(e)||e.preventDefault())}function b(e){o.contains(e.target)||e.target instanceof Document||(e.stopImmediatePropagation(),O(l.mostRecentlyFocusedNode||y()))}function g(e){if(!1!==u.escapeDeactivates&&function(e){return"Escape"===e.key||"Esc"===e.key||27===e.keyCode}(e))return e.preventDefault(),void p();(function(e){return"Tab"===e.key||9===e.keyCode})(e)&&function(e){if(E(),e.shiftKey&&e.target===l.firstTabbableNode)return e.preventDefault(),void O(l.lastTabbableNode);e.shiftKey||e.target!==l.lastTabbableNode||(e.preventDefault(),O(l.firstTabbableNode))}(e)}function w(e){u.clickOutsideDeactivates||o.contains(e.target)||u.allowOutsideClick&&u.allowOutsideClick(e)||(e.preventDefault(),e.stopImmediatePropagation())}function E(){var e=a(o);l.firstTabbableNode=e[0]||y(),l.lastTabbableNode=e[e.length-1]||y()}function O(e){e!==n.activeElement&&(e&&e.focus?(e.focus(),l.mostRecentlyFocusedNode=e,function(e){return e.tagName&&"input"===e.tagName.toLowerCase()&&"function"==typeof e.select}(e)&&e.select()):O(y()))}}},703:(e,t,n)=>{"use strict";var r=n(414);function o(){}function a(){}a.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,a,i){if(i!==r){var c=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 c.name="Invariant Violation",c}}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:a,resetWarningCache:o};return n.PropTypes=n,n}},697:(e,t,n)=>{e.exports=n(703)()},414:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},760:e=>{var t=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'],n=t.join(","),r="undefined"==typeof Element?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector;function o(e,t){t=t||{};var o,i,c,l=[],f=[],p=e.querySelectorAll(n);for(t.includeContainer&&r.call(e,n)&&(p=Array.prototype.slice.apply(p)).unshift(e),o=0;o<p.length;o++)a(i=p[o])&&(0===(c=s(i))?l.push(i):f.push({documentOrder:o,tabIndex:c,node:i}));return f.sort(u).map((function(e){return e.node})).concat(l)}function a(e){return!(!i(e)||function(e){return function(e){return l(e)&&"radio"===e.type}(e)&&!function(e){if(!e.name)return!0;var t=function(e){for(var t=0;t<e.length;t++)if(e[t].checked)return e[t]}(e.ownerDocument.querySelectorAll('input[type="radio"][name="'+e.name+'"]'));return!t||t===e}(e)}(e)||s(e)<0)}function i(e){return!(e.disabled||function(e){return l(e)&&"hidden"===e.type}(e)||function(e){return null===e.offsetParent||"hidden"===getComputedStyle(e).visibility}(e))}o.isTabbable=function(e){if(!e)throw new Error("No node provided");return!1!==r.call(e,n)&&a(e)},o.isFocusable=function(e){if(!e)throw new Error("No node provided");return!1!==r.call(e,c)&&i(e)};var c=t.concat("iframe").join(",");function s(e){var t=parseInt(e.getAttribute("tabindex"),10);return isNaN(t)?function(e){return"true"===e.contentEditable}(e)?0:e.tabIndex:t}function u(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex}function l(e){return"INPUT"===e.tagName}e.exports=o},529:e=>{e.exports=function(){for(var e={},n=0;n<arguments.length;n++){var r=arguments[n];for(var o in r)t.call(r,o)&&(e[o]=r[o])}return e};var t=Object.prototype.hasOwnProperty}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var a=t[r]={exports:{}};return e[r](a,a.exports,n),a.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";const e=window.wp.element,t=window.wp.i18n;var r=n(184),o=n.n(r);const a=window.ctEvents;var i=n.n(a);const c=window.blocksyOptions,s=window.React;var u=n.n(s);function l(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function f(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}n(697);var p=function(e){return e.initialState,e.getInitialState,e.refs,e.getRefs,e.didMount,e.didUpdate,e.willUnmount,e.getSnapshotBeforeUpdate,e.shouldUpdate,e.render,function(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}(e,["initialState","getInitialState","refs","getRefs","didMount","didUpdate","willUnmount","getSnapshotBeforeUpdate","shouldUpdate","render"])},d=function(e){function t(){var n,r;l(this,t);for(var o=arguments.length,a=Array(o),i=0;i<o;i++)a[i]=arguments[i];return n=r=f(this,e.call.apply(e,[this].concat(a))),m.call(r),f(r,n)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),t.prototype.getArgs=function(){var e=this.state,t=this.props,n=this._setState,r=this._forceUpdate,o=this._refs;return{state:e,props:p(t),refs:o,setState:n,forceUpdate:r}},t.prototype.componentDidMount=function(){this.props.didMount&&this.props.didMount(this.getArgs())},t.prototype.shouldComponentUpdate=function(e,t){return!this.props.shouldUpdate||this.props.shouldUpdate({props:this.props,state:this.state,nextProps:p(e),nextState:t})},t.prototype.componentWillUnmount=function(){this.props.willUnmount&&this.props.willUnmount({state:this.state,props:p(this.props),refs:this._refs})},t.prototype.componentDidUpdate=function(e,t,n){this.props.didUpdate&&this.props.didUpdate(Object.assign(this.getArgs(),{prevProps:p(e),prevState:t}),n)},t.prototype.getSnapshotBeforeUpdate=function(e,t){return this.props.getSnapshotBeforeUpdate?this.props.getSnapshotBeforeUpdate(Object.assign(this.getArgs(),{prevProps:p(e),prevState:t})):null},t.prototype.render=function(){var e=this.props,t=e.children,n=e.render;return n?n(this.getArgs()):"function"==typeof t?t(this.getArgs()):t||null},t}(u().Component);d.defaultProps={getInitialState:function(){},getRefs:function(){return{}}};var m=function(){var e=this;this.state=this.props.initialState||this.props.getInitialState(this.props),this._refs=this.props.refs||this.props.getRefs(this.getArgs()),this._setState=function(){return e.setState.apply(e,arguments)},this._forceUpdate=function(){return e.forceUpdate.apply(e,arguments)}};const v=d,y=function(t){var n=t.children,r=t.container,o=void 0===r?document.body:r,a=t.type,i=void 0===a?"reach-portal":a;return(0,e.createElement)(v,{getRefs:function(){return{node:null}},didMount:function(e){var t=e.refs,n=e.forceUpdate,r=o.hasOwnProperty("current")?o.current:o;t.node=document.createElement(i),r.appendChild(t.node),n()},willUnmount:function(e){var t=e.refs.node,n=o.hasOwnProperty("current")?o.current:o;n&&n.removeChild(t)},render:function(t){var r=t.refs.node;return r?(0,e.createPortal)(n,r):null}})};var h=function(e,t){return function(n){if(e&&e(n),!n.defaultPrevented)return t(n)}},b=n(172),g=n.n(b);function w(){return w=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},w.apply(this,arguments)}function E(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var O=function(){},S=function(){},x=function(e){var t=e.refs;t.trap.deactivate(),t.disposeAriaHider()},_=React.createContext(),k=React.forwardRef((function(t,n){var r=t.container,o=t.isOpen,a=void 0===o||o,i=t.onDismiss,c=void 0===i?O:i,s=t.initialFocusRef,u=t.onClick,l=t.onKeyDown,f=E(t,["container","isOpen","onDismiss","initialFocusRef","onClick","onKeyDown"]);return(0,e.createElement)(v,{didMount:S},a?(0,e.createElement)(y,{container:r,"data-reach-dialog-wrapper":!0},(0,e.createElement)(v,{refs:{overlayNode:null,contentNode:null},didMount:function(e){!function(e,t){var n,r,o;e.disposeAriaHider=(n=e.overlayNode,r=[],o=[],Array.prototype.forEach.call(document.querySelectorAll("body > *"),(function(e){if(e!==n.parentNode){var t=e.getAttribute("aria-hidden");null!==t&&"false"!==t||(r.push(t),o.push(e),e.setAttribute("aria-hidden","true"))}})),function(){o.forEach((function(e,t){var n=r[t];null===n?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",n)}))}),e.trap=g()(e.overlayNode,{initialFocus:t?function(){return t.current}:void 0,fallbackFocus:e.contentNode,escapeDeactivates:!1,clickOutsideDeactivates:!1})}(e.refs,s)},willUnmount:x},(function(t){var r=t.refs;return(0,e.createElement)(_.Provider,{value:function(e){return r.contentNode=e}},(0,e.createElement)("div",w({"data-reach-dialog-overlay":!0,onClick:h(u,(function(e){e.stopPropagation(),c()})),onKeyDown:h(l,(function(e){"Escape"===e.key&&(e.stopPropagation(),c())})),ref:function(e){r.overlayNode=e,n&&n(e)}},f)))}))):null)}));k.propTypes={initialFocusRef:function(){}};var j=function(e){return e.stopPropagation()},C=React.forwardRef((function(t,n){var r=t.onClick,o=(t.onKeyDown,E(t,["onClick","onKeyDown"]));return(0,e.createElement)(_.Consumer,null,(function(t){return(0,e.createElement)("div",w({"aria-modal":"true","data-reach-dialog-content":!0,tabIndex:"-1",onClick:h(r,j),ref:function(e){t(e),n&&n(e)}},o))}))})),A=function(e){return!!e};const N=function(t){var n=t.items,r=t.isVisible,a=void 0===r?A:r,i=t.render,s=t.className,u=t.onDismiss;return(0,e.createElement)(c.Transition,{items:n,onStart:function(){return document.body.classList[a(n)?"add":"remove"]("ct-dashboard-overlay-open")},config:{duration:200},from:{opacity:0,y:-10},enter:{opacity:1,y:0},leave:{opacity:0,y:10}},(function(t){return a(t)&&function(n){return(0,e.createElement)(k,{style:{opacity:n.opacity},container:document.querySelector("#wpbody"),onDismiss:function(){return u()}},(0,e.createElement)(C,{className:o()("ct-admin-modal",s),style:{transform:"translate3d(0px, ".concat(n.y,"px, 0px)")}},(0,e.createElement)("button",{className:"close-button",onClick:function(){return u()}},"×"),i(t,n)))}}))};function P(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function D(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?P(Object(n),!0).forEach((function(t){T(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):P(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function T(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function U(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,a=void 0;try{for(var i,c=e[Symbol.iterator]();!(r=(i=c.next()).done)&&(n.push(i.value),!t||n.length!==t);r=!0);}catch(e){o=!0,a=e}finally{try{r||null==c.return||c.return()}finally{if(o)throw a}}return n}}(e,t)||function(e,t){if(e){if("string"==typeof e)return I(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?I(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function I(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}const R=function(n){var r=n.extsSyncLoading,a=n.extensionData,i=n.onExtsSync,s=U((0,e.useState)(!1),2),u=s[0],l=s[1],f=U((0,e.useState)(null),2),p=f[0],d=f[1];return(0,e.createElement)(e.Fragment,null,(0,e.createElement)("button",{className:"ct-button ct-config-btn","data-button":"white",onClick:function(){l(!0),d(a.settings)}},(0,t.__)("Configure","blocksy-companion")),(0,e.createElement)(N,{items:u,onDismiss:function(){return l(!1)},className:"ct-product-reviews-settings-modal",render:function(){return(0,e.createElement)("div",{className:o()("ct-modal-content")},(0,e.createElement)("h2",null,(0,t.__)("Product Reviews Settings","blocksy-companion")),(0,e.createElement)("p",{className:"ct-modal-description"},(0,t.__)("Configure the slugs for single and category pages of the product review custom post type.","blocksy-companion")),(0,e.createElement)("div",{className:"ct-controls-group"},(0,e.createElement)("section",{"data-columns":"medium:2"},(0,e.createElement)(c.OptionsPanel,{onChange:function(e,t){return d((function(n){return D(D({},n),{},T({},e,t))}))},options:{single_slug:{type:"text",value:"",label:(0,t.__)("Single Slug","blocksy-companion")},category_slug:{type:"text",value:"",label:(0,t.__)("Category Slug","blocksy-companion")}},value:p||{},hasRevertButton:!1}))),(0,e.createElement)("div",{className:"ct-modal-actions has-divider"},(0,e.createElement)("button",{className:"button-primary",disabled:r||!p,onClick:function(e){e.preventDefault(),p&&(i({extAction:{type:"persist",settings:p}}),l(!1))}},r?(0,e.createElement)("svg",{width:"15",height:"15",viewBox:"0 0 100 100"},(0,e.createElement)("g",{transform:"translate(50,50)"},(0,e.createElement)("g",{transform:"scale(1)"},(0,e.createElement)("circle",{cx:"0",cy:"0",r:"50",fill:"#687c93"}),(0,e.createElement)("circle",{cx:"0",cy:"-26",r:"12",fill:"#ffffff",transform:"rotate(161.634)"},(0,e.createElement)("animateTransform",{attributeName:"transform",type:"rotate",calcMode:"linear",values:"0 0 0;360 0 0",keyTimes:"0;1",dur:"1s",begin:"0s",repeatCount:"indefinite"}))))):(0,t.__)("Save","blocksy-companion"))))}}))};function F(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}const M=function(t){var n,r,o=(n=(0,e.useState)(!1),r=2,function(e){if(Array.isArray(e))return e}(n)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,a=void 0;try{for(var i,c=e[Symbol.iterator]();!(r=(i=c.next()).done)&&(n.push(i.value),!t||n.length!==t);r=!0);}catch(e){o=!0,a=e}finally{try{r||null==c.return||c.return()}finally{if(o)throw a}}return n}}(n,r)||function(e,t){if(e){if("string"==typeof e)return F(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?F(e,t):void 0}}(n,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),a=o[0],i=o[1];return[function(){return i(!0)},(0,e.createElement)(N,{items:a,onDismiss:function(){return i(!1)},render:function(){return(0,e.createElement)("div",{className:"ct-modal-content",dangerouslySetInnerHTML:{__html:t.readme}})}})]};var L=window.ctDashboardLocalizations.DashboardContext;L.Provider,L.Consumer;const B=L;function z(e,t,n,r,o,a,i){try{var c=e[a](i),s=c.value}catch(e){return void n(e)}c.done?t(s):Promise.resolve(s).then(r,o)}function q(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var a=e.apply(t,n);function i(e){z(a,r,o,i,c,"next",e)}function c(e){z(a,r,o,i,c,"throw",e)}i(void 0)}))}}function K(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,a=void 0;try{for(var i,c=e[Symbol.iterator]();!(r=(i=c.next()).done)&&(n.push(i.value),!t||n.length!==t);r=!0);}catch(e){o=!0,a=e}finally{try{r||null==c.return||c.return()}finally{if(o)throw a}}return n}}(e,t)||function(e,t){if(e){if("string"==typeof e)return H(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?H(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function H(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function W(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,a=void 0;try{for(var i,c=e[Symbol.iterator]();!(r=(i=c.next()).done)&&(n.push(i.value),!t||n.length!==t);r=!0);}catch(e){o=!0,a=e}finally{try{r||null==c.return||c.return()}finally{if(o)throw a}}return n}}(e,t)||function(e,t){if(e){if("string"==typeof e)return $(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?$(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function $(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}const V=function(n){var r=n.extsSyncLoading,a=n.extension,i=n.onExtsSync,c=W(function(n){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){},o=K((0,e.useState)(!1),2),a=o[0],i=o[1],c=K((0,e.useState)(!1),2),s=c[0],u=c[1],l=(0,e.useContext)(B),f=(l.Link,l.history),p=ctDashboardLocalizations.plugin_data.is_pro,d=function(){var e=q(regeneratorRuntime.mark((function e(){var t;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(p||!n.config.pro){e.next=3;break}return u(!0),e.abrupt("return");case 3:return(t=new FormData).append("ext",n.name),t.append("action",n.__object?"blocksy_extension_deactivate":"blocksy_extension_activate"),i(!0),e.prev=7,e.next=10,fetch(ctDashboardLocalizations.ajax_url,{method:"POST",body:t});case 10:n.config.require_refresh&&location.reload(),r(),e.next=16;break;case 14:e.prev=14,e.t0=e.catch(7);case 16:i(!1);case 17:case"end":return e.stop()}}),e,null,[[7,14]])})));return function(){return e.apply(this,arguments)}}();return[a,d,!p&&n.config.pro?(0,e.createElement)(N,{items:s,className:"ct-onboarding-modal",onDismiss:function(){return u(!1)},render:function(){return(0,e.createElement)("div",{className:"ct-modal-content"},(0,e.createElement)("svg",{width:"55",height:"55",viewBox:"0 0 40.5 48.3"},(0,e.createElement)("path",{fill:"#2d82c8",d:"M33.4 29.4l7.1 12.3-7.4.6-4 6-7.3-12.9"}),(0,e.createElement)("path",{d:"M33.5 29.6L26 42.7l-4.2-7.3 11.6-6 .1.2zM0 41.7l7.5.6 3.9 6 7.2-12.4-11-7.3L0 41.7z",fill:"#2271b1"}),(0,e.createElement)("path",{d:"M39.5 18.7c0 1.6-2.4 2.8-2.7 4.3-.4 1.5 1 3.8.2 5.1-.8 1.3-3.4 1.2-4.5 2.3-1.1 1.1-1 3.7-2.3 4.5-1.3.8-3.6-.6-5.1-.2-1.5.4-2.7 2.7-4.3 2.7S18 35 16.5 34.7c-1.5-.4-3.8 1-5.1.2s-1.2-3.4-2.3-4.5-3.7-1-4.5-2.3.6-3.6.2-5.1-2.7-2.7-2.7-4.3 2.4-2.8 2.7-4.3c.4-1.5-1-3.8-.2-5.1C5.4 8 8.1 8.1 9.1 7c1.1-1.1 1-3.7 2.3-4.5s3.6.6 5.1.2C18 2.4 19.2 0 20.8 0c1.6 0 2.8 2.4 4.3 2.7 1.5.4 3.8-1 5.1-.2 1.3.8 1.2 3.4 2.3 4.5 1.1 1.1 3.7 1 4.5 2.3s-.6 3.6-.2 5.1c.3 1.5 2.7 2.7 2.7 4.3z",fill:"#599fd9"}),(0,e.createElement)("path",{d:"M23.6 7c-6.4-1.5-12.9 2.5-14.4 8.9-.7 3.1-.2 6.3 1.5 9.1 1.7 2.7 4.3 4.6 7.4 5.4.9.2 1.9.3 2.8.3 2.2 0 4.4-.6 6.3-1.8 2.7-1.7 4.6-4.3 5.4-7.5C34 15 30 8.5 23.6 7zm7 14c-.6 2.6-2.2 4.8-4.5 6.2-2.3 1.4-5 1.8-7.6 1.2-2.6-.6-4.8-2.2-6.2-4.5-1.4-2.3-1.8-5-1.2-7.6.6-2.6 2.2-4.8 4.5-6.2 1.6-1 3.4-1.5 5.2-1.5.8 0 1.5.1 2.3.3 5.4 1.3 8.7 6.7 7.5 12.1zm-8.2-4.5l3.7.5-2.7 2.7.7 3.7-3.4-1.8-3.3 1.8.6-3.7-2.7-2.7 3.8-.5 1.6-3.4 1.7 3.4z",fill:"#fff"})),(0,e.createElement)("h2",{className:"ct-modal-title"},"This is a Pro extension"),(0,e.createElement)("p",null,(0,t.__)("Upgrade to the Pro version and get instant access to all premium extensions, features and future updates.","blocksy-companion")),(0,e.createElement)("div",{className:"ct-modal-actions has-divider","data-buttons":"2"},(0,e.createElement)("a",{onClick:function(e){e.preventDefault(),u(!1),setTimeout((function(){f.navigate("/pro")}),300)},className:"button"},(0,t.__)("Free vs Pro","blocksy")),(0,e.createElement)("a",{href:"https://creativethemes.com/blocksy/pricing/",target:"_blank",className:"button button-primary"},(0,t.__)("Upgrade Now","blocksy-companion"))))}}):null]}(a,(function(){return i()})),2),s=c[0],u=c[1],l=W(M(a),2),f=l[0],p=l[1];return(0,e.createElement)("li",{className:o()({active:!!a.__object})},(0,e.createElement)("h4",{className:"ct-extension-title"},a.config.name,s&&(0,e.createElement)("svg",{width:"15",height:"15",viewBox:"0 0 100 100"},(0,e.createElement)("g",{transform:"translate(50,50)"},(0,e.createElement)("g",{transform:"scale(1)"},(0,e.createElement)("circle",{cx:"0",cy:"0",r:"50",fill:"#687c93"}),(0,e.createElement)("circle",{cx:"0",cy:"-26",r:"12",fill:"#ffffff",transform:"rotate(161.634)"},(0,e.createElement)("animateTransform",{attributeName:"transform",type:"rotate",calcMode:"linear",values:"0 0 0;360 0 0",keyTimes:"0;1",dur:"1s",begin:"0s",repeatCount:"indefinite"})))))),a.config.description&&(0,e.createElement)("div",{className:"ct-extension-description"},a.config.description),(0,e.createElement)("div",{className:"ct-extension-actions"},(0,e.createElement)("button",{className:o()(a.__object?"ct-button":"ct-button-primary"),"data-button":"white",disabled:s,onClick:function(){u()}},a.__object?(0,t.__)("Deactivate","blocksy-companion"):(0,t.__)("Activate","blocksy-companion")),a.__object&&(0,e.createElement)(R,{extsSyncLoading:r,extensionData:a.data,onExtsSync:i}),a.readme&&(0,e.createElement)("button",{onClick:function(){return f()},"data-button":"white",className:"ct-minimal-button ct-instruction"},(0,e.createElement)("svg",{width:"16",height:"16",viewBox:"0 0 24 24"},(0,e.createElement)("path",{d:"M12,2C6.477,2,2,6.477,2,12s4.477,10,10,10s10-4.477,10-10S17.523,2,12,2z M12,17L12,17c-0.552,0-1-0.448-1-1v-4 c0-0.552,0.448-1,1-1h0c0.552,0,1,0.448,1,1v4C13,16.552,12.552,17,12,17z M12.5,9h-1C11.224,9,11,8.776,11,8.5v-1 C11,7.224,11.224,7,11.5,7h1C12.776,7,13,7.224,13,7.5v1C13,8.776,12.776,9,12.5,9z"})))),p)};i().on("ct:extensions:card",(function(e){var t=e.CustomComponent;"product-reviews"===e.extension.name&&(t.extension=V)}))})()})();
|
|
|
|
|
|
|
|
framework/extensions/product-reviews/static/bundle/dashboard.js.LICENSE.txt
ADDED
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/*!
|
2 |
+
Copyright (c) 2017 Jed Watson.
|
3 |
+
Licensed under the MIT License (MIT), see
|
4 |
+
http://jedwatson.github.io/classnames
|
5 |
+
*/
|
framework/extensions/product-reviews/static/bundle/main-admin.min.css
CHANGED
@@ -1,8 +1,12 @@
|
|
1 |
/**
|
2 |
-
* - v1.8.
|
3 |
*
|
4 |
* Copyright (c) 2022
|
5 |
* Licensed GPLv2+
|
6 |
*/
|
7 |
|
8 |
-
.ct-product-reviews-settings-modal .ct-controls-group{
|
|
|
|
|
|
|
|
1 |
/**
|
2 |
+
* - v1.8.35
|
3 |
*
|
4 |
* Copyright (c) 2022
|
5 |
* Licensed GPLv2+
|
6 |
*/
|
7 |
|
8 |
+
.ct-product-reviews-settings-modal .ct-controls-group {
|
9 |
+
padding-top: 30px;
|
10 |
+
margin-top: 5px;
|
11 |
+
border-top: 1px dashed #eee;
|
12 |
+
}
|
framework/extensions/product-reviews/static/bundle/main.min.css
CHANGED
@@ -1,8 +1,192 @@
|
|
1 |
/**
|
2 |
-
* - v1.8.
|
3 |
*
|
4 |
* Copyright (c) 2022
|
5 |
* Licensed GPLv2+
|
6 |
*/
|
7 |
|
8 |
-
.ct-product-hero .flexy-container
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
/**
|
2 |
+
* - v1.8.35
|
3 |
*
|
4 |
* Copyright (c) 2022
|
5 |
* Licensed GPLv2+
|
6 |
*/
|
7 |
|
8 |
+
.ct-product-hero .flexy-container {
|
9 |
+
overflow: hidden;
|
10 |
+
}
|
11 |
+
@media (max-width: 999.98px) {
|
12 |
+
.ct-product-hero .flexy-pills {
|
13 |
+
--thumbs-spacing: 10px;
|
14 |
+
}
|
15 |
+
}
|
16 |
+
@media (min-width: 1000px) {
|
17 |
+
.ct-product-hero .flexy-pills {
|
18 |
+
max-width: 70%;
|
19 |
+
margin: -8% auto 0 auto;
|
20 |
+
--thumbs-spacing: 20px;
|
21 |
+
}
|
22 |
+
}
|
23 |
+
.ct-product-hero .flexy-pills ol {
|
24 |
+
margin: 0 calc(var(--thumbs-spacing) * -1);
|
25 |
+
}
|
26 |
+
.ct-product-hero .flexy-pills li {
|
27 |
+
padding-top: var(--thumbs-spacing);
|
28 |
+
padding-left: var(--thumbs-spacing);
|
29 |
+
padding-right: var(--thumbs-spacing);
|
30 |
+
}
|
31 |
+
.ct-product-hero .flexy-pills li img {
|
32 |
+
width: 100%;
|
33 |
+
border-radius: 3px;
|
34 |
+
border-radius: 2px;
|
35 |
+
border: 3px solid #fff;
|
36 |
+
}
|
37 |
+
|
38 |
+
.ct-product-hero .hero-section:not(:first-child) {
|
39 |
+
margin-top: var(--margin-bottom, 40px);
|
40 |
+
}
|
41 |
+
|
42 |
+
.ct-product-scores {
|
43 |
+
display: grid;
|
44 |
+
grid-column-gap: 25px;
|
45 |
+
grid-row-gap: 25px;
|
46 |
+
margin: 0 auto;
|
47 |
+
max-width: var(--product-scores-width, 800px);
|
48 |
+
}
|
49 |
+
@media (min-width: 690px) {
|
50 |
+
.ct-product-scores {
|
51 |
+
grid-template-columns: 2fr 1fr;
|
52 |
+
}
|
53 |
+
}
|
54 |
+
.ct-product-scores:not(:last-child) {
|
55 |
+
margin-bottom: 60px;
|
56 |
+
}
|
57 |
+
.ct-product-scores li {
|
58 |
+
display: flex;
|
59 |
+
flex-wrap: wrap;
|
60 |
+
align-items: center;
|
61 |
+
justify-content: space-between;
|
62 |
+
padding: 10px 20px;
|
63 |
+
background: rgba(243, 243, 243, 0.5);
|
64 |
+
border-radius: 2px;
|
65 |
+
}
|
66 |
+
.ct-product-scores li:hover {
|
67 |
+
background: rgb(243, 243, 243);
|
68 |
+
}
|
69 |
+
.ct-product-scores li > span {
|
70 |
+
font-size: 15px;
|
71 |
+
font-weight: 500;
|
72 |
+
}
|
73 |
+
|
74 |
+
.ct-overall-score {
|
75 |
+
display: flex;
|
76 |
+
flex-direction: column;
|
77 |
+
align-items: center;
|
78 |
+
justify-content: center;
|
79 |
+
padding: 20px;
|
80 |
+
color: var(--overall-score-text-color, #fff);
|
81 |
+
border-radius: 2px;
|
82 |
+
background: var(--overall-score-box-background, #1A202C);
|
83 |
+
}
|
84 |
+
.ct-overall-score .ct-average-score {
|
85 |
+
font-size: 55px;
|
86 |
+
font-weight: 800;
|
87 |
+
line-height: normal;
|
88 |
+
margin-bottom: 10px;
|
89 |
+
}
|
90 |
+
.ct-overall-score .ct-score-label {
|
91 |
+
font-size: 15px;
|
92 |
+
font-weight: 700;
|
93 |
+
text-transform: uppercase;
|
94 |
+
letter-spacing: 0.02em;
|
95 |
+
margin: 15px 0 0 0;
|
96 |
+
}
|
97 |
+
|
98 |
+
.ct-overall-score-layer {
|
99 |
+
display: flex;
|
100 |
+
flex-wrap: wrap;
|
101 |
+
align-items: center;
|
102 |
+
}
|
103 |
+
.ct-overall-score-layer .ct-score-label,
|
104 |
+
.ct-overall-score-layer .ct-average-score {
|
105 |
+
font-size: 14px;
|
106 |
+
font-weight: 600;
|
107 |
+
}
|
108 |
+
.ct-overall-score-layer .ct-average-score {
|
109 |
+
margin: 0 5px;
|
110 |
+
margin-inline-end: auto;
|
111 |
+
}
|
112 |
+
.ct-overall-score-layer .star-rating {
|
113 |
+
margin: 3px 0;
|
114 |
+
}
|
115 |
+
|
116 |
+
.ct-product-actions-group {
|
117 |
+
display: flex;
|
118 |
+
align-items: center;
|
119 |
+
justify-content: center;
|
120 |
+
}
|
121 |
+
.ct-product-actions-group:not(:last-child) {
|
122 |
+
margin-bottom: 60px;
|
123 |
+
}
|
124 |
+
.ct-product-actions-group .ct-button:not(:last-child) {
|
125 |
+
margin-inline-end: 25px;
|
126 |
+
}
|
127 |
+
.ct-product-actions-group .ct-icon-container {
|
128 |
+
color: inherit;
|
129 |
+
margin-inline-start: 10px;
|
130 |
+
}
|
131 |
+
|
132 |
+
.ct-product-description:not(:last-child) {
|
133 |
+
margin-bottom: 60px;
|
134 |
+
}
|
135 |
+
|
136 |
+
.ct-product-info {
|
137 |
+
display: grid;
|
138 |
+
grid-template-columns: var(--grid-template-columns);
|
139 |
+
grid-column-gap: 40px;
|
140 |
+
grid-row-gap: 40px;
|
141 |
+
border-top: 1px solid #ececec;
|
142 |
+
padding-top: var(--content-vertical-spacing, 60px);
|
143 |
+
}
|
144 |
+
@media (min-width: 1000px) {
|
145 |
+
.ct-product-info {
|
146 |
+
--grid-template-columns: 1.5fr 1fr 1fr;
|
147 |
+
}
|
148 |
+
}
|
149 |
+
@media (min-width: 690px) and (max-width: 999.98px) {
|
150 |
+
.ct-product-info {
|
151 |
+
--grid-template-columns: 1fr 1fr;
|
152 |
+
}
|
153 |
+
}
|
154 |
+
.ct-product-info li {
|
155 |
+
position: relative;
|
156 |
+
padding-inline-start: 22px;
|
157 |
+
}
|
158 |
+
.ct-product-info .ct-icon-container {
|
159 |
+
position: absolute;
|
160 |
+
left: 0;
|
161 |
+
top: 0.4em;
|
162 |
+
opacity: 0.8;
|
163 |
+
--icon-size: 13px;
|
164 |
+
}
|
165 |
+
|
166 |
+
@media (min-width: 690px) and (max-width: 999.98px) {
|
167 |
+
.ct-specs {
|
168 |
+
grid-column: 1/-1;
|
169 |
+
}
|
170 |
+
}
|
171 |
+
.ct-specs ul {
|
172 |
+
display: grid;
|
173 |
+
grid-column-gap: 40px;
|
174 |
+
}
|
175 |
+
@media (min-width: 690px) {
|
176 |
+
.ct-specs ul {
|
177 |
+
grid-template-columns: repeat(2, 1fr);
|
178 |
+
}
|
179 |
+
}
|
180 |
+
|
181 |
+
.ct-product-hero {
|
182 |
+
padding-top: var(--content-vertical-spacing, 60px);
|
183 |
+
}
|
184 |
+
.ct-product-hero .ct-container {
|
185 |
+
padding-bottom: var(--content-vertical-spacing, 60px);
|
186 |
+
border-bottom: 1px solid #ececec;
|
187 |
+
}
|
188 |
+
.ct-product-hero ul {
|
189 |
+
--listIndent: 0;
|
190 |
+
--listStyleType: none;
|
191 |
+
--content-spacing: 0;
|
192 |
+
}
|
framework/extensions/product-reviews/static/bundle/sync.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
|
1 |
+
(()=>{"use strict";var r={n:e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},d:(e,t)=>{for(var o in t)r.o(t,o)&&!r.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},o:(r,e)=>Object.prototype.hasOwnProperty.call(r,e)};const e=window.blocksyCustomizerSync,t=window.ctEvents;function o(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(r);e&&(o=o.filter((function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),t.push.apply(t,o)}return t}function c(r){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?o(Object(t),!0).forEach((function(e){a(r,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):o(Object(t)).forEach((function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(t,e))}))}return r}function a(r,e,t){return e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}var l="blc-product-review_single";r.n(t)().on("ct:customizer:sync:collect-variable-descriptors",(function(r){var t;r.result=c(c({},r.result),{},(a(t={},"".concat(l,"_product_scores_width"),{selector:(0,e.applyPrefixFor)(".ct-product-scores",l),variable:"product-scores-width",unit:"px"}),a(t,"".concat(l,"_star_rating_color"),[{selector:(0,e.applyPrefixFor)(".ct-product-scores",l),variable:"star-rating-initial-color",type:"color:default"},{selector:(0,e.applyPrefixFor)(".ct-product-scores",l),variable:"star-rating-inactive-color",type:"color:inactive"}]),a(t,"".concat(l,"_overall_score_text"),[{selector:(0,e.applyPrefixFor)(".ct-product-scores",l),variable:"overall-score-text-color",type:"color:default"}]),a(t,"".concat(l,"_overall_score_backgroud"),[{selector:(0,e.applyPrefixFor)(".ct-product-scores",l),variable:"overall-score-box-background",type:"color:default"}]),t))}))})();
|
framework/extensions/trending/extension.php
CHANGED
@@ -113,11 +113,25 @@ class BlocksyExtensionTrending {
|
|
113 |
}
|
114 |
);
|
115 |
|
116 |
-
add_action(
|
117 |
-
|
118 |
-
|
119 |
-
|
120 |
-
|
121 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
122 |
}
|
123 |
}
|
113 |
}
|
114 |
);
|
115 |
|
116 |
+
add_action(
|
117 |
+
'blocksy:global-dynamic-css:enqueue',
|
118 |
+
'BlocksyExtensionTrending::add_global_styles',
|
119 |
+
10, 3
|
120 |
+
);
|
121 |
+
}
|
122 |
+
|
123 |
+
static public function add_global_styles($args) {
|
124 |
+
blocksy_theme_get_dynamic_styles(array_merge([
|
125 |
+
'path' => dirname(__FILE__) . '/global.php',
|
126 |
+
'chunk' => 'global',
|
127 |
+
], $args));
|
128 |
+
}
|
129 |
+
|
130 |
+
static public function onDeactivation() {
|
131 |
+
remove_action(
|
132 |
+
'blocksy:global-dynamic-css:enqueue',
|
133 |
+
'BlocksyExtensionTrending::add_global_styles',
|
134 |
+
10, 3
|
135 |
+
);
|
136 |
}
|
137 |
}
|
framework/extensions/trending/static/bundle/main.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
|
1 |
+
(()=>{"use strict";function t(t){return function(t){if(Array.isArray(t))return r(t)}(t)||function(t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(t))return Array.from(t)}(t)||n(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function e(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(t)){var n=[],r=!0,o=!1,a=void 0;try{for(var i,c=t[Symbol.iterator]();!(r=(i=c.next()).done)&&(n.push(i.value),!e||n.length!==e);r=!0);}catch(t){o=!0,a=t}finally{try{r||null==c.return||c.return()}finally{if(o)throw a}}return n}}(t,e)||n(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function n(t,e){if(t){if("string"==typeof t)return r(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(t,e):void 0}}function r(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function o(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function a(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?o(Object(n),!0).forEach((function(e){i(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function i(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var c={},l=function(t){return c[t]?new Promise((function(e){e(c[t]),window.ct_customizer_localizations||(c[t]=c[t].clone())})):new Promise((function(e){return fetch(t).then((function(n){e(n),window.ct_customizer_localizations||(c[t]=n.clone())}))}))},s=function(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if((n=a({el:null,action:null},n)).el&&n.action&&!n.el.classList.contains("ct-loading")){var r=parseInt(n.el.dataset.page,10);if(("prev"!==n.action||1!==r)&&!(n.el.querySelectorAll(".ct-container > a").length<4&&1===r||n.el.dataset.page.indexOf("last")>-1&&"next"===n.action)){n.el.classList.add("ct-loading");var o="prev"===n.action?r-1:r+1;Promise.all([new Promise((function(t){n.el.classList.add("ct-leave-active"),requestAnimationFrame((function(){n.el.classList.remove("ct-leave-active"),n.el.classList.add("ct-leave"),setTimeout((function(){return t()}),650)}))})),l("".concat(ct_localizations.ajax_url,"?action=blocksy_get_trending_posts&page=").concat(o)).then((function(t){return t.json()}))]).then((function(r){var a=e(r,2),i=(a[0],a[1]),c=i.success,l=i.data;if(c){var s=l.posts,u=s.is_last_page,f=s.posts;n.el.dataset.page="".concat(o).concat(u?":last":""),t(n.el.querySelectorAll("a")).map((function(t){return t.remove()})),f.map((function(t){return n.el.insertAdjacentHTML("beforeend",'<a href="'.concat(t.url,'">\n ').concat(t.image,'\n <span class="ct-item-title">\n ').concat(t.title,"\n </span>\n </a>"))})),setTimeout((function(){n.el.classList.remove("ct-leave"),n.el.classList.add("ct-enter-active"),requestAnimationFrame((function(){n.el.classList.remove("ct-enter-active"),n.el.classList.add("ct-active"),setTimeout((function(){n.el.classList.remove("ct-active"),n.el.classList.remove("ct-loading")}),650)}))}),50)}}))}}};(0,window.ctFrontend.registerDynamicChunk)("blocksy_ext_trending",{mount:function(t,e){e.event;var n=t.closest("[data-page]");t.classList.contains("ct-arrow-left")&&s({el:n,action:"prev"}),t.classList.contains("ct-arrow-right")&&s({el:n,action:"next"})}})})();
|
framework/extensions/trending/static/bundle/main.min.css
CHANGED
@@ -1,8 +1,145 @@
|
|
1 |
/**
|
2 |
-
* - v1.8.
|
3 |
*
|
4 |
* Copyright (c) 2022
|
5 |
* Licensed GPLv2+
|
6 |
*/
|
7 |
|
8 |
-
.ct-trending-block
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
/**
|
2 |
+
* - v1.8.35
|
3 |
*
|
4 |
* Copyright (c) 2022
|
5 |
* Licensed GPLv2+
|
6 |
*/
|
7 |
|
8 |
+
.ct-trending-block {
|
9 |
+
padding: var(--padding, 30px) 0;
|
10 |
+
}
|
11 |
+
.ct-trending-block > div {
|
12 |
+
display: grid;
|
13 |
+
grid-template-columns: var(--grid-template-columns);
|
14 |
+
grid-column-gap: 30px;
|
15 |
+
grid-row-gap: 20px;
|
16 |
+
margin-bottom: 5px;
|
17 |
+
}
|
18 |
+
@media (min-width: 690px) and (max-width: 999.98px) {
|
19 |
+
.ct-trending-block > div {
|
20 |
+
--grid-template-columns: repeat(2, 1fr);
|
21 |
+
}
|
22 |
+
}
|
23 |
+
@media (min-width: 1000px) {
|
24 |
+
.ct-trending-block > div {
|
25 |
+
--grid-template-columns: repeat(4, 1fr);
|
26 |
+
}
|
27 |
+
}
|
28 |
+
.ct-trending-block > div.ct-leave-active > a, .ct-trending-block > div.ct-leave > a {
|
29 |
+
transition: opacity 0.3s ease, transform 0.3s ease;
|
30 |
+
}
|
31 |
+
.ct-trending-block > div.ct-leave-active > a:nth-of-type(1), .ct-trending-block > div.ct-leave > a:nth-of-type(1) {
|
32 |
+
transition-delay: 0s;
|
33 |
+
}
|
34 |
+
.ct-trending-block > div.ct-leave-active > a:nth-of-type(2), .ct-trending-block > div.ct-leave > a:nth-of-type(2) {
|
35 |
+
transition-delay: 0.15s;
|
36 |
+
}
|
37 |
+
.ct-trending-block > div.ct-leave-active > a:nth-of-type(3), .ct-trending-block > div.ct-leave > a:nth-of-type(3) {
|
38 |
+
transition-delay: 0.25s;
|
39 |
+
}
|
40 |
+
.ct-trending-block > div.ct-leave-active > a:nth-of-type(4), .ct-trending-block > div.ct-leave > a:nth-of-type(4) {
|
41 |
+
transition-delay: 0.35s;
|
42 |
+
}
|
43 |
+
.ct-trending-block > div.ct-leave-active > a {
|
44 |
+
opacity: 1;
|
45 |
+
transform: translateY(0);
|
46 |
+
}
|
47 |
+
.ct-trending-block > div.ct-leave > a {
|
48 |
+
opacity: 0;
|
49 |
+
transform: translateY(3px);
|
50 |
+
}
|
51 |
+
.ct-trending-block > div.ct-enter-active > a, .ct-trending-block > div.ct-active > a {
|
52 |
+
transition: opacity 0.3s ease, transform 0.3s ease;
|
53 |
+
}
|
54 |
+
.ct-trending-block > div.ct-enter-active > a:nth-of-type(1), .ct-trending-block > div.ct-active > a:nth-of-type(1) {
|
55 |
+
transition-delay: 0s;
|
56 |
+
}
|
57 |
+
.ct-trending-block > div.ct-enter-active > a:nth-of-type(2), .ct-trending-block > div.ct-active > a:nth-of-type(2) {
|
58 |
+
transition-delay: 0.15s;
|
59 |
+
}
|
60 |
+
.ct-trending-block > div.ct-enter-active > a:nth-of-type(3), .ct-trending-block > div.ct-active > a:nth-of-type(3) {
|
61 |
+
transition-delay: 0.25s;
|
62 |
+
}
|
63 |
+
.ct-trending-block > div.ct-enter-active > a:nth-of-type(4), .ct-trending-block > div.ct-active > a:nth-of-type(4) {
|
64 |
+
transition-delay: 0.35s;
|
65 |
+
}
|
66 |
+
.ct-trending-block > div.ct-enter-active > a {
|
67 |
+
opacity: 0;
|
68 |
+
transform: translateY(3px);
|
69 |
+
}
|
70 |
+
.ct-trending-block > div.ct-active > a {
|
71 |
+
opacity: 1;
|
72 |
+
transform: translateY(0);
|
73 |
+
}
|
74 |
+
.ct-trending-block .ct-block-title {
|
75 |
+
--fontSize: 15px;
|
76 |
+
grid-column: 1/-1;
|
77 |
+
display: flex;
|
78 |
+
align-items: center;
|
79 |
+
margin-bottom: 10px;
|
80 |
+
--headings-color: var(--color);
|
81 |
+
}
|
82 |
+
.ct-trending-block .ct-block-title > svg {
|
83 |
+
margin-top: 4px;
|
84 |
+
margin-inline-start: 10px;
|
85 |
+
}
|
86 |
+
.ct-trending-block a {
|
87 |
+
display: flex;
|
88 |
+
align-items: center;
|
89 |
+
--linkInitialColor: var(--color);
|
90 |
+
}
|
91 |
+
.ct-trending-block .ct-image-container {
|
92 |
+
flex: 0 0 60px;
|
93 |
+
border-radius: 100%;
|
94 |
+
margin-inline-end: 20px;
|
95 |
+
-webkit-mask-image: -webkit-radial-gradient(white, black);
|
96 |
+
}
|
97 |
+
.ct-trending-block .ct-item-title {
|
98 |
+
word-break: break-word;
|
99 |
+
}
|
100 |
+
.ct-trending-block [class*=ct-arrow] {
|
101 |
+
display: flex;
|
102 |
+
align-items: center;
|
103 |
+
justify-content: center;
|
104 |
+
width: 23px;
|
105 |
+
height: 23px;
|
106 |
+
cursor: pointer;
|
107 |
+
background: transparent;
|
108 |
+
border-radius: 2px;
|
109 |
+
opacity: 0.5;
|
110 |
+
border: 1px solid var(--color);
|
111 |
+
transition: var(--transition);
|
112 |
+
}
|
113 |
+
.ct-trending-block [class*=ct-arrow]:before {
|
114 |
+
content: "";
|
115 |
+
width: 5px;
|
116 |
+
height: 5px;
|
117 |
+
border: 1px solid currentColor;
|
118 |
+
border-right: none;
|
119 |
+
border-bottom: none;
|
120 |
+
}
|
121 |
+
.ct-trending-block [class*=ct-arrow]:hover {
|
122 |
+
opacity: 1;
|
123 |
+
color: #fff;
|
124 |
+
border-color: var(--paletteColor1);
|
125 |
+
background: var(--paletteColor1);
|
126 |
+
}
|
127 |
+
.ct-trending-block .ct-arrow-left {
|
128 |
+
margin-inline-start: auto;
|
129 |
+
margin-inline-end: 8px;
|
130 |
+
padding-left: 1px;
|
131 |
+
}
|
132 |
+
.ct-trending-block .ct-arrow-left:before {
|
133 |
+
transform: rotate(-45deg);
|
134 |
+
}
|
135 |
+
.ct-trending-block .ct-arrow-right {
|
136 |
+
padding-right: 1px;
|
137 |
+
}
|
138 |
+
.ct-trending-block .ct-arrow-right:before {
|
139 |
+
transform: rotate(135deg);
|
140 |
+
}
|
141 |
+
.ct-trending-block [data-page="1"] .ct-arrow-left,
|
142 |
+
.ct-trending-block [data-page*=last] .ct-arrow-right {
|
143 |
+
opacity: 0.2;
|
144 |
+
pointer-events: none;
|
145 |
+
}
|
framework/extensions/trending/static/bundle/sync.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
|
1 |
+
(()=>{"use strict";var e={n:t=>{var r=t&&t.__esModule?()=>t.default:()=>t;return e.d(r,{a:r}),r},d:(t,r)=>{for(var n in r)e.o(r,n)&&!e.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:r[n]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t)};const t=window.blocksyCustomizerSync,r=window.ctEvents;function n(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function o(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?n(Object(r),!0).forEach((function(t){c(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):n(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function c(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}e.n(r)().on("ct:customizer:sync:collect-variable-descriptors",(function(e){e.result=o(o(o({},e.result),{},{trendingBlockContainerSpacing:{selector:".ct-trending-block",variable:"padding",responsive:!0,unit:""}},(0,t.typographyOption)({id:"trendingBlockPostsFont",selector:".ct-trending-block .ct-item-title"})),{},{trendingBlockFontColor:[{selector:".ct-trending-block",variable:"color",type:"color:default",responsive:!0},{selector:".ct-trending-block",variable:"linkHoverColor",type:"color:hover",responsive:!0}]},(0,t.handleBackgroundOptionFor)({id:"trending_block_background",selector:".ct-trending-block",responsive:!0}))})),wp.customize("trending_block_visibility",(function(e){return e.bind((function(e){return(0,t.responsiveClassesFor)("trending_block_visibility",document.querySelector(".ct-trending-block"))}))})),wp.customize("trending_block_label",(function(e){return e.bind((function(e){var t=document.querySelector(".ct-trending-block .ct-block-title");if(t){var r=t.innerHTML.split("<svg");r[0]=e,t.innerHTML=r.join("<svg")}}))}))})();
|
framework/extensions/widgets/static/bundle/main.min.css
CHANGED
@@ -1,8 +1,243 @@
|
|
1 |
/**
|
2 |
-
* - v1.8.
|
3 |
*
|
4 |
* Copyright (c) 2022
|
5 |
* Licensed GPLv2+
|
6 |
*/
|
7 |
|
8 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|