diff --git a/wp-content/plugins/menu-icons/CHANGELOG.md b/wp-content/plugins/menu-icons/CHANGELOG.md index 521880a0..e9e42461 100644 --- a/wp-content/plugins/menu-icons/CHANGELOG.md +++ b/wp-content/plugins/menu-icons/CHANGELOG.md @@ -1,3 +1,8 @@ +##### [Version 0.13.8](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.7...v0.13.8) (2023-12-19) + +- SDK Updates +- Fixed global hide label issue + ##### [Version 0.13.7](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.6...v0.13.7) (2023-08-17) - Updated dependencies diff --git a/wp-content/plugins/menu-icons/includes/front.php b/wp-content/plugins/menu-icons/includes/front.php index 7bfb0952..a411d97e 100644 --- a/wp-content/plugins/menu-icons/includes/front.php +++ b/wp-content/plugins/menu-icons/includes/front.php @@ -240,9 +240,11 @@ final class Menu_Icons_Front_End { if ( empty( $icon ) ) { return $title; } - - $title_class = ! empty( $meta['hide_label'] ) ? self::$hidden_label_class : ''; - $title_wrapped = sprintf( + $menu_id = Menu_Icons_Settings::get_current_menu_id(); + $menu_key = sprintf( 'menu_%d', $menu_id ); + $global_hide_label = Menu_Icons_Settings::get( $menu_key, 'hide_label' ); + $title_class = ! empty( $global_hide_label ) || ! empty( $meta['hide_label'] ) ? self::$hidden_label_class : ''; + $title_wrapped = sprintf( '%s', ( ! empty( $title_class ) ) ? sprintf( ' class="%s"', esc_attr( $title_class ) ) : '', $title diff --git a/wp-content/plugins/menu-icons/menu-icons.php b/wp-content/plugins/menu-icons/menu-icons.php index 2d1a8618..94d881d9 100644 --- a/wp-content/plugins/menu-icons/menu-icons.php +++ b/wp-content/plugins/menu-icons/menu-icons.php @@ -11,7 +11,7 @@ * Plugin name: Menu Icons * Plugin URI: https://github.com/Codeinwp/wp-menu-icons * Description: Spice up your navigation menus with pretty icons, easily. - * Version: 0.13.7 + * Version: 0.13.8 * Author: ThemeIsle * Author URI: https://themeisle.com * License: GPLv2 @@ -29,7 +29,7 @@ final class Menu_Icons { const DISMISS_NOTICE = 'menu-icons-dismiss-notice'; - const VERSION = '0.13.7'; + const VERSION = '0.13.8'; /** * Holds plugin data diff --git a/wp-content/plugins/menu-icons/readme.txt b/wp-content/plugins/menu-icons/readme.txt index a4b65b5d..93335fd5 100644 --- a/wp-content/plugins/menu-icons/readme.txt +++ b/wp-content/plugins/menu-icons/readme.txt @@ -2,7 +2,7 @@ Contributors: codeinwp, themeisle Tags: menu, nav-menu, icons, navigation Requires at least: 4.7 -Tested up to: 6.3 +Tested up to: 6.4 Stable tag: trunk License: GPLv2 License URI: http://www.gnu.org/licenses/gpl-2.0.html @@ -225,6 +225,14 @@ Read [this blog post](http://kucrut.org/add-custom-image-sizes-right-way/). == Changelog == +##### [Version 0.13.8](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.7...v0.13.8) (2023-12-19) + +- SDK Updates +- Fixed global hide label issue + + + + ##### [Version 0.13.7](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.6...v0.13.7) (2023-08-17) - Updated dependencies diff --git a/wp-content/plugins/menu-icons/vendor/autoload.php b/wp-content/plugins/menu-icons/vendor/autoload.php index 41055fe4..12c12d99 100644 --- a/wp-content/plugins/menu-icons/vendor/autoload.php +++ b/wp-content/plugins/menu-icons/vendor/autoload.php @@ -22,4 +22,4 @@ if (PHP_VERSION_ID < 50600) { require_once __DIR__ . '/composer/autoload_real.php'; -return ComposerAutoloaderInit2df3d2da63bd22bca27c5f9e05dba454::getLoader(); +return ComposerAutoloaderInite0e064cdd82a4be104872380c8a68791::getLoader(); diff --git a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/CHANGELOG.md b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/CHANGELOG.md index e0740cf0..095213d7 100644 --- a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/CHANGELOG.md +++ b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/CHANGELOG.md @@ -1,3 +1,42 @@ +##### [Version 3.3.11](https://github.com/Codeinwp/themeisle-sdk/compare/v3.3.10...v3.3.11) (2023-12-12) + +- fix: cached requests for wp options +- fix: php notice on failed xml feed + +##### [Version 3.3.10](https://github.com/Codeinwp/themeisle-sdk/compare/v3.3.9...v3.3.10) (2023-12-11) + +feat: add new filter for tsdk_utmify query arguments + +##### [Version 3.3.9](https://github.com/Codeinwp/themeisle-sdk/compare/v3.3.8...v3.3.9) (2023-11-16) + +- Fix: a debugging error when you activate Neve Pro after installing Otter & Otter Pro without the license. + +##### [Version 3.3.8](https://github.com/Codeinwp/themeisle-sdk/compare/v3.3.7...v3.3.8) (2023-11-14) + +- Add Product Telemetry + +##### [Version 3.3.7](https://github.com/Codeinwp/themeisle-sdk/compare/v3.3.6...v3.3.7) (2023-10-31) + +- fix: deprecating notice in Dashboard Widget + +##### [Version 3.3.6](https://github.com/Codeinwp/themeisle-sdk/compare/v3.3.5...v3.3.6) (2023-10-05) + +- Fix duplicate notification in Neve FSE +- Fix SDK breaking Enfold theme builder + +##### [Version 3.3.5](https://github.com/Codeinwp/themeisle-sdk/compare/v3.3.4...v3.3.5) (2023-09-29) + +Fix TPC message. +Fix TPC typo. + +##### [Version 3.3.4](https://github.com/Codeinwp/themeisle-sdk/compare/v3.3.3...v3.3.4) (2023-09-18) + +- Allow users to activate plugins from the About page + +##### [Version 3.3.3](https://github.com/Codeinwp/themeisle-sdk/compare/v3.3.2...v3.3.3) (2023-08-22) + +- Disable install buttons on the About page if users can not install plugins + ##### [Version 3.3.2](https://github.com/Codeinwp/themeisle-sdk/compare/v3.3.1...v3.3.2) (2023-08-02) - Added a new product page for Otter diff --git a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/about/about.asset.php b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/about/about.asset.php index 7d660bec..6aa2c6c2 100644 --- a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/about/about.asset.php +++ b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/about/about.asset.php @@ -1 +1 @@ - array('wp-components', 'wp-element'), 'version' => 'b9d5790c82f421f0773c'); + array('wp-components', 'wp-element'), 'version' => '35f2cdc94ec1bd5b9745'); diff --git a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/about/about.css b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/about/about.css index e435af20..90d73702 100644 --- a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/about/about.css +++ b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/about/about.css @@ -1,388 +1 @@ -/*!*******************************************************************************************************************************************************************************************************************************************************!*\ - !*** css ./node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[3].use[1]!./node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[3].use[2]!./node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[3].use[3]!./assets/js/src/about/about.scss ***! - \*******************************************************************************************************************************************************************************************************************************************************/ -#wpcontent { - padding-left: 0 !important; -} - -.ti-about { - --border: 1px solid #ccc; - --link-color: var(--wp-admin-theme-color); - -webkit-font-smoothing: antialiased; - -moz-osx-font-smoothing: grayscale; - line-height: normal; - display: grid; - gap: 30px; -} -.ti-about .container { - margin: 0 auto; - max-width: 960px; - padding: 0 15px; -} -.ti-about p { - font-size: 14px; - line-height: 1.6; -} -.ti-about button { - font-weight: 600; -} -.ti-about .spin { - animation: spin 1s infinite linear; -} -@keyframes spin { - 0% { - transform: rotate(0deg); - } - 100% { - transform: rotate(359deg); - } -} -.ti-about .head { - background: #fff; - border-bottom: var(--border); - padding: 18px 0; -} -.ti-about .head .container { - padding: 0 15px; - display: flex; - flex-wrap: wrap; - align-items: center; -} -.ti-about .head img { - max-height: 55px; -} -.ti-about .head p { - margin-left: 10px; -} -.ti-about .head a { - font-style: italic; - font-weight: bold; -} -.ti-about .nav { - border-bottom: var(--border); - display: flex; - flex-wrap: wrap; - font-size: 16px; - margin: 0; - font-weight: 600; - -moz-column-gap: 20px; - column-gap: 20px; -} -.ti-about .nav a { - border-bottom: 4px solid transparent; - color: #868686; - padding: 20px 10px; - text-decoration: none; - margin-bottom: -1px; - box-sizing: border-box; -} -.ti-about .nav a:hover { - color: #313233; -} -.ti-about .nav li { - display: flex; - margin: 0; -} -.ti-about .nav li.active a { - border-color: var(--link-color); - color: #313233; -} -.ti-about .story-card .footer, .ti-about .story-card .body { - display: grid; - grid-template-columns: var(--grid, 1fr); - align-items: center; -} -.ti-about .story-card { - border: var(--border); - border-radius: 0 0 10px 10px; -} -.ti-about .story-card .body { - background: #fff; - padding: 35px 35px 10px 35px; -} -.ti-about .story-card .body h2 { - font-size: 30px; - margin: 0 0 30px; - color: #1F1D1D; -} -.ti-about .story-card .body p { - color: #1E1E1E; -} -.ti-about .story-card .body figure { - order: 0; - margin: 0; -} -.ti-about .story-card .body figcaption { - margin: 10px 0; - color: #797979; - font-size: 12px; -} -.ti-about .story-card .body img { - border-radius: 8px; - max-width: 100%; -} -.ti-about .story-card .footer { - border-top: var(--border); - padding: 30px 40px; -} -.ti-about .story-card .footer h2 { - margin: 0 0 20px; - text-align: center; - font-size: 21px; -} -.ti-about .story-card form { - display: flex; - align-items: center; -} -.ti-about .story-card form .dashicons-yes-alt { - color: #609952; -} -.ti-about .story-card input { - height: 36px; - flex-grow: 1; - border: var(--border); - border-radius: 2px; - font-size: 12px; - margin-right: 15px; -} -.ti-about .product-cards { - display: grid; - gap: 30px; -} -.ti-about .product-card { - background: #fff; - display: grid; - border: var(--border); -} -.ti-about .product-card h2 { - font-size: 21px; - margin: 0; -} -.ti-about .product-card p { - margin: 0; - color: #6C6C6C; -} -.ti-about .product-card .header { - padding: 20px 15px 0; - display: flex; - align-items: center; -} -.ti-about .product-card .body { - padding: 20px 15px; -} -.ti-about .product-card img { - max-width: 50px; - margin-right: 15px; - border-radius: 6px; -} -.ti-about .product-card .footer { - border-top: var(--border); - display: flex; - align-items: center; - padding: 15px; - align-self: flex-end; -} -.ti-about .product-card .footer p { - margin: 8px 0; - font-weight: 600; - font-size: 13px; - color: #313233; -} -.ti-about .product-card .footer .not-installed { - color: #7E7E7E; -} -.ti-about .product-card .footer .active { - color: #609952; -} -.ti-about .product-card button, .ti-about .product-card a, .ti-about .product-card .spin { - margin-left: auto; - text-decoration: none; -} -.ti-about .product-page { - margin: 0 auto; - padding: 0; - width: 100%; - max-width: 960px; - border: 1px solid #CCCCCC; - border-radius: 8px; - background-color: #FFFFFF; -} -.ti-about .product-page .hero { - display: flex; - flex-direction: column; - align-items: center; - padding: 64px; - border-bottom: 1px solid #CCCCCC; -} -.ti-about .product-page .hero h1 { - font-size: 30px; - line-height: 42px; - max-width: 500px; - text-align: center; -} -.ti-about .product-page .hero p { - font-size: 14px; - line-height: 24px; - max-width: 500px; - text-align: center; -} -.ti-about .product-page .hero .logo { - width: 64px; - margin-bottom: 24px; -} -.ti-about .product-page .hero .label { - font-size: 10px; - line-height: 12px; - color: #ED6F57; - background-color: rgba(237, 111, 87, 0.1803921569); - padding: 8px 16px; - border-radius: 4px; -} -.ti-about .product-page .col-3-highlights { - display: flex; - flex-direction: column; - justify-content: space-evenly; - padding: 24px 0; - border-bottom: 1px solid #CCCCCC; - align-items: center; - text-align: center; -} -.ti-about .product-page .col-3-highlights .col { - max-width: 360px; -} -.ti-about .product-page .col-3-highlights .col h3 { - font-size: 21px; - line-height: 32px; - margin-bottom: 8px; -} -.ti-about .product-page .col-3-highlights .col p { - font-size: 14px; - line-height: 24px; -} -.ti-about .product-page .col-2-highlights { - display: flex; - flex-direction: column; - justify-content: space-evenly; - align-items: center; - padding: 24px 0; - border-bottom: 1px solid #CCCCCC; -} -.ti-about .product-page .col-2-highlights .col { - width: 90%; -} -.ti-about .product-page .col-2-highlights .col img { - max-width: 450px; - width: 100%; -} -.ti-about .product-page .col-2-highlights .col h2 { - font-size: 24px; - line-height: 35px; - margin-bottom: 8px; -} -.ti-about .product-page .col-2-highlights .col p { - font-size: 14px; - line-height: 24px; -} -.ti-about .product-page .button-row { - display: flex; - gap: 12px; - margin-top: 48px; -} -.ti-about .otter-blocks .testimonial-nav { - display: flex; - gap: 8px; -} -.ti-about .otter-blocks .testimonial-nav .testimonial-button { - width: 10px; - height: 10px; - background-color: #D9D9D9; - margin: 0; - padding: 0; - border-radius: 50%; -} -.ti-about .otter-blocks .testimonial-nav .testimonial-button.active { - background-color: #ED6F57; -} -.ti-about .otter-blocks .testimonial-container { - width: 100%; - max-width: 450px; - display: flex; - overflow-x: scroll; - scroll-behavior: smooth; - margin: 0; - padding: 0; -} -.ti-about .otter-blocks .testimonial-container::-webkit-scrollbar { - display: none; -} -.ti-about .otter-blocks .testimonial-container .testimonial { - width: 100%; - flex: 1 0 100%; - display: flex; - flex-wrap: wrap; - justify-content: left; - gap: 14px; - align-items: center; -} -.ti-about .otter-blocks .testimonial-container .testimonial p { - width: 100%; - font-size: 14px; - line-height: 24px; -} -.ti-about .otter-blocks .testimonial-container .testimonial h3 { - font-size: 16px; - line-height: 20px; - font-weight: 700; - color: #1C1C1C; -} -.ti-about .otter-blocks .testimonial-container .testimonial img { - width: 36px; - height: 36px; - border-radius: 50%; -} -.ti-about .otter-blocks .otter-button.is-primary { - background-color: #ED6F57; -} -.ti-about .otter-blocks .otter-button.is-secondary { - color: #ED6F57; - box-shadow: inset 0 0 0 1px #ED6F57; -} -.ti-about .otter-blocks .otter-button.is-loading { - background-color: #6C6C6C; - color: #FFFFFF; -} -@media (min-width: 660px) { - .ti-about .product-cards { - grid-template-columns: 1fr 1fr; - } - .ti-about .product-page .col-3-highlights, .ti-about .product-page .col-2-highlights { - flex-direction: row; - padding: 64px 0; - } - .ti-about .product-page .col-3-highlights { - text-align: left; - } - .ti-about .product-page .col-3-highlights .col { - max-width: 200px; - } - .ti-about .product-page .col-2-highlights .col { - width: 45%; - } -} -@media (min-width: 992px) { - .ti-about .story-card .footer, .ti-about .story-card .body { - gap: 60px; - } - .ti-about .story-card { - --grid: 1.1fr 1fr; - } - .ti-about .story-card .footer h2 { - margin: 0; - text-align: left; - } - .ti-about .product-cards { - grid-template-columns: 1fr 1fr 1fr; - } -} - -/*# sourceMappingURL=about.css.map*/ \ No newline at end of file +#wpcontent{padding-left:0 !important}.ti-about{--border: 1px solid #ccc;--link-color: var(--wp-admin-theme-color);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;line-height:normal;display:grid;gap:30px}.ti-about .container{margin:0 auto;max-width:960px;padding:0 15px}.ti-about p{font-size:14px;line-height:1.6}.ti-about button{font-weight:600}.ti-about .spin{animation:spin 1s infinite linear}@keyframes spin{0%{transform:rotate(0deg)}100%{transform:rotate(359deg)}}.ti-about .head{background:#fff;border-bottom:var(--border);padding:18px 0}.ti-about .head .container{padding:0 15px;display:flex;flex-wrap:wrap;align-items:center}.ti-about .head img{max-height:55px}.ti-about .head p{margin-left:10px}.ti-about .head a{font-style:italic;font-weight:bold}.ti-about .nav{border-bottom:var(--border);display:flex;flex-wrap:wrap;font-size:16px;margin:0;font-weight:600;-moz-column-gap:20px;column-gap:20px}.ti-about .nav a{border-bottom:4px solid rgba(0,0,0,0);color:#868686;padding:20px 10px;text-decoration:none;margin-bottom:-1px;box-sizing:border-box}.ti-about .nav a:hover{color:#313233}.ti-about .nav li{display:flex;margin:0}.ti-about .nav li.active a{border-color:var(--link-color);color:#313233}.ti-about .story-card .footer,.ti-about .story-card .body{display:grid;grid-template-columns:var(--grid, 1fr);align-items:center}.ti-about .story-card{border:var(--border);border-radius:0 0 10px 10px}.ti-about .story-card .body{background:#fff;padding:35px 35px 10px 35px}.ti-about .story-card .body h2{font-size:30px;margin:0 0 30px;color:#1f1d1d}.ti-about .story-card .body p{color:#1e1e1e}.ti-about .story-card .body figure{order:0;margin:0}.ti-about .story-card .body figcaption{margin:10px 0;color:#797979;font-size:12px}.ti-about .story-card .body img{border-radius:8px;max-width:100%}.ti-about .story-card .footer{border-top:var(--border);padding:30px 40px}.ti-about .story-card .footer h2{margin:0 0 20px;text-align:center;font-size:21px}.ti-about .story-card form{display:flex;align-items:center}.ti-about .story-card form .dashicons-yes-alt{color:#609952}.ti-about .story-card input{height:36px;flex-grow:1;border:var(--border);border-radius:2px;font-size:12px;margin-right:15px}.ti-about .product-cards{display:grid;gap:30px}.ti-about .product-card{background:#fff;display:grid;border:var(--border)}.ti-about .product-card h2{font-size:21px;margin:0}.ti-about .product-card p{margin:0;color:#6c6c6c}.ti-about .product-card .header{padding:20px 15px 0;display:flex;align-items:center}.ti-about .product-card .body{padding:20px 15px}.ti-about .product-card img{max-width:50px;margin-right:15px;border-radius:6px}.ti-about .product-card .footer{border-top:var(--border);display:flex;align-items:center;padding:15px;align-self:flex-end;justify-content:space-between}.ti-about .product-card .footer p{margin:8px 0;font-weight:600;font-size:13px;color:#313233}.ti-about .product-card .footer .not-installed{color:#7e7e7e}.ti-about .product-card .footer .active{color:#609952}.ti-about .product-card button,.ti-about .product-card a,.ti-about .product-card .spin{margin-left:auto;text-decoration:none}.ti-about .product-page{margin:0 auto;padding:0;width:100%;max-width:960px;border:1px solid #ccc;border-radius:8px;background-color:#fff}.ti-about .product-page .hero{display:flex;flex-direction:column;align-items:center;padding:64px;border-bottom:1px solid #ccc}.ti-about .product-page .hero h1{font-size:30px;line-height:42px;max-width:500px;text-align:center}.ti-about .product-page .hero p{font-size:14px;line-height:24px;max-width:500px;text-align:center}.ti-about .product-page .hero .logo{width:64px;margin-bottom:24px}.ti-about .product-page .hero .label{font-size:10px;line-height:12px;color:#ed6f57;background-color:rgba(237,111,87,.1803921569);padding:8px 16px;border-radius:4px}.ti-about .product-page .col-3-highlights{display:flex;flex-direction:column;justify-content:space-evenly;padding:24px 0;border-bottom:1px solid #ccc;align-items:center;text-align:center}.ti-about .product-page .col-3-highlights .col{max-width:360px}.ti-about .product-page .col-3-highlights .col h3{font-size:21px;line-height:32px;margin-bottom:8px}.ti-about .product-page .col-3-highlights .col p{font-size:14px;line-height:24px}.ti-about .product-page .col-2-highlights{display:flex;flex-direction:column;justify-content:space-evenly;align-items:center;padding:24px 0;border-bottom:1px solid #ccc}.ti-about .product-page .col-2-highlights .col{width:90%}.ti-about .product-page .col-2-highlights .col img{max-width:450px;width:100%}.ti-about .product-page .col-2-highlights .col h2{font-size:24px;line-height:35px;margin-bottom:8px}.ti-about .product-page .col-2-highlights .col p{font-size:14px;line-height:24px}.ti-about .product-page .button-row{display:flex;gap:12px;margin-top:48px}.ti-about .otter-blocks .testimonial-nav{display:flex;gap:8px}.ti-about .otter-blocks .testimonial-nav .testimonial-button{width:10px;height:10px;background-color:#d9d9d9;margin:0;padding:0;border-radius:50%}.ti-about .otter-blocks .testimonial-nav .testimonial-button.active{background-color:#ed6f57}.ti-about .otter-blocks .testimonial-container{width:100%;max-width:450px;display:flex;overflow-x:scroll;scroll-behavior:smooth;margin:0;padding:0}.ti-about .otter-blocks .testimonial-container::-webkit-scrollbar{display:none}.ti-about .otter-blocks .testimonial-container .testimonial{width:100%;flex:1 0 100%;display:flex;flex-wrap:wrap;justify-content:left;gap:14px;align-items:center}.ti-about .otter-blocks .testimonial-container .testimonial p{width:100%;font-size:14px;line-height:24px}.ti-about .otter-blocks .testimonial-container .testimonial h3{font-size:16px;line-height:20px;font-weight:700;color:#1c1c1c}.ti-about .otter-blocks .testimonial-container .testimonial img{width:36px;height:36px;border-radius:50%}.ti-about .otter-blocks .otter-button.is-primary{background-color:#ed6f57}.ti-about .otter-blocks .otter-button.is-secondary{color:#ed6f57;box-shadow:inset 0 0 0 1px #ed6f57}.ti-about .otter-blocks .otter-button.is-loading{background-color:#6c6c6c;color:#fff}@media (min-width: 660px){.ti-about .product-cards{grid-template-columns:1fr 1fr}.ti-about .product-page .col-3-highlights,.ti-about .product-page .col-2-highlights{flex-direction:row;padding:64px 0}.ti-about .product-page .col-3-highlights{text-align:left}.ti-about .product-page .col-3-highlights .col{max-width:200px}.ti-about .product-page .col-2-highlights .col{width:45%}}@media (min-width: 992px){.ti-about .story-card .footer,.ti-about .story-card .body{gap:60px}.ti-about .story-card{--grid: 1.1fr 1fr}.ti-about .story-card .footer h2{margin:0;text-align:left}.ti-about .product-cards{grid-template-columns:1fr 1fr 1fr}} diff --git a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/about/about.js b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/about/about.js index 791c78cf..2e341ffc 100644 --- a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/about/about.js +++ b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/about/about.js @@ -1,772 +1 @@ -/******/ (() => { // webpackBootstrap -/******/ "use strict"; -/******/ var __webpack_modules__ = ({ - -/***/ "./assets/js/src/about/components/Header.js": -/*!**************************************************!*\ - !*** ./assets/js/src/about/components/Header.js ***! - \**************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ "default": () => (/* binding */ Header) -/* harmony export */ }); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__); - -function Header(_ref) { - let { - pages = [], - selected = '' - } = _ref; - const { - currentProduct, - logoUrl, - strings, - links - } = window.tiSDKAboutData; - - const hasActiveClass = function () { - let hash = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : ''; - return hash === selected ? 'active' : ''; - }; - - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", null, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "head" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "container" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("img", { - src: logoUrl, - alt: currentProduct.name - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, "by ", (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("a", { - href: "https://themeisle.com" - }, "Themeisle")))), (links.length > 0 || pages.length > 0) && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "container" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("ul", { - className: "nav" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("li", { - className: hasActiveClass() - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("a", { - href: window.location - }, strings.aboutUs)), pages.map((page, index) => (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("li", { - className: hasActiveClass(page.hash), - key: index - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("a", { - href: page.hash - }, page.name))), links.map((link, index) => (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("li", { - key: index - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("a", { - href: link.url - }, link.text)))))); -} - -/***/ }), - -/***/ "./assets/js/src/about/components/Hero.js": -/*!************************************************!*\ - !*** ./assets/js/src/about/components/Hero.js ***! - \************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ "default": () => (/* binding */ Hero) -/* harmony export */ }); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); -/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__); - - - -function Hero() { - const { - strings, - teamImage, - homeUrl, - pageSlug - } = window.tiSDKAboutData; - const { - heroHeader, - heroTextFirst, - heroTextSecond, - teamImageCaption, - newsHeading, - emailPlaceholder, - signMeUp - } = strings; - const [email, setEmail] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(''); - const [loading, setLoading] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(false); - const [hasSubscribed, setHasSubscribed] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(false); - - const submit = e => { - var _fetch$then$then; - - e.preventDefault(); - setLoading(true); - (_fetch$then$then = fetch('https://api.themeisle.com/tracking/subscribe', { - method: 'POST', - headers: { - 'Content-Type': 'application/json', - Accept: 'application/json, */*;q=0.1', - 'Cache-Control': 'no-cache' - }, - body: JSON.stringify({ - slug: 'about-us', - site: homeUrl, - from: pageSlug, - email - }) - }).then(r => r.json()).then(response => { - setLoading(false); - - if ('success' === response.code) { - setHasSubscribed(true); - } - })) === null || _fetch$then$then === void 0 ? void 0 : _fetch$then$then.catch(error => { - setLoading(false); - }); - }; - - const updateEmail = e => { - setEmail(e.target.value); - }; - - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "container" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "story-card" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "body" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", null, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("h2", null, heroHeader), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, heroTextFirst), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, heroTextSecond)), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("figure", null, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("img", { - src: teamImage, - alt: teamImageCaption - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("figcaption", null, teamImageCaption))), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "footer" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("h2", null, newsHeading), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("form", { - onSubmit: submit - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("input", { - disabled: loading || hasSubscribed, - type: "email", - value: email, - onChange: updateEmail, - placeholder: emailPlaceholder - }), !loading && !hasSubscribed && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - isPrimary: true, - type: "submit" - }, signMeUp), loading && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: "dashicons dashicons-update spin" - }), hasSubscribed && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: "dashicons dashicons-yes-alt" - }))))); -} - -/***/ }), - -/***/ "./assets/js/src/about/components/ProductCard.js": -/*!*******************************************************!*\ - !*** ./assets/js/src/about/components/ProductCard.js ***! - \*******************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ "default": () => (/* binding */ ProductCard) -/* harmony export */ }); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); -/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__); -/* harmony import */ var _common_utils__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../common/utils */ "./assets/js/src/common/utils.js"); - - - - -function ProductCard(_ref) { - let { - product, - slug - } = _ref; - const { - icon, - name, - description, - status, - premiumUrl, - activationLink - } = product; - const { - strings - } = window.tiSDKAboutData; - const { - installNow, - installed, - notInstalled, - active, - activate, - learnMore - } = strings; - const isPremium = !!premiumUrl; - const [productStatus, setProductStatus] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(status); - const [loading, setLoading] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(false); - - const runInstall = async () => { - setLoading(true); - await (0,_common_utils__WEBPACK_IMPORTED_MODULE_2__.installPluginOrTheme)(slug, slug === 'neve').then(res => { - if (res.success) { - setProductStatus('installed'); - } - }); - setLoading(false); - }; - - const runActivate = async () => { - setLoading(true); - window.location.href = activationLink; - }; - - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "product-card" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "header" - }, icon && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("img", { - src: icon, - alt: name - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("h2", null, name)), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "body" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", { - dangerouslySetInnerHTML: { - __html: description - } - })), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "footer" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, "Status:", " ", (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: productStatus - }, productStatus === 'installed' && installed, productStatus === 'not-installed' && notInstalled, productStatus === 'active' && active)), productStatus !== 'active' && !loading && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.Fragment, null, productStatus === 'not-installed' && isPremium && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - isLink: true, - icon: 'external', - href: premiumUrl, - target: "_blank" - }, learnMore), productStatus === 'not-installed' && !isPremium && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - isPrimary: true, - onClick: runInstall - }, installNow), productStatus === 'installed' && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - isSecondary: true, - onClick: runActivate - }, activate)), loading && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: "dashicons dashicons-update spin" - }))); -} - -/***/ }), - -/***/ "./assets/js/src/about/components/ProductCards.js": -/*!********************************************************!*\ - !*** ./assets/js/src/about/components/ProductCards.js ***! - \********************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ "default": () => (/* binding */ ProductCards) -/* harmony export */ }); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var _ProductCard__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./ProductCard */ "./assets/js/src/about/components/ProductCard.js"); - - -function ProductCards() { - const { - products - } = window.tiSDKAboutData; - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "container" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "product-cards" - }, Object.keys(products).map((key, index) => (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_ProductCard__WEBPACK_IMPORTED_MODULE_1__["default"], { - key: key, - slug: key, - product: products[key] - })))); -} - -/***/ }), - -/***/ "./assets/js/src/about/components/ProductPage.js": -/*!*******************************************************!*\ - !*** ./assets/js/src/about/components/ProductPage.js ***! - \*******************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ "default": () => (/* binding */ ProductPage) -/* harmony export */ }); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var _pages_Otter__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./pages/Otter */ "./assets/js/src/about/components/pages/Otter.js"); - - -const pagesMap = { - 'otter-page': _pages_Otter__WEBPACK_IMPORTED_MODULE_1__["default"] -}; - -function Page(props) { - const CurrentPage = pagesMap[props.id]; - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(CurrentPage, { - page: props.page - }); -} - -function ProductPage(_ref) { - let { - page = {} - } = _ref; - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: 'product-page' + (page && page.product ? ' ' + page.product : '') - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(Page, { - id: page.id, - page: page - })); -} - -/***/ }), - -/***/ "./assets/js/src/about/components/pages/Otter.js": -/*!*******************************************************!*\ - !*** ./assets/js/src/about/components/pages/Otter.js ***! - \*******************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ "default": () => (/* binding */ Otter) -/* harmony export */ }); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); -/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__); -/* harmony import */ var _common_utils__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../common/utils */ "./assets/js/src/common/utils.js"); - - - - -function Otter(_ref) { - let { - page = {} - } = _ref; - const { - products - } = window.tiSDKAboutData; - const { - strings, - plugin - } = page; - const product = page && page.product ? page.product : ''; - const icon = product && products[product] && products[product].icon ? products[product].icon : null; - const [testimonial, setTestimonial] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(strings.testimonials.users[0]); - const [productStatus, setProductStatus] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(plugin.status); - const [loading, setLoading] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(false); - const loadingText = 'In Progress'; - - const runInstall = async () => { - setLoading(true); - await (0,_common_utils__WEBPACK_IMPORTED_MODULE_2__.installPluginOrTheme)(product, false).then(res => { - if (res.success) { - setProductStatus('installed'); - runActivate(); - } - }); - }; - - const runActivate = async () => { - setLoading(true); - window.location.href = plugin.activationLink; - }; - - const toggleTestimonial = index => { - const user = strings.testimonials.users[index]; - const testimonial = document.getElementById('ts_' + index); - testimonial.scrollIntoView({ - behavior: 'smooth' - }); - setTestimonial(user); - }; - - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.Fragment, null, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "hero" - }, icon && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("img", { - className: "logo", - src: icon, - alt: page.name || '' - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: "label" - }, "Neve + Otter = New Possibilities \uD83E\uDD1D"), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("h1", null, strings.heading), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, strings.text), (productStatus === 'not-installed' || productStatus === 'installed') && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - variant: "primary", - disabled: loading, - className: 'otter-button' + (loading ? ' is-loading' : ''), - onClick: productStatus === 'not-installed' ? runInstall : runActivate - }, loading ? (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", null, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: "dashicons dashicons-update spin" - }), loadingText) : strings.buttons.install_otter_free)), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col-3-highlights" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("h3", null, strings.features.advancedTitle), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, strings.features.advancedDesc)), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("h3", null, strings.features.fastTitle), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, strings.features.fastDesc)), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("h3", null, strings.features.mobileTitle), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, strings.features.mobileDesc))), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col-2-highlights" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("img", { - src: strings.details.s1Image, - alt: strings.details.s1Title - })), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("h2", null, strings.details.s1Title), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, strings.details.s1Text))), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col-2-highlights" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("h2", null, strings.details.s2Title), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, strings.details.s2Text)), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("img", { - src: strings.details.s2Image, - alt: strings.details.s1Title - }))), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col-2-highlights" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("img", { - src: strings.details.s3Image, - alt: strings.details.s1Title - })), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("h2", null, strings.details.s3Title), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, strings.details.s3Text))), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col-2-highlights", - style: { - backgroundColor: '#F7F7F7', - borderBottom: 'none', - borderBottomRightRadius: '8px', - borderBottomLeftRadius: '8px' - } - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("h2", null, strings.testimonials.heading), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "button-row" - }, (productStatus === 'not-installed' || productStatus === 'installed') && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - variant: "primary", - disabled: loading, - className: 'otter-button' + (loading ? ' is-loading' : ''), - onClick: productStatus === 'not-installed' ? runInstall : runActivate - }, loading ? (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", null, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: "dashicons dashicons-update spin" - }), loadingText) : strings.buttons.install_now), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("a", { - className: "components-button otter-button is-secondary", - href: strings.buttons.learn_more_link, - target: "_blank", - rel: "external noreferrer noopener" - }, strings.buttons.learn_more))), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "col" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "testimonials" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("ul", { - id: "testimonial-container", - className: "testimonial-container" - }, strings.testimonials.users.map((user, index) => (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("li", { - className: "testimonial", - id: 'ts_' + index, - key: 'ts_' + index - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, "\"", user.text, "\""), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("img", { - src: user.avatar, - alt: user.name - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("h3", null, user.name)))), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "testimonial-nav" - }, strings.testimonials.users.map((user, index) => (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - className: 'testimonial-button' + (user.name === testimonial.name ? ' active' : ''), - key: 'button_' + index, - onClick: () => toggleTestimonial(index) - }))))))); -} -; - -/***/ }), - -/***/ "./assets/js/src/common/utils.js": -/*!***************************************!*\ - !*** ./assets/js/src/common/utils.js ***! - \***************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ "activatePlugin": () => (/* binding */ activatePlugin), -/* harmony export */ "getBlocksByType": () => (/* binding */ getBlocksByType), -/* harmony export */ "installPluginOrTheme": () => (/* binding */ installPluginOrTheme) -/* harmony export */ }); -const installPluginOrTheme = function (slug) { - let theme = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false; - return new Promise(resolve => { - wp.updates.ajax(theme === true ? 'install-theme' : 'install-plugin', { - slug, - success: () => { - resolve({ - success: true - }); - }, - error: err => { - resolve({ - success: false, - code: err.errorCode - }); - } - }); - }); -}; - -const activatePlugin = url => { - return new Promise(resolve => { - jQuery.get(url).done(() => { - resolve({ - success: true - }); - }).fail(() => { - resolve({ - success: false - }); - }); - }); -}; - -const flatRecursively = (r, a) => { - const b = {}; - Object.keys(a).forEach(function (k) { - if ('innerBlocks' !== k) { - b[k] = a[k]; - } - }); - r.push(b); - - if (Array.isArray(a.innerBlocks)) { - b.innerBlocks = a.innerBlocks.map(i => { - return i.id; - }); - return a.innerBlocks.reduce(flatRecursively, r); - } - - return r; -}; -/** - * Get blocks by type. - * - * @param {Array} blocks blocks array. - * @param {string} type type of block looking for. - * - * @return {Array} array of blocks of {type} in page - */ - - -const getBlocksByType = (blocks, type) => blocks.reduce(flatRecursively, []).filter(a => type === a.name); - - - -/***/ }), - -/***/ "./assets/js/src/about/about.scss": -/*!****************************************!*\ - !*** ./assets/js/src/about/about.scss ***! - \****************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -// extracted by mini-css-extract-plugin - - -/***/ }), - -/***/ "@wordpress/components": -/*!************************************!*\ - !*** external ["wp","components"] ***! - \************************************/ -/***/ ((module) => { - -module.exports = window["wp"]["components"]; - -/***/ }), - -/***/ "@wordpress/element": -/*!*********************************!*\ - !*** external ["wp","element"] ***! - \*********************************/ -/***/ ((module) => { - -module.exports = window["wp"]["element"]; - -/***/ }) - -/******/ }); -/************************************************************************/ -/******/ // The module cache -/******/ var __webpack_module_cache__ = {}; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ // Check if module is in cache -/******/ var cachedModule = __webpack_module_cache__[moduleId]; -/******/ if (cachedModule !== undefined) { -/******/ return cachedModule.exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = __webpack_module_cache__[moduleId] = { -/******/ // no module.id needed -/******/ // no module.loaded needed -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/************************************************************************/ -/******/ /* webpack/runtime/compat get default export */ -/******/ (() => { -/******/ // getDefaultExport function for compatibility with non-harmony modules -/******/ __webpack_require__.n = (module) => { -/******/ var getter = module && module.__esModule ? -/******/ () => (module['default']) : -/******/ () => (module); -/******/ __webpack_require__.d(getter, { a: getter }); -/******/ return getter; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/define property getters */ -/******/ (() => { -/******/ // define getter functions for harmony exports -/******/ __webpack_require__.d = (exports, definition) => { -/******/ for(var key in definition) { -/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { -/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); -/******/ } -/******/ } -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/hasOwnProperty shorthand */ -/******/ (() => { -/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) -/******/ })(); -/******/ -/******/ /* webpack/runtime/make namespace object */ -/******/ (() => { -/******/ // define __esModule on exports -/******/ __webpack_require__.r = (exports) => { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ })(); -/******/ -/************************************************************************/ -var __webpack_exports__ = {}; -// This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. -(() => { -/*!**************************************!*\ - !*** ./assets/js/src/about/about.js ***! - \**************************************/ -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var _about_scss__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./about.scss */ "./assets/js/src/about/about.scss"); -/* harmony import */ var _components_Header__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./components/Header */ "./assets/js/src/about/components/Header.js"); -/* harmony import */ var _components_Hero__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./components/Hero */ "./assets/js/src/about/components/Hero.js"); -/* harmony import */ var _components_ProductCards__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./components/ProductCards */ "./assets/js/src/about/components/ProductCards.js"); -/* harmony import */ var _components_ProductPage__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./components/ProductPage */ "./assets/js/src/about/components/ProductPage.js"); - - - - - - - - -const getTabHash = () => { - let hash = window.location.hash; - - if ('string' !== typeof window.location.hash) { - return null; - } - - return hash; -}; - -function About() { - const { - productPages - } = window.tiSDKAboutData; - const pages = productPages ? Object.keys(productPages).map(key => { - const result = productPages[key]; - result.id = key; - return result; - }) : []; - const [hash, setHash] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(getTabHash()); - - const setTabToCurrentHash = () => { - const hash = getTabHash(); - - if (null === hash) { - return; - } - - setHash(hash); - }; - - (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useEffect)(() => { - setTabToCurrentHash(); - window.addEventListener('hashchange', setTabToCurrentHash); - return () => { - window.removeEventListener('hashchange', setTabToCurrentHash); - }; - }, []); - const isHashInPages = pages.filter(page => { - return page.hash === hash; - }); - - if (isHashInPages.length > 0) { - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "ti-about" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_components_Header__WEBPACK_IMPORTED_MODULE_2__["default"], { - pages: pages, - selected: hash - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_components_ProductPage__WEBPACK_IMPORTED_MODULE_5__["default"], { - page: isHashInPages[0] - })); - } - - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "ti-about" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_components_Header__WEBPACK_IMPORTED_MODULE_2__["default"], { - pages: pages - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_components_Hero__WEBPACK_IMPORTED_MODULE_3__["default"], null), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_components_ProductCards__WEBPACK_IMPORTED_MODULE_4__["default"], null)); -} - -document.addEventListener('DOMContentLoaded', () => { - const root = document.querySelector('#ti-sdk-about'); - - if (!root) { - return; - } - - (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.render)((0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(About, null), root); -}); -})(); - -/******/ })() -; -//# sourceMappingURL=about.js.map \ No newline at end of file +!function(){"use strict";var e=window.wp.element;function t(t){let{pages:a=[],selected:n=""}=t;const{currentProduct:l,logoUrl:s,strings:c,links:i}=window.tiSDKAboutData,r=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e===n?"active":""};return(0,e.createElement)("div",null,(0,e.createElement)("div",{className:"head"},(0,e.createElement)("div",{className:"container"},(0,e.createElement)("img",{src:s,alt:l.name}),(0,e.createElement)("p",null,"by ",(0,e.createElement)("a",{href:"https://themeisle.com"},"Themeisle")))),(i.length>0||a.length>0)&&(0,e.createElement)("div",{className:"container"},(0,e.createElement)("ul",{className:"nav"},(0,e.createElement)("li",{className:r()},(0,e.createElement)("a",{href:window.location},c.aboutUs)),a.map(((t,a)=>(0,e.createElement)("li",{className:r(t.hash),key:a},(0,e.createElement)("a",{href:t.hash},t.name)))),i.map(((t,a)=>(0,e.createElement)("li",{key:a},(0,e.createElement)("a",{href:t.url},t.text)))))))}var a=window.wp.components;function n(){const{strings:t,teamImage:n,homeUrl:l,pageSlug:s}=window.tiSDKAboutData,{heroHeader:c,heroTextFirst:i,heroTextSecond:r,teamImageCaption:o,newsHeading:m,emailPlaceholder:d,signMeUp:u}=t,[E,p]=(0,e.useState)(""),[h,g]=(0,e.useState)(!1),[v,N]=(0,e.useState)(!1);return(0,e.createElement)("div",{className:"container"},(0,e.createElement)("div",{className:"story-card"},(0,e.createElement)("div",{className:"body"},(0,e.createElement)("div",null,(0,e.createElement)("h2",null,c),(0,e.createElement)("p",null,i),(0,e.createElement)("p",null,r)),(0,e.createElement)("figure",null,(0,e.createElement)("img",{src:n,alt:o}),(0,e.createElement)("figcaption",null,o))),(0,e.createElement)("div",{className:"footer"},(0,e.createElement)("h2",null,m),(0,e.createElement)("form",{onSubmit:e=>{var t;e.preventDefault(),g(!0),null===(t=fetch("https://api.themeisle.com/tracking/subscribe",{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json, */*;q=0.1","Cache-Control":"no-cache"},body:JSON.stringify({slug:"about-us",site:l,from:s,email:E})}).then((e=>e.json())).then((e=>{g(!1),"success"===e.code&&N(!0)})))||void 0===t||t.catch((e=>{g(!1)}))}},(0,e.createElement)("input",{disabled:h||v,type:"email",value:E,onChange:e=>{p(e.target.value)},placeholder:d}),!h&&!v&&(0,e.createElement)(a.Button,{isPrimary:!0,type:"submit"},u),h&&(0,e.createElement)("span",{className:"dashicons dashicons-update spin"}),v&&(0,e.createElement)("span",{className:"dashicons dashicons-yes-alt"})))))}const l=function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return new Promise((a=>{wp.updates.ajax(!0===t?"install-theme":"install-plugin",{slug:e,success:()=>{a({success:!0})},error:e=>{a({success:!1,code:e.errorCode})}})}))};function s(t){let{product:n,slug:s}=t;const{icon:c,name:i,description:r,status:o,premiumUrl:m,activationLink:d}=n,{strings:u,canInstallPlugins:E,canActivatePlugins:p}=window.tiSDKAboutData,{installNow:h,installed:g,notInstalled:v,active:N,activate:b,learnMore:f}=u,w=!!m,[y,k]=(0,e.useState)(o),[S,T]=(0,e.useState)(!1),D=async()=>{T(!0),await l(s,"neve"===s).then((e=>{e.success&&k("installed")})),T(!1)},x=async()=>{T(!0),window.location.href=d},_=()=>"not-installed"===y&&w?(0,e.createElement)(a.Button,{isLink:!0,icon:"external",href:m,target:"_blank"},f):"not-installed"!==y||w?"installed"===y?(0,e.createElement)(a.Button,{isSecondary:!0,onClick:x,disabled:S||!p},b):null:(0,e.createElement)(a.Button,{isPrimary:!0,onClick:D,disabled:S||!E},h),C=!E&&"not-installed"===y||!p&&"installed"===y?(0,e.createElement)(a.Tooltip,{text:`Ask your admin to enable ${i} on your site`,position:"top center"},_()):_();return(0,e.createElement)("div",{className:"product-card"},(0,e.createElement)("div",{className:"header"},c&&(0,e.createElement)("img",{src:c,alt:i}),(0,e.createElement)("h2",null,i)),(0,e.createElement)("div",{className:"body"},(0,e.createElement)("p",{dangerouslySetInnerHTML:{__html:r}})),(0,e.createElement)("div",{className:"footer"},(0,e.createElement)("p",null,"Status:"," ",(0,e.createElement)("span",{className:y},"installed"===y&&g,"not-installed"===y&&v,"active"===y&&N)),"active"!==y&&!S&&C,S&&(0,e.createElement)("span",{className:"dashicons dashicons-update spin"})))}function c(){const{products:t}=window.tiSDKAboutData;return(0,e.createElement)("div",{className:"container"},(0,e.createElement)("div",{className:"product-cards"},Object.keys(t).map(((a,n)=>(0,e.createElement)(s,{key:a,slug:a,product:t[a]})))))}const i={"otter-page":function(t){let{page:n={}}=t;const{products:s,canInstallPlugins:c,canActivatePlugins:i}=window.tiSDKAboutData,{strings:r,plugin:o}=n,m=n&&n.product?n.product:"",d=m&&s[m]&&s[m].icon?s[m].icon:null,[u,E]=(0,e.useState)(r.testimonials.users[0]),[p,h]=(0,e.useState)(o.status),[g,v]=(0,e.useState)(!1),N="In Progress",b=async()=>{v(!0),await l(m,!1).then((e=>{e.success&&(h("installed"),f())}))},f=async()=>{v(!0),window.location.href=o.activationLink},w=(0,e.createElement)(a.Button,{variant:"primary",disabled:g||("not-installed"===p?!c:!i),className:"otter-button"+(g?" is-loading":""),onClick:"not-installed"===p?b:f},g?(0,e.createElement)("span",null,(0,e.createElement)("span",{className:"dashicons dashicons-update spin"})," ",N):r.buttons.install_otter_free),y=(0,e.createElement)(a.Button,{variant:"primary",disabled:g||("not-installed"===p?!c:!i),className:"otter-button"+(g?" is-loading":""),onClick:"not-installed"===p?b:f},g?(0,e.createElement)("span",null,(0,e.createElement)("span",{className:"dashicons dashicons-update spin"}),N):r.buttons.install_now),k=!c&&"not-installed"===p||!i&&"installed"===p||!1,S=t=>k?(0,e.createElement)(a.Tooltip,{text:"Ask your admin to enable Otter on your site",position:"top center"},t):t;return(0,e.createElement)(e.Fragment,null,(0,e.createElement)("div",{className:"hero"},d&&(0,e.createElement)("img",{className:"logo",src:d,alt:n.name||""}),(0,e.createElement)("span",{className:"label"},"Neve + Otter = New Possibilities 🤝"),(0,e.createElement)("h1",null,r.heading),(0,e.createElement)("p",null,r.text),("not-installed"===p||"installed"===p)&&S(w)),(0,e.createElement)("div",{className:"col-3-highlights"},(0,e.createElement)("div",{className:"col"},(0,e.createElement)("h3",null,r.features.advancedTitle),(0,e.createElement)("p",null,r.features.advancedDesc)),(0,e.createElement)("div",{className:"col"},(0,e.createElement)("h3",null,r.features.fastTitle),(0,e.createElement)("p",null,r.features.fastDesc)),(0,e.createElement)("div",{className:"col"},(0,e.createElement)("h3",null,r.features.mobileTitle),(0,e.createElement)("p",null,r.features.mobileDesc))),(0,e.createElement)("div",{className:"col-2-highlights"},(0,e.createElement)("div",{className:"col"},(0,e.createElement)("img",{src:r.details.s1Image,alt:r.details.s1Title})),(0,e.createElement)("div",{className:"col"},(0,e.createElement)("h2",null,r.details.s1Title),(0,e.createElement)("p",null,r.details.s1Text))),(0,e.createElement)("div",{className:"col-2-highlights"},(0,e.createElement)("div",{className:"col"},(0,e.createElement)("h2",null,r.details.s2Title),(0,e.createElement)("p",null,r.details.s2Text)),(0,e.createElement)("div",{className:"col"},(0,e.createElement)("img",{src:r.details.s2Image,alt:r.details.s1Title}))),(0,e.createElement)("div",{className:"col-2-highlights"},(0,e.createElement)("div",{className:"col"},(0,e.createElement)("img",{src:r.details.s3Image,alt:r.details.s1Title})),(0,e.createElement)("div",{className:"col"},(0,e.createElement)("h2",null,r.details.s3Title),(0,e.createElement)("p",null,r.details.s3Text))),(0,e.createElement)("div",{className:"col-2-highlights",style:{backgroundColor:"#F7F7F7",borderBottom:"none",borderBottomRightRadius:"8px",borderBottomLeftRadius:"8px"}},(0,e.createElement)("div",{className:"col"},(0,e.createElement)("h2",null,r.testimonials.heading),(0,e.createElement)("div",{className:"button-row"},("not-installed"===p||"installed"===p)&&S(y),(0,e.createElement)("a",{className:"components-button otter-button is-secondary",href:r.buttons.learn_more_link,target:"_blank",rel:"external noreferrer noopener"},r.buttons.learn_more))),(0,e.createElement)("div",{className:"col"},(0,e.createElement)("div",{className:"testimonials"},(0,e.createElement)("ul",{id:"testimonial-container",className:"testimonial-container"},r.testimonials.users.map(((t,a)=>(0,e.createElement)("li",{className:"testimonial",id:"ts_"+a,key:"ts_"+a},(0,e.createElement)("p",null,'"',t.text,'"'),(0,e.createElement)("img",{src:t.avatar,alt:t.name}),(0,e.createElement)("h3",null,t.name))))),(0,e.createElement)("div",{className:"testimonial-nav"},r.testimonials.users.map(((t,n)=>(0,e.createElement)(a.Button,{className:"testimonial-button"+(t.name===u.name?" active":""),key:"button_"+n,onClick:()=>(e=>{const t=r.testimonials.users[e];document.getElementById("ts_"+e).scrollIntoView({behavior:"smooth"}),E(t)})(n)}))))))))}};function r(t){const a=i[t.id];return(0,e.createElement)(a,{page:t.page})}function o(t){let{page:a={}}=t;return(0,e.createElement)("div",{className:"product-page"+(a&&a.product?" "+a.product:"")},(0,e.createElement)(r,{id:a.id,page:a}))}const m=()=>{let e=window.location.hash;return"string"!=typeof window.location.hash?null:e};function d(){const{productPages:a}=window.tiSDKAboutData,l=a?Object.keys(a).map((e=>{const t=a[e];return t.id=e,t})):[],[s,i]=(0,e.useState)(m()),r=()=>{const e=m();null!==e&&i(e)};(0,e.useEffect)((()=>(r(),window.addEventListener("hashchange",r),()=>{window.removeEventListener("hashchange",r)})),[]);const d=l.filter((e=>e.hash===s));return d.length>0?(0,e.createElement)("div",{className:"ti-about"},(0,e.createElement)(t,{pages:l,selected:s}),(0,e.createElement)(o,{page:d[0]})):(0,e.createElement)("div",{className:"ti-about"},(0,e.createElement)(t,{pages:l}),(0,e.createElement)(n,null),(0,e.createElement)(c,null))}document.addEventListener("DOMContentLoaded",(()=>{const t=document.querySelector("#ti-sdk-about");t&&(0,e.render)((0,e.createElement)(d,null),t)}))}(); \ No newline at end of file diff --git a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/promos/index.asset.php b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/promos/index.asset.php index b8c38373..77c2d470 100644 --- a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/promos/index.asset.php +++ b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/promos/index.asset.php @@ -1 +1 @@ - array('wp-api', 'wp-block-editor', 'wp-components', 'wp-compose', 'wp-data', 'wp-edit-post', 'wp-element', 'wp-hooks', 'wp-plugins'), 'version' => 'c6a13557ef46b0a921d3'); + array('wp-block-editor', 'wp-components', 'wp-compose', 'wp-data', 'wp-edit-post', 'wp-element', 'wp-hooks', 'wp-plugins'), 'version' => 'bae1a40c3811e093a7be'); diff --git a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/promos/index.js b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/promos/index.js index 09cb6630..b85c4916 100644 --- a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/promos/index.js +++ b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/promos/index.js @@ -1,1311 +1 @@ -/******/ (() => { // webpackBootstrap -/******/ "use strict"; -/******/ var __webpack_modules__ = ({ - -/***/ "./assets/js/src/OptimoleNotice/index.js": -/*!***********************************************!*\ - !*** ./assets/js/src/OptimoleNotice/index.js ***! - \***********************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ "default": () => (/* binding */ OptimoleNotice) -/* harmony export */ }); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); -/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__); -/* harmony import */ var _style_scss__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./style.scss */ "./assets/js/src/OptimoleNotice/style.scss"); -/* harmony import */ var _common_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../common/utils */ "./assets/js/src/common/utils.js"); -/* harmony import */ var _common_useSettings__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../common/useSettings */ "./assets/js/src/common/useSettings.js"); - - - - - - -function OptimoleNotice(_ref) { - let { - stacked = false, - noImage = false, - type, - onDismiss, - onSuccess, - initialStatus = null - } = _ref; - const { - assets, - title, - email: initialEmail, - option, - optionKey, - optimoleActivationUrl, - optimoleApi, - optimoleDash, - nonce - } = window.themeisleSDKPromotions; - const [showForm, setShowForm] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(false); - const [email, setEmail] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(initialEmail || ''); - const [dismissed, setDismissed] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(false); - const [progress, setProgress] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(initialStatus); - const [getOption, updateOption] = (0,_common_useSettings__WEBPACK_IMPORTED_MODULE_4__["default"])(); - - const dismissNotice = async () => { - setDismissed(true); - const newValue = { ...option - }; - newValue[type] = new Date().getTime() / 1000 | 0; - window.themeisleSDKPromotions.option = newValue; - await updateOption(optionKey, JSON.stringify(newValue)); - - if (onDismiss) { - onDismiss(); - } - }; - - const toggleForm = () => { - setShowForm(!showForm); - }; - - const updateEmail = e => { - setEmail(e.target.value); - }; - - const submitForm = async e => { - e.preventDefault(); - setProgress('installing'); - await (0,_common_utils__WEBPACK_IMPORTED_MODULE_3__.installPluginOrTheme)('optimole-wp'); - setProgress('activating'); - await (0,_common_utils__WEBPACK_IMPORTED_MODULE_3__.activatePlugin)(optimoleActivationUrl); - updateOption('themeisle_sdk_promotions_optimole_installed', !Boolean(getOption('themeisle_sdk_promotions_optimole_installed'))); - setProgress('connecting'); - - try { - await fetch(optimoleApi, { - method: 'POST', - headers: { - 'X-WP-Nonce': nonce, - 'Content-Type': 'application/json' - }, - body: JSON.stringify({ - 'email': email - }) - }); - - if (onSuccess) { - onSuccess(); - } - - setProgress('done'); - } catch (e) { - setProgress('done'); - } - }; - - if (dismissed) { - return null; - } - - const form = () => { - if (progress === 'done') { - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "done" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, "Awesome! You are all set!"), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - icon: 'external', - isPrimary: true, - href: optimoleDash, - target: "_blank" - }, "Go to Optimole dashboard")); - } - - if (progress) { - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", { - className: "om-progress" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: "dashicons dashicons-update spin" - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", null, progress === 'installing' && 'Installing', progress === 'activating' && 'Activating', progress === 'connecting' && 'Connecting to API', "\u2026")); - } - - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.Fragment, null, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", null, "Enter your email address to create & connect your account"), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("form", { - onSubmit: submitForm - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("input", { - defaultValue: email, - type: "email", - onChange: updateEmail, - placeholder: "Email address" - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - isPrimary: true, - type: "submit" - }, "Start using Optimole"))); - }; - - const dismissButton = () => (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - disabled: progress && progress !== 'done', - onClick: dismissNotice, - isLink: true, - className: "om-notice-dismiss" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: "dashicons-no-alt dashicons" - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: "screen-reader-text" - }, "Dismiss this notice.")); - - if (stacked) { - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "ti-om-stack-wrap" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "om-stack-notice" - }, dismissButton(), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("img", { - src: assets + '/optimole-logo.svg', - alt: "Optimole logo" - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("h2", null, "Get more with Optimole"), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, type === 'om-editor' || type === 'om-image-block' ? 'Increase this page speed and SEO ranking by optimizing images with Optimole.' : 'Leverage Optimole\'s full integration with Elementor to automatically lazyload, resize, compress to AVIF/WebP and deliver from 400 locations around the globe!'), !showForm && 'done' !== progress && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - isPrimary: true, - onClick: toggleForm, - className: "cta" - }, "Get Started Free"), (showForm || 'done' === progress) && form(), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("i", null, title))); - } - - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.Fragment, null, dismissButton(), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "content" - }, !noImage && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("img", { - src: assets + '/optimole-logo.svg', - alt: "Optimole logo" - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", null, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, title), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", { - className: "description" - }, type === 'om-media' ? 'Save your server space by storing images to Optimole and deliver them optimized from 400 locations around the globe. Unlimited images, Unlimited traffic.' : 'This image looks to be too large and would affect your site speed, we recommend you to install Optimole to optimize your images.'), !showForm && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "actions" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - isPrimary: true, - onClick: toggleForm - }, "Get Started Free"), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - isLink: true, - target: "_blank", - href: "https://wordpress.org/plugins/optimole-wp" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: "dashicons dashicons-external" - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", null, "Learn more"))), showForm && (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "form-wrap" - }, form())))); -} - -/***/ }), - -/***/ "./assets/js/src/common/useSettings.js": -/*!*********************************************!*\ - !*** ./assets/js/src/common/useSettings.js ***! - \*********************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__) -/* harmony export */ }); -/* harmony import */ var _wordpress_api__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/api */ "@wordpress/api"); -/* harmony import */ var _wordpress_api__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_api__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/data */ "@wordpress/data"); -/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_data__WEBPACK_IMPORTED_MODULE_1__); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_2__); -/** - * WordPress dependencies. - */ - - - -/** - * useSettings Hook. - * - * useSettings hook to get/update WordPress' settings database. - * - * Setting field needs to be registered to REST for this function to work. - * - * This hook works similar to get_option and update_option in PHP just without the option for a default value. - * For notificiations to work, you need to add a Snackbar section to your React codebase if it isn't being - * used inside the block editor. - * - * @see https://github.com/WordPress/gutenberg/blob/trunk/packages/editor/src/components/editor-snackbars/index.js - * @author Hardeep Asrani - * @version 1.1 - * - */ - -const useSettings = () => { - const { - createNotice - } = (0,_wordpress_data__WEBPACK_IMPORTED_MODULE_1__.dispatch)('core/notices'); - const [settings, setSettings] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_2__.useState)({}); - const [status, setStatus] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_2__.useState)('loading'); - - const getSettings = () => { - _wordpress_api__WEBPACK_IMPORTED_MODULE_0___default().loadPromise.then(async () => { - try { - const settings = new (_wordpress_api__WEBPACK_IMPORTED_MODULE_0___default().models.Settings)(); - const response = await settings.fetch(); - setSettings(response); - } catch (error) { - setStatus('error'); - } finally { - setStatus('loaded'); - } - }); - }; - - (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_2__.useEffect)(() => { - getSettings(); - }, []); - - const getOption = option => { - return settings === null || settings === void 0 ? void 0 : settings[option]; - }; - - const updateOption = function (option, value) { - let success = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'Settings saved.'; - setStatus('saving'); - const save = new (_wordpress_api__WEBPACK_IMPORTED_MODULE_0___default().models.Settings)({ - [option]: value - }).save(); - save.success((response, status) => { - if ('success' === status) { - setStatus('loaded'); - createNotice('success', success, { - isDismissible: true, - type: 'snackbar' - }); - } - - if ('error' === status) { - setStatus('error'); - createNotice('error', 'An unknown error occurred.', { - isDismissible: true, - type: 'snackbar' - }); - } - - getSettings(); - }); - save.error(response => { - setStatus('error'); - createNotice('error', response.responseJSON.message ? response.responseJSON.message : 'An unknown error occurred.', { - isDismissible: true, - type: 'snackbar' - }); - }); - }; - - return [getOption, updateOption, status]; -}; - -/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (useSettings); - -/***/ }), - -/***/ "./assets/js/src/common/utils.js": -/*!***************************************!*\ - !*** ./assets/js/src/common/utils.js ***! - \***************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony export */ __webpack_require__.d(__webpack_exports__, { -/* harmony export */ "activatePlugin": () => (/* binding */ activatePlugin), -/* harmony export */ "getBlocksByType": () => (/* binding */ getBlocksByType), -/* harmony export */ "installPluginOrTheme": () => (/* binding */ installPluginOrTheme) -/* harmony export */ }); -const installPluginOrTheme = function (slug) { - let theme = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false; - return new Promise(resolve => { - wp.updates.ajax(theme === true ? 'install-theme' : 'install-plugin', { - slug, - success: () => { - resolve({ - success: true - }); - }, - error: err => { - resolve({ - success: false, - code: err.errorCode - }); - } - }); - }); -}; - -const activatePlugin = url => { - return new Promise(resolve => { - jQuery.get(url).done(() => { - resolve({ - success: true - }); - }).fail(() => { - resolve({ - success: false - }); - }); - }); -}; - -const flatRecursively = (r, a) => { - const b = {}; - Object.keys(a).forEach(function (k) { - if ('innerBlocks' !== k) { - b[k] = a[k]; - } - }); - r.push(b); - - if (Array.isArray(a.innerBlocks)) { - b.innerBlocks = a.innerBlocks.map(i => { - return i.id; - }); - return a.innerBlocks.reduce(flatRecursively, r); - } - - return r; -}; -/** - * Get blocks by type. - * - * @param {Array} blocks blocks array. - * @param {string} type type of block looking for. - * - * @return {Array} array of blocks of {type} in page - */ - - -const getBlocksByType = (blocks, type) => blocks.reduce(flatRecursively, []).filter(a => type === a.name); - - - -/***/ }), - -/***/ "./assets/js/src/index.js": -/*!********************************!*\ - !*** ./assets/js/src/index.js ***! - \********************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var _otter_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./otter.js */ "./assets/js/src/otter.js"); -/* harmony import */ var _optimole_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./optimole.js */ "./assets/js/src/optimole.js"); -/* harmony import */ var _rop_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./rop.js */ "./assets/js/src/rop.js"); -/* harmony import */ var _neve_fse_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./neve-fse.js */ "./assets/js/src/neve-fse.js"); - - - - - -/***/ }), - -/***/ "./assets/js/src/neve-fse.js": -/*!***********************************!*\ - !*** ./assets/js/src/neve-fse.js ***! - \***********************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); -/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__); -/* harmony import */ var _common_useSettings__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./common/useSettings */ "./assets/js/src/common/useSettings.js"); - - - - - -const NeveFSENotice = _ref => { - let { - onDismiss = () => {} - } = _ref; - const [getOption, updateOption] = (0,_common_useSettings__WEBPACK_IMPORTED_MODULE_2__["default"])(); - - const dismissNotice = async () => { - const newValue = { ...window.themeisleSDKPromotions.option - }; - newValue['neve-fse-themes-popular'] = new Date().getTime() / 1000 | 0; - window.themeisleSDKPromotions.option = newValue; - await updateOption(window.themeisleSDKPromotions.optionKey, JSON.stringify(newValue)); - - if (onDismiss) { - onDismiss(); - } - }; - - const { - neveFSEMoreUrl - } = window.themeisleSDKPromotions; - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.Fragment, null, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - onClick: dismissNotice, - className: "notice-dismiss" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: "screen-reader-text" - }, "Dismiss this notice.")), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, "Meet ", (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("b", null, "Neve FSE"), " from the makers of ", window.themeisleSDKPromotions.product, ". A theme that makes full site editing on WordPress straightforward and user-friendly."), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "neve-fse-notice-actions" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - variant: "link", - target: "_blank", - href: neveFSEMoreUrl - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: "dashicons dashicons-external" - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", null, "Learn more")))); -}; - -class NeveFSE { - constructor() { - const { - showPromotion, - debug - } = window.themeisleSDKPromotions; - this.promo = showPromotion; - this.debug = debug === '1'; - this.domRef = null; - this.run(); - } - - run() { - if (window.themeisleSDKPromotions.option['neve-fse-themes-popular']) { - return; - } - - const root = document.querySelector('#ti-neve-fse-notice'); - - if (!root) { - return; - } - - (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.render)((0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(NeveFSENotice, { - onDismiss: () => { - root.style.display = 'none'; - } - }), root); - } - -} - -new NeveFSE(); - -/***/ }), - -/***/ "./assets/js/src/optimole.js": -/*!***********************************!*\ - !*** ./assets/js/src/optimole.js ***! - \***********************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var _wordpress_plugins__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/plugins */ "@wordpress/plugins"); -/* harmony import */ var _wordpress_plugins__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_plugins__WEBPACK_IMPORTED_MODULE_1__); -/* harmony import */ var _wordpress_edit_post__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @wordpress/edit-post */ "@wordpress/edit-post"); -/* harmony import */ var _wordpress_edit_post__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_wordpress_edit_post__WEBPACK_IMPORTED_MODULE_2__); -/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @wordpress/data */ "@wordpress/data"); -/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_wordpress_data__WEBPACK_IMPORTED_MODULE_3__); -/* harmony import */ var _wordpress_compose__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @wordpress/compose */ "@wordpress/compose"); -/* harmony import */ var _wordpress_compose__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_wordpress_compose__WEBPACK_IMPORTED_MODULE_4__); -/* harmony import */ var _wordpress_hooks__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @wordpress/hooks */ "@wordpress/hooks"); -/* harmony import */ var _wordpress_hooks__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_wordpress_hooks__WEBPACK_IMPORTED_MODULE_5__); -/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @wordpress/block-editor */ "@wordpress/block-editor"); -/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_6__); -/* harmony import */ var _common_utils__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./common/utils */ "./assets/js/src/common/utils.js"); -/* harmony import */ var _OptimoleNotice__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./OptimoleNotice */ "./assets/js/src/OptimoleNotice/index.js"); - - - - - - - - - - - -const TiSdkMoleEditorPromo = () => { - const [show, setShow] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(true); - - const hide = () => { - setShow(false); - }; - - const { - getBlocks - } = (0,_wordpress_data__WEBPACK_IMPORTED_MODULE_3__.useSelect)(select => { - const { - getBlocks - } = select('core/block-editor'); - return { - getBlocks - }; - }); - const imageBlocksCount = (0,_common_utils__WEBPACK_IMPORTED_MODULE_7__.getBlocksByType)(getBlocks(), 'core/image').length; - - if (imageBlocksCount < 2) { - return null; - } - - const classes = `ti-sdk-optimole-post-publish ${show ? '' : 'hidden'}`; - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_edit_post__WEBPACK_IMPORTED_MODULE_2__.PluginPostPublishPanel, { - className: classes - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_OptimoleNotice__WEBPACK_IMPORTED_MODULE_8__["default"], { - stacked: true, - type: "om-editor", - onDismiss: hide - })); -}; - -class Optimole { - constructor() { - const { - showPromotion, - debug - } = window.themeisleSDKPromotions; - this.promo = showPromotion; - this.debug = debug === '1'; - this.domRef = null; - this.run(); - } - - run() { - if (this.debug) { - this.runAll(); - return; - } - - switch (this.promo) { - case 'om-attachment': - this.runAttachmentPromo(); - break; - - case 'om-media': - this.runMediaPromo(); - break; - - case 'om-editor': - this.runEditorPromo(); - break; - - case 'om-image-block': - this.runImageBlockPromo(); - break; - - case 'om-elementor': - this.runElementorPromo(); - break; - } - } - - runAttachmentPromo() { - wp.media.view.Attachment.Details.prototype.on("ready", () => { - setTimeout(() => { - this.removeAttachmentPromo(); - this.addAttachmentPromo(); - }, 100); - }); - wp.media.view.Modal.prototype.on("close", () => { - setTimeout(this.removeAttachmentPromo, 100); - }); - } - - runMediaPromo() { - if (window.themeisleSDKPromotions.option['om-media']) { - return; - } - - const root = document.querySelector('#ti-optml-notice'); - - if (!root) { - return; - } - - (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.render)((0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_OptimoleNotice__WEBPACK_IMPORTED_MODULE_8__["default"], { - type: "om-media", - onDismiss: () => { - root.style.opacity = 0; - } - }), root); - } - - runImageBlockPromo() { - if (window.themeisleSDKPromotions.option['om-image-block']) { - return; - } - - let showNotice = true; - let initialStatus = null; - const withImagePromo = (0,_wordpress_compose__WEBPACK_IMPORTED_MODULE_4__.createHigherOrderComponent)(BlockEdit => { - return props => { - if ('core/image' === props.name && showNotice) { - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.Fragment, null, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(BlockEdit, props), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_6__.InspectorControls, null, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_OptimoleNotice__WEBPACK_IMPORTED_MODULE_8__["default"], { - stacked: true, - type: "om-image-block", - initialStatus: initialStatus, - onDismiss: () => { - showNotice = false; - }, - onSuccess: () => { - initialStatus = 'done'; - } - }))); - } - - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(BlockEdit, props); - }; - }, 'withImagePromo'); - (0,_wordpress_hooks__WEBPACK_IMPORTED_MODULE_5__.addFilter)('editor.BlockEdit', 'optimole-promo/image-promo', withImagePromo, 99); - } - - runEditorPromo() { - if (window.themeisleSDKPromotions.option['om-editor']) { - return; - } - - (0,_wordpress_plugins__WEBPACK_IMPORTED_MODULE_1__.registerPlugin)('optimole-promo', { - render: TiSdkMoleEditorPromo - }); - } - - runElementorPromo() { - if (!window.elementor) { - return; - } - - const self = this; - elementor.on("preview:loaded", () => { - elementor.panel.currentView.on("set:page:editor", details => { - if (self.domRef) { - (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.unmountComponentAtNode)(self.domRef); - } - - if (!details.activeSection) { - return; - } - - if (details.activeSection !== 'section_image') { - return; - } - - self.runElementorActions(self); - }); - }); - } - - addAttachmentPromo() { - if (this.domRef) { - (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.unmountComponentAtNode)(this.domRef); - } - - if (window.themeisleSDKPromotions.option['om-attachment']) { - return; - } - - const mount = document.querySelector('#ti-optml-notice-helper'); - - if (!mount) { - return; - } - - this.domRef = mount; - (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.render)((0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "notice notice-info ti-sdk-om-notice", - style: { - margin: 0 - } - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_OptimoleNotice__WEBPACK_IMPORTED_MODULE_8__["default"], { - noImage: true, - type: "om-attachment", - onDismiss: () => { - mount.style.opacity = 0; - } - })), mount); - } - - removeAttachmentPromo() { - const mount = document.querySelector('#ti-optml-notice-helper'); - - if (!mount) { - return; - } - - (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.unmountComponentAtNode)(mount); - } - - runElementorActions(self) { - if (window.themeisleSDKPromotions.option['om-elementor']) { - return; - } - - const controlsWrap = document.querySelector('#elementor-panel__editor__help'); - const mountPoint = document.createElement('div'); - mountPoint.id = 'ti-optml-notice'; - self.domRef = mountPoint; - - if (controlsWrap) { - controlsWrap.parentNode.insertBefore(mountPoint, controlsWrap); - (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.render)((0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_OptimoleNotice__WEBPACK_IMPORTED_MODULE_8__["default"], { - stacked: true, - type: "om-elementor", - onDismiss: () => { - mountPoint.style.opacity = 0; - } - }), mountPoint); - } - } - - runAll() { - this.runAttachmentPromo(); - this.runMediaPromo(); - this.runEditorPromo(); - this.runImageBlockPromo(); - this.runElementorPromo(); - } - -} - -new Optimole(); - -/***/ }), - -/***/ "./assets/js/src/otter.js": -/*!********************************!*\ - !*** ./assets/js/src/otter.js ***! - \********************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/block-editor */ "@wordpress/block-editor"); -/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__); -/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); -/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__); -/* harmony import */ var _wordpress_compose__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @wordpress/compose */ "@wordpress/compose"); -/* harmony import */ var _wordpress_compose__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_wordpress_compose__WEBPACK_IMPORTED_MODULE_3__); -/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @wordpress/data */ "@wordpress/data"); -/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_wordpress_data__WEBPACK_IMPORTED_MODULE_4__); -/* harmony import */ var _wordpress_hooks__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @wordpress/hooks */ "@wordpress/hooks"); -/* harmony import */ var _wordpress_hooks__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_wordpress_hooks__WEBPACK_IMPORTED_MODULE_5__); -/* harmony import */ var _common_useSettings_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./common/useSettings.js */ "./assets/js/src/common/useSettings.js"); -/* harmony import */ var _common_utils_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./common/utils.js */ "./assets/js/src/common/utils.js"); - - - - - - - - - -const style = { - button: { - display: 'flex', - justifyContent: 'center', - width: '100%' - }, - image: { - padding: '20px 0' - }, - skip: { - container: { - display: 'flex', - flexDirection: 'column', - alignItems: 'center' - }, - button: { - fontSize: '9px' - }, - poweredby: { - fontSize: '9px', - textTransform: 'uppercase' - } - } -}; -const upsells = { - 'blocks-css': { - title: 'Custom CSS', - description: 'Enable Otter Blocks to add Custom CSS for this block.', - image: 'css.jpg' - }, - 'blocks-animation': { - title: 'Animations', - description: 'Enable Otter Blocks to add Animations for this block.', - image: 'animation.jpg' - }, - 'blocks-conditions': { - title: 'Visibility Conditions', - description: 'Enable Otter Blocks to add Visibility Conditions for this block.', - image: 'conditions.jpg' - } -}; - -const Footer = _ref => { - let { - onClick - } = _ref; - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - style: style.skip.container - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.Button, { - style: style.skip.button, - variant: "tertiary", - onClick: onClick - }, "Skip for now"), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - style: style.skip.poweredby - }, "Recommended by ", window.themeisleSDKPromotions.product)); -}; - -const withInspectorControls = (0,_wordpress_compose__WEBPACK_IMPORTED_MODULE_3__.createHigherOrderComponent)(BlockEdit => { - return props => { - if (props.isSelected && Boolean(window.themeisleSDKPromotions.showPromotion)) { - const [isLoading, setLoading] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(false); - const [installStatus, setInstallStatus] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)('default'); - const [hasSkipped, setHasSkipped] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(false); - const [getOption, updateOption, status] = (0,_common_useSettings_js__WEBPACK_IMPORTED_MODULE_6__["default"])(); - - const install = async () => { - setLoading(true); - await (0,_common_utils_js__WEBPACK_IMPORTED_MODULE_7__.installPluginOrTheme)('otter-blocks'); - updateOption('themeisle_sdk_promotions_otter_installed', !Boolean(getOption('themeisle_sdk_promotions_otter_installed'))); - await (0,_common_utils_js__WEBPACK_IMPORTED_MODULE_7__.activatePlugin)(window.themeisleSDKPromotions.otterActivationUrl); - setLoading(false); - setInstallStatus('installed'); - }; - - const Install = () => { - if ('installed' === installStatus) { - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("strong", null, "Awesome! Refresh the page to see Otter Blocks in action.")); - } - - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.Button, { - variant: "secondary", - onClick: install, - isBusy: isLoading, - style: style.button - }, "Install & Activate Otter Blocks"); - }; - - const onSkip = () => { - const option = { ...window.themeisleSDKPromotions.option - }; - option[window.themeisleSDKPromotions.showPromotion] = new Date().getTime() / 1000 | 0; - updateOption('themeisle_sdk_promotions', JSON.stringify(option)); - window.themeisleSDKPromotions.showPromotion = false; - }; - - (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useEffect)(() => { - if (hasSkipped) { - onSkip(); - } - }, [hasSkipped]); - - if (hasSkipped) { - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(BlockEdit, props); - } - - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.Fragment, null, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(BlockEdit, props), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.InspectorControls, null, Object.keys(upsells).map(key => { - if (key === window.themeisleSDKPromotions.showPromotion) { - const upsell = upsells[key]; - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.PanelBody, { - key: key, - title: upsell.title, - initialOpen: false - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, upsell.description), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(Install, null), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("img", { - style: style.image, - src: window.themeisleSDKPromotions.assets + upsell.image - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(Footer, { - onClick: () => setHasSkipped(true) - })); - } - }))); - } - - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(BlockEdit, props); - }; -}, 'withInspectorControl'); - -if (!(0,_wordpress_data__WEBPACK_IMPORTED_MODULE_4__.select)('core/edit-site')) { - (0,_wordpress_hooks__WEBPACK_IMPORTED_MODULE_5__.addFilter)('editor.BlockEdit', 'themeisle-sdk/with-inspector-controls', withInspectorControls); -} - -/***/ }), - -/***/ "./assets/js/src/rop.js": -/*!******************************!*\ - !*** ./assets/js/src/rop.js ***! - \******************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); -/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); -/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__); -/* harmony import */ var _common_utils__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./common/utils */ "./assets/js/src/common/utils.js"); -/* harmony import */ var _common_useSettings__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./common/useSettings */ "./assets/js/src/common/useSettings.js"); - - - - - - -const ROPNotice = _ref => { - let { - onDismiss = () => {} - } = _ref; - const [status, setStatus] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.useState)(''); - const [getOption, updateOption] = (0,_common_useSettings__WEBPACK_IMPORTED_MODULE_3__["default"])(); - - const dismissNotice = async () => { - const newValue = { ...window.themeisleSDKPromotions.option - }; - newValue['rop-posts'] = new Date().getTime() / 1000 | 0; - window.themeisleSDKPromotions.option = newValue; - await updateOption(window.themeisleSDKPromotions.optionKey, JSON.stringify(newValue)); - - if (onDismiss) { - onDismiss(); - } - }; - - return (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.Fragment, null, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - disabled: 'installing' === status, - onClick: dismissNotice, - variant: "link", - className: "om-notice-dismiss" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: "dashicons-no-alt dashicons" - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: "screen-reader-text" - }, "Dismiss this notice.")), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("p", null, "Boost your content's reach effortlessly! Introducing ", (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("b", null, "Revive Old Posts"), ", a cutting-edge plugin from the makers of ", window.themeisleSDKPromotions.product, ". Seamlessly auto-share old & new content across social media, driving traffic like never before."), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("div", { - className: "rop-notice-actions" - }, 'installed' !== status ? (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - variant: "primary", - isBusy: 'installing' === status, - onClick: async () => { - setStatus('installing'); - await (0,_common_utils__WEBPACK_IMPORTED_MODULE_2__.installPluginOrTheme)('tweet-old-post'); - await (0,_common_utils__WEBPACK_IMPORTED_MODULE_2__.activatePlugin)(window.themeisleSDKPromotions.ropActivationUrl); - updateOption('themeisle_sdk_promotions_rop_installed', !Boolean(getOption('themeisle_sdk_promotions_rop_installed'))); - setStatus('installed'); - } - }, "Install & Activate") : (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - variant: "primary", - href: window.themeisleSDKPromotions.ropDash - }, "Visit Dashboard"), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(_wordpress_components__WEBPACK_IMPORTED_MODULE_1__.Button, { - variant: "link", - target: "_blank", - href: "https://wordpress.org/plugins/tweet-old-post/" - }, (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", { - className: "dashicons dashicons-external" - }), (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)("span", null, "Learn more")))); -}; - -class ROP { - constructor() { - const { - showPromotion, - debug - } = window.themeisleSDKPromotions; - this.promo = showPromotion; - this.debug = debug === '1'; - this.domRef = null; - this.run(); - } - - run() { - if (window.themeisleSDKPromotions.option['rop-posts']) { - return; - } - - const root = document.querySelector('#ti-rop-notice'); - - if (!root) { - return; - } - - (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.render)((0,_wordpress_element__WEBPACK_IMPORTED_MODULE_0__.createElement)(ROPNotice, { - onDismiss: () => { - root.style.display = 'none'; - } - }), root); - } - -} - -new ROP(); - -/***/ }), - -/***/ "./assets/js/src/OptimoleNotice/style.scss": -/*!*************************************************!*\ - !*** ./assets/js/src/OptimoleNotice/style.scss ***! - \*************************************************/ -/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { - -__webpack_require__.r(__webpack_exports__); -// extracted by mini-css-extract-plugin - - -/***/ }), - -/***/ "@wordpress/api": -/*!*****************************!*\ - !*** external ["wp","api"] ***! - \*****************************/ -/***/ ((module) => { - -module.exports = window["wp"]["api"]; - -/***/ }), - -/***/ "@wordpress/block-editor": -/*!*************************************!*\ - !*** external ["wp","blockEditor"] ***! - \*************************************/ -/***/ ((module) => { - -module.exports = window["wp"]["blockEditor"]; - -/***/ }), - -/***/ "@wordpress/components": -/*!************************************!*\ - !*** external ["wp","components"] ***! - \************************************/ -/***/ ((module) => { - -module.exports = window["wp"]["components"]; - -/***/ }), - -/***/ "@wordpress/compose": -/*!*********************************!*\ - !*** external ["wp","compose"] ***! - \*********************************/ -/***/ ((module) => { - -module.exports = window["wp"]["compose"]; - -/***/ }), - -/***/ "@wordpress/data": -/*!******************************!*\ - !*** external ["wp","data"] ***! - \******************************/ -/***/ ((module) => { - -module.exports = window["wp"]["data"]; - -/***/ }), - -/***/ "@wordpress/edit-post": -/*!**********************************!*\ - !*** external ["wp","editPost"] ***! - \**********************************/ -/***/ ((module) => { - -module.exports = window["wp"]["editPost"]; - -/***/ }), - -/***/ "@wordpress/element": -/*!*********************************!*\ - !*** external ["wp","element"] ***! - \*********************************/ -/***/ ((module) => { - -module.exports = window["wp"]["element"]; - -/***/ }), - -/***/ "@wordpress/hooks": -/*!*******************************!*\ - !*** external ["wp","hooks"] ***! - \*******************************/ -/***/ ((module) => { - -module.exports = window["wp"]["hooks"]; - -/***/ }), - -/***/ "@wordpress/plugins": -/*!*********************************!*\ - !*** external ["wp","plugins"] ***! - \*********************************/ -/***/ ((module) => { - -module.exports = window["wp"]["plugins"]; - -/***/ }) - -/******/ }); -/************************************************************************/ -/******/ // The module cache -/******/ var __webpack_module_cache__ = {}; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ // Check if module is in cache -/******/ var cachedModule = __webpack_module_cache__[moduleId]; -/******/ if (cachedModule !== undefined) { -/******/ return cachedModule.exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = __webpack_module_cache__[moduleId] = { -/******/ // no module.id needed -/******/ // no module.loaded needed -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/******/ // expose the modules object (__webpack_modules__) -/******/ __webpack_require__.m = __webpack_modules__; -/******/ -/************************************************************************/ -/******/ /* webpack/runtime/chunk loaded */ -/******/ (() => { -/******/ var deferred = []; -/******/ __webpack_require__.O = (result, chunkIds, fn, priority) => { -/******/ if(chunkIds) { -/******/ priority = priority || 0; -/******/ for(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1]; -/******/ deferred[i] = [chunkIds, fn, priority]; -/******/ return; -/******/ } -/******/ var notFulfilled = Infinity; -/******/ for (var i = 0; i < deferred.length; i++) { -/******/ var chunkIds = deferred[i][0]; -/******/ var fn = deferred[i][1]; -/******/ var priority = deferred[i][2]; -/******/ var fulfilled = true; -/******/ for (var j = 0; j < chunkIds.length; j++) { -/******/ if ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) { -/******/ chunkIds.splice(j--, 1); -/******/ } else { -/******/ fulfilled = false; -/******/ if(priority < notFulfilled) notFulfilled = priority; -/******/ } -/******/ } -/******/ if(fulfilled) { -/******/ deferred.splice(i--, 1) -/******/ var r = fn(); -/******/ if (r !== undefined) result = r; -/******/ } -/******/ } -/******/ return result; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/compat get default export */ -/******/ (() => { -/******/ // getDefaultExport function for compatibility with non-harmony modules -/******/ __webpack_require__.n = (module) => { -/******/ var getter = module && module.__esModule ? -/******/ () => (module['default']) : -/******/ () => (module); -/******/ __webpack_require__.d(getter, { a: getter }); -/******/ return getter; -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/define property getters */ -/******/ (() => { -/******/ // define getter functions for harmony exports -/******/ __webpack_require__.d = (exports, definition) => { -/******/ for(var key in definition) { -/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { -/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); -/******/ } -/******/ } -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/hasOwnProperty shorthand */ -/******/ (() => { -/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) -/******/ })(); -/******/ -/******/ /* webpack/runtime/make namespace object */ -/******/ (() => { -/******/ // define __esModule on exports -/******/ __webpack_require__.r = (exports) => { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ })(); -/******/ -/******/ /* webpack/runtime/jsonp chunk loading */ -/******/ (() => { -/******/ // no baseURI -/******/ -/******/ // object to store loaded and loading chunks -/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched -/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded -/******/ var installedChunks = { -/******/ "index": 0, -/******/ "./style-index": 0 -/******/ }; -/******/ -/******/ // no chunk on demand loading -/******/ -/******/ // no prefetching -/******/ -/******/ // no preloaded -/******/ -/******/ // no HMR -/******/ -/******/ // no HMR manifest -/******/ -/******/ __webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0); -/******/ -/******/ // install a JSONP callback for chunk loading -/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => { -/******/ var chunkIds = data[0]; -/******/ var moreModules = data[1]; -/******/ var runtime = data[2]; -/******/ // add "moreModules" to the modules object, -/******/ // then flag all "chunkIds" as loaded and fire callback -/******/ var moduleId, chunkId, i = 0; -/******/ if(chunkIds.some((id) => (installedChunks[id] !== 0))) { -/******/ for(moduleId in moreModules) { -/******/ if(__webpack_require__.o(moreModules, moduleId)) { -/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; -/******/ } -/******/ } -/******/ if(runtime) var result = runtime(__webpack_require__); -/******/ } -/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); -/******/ for(;i < chunkIds.length; i++) { -/******/ chunkId = chunkIds[i]; -/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { -/******/ installedChunks[chunkId][0](); -/******/ } -/******/ installedChunks[chunkId] = 0; -/******/ } -/******/ return __webpack_require__.O(result); -/******/ } -/******/ -/******/ var chunkLoadingGlobal = self["webpackChunkthemeisle_sdk"] = self["webpackChunkthemeisle_sdk"] || []; -/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); -/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); -/******/ })(); -/******/ -/************************************************************************/ -/******/ -/******/ // startup -/******/ // Load entry module and return exports -/******/ // This entry module depends on other loaded chunks and execution need to be delayed -/******/ var __webpack_exports__ = __webpack_require__.O(undefined, ["./style-index"], () => (__webpack_require__("./assets/js/src/index.js"))) -/******/ __webpack_exports__ = __webpack_require__.O(__webpack_exports__); -/******/ -/******/ })() -; -//# sourceMappingURL=index.js.map \ No newline at end of file +!function(){"use strict";var e,t={165:function(){var e=window.wp.element,t=window.wp.blockEditor,o=window.wp.components,n=window.wp.compose,i=window.wp.data,s=window.wp.hooks,r=()=>{const{createNotice:t}=(0,i.dispatch)("core/notices"),[o,n]=(0,e.useState)({}),[s,r]=(0,e.useState)("loading");return(0,i.useSelect)((e=>{if(Object.keys(o).length)return;const{getEntityRecord:t}=e("core"),i=t("root","site");i&&(r("loaded"),n(i))}),[]),[e=>null==o?void 0:o[e],async function(e,o){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"Settings saved.";const s={[e]:o};try{const e=await fetch("/wp-json/wp/v2/settings",{method:"POST",headers:{"Content-Type":"application/json","X-WP-Nonce":wpApiSettings.nonce},body:JSON.stringify(s)});e.ok||(r("error"),t("error","Could not save the settings.",{isDismissible:!0,type:"snackbar"}));const o=await e.json();r("loaded"),t("success",i,{isDismissible:!0,type:"snackbar"}),n(o)}catch(e){console.error("Error updating option:",e)}},s]};const a=function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return new Promise((o=>{wp.updates.ajax(!0===t?"install-theme":"install-plugin",{slug:e,success:()=>{o({success:!0})},error:e=>{o({success:!1,code:e.errorCode})}})}))},l=e=>new Promise((t=>{jQuery.get(e).done((()=>{t({success:!0})})).fail((()=>{t({success:!1})}))})),m=(e,t)=>{const o={};return Object.keys(t).forEach((function(e){"innerBlocks"!==e&&(o[e]=t[e])})),e.push(o),Array.isArray(t.innerBlocks)?(o.innerBlocks=t.innerBlocks.map((e=>e.id)),t.innerBlocks.reduce(m,e)):e},c={button:{display:"flex",justifyContent:"center",width:"100%"},image:{padding:"20px 0"},skip:{container:{display:"flex",flexDirection:"column",alignItems:"center"},button:{fontSize:"9px"},poweredby:{fontSize:"9px",textTransform:"uppercase"}}},d={"blocks-css":{title:"Custom CSS",description:"Enable Otter Blocks to add Custom CSS for this block.",image:"css.jpg"},"blocks-animation":{title:"Animations",description:"Enable Otter Blocks to add Animations for this block.",image:"animation.jpg"},"blocks-conditions":{title:"Visibility Conditions",description:"Enable Otter Blocks to add Visibility Conditions for this block.",image:"conditions.jpg"}},u=t=>{let{onClick:n}=t;return(0,e.createElement)("div",{style:c.skip.container},(0,e.createElement)(o.Button,{style:c.skip.button,variant:"tertiary",onClick:n},"Skip for now"),(0,e.createElement)("span",{style:c.skip.poweredby},"Recommended by ",window.themeisleSDKPromotions.product))},p=(0,n.createHigherOrderComponent)((n=>i=>{if(i.isSelected&&Boolean(window.themeisleSDKPromotions.showPromotion)){const[s,m]=(0,e.useState)(!1),[p,h]=(0,e.useState)("default"),[w,g]=(0,e.useState)(!1),[f,E,y]=r(),k=async()=>{m(!0),await a("otter-blocks"),E("themeisle_sdk_promotions_otter_installed",!Boolean(f("themeisle_sdk_promotions_otter_installed"))),await l(window.themeisleSDKPromotions.otterActivationUrl),m(!1),h("installed")},S=()=>"installed"===p?(0,e.createElement)("p",null,(0,e.createElement)("strong",null,"Awesome! Refresh the page to see Otter Blocks in action.")):(0,e.createElement)(o.Button,{variant:"secondary",onClick:k,isBusy:s,style:c.button},"Install & Activate Otter Blocks"),P=()=>{const e={...window.themeisleSDKPromotions.option};e[window.themeisleSDKPromotions.showPromotion]=(new Date).getTime()/1e3|0,E("themeisle_sdk_promotions",JSON.stringify(e)),window.themeisleSDKPromotions.showPromotion=!1};return(0,e.useEffect)((()=>{w&&P()}),[w]),w?(0,e.createElement)(n,i):(0,e.createElement)(e.Fragment,null,(0,e.createElement)(n,i),(0,e.createElement)(t.InspectorControls,null,Object.keys(d).map((t=>{if(t===window.themeisleSDKPromotions.showPromotion){const n=d[t];return(0,e.createElement)(o.PanelBody,{key:t,title:n.title,initialOpen:!1},(0,e.createElement)("p",null,n.description),(0,e.createElement)(S,null),(0,e.createElement)("img",{style:c.image,src:window.themeisleSDKPromotions.assets+n.image}),(0,e.createElement)(u,{onClick:()=>g(!0)}))}}))))}return(0,e.createElement)(n,i)}),"withInspectorControl");(0,i.select)("core/edit-site")||(0,s.addFilter)("editor.BlockEdit","themeisle-sdk/with-inspector-controls",p);var h=window.wp.plugins,w=window.wp.editPost;function g(t){let{stacked:n=!1,noImage:i=!1,type:s,onDismiss:m,onSuccess:c,initialStatus:d=null}=t;const{assets:u,title:p,email:h,option:w,optionKey:g,optimoleActivationUrl:f,optimoleApi:E,optimoleDash:y,nonce:k}=window.themeisleSDKPromotions,[S,P]=(0,e.useState)(!1),[v,b]=(0,e.useState)(h||""),[D,B]=(0,e.useState)(!1),[O,N]=(0,e.useState)(d),[_,K]=r(),A=async()=>{B(!0);const e={...w};e[s]=(new Date).getTime()/1e3|0,window.themeisleSDKPromotions.option=e,await K(g,JSON.stringify(e)),m&&m()},C=()=>{P(!S)},x=e=>{b(e.target.value)},I=async e=>{e.preventDefault(),N("installing"),await a("optimole-wp"),N("activating"),await l(f),K("themeisle_sdk_promotions_optimole_installed",!Boolean(_("themeisle_sdk_promotions_optimole_installed"))),N("connecting");try{await fetch(E,{method:"POST",headers:{"X-WP-Nonce":k,"Content-Type":"application/json"},body:JSON.stringify({email:v})}),c&&c(),N("done")}catch(e){N("done")}};if(D)return null;const j=()=>"done"===O?(0,e.createElement)("div",{className:"done"},(0,e.createElement)("p",null,"Awesome! You are all set!"),(0,e.createElement)(o.Button,{icon:"external",isPrimary:!0,href:y,target:"_blank"},"Go to Optimole dashboard")):O?(0,e.createElement)("p",{className:"om-progress"},(0,e.createElement)("span",{className:"dashicons dashicons-update spin"}),(0,e.createElement)("span",null,"installing"===O&&"Installing","activating"===O&&"Activating","connecting"===O&&"Connecting to API","…")):(0,e.createElement)(e.Fragment,null,(0,e.createElement)("span",null,"Enter your email address to create & connect your account"),(0,e.createElement)("form",{onSubmit:I},(0,e.createElement)("input",{defaultValue:v,type:"email",onChange:x,placeholder:"Email address"}),(0,e.createElement)(o.Button,{isPrimary:!0,type:"submit"},"Start using Optimole"))),F=()=>(0,e.createElement)(o.Button,{disabled:O&&"done"!==O,onClick:A,isLink:!0,className:"om-notice-dismiss"},(0,e.createElement)("span",{className:"dashicons-no-alt dashicons"}),(0,e.createElement)("span",{className:"screen-reader-text"},"Dismiss this notice."));return n?(0,e.createElement)("div",{className:"ti-om-stack-wrap"},(0,e.createElement)("div",{className:"om-stack-notice"},F(),(0,e.createElement)("img",{src:u+"/optimole-logo.svg",alt:"Optimole logo"}),(0,e.createElement)("h2",null,"Get more with Optimole"),(0,e.createElement)("p",null,"om-editor"===s||"om-image-block"===s?"Increase this page speed and SEO ranking by optimizing images with Optimole.":"Leverage Optimole's full integration with Elementor to automatically lazyload, resize, compress to AVIF/WebP and deliver from 400 locations around the globe!"),!S&&"done"!==O&&(0,e.createElement)(o.Button,{isPrimary:!0,onClick:C,className:"cta"},"Get Started Free"),(S||"done"===O)&&j(),(0,e.createElement)("i",null,p))):(0,e.createElement)(e.Fragment,null,F(),(0,e.createElement)("div",{className:"content"},!i&&(0,e.createElement)("img",{src:u+"/optimole-logo.svg",alt:"Optimole logo"}),(0,e.createElement)("div",null,(0,e.createElement)("p",null,p),(0,e.createElement)("p",{className:"description"},"om-media"===s?"Save your server space by storing images to Optimole and deliver them optimized from 400 locations around the globe. Unlimited images, Unlimited traffic.":"This image looks to be too large and would affect your site speed, we recommend you to install Optimole to optimize your images."),!S&&(0,e.createElement)("div",{className:"actions"},(0,e.createElement)(o.Button,{isPrimary:!0,onClick:C},"Get Started Free"),(0,e.createElement)(o.Button,{isLink:!0,target:"_blank",href:"https://wordpress.org/plugins/optimole-wp"},(0,e.createElement)("span",{className:"dashicons dashicons-external"}),(0,e.createElement)("span",null,"Learn more"))),S&&(0,e.createElement)("div",{className:"form-wrap"},j()))))}const f=()=>{const[t,o]=(0,e.useState)(!0),{getBlocks:n}=(0,i.useSelect)((e=>{const{getBlocks:t}=e("core/block-editor");return{getBlocks:t}}));var s;if((s=n(),"core/image",s.reduce(m,[]).filter((e=>"core/image"===e.name))).length<2)return null;const r="ti-sdk-optimole-post-publish "+(t?"":"hidden");return(0,e.createElement)(w.PluginPostPublishPanel,{className:r},(0,e.createElement)(g,{stacked:!0,type:"om-editor",onDismiss:()=>{o(!1)}}))};new class{constructor(){const{showPromotion:e,debug:t}=window.themeisleSDKPromotions;this.promo=e,this.debug="1"===t,this.domRef=null,this.run()}run(){if(this.debug)this.runAll();else switch(this.promo){case"om-attachment":this.runAttachmentPromo();break;case"om-media":this.runMediaPromo();break;case"om-editor":this.runEditorPromo();break;case"om-image-block":this.runImageBlockPromo();break;case"om-elementor":this.runElementorPromo()}}runAttachmentPromo(){wp.media.view.Attachment.Details.prototype.on("ready",(()=>{setTimeout((()=>{this.removeAttachmentPromo(),this.addAttachmentPromo()}),100)})),wp.media.view.Modal.prototype.on("close",(()=>{setTimeout(this.removeAttachmentPromo,100)}))}runMediaPromo(){if(window.themeisleSDKPromotions.option["om-media"])return;const t=document.querySelector("#ti-optml-notice");t&&(0,e.render)((0,e.createElement)(g,{type:"om-media",onDismiss:()=>{t.style.opacity=0}}),t)}runImageBlockPromo(){if(window.themeisleSDKPromotions.option["om-image-block"])return;let o=!0,i=null;const r=(0,n.createHigherOrderComponent)((n=>s=>"core/image"===s.name&&o?(0,e.createElement)(e.Fragment,null,(0,e.createElement)(n,s),(0,e.createElement)(t.InspectorControls,null,(0,e.createElement)(g,{stacked:!0,type:"om-image-block",initialStatus:i,onDismiss:()=>{o=!1},onSuccess:()=>{i="done"}}))):(0,e.createElement)(n,s)),"withImagePromo");(0,s.addFilter)("editor.BlockEdit","optimole-promo/image-promo",r,99)}runEditorPromo(){window.themeisleSDKPromotions.option["om-editor"]||(0,h.registerPlugin)("optimole-promo",{render:f})}runElementorPromo(){if(!window.elementor)return;const t=this;elementor.on("preview:loaded",(()=>{elementor.panel.currentView.on("set:page:editor",(o=>{t.domRef&&(0,e.unmountComponentAtNode)(t.domRef),o.activeSection&&"section_image"===o.activeSection&&t.runElementorActions(t)}))}))}addAttachmentPromo(){if(this.domRef&&(0,e.unmountComponentAtNode)(this.domRef),window.themeisleSDKPromotions.option["om-attachment"])return;const t=document.querySelector("#ti-optml-notice-helper");t&&(this.domRef=t,(0,e.render)((0,e.createElement)("div",{className:"notice notice-info ti-sdk-om-notice",style:{margin:0}},(0,e.createElement)(g,{noImage:!0,type:"om-attachment",onDismiss:()=>{t.style.opacity=0}})),t))}removeAttachmentPromo(){const t=document.querySelector("#ti-optml-notice-helper");t&&(0,e.unmountComponentAtNode)(t)}runElementorActions(t){if(window.themeisleSDKPromotions.option["om-elementor"])return;const o=document.querySelector("#elementor-panel__editor__help"),n=document.createElement("div");n.id="ti-optml-notice",t.domRef=n,o&&(o.parentNode.insertBefore(n,o),(0,e.render)((0,e.createElement)(g,{stacked:!0,type:"om-elementor",onDismiss:()=>{n.style.opacity=0}}),n))}runAll(){this.runAttachmentPromo(),this.runMediaPromo(),this.runEditorPromo(),this.runImageBlockPromo(),this.runElementorPromo()}};const E=t=>{let{onDismiss:n=(()=>{})}=t;const[i,s]=(0,e.useState)(""),[m,c]=r();return(0,e.createElement)(e.Fragment,null,(0,e.createElement)(o.Button,{disabled:"installing"===i,onClick:async()=>{const e={...window.themeisleSDKPromotions.option};e["rop-posts"]=(new Date).getTime()/1e3|0,window.themeisleSDKPromotions.option=e,await c(window.themeisleSDKPromotions.optionKey,JSON.stringify(e)),n&&n()},variant:"link",className:"om-notice-dismiss"},(0,e.createElement)("span",{className:"dashicons-no-alt dashicons"}),(0,e.createElement)("span",{className:"screen-reader-text"},"Dismiss this notice.")),(0,e.createElement)("p",null,"Boost your content's reach effortlessly! Introducing ",(0,e.createElement)("b",null,"Revive Old Posts"),", a cutting-edge plugin from the makers of ",window.themeisleSDKPromotions.product,". Seamlessly auto-share old & new content across social media, driving traffic like never before."),(0,e.createElement)("div",{className:"rop-notice-actions"},"installed"!==i?(0,e.createElement)(o.Button,{variant:"primary",isBusy:"installing"===i,onClick:async()=>{s("installing"),await a("tweet-old-post"),await l(window.themeisleSDKPromotions.ropActivationUrl),c("themeisle_sdk_promotions_rop_installed",!Boolean(m("themeisle_sdk_promotions_rop_installed"))),s("installed")}},"Install & Activate"):(0,e.createElement)(o.Button,{variant:"primary",href:window.themeisleSDKPromotions.ropDash},"Visit Dashboard"),(0,e.createElement)(o.Button,{variant:"link",target:"_blank",href:"https://wordpress.org/plugins/tweet-old-post/"},(0,e.createElement)("span",{className:"dashicons dashicons-external"}),(0,e.createElement)("span",null,"Learn more"))))};new class{constructor(){const{showPromotion:e,debug:t}=window.themeisleSDKPromotions;this.promo=e,this.debug="1"===t,this.domRef=null,this.run()}run(){if(window.themeisleSDKPromotions.option["rop-posts"])return;const t=document.querySelector("#ti-rop-notice");t&&(0,e.render)((0,e.createElement)(E,{onDismiss:()=>{t.style.display="none"}}),t)}};const y=t=>{let{onDismiss:n=(()=>{})}=t;const[i,s]=r(),{neveFSEMoreUrl:a}=window.themeisleSDKPromotions;return(0,e.createElement)(e.Fragment,null,(0,e.createElement)(o.Button,{onClick:async()=>{const e={...window.themeisleSDKPromotions.option};e["neve-fse-themes-popular"]=(new Date).getTime()/1e3|0,window.themeisleSDKPromotions.option=e,await s(window.themeisleSDKPromotions.optionKey,JSON.stringify(e)),n&&n()},className:"notice-dismiss"},(0,e.createElement)("span",{className:"screen-reader-text"},"Dismiss this notice.")),(0,e.createElement)("p",null,"Meet ",(0,e.createElement)("b",null,"Neve FSE")," from the makers of ",window.themeisleSDKPromotions.product,". A theme that makes full site editing on WordPress straightforward and user-friendly."),(0,e.createElement)("div",{className:"neve-fse-notice-actions"},(0,e.createElement)(o.Button,{variant:"link",target:"_blank",href:a},(0,e.createElement)("span",{className:"dashicons dashicons-external"}),(0,e.createElement)("span",null,"Learn more"))))};new class{constructor(){const{showPromotion:e,debug:t}=window.themeisleSDKPromotions;this.promo=e,this.debug="1"===t,this.domRef=null,this.run()}run(){if(window.themeisleSDKPromotions.option["neve-fse-themes-popular"])return;const t=document.querySelector("#ti-neve-fse-notice");t&&(0,e.render)((0,e.createElement)(y,{onDismiss:()=>{t.style.display="none"}}),t)}}}},o={};function n(e){var i=o[e];if(void 0!==i)return i.exports;var s=o[e]={exports:{}};return t[e](s,s.exports,n),s.exports}n.m=t,e=[],n.O=function(t,o,i,s){if(!o){var r=1/0;for(c=0;c=s)&&Object.keys(n.O).every((function(e){return n.O[e](o[l])}))?o.splice(l--,1):(a=!1,s0&&e[c-1][2]>s;c--)e[c]=e[c-1];e[c]=[o,i,s]},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},function(){var e={826:0,431:0};n.O.j=function(t){return 0===e[t]};var t=function(t,o){var i,s,r=o[0],a=o[1],l=o[2],m=0;if(r.some((function(t){return 0!==e[t]}))){for(i in a)n.o(a,i)&&(n.m[i]=a[i]);if(l)var c=l(n)}for(t&&t(o);m span { - display: none; -} -.ti-om-stack-wrap .om-stack-notice img { - max-width: 90px !important; -} -.ti-om-stack-wrap .om-stack-notice h2 { - font-size: 18px; - margin: 30px auto 10px; - font-weight: 600; -} -.ti-om-stack-wrap .om-stack-notice p { - font-size: 13px; - max-width: 250px; - margin: 0 auto; - line-height: 17px; -} -.ti-om-stack-wrap .om-stack-notice i { - margin-top: 10px; - font-size: 12px; - color: #757575; -} -.ti-om-stack-wrap .om-stack-notice .cta { - margin: 20px auto 0; - padding: 10px 25px !important; -} -.ti-om-stack-wrap .om-stack-notice .om-notice-dismiss { - color: inherit; -} -.ti-om-stack-wrap .om-stack-notice input { - border-radius: 0; -} -.ti-om-stack-wrap .om-stack-notice form { - place-items: center; - width: 75%; - display: grid; - margin-top: 10px; - gap: 10px; -} -.ti-om-stack-wrap .om-stack-notice .done { - margin-top: 15px; - display: grid; - gap: 10px; -} -.ti-om-stack-wrap .om-stack-notice .done p { - font-size: 15px; - font-weight: 500; -} -.ti-om-stack-wrap .om-stack-notice .om-progress { - margin: 20px 0; -} - -.block-editor-block-inspector .ti-om-stack-wrap { - border-top: 1px solid #e0e0e0; -} - -.om-progress { - gap: 5px; - font-size: 14px; - display: flex; - align-items: center; -} -.om-progress .spin { - animation: om-rotation 2s infinite linear; -} - -@keyframes om-rotation { - 0% { - transform: rotate(0deg); - } - 100% { - transform: rotate(359deg); - } -} -.ti-sdk-om-promo.hidden { - display: none; -} - -.media-sidebar .ti-sdk-om-notice input { - min-width: unset; - flex-grow: 1; -} -.media-sidebar .ti-sdk-om-notice .description { - margin-bottom: 10px; -} -.media-sidebar .ti-sdk-om-notice .content { - padding: 15px 10px; -} -.media-sidebar .ti-sdk-om-notice .actions { - gap: 10px; -} -.media-sidebar .ti-sdk-om-notice form { - flex-wrap: wrap; - justify-content: center; -} - -.attachment-info .ti-sdk-om-notice input { - min-width: unset; - flex-grow: 1; -} -.attachment-info .ti-sdk-om-notice form { - flex-wrap: wrap; - justify-content: center; -} - -.ti-sdk-rop-notice { - position: relative; - padding: 10px; -} -.ti-sdk-rop-notice .rop-notice-actions { - display: flex; - gap: 10px; -} -.ti-sdk-rop-notice p { - padding: 0 10px 0 0; -} - -.ti-sdk-neve-fse-notice { - position: relative; - padding: 10px; -} -.ti-sdk-neve-fse-notice .neve-fse-notice-actions { - display: flex; - gap: 10px; -} -.ti-sdk-neve-fse-notice .neve-fse-notice-actions a { - text-decoration: none; -} -.ti-sdk-neve-fse-notice .neve-fse-notice-actions a span:not(.dashicons) { - text-decoration: underline; -} -.ti-sdk-neve-fse-notice p { - padding: 0 10px 0 0; - font-size: 14px; -} -@media screen and (min-width: 768px) { - .ti-sdk-om-notice img { - display: block; - } -} -@media screen and (min-width: 1200px) { - .attachment-info .ti-sdk-om-notice form { - flex-wrap: unset; - } -} - -/*# sourceMappingURL=style-index.css.map*/ \ No newline at end of file +.ti-sdk-om-notice{--wp-admin-theme-color: #3858E9;--wp-admin-theme-color-darker-10: #2e47ba;position:relative;padding:0;border-left-color:#3858e9}.ti-sdk-om-notice .content{background:rgba(255,255,255,.75);display:flex;align-items:center;padding:15px 20px}.ti-sdk-om-notice img{max-width:100px;margin-right:20px;display:none}.ti-sdk-om-notice .description{font-size:14px;margin-bottom:20px;color:#000}.ti-sdk-om-notice .actions{margin-top:auto;display:flex;margin-bottom:0;gap:20px}.ti-sdk-om-notice form{display:flex;align-items:center;gap:10px}.ti-sdk-om-notice .form-wrap{display:grid}.ti-sdk-om-notice .form-wrap span:not(.dashicons){margin-bottom:5px;font-weight:500}.ti-sdk-om-notice input{border-radius:0;min-width:250px}.ti-sdk-om-notice a.components-button{display:flex;align-items:center;justify-content:center}.ti-sdk-om-notice .is-link{text-decoration:none;display:flex;align-items:center}.ti-sdk-om-notice .is-link span{line-height:normal}.ti-sdk-om-notice .dashicons{margin-right:2px;text-decoration:none}.ti-sdk-om-notice .done{display:flex;flex-direction:column;align-items:flex-start}.ti-sdk-om-notice .done a{width:auto}.compat-field-optimole th{display:none !important}.compat-field-optimole td{width:100% !important}.compat-field-optimole .ti-sdk-om-notice{margin:0}.om-notice-dismiss{right:10px;top:10px;text-decoration:none !important;position:absolute}.om-notice-dismiss:before{content:none}.ti-om-stack-wrap .om-stack-notice{--wp-admin-theme-color: #3858E9;--wp-admin-theme-color-darker-10: #2e47ba;display:flex;flex-direction:column;align-items:center;position:relative;text-align:center;padding:20px 10px}.ti-om-stack-wrap .om-stack-notice>span{display:none}.ti-om-stack-wrap .om-stack-notice img{max-width:90px !important}.ti-om-stack-wrap .om-stack-notice h2{font-size:18px;margin:30px auto 10px;font-weight:600}.ti-om-stack-wrap .om-stack-notice p{font-size:13px;max-width:250px;margin:0 auto;line-height:17px}.ti-om-stack-wrap .om-stack-notice i{margin-top:10px;font-size:12px;color:#757575}.ti-om-stack-wrap .om-stack-notice .cta{margin:20px auto 0;padding:10px 25px !important}.ti-om-stack-wrap .om-stack-notice .om-notice-dismiss{color:inherit}.ti-om-stack-wrap .om-stack-notice input{border-radius:0}.ti-om-stack-wrap .om-stack-notice form{place-items:center;width:75%;display:grid;margin-top:10px;gap:10px}.ti-om-stack-wrap .om-stack-notice .done{margin-top:15px;display:grid;gap:10px}.ti-om-stack-wrap .om-stack-notice .done p{font-size:15px;font-weight:500}.ti-om-stack-wrap .om-stack-notice .om-progress{margin:20px 0}.block-editor-block-inspector .ti-om-stack-wrap{border-top:1px solid #e0e0e0}.om-progress{gap:5px;font-size:14px;display:flex;align-items:center}.om-progress .spin{animation:om-rotation 2s infinite linear}@keyframes om-rotation{0%{transform:rotate(0deg)}100%{transform:rotate(359deg)}}.ti-sdk-om-promo.hidden{display:none}.media-sidebar .ti-sdk-om-notice input{min-width:unset;flex-grow:1}.media-sidebar .ti-sdk-om-notice .description{margin-bottom:10px}.media-sidebar .ti-sdk-om-notice .content{padding:15px 10px}.media-sidebar .ti-sdk-om-notice .actions{gap:10px}.media-sidebar .ti-sdk-om-notice form{flex-wrap:wrap;justify-content:center}.attachment-info .ti-sdk-om-notice input{min-width:unset;flex-grow:1}.attachment-info .ti-sdk-om-notice form{flex-wrap:wrap;justify-content:center}.ti-sdk-rop-notice{position:relative;padding:10px}.ti-sdk-rop-notice .rop-notice-actions{display:flex;gap:10px}.ti-sdk-rop-notice p{padding:0 10px 0 0}.ti-sdk-neve-fse-notice{position:relative;padding:10px}.ti-sdk-neve-fse-notice .neve-fse-notice-actions{display:flex;gap:10px}.ti-sdk-neve-fse-notice .neve-fse-notice-actions a{text-decoration:none}.ti-sdk-neve-fse-notice .neve-fse-notice-actions a span:not(.dashicons){text-decoration:underline}.ti-sdk-neve-fse-notice p{padding:0 10px 0 0;font-size:14px}@media screen and (min-width: 768px){.ti-sdk-om-notice img{display:block}}@media screen and (min-width: 1200px){.attachment-info .ti-sdk-om-notice form{flex-wrap:unset}} diff --git a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/tracking/tracking.asset.php b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/tracking/tracking.asset.php new file mode 100644 index 00000000..21387440 --- /dev/null +++ b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/tracking/tracking.asset.php @@ -0,0 +1 @@ + array(), 'version' => 'bacc1f000efc9f479fc0'); diff --git a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/tracking/tracking.js b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/tracking/tracking.js new file mode 100644 index 00000000..6fd91534 --- /dev/null +++ b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/assets/js/build/tracking/tracking.js @@ -0,0 +1 @@ +!function(){var e={705:function(e){e.exports=function e(t,n,r){function o(s,u){if(!n[s]){if(!t[s]){if(i)return i(s,!0);throw new Error("Cannot find module '"+s+"'")}u=n[s]={exports:{}},t[s][0].call(u.exports,(function(e){return o(t[s][1][e]||e)}),u,u.exports,e,t,n,r)}return n[s].exports}for(var i=void 0,s=0;s>16),a((65280&r)>>8),a(255&r);return 2==o?a(255&(r=f(e.charAt(n))<<2|f(e.charAt(n+1))>>4)):1==o&&(a((r=f(e.charAt(n))<<10|f(e.charAt(n+1))<<4|f(e.charAt(n+2))>>2)>>8&255),a(255&r)),i},e.fromByteArray=function(e){var t,n,r,o,i=e.length%3,s="";function u(e){return"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(e)}for(t=0,r=e.length-i;t>18&63)+u(o>>12&63)+u(o>>6&63)+u(63&o);switch(i){case 1:s=(s+=u((n=e[e.length-1])>>2))+u(n<<4&63)+"==";break;case 2:s=(s=(s+=u((n=(e[e.length-2]<<8)+e[e.length-1])>>10))+u(n>>4&63))+u(n<<2&63)+"="}return s}}(void 0===n?this.base64js={}:n)}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/base64-js/lib/b64.js","/node_modules/gulp-browserify/node_modules/base64-js/lib")},{buffer:3,lYpoI2:11}],3:[function(e,t,n){(function(t,r,o,i,s,u,a,f,l){var c=e("base64-js"),d=e("ieee754");function o(e,t,n){if(!(this instanceof o))return new o(e,t,n);var r,i,s,u,a=typeof e;if("base64"===t&&"string"==a)for(e=(u=e).trim?u.trim():u.replace(/^\s+|\s+$/g,"");e.length%4!=0;)e+="=";if("number"==a)r=x(e);else if("string"==a)r=o.byteLength(e,t);else{if("object"!=a)throw new Error("First argument needs to be a number, array or string.");r=x(e.length)}if(o._useTypedArrays?i=o._augment(new Uint8Array(r)):((i=this).length=r,i._isBuffer=!0),o._useTypedArrays&&"number"==typeof e.byteLength)i._set(e);else if(S(u=e)||o.isBuffer(u)||u&&"object"==typeof u&&"number"==typeof u.length)for(s=0;s>>0)):(t+1>>0),o}function g(e,t,n,r){if(r||(Y("boolean"==typeof n,"missing or invalid endian"),Y(null!=t,"missing offset"),Y(t+1>>8*(r?i:1-i)}function m(e,t,n,r,o){if(o||(Y(null!=t,"missing value"),Y("boolean"==typeof r,"missing or invalid endian"),Y(null!=n,"missing offset"),Y(n+3>>8*(r?i:3-i)&255}function _(e,t,n,r,o){o||(Y(null!=t,"missing value"),Y("boolean"==typeof r,"missing or invalid endian"),Y(null!=n,"missing offset"),Y(n+1>8,n%=256,r.push(n),r.push(t);return r}(t),e,n,r)}(this,e,t,n);break;default:throw new Error("Unknown encoding")}return i},o.prototype.toString=function(e,t,n){var r,o,i,s,u=this;if(e=String(e||"utf8").toLowerCase(),t=Number(t)||0,(n=void 0!==n?Number(n):u.length)===t)return"";switch(e){case"hex":r=function(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||rthis.length&&(r=this.length);var i=(r=e.length-t=this.length))return this[e]},o.prototype.readUInt16LE=function(e,t){return h(this,e,!0,t)},o.prototype.readUInt16BE=function(e,t){return h(this,e,!1,t)},o.prototype.readUInt32LE=function(e,t){return p(this,e,!0,t)},o.prototype.readUInt32BE=function(e,t){return p(this,e,!1,t)},o.prototype.readInt8=function(e,t){if(t||(Y(null!=e,"missing offset"),Y(e=this.length))return 128&this[e]?-1*(255-this[e]+1):this[e]},o.prototype.readInt16LE=function(e,t){return g(this,e,!0,t)},o.prototype.readInt16BE=function(e,t){return g(this,e,!1,t)},o.prototype.readInt32LE=function(e,t){return y(this,e,!0,t)},o.prototype.readInt32BE=function(e,t){return y(this,e,!1,t)},o.prototype.readFloatLE=function(e,t){return w(this,e,!0,t)},o.prototype.readFloatBE=function(e,t){return w(this,e,!1,t)},o.prototype.readDoubleLE=function(e,t){return b(this,e,!0,t)},o.prototype.readDoubleBE=function(e,t){return b(this,e,!1,t)},o.prototype.writeUInt8=function(e,t,n){n||(Y(null!=e,"missing value"),Y(null!=t,"missing offset"),Y(t=this.length||(this[t]=e)},o.prototype.writeUInt16LE=function(e,t,n){v(this,e,t,!0,n)},o.prototype.writeUInt16BE=function(e,t,n){v(this,e,t,!1,n)},o.prototype.writeUInt32LE=function(e,t,n){m(this,e,t,!0,n)},o.prototype.writeUInt32BE=function(e,t,n){m(this,e,t,!1,n)},o.prototype.writeInt8=function(e,t,n){n||(Y(null!=e,"missing value"),Y(null!=t,"missing offset"),Y(t=this.length||(0<=e?this.writeUInt8(e,t,n):this.writeUInt8(255+e+1,t,n))},o.prototype.writeInt16LE=function(e,t,n){_(this,e,t,!0,n)},o.prototype.writeInt16BE=function(e,t,n){_(this,e,t,!1,n)},o.prototype.writeInt32LE=function(e,t,n){E(this,e,t,!0,n)},o.prototype.writeInt32BE=function(e,t,n){E(this,e,t,!1,n)},o.prototype.writeFloatLE=function(e,t,n){I(this,e,t,!0,n)},o.prototype.writeFloatBE=function(e,t,n){I(this,e,t,!1,n)},o.prototype.writeDoubleLE=function(e,t,n){A(this,e,t,!0,n)},o.prototype.writeDoubleBE=function(e,t,n){A(this,e,t,!1,n)},o.prototype.fill=function(e,t,n){if(t=t||0,n=n||this.length,Y("number"==typeof(e="string"==typeof(e=e||0)?e.charCodeAt(0):e)&&!isNaN(e),"value is not a number"),Y(t<=n,"end < start"),n!==t&&0!==this.length){Y(0<=t&&t"},o.prototype.toArrayBuffer=function(){if("undefined"==typeof Uint8Array)throw new Error("Buffer.toArrayBuffer not supported in this browser");if(o._useTypedArrays)return new o(this).buffer;for(var e=new Uint8Array(this.length),t=0,n=e.length;t=t.length||o>=e.length);o++)t[o+n]=e[o];return o}function C(e){try{return decodeURIComponent(e)}catch(e){return String.fromCharCode(65533)}}function M(e,t){Y("number"==typeof e,"cannot write a non-number as a number"),Y(0<=e,"specified a negative value for writing an unsigned value"),Y(e<=t,"value is larger than maximum value for type"),Y(Math.floor(e)===e,"value has a fractional component")}function N(e,t,n){Y("number"==typeof e,"cannot write a non-number as a number"),Y(e<=t,"value larger than maximum allowed value"),Y(n<=e,"value smaller than minimum allowed value"),Y(Math.floor(e)===e,"value has a fractional component")}function F(e,t,n){Y("number"==typeof e,"cannot write a non-number as a number"),Y(e<=t,"value larger than maximum allowed value"),Y(n<=e,"value smaller than minimum allowed value")}function Y(e,t){if(!e)throw new Error(t||"Failed assertion")}o._augment=function(e){return e._isBuffer=!0,e._get=e.get,e._set=e.set,e.get=B.get,e.set=B.set,e.write=B.write,e.toString=B.toString,e.toLocaleString=B.toString,e.toJSON=B.toJSON,e.copy=B.copy,e.slice=B.slice,e.readUInt8=B.readUInt8,e.readUInt16LE=B.readUInt16LE,e.readUInt16BE=B.readUInt16BE,e.readUInt32LE=B.readUInt32LE,e.readUInt32BE=B.readUInt32BE,e.readInt8=B.readInt8,e.readInt16LE=B.readInt16LE,e.readInt16BE=B.readInt16BE,e.readInt32LE=B.readInt32LE,e.readInt32BE=B.readInt32BE,e.readFloatLE=B.readFloatLE,e.readFloatBE=B.readFloatBE,e.readDoubleLE=B.readDoubleLE,e.readDoubleBE=B.readDoubleBE,e.writeUInt8=B.writeUInt8,e.writeUInt16LE=B.writeUInt16LE,e.writeUInt16BE=B.writeUInt16BE,e.writeUInt32LE=B.writeUInt32LE,e.writeUInt32BE=B.writeUInt32BE,e.writeInt8=B.writeInt8,e.writeInt16LE=B.writeInt16LE,e.writeInt16BE=B.writeInt16BE,e.writeInt32LE=B.writeInt32LE,e.writeInt32BE=B.writeInt32BE,e.writeFloatLE=B.writeFloatLE,e.writeFloatBE=B.writeFloatBE,e.writeDoubleLE=B.writeDoubleLE,e.writeDoubleBE=B.writeDoubleBE,e.fill=B.fill,e.inspect=B.inspect,e.toArrayBuffer=B.toArrayBuffer,e}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/buffer/index.js","/node_modules/gulp-browserify/node_modules/buffer")},{"base64-js":2,buffer:3,ieee754:10,lYpoI2:11}],4:[function(e,t,n){(function(n,r,o,i,s,u,a,f,l){o=e("buffer").Buffer;var c=new o(4);c.fill(0),t.exports={hash:function(e,t,n,r){for(var i=t(function(e,t){e.length%4!=0&&(n=e.length+(4-e.length%4),e=o.concat([e,c],n));for(var n,r=[],i=t?e.readInt32BE:e.readInt32LE,s=0;sg?t=e(t):t.length>5]|=128<>>9<<4)]=t;for(var n=1732584193,r=-271733879,o=-1732584194,i=271733878,s=0;s>>32-o,n)}function p(e,t,n,r,o,i,s){return h(t&n|~t&r,e,t,o,i,s)}function g(e,t,n,r,o,i,s){return h(t&r|n&~r,e,t,o,i,s)}function y(e,t,n,r,o,i,s){return h(t^n^r,e,t,o,i,s)}function w(e,t,n,r,o,i,s){return h(n^(t|~r),e,t,o,i,s)}function b(e,t){var n=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(n>>16)<<16|65535&n}t.exports=function(e){return c.hash(e,d,16)}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/md5.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:11}],7:[function(e,t,n){(function(e,n,r,o,i,s,u,a,f){t.exports=function(e){for(var t,n=new Array(e),r=0;r>>((3&r)<<3)&255;return n}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/rng.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{buffer:3,lYpoI2:11}],8:[function(e,t,n){(function(n,r,o,i,s,u,a,f,l){var c=e("./helpers");function d(e,t){e[t>>5]|=128<<24-t%32,e[15+(t+64>>9<<4)]=t;for(var n,r,o,i=Array(80),s=1732584193,u=-271733879,a=-1732584194,f=271733878,l=-1009589776,c=0;c>16)+(t>>16)+(n>>16)<<16|65535&n}function p(e,t){return e<>>32-t}t.exports=function(e){return c.hash(e,d,20,!0)}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/sha.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:11}],9:[function(e,t,n){(function(n,r,o,i,s,u,a,f,l){function c(e,t){var n=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(n>>16)<<16|65535&n}function d(e,t){var n,r=new Array(1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298),o=new Array(1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225),i=new Array(64);e[t>>5]|=128<<24-t%32,e[15+(t+64>>9<<4)]=t;for(var s,u,a=0;a>>t|e<<32-t},g=function(e,t){return e>>>t};t.exports=function(e){return h.hash(e,d,32,!0)}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/sha256.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:11}],10:[function(e,t,n){(function(e,t,r,o,i,s,u,a,f){n.read=function(e,t,n,r,o){var i,s,u=8*o-r-1,a=(1<>1,l=-7,c=n?o-1:0,d=n?-1:1;for(o=e[t+c],c+=d,i=o&(1<<-l)-1,o>>=-l,l+=u;0>=-l,l+=r;0>1,c=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,d=r?0:i-1,h=r?1:-1;for(i=t<0||0===t&&1/t<0?1:0,t=Math.abs(t),isNaN(t)||t===1/0?(u=isNaN(t)?1:0,s=f):(s=Math.floor(Math.log(t)/Math.LN2),t*(r=Math.pow(2,-s))<1&&(s--,r*=2),2<=(t+=1<=s+l?c/r:c*Math.pow(2,1-l))*r&&(s++,r/=2),f<=s+l?(u=0,s=f):1<=s+l?(u=(t*r-1)*Math.pow(2,o),s+=l):(u=t*Math.pow(2,l-1)*Math.pow(2,o),s=0));8<=o;e[n+d]=255&u,d+=h,u/=256,o-=8);for(s=s<{var t,n;const r=null==e||null===(t=e.filter((e=>null==e?void 0:e[0])))||void 0===t?void 0:t[0];return null!==(n=null==r?void 0:r[1])&&void 0!==n?n:null==r?void 0:r[0]};class a{constructor(){var t,n;e(this,"_set",((e,t,n)=>{if(!this.hasProduct(t.slug))return;if(!(null!=n&&n.consent||this.getProductConsent(t.slug)))return;if(!this.validate(t))return;const r=null!=n&&n.directSave?t:this.trkMetadata(t);this.events.set(e,r),null!=n&&n.refreshTimer&&this.refreshTimer(),null!=n&&n.sendNow?this.uploadEvents():null!=n&&n.ignoreLimit||this.sendIfLimitReached()})),e(this,"_add",((e,t)=>{const n=s()(e);return this._set(n.toString(),e,t),n.toString()})),e(this,"with",(e=>{const t={slug:e,...this.envInfo()};return{add:(e,n)=>this._add({...t,...e},n),set:(e,n,r)=>this._set(e,{...t,...n},r),base:this}})),e(this,"envInfo",(()=>({site:window.location.hostname}))),e(this,"uploadEvents",(async()=>{if(0!==this.events.size)try{const e=Array.from(this.events.values());this.events.clear();const t=await this.sendBulkTracking(e.map((e=>{let{slug:t,site:n,license:r,...o}=e;return{slug:t,site:n,license:r,data:o}})));t.ok||this.listeners.forEach((e=>e({success:!1,error:"Failed to send tracking events"})));const n=await t.json();this.listeners.forEach((e=>e({success:!0,response:n})))}catch(e){console.error(e)}})),e(this,"sendIfLimitReached",(()=>{if(this.events.size>=this.eventsLimit)return this.uploadEvents()})),e(this,"subscribe",(e=>(this.listeners.push(e),()=>{this.listeners=this.listeners.filter((t=>t!==e))}))),e(this,"hasConsent",(()=>this.consent)),e(this,"sendBulkTracking",(e=>fetch(this.endpoint,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)}))),e(this,"trkMetadata",(e=>({env:u([[window.location.href.includes("customize.php"),"customizer"],[window.location.href.includes("site-editor.php"),"site-editor"],[window.location.href.includes("widgets.php"),"widgets"],[window.location.href.includes("admin.php"),"admin"],["post-editor"]]),license:this.getProductTackHash(e.slug),...null!=e?e:{}}))),e(this,"hasProduct",(e=>this.products.some((t=>{var n;return null==t||null===(n=t.slug)||void 0===n?void 0:n.includes(e)})))),e(this,"getProductTackHash",(e=>{var t;return null===(t=this.products.find((t=>{var n;return null==t||null===(n=t.slug)||void 0===n?void 0:n.includes(e)})))||void 0===t?void 0:t.trackHash})),e(this,"getProductConsent",(e=>{var t;return null===(t=this.products.find((t=>{var n;return null==t||null===(n=t.slug)||void 0===n?void 0:n.includes(e)})))||void 0===t?void 0:t.consent})),e(this,"start",(()=>{this.interval||(this.interval=window.setInterval((()=>{this.uploadEvents()}),this.autoSendIntervalTime))})),e(this,"stop",(()=>{this.interval&&(window.clearInterval(this.interval),this.interval=null)})),e(this,"refreshTimer",(()=>{this.stop(),this.start()})),e(this,"validate",(e=>"object"==typeof e?0!==Object.keys(e).length&&Object.values(e).every(this.validate):void 0!==e)),e(this,"clone",(()=>{const e=new a;return e.events=new Map(this.events),e.listeners=[...this.listeners],e.interval=this.interval,e.consent=this.consent,e.endpoint=this.endpoint,e})),this.events=new Map,this.eventsLimit=50,this.listeners=[],this.interval=null,this.consent=!1,this.endpoint=null===(t=tiTelemetry)||void 0===t?void 0:t.endpoint,this.products=null===(n=tiTelemetry)||void 0===n?void 0:n.products,this.autoSendIntervalTime=3e5}}window.tiTrk=new a,null===(t=window)||void 0===t||null===(r=t.wp)||void 0===r||null===(o=r.customize)||void 0===o||o.bind("save",(()=>{var e,t;null===(e=window)||void 0===e||null===(t=e.tiTrk)||void 0===t||t.uploadEvents()})),window.addEventListener("beforeunload",(async()=>{var e,t;null===(e=window)||void 0===e||null===(t=e.tiTrk)||void 0===t||t.uploadEvents()}))}()}(); \ No newline at end of file diff --git a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/load.php b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/load.php index dbf4404d..3659a105 100644 --- a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/load.php +++ b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/load.php @@ -14,7 +14,7 @@ if ( ! defined( 'ABSPATH' ) ) { return; } // Current SDK version and path. -$themeisle_sdk_version = '3.3.2'; +$themeisle_sdk_version = '3.3.11'; $themeisle_sdk_path = dirname( __FILE__ ); global $themeisle_sdk_max_version; @@ -90,8 +90,8 @@ if ( ! function_exists( 'tsdk_utmify' ) ) { $current_page = isset( $screen->id ) ? $screen->id : ( ( $screen === null ) ? 'non-admin' : $screen ); $current_page = sanitize_key( str_replace( '.php', '', $current_page ) ); } - $location = $location === null ? $current_page : $location; - $content = sanitize_key( + $location = $location === null ? $current_page : $location; + $content = sanitize_key( trim( str_replace( [ @@ -102,22 +102,26 @@ if ( ! function_exists( 'tsdk_utmify' ) ) { '/upgrade', ], '', - $url + $url ), - '/' - ) + '/' + ) ); - return esc_url_raw( + $filter_key = sanitize_key( $content ); + $url_args = [ + 'utm_source' => 'wpadmin', + 'utm_medium' => $location, + 'utm_campaign' => $area, + 'utm_content' => $content, + ]; + $query_arguments = apply_filters( 'tsdk_utmify_' . $filter_key, $url_args, $url ); + $utmify_url = esc_url_raw( add_query_arg( - [ - 'utm_source' => 'wpadmin', - 'utm_medium' => $location, - 'utm_campaign' => $area, - 'utm_content' => $content, - ], - $url - ) + $query_arguments, + $url + ) ); + return apply_filters( 'tsdk_utmify_url_' . $filter_key, $utmify_url, $url ); } add_filter( 'tsdk_utmify', 'tsdk_utmify', 10, 3 ); diff --git a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/About_us.php b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/About_us.php index aa964b13..291ac38a 100644 --- a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/About_us.php +++ b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/About_us.php @@ -175,20 +175,19 @@ class About_Us extends Abstract_Module { private function get_about_localization_data() { $links = isset( $this->about_data['page_menu'] ) ? $this->about_data['page_menu'] : []; $product_pages = isset( $this->about_data['product_pages'] ) ? $this->about_data['product_pages'] : []; - return [ - 'links' => $links, - 'logoUrl' => $this->about_data['logo'], - 'productPages' => $this->get_product_pages_data( $product_pages ), - 'products' => $this->get_other_products_data(), - 'homeUrl' => esc_url( home_url() ), - 'pageSlug' => $this->get_about_page_slug(), - 'currentProduct' => [ + 'links' => $links, + 'logoUrl' => $this->about_data['logo'], + 'productPages' => $this->get_product_pages_data( $product_pages ), + 'products' => $this->get_other_products_data(), + 'homeUrl' => esc_url( home_url() ), + 'pageSlug' => $this->get_about_page_slug(), + 'currentProduct' => [ 'slug' => $this->product->get_key(), 'name' => $this->product->get_name(), ], - 'teamImage' => $this->get_sdk_uri() . 'assets/images/team.jpg', - 'strings' => [ + 'teamImage' => $this->get_sdk_uri() . 'assets/images/team.jpg', + 'strings' => [ 'aboutUs' => __( 'About us', 'textdomain' ), 'heroHeader' => __( 'Our Story', 'textdomain' ), 'heroTextFirst' => __( 'Themeisle was founded in 2012 by a group of passionate developers who wanted to create beautiful and functional WordPress themes and plugins. Since then, we have grown into a team of over 20 dedicated professionals who are committed to delivering the best possible products to our customers.', 'textdomain' ), @@ -204,6 +203,8 @@ class About_Us extends Abstract_Module { 'notInstalled' => __( 'Not Installed', 'textdomain' ), 'active' => __( 'Active', 'textdomain' ), ], + 'canInstallPlugins' => current_user_can( 'install_plugins' ), + 'canActivatePlugins' => current_user_can( 'activate_plugins' ), ]; } @@ -286,8 +287,8 @@ class About_Us extends Abstract_Module { $pages, function ( $page_data, $page_key ) use ( $product_pages ) { return in_array( $page_key, $product_pages, true ) && - isset( $page_data['plugin']['status'] ) && - $page_data['plugin']['status'] === 'not-installed'; + isset( $page_data['plugin']['status'] ) && + $page_data['plugin']['status'] === 'not-installed'; }, ARRAY_FILTER_USE_BOTH ); @@ -345,8 +346,8 @@ class About_Us extends Abstract_Module { 'condition' => class_exists( 'WooCommerce', false ), ], 'templates-patterns-collection' => [ - 'name' => 'Template Cloud', - 'description' => __( 'Ultimate Free Templates Cloud for WordPress, for blocks, patters of full pages.', 'textdomain' ), + 'name' => 'Templates Cloud', + 'description' => __( 'Design, save, and revisit your templates anytime with your personal vault on Templates Cloud.', 'textdomain' ), ], ]; diff --git a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Dashboard_widget.php b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Dashboard_widget.php index 33eb9ccb..89eb28ce 100644 --- a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Dashboard_widget.php +++ b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Dashboard_widget.php @@ -313,8 +313,35 @@ class Dashboard_Widget extends Abstract_Module { */ private function setup_feeds() { if ( false === ( $items_normalized = get_transient( 'themeisle_sdk_feed_items' ) ) ) { //phpcs:ignore Squiz.PHP.DisallowMultipleAssignments.FoundInControlStructure + // Do not force the feed for the items in the sdk feeds list. + // this prevents showing notices if another plugin will force all SimplePie feeds to load, instead it will + // use the regular SimplePie validation and abort early if the feed is not valid. + $sdk_feeds = $this->feeds; + add_action( + 'wp_feed_options', + function ( $feed, $url ) use ( $sdk_feeds ) { + if ( defined( 'TI_SDK_PHPUNIT' ) && true === TI_SDK_PHPUNIT ) { + return; + } + + if ( ! is_string( $url ) && in_array( $url, $sdk_feeds, true ) ) { + $feed->force_feed( false ); + return; + } + if ( is_array( $url ) ) { + foreach ( $url as $feed_url ) { + if ( in_array( $feed_url, $sdk_feeds, true ) ) { + $feed->force_feed( false ); + return; + } + } + } + }, + PHP_INT_MAX, + 2 + ); // Load SimplePie Instance. - $feed = fetch_feed( $this->feeds ); + $feed = fetch_feed( $sdk_feeds ); // TODO report error when is an error loading the feed. if ( is_wp_error( $feed ) ) { return; @@ -322,6 +349,9 @@ class Dashboard_Widget extends Abstract_Module { $items = $feed->get_items( 0, 5 ); $items = is_array( $items ) ? $items : []; + + $items_normalized = []; + foreach ( $items as $item ) { $items_normalized[] = array( 'title' => $item->get_title(), diff --git a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Licenser.php b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Licenser.php index 72a91d66..d5ed07d4 100644 --- a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Licenser.php +++ b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Licenser.php @@ -264,6 +264,23 @@ class Licenser extends Abstract_Module { return isset( $license_data->license ) ? $license_data : false; } + /** + * Get license hash. + * + * @param string $key Product key. + * + * @return bool|string + */ + public static function create_license_hash( $key ) { + $data = self::get_license_data( $key ); + + if ( ! $data ) { + return false; + } + + return isset( $data->key ) ? wp_hash( $data->key ) : false; + } + /** * Check if license is valid. * diff --git a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Logger.php b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Logger.php index f9442a09..5d05968f 100644 --- a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Logger.php +++ b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Logger.php @@ -29,6 +29,11 @@ class Logger extends Abstract_Module { */ const TRACKING_ENDPOINT = 'https://api.themeisle.com/tracking/log'; + /** + * Endpoint where to collect telemetry. + */ + const TELEMETRY_ENDPOINT = 'https://api.themeisle.com/tracking/events'; + /** * Check if we should load the module for this product. @@ -38,7 +43,6 @@ class Logger extends Abstract_Module { * @return bool Should we load ? */ public function can_load( $product ) { - return apply_filters( $product->get_slug() . '_sdk_enable_logger', true ); } @@ -53,7 +57,6 @@ class Logger extends Abstract_Module { $this->product = $product; $this->setup_notification(); $this->setup_actions(); - return $this; } @@ -76,12 +79,18 @@ class Logger extends Abstract_Module { if ( ! $this->is_logger_active() ) { return; } + + $can_load_telemetry = apply_filters( 'themeisle_sdk_enable_telemetry', false ); + + if ( $can_load_telemetry ) { + add_action( 'admin_enqueue_scripts', array( $this, 'load_telemetry' ) ); + } + $action_key = $this->product->get_key() . '_log_activity'; if ( ! wp_next_scheduled( $action_key ) ) { wp_schedule_single_event( time() + ( wp_rand( 1, 24 ) * 3600 ), $action_key ); } add_action( $action_key, array( $this, 'send_log' ) ); - } /** @@ -176,4 +185,101 @@ class Logger extends Abstract_Module { ) ); } + + /** + * Load telemetry. + * + * @return void + */ + public function load_telemetry() { + // See which products have telemetry enabled. + try { + $products_with_telemetry = array(); + $all_products = Loader::get_products(); + $all_products[ $this->product->get_slug() ] = $this->product; // Add current product to the list of products to check for telemetry. + + foreach ( $all_products as $product_slug => $product ) { + + // Ignore pro products. + if ( false !== strstr( $product_slug, 'pro' ) ) { + continue; + } + + $default = 'no'; + + if ( ! $product->is_wordpress_available() ) { + $default = 'yes'; + } else { + $pro_slug = $product->get_pro_slug(); + + if ( ! empty( $pro_slug ) && isset( $all_products[ $pro_slug ] ) ) { + $default = 'yes'; + } + } + + if ( 'yes' === get_option( $product->get_key() . '_logger_flag', $default ) ) { + + $main_slug = explode( '-', $product_slug ); + $main_slug = $main_slug[0]; + $pro_slug = $product->get_pro_slug(); + $track_hash = Licenser::create_license_hash( str_replace( '-', '_', ! empty( $pro_slug ) ? $pro_slug : $product_slug ) ); + + // Check if product was already tracked. + $active_telemetry = false; + foreach ( $products_with_telemetry as &$product_with_telemetry ) { + if ( $product_with_telemetry['slug'] === $main_slug ) { + $active_telemetry = true; + break; + } + } + + if ( $active_telemetry ) { + continue; + } + + $products_with_telemetry[] = array( + 'slug' => $main_slug, + 'trackHash' => $track_hash ? $track_hash : 'free', + 'consent' => true, + ); + } + } + + $products_with_telemetry = apply_filters( 'themeisle_sdk_telemetry_products', $products_with_telemetry ); + + if ( 0 === count( $products_with_telemetry ) ) { + return; + } + + global $themeisle_sdk_max_path; + $asset_file = require $themeisle_sdk_max_path . '/assets/js/build/tracking/tracking.asset.php'; + + wp_enqueue_script( + 'themeisle_sdk_telemetry_script', + $this->get_sdk_uri() . 'assets/js/build/tracking/tracking.js', + $asset_file['dependencies'], + $asset_file['version'], + true + ); + + wp_localize_script( + 'themeisle_sdk_telemetry_script', + 'tiTelemetry', + array( + 'products' => $products_with_telemetry, + 'endpoint' => self::TELEMETRY_ENDPOINT, + ) + ); + } catch ( \Exception $e ) { + if ( defined( 'WP_DEBUG' ) && WP_DEBUG && defined( 'WP_DEBUG_LOG' ) && WP_DEBUG_LOG ) { + error_log( $e->getMessage() ); // phpcs:ignore + } + } catch ( \Error $e ) { + if ( defined( 'WP_DEBUG' ) && WP_DEBUG && defined( 'WP_DEBUG_LOG' ) && WP_DEBUG_LOG ) { + error_log( $e->getMessage() ); // phpcs:ignore + } + } finally { + return; + } + } } diff --git a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Promotions.php b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Promotions.php index cdb5000b..137e9b7e 100644 --- a/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Promotions.php +++ b/wp-content/plugins/menu-icons/vendor/codeinwp/themeisle-sdk/src/Modules/Promotions.php @@ -159,7 +159,6 @@ class Promotions extends Abstract_Module { */ public function load_available() { $this->promotions = $this->filter_by_screen_and_merge(); - if ( empty( $this->promotions ) ) { return; } @@ -268,6 +267,22 @@ class Promotions extends Abstract_Module { return false; } + /** + * Third-party compatibility. + * + * @return boolean + */ + private function has_conflicts() { + global $pagenow; + + // Editor notices aren't compatible with Enfold theme. + if ( defined( 'AV_FRAMEWORK_VERSION' ) && in_array( $pagenow, array( 'post.php', 'post-new.php' ) ) ) { + return true; + } + + return false; + } + /** * Get promotions. * @@ -285,6 +300,8 @@ class Promotions extends Abstract_Module { $has_ppom = defined( 'PPOM_VERSION' ) || $this->is_plugin_installed( 'woocommerce-product-addon' ); $is_min_req_v = version_compare( get_bloginfo( 'version' ), '5.8', '>=' ); $is_min_fse_v = version_compare( get_bloginfo( 'version' ), '6.2', '>=' ); + $current_theme = wp_get_theme(); + $has_neve_fse = $current_theme->template === 'neve-fse' || $current_theme->parent() === 'neve-fse'; $has_enough_attachments = $this->has_min_media_attachments(); $has_enough_old_posts = $this->has_old_posts(); @@ -351,7 +368,7 @@ class Promotions extends Abstract_Module { ], 'neve-fse' => [ 'neve-fse-themes-popular' => [ - 'env' => $is_min_fse_v, + 'env' => ! $has_neve_fse && $is_min_fse_v, 'screen' => 'themes-install-popular', ], ], @@ -359,7 +376,7 @@ class Promotions extends Abstract_Module { foreach ( $all as $slug => $data ) { foreach ( $data as $key => $conditions ) { - if ( ! $conditions['env'] ) { + if ( ! $conditions['env'] || $this->has_conflicts() ) { unset( $all[ $slug ][ $key ] ); continue; @@ -530,6 +547,12 @@ class Promotions extends Abstract_Module { $this->load_woo_promos(); break; case 'neve-fse-themes-popular': + // Remove any other notifications if Neve FSE promotion is showing + remove_action( 'admin_notices', array( 'ThemeisleSDK\Modules\Notification', 'show_notification' ) ); + remove_action( 'wp_ajax_themeisle_sdk_dismiss_notice', array( 'ThemeisleSDK\Modules\Notification', 'dismiss' ) ); + remove_action( 'admin_head', array( 'ThemeisleSDK\Modules\Notification', 'dismiss_get' ) ); + remove_action( 'admin_head', array( 'ThemeisleSDK\Modules\Notification', 'setup_notifications' ) ); + // Add required actions to display this notification add_action( 'admin_enqueue_scripts', [ $this, 'enqueue' ] ); add_action( 'admin_notices', [ $this, 'render_neve_fse_themes_notice' ] ); break; @@ -784,7 +807,7 @@ class Promotions extends Abstract_Module { ); return $tabs; - } + } ); add_action( 'woocommerce_product_data_panels', array( $this, 'woocommerce_tab_content' ) ); @@ -800,7 +823,7 @@ class Promotions extends Abstract_Module { function( $key ) { return in_array( $key, $this->promotions, true ); }, - ARRAY_FILTER_USE_KEY + ARRAY_FILTER_USE_KEY ); // Display CSS diff --git a/wp-content/plugins/menu-icons/vendor/composer/autoload_real.php b/wp-content/plugins/menu-icons/vendor/composer/autoload_real.php index 3dca5351..f460979c 100644 --- a/wp-content/plugins/menu-icons/vendor/composer/autoload_real.php +++ b/wp-content/plugins/menu-icons/vendor/composer/autoload_real.php @@ -2,7 +2,7 @@ // autoload_real.php @generated by Composer -class ComposerAutoloaderInit2df3d2da63bd22bca27c5f9e05dba454 +class ComposerAutoloaderInite0e064cdd82a4be104872380c8a68791 { private static $loader; @@ -22,16 +22,16 @@ class ComposerAutoloaderInit2df3d2da63bd22bca27c5f9e05dba454 return self::$loader; } - spl_autoload_register(array('ComposerAutoloaderInit2df3d2da63bd22bca27c5f9e05dba454', 'loadClassLoader'), true, true); + spl_autoload_register(array('ComposerAutoloaderInite0e064cdd82a4be104872380c8a68791', 'loadClassLoader'), true, true); self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__)); - spl_autoload_unregister(array('ComposerAutoloaderInit2df3d2da63bd22bca27c5f9e05dba454', 'loadClassLoader')); + spl_autoload_unregister(array('ComposerAutoloaderInite0e064cdd82a4be104872380c8a68791', 'loadClassLoader')); require __DIR__ . '/autoload_static.php'; - call_user_func(\Composer\Autoload\ComposerStaticInit2df3d2da63bd22bca27c5f9e05dba454::getInitializer($loader)); + call_user_func(\Composer\Autoload\ComposerStaticInite0e064cdd82a4be104872380c8a68791::getInitializer($loader)); $loader->register(true); - $filesToLoad = \Composer\Autoload\ComposerStaticInit2df3d2da63bd22bca27c5f9e05dba454::$files; + $filesToLoad = \Composer\Autoload\ComposerStaticInite0e064cdd82a4be104872380c8a68791::$files; $requireFile = \Closure::bind(static function ($fileIdentifier, $file) { if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true; diff --git a/wp-content/plugins/menu-icons/vendor/composer/autoload_static.php b/wp-content/plugins/menu-icons/vendor/composer/autoload_static.php index 1091147d..9d5c6d92 100644 --- a/wp-content/plugins/menu-icons/vendor/composer/autoload_static.php +++ b/wp-content/plugins/menu-icons/vendor/composer/autoload_static.php @@ -4,7 +4,7 @@ namespace Composer\Autoload; -class ComposerStaticInit2df3d2da63bd22bca27c5f9e05dba454 +class ComposerStaticInite0e064cdd82a4be104872380c8a68791 { public static $files = array ( '2c2d2fe92db4cd03403dbb108ac263b7' => __DIR__ . '/..' . '/codeinwp/gutenberg-menu-icons/load.php', @@ -20,7 +20,7 @@ class ComposerStaticInit2df3d2da63bd22bca27c5f9e05dba454 public static function getInitializer(ClassLoader $loader) { return \Closure::bind(function () use ($loader) { - $loader->classMap = ComposerStaticInit2df3d2da63bd22bca27c5f9e05dba454::$classMap; + $loader->classMap = ComposerStaticInite0e064cdd82a4be104872380c8a68791::$classMap; }, null, ClassLoader::class); } diff --git a/wp-content/plugins/menu-icons/vendor/composer/installed.json b/wp-content/plugins/menu-icons/vendor/composer/installed.json index 38955eb3..569ae7b1 100644 --- a/wp-content/plugins/menu-icons/vendor/composer/installed.json +++ b/wp-content/plugins/menu-icons/vendor/composer/installed.json @@ -128,23 +128,23 @@ }, { "name": "codeinwp/themeisle-sdk", - "version": "3.3.2", - "version_normalized": "3.3.2.0", + "version": "3.3.11", + "version_normalized": "3.3.11.0", "source": { "type": "git", "url": "https://github.com/Codeinwp/themeisle-sdk.git", - "reference": "b799403bec877749ee0a2916dc859366d62bd76c" + "reference": "583c474d8b5a8d12592f4a78ab8fa335aaf42fc0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Codeinwp/themeisle-sdk/zipball/b799403bec877749ee0a2916dc859366d62bd76c", - "reference": "b799403bec877749ee0a2916dc859366d62bd76c", + "url": "https://api.github.com/repos/Codeinwp/themeisle-sdk/zipball/583c474d8b5a8d12592f4a78ab8fa335aaf42fc0", + "reference": "583c474d8b5a8d12592f4a78ab8fa335aaf42fc0", "shasum": "" }, "require-dev": { "codeinwp/phpcs-ruleset": "dev-main" }, - "time": "2023-08-02T13:04:20+00:00", + "time": "2023-12-12T10:06:27+00:00", "type": "library", "installation-source": "dist", "notification-url": "https://packagist.org/downloads/", diff --git a/wp-content/plugins/menu-icons/vendor/composer/installed.php b/wp-content/plugins/menu-icons/vendor/composer/installed.php index d354cb80..4848d0c6 100644 --- a/wp-content/plugins/menu-icons/vendor/composer/installed.php +++ b/wp-content/plugins/menu-icons/vendor/composer/installed.php @@ -1,9 +1,9 @@ array( 'name' => 'codeinwp/wp-menu-icons', - 'pretty_version' => 'v0.13.7', - 'version' => '0.13.7.0', - 'reference' => 'd7c7cb963c564590d2c233714b80e6b0547bd5bd', + 'pretty_version' => 'v0.13.8', + 'version' => '0.13.8.0', + 'reference' => '3d0f5fe65015775d09b4cd6d7db74aa0367430da', 'type' => 'wordpress-plugin', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), @@ -38,18 +38,18 @@ 'dev_requirement' => false, ), 'codeinwp/themeisle-sdk' => array( - 'pretty_version' => '3.3.2', - 'version' => '3.3.2.0', - 'reference' => 'b799403bec877749ee0a2916dc859366d62bd76c', + 'pretty_version' => '3.3.11', + 'version' => '3.3.11.0', + 'reference' => '583c474d8b5a8d12592f4a78ab8fa335aaf42fc0', 'type' => 'library', 'install_path' => __DIR__ . '/../codeinwp/themeisle-sdk', 'aliases' => array(), 'dev_requirement' => false, ), 'codeinwp/wp-menu-icons' => array( - 'pretty_version' => 'v0.13.7', - 'version' => '0.13.7.0', - 'reference' => 'd7c7cb963c564590d2c233714b80e6b0547bd5bd', + 'pretty_version' => 'v0.13.8', + 'version' => '0.13.8.0', + 'reference' => '3d0f5fe65015775d09b4cd6d7db74aa0367430da', 'type' => 'wordpress-plugin', 'install_path' => __DIR__ . '/../../', 'aliases' => array(),