Popups for Divi - Version 2.2.2

Version Description

  • Improve: Images inside Areas are instantly loaded in Chrome (fixed a lazy-load bug).
  • Improved: New logic to calculate Area size and position that supports orientation-change of mobile devices.
  • Fix: WooCommerce pages now display all available Popups, not only the first one.
  • Fix: Added support for IE 11.
  • Fix: Popup text is no longer blurry in Windows browsers
  • Change: New JS API function to identify an Area: DiviAreaItem.hasId()
  • Change: Deprecated the "full-width" class, because it's not used anymore

Plugin tested with WordPress 5.5.6 and Divi 4.6.5

Download this release

Release Info

Developer stracker.phil
Plugin Icon 128x128 Popups for Divi
Version 2.2.2
Comparing to
See all releases

Code changes from version 2.2.1 to 2.2.2

css/builder.css CHANGED
@@ -1 +1 @@
1
- .popup{display:none;box-shadow:0 3px 10px -1px rgba(0,0,0,.3),0 0 20px 2px rgba(0,0,0,.2);min-width:360px;max-width:95%}#et-fb-app .et_pb_section.popup{display:block;background-color:#fff;margin:30px auto;overflow:visible;z-index:auto}#et-fb-app .et_pb_section.popup+.et_pb_section.popup{margin-top:60px}#et-fb-app .et_pb_section.popup:after{content:"";position:absolute;background:#ccc;background:#fff repeating-linear-gradient(315deg,rgba(0,0,0,.03),rgba(0,0,0,.03) 10px,rgba(0,0,0,.06) 0,rgba(0,0,0,.06) 20px);left:50%;width:100vw;top:-30px;bottom:-30px;z-index:-1;margin:0 0 0 -50vw;background-attachment:fixed}#et-fb-app .et_pb_section.popup:before{content:"#" attr(id);position:absolute;top:0;left:50%;-webkit-transform:translate(-50%,-100%);transform:translate(-50%,-100%);background:#666;padding:0 8px;color:#fff;font-size:12px;line-height:26px;font-weight:700;opacity:.5;transition:all .3s;bottom:auto;right:auto;z-index:20;border-radius:3px 3px 0 0}#et-fb-app .et_pb_section.popup:hover:before{background:#2b87da;opacity:1}.et_fb_hidden_header #et-fb-app .et_pb_section.popup:after{width:100vw}
1
+ .popup{display:none;box-shadow:0 3px 10px -1px rgba(0,0,0,.3),0 0 20px 2px rgba(0,0,0,.2);min-width:360px;max-width:95%}#et-fb-app .et_pb_section.popup{display:block;background-color:#fff;margin:30px auto;overflow:visible;z-index:auto}#et-fb-app .et_pb_section.popup+.et_pb_section.popup{margin-top:60px}#et-fb-app .et_pb_section.popup:after{content:"";position:absolute;background:#ccc;background:#fff repeating-linear-gradient(315deg,rgba(0,0,0,.03),rgba(0,0,0,.03) 10px,rgba(0,0,0,.06) 0,rgba(0,0,0,.06) 20px);left:50%;width:100vw;top:-30px;bottom:-30px;z-index:-1;margin:0 0 0 -50vw;background-attachment:fixed}#et-fb-app .et_pb_section.popup:before{content:"#" attr(id);position:absolute;top:0;left:50%;transform:translate(-50%,-100%);background:#666;padding:0 8px;color:#fff;font-size:12px;line-height:26px;font-weight:700;opacity:.5;transition:all .3s;bottom:auto;right:auto;z-index:20;border-radius:3px 3px 0 0}#et-fb-app .et_pb_section.popup:hover:before{background:#2b87da;opacity:1}.et_fb_hidden_header #et-fb-app .et_pb_section.popup:after{width:100vw}html.et-bfb-html.et-fb-preview--desktop>body.single-divi-area.et-bfb:not(.wp-admin) #et_pb_root>.et-fb-post-content,html.et-bfb-html.et-fb-preview--phone>body.single-divi-area.et-bfb:not(.wp-admin) #et_pb_root>.et-fb-post-content,html.et-bfb-html.et-fb-preview--tablet>body.single-divi-area.et-bfb:not(.wp-admin) #et_pb_root>.et-fb-post-content,html.et-bfb-html.et-fb-preview--zoom>body.single-divi-area.et-bfb:not(.wp-admin) #et_pb_root>.et-fb-post-content{background:hsla(0,0%,100%,.6);box-shadow:0 5px 12px rgba(43,135,218,.2);margin-left:10px;margin-right:10px;margin-top:10px}.et-bfb-html .single-divi-area{background:none!important}.et-fb-post-content{position:relative}.et-fb-post-content>.da-close{position:absolute;right:0;top:0;display:block;box-sizing:content-box;width:30px;height:30px;line-height:30px;text-decoration:none;text-align:center;font-family:Courier New,monospace;font-size:20px;font-weight:700;cursor:pointer;opacity:.7;transition:all .3s;pointer-events:all;z-index:100}.et-fb-post-content>.da-close:active,.et-fb-post-content>.da-close:focus,.et-fb-post-content>.da-close:hover{opacity:1;transform:scale(1.1)}.et-fb-post-content[data-da-color=light]>.da-close{color:#333;background:hsla(0,0%,100%,.13);box-shadow:0 0 3px 1px rgba(0,0,0,.03)}.et-fb-post-content[data-da-color=light]>.da-close:active,.et-fb-post-content[data-da-color=light]>.da-close:focus,.et-fb-post-content[data-da-color=light]>.da-close:hover{color:#000;background:#fff;box-shadow:0 0 4px 0 rgba(0,0,0,.13),0 0 3px 1px rgba(0,0,0,.07)}.et-fb-post-content[data-da-color=dark]>.da-close{color:#eee;background:rgba(0,0,0,.13);box-shadow:0 0 0 1px hsla(0,0%,100%,.03);text-shadow:0 0 1px #000,0 0 3px rgba(0,0,0,.67)}.et-fb-post-content[data-da-color=dark]>.da-close:active,.et-fb-post-content[data-da-color=dark]>.da-close:focus,.et-fb-post-content[data-da-color=dark]>.da-close:hover{color:#fff;background:#2b2b2b;box-shadow:0 0 1px 1px hsla(0,0%,100%,.2)}.et-fb-post-content[data-da-close-bg=none]>.da-close,.et-fb-post-content[data-da-close-bg=none]>.da-close:active,.et-fb-post-content[data-da-close-bg=none]>.da-close:focus,.et-fb-post-content[data-da-close-bg=none]>.da-close:hover{box-shadow:none;background:transparent}.et-fb-preview--wireframe .et-fb-post-content>.da-close{display:none!important}
css/front.css CHANGED
@@ -1 +1 @@
1
- #et-boc .area-outer-wrap{position:fixed;z-index:100;pointer-events:none;max-width:100vw;max-height:100vh}#et-boc .area-outer-wrap.entry-content{padding:0}#et-boc .area-outer-wrap[data-da-type=popup]{min-width:320px;padding:10px}@media screen and (min-width:981px){#et-boc .area-outer-wrap[data-da-type=popup]{width:90%}}@media screen and (max-width:980px){#et-boc .area-outer-wrap[data-da-type=popup]{width:calc(100% - 20px)}}#et-boc .area-outer-wrap[data-da-type=inline]{position:relative;top:unset;bottom:unset;left:unset;right:unset;width:unset;height:unset;-webkit-transform:unset;transform:unset;max-width:unset;max-height:unset}#et-boc .area-outer-wrap>[data-da-area]{position:relative;background-repeat:no-repeat;background-position:50%;margin:auto;pointer-events:all;overflow:auto;-ms-scroll-chaining:none;overscroll-behavior:contain}#et-boc .area-outer-wrap>[data-da-area] .clearfix:after,#et-boc .area-outer-wrap>[data-da-area] .et_pb_row:after,#et-boc .area-outer-wrap>[data-da-area] .et_pb_row_inner:after,#et-boc .area-outer-wrap>[data-da-area] .et_pb_slides:after{content:""}#et-boc .area-outer-wrap>[data-da-area] .et_pb_contact_select{-moz-appearance:textfield}#et-boc .area-outer-wrap[data-da-positionv=top]{top:0}#et-boc .area-outer-wrap[data-da-positionv=top][data-da-type=hover][data-da-positionh=center]{-webkit-transform:translate(-50%,-100%);transform:translate(-50%,-100%)}#et-boc .area-outer-wrap[data-da-positionv=center]{top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%)}#et-boc .area-outer-wrap[data-da-positionv=center][data-da-type=hover][data-da-positionh=left]{-webkit-transform:translate(-100%,-50%);transform:translate(-100%,-50%)}#et-boc .area-outer-wrap[data-da-positionv=bottom]{bottom:0}#et-boc .area-outer-wrap[data-da-positionh=left]{left:0;width:auto}#et-boc .area-outer-wrap[data-da-positionh=center]{left:50%;-webkit-transform:translateX(-50%);transform:translateX(-50%)}#et-boc .area-outer-wrap[data-da-positionh=right]{right:0;width:auto}#et-boc .area-outer-wrap[data-da-position=center-center]{-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%)}#et-boc .area-outer-wrap[data-da-type=popup].full-width{width:auto;left:0;right:0;-webkit-transform:none;transform:none}#et-boc .area-outer-wrap[data-da-type=popup].full-width[data-da-positionv=center]{-webkit-transform:translateY(-50%);transform:translateY(-50%)}#et-boc .area-outer-wrap[data-da-type=popup].full-width [data-da-area]{max-width:100%}#et-boc .area-outer-wrap[data-da-type=popup].full-height{height:auto;top:0;bottom:0;-webkit-transform:none;transform:none}#et-boc .area-outer-wrap[data-da-type=popup].full-height[data-da-positionh=center]{-webkit-transform:translateX(-50%);transform:translateX(-50%)}#et-boc .area-outer-wrap[data-da-type=popup].full-height [data-da-area]{max-height:100%}#et-boc .area-outer-wrap[data-da-type=popup].full-width.full-height{-webkit-transform:none;transform:none}#et-boc .area-outer-wrap .da-close-wrap{display:block;position:absolute;left:50%;top:50%;z-index:100;text-align:right;transition:opacity .6s .3s;overflow:visible;pointer-events:none;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%)}#et-boc .area-outer-wrap .da-close{position:absolute;right:0;top:0;display:block;box-sizing:content-box;width:30px;height:30px;line-height:30px;text-decoration:none;text-align:center;font-family:Courier New,monospace;font-size:20px;font-weight:700;cursor:pointer;opacity:.7;transition:all .3s;pointer-events:all}#et-boc .area-outer-wrap .da-close:active,#et-boc .area-outer-wrap .da-close:focus,#et-boc .area-outer-wrap .da-close:hover{opacity:1;-webkit-transform:scale(1.1);transform:scale(1.1)}#et-boc .area-outer-wrap[data-da-close-btn=no] .da-close-wrap{display:none!important}#et-boc .area-outer-wrap[data-da-close-btn=yes] .da-close-wrap{display:block}#et-boc .area-outer-wrap[data-da-color=light] .da-close{color:#333;background:hsla(0,0%,100%,.13);box-shadow:0 0 3px 1px rgba(0,0,0,.03)}#et-boc .area-outer-wrap[data-da-color=light] .da-close:active,#et-boc .area-outer-wrap[data-da-color=light] .da-close:focus,#et-boc .area-outer-wrap[data-da-color=light] .da-close:hover{color:#000;background:#fff;box-shadow:0 0 4px 0 rgba(0,0,0,.13),0 0 3px 1px rgba(0,0,0,.07)}#et-boc .area-outer-wrap[data-da-color=dark] .da-close{color:#eee;background:rgba(0,0,0,.13);box-shadow:0 0 0 1px hsla(0,0%,100%,.03);text-shadow:0 0 1px #000,0 0 3px rgba(0,0,0,.67)}#et-boc .area-outer-wrap[data-da-color=dark] .da-close:active,#et-boc .area-outer-wrap[data-da-color=dark] .da-close:focus,#et-boc .area-outer-wrap[data-da-color=dark] .da-close:hover{color:#fff;background:#2b2b2b;box-shadow:0 0 1px 1px hsla(0,0%,100%,.2)}#et-boc .area-outer-wrap[data-da-close-bg=none] .da-close,#et-boc .area-outer-wrap[data-da-close-bg=none] .da-close:active,#et-boc .area-outer-wrap[data-da-close-bg=none] .da-close:focus,#et-boc .area-outer-wrap[data-da-close-bg=none] .da-close:hover{box-shadow:none;background:transparent}#et-boc .area-outer-wrap[data-da-loader=yes] [data-da-area]{background-image:url(../img/spin.gif),radial-gradient(circle at center,#fff 65%,hsla(0,0%,100%,0) 66%)!important;background-size:32px 32px,48px 48px}#et-boc .area-outer-wrap[data-da-shadow=yes] [data-da-area]{box-shadow:0 3px 10px -1px rgba(0,0,0,.3),0 2px 50px 2px rgba(0,0,0,.2)}#et-boc .area-outer-wrap[data-da-shadow=no] [data-da-area]{box-shadow:none}.area-outer-wrap [data-da-area]{display:block;pointer-events:all}.da-overlay{position:fixed;left:0;top:0;right:0;bottom:0;background:rgba(0,0,0,.55);z-index:99;transition:-webkit-backdrop-filter 1s 1s;transition:backdrop-filter 1s 1s;transition:backdrop-filter 1s 1s,-webkit-backdrop-filter 1s 1s;-webkit-backdrop-filter:none;backdrop-filter:none}.da-overlay-visible .da-overlay{-webkit-backdrop-filter:saturate(180%) blur(5px);backdrop-filter:saturate(180%) blur(5px)}[data-area-hook]{display:none!important;visibility:hidden!important}
1
+ [class*=et_pb_section_dap_]{width:100%}#et-boc .area-outer-wrap{position:fixed;z-index:100;pointer-events:none;max-width:100vw;max-height:100vh}#et-boc .area-outer-wrap.entry-content{padding:0}#et-boc .area-outer-wrap[data-da-type=popup]{min-width:320px;padding:10px}@media screen and (min-width:981px){#et-boc .area-outer-wrap[data-da-type=popup]{width:90%}}@media screen and (max-width:980px){#et-boc .area-outer-wrap[data-da-type=popup]{width:100%}}#et-boc .area-outer-wrap[data-da-type=inline]{position:relative;top:unset;bottom:unset;left:unset;right:unset;width:unset;height:unset;transform:unset;max-width:unset;max-height:unset}#et-boc .area-outer-wrap>[data-da-area]{position:relative;background-repeat:no-repeat;background-position:50%;margin:auto;pointer-events:all;overflow:auto;-ms-scroll-chaining:none;overscroll-behavior:contain;height:100%;display:flex!important;flex-direction:column}#et-boc .area-outer-wrap>[data-da-area]>.et_pb_section{flex:1 0 auto}#et-boc .area-outer-wrap>[data-da-area] .clearfix:after,#et-boc .area-outer-wrap>[data-da-area] .et_pb_row:after,#et-boc .area-outer-wrap>[data-da-area] .et_pb_row_inner:after,#et-boc .area-outer-wrap>[data-da-area] .et_pb_slides:after{content:""}#et-boc .area-outer-wrap>[data-da-area] .et_pb_contact_select{-moz-appearance:textfield}#et-boc .area-outer-wrap[data-da-type=popup].full-height{height:auto!important;top:0!important;bottom:0!important;margin-top:0!important}#et-boc .area-outer-wrap[data-da-type=popup].full-height [data-da-area]{max-height:100%}#et-boc .area-outer-wrap .da-close-wrap{display:block;position:absolute;left:50%;top:50%;z-index:100;text-align:right;transition:opacity .6s .3s;overflow:visible;pointer-events:none;transform:translate(-50%,-50%)}#et-boc .area-outer-wrap .da-close{position:absolute;right:0;top:0;display:block;box-sizing:content-box;width:30px;height:30px;line-height:30px;text-decoration:none;text-align:center;font-family:Courier New,monospace;font-size:20px;font-weight:700;cursor:pointer;opacity:.7;transition:all .3s;pointer-events:all}#et-boc .area-outer-wrap .da-close:active,#et-boc .area-outer-wrap .da-close:focus,#et-boc .area-outer-wrap .da-close:hover{opacity:1;transform:scale(1.1)}#et-boc .area-outer-wrap[data-da-close-btn=no] .da-close-wrap{display:none!important}#et-boc .area-outer-wrap[data-da-close-btn=yes] .da-close-wrap{display:block}#et-boc .area-outer-wrap[data-da-color=light] .da-close{color:#333;background:hsla(0,0%,100%,.13);box-shadow:0 0 3px 1px rgba(0,0,0,.03)}#et-boc .area-outer-wrap[data-da-color=light] .da-close:active,#et-boc .area-outer-wrap[data-da-color=light] .da-close:focus,#et-boc .area-outer-wrap[data-da-color=light] .da-close:hover{color:#000;background:#fff;box-shadow:0 0 4px 0 rgba(0,0,0,.13),0 0 3px 1px rgba(0,0,0,.07)}#et-boc .area-outer-wrap[data-da-color=dark] .da-close{color:#eee;background:rgba(0,0,0,.13);box-shadow:0 0 0 1px hsla(0,0%,100%,.03);text-shadow:0 0 1px #000,0 0 3px rgba(0,0,0,.67)}#et-boc .area-outer-wrap[data-da-color=dark] .da-close:active,#et-boc .area-outer-wrap[data-da-color=dark] .da-close:focus,#et-boc .area-outer-wrap[data-da-color=dark] .da-close:hover{color:#fff;background:#2b2b2b;box-shadow:0 0 1px 1px hsla(0,0%,100%,.2)}#et-boc .area-outer-wrap[data-da-close-bg=none] .da-close,#et-boc .area-outer-wrap[data-da-close-bg=none] .da-close:active,#et-boc .area-outer-wrap[data-da-close-bg=none] .da-close:focus,#et-boc .area-outer-wrap[data-da-close-bg=none] .da-close:hover{box-shadow:none;background:transparent}#et-boc .area-outer-wrap[data-da-loader=yes] [data-da-area]{background-image:url(../img/spin.gif),radial-gradient(circle at center,#fff 65%,hsla(0,0%,100%,0) 66%)!important;background-size:32px 32px,48px 48px}#et-boc .area-outer-wrap[data-da-shadow=yes] [data-da-area]{box-shadow:0 3px 10px -1px rgba(0,0,0,.3),0 2px 50px 2px rgba(0,0,0,.2)}#et-boc .area-outer-wrap[data-da-shadow=no] [data-da-area]{box-shadow:none}.area-outer-wrap [data-da-area]{display:block;pointer-events:all}.da-overlay{position:fixed;left:0;top:0;right:0;bottom:0;background:rgba(0,0,0,.55);z-index:99;transition:-webkit-backdrop-filter 1s 1s;transition:backdrop-filter 1s 1s;transition:backdrop-filter 1s 1s,-webkit-backdrop-filter 1s 1s;-webkit-backdrop-filter:none;backdrop-filter:none}.da-overlay-visible .da-overlay{-webkit-backdrop-filter:saturate(180%) blur(5px);backdrop-filter:saturate(180%) blur(5px)}[data-area-hook]{display:none!important;visibility:hidden!important}
include/class-popups-for-divi-compatibility.php DELETED
@@ -1,42 +0,0 @@
1
- <?php
2
- /**
3
- * Makes sure, that our plugin integrates nicely with other plugins.
4
- *
5
- * @package Popups_For_Divi
6
- */
7
-
8
- /**
9
- * Compatibility module.
10
- *
11
- * @since 1.4.5
12
- */
13
- class Popups_For_Divi_Compatibility extends Popups_For_Divi_Component {
14
- /**
15
- * Called during the "plugins_loaded" action. Hook up all actions/filters.
16
- *
17
- * @since 1.4.5
18
- * @return void
19
- */
20
- public function setup() {
21
- // SG Optimizer.
22
- add_action(
23
- 'sgo_javascript_combine_excluded_inline_content',
24
- [ $this, 'sg_optimizer_exclude_inline_content' ]
25
- );
26
- }
27
-
28
- /**
29
- * Instructs SG Optimizer to NOT combine our loader script. Combined scripts are
30
- * moved to end of the document, which counteracts the entire purpose of the
31
- * loader...
32
- *
33
- * @since 1.4.5
34
- * @param array $exclude_list Default exclude list.
35
- * @return array Extended exclude list.
36
- */
37
- public function sg_optimizer_exclude_inline_content( $exclude_list ) {
38
- $exclude_list[] = 'window.DiviPopupData=window.DiviAreaConfig=';
39
-
40
- return $exclude_list;
41
- }
42
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
include/core/class-pfd-app.php ADDED
@@ -0,0 +1,117 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Popups for Divi
4
+ * Main plugin instance/controller. The main popup logic is done in javascript,
5
+ * so we mainly need to make sure that our JS/CSS is loaded on the correctly.
6
+ *
7
+ * @package Popups_For_Divi
8
+ */
9
+
10
+ defined( 'ABSPATH' ) || die();
11
+
12
+ /**
13
+ * The application entry class.
14
+ */
15
+ class PFD_App extends PFD_Component {
16
+
17
+ /**
18
+ * Hook up the module.
19
+ *
20
+ * @since 1.0.0
21
+ * @since 2.0.4 function renamed from __construct() to setup().
22
+ */
23
+ public function setup() {
24
+ load_plugin_textdomain(
25
+ 'popups-for-divi',
26
+ false,
27
+ dirname( DIVI_POPUP_PLUGIN ) . '/lang/'
28
+ );
29
+
30
+ // Do not load the JS library, when the Pro version is active.
31
+ if ( defined( 'DIVI_AREAS_PLUGIN' ) ) {
32
+ return;
33
+ }
34
+
35
+ // Add dependencies.
36
+ $this->add_module( 'welcome', 'PFD_Onboarding' )->setup_on( 'divi_popups_loaded' );
37
+ $this->add_module( 'editor', 'PFD_Editor' )->setup_on( 'divi_popups_loaded' );
38
+ $this->add_module( 'asset', 'PFD_Asset' )->setup_on( 'divi_popups_loaded' );
39
+
40
+ $this->setup_hooks();
41
+
42
+ /**
43
+ * Initialize dependencies.
44
+ *
45
+ * @since 2.0.4
46
+ */
47
+ do_action( 'divi_popups_loaded' );
48
+ }
49
+
50
+ /**
51
+ * Hook into WordPress actions.
52
+ *
53
+ * @since 2.2.2
54
+ * @return void
55
+ */
56
+ public function setup_hooks() {
57
+ add_filter(
58
+ 'plugin_action_links_' . DIVI_POPUP_PLUGIN,
59
+ [ $this, 'plugin_add_settings_link' ]
60
+ );
61
+
62
+ add_filter(
63
+ 'plugin_row_meta',
64
+ [ $this, 'plugin_row_meta' ],
65
+ 10,
66
+ 4
67
+ );
68
+
69
+ add_action(
70
+ 'wp_enqueue_scripts',
71
+ [ $this->module( 'asset' ), 'enqueue_js_library' ]
72
+ );
73
+ }
74
+
75
+ /**
76
+ * Display a custom link in the plugins list
77
+ *
78
+ * @since 1.0.2
79
+ * @param array $links List of plugin links.
80
+ * @return array New list of plugin links.
81
+ */
82
+ public function plugin_add_settings_link( $links ) {
83
+ $links[] = sprintf(
84
+ '<a href="%s" target="_blank">%s</a>',
85
+ 'https://divimode.com/divi-popup/?utm_source=wpadmin&utm_medium=link&utm_campaign=popups-for-divi',
86
+ __( 'How it works', 'divi-popup' )
87
+ );
88
+ return $links;
89
+ }
90
+
91
+ /**
92
+ * Display additional details in the right column of the "Plugins" page.
93
+ *
94
+ * @since 1.6.0
95
+ * @param string[] $plugin_meta An array of the plugin's metadata,
96
+ * including the version, author,
97
+ * author URI, and plugin URI.
98
+ * @param string $plugin_file Path to the plugin file relative to the plugins directory.
99
+ * @param array $plugin_data An array of plugin data.
100
+ * @param string $status Status of the plugin. Defaults are 'All', 'Active',
101
+ * 'Inactive', 'Recently Activated', 'Upgrade', 'Must-Use',
102
+ * 'Drop-ins', 'Search'.
103
+ */
104
+ public function plugin_row_meta( $plugin_meta, $plugin_file, $plugin_data, $status ) {
105
+ if ( DIVI_POPUP_PLUGIN !== $plugin_file ) {
106
+ return $plugin_meta;
107
+ }
108
+
109
+ $plugin_meta[] = sprintf(
110
+ '<a href="%s" target="_blank">%s</a>',
111
+ 'https://divimode.com/divi-areas-pro/?utm_source=wpadmin&utm_medium=link&utm_campaign=popups-for-divi',
112
+ __( 'Divi Areas <strong>Pro</strong>', 'divi-popup' )
113
+ );
114
+
115
+ return $plugin_meta;
116
+ }
117
+ }
include/{class-popups-for-divi.php → core/class-pfd-asset.php} RENAMED
@@ -1,8 +1,6 @@
1
  <?php
2
  /**
3
- * Popups for Divi
4
- * Main plugin instance/controller. The main popup logic is done in javascript,
5
- * so we mainly need to make sure that our JS/CSS is loaded on the correctly.
6
  *
7
  * @package Popups_For_Divi
8
  */
@@ -10,108 +8,38 @@
10
  defined( 'ABSPATH' ) || die();
11
 
12
  /**
13
- * The application entry class.
 
 
14
  */
15
- class Popups_For_Divi extends Popups_For_Divi_Component {
16
 
17
  /**
18
- * Hook up the module.
19
  *
20
- * @since 1.0.0
21
- * @since 2.0.4 function renamed from __construct() to setup().
22
  */
23
  public function setup() {
24
- load_plugin_textdomain(
25
- 'popups-for-divi',
26
- false,
27
- dirname( DIVI_POPUP_PLUGIN ) . '/lang/'
28
- );
29
-
30
- add_filter(
31
- 'plugin_action_links_' . DIVI_POPUP_PLUGIN,
32
- array( $this, 'plugin_add_settings_link' )
33
- );
34
-
35
- add_filter(
36
- 'plugin_row_meta',
37
- array( $this, 'plugin_row_meta' ),
38
- 10,
39
- 4
40
- );
41
-
42
- // Do not load the JS library, when the Pro version is active.
43
- if ( defined( 'DIVI_AREAS_PLUGIN' ) ) {
44
- return;
45
- }
46
-
47
- add_action( 'wp_enqueue_scripts', [ $this, 'enqueue_js_library' ] );
48
  add_filter( 'divi_areas_debug_infos', [ $this, 'generate_debug_infos' ] );
49
-
50
- // Load compatibility module.
51
- $this->add_module( 'compat', 'Popups_For_Divi_Compatibility' )
52
- ->setup_on( 'divi_popups_loaded' );
53
-
54
- // Add dependencies.
55
- $this->add_module( 'onboarding', 'Popups_For_Divi_Onboarding' )
56
- ->setup_on( 'divi_popups_loaded' );
57
- $this->add_module( 'editor', 'Popups_For_Divi_Editor' )
58
- ->setup_on( 'divi_popups_loaded' );
59
-
60
- /**
61
- * Initialize dependencies.
62
- *
63
- * @since 2.0.4
64
- */
65
- do_action( 'divi_popups_loaded' );
66
- }
67
-
68
- /**
69
- * Display a custom link in the plugins list
70
- *
71
- * @since 1.0.2
72
- * @param array $links List of plugin links.
73
- * @return array New list of plugin links.
74
- */
75
- public function plugin_add_settings_link( $links ) {
76
- $links[] = sprintf(
77
- '<a href="%s" target="_blank">%s</a>',
78
- 'https://divimode.com/divi-popup/?utm_source=wpadmin&utm_medium=link&utm_campaign=popups-for-divi',
79
- __( 'How it works', 'divi-popup' )
80
- );
81
- return $links;
82
  }
83
 
84
  /**
85
- * Display additional details in the right column of the "Plugins" page.
86
  *
87
- * @since 1.6.0
88
- * @param string[] $plugin_meta An array of the plugin's metadata,
89
- * including the version, author,
90
- * author URI, and plugin URI.
91
- * @param string $plugin_file Path to the plugin file relative to the plugins directory.
92
- * @param array $plugin_data An array of plugin data.
93
- * @param string $status Status of the plugin. Defaults are 'All', 'Active',
94
- * 'Inactive', 'Recently Activated', 'Upgrade', 'Must-Use',
95
- * 'Drop-ins', 'Search'.
96
  */
97
- public function plugin_row_meta( $plugin_meta, $plugin_file, $plugin_data, $status ) {
98
- if ( DIVI_POPUP_PLUGIN !== $plugin_file ) {
99
- return $plugin_meta;
100
  }
101
-
102
- $plugin_meta[] = sprintf(
103
- '<a href="%s" target="_blank">%s</a>',
104
- 'https://divimode.com/divi-areas-pro/?utm_source=wpadmin&utm_medium=link&utm_campaign=popups-for-divi',
105
- __( 'Divi Areas <strong>Pro</strong>', 'divi-popup' )
106
- );
107
-
108
- return $plugin_meta;
109
  }
110
 
111
  /**
112
  * Add the CSS/JS support to the front-end to make the popups work.
113
  *
114
- * @since 1.0.0
115
  */
116
  public function enqueue_js_library() {
117
  global $wp_query;
@@ -136,7 +64,6 @@ class Popups_For_Divi extends Popups_For_Divi_Component {
136
 
137
  if ( function_exists( 'et_fb_is_enabled' ) ) {
138
  $is_divi_v3 = true;
139
- add_filter( 'divi_popup_build_mode', 'et_fb_is_enabled' );
140
  } else {
141
  $is_divi_v3 = false;
142
  }
@@ -190,6 +117,16 @@ class Popups_For_Divi extends Popups_For_Divi_Component {
190
  */
191
  $js_data['modalIndicatorClass'] = 'is-modal';
192
 
 
 
 
 
 
 
 
 
 
 
193
  /**
194
  * This changes the default close-button state when a popup does
195
  * not specify noCloseClass or withCloseClass
@@ -273,9 +210,9 @@ class Popups_For_Divi extends Popups_For_Divi_Component {
273
  * @since JS 1.0.0
274
  */
275
  $js_data['initializeOnEvent'] = (
276
- $is_divi_v3
277
- ? 'et_pb_after_init_modules' // Divi 3.0+ detected.
278
- : false // Older Divi or other themes.
279
  );
280
 
281
  /**
@@ -286,14 +223,6 @@ class Popups_For_Divi extends Popups_For_Divi_Component {
286
  */
287
  $js_data['popupWrapperClass'] = 'area-outer-wrap';
288
 
289
- /**
290
- * CSS class that is added to the popup when it enters
291
- * full-width mode (i.e. on small screens)
292
- *
293
- * @since JS 1.0.0
294
- */
295
- $js_data['fullWidthClass'] = 'full-width';
296
-
297
  /**
298
  * CSS class that is added to the popup when it enters
299
  * full-height mode (i.e. on small screens)
@@ -443,7 +372,7 @@ class Popups_For_Divi extends Popups_For_Divi_Component {
443
  */
444
  $js_data['sys'] = apply_filters( 'divi_areas_debug_infos', [] );
445
 
446
- if ( is_admin() || apply_filters( 'divi_popup_build_mode', false ) ) {
447
  $base_name = 'builder';
448
  $inline_css = '';
449
  } else {
@@ -462,26 +391,44 @@ class Popups_For_Divi extends Popups_For_Divi_Component {
462
  $this->inject_loader( $js_data );
463
 
464
  wp_register_script(
465
- 'js-divi-popup',
466
- plugins_url( 'js/' . $base_name . '.js', dirname( __FILE__ ) ),
467
  [ 'jquery' ],
468
  $cache_version,
469
  true
470
  );
471
 
472
  wp_register_style(
473
- 'css-divi-popup',
474
- plugins_url( 'css/' . $base_name . '.css', dirname( __FILE__ ) ),
475
- array(),
476
  $cache_version,
477
  'all'
478
  );
479
 
480
- wp_enqueue_script( 'js-divi-popup' );
481
- wp_enqueue_style( 'css-divi-popup' );
482
 
483
  if ( $inline_css ) {
484
- wp_add_inline_style( 'css-divi-popup', $inline_css );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
485
  }
486
  }
487
 
@@ -498,9 +445,9 @@ class Popups_For_Divi extends Popups_For_Divi_Component {
498
  * @since 1.4.3
499
  * @param array $js_config The DiviAreaConfig object details.
500
  */
501
- public function inject_loader( array $js_config ) {
502
  /*
503
- Notice how this function ignores WP Coding Standards!
504
 
505
  The reason is, that we load the contents of a javascript file which we
506
  control (it's minified and part of plugin folder). Hence, the output is
@@ -517,7 +464,7 @@ class Popups_For_Divi extends Popups_For_Divi_Component {
517
  *
518
  * This line is used by the compatibility module!
519
  *
520
- * @see Popups_For_Divi_Compatibility::sg_optimizer_exclude_inline_content()
521
  */
522
  $loader[] = sprintf(
523
  'window.DiviPopupData=window.DiviAreaConfig=%s',
@@ -536,9 +483,9 @@ class Popups_For_Divi extends Popups_For_Divi_Component {
536
  /**
537
  * Collect anonymous details about the current system for output in error logs.
538
  *
539
- * @filter divi_areas_debug_infos
540
  *
541
- * @since 2.0.4
542
  * @param array $infos Debug details.
543
  * @return array Array containing debug details.
544
  */
1
  <?php
2
  /**
3
+ * Handles all assets (JS, CSS, JSON configuration, etc).
 
 
4
  *
5
  * @package Popups_For_Divi
6
  */
8
  defined( 'ABSPATH' ) || die();
9
 
10
  /**
11
+ * Asset handler class.
12
+ *
13
+ * @since 2.0.0
14
  */
15
+ class PFD_Asset extends PFD_Component {
16
 
17
  /**
18
+ * Called during the "plugins_loaded" action.
19
  *
20
+ * @since 2.0.0
 
21
  */
22
  public function setup() {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
23
  add_filter( 'divi_areas_debug_infos', [ $this, 'generate_debug_infos' ] );
24
+ add_action( 'init', [ $this, 'setup_hooks' ], 11 );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
25
  }
26
 
27
  /**
28
+ * Set up custom hooks for this module.
29
  *
30
+ * @since 2.0.1
31
+ * @return void
 
 
 
 
 
 
 
32
  */
33
+ public function setup_hooks() {
34
+ if ( function_exists( 'et_fb_is_enabled' ) ) {
35
+ add_filter( 'divi_areas_is_build_mode', 'et_fb_is_enabled' );
36
  }
 
 
 
 
 
 
 
 
37
  }
38
 
39
  /**
40
  * Add the CSS/JS support to the front-end to make the popups work.
41
  *
42
+ * @since 0.2.0
43
  */
44
  public function enqueue_js_library() {
45
  global $wp_query;
64
 
65
  if ( function_exists( 'et_fb_is_enabled' ) ) {
66
  $is_divi_v3 = true;
 
67
  } else {
68
  $is_divi_v3 = false;
69
  }
117
  */
118
  $js_data['modalIndicatorClass'] = 'is-modal';
119
 
120
+ /**
121
+ * Class that indicates a blocking popup, which has the purpose to block the
122
+ * page behind it from access. As a result, the blocking Popup ignores the ESC
123
+ * key. When combined with "is-modal" and "no-close", the Popup is practically
124
+ * un-closeable.
125
+ *
126
+ * @since JS 2.0.0
127
+ */
128
+ $js_data['blockingIndicatorClass'] = 'is-blocking';
129
+
130
  /**
131
  * This changes the default close-button state when a popup does
132
  * not specify noCloseClass or withCloseClass
210
  * @since JS 1.0.0
211
  */
212
  $js_data['initializeOnEvent'] = (
213
+ $is_divi_v3
214
+ ? 'et_pb_after_init_modules' // Divi 3.0+ detected.
215
+ : false // Older Divi or other themes.
216
  );
217
 
218
  /**
223
  */
224
  $js_data['popupWrapperClass'] = 'area-outer-wrap';
225
 
 
 
 
 
 
 
 
 
226
  /**
227
  * CSS class that is added to the popup when it enters
228
  * full-height mode (i.e. on small screens)
372
  */
373
  $js_data['sys'] = apply_filters( 'divi_areas_debug_infos', [] );
374
 
375
+ if ( is_admin() || apply_filters( 'divi_areas_is_build_mode', false ) ) {
376
  $base_name = 'builder';
377
  $inline_css = '';
378
  } else {
391
  $this->inject_loader( $js_data );
392
 
393
  wp_register_script(
394
+ 'js-divi-area',
395
+ DIVI_POPUP_URL . 'js/' . $base_name . '.js',
396
  [ 'jquery' ],
397
  $cache_version,
398
  true
399
  );
400
 
401
  wp_register_style(
402
+ 'css-divi-area',
403
+ DIVI_POPUP_URL . 'css/' . $base_name . '.css',
404
+ [],
405
  $cache_version,
406
  'all'
407
  );
408
 
409
+ wp_enqueue_script( 'js-divi-area' );
410
+ wp_enqueue_style( 'css-divi-area' );
411
 
412
  if ( $inline_css ) {
413
+ wp_add_inline_style( 'css-divi-area', $inline_css );
414
+ }
415
+ }
416
+
417
+ /**
418
+ * Enqueues the styles for the Divi Area front end preview.
419
+ *
420
+ * @since 2.0.0
421
+ * @return void
422
+ */
423
+ public function enqueue_ie_scripts() {
424
+ if ( ! is_admin() && ! apply_filters( 'divi_areas_is_build_mode', false ) ) {
425
+ wp_enqueue_script(
426
+ 'dap-ie',
427
+ DIVI_POPUP_URL . 'js/ie-compat.js',
428
+ [],
429
+ DIVI_POPUP_VERSION,
430
+ false
431
+ );
432
  }
433
  }
434
 
445
  * @since 1.4.3
446
  * @param array $js_config The DiviAreaConfig object details.
447
  */
448
+ private function inject_loader( array $js_config ) {
449
  /*
450
+ Notice, how this function ignores WP Coding Standards!
451
 
452
  The reason is, that we load the contents of a javascript file which we
453
  control (it's minified and part of plugin folder). Hence, the output is
464
  *
465
  * This line is used by the compatibility module!
466
  *
467
+ * @see divi_areas_exclude_inline_content() in plugin-compatibility.php
468
  */
469
  $loader[] = sprintf(
470
  'window.DiviPopupData=window.DiviAreaConfig=%s',
483
  /**
484
  * Collect anonymous details about the current system for output in error logs.
485
  *
486
+ * @filter divi_POPUP_debug_infos
487
  *
488
+ * @since 1.2.3
489
  * @param array $infos Debug details.
490
  * @return array Array containing debug details.
491
  */
include/{class-popups-for-divi-component.php → core/class-pfd-component.php} RENAMED
@@ -1,18 +1,25 @@
1
  <?php
2
  /**
3
- * Base component for other Popups for Divi classes.
4
  *
5
  * @package Popups_For_Divi
6
  */
7
 
8
  /**
9
  * Base class.
 
 
 
 
 
 
 
10
  */
11
- class Popups_For_Divi_Component {
12
  /**
13
  * Whether the current instance was already set up.
14
  *
15
- * @since 2.0.4
16
  * @var bool
17
  */
18
  private $setup_complete = false;
@@ -22,28 +29,17 @@ class Popups_For_Divi_Component {
22
  *
23
  * Used by add_module() / module() / module_type().
24
  *
25
- * @since 2.0.4
26
  * @var array
27
  */
28
- private $internal_modules = [];
29
-
30
- /**
31
- * The parent app component.
32
- *
33
- * @since 2.0.4
34
- * @var object
35
- */
36
- private $internal_app = null;
37
 
38
  /**
39
  * Set up the new component.
40
  *
41
- * @since 2.0.4
42
- * @param mixed $parent A parent component, or empty.
43
  */
44
- public function __construct( $parent = null ) {
45
- $this->internal_app = $parent;
46
-
47
  // Initialize variables instantly.
48
  $this->setup_instance();
49
  }
@@ -51,7 +47,7 @@ class Popups_For_Divi_Component {
51
  /**
52
  * Setup class variables during constructor call.
53
  *
54
- * @since 2.0.4
55
  * @return void
56
  */
57
  protected function setup_instance() {
@@ -61,7 +57,7 @@ class Popups_For_Divi_Component {
61
  /**
62
  * Setup all the hooks of the object and initialize members.
63
  *
64
- * @since 2.0.4
65
  * @return void
66
  */
67
  public function setup() {
@@ -71,7 +67,7 @@ class Popups_For_Divi_Component {
71
  /**
72
  * Marks the current instance as set-up.
73
  *
74
- * @since 2.0.4
75
  * @return void
76
  */
77
  final public function internal_setup() {
@@ -81,9 +77,9 @@ class Popups_For_Divi_Component {
81
  /**
82
  * Registers a setup hook name and returns $this for chaining.
83
  *
84
- * @since 2.0.4
85
  * @param string $hook_name Defines the WP action which triggers setup().
86
- * @return Popups_For_Divi_Component
87
  */
88
  final public function setup_on( $hook_name ) {
89
  if ( ! $this->setup_complete ) {
@@ -95,39 +91,39 @@ class Popups_For_Divi_Component {
95
  }
96
 
97
  /**
98
- * Returns the parent component of the current component.
99
  *
100
- * @since 2.0.4
101
- * @return object
102
  */
103
- final public function app() {
104
- return $this->internal_app;
105
  }
106
 
107
  /**
108
  * Registers a new child module of the current component.
109
  *
110
- * @throws Exception When the specified class name is invalid.
111
- * @throws Exception When the given module identifier is already registered.
112
  *
113
- * @since 2.0.4
114
  * @param string $id Identifier of the module, used to address it later.
115
  * @param string $class_name Class name of the new module.
116
  * @return object The newly created module instance.
117
  */
118
- final protected function add_module( $id, $class_name ) {
119
  if ( ! class_exists( $class_name ) ) {
120
- throw new Exception( 'Class not found: ' . $class_name );
121
  }
122
- if ( isset( $this->internal_modules[ $id ] ) ) {
123
- throw new Exception( 'Module already registered: ' . $id );
124
  }
125
 
126
  // Create the new module instance.
127
- $inst = new $class_name( $this );
128
 
129
  // Store the instance for later access.
130
- $this->internal_modules[ $id ] = [
131
  'id' => $id,
132
  'class' => $class_name,
133
  'inst' => $inst,
@@ -143,24 +139,25 @@ class Popups_For_Divi_Component {
143
  * $strict param determines whether to check all parent components or whether
144
  * an error should be thrown.
145
  *
146
- * @throws Exception When no module with the requested identifier exists.
 
147
  *
148
- * @since 2.0.4
149
  * @param string $id The module identifier.
150
  * @param bool $strict When false, then the parents module() is returned in
151
  * case the current component does not have the requested
152
  * module.
153
  * @return object Returns the module instance.
154
  */
155
- final public function module( $id, $strict = false ) {
156
- if ( isset( $this->internal_modules[ $id ] ) ) {
157
- return $this->internal_modules[ $id ]['inst'];
158
  }
159
 
160
- if ( $strict || ! $this->internal_app ) {
161
- throw new Exception( 'No module found with id: ' . $id );
162
  } else {
163
- return $this->app()->module( $id, false );
164
  }
165
  }
166
 
@@ -168,14 +165,14 @@ class Popups_For_Divi_Component {
168
  * Returns the class name of the requested module, or an empty string when no
169
  * module with the given identifier was registered.
170
  *
171
- * @since 2.0.4
172
  * @param string $id The module identifier.
173
  * @return string Returns the class name of the module, or an empty string when
174
  * the module was not registered.
175
  */
176
  final public function module_type( $id ) {
177
- if ( isset( $this->internal_modules[ $id ] ) ) {
178
- return $this->internal_modules[ $id ]['class'];
179
  }
180
 
181
  return '';
1
  <?php
2
  /**
3
+ * Base component for other PFD-classes.
4
  *
5
  * @package Popups_For_Divi
6
  */
7
 
8
  /**
9
  * Base class.
10
+ *
11
+ * This base class is shared with other divimode plugins.
12
+ *
13
+ * When this file needs to be updated, change the version number and propagate all
14
+ * changes to the other plugins!
15
+ *
16
+ * @version 2.0.1
17
  */
18
+ class PFD_Component {
19
  /**
20
  * Whether the current instance was already set up.
21
  *
22
+ * @since 1.2.3
23
  * @var bool
24
  */
25
  private $setup_complete = false;
29
  *
30
  * Used by add_module() / module() / module_type().
31
  *
32
+ * @since 1.2.3
33
  * @var array
34
  */
35
+ private static $internal_modules = [];
 
 
 
 
 
 
 
 
36
 
37
  /**
38
  * Set up the new component.
39
  *
40
+ * @since 1.2.3
 
41
  */
42
+ public function __construct() {
 
 
43
  // Initialize variables instantly.
44
  $this->setup_instance();
45
  }
47
  /**
48
  * Setup class variables during constructor call.
49
  *
50
+ * @since 1.2.3
51
  * @return void
52
  */
53
  protected function setup_instance() {
57
  /**
58
  * Setup all the hooks of the object and initialize members.
59
  *
60
+ * @since 1.2.3
61
  * @return void
62
  */
63
  public function setup() {
67
  /**
68
  * Marks the current instance as set-up.
69
  *
70
+ * @since 1.2.3
71
  * @return void
72
  */
73
  final public function internal_setup() {
77
  /**
78
  * Registers a setup hook name and returns $this for chaining.
79
  *
80
+ * @since 1.2.3
81
  * @param string $hook_name Defines the WP action which triggers setup().
82
+ * @return PFD_Component
83
  */
84
  final public function setup_on( $hook_name ) {
85
  if ( ! $this->setup_complete ) {
91
  }
92
 
93
  /**
94
+ * Returns the main application object.
95
  *
96
+ * @since 1.2.3
97
+ * @return PFD_App
98
  */
99
+ final public static function app() {
100
+ return $GLOBALS['divi_popup'];
101
  }
102
 
103
  /**
104
  * Registers a new child module of the current component.
105
  *
106
+ * @throws PFD_Exception_Invalid_Module_Class When the specified class name is invalid.
107
+ * @throws PFD_Exception_Module_Already_Registered When the given module identifier is already registered.
108
  *
109
+ * @since 1.2.3
110
  * @param string $id Identifier of the module, used to address it later.
111
  * @param string $class_name Class name of the new module.
112
  * @return object The newly created module instance.
113
  */
114
+ final protected static function add_module( $id, $class_name ) {
115
  if ( ! class_exists( $class_name ) ) {
116
+ throw new PFD_Exception_Invalid_Module_Class( 'Class not found: ' . $class_name );
117
  }
118
+ if ( isset( self::$internal_modules[ $id ] ) ) {
119
+ throw new PFD_Exception_Module_Already_Registered( 'Module already registered: ' . $id );
120
  }
121
 
122
  // Create the new module instance.
123
+ $inst = new $class_name();
124
 
125
  // Store the instance for later access.
126
+ self::$internal_modules[ $id ] = [
127
  'id' => $id,
128
  'class' => $class_name,
129
  'inst' => $inst,
139
  * $strict param determines whether to check all parent components or whether
140
  * an error should be thrown.
141
  *
142
+ * @throws PFD_Exception_Module_Not_Found When no module with the requested
143
+ * identifier exists.
144
  *
145
+ * @since 1.2.3
146
  * @param string $id The module identifier.
147
  * @param bool $strict When false, then the parents module() is returned in
148
  * case the current component does not have the requested
149
  * module.
150
  * @return object Returns the module instance.
151
  */
152
+ final public static function module( $id, $strict = false ) {
153
+ if ( isset( self::$internal_modules[ $id ] ) ) {
154
+ return self::$internal_modules[ $id ]['inst'];
155
  }
156
 
157
+ if ( $strict ) {
158
+ throw new PFD_Exception_Module_Not_Found( 'No module found with id: ' . $id );
159
  } else {
160
+ return null;
161
  }
162
  }
163
 
165
  * Returns the class name of the requested module, or an empty string when no
166
  * module with the given identifier was registered.
167
  *
168
+ * @since 1.2.3
169
  * @param string $id The module identifier.
170
  * @return string Returns the class name of the module, or an empty string when
171
  * the module was not registered.
172
  */
173
  final public function module_type( $id ) {
174
+ if ( isset( self::$internal_modules[ $id ] ) ) {
175
+ return self::$internal_modules[ $id ]['class'];
176
  }
177
 
178
  return '';
include/{class-popups-for-divi-editor.php → core/class-pfd-editor.php} RENAMED
@@ -8,7 +8,7 @@
8
  /**
9
  * Ajax handler.
10
  */
11
- class Popups_For_Divi_Editor extends Popups_For_Divi_Component {
12
  /**
13
  * Called during the "plugins_loaded" action to add relevant hooks.
14
  *
8
  /**
9
  * Ajax handler.
10
  */
11
+ class PFD_Editor extends PFD_Component {
12
  /**
13
  * Called during the "plugins_loaded" action to add relevant hooks.
14
  *
include/{class-popups-for-divi-onboarding.php → core/class-pfd-onboarding.php} RENAMED
@@ -14,7 +14,7 @@ defined( 'ABSPATH' ) || die();
14
  /**
15
  * Set up our popup integration.
16
  */
17
- class Popups_For_Divi_Onboarding extends Popups_For_Divi_Component {
18
 
19
  /**
20
  * Hook up the module.
@@ -35,12 +35,12 @@ class Popups_For_Divi_Onboarding extends Popups_For_Divi_Component {
35
 
36
  add_action(
37
  'wp_ajax_pfd_hide_onboarding',
38
- array( $this, 'ajax_hide_onboarding' )
39
  );
40
 
41
  add_action(
42
  'wp_ajax_pfd_start_course',
43
- array( $this, 'ajax_start_course' )
44
  );
45
  }
46
 
@@ -54,7 +54,7 @@ class Popups_For_Divi_Onboarding extends Popups_For_Divi_Component {
54
  if ( $this->show_onboarding_form() ) {
55
  add_action(
56
  'admin_notices',
57
- array( $this, 'onboarding_notice' ),
58
  1
59
  );
60
  }
@@ -140,16 +140,16 @@ class Popups_For_Divi_Onboarding extends Popups_For_Divi_Component {
140
  // Send the subscription details to our website.
141
  $resp = wp_remote_post(
142
  'https://divimode.com/wp-admin/admin-post.php',
143
- array(
144
  'headers' => [
145
  'Content-Type' => 'application/x-www-form-urlencoded; charset=utf-8',
146
  ],
147
- 'body' => array(
148
  'action' => 'pfd_start_onboarding',
149
  'fname' => $name,
150
  'email' => $email,
151
- ),
152
- )
153
  );
154
 
155
  if ( is_wp_error( $resp ) ) {
14
  /**
15
  * Set up our popup integration.
16
  */
17
+ class PFD_Onboarding extends PFD_Component {
18
 
19
  /**
20
  * Hook up the module.
35
 
36
  add_action(
37
  'wp_ajax_pfd_hide_onboarding',
38
+ [ $this, 'ajax_hide_onboarding' ]
39
  );
40
 
41
  add_action(
42
  'wp_ajax_pfd_start_course',
43
+ [ $this, 'ajax_start_course' ]
44
  );
45
  }
46
 
54
  if ( $this->show_onboarding_form() ) {
55
  add_action(
56
  'admin_notices',
57
+ [ $this, 'onboarding_notice' ],
58
  1
59
  );
60
  }
140
  // Send the subscription details to our website.
141
  $resp = wp_remote_post(
142
  'https://divimode.com/wp-admin/admin-post.php',
143
+ [
144
  'headers' => [
145
  'Content-Type' => 'application/x-www-form-urlencoded; charset=utf-8',
146
  ],
147
+ 'body' => [
148
  'action' => 'pfd_start_onboarding',
149
  'fname' => $name,
150
  'email' => $email,
151
+ ],
152
+ ]
153
  );
154
 
155
  if ( is_wp_error( $resp ) ) {
include/helper/exceptions.php ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php //phpcs:ignore WordPress.Files.FileName.InvalidClassFileName
2
+ /**
3
+ * Defines custom exceptions that are thrown by Popups for Divi.
4
+ *
5
+ * @package Popups_For_Divi
6
+ * @phpcs:disable Generic.Files.OneObjectStructurePerFile.MultipleFound
7
+ */
8
+
9
+ defined( 'ABSPATH' ) || die();
10
+
11
+ /**
12
+ * Exception that is thrown, when a requested application module does not exist. It
13
+ * indicates, that either an invalid module is used, or that the app tries to access a
14
+ * module before it was registered.
15
+ *
16
+ * @since 2.0.0
17
+ */
18
+ class PFD_Exception_Module_Not_Found extends Exception {}
19
+
20
+ /**
21
+ * Exception that is thrown, when the application tries to register a new module, but
22
+ * the specified module class does not exist. Either the module class contains a typo
23
+ * (i.e. invalid class name) or the class definition was not loaded yet.
24
+ *
25
+ * @since 2.0.0
26
+ */
27
+ class PFD_Exception_Invalid_Module_Class extends Exception {}
28
+
29
+ /**
30
+ * Exception that is throws when the application tries to register two modules with
31
+ * the same name. That's a clear indicator of unstructured or too complex code.
32
+ *
33
+ * @since 2.0.0
34
+ */
35
+ class PFD_Exception_Module_Already_Registered extends Exception {}
include/helper/plugin-compatibility.php ADDED
@@ -0,0 +1,55 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Makes sure, that our plugin integrates nicely with other plugins.
4
+ *
5
+ * @package Popups_For_Divi
6
+ */
7
+
8
+ defined( 'ABSPATH' ) || die();
9
+
10
+ // SG Optimizer.
11
+ add_filter(
12
+ 'sgo_javascript_combine_excluded_inline_content',
13
+ 'divi_popup_exclude_inline_content'
14
+ );
15
+
16
+ // WP Rocket.
17
+ add_filter(
18
+ 'rocket_excluded_inline_js_content',
19
+ 'divi_popup_exclude_inline_content'
20
+ );
21
+
22
+ /**
23
+ * Instructs Caching plugins to NOT combine our loader script. Combined scripts are
24
+ * moved to end of the document, which counteracts the entire purpose of the
25
+ * loader...
26
+ *
27
+ * Used by SG Optimizer, WP Rocket
28
+ *
29
+ * @since 1.4.5
30
+ * @param array $exclude_list Default exclude list.
31
+ * @return array Extended exclude list.
32
+ */
33
+ function divi_popup_exclude_inline_content( $exclude_list ) {
34
+ $exclude_list[] = 'window.DiviPopupData=window.DiviAreaConfig=';
35
+
36
+ return $exclude_list;
37
+ }
38
+
39
+ /**
40
+ * Provides plugin compatibility with IE 11.
41
+ *
42
+ * @global $is_IE Boolean. True for all IE browsers.
43
+ *
44
+ * @since 2.0.1
45
+ * @return void
46
+ */
47
+ function divi_popup_ie_compat() {
48
+ add_filter(
49
+ 'wp_enqueue_scripts',
50
+ [ PFD_App::module( 'asset' ), 'enqueue_ie_scripts' ],
51
+ 1
52
+ );
53
+ }
54
+
55
+ add_action( 'divi_popups_loaded', 'divi_popup_ie_compat' );
js/builder.js CHANGED
@@ -1 +1 @@
1
- !function(e){var t={};function i(o){if(t[o])return t[o].exports;var a=t[o]={i:o,l:!1,exports:{}};return e[o].call(a.exports,a,a.exports,i),a.l=!0,a.exports}i.m=e,i.c=t,i.d=function(e,t,o){i.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,t){if(1&t&&(e=i(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(i.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)i.d(o,a,function(t){return e[t]}.bind(null,a));return o},i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,"a",t),t},i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.p="",i(i.s=15)}({0:function(e,t,i){"use strict";var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};!function(e){DiviArea.Utils=DiviArea.Utils||{};var t=!1;function i(t,i,o){var a,n;for(Array.isArray(t)&&(t=e(t).map(e.fn.toArray)),t=e(t),i=i.split(/\s+/),a=0;a<t.length;a++)for(n=0;n<i.length;n++)o(t[a],i[n])}DiviArea.Utils.getOption=function(e){var t=DiviAreaConfig[e],i=DiviArea.Utils.sanitizeHookName(e);return DiviArea.Hooks.silent().applyFilters("get_option_"+i,t)},DiviArea.Utils.toBool=function(e,t){return void 0===t&&(t=!0),void 0===e||null===e?!!t:!0===e||!1===e?e:("string"==typeof e&&(e=e.toLowerCase()),0!==e&&"0"!==e&&"n"!==e[0]&&"f"!==e[0]&&"off"!==e&&(1===e||"1"===e||"y"===e[0]||"t"===e[0]||"on"===e||!!t))},DiviArea.Utils.toMilliseconds=function(e){var t,i=parseFloat(e,10),o=e.match(/m?s/);switch(o&&(o=o[0]),o){case"s":t=1e3*i;break;case"ms":t=i;break;default:t=0}return t},DiviArea.Utils.sanitizeHookName=function(e){return e.toLowerCase().replace(/-/g,"_").replace(/[^a-z0-9_]+/,"")},DiviArea.Utils.showOnViewport=function(t){var i=e(window).innerWidth();return i<768?t.getData("onmobile"):i<981?t.getData("ontablet"):t.getData("ondesktop")},DiviArea.Utils.isPosition=function(e,t){var i=e.offsetParent();return"HTML"!==i.prop("tagName")&&(t===i.css("position")||DiviArea.Utils.isPosition(i,t))},DiviArea.Utils.setLocalData=function(e,t,i){(!i||isNaN(i)||i<1)&&(i=525600);var o=DiviArea.Utils.sanitizeHookName(e);if(t=DiviArea.applyFilters("set_data",t,e),t=DiviArea.applyFilters("set_data_"+o,t,e),i=DiviArea.applyFilters("set_data_expire",i,e,t),i=DiviArea.applyFilters("set_data_expire_"+o,i,e,t),!(!1===t||i<=0))if(window.localStorage){var a=new Date;a=a.setMinutes(a.getMinutes()+i),localStorage.setItem("_da_"+e,a+":"+t)}else DiviArea.Utils.setCookie("_da_"+e,t,i)},DiviArea.Utils.getLocalData=function(e){var t=!1;if(window.localStorage){var i=localStorage.getItem("_da_"+e);if(i){var o=i.split(":"),a=parseInt(o.shift()),n=o.join(":");a>new Date?t=n:localStorage.removeItem("_da_"+e)}}else t=DiviArea.Utils.getCookie("_da_"+e);var r=DiviArea.Utils.sanitizeHookName(e);return t=DiviArea.applyFilters("get_data",t,e),t=DiviArea.applyFilters("get_data_"+r,t,e)},DiviArea.Utils.setCookie=function(e,t,i){var o=escape(t);if(i){var a=new Date;a.setMinutes(a.getMinutes()+i),o+="; expires="+a.toUTCString()}document.cookie=e+"="+o+"; path=/"},DiviArea.Utils.getCookie=function(e){var t,i,o,a=document.cookie.split(";");for(t=0;t<a.length;t++)if(i=a[t].substr(0,a[t].indexOf("=")),o=a[t].substr(a[t].indexOf("=")+1),(i=i.replace(/^\s+|\s+$/g,""))===e)return unescape(o);return!1},DiviArea.Utils.getWindow=function(t){return e.isWindow(t)?t:9===t.nodeType&&(t.defaultView||t.parentWindow)},DiviArea.Utils.getClientRect=function(t){var i={top:0,left:0,width:0,height:0,bottom:0,right:0};if(0===t.length)return i;var o,a=(t=t[0]).ownerDocument,n=a.documentElement;if(!e.contains(n,t))return i;if(e.support.getBoundingClientRect){try{o=t.getBoundingClientRect()}catch(e){}if(!o)return i;if(o.right===o.left&&o.top===o.bottom)return i;var r=DiviArea.Utils.getWindow(a);i.top=o.top+(r.pageYOffset||n.scrollTop)-(n.clientTop||0),i.left=o.left+(r.pageXOffset||n.scrollLeft)-(n.clientLeft||0),i.width=o.right-o.left,i.height=o.bottom-o.top}else{if("none"===t.css("display"))return i;(i=t.offset()).width=t.outerWidth(),i.height=t.outerHeight()}return i.bottom=i.top+i.height,i.right=i.left+i.width,i},DiviArea.Utils.bindPassiveEvent=function(e,o,a){var n;n=!!t&&{passive:!1,capture:!1},i(e,o,function(e,t){e.addEventListener(t,a,n)})},DiviArea.Utils.unbindPassiveEvent=function(e,o,a){var n;n=!!t&&{passive:!1,capture:!1},i(e,o,function(e,t){e.removeEventListener(t,a,n)})},DiviArea.Utils.init=function(){var i={popupSelector:".et_pb_section.popup",fullWidthClass:"full-width",fullHeightClass:"full-height",openPopupClass:"da-overlay-visible",overlayClass:"da-overlay",modalIndicatorClass:"is-modal",exitIndicatorClass:"on-exit",hoverTriggerClass:"on-hover",clickTriggerClass:"on-click",activePopupClass:"is-open",noCloseClass:"no-close",altCloseClass:"close-alt",notMobileClass:"not-mobile",notTabletClass:"not-tablet",notDesktopClass:"not-desktop",withCloseClass:"with-close",withLoaderClass:"with-loader",singletonClass:"single",darkModeClass:"dark",noShadowClass:"with-shadow",closeButtonClass:"da-close",popupWrapperClass:"area-outer-wrap",defaultShowCloseButton:!0,idAttrib:"data-popup",triggerClassPrefix:"show-popup-",baseContext:"body",triggerCloseClass:"close",zIndex:1e6,onExitDelay:2e3,animateSpeed:300,debug:!1,debugVerbose:!1,initializeOnEvent:"et_pb_after_init_modules"},o="";if(function(){try{var e={get passive(){return t=!0,!1}};window.addEventListener("test",null,e),window.removeEventListener("test",null,e)}catch(e){t=!1}}(),e.support.getBoundingClientRect="getBoundingClientRect"in document.documentElement,window.DiviAreaConfig||(window.DiviAreaConfig=i),window.DiviPopupData)for(o in DiviPopupData)DiviPopupData.hasOwnProperty(o)&&(DiviAreaConfig[o]=DiviPopupData[o]);for(o in i)void 0===DiviAreaConfig[o]&&(DiviAreaConfig[o]=i[o]);for(o in DiviAreaConfig)DiviAreaConfig[o].replace&&(DiviAreaConfig[o]=DiviAreaConfig[o].replace(/^[\s\xA0]+|[\s\xA0]+$/g,""));DiviAreaConfig.zIndex=parseInt(DiviAreaConfig.zIndex),DiviAreaConfig.onExitDelay=parseInt(DiviAreaConfig.onExitDelay),DiviAreaConfig.animateSpeed=parseInt(DiviAreaConfig.animateSpeed),DiviAreaConfig.debug=!!DiviAreaConfig.debug,DiviAreaConfig.defaultShowCloseButton=!!DiviAreaConfig.defaultShowCloseButton,(!DiviAreaConfig.triggerClassPrefix||DiviAreaConfig.triggerClassPrefix.length<3)&&(DiviAreaConfig.triggerClassPrefix=!1),"body"===DiviAreaConfig.baseContext&&(1===e("#et_builder_outer_content").length?(DiviAreaConfig.baseContext="#et_builder_outer_content",DiviArea.Debug.info("🎚 Divi plugin detected.","Inject Areas into #et_builder_outer_content")):1===e(".et-db #et-boc").length?(DiviAreaConfig.baseContext=".et-db #et-boc",DiviArea.Debug.info("🎚 Divi theme detected.","Inject Areas into #et-boc")):1===e("body.et_divi_theme #page-container").length&&(DiviAreaConfig.baseContext="#page-container",DiviArea.Debug.info("🎚 Divi theme detected.","Inject Areas into #page-container"))),"body"===DiviAreaConfig.baseContext||e(DiviAreaConfig.baseContext).length||(DiviAreaConfig.baseContext="body",DiviArea.Debug.info("🎚 Invalid baseContext given.","Inject Areas into body instead.")),window.DiviPopupData=window.DiviAreaConfig,window.DiviAreaConfig=DiviArea.applyFilters("init_options",DiviAreaConfig)},DiviArea.Utils.initErrorLogging=function(e){var t=function(e,t,i){if(!e[t]||!e[t].__dm_orig__){var o=e[t],a=void 0;for(var n in e[t]=function(){var e=!1;try{e=i.apply(this,arguments)}finally{!e&&o&&(a=o.apply(this,arguments))}return a},o)o.hasOwnProperty(n)&&(e[t][n]=o[n]);e[t].__dm_orig__=o}},i=function(){var e=!1;if(arguments[0]&&"[DiviAreas]"===arguments[0])return!1;for(var t=0;t<arguments.length;t++)if("object"===o(arguments[t])&&arguments[t]&&arguments[t].message&&arguments[t].stack){e=arguments[t];break}if(e){var i=[],a=e.stack.toString().split("\n");if(i.push("divimode.com Anonymized Error Report"),i.push("-".repeat(30)),i.push(e.name),e.message?i.push(e.message):i.push("-"),i.push(""),a&&a.length>1)for(var n=0;n<a.length;n++){var r=a[n];if(r.match(/(\/wp-includes\/|\/jquery\.js)/))break;r.match(/\.js/)&&(r=(r=(r=r.replace(/^\s+|\s+$/g,"")).replace(/https?:.*?\/wp-content/g,"")).replace(/\.js\?[\w=&_\-\.]*/g,".js"),i.push(r))}if(DiviArea.info&&(i.push(""),i.push("js api:"+DiviArea.info)),window.DiviAreaConfig&&DiviAreaConfig.sys&&DiviAreaConfig.sys.plugin)for(var s in i.push(""),DiviAreaConfig.sys)try{i.push(s+": "+DiviAreaConfig.sys[s])}catch(e){}i.push("-".repeat(30));var l=console.error.__dm_orig__||console.error;return console.log(""),l("✋ "+i.join("\n| ")),console.log(""),!0}return!1};t(e,"onerror",i),t(e.console,"error",i)}}(window.jQuery)},15:function(e,t,i){i(16),e.exports=i(18)},16:function(e,t,i){"use strict";var o=function(e){return e&&e.__esModule?e:{default:e}}(i(17));!function(){jQuery(window).on("et_fb_init",function(){window.DiviAreaVB=window.DiviAreaVB||new o.default}),function e(){window.DiviArea?(i(0),DiviArea.Utils.initErrorLogging(window)):window.setTimeout(e,100)}()}()},17:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=function(){function e(e,t){for(var i=0;i<t.length;i++){var o=t[i];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,i,o){return i&&e(t.prototype,i),o&&e(t,o),t}}();var a=!1,n=!1,r=!1,s=!1,l={},d={module_id:"",module_class:"",da_is_popup:"off",da_popup_slug:"",da_exit_intent:"off",da_has_close:"on",da_alt_close:"off",da_dark_close:"off",da_not_modal:"on",da_is_singular:"off",da_with_loader:"off",da_has_shadow:"on",da_disable_devices:"off|off|off"},u=0,f=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.init=this.init.bind(this),window.setTimeout(this.init,20)}return o(e,[{key:"init",value:function(){if(window.ET_Builder){var e=(window._daConfig||{}).divi_areas_cpt||"divi-area";((((ET_Builder.Frames||{}).app||{}).ETBuilderBackendDynamic||{}).postType||"page")!==e&&this.startObserver()}else{if(!(++u<10))throw new Error("Could not initilize the Library (ET_Builder is undefined)");window.setTimeout(this.init,250)}}},{key:"startObserver",value:function(){var e=this;a&&this.stopObserver();var t=this.getAppFrame();if(t){var i=jQuery(t.document),o=this.sanitizeSlug;a=window.setInterval(function(){return e.observeAttribs()},200),i.on("blur.da",'input[name="module_id"], input[name="module_class"]',function(){e.observeClasses()}),i.on("blur.da",'input[name="da_popup_slug"]',function(){jQuery(this).val(o(jQuery(this).val()))})}else window.setTimeout(function(){return e.startObserver()},100)}},{key:"stopObserver",value:function(){if(a){var e=this.getAppFrame(),t=jQuery(e.document);window.clearInterval(a),t.off(".da",'input[name="module_id"], input[name="module_class"], input[name="da_popup_slug"]'),a=!1}}},{key:"observeAttribs",value:function(){var e=this.getApp();if(e&&e.state.activeModule&&e.state.activeModule.props&&"et_pb_section"===e.state.activeModule.props.type)for(var t=0;t<e.state.sections.length;t++){var i=e.state.sections[t],o=!1;this.compareSectionAttrs(i)&&(o=this.setSectionClasses(i)),o&&this.setSectionState(i,o)}}},{key:"observeClasses",value:function(){var e=this.getApp();if(e&&e.state)for(var t=0;t<e.state.sections.length;t++){var i=e.state.sections[t],o=!1;this.compareSectionClasses(i)&&(o=this.setSectionAttrs(i),o=this.setSectionClasses(o)),o&&this.setSectionState(i,o)}}},{key:"getAppFrame",value:function(){return!!(window.top.ET_Builder&&window.top.ET_Builder.Frames&&window.top.ET_Builder.Frames.top)&&window.top.ET_Builder.Frames.top}},{key:"getApp",value:function(){var e=this.getAppFrame();if(!e)return!1;var t=jQuery(e.document).find("#et-fb-app .place-top");if(!t||!t.length)return!1;if(!r||!t[0][r])for(var i in t[0])if(0===i.indexOf("__reactInternalInstance$")){n=i.substr(24),r="__reactInternalInstance$"+n;break}var o=t[0][r],a=this.getProp(o,["alternate","return","alternate","return","alternate","memoizedProps","_owner","alternate","memoizedState"]),s=this.getProp(o,["return","stateNode","setState"]);return!(!a||!s)&&{state:a,setState:s.bind(o.return.stateNode)}}},{key:"getProp",value:function(e,t){if(!t.length)return e;var i=t.shift();return!(!e||void 0===e[i])&&this.getProp(e[i],t)}},{key:"setSectionState",value:function(e,t){var i=this.getAppFrame();for(var o in d)e.attrs[o]!==t.attrs[o]&&(void 0===t.attrs[o]?delete e.attrs[o]:e.attrs[o]=t.attrs[o]);s&&window.clearTimeout(s),s=window.setTimeout(function(){s=!1;var e=document.createEvent("MouseEvents"),t=document.createEvent("MouseEvents"),o=i.jQuery(".et-fb-modal__resize")[0],a=i;o&&a&&(e.initMouseEvent("mousedown",!0,!0),t.initMouseEvent("mouseup",!0,!0),o.dispatchEvent(e),a.dispatchEvent(t))},50)}},{key:"compareSectionAttrs",value:function(e){var t=l[e.address],i=!1;for(var o in t||(i=!0,t={}),d)0===o.indexOf("da_")&&e.attrs[o]!==t[o]&&(i=!0,t[o]=e.attrs[o]);return i&&(l[e.address]=t),i}},{key:"compareSectionClasses",value:function(e){var t=l[e.address],i=!1;return t||(i=!0,t={}),void 0===t.module_id&&(t.module_id=""),void 0===t.module_class&&(t.module_class=""),e.attrs.module_id!==t.module_id&&(e.attrs.module_id||t.module_id)&&(i=!0,t.module_id=e.attrs.module_id),e.attrs.module_class!==t.module_class&&(e.attrs.module_class||t.module_class)&&(i=!0,t.module_class=e.attrs.module_class),i&&(l[e.address]=t),i}},{key:"sanitizeSlug",value:function(e){return"string"!=typeof e&&(e=""),e=(e=(e=(e=e.replace(/#/g,"")).replace(/[^a-zA-Z0-9\-_]/g,"-")).replace(/\-+/g,"-")).replace(/^\-+|\-+$/g,"")}},{key:"setSectionClasses",value:function(e){var t=JSON.parse(JSON.stringify(e)),i=(e.attrs.module_class||"").split(" "),o=e.attrs.da_is_popup||"off",a=e.attrs.da_popup_slug||"",n=e.attrs.da_exit_intent||"off",r=e.attrs.da_has_close||"on",s=e.attrs.da_alt_close||"off",d=e.attrs.da_dark_close||"off",u=e.attrs.da_not_modal||"on",f=e.attrs.da_is_singular||"off",p=e.attrs.da_with_loader||"off",c=e.attrs.da_has_shadow||"on",v=(e.attrs.da_disable_devices||"off|off|off").split("|"),_=["popup","on-exit","no-close","close-alt","dark","is-modal","single","with-loader","no-shadow","not-mobile","not-tablet","not-desktop"];return i=i.filter(function(e){return-1===_.indexOf(e)}),"on"===o&&(i.push("popup"),"on"===n&&i.push("on-exit"),"on"!==r?i.push("no-close"):("on"===s&&i.push("close-alt"),"on"===d&&i.push("dark")),"on"!==u&&i.push("is-modal"),"on"===f&&i.push("single"),"on"===p&&i.push("with-loader"),"on"!==c&&i.push("no-shadow"),"on"===v[0]&&i.push("not-mobile"),"on"===v[1]&&i.push("not-tablet"),"on"===v[2]&&i.push("not-desktop"),a&&(t.attrs.module_id=this.sanitizeSlug(a))),t.attrs.module_class=i.filter(function(e){return e}).join(" "),l[t.address].module_class=t.attrs.module_class,l[t.address].module_id=t.attrs.module_id,t}},{key:"setSectionAttrs",value:function(e){var t=JSON.parse(JSON.stringify(e)),i=this.sanitizeSlug(e.attrs.module_id),o=(e.attrs.module_class||"").split(" "),a=["off","off","off"];return t.attrs.da_is_popup=-1!==o.indexOf("popup")?"on":"off",t.attrs.da_has_close=-1===o.indexOf("no-close")?"on":"off",t.attrs.da_exit_intent=-1!==o.indexOf("on-exit")?"on":"off",t.attrs.da_alt_close=-1!==o.indexOf("close-alt")?"on":"off",t.attrs.da_dark_close=-1!==o.indexOf("dark")?"on":"off",t.attrs.da_not_modal=-1===o.indexOf("is-modal")?"on":"off",t.attrs.da_is_singular=-1!==o.indexOf("single")?"on":"off",t.attrs.da_with_loader=-1!==o.indexOf("with-loader")?"on":"off",t.attrs.da_has_shadow=-1===o.indexOf("no-shadow")?"on":"off",a[0]=-1!==o.indexOf("not-mobile")?"on":"off",a[1]=-1!==o.indexOf("not-tablet")?"on":"off",a[2]=-1!==o.indexOf("not-desktop")?"on":"off",t.attrs.da_disable_devices=a.join("|"),i&&(t.attrs.da_popup_slug=i),l[t.address].da_is_popup=t.attrs.da_is_popup,l[t.address].da_popup_slug=this.sanitizeSlug(t.attrs.da_popup_slug),l[t.address].da_has_close=t.attrs.da_has_close,l[t.address].da_exit_intent=t.attrs.da_exit_intent,l[t.address].da_alt_close=t.attrs.da_alt_close,l[t.address].da_dark_close=t.attrs.da_dark_close,l[t.address].da_not_modal=t.attrs.da_not_modal,l[t.address].da_is_singular=t.attrs.da_is_singular,l[t.address].da_has_shadow=t.attrs.da_has_shadow,l[t.address].da_disable_devices=t.attrs.da_disable_devices,l[t.address].da_with_loader=t.attrs.da_with_loader,t}}]),e}();t.default=f},18:function(e,t,i){}});
1
+ !function(){"use strict";var t,e=Object.freeze({__proto__:null});!function(t){window.DiviAreaFB=window.DiviAreaFB||{};var e=DiviAreaFB,a=!1,o=!1,s=!1,n=!1,d={},r={module_id:"",module_class:"",da_is_popup:"off",da_popup_slug:"",da_exit_intent:"off",da_has_close:"on",da_alt_close:"off",da_dark_close:"off",da_not_modal:"on",da_is_singular:"off",da_with_loader:"off",da_has_shadow:"on",da_disable_devices:"off|off|off"},i=0;function _(t,e){if(!e.length)return t;var a=e.shift();return!(!t||void 0===t[a])&&_(t[a],e)}function l(t,a){var o=e.getAppFrame();for(var s in r)t.attrs[s]!==a.attrs[s]&&(void 0===a.attrs[s]?delete t.attrs[s]:t.attrs[s]=a.attrs[s]);n&&window.clearTimeout(n),n=window.setTimeout((function(){n=!1;var t=document.createEvent("MouseEvents"),e=document.createEvent("MouseEvents"),a=o.jQuery(".et-fb-modal__resize")[0],s=o;a&&s&&(t.initMouseEvent("mousedown",!0,!0),e.initMouseEvent("mouseup",!0,!0),a.dispatchEvent(t),s.dispatchEvent(e))}),50)}function u(t){var e=d[t.address],a=!1;for(var o in e||(a=!0,e={}),r)0===o.indexOf("da_")&&t.attrs[o]!==e[o]&&(a=!0,e[o]=t.attrs[o]);return a&&(d[t.address]=e),a}function f(t){var e=d[t.address],a=!1;return e||(a=!0,e={}),void 0===e.module_id&&(e.module_id=""),void 0===e.module_class&&(e.module_class=""),t.attrs.module_id!==e.module_id&&(t.attrs.module_id||e.module_id)&&(a=!0,e.module_id=t.attrs.module_id),t.attrs.module_class!==e.module_class&&(t.attrs.module_class||e.module_class)&&(a=!0,e.module_class=t.attrs.module_class),a&&(d[t.address]=e),a}function p(t){var a=JSON.parse(JSON.stringify(t)),o=(t.attrs.module_class||"").split(" "),s=t.attrs.da_is_popup||"off",n=t.attrs.da_popup_slug||"",r=t.attrs.da_exit_intent||"off",i=t.attrs.da_has_close||"on",_=t.attrs.da_alt_close||"off",l=t.attrs.da_dark_close||"off",u=t.attrs.da_not_modal||"on",f=t.attrs.da_is_singular||"off",p=t.attrs.da_with_loader||"off",c=t.attrs.da_has_shadow||"on",m=(t.attrs.da_disable_devices||"off|off|off").split("|"),v=["popup","on-exit","no-close","close-alt","dark","is-modal","single","with-loader","no-shadow","not-mobile","not-tablet","not-desktop"];return o=o.filter((function(t){return-1===v.indexOf(t)})),"on"===s&&(o.push("popup"),"on"===r&&o.push("on-exit"),"on"!==i?o.push("no-close"):("on"===_&&o.push("close-alt"),"on"===l&&o.push("dark")),"on"!==u&&o.push("is-modal"),"on"===f&&o.push("single"),"on"===p&&o.push("with-loader"),"on"!==c&&o.push("no-shadow"),"on"===m[0]&&o.push("not-mobile"),"on"===m[1]&&o.push("not-tablet"),"on"===m[2]&&o.push("not-desktop"),n&&(a.attrs.module_id=e.sanitizeSlug(n))),a.attrs.module_class=o.filter((function(t){return t})).join(" "),d[a.address].module_class=a.attrs.module_class,d[a.address].module_id=a.attrs.module_id,a}function c(t){var a=JSON.parse(JSON.stringify(t)),o=e.sanitizeSlug(t.attrs.module_id),s=(t.attrs.module_class||"").split(" "),n=["off","off","off"];return a.attrs.da_is_popup=-1!==s.indexOf("popup")?"on":"off",a.attrs.da_has_close=-1===s.indexOf("no-close")?"on":"off",a.attrs.da_exit_intent=-1!==s.indexOf("on-exit")?"on":"off",a.attrs.da_alt_close=-1!==s.indexOf("close-alt")?"on":"off",a.attrs.da_dark_close=-1!==s.indexOf("dark")?"on":"off",a.attrs.da_not_modal=-1===s.indexOf("is-modal")?"on":"off",a.attrs.da_is_singular=-1!==s.indexOf("single")?"on":"off",a.attrs.da_with_loader=-1!==s.indexOf("with-loader")?"on":"off",a.attrs.da_has_shadow=-1===s.indexOf("no-shadow")?"on":"off",n[0]=-1!==s.indexOf("not-mobile")?"on":"off",n[1]=-1!==s.indexOf("not-tablet")?"on":"off",n[2]=-1!==s.indexOf("not-desktop")?"on":"off",a.attrs.da_disable_devices=n.join("|"),o&&(a.attrs.da_popup_slug=o),d[a.address].da_is_popup=a.attrs.da_is_popup,d[a.address].da_popup_slug=e.sanitizeSlug(a.attrs.da_popup_slug),d[a.address].da_has_close=a.attrs.da_has_close,d[a.address].da_exit_intent=a.attrs.da_exit_intent,d[a.address].da_alt_close=a.attrs.da_alt_close,d[a.address].da_dark_close=a.attrs.da_dark_close,d[a.address].da_not_modal=a.attrs.da_not_modal,d[a.address].da_is_singular=a.attrs.da_is_singular,d[a.address].da_has_shadow=a.attrs.da_has_shadow,d[a.address].da_disable_devices=a.attrs.da_disable_devices,d[a.address].da_with_loader=a.attrs.da_with_loader,a}e.init=function(){if(window.ET_Builder){var o=(window._daConfig||{}).divi_areas_cpt||"divi-area";((((ET_Builder.Frames||{}).app||{}).ETBuilderBackendDynamic||{}).postType||"page")!==o&&function o(){a&&function(){if(!a)return;var o=e.getAppFrame(),s=t(o.document);window.clearInterval(a),s.off(".da",'input[name="module_id"], input[name="module_class"], input[name="da_popup_slug"]'),a=!1}();var s=e.getAppFrame();if(!s)return void window.setTimeout((function(){return o()}),100);var n=t(s.document);a=window.setInterval((function(){return function(){var t=e.getApp();if(!t)return;if(!t.state.activeModule||!t.state.activeModule.props)return;if("et_pb_section"!==t.state.activeModule.props.type)return;for(var a=0;a<t.state.sections.length;a++){var o=t.state.sections[a],s=!1;u(o)&&(s=p(o)),s&&l(o,s)}}()}),200),n.on("blur.da",'input[name="module_id"], input[name="module_class"]',(function(){!function(){var t=e.getApp();if(!t||!t.state)return;for(var a=0;a<t.state.sections.length;a++){var o=t.state.sections[a],s=!1;f(o)&&(s=p(s=c(o))),s&&l(o,s)}}()})),n.on("blur.da",'input[name="da_popup_slug"]',(function(){t(this).val(e.sanitizeSlug(t(this).val()))}))}()}else{if(!(++i<10))throw new Error("Could not initialize the Library (ET_Builder is undefined)");window.setTimeout(e.init,250)}},e.getAppFrame=function(){return!!(window.top.ET_Builder&&window.top.ET_Builder.Frames&&window.top.ET_Builder.Frames.top)&&window.top.ET_Builder.Frames.top},e.getApp=function(){var a=e.getAppFrame();if(!a)return!1;var n=t(a.document).find("#et-fb-app .place-top");if(!n||!n.length)return!1;if(!s||!n[0][s])for(var d in n[0])if(0===d.indexOf("__reactInternalInstance$")){o=d.substr(24),s="__reactInternalInstance$"+o;break}var r=n[0][s],i=_(r,["alternate","return","alternate","return","alternate","memoizedProps","_owner","alternate","memoizedState"]),l=_(r,["return","stateNode","setState"]);return!(!i||!l)&&{state:i,setState:l.bind(r.return.stateNode)}},e.sanitizeSlug=function(t){return"string"!=typeof t&&(t=""),t=(t=(t=(t=t.replace(/#/g,"")).replace(/[^a-zA-Z0-9\-_]/g,"-")).replace(/\-+/g,"-")).replace(/^\-+|\-+$/g,"")}}(jQuery),(t=e)&&t.default,jQuery(window).on("et_fb_init",(function(){window.setTimeout(DiviAreaFB.init,20)}))}();
js/front.js CHANGED
@@ -1 +1 @@
1
- !function(e){var i={};function t(a){if(i[a])return i[a].exports;var r=i[a]={i:a,l:!1,exports:{}};return e[a].call(r.exports,r,r.exports,t),r.l=!0,r.exports}t.m=e,t.c=i,t.d=function(e,i,a){t.o(e,i)||Object.defineProperty(e,i,{enumerable:!0,get:a})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,i){if(1&i&&(e=t(e)),8&i)return e;if(4&i&&"object"==typeof e&&e&&e.__esModule)return e;var a=Object.create(null);if(t.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:e}),2&i&&"string"!=typeof e)for(var r in e)t.d(a,r,function(i){return e[i]}.bind(null,r));return a},t.n=function(e){var i=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(i,"a",i),i},t.o=function(e,i){return Object.prototype.hasOwnProperty.call(e,i)},t.p="",t(t.s=4)}([function(e,i,t){"use strict";var a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};!function(e){DiviArea.Utils=DiviArea.Utils||{};var i=!1;function t(i,t,a){var r,o;for(Array.isArray(i)&&(i=e(i).map(e.fn.toArray)),i=e(i),t=t.split(/\s+/),r=0;r<i.length;r++)for(o=0;o<t.length;o++)a(i[r],t[o])}DiviArea.Utils.getOption=function(e){var i=DiviAreaConfig[e],t=DiviArea.Utils.sanitizeHookName(e);return DiviArea.Hooks.silent().applyFilters("get_option_"+t,i)},DiviArea.Utils.toBool=function(e,i){return void 0===i&&(i=!0),void 0===e||null===e?!!i:!0===e||!1===e?e:("string"==typeof e&&(e=e.toLowerCase()),0!==e&&"0"!==e&&"n"!==e[0]&&"f"!==e[0]&&"off"!==e&&(1===e||"1"===e||"y"===e[0]||"t"===e[0]||"on"===e||!!i))},DiviArea.Utils.toMilliseconds=function(e){var i,t=parseFloat(e,10),a=e.match(/m?s/);switch(a&&(a=a[0]),a){case"s":i=1e3*t;break;case"ms":i=t;break;default:i=0}return i},DiviArea.Utils.sanitizeHookName=function(e){return e.toLowerCase().replace(/-/g,"_").replace(/[^a-z0-9_]+/,"")},DiviArea.Utils.showOnViewport=function(i){var t=e(window).innerWidth();return t<768?i.getData("onmobile"):t<981?i.getData("ontablet"):i.getData("ondesktop")},DiviArea.Utils.isPosition=function(e,i){var t=e.offsetParent();return"HTML"!==t.prop("tagName")&&(i===t.css("position")||DiviArea.Utils.isPosition(t,i))},DiviArea.Utils.setLocalData=function(e,i,t){(!t||isNaN(t)||t<1)&&(t=525600);var a=DiviArea.Utils.sanitizeHookName(e);if(i=DiviArea.applyFilters("set_data",i,e),i=DiviArea.applyFilters("set_data_"+a,i,e),t=DiviArea.applyFilters("set_data_expire",t,e,i),t=DiviArea.applyFilters("set_data_expire_"+a,t,e,i),!(!1===i||t<=0))if(window.localStorage){var r=new Date;r=r.setMinutes(r.getMinutes()+t),localStorage.setItem("_da_"+e,r+":"+i)}else DiviArea.Utils.setCookie("_da_"+e,i,t)},DiviArea.Utils.getLocalData=function(e){var i=!1;if(window.localStorage){var t=localStorage.getItem("_da_"+e);if(t){var a=t.split(":"),r=parseInt(a.shift()),o=a.join(":");r>new Date?i=o:localStorage.removeItem("_da_"+e)}}else i=DiviArea.Utils.getCookie("_da_"+e);var n=DiviArea.Utils.sanitizeHookName(e);return i=DiviArea.applyFilters("get_data",i,e),i=DiviArea.applyFilters("get_data_"+n,i,e)},DiviArea.Utils.setCookie=function(e,i,t){var a=escape(i);if(t){var r=new Date;r.setMinutes(r.getMinutes()+t),a+="; expires="+r.toUTCString()}document.cookie=e+"="+a+"; path=/"},DiviArea.Utils.getCookie=function(e){var i,t,a,r=document.cookie.split(";");for(i=0;i<r.length;i++)if(t=r[i].substr(0,r[i].indexOf("=")),a=r[i].substr(r[i].indexOf("=")+1),(t=t.replace(/^\s+|\s+$/g,""))===e)return unescape(a);return!1},DiviArea.Utils.getWindow=function(i){return e.isWindow(i)?i:9===i.nodeType&&(i.defaultView||i.parentWindow)},DiviArea.Utils.getClientRect=function(i){var t={top:0,left:0,width:0,height:0,bottom:0,right:0};if(0===i.length)return t;var a,r=(i=i[0]).ownerDocument,o=r.documentElement;if(!e.contains(o,i))return t;if(e.support.getBoundingClientRect){try{a=i.getBoundingClientRect()}catch(e){}if(!a)return t;if(a.right===a.left&&a.top===a.bottom)return t;var n=DiviArea.Utils.getWindow(r);t.top=a.top+(n.pageYOffset||o.scrollTop)-(o.clientTop||0),t.left=a.left+(n.pageXOffset||o.scrollLeft)-(o.clientLeft||0),t.width=a.right-a.left,t.height=a.bottom-a.top}else{if("none"===i.css("display"))return t;(t=i.offset()).width=i.outerWidth(),t.height=i.outerHeight()}return t.bottom=t.top+t.height,t.right=t.left+t.width,t},DiviArea.Utils.bindPassiveEvent=function(e,a,r){var o;o=!!i&&{passive:!1,capture:!1},t(e,a,function(e,i){e.addEventListener(i,r,o)})},DiviArea.Utils.unbindPassiveEvent=function(e,a,r){var o;o=!!i&&{passive:!1,capture:!1},t(e,a,function(e,i){e.removeEventListener(i,r,o)})},DiviArea.Utils.init=function(){var t={popupSelector:".et_pb_section.popup",fullWidthClass:"full-width",fullHeightClass:"full-height",openPopupClass:"da-overlay-visible",overlayClass:"da-overlay",modalIndicatorClass:"is-modal",exitIndicatorClass:"on-exit",hoverTriggerClass:"on-hover",clickTriggerClass:"on-click",activePopupClass:"is-open",noCloseClass:"no-close",altCloseClass:"close-alt",notMobileClass:"not-mobile",notTabletClass:"not-tablet",notDesktopClass:"not-desktop",withCloseClass:"with-close",withLoaderClass:"with-loader",singletonClass:"single",darkModeClass:"dark",noShadowClass:"with-shadow",closeButtonClass:"da-close",popupWrapperClass:"area-outer-wrap",defaultShowCloseButton:!0,idAttrib:"data-popup",triggerClassPrefix:"show-popup-",baseContext:"body",triggerCloseClass:"close",zIndex:1e6,onExitDelay:2e3,animateSpeed:300,debug:!1,debugVerbose:!1,initializeOnEvent:"et_pb_after_init_modules"},a="";if(function(){try{var e={get passive(){return i=!0,!1}};window.addEventListener("test",null,e),window.removeEventListener("test",null,e)}catch(e){i=!1}}(),e.support.getBoundingClientRect="getBoundingClientRect"in document.documentElement,window.DiviAreaConfig||(window.DiviAreaConfig=t),window.DiviPopupData)for(a in DiviPopupData)DiviPopupData.hasOwnProperty(a)&&(DiviAreaConfig[a]=DiviPopupData[a]);for(a in t)void 0===DiviAreaConfig[a]&&(DiviAreaConfig[a]=t[a]);for(a in DiviAreaConfig)DiviAreaConfig[a].replace&&(DiviAreaConfig[a]=DiviAreaConfig[a].replace(/^[\s\xA0]+|[\s\xA0]+$/g,""));DiviAreaConfig.zIndex=parseInt(DiviAreaConfig.zIndex),DiviAreaConfig.onExitDelay=parseInt(DiviAreaConfig.onExitDelay),DiviAreaConfig.animateSpeed=parseInt(DiviAreaConfig.animateSpeed),DiviAreaConfig.debug=!!DiviAreaConfig.debug,DiviAreaConfig.defaultShowCloseButton=!!DiviAreaConfig.defaultShowCloseButton,(!DiviAreaConfig.triggerClassPrefix||DiviAreaConfig.triggerClassPrefix.length<3)&&(DiviAreaConfig.triggerClassPrefix=!1),"body"===DiviAreaConfig.baseContext&&(1===e("#et_builder_outer_content").length?(DiviAreaConfig.baseContext="#et_builder_outer_content",DiviArea.Debug.info("🎚 Divi plugin detected.","Inject Areas into #et_builder_outer_content")):1===e(".et-db #et-boc").length?(DiviAreaConfig.baseContext=".et-db #et-boc",DiviArea.Debug.info("🎚 Divi theme detected.","Inject Areas into #et-boc")):1===e("body.et_divi_theme #page-container").length&&(DiviAreaConfig.baseContext="#page-container",DiviArea.Debug.info("🎚 Divi theme detected.","Inject Areas into #page-container"))),"body"===DiviAreaConfig.baseContext||e(DiviAreaConfig.baseContext).length||(DiviAreaConfig.baseContext="body",DiviArea.Debug.info("🎚 Invalid baseContext given.","Inject Areas into body instead.")),window.DiviPopupData=window.DiviAreaConfig,window.DiviAreaConfig=DiviArea.applyFilters("init_options",DiviAreaConfig)},DiviArea.Utils.initErrorLogging=function(e){var i=function(e,i,t){if(!e[i]||!e[i].__dm_orig__){var a=e[i],r=void 0;for(var o in e[i]=function(){var e=!1;try{e=t.apply(this,arguments)}finally{!e&&a&&(r=a.apply(this,arguments))}return r},a)a.hasOwnProperty(o)&&(e[i][o]=a[o]);e[i].__dm_orig__=a}},t=function(){var e=!1;if(arguments[0]&&"[DiviAreas]"===arguments[0])return!1;for(var i=0;i<arguments.length;i++)if("object"===a(arguments[i])&&arguments[i]&&arguments[i].message&&arguments[i].stack){e=arguments[i];break}if(e){var t=[],r=e.stack.toString().split("\n");if(t.push("divimode.com Anonymized Error Report"),t.push("-".repeat(30)),t.push(e.name),e.message?t.push(e.message):t.push("-"),t.push(""),r&&r.length>1)for(var o=0;o<r.length;o++){var n=r[o];if(n.match(/(\/wp-includes\/|\/jquery\.js)/))break;n.match(/\.js/)&&(n=(n=(n=n.replace(/^\s+|\s+$/g,"")).replace(/https?:.*?\/wp-content/g,"")).replace(/\.js\?[\w=&_\-\.]*/g,".js"),t.push(n))}if(DiviArea.info&&(t.push(""),t.push("js api:"+DiviArea.info)),window.DiviAreaConfig&&DiviAreaConfig.sys&&DiviAreaConfig.sys.plugin)for(var s in t.push(""),DiviAreaConfig.sys)try{t.push(s+": "+DiviAreaConfig.sys[s])}catch(e){}t.push("-".repeat(30));var l=console.error.__dm_orig__||console.error;return console.log(""),l("✋ "+t.join("\n| ")),console.log(""),!0}return!1};i(e,"onerror",t),i(e.console,"error",t)}}(window.jQuery)},,,,function(e,i,t){t(5),e.exports=t(14)},function(e,i,t){"use strict";t(0),t(6),t(7),t(8),t(9),t(10),t(11),t(12),t(13),DiviArea.init(!1)},function(e,i,t){"use strict";var a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};function r(e){if(Array.isArray(e)){for(var i=0,t=Array(e.length);i<e.length;i++)t[i]=e[i];return t}return Array.from(e)}window.DiviAreaItem=function(e,i){var t=jQuery,o=window.ResizeObserver||window.WebKitResizeObserver,n=t(e),s={},l={hideclose:!1,showclose:!0,notmobile:!1,onmobile:!0,nottablet:!1,ontablet:!0,notdesktop:!1,ondesktop:!0,closealt:!1,notmodal:!0,ismodal:!1,triggerexit:!1,shadow:!0,noshadow:!1,darkmode:!1,singleton:!1,static:!1},d={hideclose:"showclose",notdesktop:"ondesktop",notmobile:"onmobile",notmodal:"ismodal",nottablet:"ontablet",shadow:"noshadow",dynamic:"static"},c=null,u=null,v=0,p=null,f=null;function D(){for(var e in s._id=n.attr("id"),s._key=DiviArea.Utils.sanitizeHookName(s._id),s._type=w(i),s._inDom=n.closest(document.documentElement).length,s._isVisible=s._inDom&&n[0].getClientRects().length,DiviArea.Debug.debug("Area Type",this.theType()),DiviArea.Debug.debug("Area ID",this.theId()),DiviArea.Debug.debug("Area Hook",this.theKey()),x(n),this.setData("zindex",0),this.setData("container",t("body")),this.setData("hasShowAnim",!0),this.setData("position","center-center"),this.setData("positionv","center"),this.setData("positionh","center"),l)void 0!==n.data("da-"+e)?(this.setData(DiviArea.Utils.toBool(n.data("da-"+e))),n.removeAttr("data-da-"+e)):void 0!==n.data(e)?(this.setData(DiviArea.Utils.toBool(n.data(e))),n.removeAttr("data-"+e)):this.setData(e,l[e]);var a={};for(var r in a[DiviArea.Utils.getOption("notMobileClass")]=["onmobile",!1],a[DiviArea.Utils.getOption("notTabletClass")]=["ontablet",!1],a[DiviArea.Utils.getOption("notDesktopClass")]=["ondesktop",!1],a[DiviArea.Utils.getOption("noCloseClass")]=["showclose",!1],a[DiviArea.Utils.getOption("withCloseClass")]=["showclose",!0],a[DiviArea.Utils.getOption("altCloseClass")]=["closealt",!0],a[DiviArea.Utils.getOption("modalIndicatorClass")]=["ismodal",!0],a[DiviArea.Utils.getOption("exitIndicatorClass")]=["triggerexit",!0],a[DiviArea.Utils.getOption("noShadowClass")]=["noshadow",!0],a[DiviArea.Utils.getOption("darkModeClass")]=["darkmode",!0],a[DiviArea.Utils.getOption("singletonClass")]=["singleton",!0],a[DiviArea.Utils.getOption("withLoaderClass")]=["withloader",!0],a)if(n.hasClass(r)){var d=a[r];this.setData(d[0],d[1]),n.removeClass(r)}DiviArea.UI.initializeAreaAnimation(n),y(),b(),o&&(p=new o(function(e){var i=n[0].scrollHeight-n[0].clientHeight;i>0&&i-n[0].scrollTop<1&&(n[0].scrollTop-=1),k()},{box:"border-box"}))}function g(){var e={},i={};n.attr("data-da-area",this.theId()),c.attr("data-da-registered",1),c.attr("data-da-type",this.theType()),c.attr("data-da-close-btn",this.getData("showclose")?"yes":"no"),c.attr("data-da-close-bg",this.getData("closeAlt")?"none":"solid"),c.attr("data-da-loader",this.getData("withLoader")?"yes":"no"),c.attr("data-da-shadow",this.getData("shadow")?"yes":"no"),c.attr("data-da-color",this.getData("darkMode")?"dark":"light");var t=this.getData("wrapClasses");t&&c.addClass(t),this.isType("inline")||this.isType("hover")?(c.removeAttr("data-da-position"),c.removeAttr("data-da-positionh"),c.removeAttr("data-da-positionv")):(c.attr("data-da-position",this.getData("position")),c.attr("data-da-positionh",this.getData("positionh")),c.attr("data-da-positionv",this.getData("positionv"))),this.getData("maxheight")&&(e.overflow="auto",e.maxHeight=this.getData("maxheight")),this.getData("maxwidth")&&(e.maxWidth=this.getData("maxwidth")),this.inDom()&&(i.zIndex=this.getData("zindex")),n.css(e),c.css(i),this.doAction("refresh_area")}function A(){var e=this;if(this.isVisible()){n.find("."+DiviArea.Utils.getOption("closeButtonClass")).off(".da");var i=function(i,t){return DiviArea.Debug.debug("Click on",t,"close-button"),e.doAction("close_area",e,t),i.preventDefault(),!1};c.find("div ."+DiviArea.Utils.getOption("triggerCloseClass")).off(".da").on("click.da",function(e){return i(e,"custom")}),u.find("a").off(".da").on("click.da",function(e){return i(e,"default")}),t(window).on("resize",k),this.addAction("close_area",C)}else c.find("div ."+DiviArea.Utils.getOption("triggerCloseClass")).off(".da"),u.find("a").off(".da"),t(window).off("resize",k),this.removeAction("close_area")}function h(e){var i=this;if(this.isVisible()){if(this.getData("hasShowAnim")){DiviArea.Debug.info("✨ Animate the area (show)",this.theId()),DiviArea.UI.animateArea(this,"show",function(){i.getData("showclose")&&u.show(),e()})}}else this.getData("hasShowAnim")&&(u.hide(),DiviArea.Debug.info("✨ Animate the area (hide)",this.theId()),DiviArea.UI.animateArea(this,"hide",e))}function b(){if(!u){var e=DiviArea.Utils.getOption("closeButtonClass"),i=e+"-wrap";u=t("<span>").addClass(i).appendTo(c),t("<a>").attr("href","#close").addClass(e).html("&times;").appendTo(u),u.hide(),this.doAction("area_close_button",u,this)}}function y(){if(!c){var e=DiviArea.Utils.getOption("popupWrapperClass");(c=n.parent()).hasClass(e)||(n.wrap("<div>"),(c=n.parent()).addClass(e)),x(c),this.doAction("area_wrap",c,this)}}function m(){v&&clearTimeout(v),v=setTimeout(function(){g(),v=0},20)}function w(e){return e.toLowerCase().trim().replace(/-/,"")}function C(e,i){var t=!1;if(t=this.applyFilters("ignore_close_area",t,this,i))return DiviArea.Debug.debug("Ignored, manually cancelled in filter"),!0;DiviArea.hide(this)}function _(e){var i=this,t=n.attr("style"),a=function(){n.attr("style",t).hide(),window.setTimeout(e,1)};this.isType("inline")||this.getData("maxwidth")?a():(n.attr("style","opacity:0!important;transition:none!important;display:block!important"),window.setTimeout(function(){var e=!1,t=!1;(e=n.hasClass("et_pb_section")?n:n.find(".et_pb_section").length?n.find(".et_pb_section"):n.children())&&e.length&&(t=e.first().outerWidth()),t&&!isNaN(t)?(i.setData("maxwidth",t.toString()+"px"),DiviArea.Debug.debug("Auto max-width calculated:",i.getData("maxwidth"),i.theId())):(i.setData("maxwidth","1080px"),DiviArea.Debug.debug("Could not calculate max-width for",i.theId())),a()},40))}function k(){if(this.isVisible()){var e=this.getSize();u.css({width:e.width,height:e.height});var i,a,r=parseInt(t("html").css("marginTop")),o=window.innerWidth,n=window.innerHeight;i=o-e.contentWidth,a=this.isType("popup")?n-e.contentHeight:n-r-e.contentHeight,i<=20?c.attr("data-da-size-full-width")||(c.attr("data-da-size-full-width",1),c.addClass(DiviArea.Utils.getOption("fullWidthClass"))):c.attr("data-da-size-full-width")&&(c.removeAttr("data-da-size-full-width"),c.removeClass(DiviArea.Utils.getOption("fullWidthClass"))),a<=20?c.attr("data-da-size-full-height")||(c.attr("data-da-size-full-height",1),c.addClass(DiviArea.Utils.getOption("fullHeightClass"))):c.attr("data-da-size-full-height")&&(c.removeAttr("data-da-size-full-height"),c.removeClass(DiviArea.Utils.getOption("fullHeightClass")))}}function x(e){var i=this;e.data("is-area",!0),e.data("area",this),e.data("area-config",s),e.getArea=function(){return i}}function O(){}this.theId=function(){return"#"+s._id},this.theKey=function(){return s._key},this.theType=function(){return s._type},this.isType=function(e){if(!e)return!0;if("string"!=typeof e)throw new Error("DiviAreaItem.isType() expects a string parameter. Given value is a "+(void 0===e?"undefined":a(e)));if((e=w(e))===s._type)return!0;if("any"===e||"all"===e)return!0;for(var i=0===e.indexOf("not:"),t=e.replace(/^not:\s*/,"").split(/\s*,\s*/),r=0;r<t.length;r++)if(t[r]===s._type)return!i;return i},this.get=function(e){return e?t(e,n):n},this.getWrap=function(){return c},this.attach=function(){var e=this;if(!this.inDom()){s._inDom=!0;var i=this.findHook();if(n.hide(),i){var t=i.data("area-place"),a=i;"after"===t?a=i.next():"replace"===t&&(f=i.next().detach()),a.after(c.detach())}else c.detach().appendTo(this.getData("container"));c.closest("#et-boc").length||c.wrap('<div id="et-boc">'),_(function(){e.setVisible(!0,function(){if(p){var e=DiviArea.Utils.getOption("closeButtonClass")+"-wrap";n.children().each(function(i,t){-1===t.className.indexOf(e)&&p.observe(t)}),p.observe(n[0])}})})}},this.detach=function(){if(this.inDom()){s._inDom=!1;var e=this.findHook();p&&p.disconnect(),this.setVisible(!1,function(){var i=c.parent();n.hide(),c.detach(),"et-boc"!==i.attr("id")||i.children().length||i.remove(),f&&(e.after(f),f=null)})}},this.findHook=function(){var e='[data-area-hook="'+this.getData("postId")+'"]',i=t(e);return!!i.length&&i},this.setVisible=function(e,i){e=!!e,s._isVisible!==e&&("function"!=typeof i&&(i=O),s._isVisible=e,A(),h(i),this.isVisible()?this.doAction("show_area"):this.doAction("hide_area"))},this.setTriggerEvent=function(e){var i=!1;e&&(e.delegateTarget?i=e.delegateTarget:e.target&&(i=e.target)),this.setData("attachto",i),DiviArea.Debug.debug("Attached to element:",i||"(none)")},this.isVisible=function(){return s._isVisible},this.inDom=function(){return s._inDom},this.getSize=function(){var e={width:0,height:0,contentWidth:0,contentHeight:0};return this.isVisible()&&(e.width=n[0].clientWidth,e.height=n[0].clientHeight,e.contentWidth=n[0].scrollWidth||e.width,e.contentHeight=n[0].scrollHeight||e.height),e},this.getData=function(e){var i;return e=e.toLowerCase().replace(/[^a-z0-9]/,""),d.hasOwnProperty(e)?(e=d[e],i=!s[e]):i=s[e],i},this.setData=function(e,i){if(void 0!==i){if(e=e.toLowerCase().replace(/[^a-z0-9]/,""),l.hasOwnProperty(e))i=DiviArea.Utils.toBool(i,l[e]),d.hasOwnProperty(e)&&(e=d[e],i=!i);else switch(e){case"zindex":i=parseInt(i);break;case"closedelay":i=parseFloat(i);break;case"position":-1!==i.indexOf("top")?s.positionv="top":-1!==i.indexOf("bottom")?s.positionv="bottom":s.positionv="center",-1!==i.indexOf("left")?s.positionh="left":-1!==i.indexOf("right")?s.positionh="right":s.positionh="center",i=s.positionv+"-"+s.positionh;break;case"positionh":if("left"!==i&&"right"!==i&&"center"!==i)return;break;case"positionv":if("top"!==i&&"bottom"!==i&&"center"!==i)return;break;case"container":(i=t(i).first()).length||(i=t("body"));break;case"attachto":i=t(i).first()}switch(s[e]=i,e){case"positionh":case"positionv":s.position=s.positionv+"-"+s.positionh}m()}},this.doAction=function(e){for(var i,t=arguments.length,a=Array(t>1?t-1:0),o=1;o<t;o++)a[o-1]=arguments[o];a.length||(a=[this]),(i=DiviArea).doAction.apply(i,[[e,e+"_"+this.theKey()]].concat(r(a)))},this.applyFilters=function(e,i){for(var t=arguments.length,a=Array(t>2?t-2:0),o=2;o<t;o++)a[o-2]=arguments[o];var n;return a.length||(a=[this]),(n=DiviArea).applyFilters.apply(n,[[e,e+"_"+this.theKey()],i].concat(r(a)))},this.addFilter=function(e,i,t,a){DiviArea.addFilter(e+"_"+this.theKey(),i,t,a)},this.addAction=function(e,i,t,a){DiviArea.addAction(e+"_"+this.theKey(),i,t,a)},this.removeFilter=function(e,i){DiviArea.removeFilter(e+"_"+this.theKey(),i)},this.removeAction=function(e,i){DiviArea.removeAction(e+"_"+this.theKey(),i)},this.addActionOnce=function(e,i,t,a){DiviArea.addActionOnce(e+"_"+this.theKey(),i,t,a)},this.hasClass=n.hasClass.bind(n),this.addClass=n.addClass.bind(n),this.removeClass=n.removeClass.bind(n),this.attr=n.attr.bind(n),this.removeAttr=n.removeAttr.bind(n),this.find=n.find.bind(n),D=D.bind(this),g=g.bind(this),A=A.bind(this),h=h.bind(this),m=m.bind(this),y=y.bind(this),b=b.bind(this),C=C.bind(this),_=_.bind(this),k=k.bind(this),x=x.bind(this),D()}},function(e,i,t){"use strict";!function(e){DiviArea.init=function(i){var t=[window.location.protocol,"//",window.location.host,"/wp-admin/edit.php?post_type=divi-area&page=settings#frontend"];this.app=i?"Divi Areas Pro":"Popups for Divi",this.lib=i?"DiviArea":"DiviPopup",this.version="1.2.4",this.info=this.lib+"-"+this.version,this.loaded=!0,DiviArea.Debug.info("🚀 Initialize "+this.app,"- JS API:",this.info),i?DiviArea.Debug.info("ℹ️ You can disable the debug output on the Settings page:",t.join("")):DiviArea.Debug.info("ℹ️ You can disable the debug output by disabling WP_DEBUG"),DiviArea.Debug.debug("Details about the Debug Mode","https://divimode.com/knowledge-base/debug-options/"),DiviArea.Utils.init(),DiviArea.Utils.getOption("initializeOnEvent")?e(window,document).one(DiviArea.Utils.getOption("initializeOnEvent"),function(){window.setTimeout(DiviArea.Core.init,1)}):window.setTimeout(DiviArea.Core.init,1)},DiviArea.markClosed=function(e,i){if(DiviArea.Utils.getOption("debug")){var t=DiviArea.Data.sanitizeId(e);DiviArea.Debug.info("📌 Mark Area as closed for "+i+" minutes:",t)}DiviArea.Utils.setLocalData(e,"1",i)},DiviArea.isClosed=function(e){e=e.toLowerCase().replace(/^#/,"");var i=DiviArea.Utils.getLocalData(e);if(DiviArea.Utils.getOption("debug")){var t=DiviArea.Data.sanitizeId(e);"1"===i?DiviArea.Debug.info("📌 Area is still closed:",t):DiviArea.Debug.info("📌 Area is not closed:",t)}return"1"===i},DiviArea.register=function(i){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(!(i=DiviArea.Data.sanitizeId(i)))return!1;var r=DiviArea.getArea(i);if(r)return r;var o=e(i);if(o.length&&t.selector&&(o=o.filter(t.selector),delete t.selector),1!==o.length)return!1;if(!a){if(o.data("da-type"))a=o.data("da-type"),o.removeAttr("data-da-type");else if(o.data("type"))a=o.data("type"),o.removeAttr("data-type");else for(var n=o[0].className.split(/\s+/),s=0;s<n.length;s++)if(0===n[s].indexOf("divi-area-type-")){a=n[s].replace("divi-area-type-",""),o.removeClass(n[s]);break}if(!a)return!1}DiviArea.Debug.group("Register Area | "+a+" | "+i);var l=DiviArea.Data.createArea(o,a,i);return t.alternateid?DiviArea.Data.addAltId(l.theId(),t.alternateid):t.alternateId?DiviArea.Data.addAltId(l.theId(),t.alternateId):t.ids&&DiviArea.Data.addAltId(l.theId(),t.ids),delete t.alternateid,delete t.alternateId,delete t.ids,Object.keys(t).forEach(function(e){l.setData(e,t[e])}),l.setData("wrap-classes","et-l entry-content"),l.isType("inline")&&l.getData("static")?(DiviArea.Core.initContainer(l),DiviArea.show(i)):(l.detach(),l.setData("container",DiviArea.Core.getContext())),DiviArea.Debug.info("➕ Registered new area:",i,"("+a+")"),DiviArea.Debug.group(),l.doAction("init_area"),l},DiviArea.show=function(e,i){var t=DiviArea.getArea(e);return t?DiviArea.Utils.showOnViewport(t)?(DiviArea.Debug.group("Show area",t.theId()),t.setData("hasShowAnim",!t.isVisible()),DiviArea.Core.attachArea(t),t.isType("hover")&&(t.setTriggerEvent(i),DiviArea.Core.setupHoverArea(t)),DiviArea.Core.reOrderAreas(),DiviArea.Debug.group(),!0):(DiviArea.Debug.debug("Do not trigger area on this device:",t.theId()),!1):(DiviArea.Debug.error("Could not find an area with the ID:",e),!1)},DiviArea.hide=function(e){var i=DiviArea.Data.getVisibleArea(e);i&&(i.setData("hasShowAnim",!0),DiviArea.Debug.debug("Close area and unlink event handlers:",i.theId()),DiviArea.Core.detachArea(i)),DiviArea.Core.reOrderAreas()}}(jQuery)},function(e,i,t){"use strict";!function(e){DiviArea.Core=DiviArea.Core||{};var i=window.ResizeObserver||window.WebKitResizeObserver,t=null,a=null,r=!1,o=!1;function n(e,i){DiviArea.Core.isArea(e)||(e=DiviArea.Data.getVisibleArea())&&(DiviArea.Debug.debug("Close the top-most area"),e.doAction("close_area",e,"default"))}function s(e){if(27===e.keyCode)return function(){DiviArea.Debug.info("⚡️ ESC-key pressed");var e=!1;return DiviArea.Data.countVisibleAreas("popup")?(e=DiviArea.applyFilters("ignore_esc_key",e))?(DiviArea.Debug.debug("Ignored, manually cancelled in filter"),!0):(DiviArea.Debug.debug("Close top-most popup"),DiviArea.doAction("close_area",null,"esc"),!1):(DiviArea.Debug.debug("Ignored, no popup is visible"),!0)}()}function l(){var e=["popup","flyin"],i=!1;function t(e,t){i||e.getData("triggerexit")&&(DiviArea.isClosed(t)?e.setData("triggerexit",!1):DiviArea.show(t)&&(e.setData("triggerexit",!1),i=!0))}for(var a in e)i=!1,DiviArea.Data.loopAllAreas(e[a],t)}function d(e,i){var t=[];if(i.isType("popup")&&"show"===e&&i.getData("singleton")&&DiviArea.Data.loopVisibleAreas("popup",function(e){t.push(e.theId())}),"hide"===e?i.doAction("before_hide_area",i,t):i.doAction("before_show_area",i,t),t.length)for(var a in DiviArea.Debug.debug("Hide following areas:",t),t){var r=DiviArea.getArea(t[a]);r&&r.inDom()&&DiviArea.Core.detachArea(r)}}function c(i,t){var a;if(a=DiviArea.Data.sanitizeId(t))if(i.attr("data-area-id"))DiviArea.Debug.debug("Trigger already prepared",i[0]);else if(DiviArea.getArea(a)){var r=DiviArea.Utils.getOption("hoverTriggerClass"),o=DiviArea.Utils.getOption("clickTriggerClass");i.attr("data-area-id",a),i.addClass("popup-trigger"),i.off("click"),i.hasClass(r)&&(i.on("mouseover._da",n),DiviArea.Debug.debug("Prepared Hover trigger to open this area:",a,i[0])),i.hasClass(r)&&!i.hasClass(o)||(i.on("click._da",n),DiviArea.Debug.debug("Prepared Click trigger to open this area:",a,i[0]))}else DiviArea.Debug.debug("Ignore trigger. No area found with this ID:",i[0]);else DiviArea.Debug.debug("Ignore trigger. Invalid target ID:",t,i[0]);function n(i){var t=e(i.target);return!("A"!==t.prop("tagName")||!t.attr("href").length||t.attr("data-area-id"))||(i.preventDefault(),DiviArea.Debug.debug("Trigger area:",a),DiviArea.show(a,i),!1)}}function u(i){var t=e(i.target).closest("[data-da-type][data-da-registered]"),a=DiviArea.Utils.getOption("fullHeightClass");return!(!t.length||!t.hasClass(a))||(i.preventDefault(),i.stopPropagation(),!1)}DiviArea.Core.init=function(){r?DiviArea.Debug.error("Core.init() was already executed. It should not run twice, please review the code!"):(r=!0,DiviArea.Debug.debug("Initialize the app"),DiviArea.doAction("load"),(t=e(DiviArea.Utils.getOption("baseContext")).filter(":visible").first()).length?(t.closest("#et-boc").length||(t.append('<div id="et-boc"></div>'),t=t.find("#et-boc").first()),DiviArea.Debug.debug('Base context "'+DiviArea.Utils.getOption("baseContext")+'" found',t)):DiviArea.Debug.error('Could not find the popup container "'+DiviArea.Utils.getOption("baseContext")+'"'),function(){var i=e(".et_pb_fullscreen_nav_container #mobile_menu_slide");if(!i.length)return;i.parent().css({minHeight:i.outerHeight()})}(),window.setTimeout(function(){e(window).on("mouseleave.da",function(e){var i;"input"!==e.target.tagName.toLowerCase()&&"textarea"!==e.target.tagName.toLowerCase()&&"select"!==e.target.tagName.toLowerCase()&&(i=Math.max(document.documentElement.clientWidth,window.innerWidth||0),e.clientX>=i-50||e.clientY>=50||e.toElement||e.relatedTarget||(DiviArea.Debug.info("⚡️ Exit-intent detected (mouse leave)"),DiviArea.doAction("exit_intent","mouse-leave")))}),DiviArea.addAction("exit_intent",l)},DiviArea.Utils.getOption("onExitDelay")),DiviArea.addAction("ready",function(){DiviArea.addAction("close_area",n),function(e){var i=window.MutationObserver||window.WebKitMutationObserver,t=window.addEventListener,a=DiviArea.Core.getContext(),r=!1;function o(){r||(r=setTimeout(function(){r=!1,DiviArea.Debug.debug("DOM changed"),e()},50))}if(i){var n=new i(function(e,i){if(e[0].addedNodes.length||e[0].removedNodes.length)return o()});n.observe(a[0],{childList:!0,subtree:!0})}else t&&(a.addEventListener("DOMNodeInserted",o,!1),a.addEventListener("DOMNodeRemoved",o,!1))}(DiviArea.Core.activateContainer),e(document).on("keyup",s)},1),DiviArea.addAction("ready",function(){DiviArea.Core.activateContainer()},10),DiviArea.doAction("ready"))},DiviArea.Core.isArea=function(e){return e&&e instanceof DiviAreaItem},DiviArea.Core.getContext=function(){return t},DiviArea.Core.reOrderAreas=function(){if(DiviArea.Data.countVisibleAreas("popup")||DiviArea.hideOverlay(),DiviArea.Data.countVisibleAreas()){var e=DiviArea.Utils.getOption("zIndex"),i=DiviArea.Data.countVisibleAreas("not: inline"),t=DiviArea.Data.countVisibleAreas("popup"),a=[],r=0,o=0,n={};if(DiviArea.Debug.debug("Refresh the z-index of visible areas"),DiviArea.Data.loopVisibleAreas("any",DiviArea.Core.blurArea),DiviArea.Core.focusArea(DiviArea.Data.getVisibleArea()),DiviArea.Data.loopVisibleAreas("not: inline",function(a){var s=0;a.isType("popup")?(s=e+i-t+ ++o,a.hasClass(DiviArea.Utils.getOption("activePopupClass"))&&(n.overlay=s,s+=1)):s=e+ ++r,n[a.theId()]=s}),(n=DiviArea.applyFilters("reorder_areas",n)).overlay&&!isNaN(n.overlay)){var s=DiviArea.showOverlay(n.overlay);a.push({id:"-",type:"overlay","z-index":s})}for(var l in n)d(l);DiviArea.Debug.info("👓 List of visible Areas:"),DiviArea.Debug.table(a)}function d(e){if("overlay"!==e){var i=DiviArea.getArea(e);if(i){var t=n[e];t&&!isNaN(t)&&i.setData("zindex",t),i.isType("popup")&&i.attach(),a.push({id:i.theId(),type:i.theType(),"z-index":i.getData("zindex")||null})}}}},DiviArea.Core.activateContainer=function(i){var t,a=void 0===i,r=void 0;if(void 0===i?i=e("body"):DiviArea.Core.isArea(i)&&(i=i.get()),function(i){i.find(DiviArea.Utils.getOption("popupSelector")).not("[data-da-area]").filter("[id]").each(function(){var i=e(this);DiviArea.Debug.debug("Found an inline Popup Area:",i.attr("id")),DiviArea.register(i,{},"popup")})}(i),(t=function(i,t){var a,r,o,n=[];if(!i.ids||!i.ids.length)return[];function s(i,t){var a;for(a=0;a<t.length;a++){var r=e(t[a]);r.attr("data-area-id")||(r.attr("data-da-area")||r.hasClass("divi-area-wrap")||r.hasClass("et_pb_section")&&r.hasClass("popup")||n.push({id:i,item:r}))}}for(a=0;a<i.ids.length;a++){var l="#"+(o=i.ids[a].replace(/^#/,"")),d=i.linkPrefix?"#"+i.linkPrefix+o:"",c="."+o,u=i.classPrefix?"."+i.classPrefix+o:"",v=i.dataAttrib?i.dataAttrib+'="'+o+'"':"";if(s(o,e('[href="'+l+'"]',t)),d&&s(o,e('[href="'+d+'"]',t)),s(o,e(c,t)),u&&s(o,e(u,t)),v&&s(o,e("["+v+"]",t)),window.et_link_options_data)for(r=et_link_options_data.length-1;r>=0;r--)if(l===et_link_options_data[r].url||d===et_link_options_data[r].url){var p=e("."+et_link_options_data[r].class,t);s(o,p),p.off("click"),et_link_options_data.splice(r,1)}}return n}({ids:DiviArea.listAreas(),linkPrefix:"popup:",dataAttrib:DiviArea.Utils.getOption("idAttrib"),classPrefix:DiviArea.Utils.getOption("triggerClassPrefix")},i)).length){for(a?DiviArea.Debug.group("Activate all triggers in document"):DiviArea.Debug.group("Activate triggers in area",i.attr("id")),r=0;r<t.length;r++){var o=t[r];c(o.item,o.id)}DiviArea.Debug.group()}else a?DiviArea.Debug.debug("No new triggers found in document"):DiviArea.Debug.debug("No new triggers found in area",i.attr("id"));DiviArea.Core.initContainer(i)},DiviArea.Core.initContainer=function(i){var t=!1,a=!1;return DiviArea.Core.isArea(i)?(t=i,i=i.get()):i.data("is-area")&&(t=i.getArea()),t&&(a=t.getData("post_id")),t&&!0===i.data("area-init-done")||(t&&i.data("area-init-done",!0),e("body").trigger("post-load"),void 0!==window.et_fix_pricing_currency_position&&window.et_fix_pricing_currency_position(i.find(".et_pb_pricing_table")),a&&i.find(".et_pb_newsletter_form").length&&i.find(".et_pb_newsletter_form [name=et_pb_signup_post_id]").val(a),function(e){if(!window.grecaptcha)return;if(!e.find('input[name="g-recaptcha-response"]').length)return;if(e.find("[data-sitekey].g-recaptcha").length>0){if(!grecaptcha.render)return;e.find("form").each(function(){var e=jQuery(this),i=e.find("[data-sitekey].g-recaptcha");if(i.length&&!e.find('iframe[src*="/recaptcha/"]').length){var t={sitekey:i.attr("data-sitekey"),type:i.attr("data-type"),size:i.attr("data-size"),theme:i.attr("data-theme"),badge:i.attr("data-badge"),tabindex:i.attr("data-tabindex")},a=i.attr("data-callback"),r=i.attr("data-expired-callback");a&&"function"==typeof window[a]&&(t.callback=window[a]),r&&"function"==typeof window[r]&&(t["expired-callback"]=window[r]);var o=grecaptcha.render(i[0],t);window.recaptchaWidgets&&recaptchaWidgets.push(o)}})}else{if(!grecaptcha.execute)return;var i=jQuery('script[src*="google.com/recaptcha/api.js"]').attr("src"),t=i.replace(/^.*render=(.*)$/,"$1").split("&")[0];grecaptcha.execute(t,{action:"homepage"}).then(function(i){e.find('form [name="g-recaptcha-response]').val(i)})}}(i)),void 0!==window.et_reinit_waypoint_modules&&window.et_reinit_waypoint_modules(),i},DiviArea.Core.deactivateContainer=function(i){DiviArea.Core.isArea(i)&&(DiviArea.Debug.debug("Deactivate all triggers in area",i.theId()),i.find("[data-area-id]").each(function(){!function(e){DiviArea.Debug.debug("Remove trigger:",e[0]),e.removeAttr("data-area-id"),e.removeClass("popup-trigger"),e.off("._da")}(e(this))}))},DiviArea.Core.attachArea=function(e){o||(o=!0,d("show",e),o=!1),DiviArea.Data.addVisibleArea(e),e.attach()},DiviArea.Core.detachArea=function(e){if(o||(o=!0,d("hide",e),o=!1),e.inDom()){if(!DiviArea.Core.isArea(e)||!e.inDom())return;e.removeClass("__is_animating"),DiviArea.Data.removeVisibleArea(e),DiviArea.Core.blurArea(e),e.detach()}},DiviArea.Core.focusArea=function(e){var i=DiviArea.Utils.getOption("activePopupClass");e&&(!function(e){a&&!e.data("observe-resize")&&(a.observe(e[0]),e.data("observe-resize",!0))}(e.get()),DiviArea.Core.activateContainer(e),e.hasClass(i)||(e.addClass(i),e.doAction("focus_area")))},DiviArea.Core.blurArea=function(e){var i=DiviArea.Utils.getOption("activePopupClass");e&&(!function(e){a&&e.data("observe-resize")&&(a.unobserve(e[0]),e.data("observe-resize",!1))}(e.get()),DiviArea.Core.deactivateContainer(e),e.hasClass(i)&&(e.removeClass(i),e.doAction("blur_area")))},DiviArea.Core.setupHoverArea=function(t){var a=t.getData("attachto"),r=t.get(),o=t.getWrap();if(a.length){var n=DiviArea.Utils.isPosition(a,"fixed"),s=t.theId(),l=t.getData("closeTrigger"),d=1e3*t.getData("closedelay"),c=!1,u=!1,v=!1;i&&(v=new i(function(e){var i=!0,t=!1,a=void 0;try{for(var r,o=e[Symbol.iterator]();!(i=(r=o.next()).done);i=!0){var n=r.value.contentRect,s=n.width+"-"+n.height;s!==u&&(u=s,f())}}catch(e){t=!0,a=e}finally{try{!i&&o.return&&o.return()}finally{if(t)throw a}}},{box:"border-box"})),v&&v.observe(a[0]),"click"===l?e(document).on("click."+t.theKey(),function(i){e(i.target).closest(s).length||D()}):"hover"===l&&(r.on("mouseleave._dah",D),a.on("mouseleave._dah",D)),a.on("mouseenter._dah",g),r.on("mouseenter._dah",g),t.addActionOnce("show_area",p),DiviArea.Debug.debug("Prepared positioning of hover area")}else DiviArea.Debug.error("Hover Area without alignment element found");function p(){DiviArea.Debug.info("📐 Position area relative to element:",a),f()}function f(){var e=n?a[0].getBoundingClientRect():DiviArea.Utils.getClientRect(a),i=t.getData("positionv"),r=t.getData("positionh"),s=t.getSize(),l={left:"",top:"",right:"",bottom:"",width:"",height:"",position:n?"fixed":"absolute"};"top"===i||"bottom"===i?(l.top="top"===i?e.top-s.height:e.bottom,l.left=e.left+e.width/2-s.width/2):"left"===r||"right"===r?(l.left="left"===r?e.left-s.width:e.right,l.top=e.top+e.height/2-s.height/2):DiviArea.Debug.error("Invalid position",t.getData("position")),l.top<0&&(l.top=0),l.left<0&&(l.left=0),l.left+s.width>window.innerWidth&&(l.left=window.innerWidth-s.width),DiviArea.Debug.debug("Area position:",l),o.css(l)}function D(){g(),c=window.setTimeout(function(){v&&v.disconnect(),e(document).off("."+t.theKey()),r.off("._dah"),a.off("._dah"),DiviArea.hide(t)},d)}function g(){c&&window.clearTimeout(c),c=!1}},DiviArea.Core.disableBodyScroll=function(){var i=e("body");!0!==i.data("da-disable-scroll")&&(i.data("da-disable-scroll",!0),i.addClass(DiviArea.Utils.getOption("openPopupClass")),DiviArea.Utils.bindPassiveEvent([i,DiviArea.getOverlay()],"mousewheel touchmove",u),DiviArea.doAction("disabled_scrolling"))},DiviArea.Core.enableBodyScroll=function(){var i=e("body");!0===i.data("da-disable-scroll")&&(i.data("da-disable-scroll",!1),i.removeClass(DiviArea.Utils.getOption("openPopupClass")),DiviArea.Utils.unbindPassiveEvent([i,DiviArea.getOverlay()],"mousewheel touchmove",u),DiviArea.doAction("enabled_scrolling"))},DiviArea.Core.closeMainMenu=function(){e(".et_pb_fullscreen_menu_active").length?e(".et_toggle_fullscreen_menu").first().trigger("click"):e(".et_pb_slide_menu_active").length&&e(".et_toggle_slide_menu").first().trigger("click")}}(jQuery)},function(e,i,t){"use strict";!function(e){DiviArea.Data=DiviArea.Data||{};var i={},t=[],a={};DiviArea.Data.sanitizeId=function(e,i){if(!e)return"";if(e instanceof DiviAreaItem)return e.theId();if(e instanceof jQuery)return"#"+e.attr("id");if(e){if(i){var t=new RegExp("^#"+i+":");e=e.replace(t,"#",e)}"#"!==e[0]&&(e="#"+e)}return e.length>1?e:""},DiviArea.Data.getRealId=function(e){var t=DiviArea.Data.sanitizeId(e),r=DiviArea.Data.sanitizeId(a[t]);return t&&void 0!==i[t]?t:r&&void 0!==i[r]?r:""},DiviArea.Data.addAltId=function(e,i){function t(i){i=DiviArea.Data.sanitizeId(i),e!==i&&(null===e?delete a[i]:a[i]=e)}e=DiviArea.Data.sanitizeId(e),Array.isArray(i)?i.forEach(function(e){return t(e)}):t(i)},DiviArea.Data.getArea=function(e){if(e instanceof DiviAreaItem)return e;e instanceof jQuery&&(e=e.attr("id"));var t=DiviArea.Data.getRealId(e);return!!t&&i[t]},DiviArea.Data.createArea=function(e,t,a){return a=DiviArea.Data.sanitizeId(a),i[a]=new DiviAreaItem(e,t),i[a]},DiviArea.Data.getAllIds=function(e){var t=[];if(DiviArea.Core.isArea(e)){var r=e.theId();for(var o in t.push(r),a)r===a[o]&&t.push(o)}else{for(var n in i){i[n].isType(e)&&t.push(n)}for(var s in a){var l=a[s];i[l].isType(e)&&t.push(s)}}return t},DiviArea.Data.loopAllAreas=function(e,t){for(var a in i){var r=i[a];r.isType(e)&&t(r,a)}},DiviArea.Data.countVisibleAreas=function(e){if(!e||"any"===e)return t.length;var i=0;return DiviArea.Data.loopVisibleAreas(e,function(){return i++}),i},DiviArea.Data.addVisibleArea=function(e){if(!(e=DiviArea.getArea(e)))return!1;if(e.isType("popup")||!DiviArea.Data.countVisibleAreas("popup"))t.push(e);else for(var i=0;i<t.length;i++)if(t[i].isType("popup")){t.splice(i,0,e);break}},DiviArea.Data.removeVisibleArea=function(e){if(!(e=DiviArea.getArea(e)))return!1;for(var i=e.theId(),a=t.length-1;a>=0;a--){t[a].theId()===i&&t.splice(a,1)}},DiviArea.Data.getVisibleArea=function(e,i){var a=t.length-1;if(!e&&!i)return t[a];if(e){var r=DiviArea.getArea(e);return!!r&&(!!r.isType(i)&&(!!r.isVisible()&&r))}for(var o=a;o>=0;o--){var n=t[o];if(n.isType(i))return n}return!1},DiviArea.Data.loopVisibleAreas=function(e,i,a){for(var r=t.length,o=a?r-1:0,n=0;n<r;n++){var s=t[o];o+=a?-1:1,s.isType(e)&&i(s,n)}}}(window.jQuery)},function(e,i,t){"use strict";!function(e){var i=null,t=!1;function a(e){DiviArea.Debug.info("⚡️ Click on background overlay"),e.preventDefault(),DiviArea.doAction("click_overlay");var i=DiviArea.Data.getVisibleArea(null,"popup");return i?i.getData("ismodal")?(DiviArea.Debug.debug("Ignore click:",'Top-most popup is marked as "modal"'),!1):DiviArea.applyFilters("ignore_overlay_click",!1)?(DiviArea.Debug.debug("Ignore click:","Manually cancelled via filter"),!1):(DiviArea.doAction("close_area",null,"overlay"),DiviArea.Data.countVisibleAreas("popup")||DiviArea.hideOverlay(),!1):(DiviArea.Debug.debug("Ignore click:","No visible Popups found"),!1)}DiviArea.showOverlay=function(r){return null===i&&((i=e("<div />")).addClass(DiviArea.Utils.getOption("overlayClass")),i.on("click.popup",a),DiviArea.doAction("init_overlay",i)),r&&!isNaN(r)||(r=DiviArea.Utils.getOption("zIndex"),r+=Math.max(0,DiviArea.Data.countVisibleAreas())),i.css({zIndex:r}),t||(t=!0,DiviArea.Debug.info("⤴️ Show background overlay"),i.detach().appendTo(DiviArea.Core.getContext()),i.fadeIn(DiviArea.Utils.getOption("animateSpeed"),function(){t&&DiviArea.Core.disableBodyScroll()}),DiviArea.doAction("show_overlay",i),DiviArea.Core.closeMainMenu()),r},DiviArea.hideOverlay=function(){t&&(t=!1,DiviArea.Debug.info("⤵️ Hide background overlay"),i.hide().detach(),DiviArea.Core.enableBodyScroll(),DiviArea.doAction("hide_overlay",i))},DiviArea.getOverlay=function(){return i}}(jQuery)},function(e,i,t){"use strict";!function(){DiviArea.UI=DiviArea.UI||{};var e={};function i(e,i,t){t=t||e.data("et_waypoint_max_instances")||1;var a=e.data("et_waypoint")||[];if(a.length<t){var r=e.waypoint(i);r&&r.length>0&&(a.push(r[0]),e.data("et_waypoint",a))}else for(var o=0;o<a.length;o++)a[o].context.refresh()}DiviArea.UI.animateArea=function(t,a,r){var o=!1,n=!1;window.TweenLite&&t.isType("flyin")&&(n=!0),"function"!=typeof r&&(r=function(){}),"hide"!==a||t.isType("flyin")?(t.hasClass("et_pb_section")&&jQuery.fn.waypoint&&"yes"!==et_pb_custom.ignore_waypoints&&function(t){var a=t.attr("data-animation"),r=!1;if(!a)return!1;if(!(r=e[a]))return!1;jQuery("body").css("overflow-x","hidden"),jQuery("#page-container").css("overflow-y","hidden"),t.attr({"data-animation-style":r.style,"data-animation-repeat":"once"===r.repeat?"":"infinite","data-animation-duration":r.duration,"data-animation-delay":r.delay,"data-animation-intensity":r.intensity,"data-animation-starting-opacity":r.starting_opacity,"data-animation-speed-curve":r.speed_curve}),i(t,{offset:"100%",handler:function(){!function(e){var i=e.attr("data-animation-style"),t=e.attr("data-animation-repeat"),a=e.attr("data-animation-duration"),r=e.attr("data-animation-delay"),o=e.attr("data-animation-intensity"),n=e.attr("data-animation-starting-opacity"),s=e.attr("data-animation-speed-curve");!function(e){for(var i=[],t=e.get(0).attributes,a=0;a<t.length;a++)"data-animation-"===t[a].name.substring(0,15)&&i.push(t[a].name);jQuery.each(i,function(i,t){e.removeAttr(t)})}(e);var l=isNaN(parseInt(n))?0:.01*parseInt(n);-1===jQuery.inArray(s,["linear","ease","ease-in","ease-out","ease-in-out"])&&(s="ease-in-out"),e.css({"animation-duration":a,"animation-delay":r,opacity:l,"animation-timing-function":s});for(var d={},c=isNaN(parseInt(o))?50:parseInt(o),u=["slide","zoom","flip","fold","roll"],v=!1,p=!1,f=0;f<u.length;f++){var D=u[f];if(i&&i.substr(0,D.length)===D){v=D,""!==(p=i.substr(D.length,i.length))&&(p=p.toLowerCase());break}}!1!==v&&!1!==p&&(d=function(e,i,t){var a={};switch(e){case"slide":switch(i){case"top":a={transform:"translate3d(0, "+(r=-2*t)+"%, 0)"};break;case"right":a={transform:"translate3d("+(r=2*t)+"%, 0, 0)"};break;case"bottom":a={transform:"translate3d(0, "+(r=2*t)+"%, 0)"};break;case"left":var r=-2*t;a={transform:"translate3d("+r+"%, 0, 0)"};break;default:a={transform:"scale3d("+(o=.01*(100-t))+", "+o+", "+o+")"}}break;case"zoom":var o=.01*(100-t);switch(i){case"top":case"right":case"bottom":case"left":default:a={transform:"scale3d("+o+", "+o+", "+o+")"}}break;case"flip":switch(i){case"right":a={transform:"perspective(2000px) rotateY("+(n=Math.ceil(.9*t))+"deg)"};break;case"left":a={transform:"perspective(2000px) rotateY("+(n=-1*Math.ceil(.9*t))+"deg)"};break;case"top":default:a={transform:"perspective(2000px) rotateX("+(n=Math.ceil(.9*t))+"deg)"};break;case"bottom":a={transform:"perspective(2000px) rotateX("+(n=-1*Math.ceil(.9*t))+"deg)"}}break;case"fold":switch(i){case"top":a={transform:"perspective(2000px) rotateX("+(n=-1*Math.ceil(.9*t))+"deg)"};break;case"bottom":a={transform:"perspective(2000px) rotateX("+(n=Math.ceil(.9*t))+"deg)"};break;case"left":a={transform:"perspective(2000px) rotateY("+(n=Math.ceil(.9*t))+"deg)"};break;case"right":default:a={transform:"perspective(2000px) rotateY("+(n=-1*Math.ceil(.9*t))+"deg)"}}break;case"roll":switch(i){case"right":case"bottom":a={transform:"rotateZ("+(n=-1*Math.ceil(3.6*t))+"deg)"};break;case"top":case"left":a={transform:"rotateZ("+(n=Math.ceil(3.6*t))+"deg)"};break;default:var n=Math.ceil(3.6*t);a={transform:"rotateZ("+n+"deg)"}}}return a}(v,p,c)),jQuery.isEmptyObject(d)||e.css(d),e.addClass("et_animated"),e.addClass(i),e.addClass(t)}(jQuery(this.element))}})}(t.get())&&(o=!0),n?function(e,i,t){DiviArea.Debug.debug("Animate Area using GSAP");var a=DiviArea.Utils.getOption("animateSpeed"),r={},o={},n=e.get();n.css({opacity:"show"===i?0:1,transition:"all 0s"}),n.show(),window.setTimeout(function(){"left"===e.getData("positionh")?(r.left=-1*n.outerWidth(),o.left=0):"right"===e.getData("positionh")?(r.right=-1*n.outerWidth(),o.right=0):"top"===e.getData("positionv")?(r.top=-1*n.outerHeight(),o.top=0):"bottom"===e.getData("positionv")&&(r.bottom=-1*n.outerHeight(),o.bottom=0),r.opacity=1,o.opacity=1,"hide"===i?(n.css(o),TweenLite.to(n,a/1e3,{css:r})):(n.css(r),TweenLite.to(n,a/1e3,{css:o})),window.setTimeout(t,a)},5)}(t,a,r):o?function(e,t,a){DiviArea.Debug.debug("Animate Area using a Divi Animation");var r=e.get();r.show(),r.css({opacity:0}),window.setTimeout(function(){r.css({opacity:""}),i(r,{offset:"100%",handler:function(){r.addClass("et-animated"),a()}},2)},10)}(t,0,r):function(e,i,t){var a=e.get(),r=DiviArea.Utils.getOption("animateSpeed");"show"===i?(DiviArea.Debug.debug("Animate Area using jQuery fadeIn",r),a.fadeIn(r,t)):"hide"===i&&(DiviArea.Debug.debug("Animate Area using jQuery fadeOut",r),a.fadeOut(r,t))}(t,a,r)):r()},DiviArea.UI.initializeAreaAnimation=function(i){if(!window.et_animation_data||!window.et_animation_data.length>0)return!1;i.removeClass("et-waypoint"),i.removeClass("et-animated");for(var t=0;t<et_animation_data.length;t++){var a=!1,r=et_animation_data[t];r&&(r.class&&i.hasClass(r.class)&&r.style&&r.repeat&&r.duration&&r.delay&&r.intensity&&r.starting_opacity&&r.speed_curve&&(a=r.class,i.addClass("pfd-waypoint"),i.attr("data-animation",a),e[a]=r,et_animation_data[t].class=void 0))}}}()},function(e,i,t){"use strict";!function(){DiviArea.Debug=DiviArea.Debug||{};var e=!1,i=window.DiviAreaConfig;DiviArea.Debug.group=function(t){if(i.debug&&console.group){var a=!e||t&&t!==e;if(e&&(console.groupEnd(),e=!1),t&&a){var r=Array.prototype.slice.call(arguments);r.unshift("[DiviAreas]"),console.group.apply(this,r),e=t}}},DiviArea.Debug.table=function(){if(i.debug){var e=Array.prototype.slice.call(arguments);Array.isArray(e[0])||(e=[e]),console.table?console.table.apply(this,e):console.log.apply(this,e)}},DiviArea.Debug.verbose=function(){if(i.debug&&i.debugVerbose){var e=Array.prototype.slice.call(arguments);e.unshift("color:#cfd8dc;font-style:italic"),e.unshift("[DiviAreas] %c%s"),console.debug.apply(this,e)}},DiviArea.Debug.debug=function(){if(i.debug){var e=Array.prototype.slice.call(arguments);e.unshift("color:#90a4ae"),e.unshift("[DiviAreas] %c%s"),console.debug.apply(this,e)}},DiviArea.Debug.info=function(){if(i.debug){var e=Array.prototype.slice.call(arguments);e.unshift("color:#0288d1;background:#fafcfe"),e.unshift("[DiviAreas] %c%s"),console.log.apply(this,e)}},DiviArea.Debug.error=function(){var e=Array.prototype.slice.call(arguments);e.unshift("[DiviAreas]"),console.error.apply(this,e)},DiviArea.Debug.sysInfo=function(){var e=["\n----------"];if(e.push("Please copy-paste this information into your support ticket:"),e.push("----------\n"),DiviArea.lib&&DiviArea.version&&e.push(" • js_api: "+DiviArea.lib+" "+DiviArea.version),window.DiviAreaConfig&&DiviAreaConfig.sys&&DiviAreaConfig.sys.plugin)for(var i in DiviAreaConfig.sys)try{e.push(" • "+i+": "+" ".repeat(Math.max(0,11-i.length))+DiviAreaConfig.sys[i])}catch(e){}return e.push(" • browser: "+navigator.userAgent),e.push("\n----------\n"),e.join("\n")}}(),function(){var e=!0,i={};i.silent=DiviArea.Hooks.silent,i.removeFilter=DiviArea.Hooks.removeFilter,i.removeAction=DiviArea.Hooks.removeAction,i.applyFilters=DiviArea.Hooks.applyFilters,i.doAction=DiviArea.Hooks.doAction,i.addFilter=DiviArea.Hooks.addFilter,i.addAction=DiviArea.Hooks.addAction,i.addActionOnce=DiviArea.Hooks.addActionOnce,DiviArea.Hooks.silent=function(){return e=!1,i.silent.apply(this,arguments)},DiviArea.removeFilter=DiviArea.Hooks.removeFilter=function(t){return e&&DiviArea.Debug.debug("Remove Filter:",t),e=!0,i.removeFilter.apply(this,arguments)},DiviArea.removeAction=DiviArea.Hooks.removeAction=function(t){return e&&DiviArea.Debug.debug("Remove Action:",t),e=!0,i.removeAction.apply(this,arguments)},DiviArea.applyFilters=DiviArea.Hooks.applyFilters=function(t){if(e){Array.isArray(t)||(t=[t]),DiviArea.Debug.info("📢️ Apply Filters:",t.join(" → "));for(var a=0;a<t.length;a++)DiviArea.Debug.debug(' ⚙ DiviArea.addFilter("'+t[a]+'", callback)')}return e=!0,i.applyFilters.apply(this,arguments)},DiviArea.doAction=DiviArea.Hooks.doAction=function(t){if(e){Array.isArray(t)||(t=[t]),DiviArea.Debug.info("📢️ Do Action:",t.join(" → "));for(var a=0;a<t.length;a++)DiviArea.Debug.debug(' ⚙ DiviArea.addAction("'+t[a]+'", callback)')}return e=!0,i.doAction.apply(this,arguments)},DiviArea.addFilter=DiviArea.Hooks.addFilter=function(t){return e&&DiviArea.Debug.debug("Add Filter:",t),e=!0,i.addFilter.apply(this,arguments)},DiviArea.addAction=DiviArea.Hooks.addAction=function(t){return e&&DiviArea.Debug.debug("Add Action:",t),e=!0,i.addAction.apply(this,arguments)},DiviArea.addActionOnce=DiviArea.Hooks.addActionOnce=function(t){return e&&DiviArea.Debug.debug("Add Action Once:",t),e=!0,i.addActionOnce.apply(this,arguments)}}()},function(e,i,t){"use strict";var a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};DiviArea.openPopup=function(e){DiviArea.Debug.error("DiviArea.openPopup() is deprecated. Please use DiviArea.show() instead"),DiviArea.show(e)},DiviArea.openArea=function(e){DiviArea.Debug.error("DiviArea.openArea() is deprecated. Please use DiviArea.show() instead"),DiviArea.show(e)},DiviArea.closePopup=function(e){DiviArea.Debug.error("DiviArea.closeArea() is deprecated. Please use DiviArea.hide() instead"),DiviArea.hide(e)},DiviArea.closeArea=function(e){DiviArea.Debug.error("DiviArea.closeArea() is deprecated. Please use DiviArea.hide() instead"),DiviArea.hide(e)},DiviArea.Data.configArea=function(e,i,t){DiviArea.Debug.error("DiviArea.configArea() is deprecated. Please use area.setData() instead");var r=DiviArea.getArea(e);if(r)if("object"!==(void 0===i?"undefined":a(i)))r.setData(i,t);else for(var o in i)i.hasOwnProperty(o)&&r.setData(o,i[o])},DiviArea.Hooks.silent().addAction("init_area",function(e){DiviArea.Hooks.silent().doAction("init_area-"+e.theKey(),e)},1),DiviArea.Hooks.silent().addAction("show_area",function(e){DiviArea.Hooks.silent().doAction("show_area-"+e.theKey(),e)},1),DiviArea.Hooks.silent().addAction("hide_area",function(e){DiviArea.Hooks.silent().doAction("hide_area-"+e.theKey(),e)},1),DiviArea.Hooks.silent().addAction("close_area",function(e,i){e&&DiviArea.Hooks.silent().doAction("close_area-"+e.theKey(),e,i)},1),DiviArea.Hooks.silent().addAction("blur_area",function(e){DiviArea.Hooks.silent().doAction("blur_area-"+e.theKey(),e)},1),DiviArea.Hooks.silent().addAction("focus_area",function(e){DiviArea.Hooks.silent().doAction("focus_area-"+e.theKey(),e)},1),DiviArea.Hooks.silent().addAction("before_show_area",function(e,i){DiviArea.Hooks.silent().doAction("before_show_area-"+e.theKey(),e,i)},1),DiviArea.Hooks.silent().addAction("before_hide_area",function(e,i){DiviArea.Hooks.silent().doAction("before_hide_area-"+e.theKey(),e,i)},1),DiviArea.Hooks.silent().addFilter("ignore_close_area",function(e,i,t){return e=DiviArea.Hooks.silent().applyFilters("before_close_area",e,i,t),e=DiviArea.Hooks.silent().applyFilters("before_close_area-"+i.theKey(),e,i,t)},1),DiviArea.Hooks.silent().addFilter("ignore_esc_key",function(e){return e=DiviArea.Hooks.silent().applyFilters("esc_key_pressed",e)},1),DiviArea.Hooks.silent().addAction("area_close_button",function(e){e.addClass("evr-close_wrap"),e.find(">a").addClass("evr-close")},1),DiviArea.Hooks.silent().addAction("area_wrap",function(e){e.addClass("popup_outer_wrap")},1),DiviArea.Hooks.silent().addAction("init_overlay",function(e){e.addClass("evr_fb_popup_modal")},1),DiviArea.Hooks.silent().addAction("refresh_area",function(e){var i={notmobile:DiviArea.Utils.getOption("notMobileClass"),nottablet:DiviArea.Utils.getOption("notTabletClass"),notdesktop:DiviArea.Utils.getOption("notDesktopClass"),showclose:DiviArea.Utils.getOption("withCloseClass"),hideclose:DiviArea.Utils.getOption("noCloseClass"),closealt:DiviArea.Utils.getOption("altCloseClass"),ismodal:DiviArea.Utils.getOption("modalIndicatorClass"),noshadow:DiviArea.Utils.getOption("noShadowClass"),darkmode:DiviArea.Utils.getOption("darkModeClass"),singleton:DiviArea.Utils.getOption("singletonClass")};for(var t in i)e.getData(t)?e.addClass(i[t]):e.removeClass(i[t])},1),DiviArea.listAreas=DiviArea.Data.getAllIds,DiviArea.configArea=DiviArea.Data.configArea,DiviArea.getArea=DiviArea.Data.getArea},function(e,i,t){}]);
1
+ !function(){"use strict";var e=Object.freeze({__proto__:null});!function(e){window.DiviArea=window.DiviArea||{},DiviArea.Utils=DiviArea.Utils||{};var i=!1,t=null,a=null,r=null;function o(i,t,a){var r,o;for(Array.isArray(i)&&(i=e(i).map(e.fn.toArray)),i=e(i),t=t.split(/\s+/),r=0;r<i.length;r++)for(o=0;o<t.length;o++)a(i[r],t[o])}DiviArea.Utils.getOption=function(e){var i=DiviAreaConfig[e],t=DiviArea.Utils.sanitizeHookName(e);return DiviArea.Hooks.silent().applyFilters("get_option_"+t,i)},DiviArea.Utils.toBool=function(e,i){return void 0===i&&(i=!0),null==e?!!i:!0===e||!1===e?e:("string"==typeof e&&(e=e.toLowerCase()),0!==e&&"0"!==e&&"n"!==e[0]&&"f"!==e[0]&&"off"!==e&&(1===e||"1"===e||"y"===e[0]||"t"===e[0]||"on"===e||!!i))},DiviArea.Utils.toMilliseconds=function(e){var i,t=parseFloat(e,10),a=e.match(/m?s/);switch(a&&(a=a[0]),a){case"s":i=1e3*t;break;case"ms":i=t;break;default:i=0}return i},DiviArea.Utils.sanitizeHookName=function(e){return e.toLowerCase().replace(/-/g,"_").replace(/[^a-z0-9_]+/,"")},DiviArea.Utils.showOnViewport=function(i){var t=e(window).innerWidth();return!i||!!(t<768?Array.isArray(i)?i[2]:i.getData("onmobile"):t<981?Array.isArray(i)?i[1]:i.getData("ontablet"):Array.isArray(i)?i[0]:i.getData("ondesktop"))},DiviArea.Utils.isPosition=function(e,i){var t=e.offsetParent();return"HTML"!==t.prop("tagName")&&(i===t.css("position")||DiviArea.Utils.isPosition(t,i))},DiviArea.Utils.setLocalData=function(e,i,t){(!t||isNaN(t)||t<1)&&(t=525600);var a=DiviArea.Utils.sanitizeHookName(e);if(i=DiviArea.applyFilters("set_data",i,e),i=DiviArea.applyFilters("set_data_"+a,i,e),t=DiviArea.applyFilters("set_data_expire",t,e,i),t=DiviArea.applyFilters("set_data_expire_"+a,t,e,i),!(!1===i||t<=0))if(window.localStorage){var r=new Date;r=r.setMinutes(r.getMinutes()+t),localStorage.setItem("_da_"+e,r+":"+i)}else DiviArea.Utils.setCookie("_da_"+e,i,t)},DiviArea.Utils.getLocalData=function(e){var i=!1;if(window.localStorage){var t=localStorage.getItem("_da_"+e);if(t){var a=t.split(":"),r=parseInt(a.shift()),o=a.join(":");r>new Date?i=o:localStorage.removeItem("_da_"+e)}}else i=DiviArea.Utils.getCookie("_da_"+e);var n=DiviArea.Utils.sanitizeHookName(e);return i=DiviArea.applyFilters("get_data",i,e),i=DiviArea.applyFilters("get_data_"+n,i,e)},DiviArea.Utils.setCookie=function(e,i,t){var a=escape(i);if(t){var r=new Date;r.setMinutes(r.getMinutes()+t),a+="; expires="+r.toUTCString()}document.cookie=e+"="+a+"; path=/"},DiviArea.Utils.getCookie=function(e){var i,t,a,r=document.cookie.split(";");for(i=0;i<r.length;i++)if(t=r[i].substr(0,r[i].indexOf("=")),a=r[i].substr(r[i].indexOf("=")+1),(t=t.replace(/^\s+|\s+$/g,""))===e)return unescape(a);return!1},DiviArea.Utils.getUrlParam=function(e){if(null===a){a={};var i=window.location.search.slice(1);if(i)for(var t=(i=i.split("#")[0]).split("&"),r=0;r<t.length;r++){var o=t[r].split("="),n=o[0],s=void 0===o[1]||o[1];if(n=n.toLowerCase(),"string"==typeof s&&(s=s.toLowerCase()),n.match(/\[(\d+)?\]$/)){var l=n.replace(/\[(\d+)?\]/,"");if(a[l]||(a[l]=[]),n.match(/\[\d+\]$/)){var d=/\[(\d+)\]/.exec(n)[1];a[l][d]=s}else a[l].push(s)}else a[n]?a[n]&&"string"==typeof a[n]?(a[n]=[a[n]],a[n].push(s)):a[n].push(s):a[n]=s}}return e?a[e]:Object.assign({},a)},DiviArea.Utils.getWindow=function(i){return e.isWindow(i)?i:9===i.nodeType&&(i.defaultView||i.parentWindow)},DiviArea.Utils.getClientRect=function(i){var t={top:0,left:0,width:0,height:0,bottom:0,right:0};if(0===i.length)return t;var a,r=(i=i[0]).ownerDocument,o=r.documentElement;if(!e.contains(o,i))return t;if(e.support.getBoundingClientRect){try{a=i.getBoundingClientRect()}catch(e){}if(!a)return t;if(a.right===a.left&&a.top===a.bottom)return t;var n=DiviArea.Utils.getWindow(r);t.top=a.top+(n.pageYOffset||o.scrollTop)-(o.clientTop||0),t.left=a.left+(n.pageXOffset||o.scrollLeft)-(o.clientLeft||0),t.width=a.right-a.left,t.height=a.bottom-a.top}else{if("none"===i.css("display"))return t;(t=i.offset()).width=i.outerWidth(),t.height=i.outerHeight()}return t.bottom=t.top+t.height,t.right=t.left+t.width,t},DiviArea.Utils.bindPassiveEvent=function(e,t,a){var r;r=!!i&&{passive:!1,capture:!1},o(e,t,(function(e,i){e.addEventListener(i,a,r)}))},DiviArea.Utils.unbindPassiveEvent=function(e,t,a){var r;r=!!i&&{passive:!1,capture:!1},o(e,t,(function(e,i){e.removeEventListener(i,a,r)}))},DiviArea.Utils.init=function(){var t={popupSelector:".et_pb_section.popup",fullHeightClass:"full-height",openPopupClass:"da-overlay-visible",overlayClass:"da-overlay",modalIndicatorClass:"is-modal",blockingIndicatorClass:"is-blocking",exitIndicatorClass:"on-exit",hoverTriggerClass:"on-hover",clickTriggerClass:"on-click",activePopupClass:"is-open",noCloseClass:"no-close",altCloseClass:"close-alt",notMobileClass:"not-mobile",notTabletClass:"not-tablet",notDesktopClass:"not-desktop",withCloseClass:"with-close",withLoaderClass:"with-loader",singletonClass:"single",darkModeClass:"dark",noShadowClass:"with-shadow",closeButtonClass:"da-close",popupWrapperClass:"area-outer-wrap",defaultShowCloseButton:!0,idAttrib:"data-popup",triggerClassPrefix:"show-popup-",baseContext:"body",triggerCloseClass:"close",zIndex:1e6,onExitDelay:2e3,animateSpeed:300,debug:!1,debugVerbose:!1,initializeOnEvent:"et_pb_after_init_modules"},a="";if(function(){try{var e={get passive(){return i=!0,!1}};window.addEventListener("test",null,e),window.removeEventListener("test",null,e)}catch(e){i=!1}}(),e.support.getBoundingClientRect="getBoundingClientRect"in document.documentElement,window.DiviAreaConfig||(window.DiviAreaConfig=t),window.DiviPopupData)for(a in DiviPopupData)DiviPopupData.hasOwnProperty(a)&&(DiviAreaConfig[a]=DiviPopupData[a]);for(a in t)void 0===DiviAreaConfig[a]&&(DiviAreaConfig[a]=t[a]);for(a in DiviAreaConfig)DiviAreaConfig[a].replace&&(DiviAreaConfig[a]=DiviAreaConfig[a].replace(/^[\s\xA0]+|[\s\xA0]+$/g,""));DiviAreaConfig.zIndex=parseInt(DiviAreaConfig.zIndex),DiviAreaConfig.onExitDelay=parseInt(DiviAreaConfig.onExitDelay),DiviAreaConfig.animateSpeed=parseInt(DiviAreaConfig.animateSpeed),DiviAreaConfig.debug=!!DiviAreaConfig.debug,DiviAreaConfig.defaultShowCloseButton=!!DiviAreaConfig.defaultShowCloseButton,(!DiviAreaConfig.triggerClassPrefix||DiviAreaConfig.triggerClassPrefix.length<3)&&(DiviAreaConfig.triggerClassPrefix=!1),"body"===DiviAreaConfig.baseContext&&(1===e("#et_builder_outer_content").length?(DiviAreaConfig.baseContext="#et_builder_outer_content",DiviArea.Debug.info("🎚 Divi plugin detected.","Inject Areas into #et_builder_outer_content")):1===e(".et-db #et-boc").length?(DiviAreaConfig.baseContext=".et-db #et-boc",DiviArea.Debug.info("🎚 Divi theme detected.","Inject Areas into #et-boc")):1===e("body.et_divi_theme #page-container").length&&(DiviAreaConfig.baseContext="#page-container",DiviArea.Debug.info("🎚 Divi theme detected.","Inject Areas into #page-container"))),"body"===DiviAreaConfig.baseContext||e(DiviAreaConfig.baseContext).length||(DiviAreaConfig.baseContext="body",DiviArea.Debug.info("🎚 Invalid baseContext given.","Inject Areas into body instead.")),window.DiviPopupData=window.DiviAreaConfig,window.DiviAreaConfig=DiviArea.applyFilters("init_options",DiviAreaConfig)},DiviArea.Utils.initErrorLogging=function(e){var i=function(e,i,t){if(!e[i]||!e[i].__dm_orig__){var a=e[i],r=void 0;for(var o in e[i]=function(){var e=!1;try{e=t.apply(this,arguments)}finally{!e&&a&&(r=a.apply(this,arguments))}return r},a)a.hasOwnProperty(o)&&(e[i][o]=a[o]);e[i].__dm_orig__=a}},t=function(){var e=arguments,i=!1;if(arguments[0]&&"[DiviAreas]"===arguments[0])return!1;for(var t=0;t<arguments.length;t++)if("object"==typeof e[t]&&e[t]&&e[t].message&&e[t].stack){i=e[t];break}if(i){var a=[],r=i.stack.toString().split("\n");if(a.push("divimode.com Anonymized Error Report"),a.push("-".repeat(30)),a.push(i.name),i.message?a.push(i.message):a.push("-"),a.push(""),r&&r.length>1)for(var o=0;o<r.length;o++){var n=r[o];if(n.match(/(\/wp-includes\/|\/jquery\.js)/))break;n.match(/\.js/)&&(n=(n=(n=n.replace(/^\s+|\s+$/g,"")).replace(/https?:.*?\/wp-content/g,"")).replace(/\.js\?[\w=&_\-\.]*/g,".js"),a.push(n))}if(DiviArea.info&&(a.push(""),a.push("js api:"+DiviArea.info)),window.DiviAreaConfig&&DiviAreaConfig.sys&&DiviAreaConfig.sys.plugin)for(var s in a.push(""),DiviAreaConfig.sys)try{a.push(s+": "+DiviAreaConfig.sys[s])}catch(e){}a.push("-".repeat(30));var l=console.error.__dm_orig__||console.error;return console.log(""),l("✋ "+a.join("\n| ")),console.log(""),!0}return!1};i(e,"onerror",t),i(e.console,"error",t)},DiviArea.Utils.toPixel=function(e,i,a){if(t||((t={}).PPI=void 0,t.getPPI=function(){return t.PPI=t.PPI||t.getSizeBrutal("in",document.body),t.PPI},t.parseUnit=function(e){var i=[0,""];e=String(e);var t=parseFloat(e,10);return i[0]=t,i[1]=e.match(/[\d.\-\+]*\s*(.*)/)[1]||"",i},t.getPropertyInPx=function(e,i){var a=t.parseUnit(getComputedStyle(e).getPropertyValue(i));return a[0]*t.conversionFactor(a[1],e)},t.getSizeBrutal=function(e,i){var a=document.createElement("div");a.style.height="128"+e,i.appendChild(a);var r=t.getPropertyInPx(a,"height")/128;return i.removeChild(a),r},t.conversionFactor=function(e,i){switch(e=(e+""||"px").trim().toLowerCase()){case"%":return i.clientHeight/100;case"ch":case"ex":return t.getSizeBrutal(e,i);case"em":return t.getPropertyInPx(i,"font-size");case"rem":return t.getPropertyInPx(document.body,"font-size");case"vw":return window.innerWidth/100;case"vh":return window.innerHeight/100;case"vmin":return Math.min(window.innerWidth,window.innerHeight)/100;case"vmax":return Math.max(window.innerWidth,window.innerHeight)/100;case"in":return t.getPPI();case"cm":return t.getPPI()/2.54;case"mm":return t.getPPI()/25.4;case"pt":return t.getPPI()/72;case"pc":return t.getPPI()/6;case"px":return 1}return 0}),!e)return 0;if((a=a||document.body)!==window&&a!==document||(a=document.body),!isNaN(e)){if(i){var r=t.conversionFactor(i,a);return"number"==typeof r?e*r:0}return e}return 0},DiviArea.Utils.getStyleDef=function(e,i,t){var a="";return null===r&&(r=[],Array.from(document.styleSheets).map((function(e){try{r.push.apply(r,Array.from(e.rules))}catch(e){}}))),e.style&&""!==e.style[i]?a=e.style[i]:r.reverse().some((function(r){var o=!1;try{o=e.matches(r.selectorText)}catch(e){}return!(o&&t&&t.length&&-1!==t.indexOf(r.selectorText))&&(o&&Array.from(r.style).some((function(e){return e===i}))?(a=r.style[i],!0):void 0)})),a}}(window.jQuery),window.DiviAreaItem=function(e,i){var t=jQuery,a=window.ResizeObserver||window.WebKitResizeObserver,r=t(e),o={},n={hideclose:!1,showclose:!0,notmobile:!1,onmobile:!0,nottablet:!1,ontablet:!0,notdesktop:!1,ondesktop:!0,closealt:!1,notmodal:!0,ismodal:!1,notblocking:!1,isblocking:!1,triggerexit:!1,shadow:!0,noshadow:!1,darkmode:!1,singleton:!1,static:!1,withloader:!1},s={hideclose:"showclose",notdesktop:"ondesktop",notmobile:"onmobile",notmodal:"ismodal",notblocking:"isblocking",nottablet:"ontablet",shadow:"noshadow",dynamic:"static"},l=null,d=null,c=0,v=null,u=null,p=null,g={};function h(){for(var e in o._id=r.attr("id"),o._key=DiviArea.Utils.sanitizeHookName(o._id),o._type=y(i),o._inDom=r.closest(document.documentElement).length,o._isVisible=o._inDom&&r[0].getClientRects().length,o._size={},DiviArea.Debug.debug("Area Type",this.theType()),DiviArea.Debug.debug("Area ID",this.theId()),DiviArea.Debug.debug("Area Hook",this.theKey()),U(r),this.setData("zindex",0),this.setData("container",t("body")),this.setData("hasShowAnim",!0),this.setData("position","center-center"),this.setData("positionv","center"),this.setData("positionh","center"),n)void 0!==r.data("da-"+e)?(this.setData(DiviArea.Utils.toBool(r.data("da-"+e))),r.removeAttr("data-da-"+e)):void 0!==r.data(e)?(this.setData(DiviArea.Utils.toBool(r.data(e))),r.removeAttr("data-"+e)):this.setData(e,n[e]);var s={};for(var l in s[DiviArea.Utils.getOption("notMobileClass")]=["onmobile",!1],s[DiviArea.Utils.getOption("notTabletClass")]=["ontablet",!1],s[DiviArea.Utils.getOption("notDesktopClass")]=["ondesktop",!1],s[DiviArea.Utils.getOption("noCloseClass")]=["showclose",!1],s[DiviArea.Utils.getOption("withCloseClass")]=["showclose",!0],s[DiviArea.Utils.getOption("altCloseClass")]=["closealt",!0],s[DiviArea.Utils.getOption("modalIndicatorClass")]=["ismodal",!0],s[DiviArea.Utils.getOption("blockingIndicatorClass")]=["isblocking",!0],s[DiviArea.Utils.getOption("exitIndicatorClass")]=["triggerexit",!0],s[DiviArea.Utils.getOption("noShadowClass")]=["noshadow",!0],s[DiviArea.Utils.getOption("darkModeClass")]=["darkmode",!0],s[DiviArea.Utils.getOption("singletonClass")]=["singleton",!0],s[DiviArea.Utils.getOption("withLoaderClass")]=["withloader",!0],s)if(r.hasClass(l)){var d=s[l];this.setData(d[0],d[1]),r.removeClass(l)}DiviArea.UI.initializeAreaAnimation(r),m(),b(),D(),a&&(v=new a((function(e){var i=r[0].scrollHeight-r[0].clientHeight;i>0&&i-r[0].scrollTop<1&&(r[0].scrollTop-=1),o._size.width=0,o._size.height=0,o._size.contentWidth=0,o._size.contentHeight=0,O("resize",k)}),{box:"border-box"}),u=new a((function(e){o._size.wrapperWidth=0,o._size.wrapperHeight=0,O("resize",k)}),{box:"border-box"}))}function D(){r.attr("data-da-area",o._id),l.attr("data-da-area",o._id),l.attr("data-da-registered",1),l.attr("data-da-type",this.theType()),l.attr("data-da-close-btn",this.getData("showclose")?"yes":"no"),l.attr("data-da-close-bg",this.getData("closeAlt")?"none":"solid"),l.attr("data-da-loader",this.getData("withLoader")?"yes":"no"),l.attr("data-da-shadow",this.getData("shadow")?"yes":"no"),l.attr("data-da-color",this.getData("darkMode")?"dark":"light");var e=this.getData("wrapClasses");e&&l.addClass(e),O("position",this.setPosition),this.doAction("refresh_area")}function f(){var e=this;if(this.isVisible()){r.find("."+DiviArea.Utils.getOption("closeButtonClass")).off(".da");var i=function(i,t){return DiviArea.Debug.debug("Click on",t,"close-button"),e.doAction("close_area",e,t),i.preventDefault(),!1};l.find("div ."+DiviArea.Utils.getOption("triggerCloseClass")).off(".da").on("click.da",(function(e){return i(e,"custom")})),d.find("a").off(".da").on("click.da",(function(e){return i(e,"default")})),t(window).on("resize",C),this.addAction("close_area",_)}else l.find("div ."+DiviArea.Utils.getOption("triggerCloseClass")).off(".da"),d.find("a").off(".da"),t(window).off("resize",C),this.removeAction("close_area")}function A(e){var i=this;if(this.isVisible()){if(this.getData("hasShowAnim")){DiviArea.Debug.info("✨ Animate the area (show)",this.theId()),DiviArea.UI.animateArea(this,"show",(function(){i.getData("showclose")&&d.show(),e()}))}}else this.getData("hasShowAnim")&&(d.hide(),DiviArea.Debug.info("✨ Animate the area (hide)",this.theId()),DiviArea.UI.animateArea(this,"hide",e))}function b(){if(!d){var e=DiviArea.Utils.getOption("closeButtonClass"),i=e+"-wrap";d=t("<span>").addClass(i).appendTo(l),t("<a>").attr("href","#close").addClass(e).html("&times;").appendTo(d),d.hide(),this.doAction("area_close_button",d,this)}}function m(){if(!l){var e=DiviArea.Utils.getOption("popupWrapperClass");(l=r.parent()).hasClass(e)||(r.wrap("<div>"),(l=r.parent()).addClass(e)),U(l),this.doAction("area_wrap",l,this)}}function w(){var e=this;c&&clearTimeout(c),c=setTimeout((function(){c=0,e.inDom()&&D()}),20)}function y(e){return e.toLowerCase().trim().replace(/-/,"")}function _(e,i){var t=!1;if(t=this.applyFilters("ignore_close_area",t,this,i))return DiviArea.Debug.debug("Ignored, manually cancelled in filter"),!0;DiviArea.hide(this)}function C(){o._size.windowWidth=0,o._size.windowHeight=0,o._size.wrapperWidth=0,o._size.wrapperHeight=0,O("resize",k)}function k(){if(this.isVisible()){var e=this.getSize(),i=[e.contentWidth,e.contentHeight,e.windowWidth,e.windowHeight].join("-");if(o._resizeState!==i){if(o._resizeState=i,d.css({width:e.width,height:e.height}),this.isType("popup"))if(l.attr("data-da-size-full-height"))e.wrapperHeight-e.contentHeight>=20&&(l.removeAttr("data-da-size-full-height"),l.removeClass(DiviArea.Utils.getOption("fullHeightClass")));else e.windowHeight-e.contentHeight<=20&&(l.attr("data-da-size-full-height",1),l.addClass(DiviArea.Utils.getOption("fullHeightClass")));O("position",this.setPosition)}}}function x(e,i){var t,a="";if(i||""===(a=DiviArea.Utils.getStyleDef(l[0],e))&&(a=DiviArea.Utils.getStyleDef(r[0],e)),""===a){var o=r.find(".et_pb_section");for(t=0;t<o.length&&!a;t++)a=DiviArea.Utils.getStyleDef(o[t],e,['[class*="et_pb_section_dap_"]'])}return a}function I(){var e=x("width"),i=x("max-width",!0);e&&"auto"!==e||(this.isType("popup")||l.css("width","100%"),r.css("width","100%")),i&&r.css("max-width",i)}function O(e,i){var t=this;g[e]||(g[e]=window.setTimeout((function(){g[e]=!1,i.apply(t)}),4))}function U(e){var i=this;e.data("is-area",!0),e.data("area",this),e.data("area-config",o),e.getArea=function(){return i}}function z(){}this.theId=function(){return"#"+o._id},this.theKey=function(){return o._key},this.hasId=function(e){e=e.replace(/^#/,"",e);var i=DiviArea.Data.getRealId(e);return i||(i=DiviArea.Data.getRealId("divi-area-"+e)),i&&i===this.theId()},this.theType=function(){return o._type},this.isType=function(e){if(!e)return!0;if("string"!=typeof e)throw new Error("DiviAreaItem.isType() expects a string parameter. Given value is a "+typeof e);if((e=y(e))===o._type)return!0;if("any"===e||"all"===e)return!0;for(var i=0===e.indexOf("not:"),t=e.replace(/^not:\s*/,"").split(/\s*,\s*/),a=0;a<t.length;a++)if(t[a]===o._type)return!i;return i},this.get=function(e){return e?t(e,r):r},this.getWrap=function(){return l},this.attach=function(){if(w(),!this.inDom()){o._inDom=!0;var e=this.findHook();if(r.hide(),e){var i=e.data("area-place"),t=e;"after"===i?t=e.next():"replace"===i&&(p=e.next().detach()),t.after(l.detach())}else l.detach().appendTo(this.getData("container"));l.closest("#et-boc").length||l.wrap('<div id="et-boc">'),O("position",this.setPosition),this.setVisible(!0,(function(){if(v){var e=DiviArea.Utils.getOption("closeButtonClass")+"-wrap";r.children().each((function(i,t){-1===t.className.indexOf(e)&&v.observe(t)})),v.observe(r[0]),u.observe(l[0])}}))}},this.detach=function(){if(this.inDom()){o._inDom=!1;var e=this.findHook();v&&v.disconnect(),u&&u.disconnect(),this.setVisible(!1,(function(){var i=l.parent();r.hide(),l.detach(),"et-boc"!==i.attr("id")||i.hasClass("dm-base-context")||i.children().length||i.remove(),p&&(e.after(p),p=null)}))}},this.findHook=function(){var e='[data-area-hook="'+this.getData("hookid")+'"]',i=t(e);return!!i.length&&i},this.setVisible=function(e,i){e=!!e,o._isVisible!==e&&("function"!=typeof i&&(i=z),o._isVisible=e,f(),A(i),this.isVisible()?(I(),this.doAction("show_area")):this.doAction("hide_area"))},this.setPosition=function(){var e={},i={};if(this.isVisible()&&this.inDom()){if(this.getData("maxheight")&&(e.overflow="auto",e.maxHeight="100%",i.maxHeight=this.getData("maxheight")),this.getData("maxwidth")&&(e.maxWidth="100%",i.maxWidth=this.getData("maxwidth")),i.zIndex=this.getData("zindex"),this.isType("inline")||this.isType("hover"))l.removeAttr("data-da-position"),l.removeAttr("data-da-position-h"),l.removeAttr("data-da-position-v");else{var t=this.getData("positionh"),a=this.getData("positionv"),o=null;switch(l.attr("data-da-position",this.getData("position")),l.attr("data-da-position-h",t),l.attr("data-da-position-v",a),t){case"left":i.left="0";break;case"right":i.right="0";break;case"center":o||(o=this.getSize()),i.left=Math.max(0,parseInt((o.windowWidth-o.wrapperWidth)/2))+"px"}if(!l.attr("data-da-size-full-height"))switch(a){case"top":i.top="0";break;case"bottom":i.bottom="0";break;case"center":o||(o=this.getSize()),i.top=Math.max(0,parseInt((o.windowHeight-o.wrapperHeight)/2))+"px"}}r.css(e),l.css(i)}},this.setTriggerEvent=function(i){var a=!1;i&&(this.setData("event",i),i.currentTarget?a=i.currentTarget:i instanceof jQuery?a=i.first():window.HTMLElement&&e instanceof window.HTMLElement&&(a=t(i))),this.setData("attachto",a),DiviArea.Debug.debug("Attached to element:",a||"(none)")},this.isVisible=function(){return o._isVisible},this.inDom=function(){return o._inDom},this.getSize=function(){var e=this.isVisible();if(o._size&&void 0!==o._size.width||(o._size={}),o._size.width||(o._size.width=e?r[0].clientWidth:0),o._size.height||(o._size.height=e?r[0].clientHeight:0),o._size.contentWidth||(o._size.contentWidth=e?r[0].scrollWidth:0),!o._size.contentHeight&&(o._size.contentHeight=0,e))if(r.hasClass("et_pb_section")){var i=window.getComputedStyle(r[0]);o._size.contentHeight+=parseInt(i["border-top-width"]),o._size.contentHeight+=parseInt(i["padding-top"]),o._size.contentHeight+=parseInt(i["padding-bottom"]),o._size.contentHeight+=parseInt(i["border-bottom-width"]),r.children().each((function(){o._size.contentHeight+=this.offsetHeight}))}else o._size.contentHeight=r[0].scrollHeight;return o._size.wrapperWidth||(o._size.wrapperWidth=e?l[0].offsetWidth:0),o._size.wrapperHeight||(o._size.wrapperHeight=e?l[0].offsetHeight:0),o._size.windowWidth||(o._size.windowWidth=window.innerWidth),o._size.windowHeight||(o._size.windowHeight=window.innerHeight),o._size},this.getData=function(e){var i;return e=e.toLowerCase().replace(/[^a-z0-9]/,""),s.hasOwnProperty(e)?(e=s[e],i=!o[e]):i=o[e],i},this.setData=function(e,i){if(void 0!==i){if(e=e.toLowerCase().replace(/[^a-z0-9]/,""),n.hasOwnProperty(e))i=DiviArea.Utils.toBool(i,n[e]),s.hasOwnProperty(e)&&(e=s[e],i=!i);else switch(e){case"zindex":i=parseInt(i);break;case"closedelay":i=parseFloat(i);break;case"position":-1!==i.indexOf("top")?o.positionv="top":-1!==i.indexOf("bottom")?o.positionv="bottom":o.positionv="center",-1!==i.indexOf("left")?o.positionh="left":-1!==i.indexOf("right")?o.positionh="right":o.positionh="center",i=o.positionv+"-"+o.positionh;break;case"positionh":if("left"!==i&&"right"!==i&&"center"!==i)return;break;case"positionv":if("top"!==i&&"bottom"!==i&&"center"!==i)return;break;case"container":(i=t(i).first()).length||(i=t("body"));break;case"attachto":i=t(i).first()}switch(o[e]=i,e){case"positionh":case"positionv":o.position=o.positionv+"-"+o.positionh}w()}},this.doAction=function(e){for(var i=[],t=arguments.length-1;t-- >0;)i[t]=arguments[t+1];i.length||(i=[this]),DiviArea.doAction.apply(DiviArea,[[e,e+"_"+this.theKey()]].concat(i))},this.applyFilters=function(e,i){for(var t=[],a=arguments.length-2;a-- >0;)t[a]=arguments[a+2];return t.length||(t=[this]),DiviArea.applyFilters.apply(DiviArea,[[e,e+"_"+this.theKey()],i].concat(t))},this.addFilter=function(e,i,t,a){DiviArea.addFilter(e+"_"+this.theKey(),i,t,a)},this.addAction=function(e,i,t,a){DiviArea.addAction(e+"_"+this.theKey(),i,t,a)},this.removeFilter=function(e,i){DiviArea.removeFilter(e+"_"+this.theKey(),i)},this.removeAction=function(e,i){DiviArea.removeAction(e+"_"+this.theKey(),i)},this.addActionOnce=function(e,i,t,a){DiviArea.addActionOnce(e+"_"+this.theKey(),i,t,a)},this.hasClass=r.hasClass.bind(r),this.addClass=r.addClass.bind(r),this.removeClass=r.removeClass.bind(r),this.attr=r.attr.bind(r),this.removeAttr=r.removeAttr.bind(r),this.find=r.find.bind(r),h=h.bind(this),D=D.bind(this),f=f.bind(this),A=A.bind(this),w=w.bind(this),m=m.bind(this),b=b.bind(this),_=_.bind(this),C=C.bind(this),k=k.bind(this),x=x.bind(this),I=I.bind(this),O=O.bind(this),U=U.bind(this),h()};var i,t,a,r;i=jQuery,DiviArea.init=function(e){var t=[window.location.protocol,"//",window.location.host,"/wp-admin/edit.php?post_type=divi-area&page=settings#frontend"];this.app=e?"Divi Areas Pro":"Popups for Divi",this.lib=e?"DiviArea":"DiviPopup",this.version="2.0.0",this.info=this.lib+"-"+this.version,this.loaded=!0,DiviArea.Debug.info("🚀 Initialize "+this.app,"- JS API:",this.info),e?DiviArea.Debug.info("ℹ️ You can disable the debug output on the Settings page:",t.join("")):DiviArea.Debug.info("ℹ️ You can disable the debug output by disabling WP_DEBUG"),DiviArea.Debug.debug("Details about the Debug Mode","https://divimode.com/knowledge-base/debug-options/"),DiviArea.Utils.init(),DiviArea.Utils.getOption("initializeOnEvent")?i(window,document).one(DiviArea.Utils.getOption("initializeOnEvent"),(function(){window.setTimeout(DiviArea.Core.init,1)})):window.setTimeout(DiviArea.Core.init,1)},DiviArea.markClosed=function(e,i){if(DiviArea.Utils.getOption("debug")){var t=DiviArea.Data.sanitizeId(e);DiviArea.Debug.info("📌 Mark Area as closed for "+i+" minutes:",t)}DiviArea.Utils.setLocalData(e,"1",i)},DiviArea.isClosed=function(e){e=e.toLowerCase().replace(/^#/,"");var i=DiviArea.Utils.getLocalData(e);if(DiviArea.Utils.getOption("debug")){var t=DiviArea.Data.sanitizeId(e);"1"===i?DiviArea.Debug.info("📌 Area is still closed:",t):DiviArea.Debug.info("📌 Area is not closed:",t)}return"1"===i},DiviArea.register=function(e,t,a){if(void 0===t&&(t={}),void 0===a&&(a=!1),!(e=DiviArea.Data.sanitizeId(e)))return!1;var r=DiviArea.getArea(e);if(r)return r;var o=i(e);if(o.length&&t.selector&&(o=o.filter(t.selector),delete t.selector),1!==o.length)return!1;if(!a){if(o.data("da-type"))a=o.data("da-type"),o.removeAttr("data-da-type");else if(o.data("type"))a=o.data("type"),o.removeAttr("data-type");else for(var n=o[0].className.split(/\s+/),s=0;s<n.length;s++)if(0===n[s].indexOf("divi-area-type-")){a=n[s].replace("divi-area-type-",""),o.removeClass(n[s]);break}if(!a)return!1}if(DiviArea.Debug.group("Register Area | "+a+" | "+e),t.areaHook&&t.hookId&&"inline"===a){var l=i(t.areaHook).first();if(l.length){var d=i("<span>");d.attr("data-area-hook",t.hookId),d.attr("data-area-place",t.areaPlace),l.before(d)}else DiviArea.Debug.error("Inline hook not found:",t.areaHook)}var c=DiviArea.Data.createArea(o,a,e);return t.alternateid?DiviArea.Data.addAltId(c.theId(),t.alternateid):t.alternateId?DiviArea.Data.addAltId(c.theId(),t.alternateId):t.ids&&DiviArea.Data.addAltId(c.theId(),t.ids),delete t.alternateid,delete t.alternateId,delete t.ids,Object.keys(t).forEach((function(e){c.setData(e,t[e])})),c.setData("wrap-classes","et-l entry-content"),c.isType("inline")&&c.getData("static")?(DiviArea.Core.initContainer(c),DiviArea.show(e,"static")):(c.detach(),c.setData("container",DiviArea.Core.getContext())),DiviArea.Debug.info("➕ Registered new area:",e,"("+a+")"),DiviArea.Debug.group(),c.doAction("init_area"),c},DiviArea.show=function(e,i){if(!e)return!1;var t=DiviArea.getArea(e);return t?DiviArea.Utils.showOnViewport(t)?(DiviArea.Debug.group("Show area",t.theId()),t.setData("hasShowAnim",!t.isVisible()),t.setTriggerEvent(i),t.isType("hover")&&DiviArea.Core.setupHoverArea(t),DiviArea.Core.attachArea(t),DiviArea.Core.reOrderAreas(),DiviArea.Debug.group(),!0):(DiviArea.Debug.debug("Do not trigger area on this device:",t.theId()),!1):(DiviArea.Debug.error("Could not find an area with the ID:",e),!1)},DiviArea.hide=function(e){var i=DiviArea.Data.getVisibleArea(e);i&&(i.setData("hasShowAnim",!0),i.setData("event",void 0),DiviArea.Debug.debug("Close area and unlink event handlers:",i.theId()),DiviArea.Core.detachArea(i)),DiviArea.Core.reOrderAreas()},function(e){DiviArea.Core=DiviArea.Core||{};var i=window.ResizeObserver||window.WebKitResizeObserver,t=null,a=!1,r=!1;function o(e,i){DiviArea.Core.isArea(e)||(e=DiviArea.Data.getVisibleArea())&&(DiviArea.Debug.debug("Close the top-most area"),e.doAction("close_area",e,"default"))}function n(e){if(27===e.keyCode)return function(){DiviArea.Debug.info("⚡️ ESC-key pressed");var e=!1,i=DiviArea.Data.getVisibleArea(null,"popup");return i?(e=i.getData("isblocking"),(e=DiviArea.applyFilters("ignore_esc_key",e))?(DiviArea.Debug.debug("Ignored, manually cancelled in filter"),!0):(DiviArea.Debug.debug("Close top-most popup"),DiviArea.doAction("close_area",null,"esc"),!1)):(DiviArea.Debug.debug("Ignored, no popup is visible"),!0)}()}function s(){var e=["popup","flyin"],i=!1;function t(e,t){i||e.getData("triggerexit")&&(DiviArea.isClosed(t)?e.setData("triggerexit",!1):DiviArea.show(t,"exit")&&(e.setData("triggerexit",!1),i=!0))}for(var a in e)i=!1,DiviArea.Data.loopAllAreas(e[a],t)}function l(e,i){var t=[];if(i.isType("popup")&&"show"===e&&i.getData("singleton")&&DiviArea.Data.loopVisibleAreas("popup",(function(e){t.push(e.theId())})),"hide"===e?i.doAction("before_hide_area",i,t):i.doAction("before_show_area",i,t),t.length)for(var a in DiviArea.Debug.debug("Hide following areas:",t),t){var r=DiviArea.getArea(t[a]);r&&r.inDom()&&DiviArea.Core.detachArea(r)}}function d(i,t){var a;if(a=DiviArea.Data.sanitizeId(t))if(i.attr("data-area-id"))DiviArea.Debug.debug("Trigger already prepared",i[0]);else if(DiviArea.getArea(a)){var r=DiviArea.Utils.getOption("hoverTriggerClass"),o=DiviArea.Utils.getOption("clickTriggerClass");i.attr("data-area-id",a),i.addClass("popup-trigger"),i.off("click"),i.hasClass(r)&&(i.on("mouseenter._da",n),DiviArea.Debug.debug("Prepared Hover trigger to open this area:",a,i[0])),i.hasClass(r)&&!i.hasClass(o)||(i.on("click._da",n),DiviArea.Debug.debug("Prepared Click trigger to open this area:",a,i[0]))}else DiviArea.Debug.debug("Ignore trigger. No area found with this ID:",i[0]);else DiviArea.Debug.debug("Ignore trigger. Invalid target ID:",t,i[0]);function n(i){var t=e(i.target);return!("A"!==t.prop("tagName")||!t.attr("href").length||t.attr("data-area-id"))||(i.preventDefault(),DiviArea.Debug.debug("Trigger area:",a),DiviArea.show(a,i),!1)}}function c(i){var t=e(i.target).closest("[data-da-type][data-da-registered]"),a=DiviArea.Utils.getOption("fullHeightClass");return!(!t.length||!t.hasClass(a))||(i.preventDefault(),i.stopPropagation(),!1)}DiviArea.Core.init=function(){a?DiviArea.Debug.error("Core.init() was already executed. It should not run twice, please review the code!"):(a=!0,DiviArea.Debug.debug("Initialize the app"),DiviArea.doAction("load"),(t=e(DiviArea.Utils.getOption("baseContext")).filter(":visible").first()).length?(t.closest("#et-boc").length||(t.append('<div id="et-boc" class="dm-base-context"></div>'),t=t.find("#et-boc").first()),DiviArea.Debug.debug('Base context "'+DiviArea.Utils.getOption("baseContext")+'" found',t)):DiviArea.Debug.error('Could not find the popup container "'+DiviArea.Utils.getOption("baseContext")+'"'),function(){var i=e(".et_pb_fullscreen_nav_container #mobile_menu_slide");if(!i.length)return;i.parent().css({minHeight:i.outerHeight()})}(),window.setTimeout((function(){e(window).on("mouseleave.da",(function(e){var i;"input"!==e.target.tagName.toLowerCase()&&"textarea"!==e.target.tagName.toLowerCase()&&"select"!==e.target.tagName.toLowerCase()&&(i=Math.max(document.documentElement.clientWidth,window.innerWidth||0),e.clientX>=i-50||e.clientY>=50||e.toElement||e.relatedTarget||(DiviArea.Debug.info("⚡️ Exit-intent detected (mouse leave)"),DiviArea.doAction("exit_intent","mouse-leave")))})),DiviArea.addAction("exit_intent",s)}),DiviArea.Utils.getOption("onExitDelay")),DiviArea.addAction("ready",(function(){DiviArea.addAction("close_area",o),function(e){var i=window.MutationObserver||window.WebKitMutationObserver,t=window.addEventListener,a=DiviArea.Core.getContext(),r=!1;function o(){r||(r=setTimeout((function(){r=!1,DiviArea.Debug.debug("DOM changed"),e()}),50))}if(i){new i((function(e,i){if(e[0].addedNodes.length||e[0].removedNodes.length)return o()})).observe(a[0],{childList:!0,subtree:!0})}else t&&(a.addEventListener("DOMNodeInserted",o,!1),a.addEventListener("DOMNodeRemoved",o,!1))}(DiviArea.Core.activateContainer),e(document).on("keyup",n)}),1),DiviArea.addAction("ready",(function(){DiviArea.Core.activateContainer()}),9),DiviArea.doAction("ready"))},DiviArea.Core.isArea=function(e){return e&&e instanceof DiviAreaItem},DiviArea.Core.getContext=function(){return t},DiviArea.Core.reOrderAreas=function(){if(DiviArea.Data.countVisibleAreas("popup")||DiviArea.hideOverlay(),DiviArea.Data.countVisibleAreas()){var e=DiviArea.Utils.getOption("zIndex"),i=DiviArea.Data.countVisibleAreas("not: inline"),t=DiviArea.Data.countVisibleAreas("popup"),a=[],r=0,o=0,n={};if(DiviArea.Debug.debug("Refresh the z-index of visible areas"),DiviArea.Data.loopVisibleAreas("any",DiviArea.Core.blurArea),DiviArea.Core.focusArea(DiviArea.Data.getVisibleArea()),DiviArea.Data.loopVisibleAreas("not: inline",(function(a){var s=0;a.isType("popup")?(o++,s=e+i-t+o,a.hasClass(DiviArea.Utils.getOption("activePopupClass"))&&(n.overlay=s,s+=1)):(r++,s=e+r),n[a.theId()]=s})),(n=DiviArea.applyFilters("reorder_areas",n)).overlay&&!isNaN(n.overlay)){var s=DiviArea.showOverlay(n.overlay);a.push({id:"-",type:"overlay","z-index":s})}for(var l in n)d(l);DiviArea.Debug.info("👓 List of visible Areas:"),DiviArea.Debug.table(a)}function d(e){if("overlay"!==e){var i=DiviArea.getArea(e);if(i){var t=n[e];t&&!isNaN(t)&&i.setData("zindex",t),i.isType("popup")&&i.attach(),a.push({id:i.theId(),type:i.theType(),"z-index":i.getData("zindex")||null})}}}},DiviArea.Core.activateContainer=function(i){var t,a,r=void 0===i;if(void 0===i?i=e("body"):DiviArea.Core.isArea(i)&&(i=i.get()),function(i){i.find(DiviArea.Utils.getOption("popupSelector")).not("[data-da-area]").filter("[id]").each((function(){var i=e(this);DiviArea.Debug.debug("Found an inline Popup Area:",i.attr("id")),DiviArea.register(i,{},"popup")}))}(i),(a=function(i,t){var a,r,o,n=[];if(!i.ids||!i.ids.length)return[];function s(i,t){var a;for(a=0;a<t.length;a++){var r=e(t[a]);r.attr("data-area-id")||(r.attr("data-da-area")||r.hasClass("divi-area-wrap")||r.hasClass("et_pb_section")&&r.hasClass("popup")||n.push({id:i,item:r}))}}for(a=0;a<i.ids.length;a++){var l="#"+(o=i.ids[a].replace(/^#/,"")),d=i.linkPrefix?"#"+i.linkPrefix+o:"",c="."+o,v=i.classPrefix?"."+i.classPrefix+o:"",u=i.dataAttrib?i.dataAttrib+'="'+o+'"':"";if(s(o,e('[href="'+l+'"]',t)),d&&s(o,e('[href="'+d+'"]',t)),s(o,e(c,t)),v&&s(o,e(v,t)),u&&s(o,e("["+u+"]",t)),window.et_link_options_data)for(r=et_link_options_data.length-1;r>=0;r--)if(l===et_link_options_data[r].url||d===et_link_options_data[r].url){var p=e("."+et_link_options_data[r].class,t);s(o,p),p.off("click"),et_link_options_data.splice(r,1)}}return n}({ids:DiviArea.listAreas(),linkPrefix:"popup:",dataAttrib:DiviArea.Utils.getOption("idAttrib"),classPrefix:DiviArea.Utils.getOption("triggerClassPrefix")},i)).length){for(r?DiviArea.Debug.group("Activate all triggers in document"):DiviArea.Debug.group("Activate triggers in area",i.attr("id")),t=0;t<a.length;t++){var o=a[t];d(o.item,o.id)}DiviArea.Debug.group()}else r?DiviArea.Debug.debug("No new triggers found in document"):DiviArea.Debug.debug("No new triggers found in area",i.attr("id"));DiviArea.Core.initContainer(i)},DiviArea.Core.initContainer=function(i){var t=!1,a=!1;return DiviArea.Core.isArea(i)?(t=i,i=i.get()):i.data("is-area")&&(t=i.getArea()),t&&(a=t.getData("post_id")),t&&!0===i.data("area-init-done")||(t&&i.data("area-init-done",!0),e("body").trigger("post-load"),i.find("img[loading=lazy]").attr("loading","eager"),void 0!==window.et_fix_pricing_currency_position&&window.et_fix_pricing_currency_position(i.find(".et_pb_pricing_table")),a&&i.find(".et_pb_newsletter_form").length&&i.find(".et_pb_newsletter_form [name=et_pb_signup_post_id]").val(a),function(e){if(!window.grecaptcha)return;if(!e.find('input[name="g-recaptcha-response"]').length)return;if(e.find("[data-sitekey].g-recaptcha").length>0){if(!grecaptcha.render)return;e.find("form").each((function(){var e=jQuery(this),i=e.find("[data-sitekey].g-recaptcha");if(i.length&&!e.find('iframe[src*="/recaptcha/"]').length){var t={sitekey:i.attr("data-sitekey"),type:i.attr("data-type"),size:i.attr("data-size"),theme:i.attr("data-theme"),badge:i.attr("data-badge"),tabindex:i.attr("data-tabindex")},a=i.attr("data-callback"),r=i.attr("data-expired-callback");a&&"function"==typeof window[a]&&(t.callback=window[a]),r&&"function"==typeof window[r]&&(t["expired-callback"]=window[r]);var o=grecaptcha.render(i[0],t);window.recaptchaWidgets&&recaptchaWidgets.push(o)}}))}else{if(!grecaptcha.execute)return;var i=jQuery('script[src*="google.com/recaptcha/api.js"]').attr("src").replace(/^.*render=(.*)$/,"$1").split("&")[0];grecaptcha.execute(i,{action:"homepage"}).then((function(i){e.find('form [name="g-recaptcha-response]').val(i)}))}}(i)),void 0!==window.et_reinit_waypoint_modules&&window.et_reinit_waypoint_modules(),i},DiviArea.Core.deactivateContainer=function(i){DiviArea.Core.isArea(i)&&(DiviArea.Debug.debug("Deactivate all triggers in area",i.theId()),i.find("[data-area-id]").each((function(){!function(e){DiviArea.Debug.debug("Remove trigger:",e[0]),e.removeAttr("data-area-id"),e.removeClass("popup-trigger"),e.off("._da")}(e(this))})))},DiviArea.Core.attachArea=function(e){r||(r=!0,l("show",e),r=!1),DiviArea.Data.addVisibleArea(e),e.attach()},DiviArea.Core.detachArea=function(e){if(r||(r=!0,l("hide",e),r=!1),e.inDom()){if(!DiviArea.Core.isArea(e)||!e.inDom())return;e.removeClass("__is_animating"),DiviArea.Data.removeVisibleArea(e),DiviArea.Core.blurArea(e),e.detach()}},DiviArea.Core.focusArea=function(e){var i=DiviArea.Utils.getOption("activePopupClass");e&&(e.get(),DiviArea.Core.activateContainer(e),e.hasClass(i)||(e.addClass(i),e.doAction("focus_area")))},DiviArea.Core.blurArea=function(e){var i=DiviArea.Utils.getOption("activePopupClass");e&&(e.get(),DiviArea.Core.deactivateContainer(e),e.hasClass(i)&&(e.removeClass(i),e.doAction("blur_area")))},DiviArea.Core.setupHoverArea=function(t){var a=t.getData("attachto"),r=t.get(),o=t.getWrap();if(a.length){var n=DiviArea.Utils.isPosition(a,"fixed"),s=t.theId(),l=t.getData("closeTrigger"),d=1e3*t.getData("closedelay"),c=!1,v=!1,u=!1;i&&(u=new i((function(e){for(var i=0;i<e.length;i++){var t=e[i].contentRect,a=t.width+"-"+t.height;a!==v&&(v=a,g())}}),{box:"border-box"})),u&&u.observe(a[0]),"click"===l?e(document).on("click."+t.theKey(),(function(i){e(i.target).closest(s).length||h()})):"hover"===l&&(r.on("mouseleave._dah",h),a.on("mouseleave._dah",h)),a.on("mouseenter._dah",D),r.on("mouseenter._dah",D),t.isVisible()?p():t.addActionOnce("show_area",p),DiviArea.Debug.debug("Prepared positioning of hover area")}else DiviArea.Debug.error("Hover Area without alignment element found");function p(){DiviArea.Debug.info("📐 Position area relative to element:",a),g()}function g(){var e=n?a[0].getBoundingClientRect():DiviArea.Utils.getClientRect(a),i=t.getData("positionv"),r=t.getData("positionh"),s=t.getSize(),l={left:"",top:"",right:"",bottom:"",width:"",height:"",position:n?"fixed":"absolute"};"top"===i||"bottom"===i?(l.top="top"===i?e.top-s.height:e.bottom,l.left=e.left+e.width/2-s.width/2):"left"===r||"right"===r?(l.left="left"===r?e.left-s.width:e.right,l.top=e.top+e.height/2-s.height/2):DiviArea.Debug.error("Invalid position",t.getData("position")),l.top<0&&(l.top=0),l.left<0&&(l.left=0),l.left+s.width>window.innerWidth&&(l.left=window.innerWidth-s.width),DiviArea.Debug.debug("Area position:",l),o.css(l)}function h(){D(),c=window.setTimeout((function(){var i=t.getData("attachto");i&&i.length&&a!==i||(u&&u.disconnect(),e(document).off("."+t.theKey()),r.off("._dah"),a.off("._dah"),DiviArea.hide(t))}),d)}function D(){c&&window.clearTimeout(c),c=!1}},DiviArea.Core.disableBodyScroll=function(){var i=e("body");!0!==i.data("da-disable-scroll")&&(i.data("da-disable-scroll",!0),i.addClass(DiviArea.Utils.getOption("openPopupClass")),DiviArea.Utils.bindPassiveEvent([i,DiviArea.getOverlay()],"mousewheel touchmove",c),DiviArea.doAction("disabled_scrolling"))},DiviArea.Core.enableBodyScroll=function(){var i=e("body");!0===i.data("da-disable-scroll")&&(i.data("da-disable-scroll",!1),i.removeClass(DiviArea.Utils.getOption("openPopupClass")),DiviArea.Utils.unbindPassiveEvent([i,DiviArea.getOverlay()],"mousewheel touchmove",c),DiviArea.doAction("enabled_scrolling"))},DiviArea.Core.closeMainMenu=function(){e(".et_pb_fullscreen_menu_active").length?e(".et_toggle_fullscreen_menu").first().trigger("click"):e(".et_pb_slide_menu_active").length&&e(".et_toggle_slide_menu").first().trigger("click")}}(jQuery),function(e){DiviArea.Data=DiviArea.Data||{};var i={},t=[],a={};DiviArea.Data.sanitizeId=function(e,i){if(!e)return"";if(e instanceof DiviAreaItem)return e.theId();if(e instanceof jQuery)return"#"+e.attr("id");if(e){if(i){var t=new RegExp("^#"+i+":");e=e.replace(t,"#",e)}"#"!==e[0]&&(e="#"+e)}return e.length>1?e:""},DiviArea.Data.getRealId=function(e){var t=DiviArea.Data.sanitizeId(e),r=DiviArea.Data.sanitizeId(a[t]);return t&&void 0!==i[t]?t:r&&void 0!==i[r]?r:""},DiviArea.Data.addAltId=function(e,i){function t(i){i=DiviArea.Data.sanitizeId(i),e!==i&&(null===e?delete a[i]:a[i]=e)}e=DiviArea.Data.sanitizeId(e),Array.isArray(i)?i.forEach((function(e){return t(e)})):t(i)},DiviArea.Data.getArea=function(e){if(e instanceof DiviAreaItem)return e;e instanceof jQuery&&(e=e.attr("id"));var t=DiviArea.Data.getRealId(e);return!!t&&i[t]},DiviArea.Data.createArea=function(e,t,a){return a=DiviArea.Data.sanitizeId(a),i[a]=new DiviAreaItem(e,t),i[a]},DiviArea.Data.getAllIds=function(e){var t=[];if(DiviArea.Core.isArea(e)){var r=e.theId();for(var o in t.push(r),a)r===a[o]&&t.push(o)}else{for(var n in i){i[n].isType(e)&&t.push(n)}for(var s in a){var l=a[s];i[l].isType(e)&&t.push(s)}}return t},DiviArea.Data.loopAllAreas=function(e,t){for(var a in i){var r=i[a];r.isType(e)&&t(r,a)}},DiviArea.Data.countVisibleAreas=function(e){if(!e||"any"===e)return t.length;var i=0;return DiviArea.Data.loopVisibleAreas(e,(function(){return i++})),i},DiviArea.Data.addVisibleArea=function(e){if(!(e=DiviArea.getArea(e)))return!1;if(e.isType("popup")||!DiviArea.Data.countVisibleAreas("popup"))t.push(e);else for(var i=0;i<t.length;i++)if(t[i].isType("popup")){t.splice(i,0,e);break}},DiviArea.Data.removeVisibleArea=function(e){if(!(e=DiviArea.getArea(e)))return!1;for(var i=e.theId(),a=t.length-1;a>=0;a--){t[a].theId()===i&&t.splice(a,1)}},DiviArea.Data.getVisibleArea=function(e,i){var a=t.length-1;if(!e&&!i)return t[a];if(e){var r=DiviArea.getArea(e);return!!r&&(!!r.isType(i)&&(!!r.isVisible()&&r))}for(var o=a;o>=0;o--){var n=t[o];if(n.isType(i))return n}return!1},DiviArea.Data.loopVisibleAreas=function(e,i,a){for(var r=t.length,o=a?r-1:0,n=0;n<r;n++){var s=t[o];o+=a?-1:1,s.isType(e)&&i(s,n)}}}(),function(e){var i=null,t=!1;function a(e){DiviArea.Debug.info("⚡️ Click on background overlay"),e.preventDefault(),DiviArea.doAction("click_overlay");var i=DiviArea.Data.getVisibleArea(null,"popup");return i?i.getData("ismodal")?(DiviArea.Debug.debug("Ignore click:",'Top-most popup is marked as "modal"'),!1):DiviArea.applyFilters("ignore_overlay_click",!1)?(DiviArea.Debug.debug("Ignore click:","Manually cancelled via filter"),!1):(DiviArea.doAction("close_area",null,"overlay"),DiviArea.Data.countVisibleAreas("popup")||DiviArea.hideOverlay(),!1):(DiviArea.Debug.debug("Ignore click:","No visible Popups found"),!1)}DiviArea.showOverlay=function(r){return null===i&&((i=e("<div />")).addClass(DiviArea.Utils.getOption("overlayClass")),i.on("click.popup",a),DiviArea.doAction("init_overlay",i)),r&&!isNaN(r)||(r=DiviArea.Utils.getOption("zIndex"),r+=Math.max(0,DiviArea.Data.countVisibleAreas())),i.css({zIndex:r}),t||(t=!0,DiviArea.Debug.info("⤴️ Show background overlay"),i.detach().appendTo(DiviArea.Core.getContext()),i.fadeIn(DiviArea.Utils.getOption("animateSpeed"),(function(){t&&DiviArea.Core.disableBodyScroll()})),DiviArea.doAction("show_overlay",i),DiviArea.Core.closeMainMenu()),r},DiviArea.hideOverlay=function(){t&&(t=!1,DiviArea.Debug.info("⤵️ Hide background overlay"),i.hide().detach(),DiviArea.Core.enableBodyScroll(),DiviArea.doAction("hide_overlay",i))},DiviArea.getOverlay=function(){return i}}(jQuery),function(){DiviArea.UI=DiviArea.UI||{};var e={};function i(e,i,t){t=t||e.data("et_waypoint_max_instances")||1;var a=e.data("et_waypoint")||[];if(a.length<t){var r=e.waypoint(i);r&&r.length>0&&(a.push(r[0]),e.data("et_waypoint",a))}else for(var o=0;o<a.length;o++)a[o].context.refresh()}DiviArea.UI.animateArea=function(t,a,r){var o=!1,n=!1;window.TweenLite&&t.isType("flyin")&&(n=!0),"function"!=typeof r&&(r=function(){}),"hide"!==a||t.isType("flyin")?(t.hasClass("et_pb_section")&&jQuery.fn.waypoint&&"yes"!==et_pb_custom.ignore_waypoints&&function(t){var a,r=t.attr("data-animation");if(!r)return!1;if(!(a=e[r]))return!1;jQuery("body").css("overflow-x","hidden"),jQuery("#page-container").css("overflow-y","hidden"),t.attr({"data-animation-style":a.style,"data-animation-repeat":"once"===a.repeat?"":"infinite","data-animation-duration":a.duration,"data-animation-delay":a.delay,"data-animation-intensity":a.intensity,"data-animation-starting-opacity":a.starting_opacity,"data-animation-speed-curve":a.speed_curve}),i(t,{offset:"100%",handler:function(){!function(e){var i=e.attr("data-animation-style"),t=e.attr("data-animation-repeat"),a=e.attr("data-animation-duration"),r=e.attr("data-animation-delay"),o=e.attr("data-animation-intensity"),n=e.attr("data-animation-starting-opacity"),s=e.attr("data-animation-speed-curve");!function(e){for(var i=[],t=e.get(0).attributes,a=0;a<t.length;a++)"data-animation-"===t[a].name.substring(0,15)&&i.push(t[a].name);jQuery.each(i,(function(i,t){e.removeAttr(t)}))}(e);var l=isNaN(parseInt(n))?0:.01*parseInt(n);-1===jQuery.inArray(s,["linear","ease","ease-in","ease-out","ease-in-out"])&&(s="ease-in-out"),e.css({"animation-duration":a,"animation-delay":r,opacity:l,"animation-timing-function":s});for(var d={},c=isNaN(parseInt(o))?50:parseInt(o),v=["slide","zoom","flip","fold","roll"],u=!1,p=!1,g=0;g<v.length;g++){var h=v[g];if(i&&i.substr(0,h.length)===h){u=h,""!==(p=i.substr(h.length,i.length))&&(p=p.toLowerCase());break}}!1!==u&&!1!==p&&(d=function(e,i,t){var a={};switch(e){case"slide":switch(i){case"top":a={transform:"translate3d(0, "+(r=-2*t)+"%, 0)"};break;case"right":a={transform:"translate3d("+(r=2*t)+"%, 0, 0)"};break;case"bottom":a={transform:"translate3d(0, "+(r=2*t)+"%, 0)"};break;case"left":var r=-2*t;a={transform:"translate3d("+r+"%, 0, 0)"};break;default:a={transform:"scale3d("+(o=.01*(100-t))+", "+o+", "+o+")"}}break;case"zoom":var o=.01*(100-t);switch(i){case"top":case"right":case"bottom":case"left":default:a={transform:"scale3d("+o+", "+o+", "+o+")"}}break;case"flip":switch(i){case"right":a={transform:"perspective(2000px) rotateY("+(n=Math.ceil(.9*t))+"deg)"};break;case"left":a={transform:"perspective(2000px) rotateY("+(n=-1*Math.ceil(.9*t))+"deg)"};break;case"top":default:a={transform:"perspective(2000px) rotateX("+(n=Math.ceil(.9*t))+"deg)"};break;case"bottom":a={transform:"perspective(2000px) rotateX("+(n=-1*Math.ceil(.9*t))+"deg)"}}break;case"fold":switch(i){case"top":a={transform:"perspective(2000px) rotateX("+(n=-1*Math.ceil(.9*t))+"deg)"};break;case"bottom":a={transform:"perspective(2000px) rotateX("+(n=Math.ceil(.9*t))+"deg)"};break;case"left":a={transform:"perspective(2000px) rotateY("+(n=Math.ceil(.9*t))+"deg)"};break;case"right":default:a={transform:"perspective(2000px) rotateY("+(n=-1*Math.ceil(.9*t))+"deg)"}}break;case"roll":switch(i){case"right":case"bottom":a={transform:"rotateZ("+(n=-1*Math.ceil(3.6*t))+"deg)"};break;case"top":case"left":a={transform:"rotateZ("+(n=Math.ceil(3.6*t))+"deg)"};break;default:var n=Math.ceil(3.6*t);a={transform:"rotateZ("+n+"deg)"}}}return a}(u,p,c)),jQuery.isEmptyObject(d)||e.css(d),e.addClass("et_animated"),e.addClass(i),e.addClass(t)}(jQuery(this.element))}})}(t.get())&&(o=!0),n?function(e,i,t){DiviArea.Debug.debug("Animate Area using GSAP");var a=DiviArea.Utils.getOption("animateSpeed"),r={},o={},n=e.get();n.css({opacity:"show"===i?0:1,transition:"all 0s"}),n.show(),window.setTimeout((function(){"left"===e.getData("positionh")?(r.left=-1*n.outerWidth(),o.left=0):"right"===e.getData("positionh")?(r.right=-1*n.outerWidth(),o.right=0):"top"===e.getData("positionv")?(r.top=-1*n.outerHeight(),o.top=0):"bottom"===e.getData("positionv")&&(r.bottom=-1*n.outerHeight(),o.bottom=0),r.opacity=1,o.opacity=1,"hide"===i?(n.css(o),TweenLite.to(n,a/1e3,{css:r})):(n.css(r),TweenLite.to(n,a/1e3,{css:o})),window.setTimeout(t,a)}),5)}(t,a,r):o?function(e,t,a){DiviArea.Debug.debug("Animate Area using a Divi Animation");var r=e.get();r.show(),r.css({opacity:0}),window.setTimeout((function(){r.css({opacity:""}),i(r,{offset:"100%",handler:function(){r.addClass("et-animated"),a()}},2)}),10)}(t,0,r):function(e,i,t){var a=e.get(),r=DiviArea.Utils.getOption("animateSpeed");"show"===i?(DiviArea.Debug.debug("Animate Area using jQuery fadeIn",r),a.fadeIn(r,t)):"hide"===i&&(DiviArea.Debug.debug("Animate Area using jQuery fadeOut",r),a.fadeOut(r,t))}(t,a,r)):r()},DiviArea.UI.initializeAreaAnimation=function(i){if(!window.et_animation_data||!window.et_animation_data.length>0)return!1;i.removeClass("et-waypoint"),i.removeClass("et-animated");for(var t=0;t<et_animation_data.length;t++){var a=!1,r=et_animation_data[t];r&&(r.class&&i.hasClass(r.class)&&r.style&&r.repeat&&r.duration&&r.delay&&r.intensity&&r.starting_opacity&&r.speed_curve&&(a=r.class,i.addClass("pfd-waypoint"),i.attr("data-animation",a),e[a]=r,et_animation_data[t].class=void 0))}}}(),function(){DiviArea.Debug=DiviArea.Debug||{};var e=!1,i=window.DiviAreaConfig;DiviArea.Debug.group=function(t){if(i.debug&&console.group){var a=!e||t&&t!==e;if(e&&(console.groupEnd(),e=!1),t&&a){var r=Array.prototype.slice.call(arguments);r.unshift("[DiviAreas]"),console.group.apply(this,r),e=t}}},DiviArea.Debug.table=function(){if(i.debug){var e=Array.prototype.slice.call(arguments);Array.isArray(e[0])||(e=[e]),console.table?console.table.apply(this,e):console.log.apply(this,e)}},DiviArea.Debug.verbose=function(){if(i.debug&&i.debugVerbose){var e=Array.prototype.slice.call(arguments);e.unshift("color:#cfd8dc;font-style:italic"),e.unshift("[DiviAreas] %c%s"),console.debug.apply(this,e)}},DiviArea.Debug.debug=function(){if(i.debug){var e=Array.prototype.slice.call(arguments);e.unshift("color:#90a4ae"),e.unshift("[DiviAreas] %c%s"),console.debug.apply(this,e)}},DiviArea.Debug.info=function(){if(i.debug){var e=Array.prototype.slice.call(arguments);e.unshift("color:#0288d1;background:#fafcfe"),e.unshift("[DiviAreas] %c%s"),console.log.apply(this,e)}},DiviArea.Debug.error=function(){var e=Array.prototype.slice.call(arguments);e.unshift("[DiviAreas]"),console.error.apply(this,e)},DiviArea.Debug.sysInfo=function(){var e=["\n----------"];if(e.push("Please copy-paste this information into your support ticket:"),e.push("----------\n"),DiviArea.lib&&DiviArea.version&&e.push(" • js_api: "+DiviArea.lib+" "+DiviArea.version),window.DiviAreaConfig&&DiviAreaConfig.sys&&DiviAreaConfig.sys.plugin)for(var i in DiviAreaConfig.sys)try{e.push(" • "+i+": "+" ".repeat(Math.max(0,11-i.length))+DiviAreaConfig.sys[i])}catch(e){}return e.push(" • browser: "+navigator.userAgent),e.push("\n----------\n"),e.join("\n")}}(),t=!0,(a={}).silent=DiviArea.Hooks.silent,a.removeFilter=DiviArea.Hooks.removeFilter,a.removeAction=DiviArea.Hooks.removeAction,a.applyFilters=DiviArea.Hooks.applyFilters,a.doAction=DiviArea.Hooks.doAction,a.addFilter=DiviArea.Hooks.addFilter,a.addAction=DiviArea.Hooks.addAction,a.addActionOnce=DiviArea.Hooks.addActionOnce,DiviArea.Hooks.silent=function(){return t=!1,a.silent.apply(this,arguments)},DiviArea.removeFilter=DiviArea.Hooks.removeFilter=function(e){return t&&DiviArea.Debug.debug("Remove Filter:",e),t=!0,a.removeFilter.apply(this,arguments)},DiviArea.removeAction=DiviArea.Hooks.removeAction=function(e){return t&&DiviArea.Debug.debug("Remove Action:",e),t=!0,a.removeAction.apply(this,arguments)},DiviArea.applyFilters=DiviArea.Hooks.applyFilters=function(e){if(t){Array.isArray(e)||(e=[e]),DiviArea.Debug.info("📢️ Apply Filters:",e.join(" → "));for(var i=0;i<e.length;i++)DiviArea.Debug.debug(' ⚙ DiviArea.addFilter("'+e[i]+'", callback)')}return t=!0,a.applyFilters.apply(this,arguments)},DiviArea.doAction=DiviArea.Hooks.doAction=function(e){if(t){Array.isArray(e)||(e=[e]),DiviArea.Debug.info("📢️ Do Action:",e.join(" → "));for(var i=0;i<e.length;i++)DiviArea.Debug.debug(' ⚙ DiviArea.addAction("'+e[i]+'", callback)')}return t=!0,a.doAction.apply(this,arguments)},DiviArea.addFilter=DiviArea.Hooks.addFilter=function(e){return t&&DiviArea.Debug.debug("Add Filter:",e),t=!0,a.addFilter.apply(this,arguments)},DiviArea.addAction=DiviArea.Hooks.addAction=function(e){return t&&DiviArea.Debug.debug("Add Action:",e),t=!0,a.addAction.apply(this,arguments)},DiviArea.addActionOnce=DiviArea.Hooks.addActionOnce=function(e){return t&&DiviArea.Debug.debug("Add Action Once:",e),t=!0,a.addActionOnce.apply(this,arguments)},DiviArea.openPopup=function(e){DiviArea.Debug.error("DiviArea.openPopup() is deprecated. Please use DiviArea.show() instead"),DiviArea.show(e)},DiviArea.openArea=function(e){DiviArea.Debug.error("DiviArea.openArea() is deprecated. Please use DiviArea.show() instead"),DiviArea.show(e)},DiviArea.closePopup=function(e){DiviArea.Debug.error("DiviArea.closeArea() is deprecated. Please use DiviArea.hide() instead"),DiviArea.hide(e)},DiviArea.closeArea=function(e){DiviArea.Debug.error("DiviArea.closeArea() is deprecated. Please use DiviArea.hide() instead"),DiviArea.hide(e)},DiviArea.Data.configArea=function(e,i,t){DiviArea.Debug.error("DiviArea.configArea() is deprecated. Please use area.setData() instead");var a=DiviArea.getArea(e);if(a)if("object"!=typeof i)a.setData(i,t);else for(var r in i)i.hasOwnProperty(r)&&a.setData(r,i[r])},DiviArea.Hooks.silent().addAction("init_area",(function(e){DiviArea.Hooks.silent().doAction("init_area-"+e.theKey(),e)}),1),DiviArea.Hooks.silent().addAction("show_area",(function(e){DiviArea.Hooks.silent().doAction("show_area-"+e.theKey(),e)}),1),DiviArea.Hooks.silent().addAction("hide_area",(function(e){DiviArea.Hooks.silent().doAction("hide_area-"+e.theKey(),e)}),1),DiviArea.Hooks.silent().addAction("close_area",(function(e,i){e&&DiviArea.Hooks.silent().doAction("close_area-"+e.theKey(),e,i)}),1),DiviArea.Hooks.silent().addAction("blur_area",(function(e){DiviArea.Hooks.silent().doAction("blur_area-"+e.theKey(),e)}),1),DiviArea.Hooks.silent().addAction("focus_area",(function(e){DiviArea.Hooks.silent().doAction("focus_area-"+e.theKey(),e)}),1),DiviArea.Hooks.silent().addAction("before_show_area",(function(e,i){DiviArea.Hooks.silent().doAction("before_show_area-"+e.theKey(),e,i)}),1),DiviArea.Hooks.silent().addAction("before_hide_area",(function(e,i){DiviArea.Hooks.silent().doAction("before_hide_area-"+e.theKey(),e,i)}),1),DiviArea.Hooks.silent().addFilter("ignore_close_area",(function(e,i,t){return e=DiviArea.Hooks.silent().applyFilters("before_close_area",e,i,t),e=DiviArea.Hooks.silent().applyFilters("before_close_area-"+i.theKey(),e,i,t)}),1),DiviArea.Hooks.silent().addFilter("ignore_esc_key",(function(e){return e=DiviArea.Hooks.silent().applyFilters("esc_key_pressed",e)}),1),DiviArea.Hooks.silent().addAction("area_close_button",(function(e){e.addClass("evr-close_wrap"),e.find(">a").addClass("evr-close")}),1),DiviArea.Hooks.silent().addAction("area_wrap",(function(e){e.addClass("popup_outer_wrap")}),1),DiviArea.Hooks.silent().addAction("init_overlay",(function(e){e.addClass("evr_fb_popup_modal")}),1),DiviArea.Hooks.silent().addAction("refresh_area",(function(e){var i={notmobile:DiviArea.Utils.getOption("notMobileClass"),nottablet:DiviArea.Utils.getOption("notTabletClass"),notdesktop:DiviArea.Utils.getOption("notDesktopClass"),showclose:DiviArea.Utils.getOption("withCloseClass"),hideclose:DiviArea.Utils.getOption("noCloseClass"),closealt:DiviArea.Utils.getOption("altCloseClass"),ismodal:DiviArea.Utils.getOption("modalIndicatorClass"),noshadow:DiviArea.Utils.getOption("noShadowClass"),darkmode:DiviArea.Utils.getOption("darkModeClass"),singleton:DiviArea.Utils.getOption("singletonClass")};for(var t in i)e.getData(t)?e.addClass(i[t]):e.removeClass(i[t])}),1),DiviArea.listAreas=DiviArea.Data.getAllIds,DiviArea.configArea=DiviArea.Data.configArea,DiviArea.getArea=DiviArea.Data.getArea,(r=e)&&r.default,DiviArea.init(!1)}();
js/ie-compat.js ADDED
@@ -0,0 +1 @@
 
1
+ !function(e){"function"==typeof define&&define.amd?define(e):e()}((function(){"use strict";var e,t=[],n="ResizeObserver loop completed with undelivered notifications.";!function(e){e.BORDER_BOX="border-box",e.CONTENT_BOX="content-box",e.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"}(e||(e={}));var r,o,i,s,a,c=function(){function e(e,t,n,r){return this.x=e,this.y=t,this.width=n,this.height=r,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,Object.freeze(this)}return e.prototype.toJSON=function(){var e=this;return{x:e.x,y:e.y,top:e.top,right:e.right,bottom:e.bottom,left:e.left,width:e.width,height:e.height}},e.fromRect=function(t){return new e(t.x,t.y,t.width,t.height)},e}(),u=function(e){return e instanceof SVGElement&&"getBBox"in e},h=function(e){if(u(e)){var t=e.getBBox(),n=t.width,r=t.height;return!n&&!r}var o=e,i=o.offsetWidth,s=o.offsetHeight;return!(i||s||e.getClientRects().length)},f=function(e){var t,n,r=null===(n=null===(t=e)||void 0===t?void 0:t.ownerDocument)||void 0===n?void 0:n.defaultView;return!!(r&&e instanceof r.Element)},d="undefined"!=typeof window?window:{},l=new WeakMap,v=/auto|scroll/,p=/^tb|vertical/,g=/msie|trident/i.test(d.navigator&&d.navigator.userAgent),b=function(e){return parseFloat(e||"0")},m=function(e,t,n){return void 0===e&&(e=0),void 0===t&&(t=0),void 0===n&&(n=!1),Object.freeze({inlineSize:(n?t:e)||0,blockSize:(n?e:t)||0})},w=Object.freeze({devicePixelContentBoxSize:m(),borderBoxSize:m(),contentBoxSize:m(),contentRect:new c(0,0,0,0)}),y=function(e,t){if(void 0===t&&(t=!1),l.has(e)&&!t)return l.get(e);if(h(e))return l.set(e,w),w;var n=getComputedStyle(e),r=u(e)&&e.ownerSVGElement&&e.getBBox(),o=!g&&"border-box"===n.boxSizing,i=p.test(n.writingMode||""),s=!r&&v.test(n.overflowY||""),a=!r&&v.test(n.overflowX||""),f=r?0:b(n.paddingTop),d=r?0:b(n.paddingRight),y=r?0:b(n.paddingBottom),E=r?0:b(n.paddingLeft),x=r?0:b(n.borderTopWidth),T=r?0:b(n.borderRightWidth),z=r?0:b(n.borderBottomWidth),S=E+d,B=f+y,O=(r?0:b(n.borderLeftWidth))+T,R=x+z,M=a?e.offsetHeight-R-e.clientHeight:0,k=s?e.offsetWidth-O-e.clientWidth:0,C=o?S+O:0,N=o?B+R:0,A=r?r.width:b(n.width)-C-k,D=r?r.height:b(n.height)-N-M,F=A+S+k+O,P=D+B+M+R,_=Object.freeze({devicePixelContentBoxSize:m(Math.round(A*devicePixelRatio),Math.round(D*devicePixelRatio),i),borderBoxSize:m(F,P,i),contentBoxSize:m(A,D,i),contentRect:new c(E,f,A,D)});return l.set(e,_),_},E=function(t,n,r){var o=y(t,r),i=o.borderBoxSize,s=o.contentBoxSize,a=o.devicePixelContentBoxSize;switch(n){case e.DEVICE_PIXEL_CONTENT_BOX:return a;case e.BORDER_BOX:return i;default:return s}},x=function(e){var t=y(e);this.target=e,this.contentRect=t.contentRect,this.borderBoxSize=[t.borderBoxSize],this.contentBoxSize=[t.contentBoxSize],this.devicePixelContentBoxSize=[t.devicePixelContentBoxSize]},T=function(e){if(h(e))return 1/0;for(var t=0,n=e.parentNode;n;)t+=1,n=n.parentNode;return t},z=function(){var e=1/0,n=[];t.forEach((function(t){if(0!==t.activeTargets.length){var r=[];t.activeTargets.forEach((function(t){var n=new x(t.target),o=T(t.target);r.push(n),t.lastReportedSize=E(t.target,t.observedBox),o<e&&(e=o)})),n.push((function(){t.callback.call(t.observer,r,t.observer)})),t.activeTargets.splice(0,t.activeTargets.length)}}));for(var r=0,o=n;r<o.length;r++){(0,o[r])()}return e},S=function(e){t.forEach((function(t){t.activeTargets.splice(0,t.activeTargets.length),t.skippedTargets.splice(0,t.skippedTargets.length),t.observationTargets.forEach((function(n){n.isActive()&&(T(n.target)>e?t.activeTargets.push(n):t.skippedTargets.push(n))}))}))},B=function(){var e,r=0;for(S(r);t.some((function(e){return e.activeTargets.length>0}));)r=z(),S(r);return t.some((function(e){return e.skippedTargets.length>0}))&&("function"==typeof ErrorEvent?e=new ErrorEvent("error",{message:n}):((e=document.createEvent("Event")).initEvent("error",!1,!1),e.message=n),window.dispatchEvent(e)),r>0},O=[],R=function(e){if(!r){var t=0,n=document.createTextNode("");new MutationObserver((function(){return O.splice(0).forEach((function(e){return e()}))})).observe(n,{characterData:!0}),r=function(){n.textContent=""+(t?t--:t++)}}O.push(e),r()},M=0,k={attributes:!0,characterData:!0,childList:!0,subtree:!0},C=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],N=function(e){return void 0===e&&(e=0),Date.now()+e},A=!1,D=new(function(){function e(){var e=this;this.stopped=!0,this.listener=function(){return e.schedule()}}return e.prototype.run=function(e){var t=this;if(void 0===e&&(e=250),!A){A=!0;var n,r=N(e);n=function(){var n=!1;try{n=B()}finally{if(A=!1,e=r-N(),!M)return;n?t.run(1e3):e>0?t.run(e):t.start()}},R((function(){requestAnimationFrame(n)}))}},e.prototype.schedule=function(){this.stop(),this.run()},e.prototype.observe=function(){var e=this,t=function(){return e.observer&&e.observer.observe(document.body,k)};document.body?t():d.addEventListener("DOMContentLoaded",t)},e.prototype.start=function(){var e=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),C.forEach((function(t){return d.addEventListener(t,e.listener,!0)})))},e.prototype.stop=function(){var e=this;this.stopped||(this.observer&&this.observer.disconnect(),C.forEach((function(t){return d.removeEventListener(t,e.listener,!0)})),this.stopped=!0)},e}()),F=function(e){!M&&e>0&&D.start(),!(M+=e)&&D.stop()},P=function(){function t(t,n){this.target=t,this.observedBox=n||e.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return t.prototype.isActive=function(){var e,t=E(this.target,this.observedBox,!0);return e=this.target,u(e)||function(e){switch(e.tagName){case"INPUT":if("image"!==e.type)break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1}(e)||"inline"!==getComputedStyle(e).display||(this.lastReportedSize=t),this.lastReportedSize.inlineSize!==t.inlineSize||this.lastReportedSize.blockSize!==t.blockSize},t}(),_=function(e,t){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=e,this.callback=t},j=new WeakMap,I=function(e,t){for(var n=0;n<e.length;n+=1)if(e[n].target===t)return n;return-1},L=function(){function e(){}return e.connect=function(e,t){var n=new _(e,t);j.set(e,n)},e.observe=function(e,n,r){var o=j.get(e),i=0===o.observationTargets.length;I(o.observationTargets,n)<0&&(i&&t.push(o),o.observationTargets.push(new P(n,r&&r.box)),F(1),D.schedule())},e.unobserve=function(e,n){var r=j.get(e),o=I(r.observationTargets,n),i=1===r.observationTargets.length;o>=0&&(i&&t.splice(t.indexOf(r),1),r.observationTargets.splice(o,1),F(-1))},e.disconnect=function(e){var t=this,n=j.get(e);n.observationTargets.slice().forEach((function(n){return t.unobserve(e,n.target)})),n.activeTargets.splice(0,n.activeTargets.length)},e}(),W=function(){function e(e){if(0===arguments.length)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if("function"!=typeof e)throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");L.connect(this,e)}return e.prototype.observe=function(e,t){if(0===arguments.length)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!f(e))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");L.observe(this,e,t)},e.prototype.unobserve=function(e){if(0===arguments.length)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!f(e))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");L.unobserve(this,e)},e.prototype.disconnect=function(){L.disconnect(this)},e.toString=function(){return"function ResizeObserver () { [polyfill code] }"},e}();Element.prototype.matches||(Element.prototype.matches=Element.prototype.matchesSelector||Element.prototype.mozMatchesSelector||Element.prototype.msMatchesSelector||Element.prototype.oMatchesSelector||Element.prototype.webkitMatchesSelector||function(e){for(var t=(this.document||this.ownerDocument).querySelectorAll(e),n=t.length;--n>=0&&t.item(n)!==this;);return n>-1}),Array.from||(Array.from=(o=Object.prototype.toString,i=function(e){return"function"==typeof e||"[object Function]"===o.call(e)},s=Math.pow(2,53)-1,a=function(e){var t=function(e){var t=Number(e);return isNaN(t)?0:0!==t&&isFinite(t)?(t>0?1:-1)*Math.floor(Math.abs(t)):t}(e);return Math.min(Math.max(t,0),s)},function(e){var t=this,n=Object(e);if(null==e)throw new TypeError("Array.from requires an array-like object - not null or undefined");var r,o=arguments.length>1?arguments[1]:void 0;if(void 0!==o){if(!i(o))throw new TypeError("Array.from: when provided, the second argument must be a function");arguments.length>2&&(r=arguments[2])}for(var s,c=a(n.length),u=i(t)?Object(new t(c)):new Array(c),h=0;h<c;)s=n[h],u[h]=o?void 0===r?o(s,h):o.call(r,s,h):s,h+=1;return u.length=c,u})),window.ResizeObserver=W}));
js/loader.js CHANGED
@@ -1 +1 @@
1
- !function(e){var i={};function r(t){if(i[t])return i[t].exports;var n=i[t]={i:t,l:!1,exports:{}};return e[t].call(n.exports,n,n.exports,r),n.l=!0,n.exports}r.m=e,r.c=i,r.d=function(e,i,t){r.o(e,i)||Object.defineProperty(e,i,{enumerable:!0,get:t})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,i){if(1&i&&(e=r(e)),8&i)return e;if(4&i&&"object"==typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(r.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&i&&"string"!=typeof e)for(var n in e)r.d(t,n,function(i){return e[i]}.bind(null,n));return t},r.n=function(e){var i=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(i,"a",i),i},r.o=function(e,i){return Object.prototype.hasOwnProperty.call(e,i)},r.p="",r(r.s=1)}([,function(e,i,r){e.exports=r(2)},function(e,i,r){"use strict";window.DiviArea=window.DiviPopup={loaded:!1},r(3)},function(e,i,r){"use strict";!function(){DiviArea.Hooks={};var e={};function i(i,r,t){var n,o,a;if("string"==typeof i)if(e[i]){if(r)if((n=e[i])&&t)for(a=n.length;a--;)(o=n[a]).callback===r&&o.context===t&&(n[a]=!1);else for(a=n.length;a--;)n[a].callback===r&&(n[a]=!1)}else e[i]=[]}function r(i,r,t,n){if("string"==typeof i){var o={callback:r,priority:t,context:n},a=e[i];a?(a.push(o),a=function(e){var i,r,t,n,o=e.length;for(n=1;n<o;n++)for(i=e[n],r=n;r>0;r--)(t=e[r-1]).priority>i.priority&&(e[r]=t,e[r-1]=i);return e}(a)):a=[o],e[i]=a}}function t(i,r,t){var n,o;for("string"==typeof r&&(r=[r]),n=0;n<r.length;n++){var a=e[r[n]],f=!1,c=void 0;if(a){var l=a.length;for(o=0;o<l;o++)if(a[o])if("filter"===i)void 0!==(c=a[o].callback.apply(a[o].context,t))&&(t[0]=c);else{if(!a[o]||"function"!=typeof a[o].callback)return!1;a[o].callback.apply(a[o].context,t)}else f=!0;if(f)for(o=l;o--;)a[o]||a.splice(o,1)}}if("filter"===i)return t[0]}DiviArea.Hooks.silent=function(){return DiviArea.Hooks},DiviArea.removeFilter=DiviArea.Hooks.removeFilter=function(e,r){i(e,r)},DiviArea.removeAction=DiviArea.Hooks.removeAction=function(e,r){i(e,r)},DiviArea.applyFilters=DiviArea.Hooks.applyFilters=function(e){for(var i=arguments.length,r=Array(i>1?i-1:0),n=1;n<i;n++)r[n-1]=arguments[n];return t("filter",e,r)},DiviArea.doAction=DiviArea.Hooks.doAction=function(e){for(var i=arguments.length,r=Array(i>1?i-1:0),n=1;n<i;n++)r[n-1]=arguments[n];t("action",e,r)},DiviArea.addFilter=DiviArea.Hooks.addFilter=function(e,i,t,n){r(e,i,parseInt(t||10,10),n||window)},DiviArea.addAction=DiviArea.Hooks.addAction=function(e,i,t,n){r(e,i,parseInt(t||10,10),n||window)},DiviArea.addActionOnce=DiviArea.Hooks.addActionOnce=function(e,t,n,o){r(e,t,parseInt(n||10,10),o||window),r(e,function(){i(e,t)},1+parseInt(n||10,10),o||window)}}()}]);
1
+ !function(){"use strict";!function(){window.DiviArea=window.DiviPopup={loaded:!1};var n=window.DiviArea,i=n.Hooks={},t={};function o(n,i,o){var e,r,c;if("string"==typeof n)if(t[n]){if(i)if((e=t[n])&&o)for(c=e.length;c--;)(r=e[c]).callback===i&&r.context===o&&(e[c]=!1);else for(c=e.length;c--;)e[c].callback===i&&(e[c]=!1)}else t[n]=[]}function e(n,i,o,e){if("string"==typeof n){var r={callback:i,priority:o,context:e},c=t[n];c?(c.push(r),c=function(n){var i,t,o,e,r=n.length;for(e=1;e<r;e++)for(i=n[e],t=e;t>0;t--)(o=n[t-1]).priority>i.priority&&(n[t]=o,n[t-1]=i);return n}(c)):c=[r],t[n]=c}}function r(n,i,o){var e,r;for("string"==typeof i&&(i=[i]),e=0;e<i.length;e++){var c=t[i[e]],f=!1,a=void 0;if(c){var l=c.length;for(r=0;r<l;r++)if(c[r])if("filter"===n)void 0!==(a=c[r].callback.apply(c[r].context,o))&&(o[0]=a);else{if(!c[r]||"function"!=typeof c[r].callback)return!1;c[r].callback.apply(c[r].context,o)}else f=!0;if(f)for(r=l;r--;)c[r]||c.splice(r,1)}}if("filter"===n)return o[0]}i.silent=function(){return i},n.removeFilter=i.removeFilter=function(n,i){o(n,i)},n.removeAction=i.removeAction=function(n,i){o(n,i)},n.applyFilters=i.applyFilters=function(n){for(var i=[],t=arguments.length-1;t-- >0;)i[t]=arguments[t+1];return r("filter",n,i)},n.doAction=i.doAction=function(n){for(var i=[],t=arguments.length-1;t-- >0;)i[t]=arguments[t+1];r("action",n,i)},n.addFilter=i.addFilter=function(n,i,t,o){e(n,i,parseInt(t||10,10),o||window)},n.addAction=i.addAction=function(n,i,t,o){e(n,i,parseInt(t||10,10),o||window)},n.addActionOnce=i.addActionOnce=function(n,i,t,r){e(n,i,parseInt(t||10,10),r||window),e(n,(function(){o(n,i)}),1+parseInt(t||10,10),r||window)}}()}();
plugin.php CHANGED
@@ -13,7 +13,7 @@
13
  * Author: divimode.com
14
  * Author URI: https://divimode.com/?utm_source=wpadmin&utm_medium=link&utm_campaign=popups-for-divi
15
  * Created: 30.12.2017
16
- * Version: 2.2.1
17
  * Text Domain: divi-popup
18
  * Domain Path: /lang
19
  * License: GPL v2 or later
@@ -40,51 +40,82 @@ defined( 'ABSPATH' ) || die();
40
  /**
41
  * A new version value will force refresh of CSS and JS files for all users.
42
  */
43
- define( 'DIVI_POPUP_VERSION', '2.2.1' );
44
 
 
 
 
 
 
45
  define( 'DIVI_POPUP_PLUGIN_FILE', __FILE__ );
 
 
 
 
 
 
46
  define( 'DIVI_POPUP_PLUGIN', plugin_basename( DIVI_POPUP_PLUGIN_FILE ) );
47
- define( 'DIVI_POPUP_PATH', plugin_dir_path( DIVI_POPUP_PLUGIN_FILE ) );
48
 
49
  /**
50
- * Simple handler for spl_autoload_register (autoload classes on demand).
51
  *
52
- * @since 0.1.0
53
- * @param string $class Class name.
54
- * @return bool True if the class-file was found and loaded.
55
  */
56
- function divi_popup_class_loader( $class ) {
57
- $class = strtolower( $class );
58
 
59
- if ( 'popups_for_divi' === substr( $class, 0, 15 ) ) {
60
- // Load a "Popups_For_Divi_" class from the includes folder.
61
- $module_file = str_replace( '_', '-', $class ) . '.php';
62
- $module_path = DIVI_POPUP_PATH . "include/class-{$module_file}";
63
- } else {
64
- // Not a Popups for Divi class, ignore it.
65
- return false;
66
- }
67
 
68
- if ( ! file_exists( $module_path ) ) {
69
- return false;
 
 
 
 
 
 
 
 
70
  }
71
 
72
- include_once $module_path;
73
- return true;
74
  }
75
 
76
- // Initialize the autoloader.
77
- spl_autoload_register( 'divi_popup_class_loader' );
78
-
79
  /**
80
- * Getter function that returns the main Divi_Areas_Pro instance.
 
81
  *
82
- * @since 2.0.4
83
- * @return Popups_For_Divi The main application instance.
 
 
 
 
 
 
 
 
 
84
  */
85
- function divi_popup() {
86
- return $GLOBALS['divi_popup'];
 
 
 
 
 
 
 
 
 
87
  }
88
 
89
- // Hook up the plugin.
90
- $GLOBALS['divi_popup'] = ( new Popups_For_Divi() )->setup_on( 'plugins_loaded' );
 
 
 
13
  * Author: divimode.com
14
  * Author URI: https://divimode.com/?utm_source=wpadmin&utm_medium=link&utm_campaign=popups-for-divi
15
  * Created: 30.12.2017
16
+ * Version: 2.2.2
17
  * Text Domain: divi-popup
18
  * Domain Path: /lang
19
  * License: GPL v2 or later
40
  /**
41
  * A new version value will force refresh of CSS and JS files for all users.
42
  */
43
+ define( 'DIVI_POPUP_VERSION', '2.2.2' );
44
 
45
+ /**
46
+ * Absolute path and file name of the main plugin file.
47
+ *
48
+ * @var string
49
+ */
50
  define( 'DIVI_POPUP_PLUGIN_FILE', __FILE__ );
51
+
52
+ /**
53
+ * Basename of the WordPress plugin. I.e., "plugin-dir/plugin-file.php".
54
+ *
55
+ * @var string
56
+ */
57
  define( 'DIVI_POPUP_PLUGIN', plugin_basename( DIVI_POPUP_PLUGIN_FILE ) );
 
58
 
59
  /**
60
+ * Absolute path to the plugin folder, with trailing slash.
61
  *
62
+ * @var string
 
 
63
  */
64
+ define( 'DIVI_POPUP_PATH', plugin_dir_path( DIVI_POPUP_PLUGIN_FILE ) );
 
65
 
66
+ /**
67
+ * Absolute URL to the plugin folder, with trailing slash.
68
+ *
69
+ * @var string
70
+ */
71
+ define( 'DIVI_POPUP_URL', plugin_dir_url( DIVI_POPUP_PLUGIN_FILE ) );
 
 
72
 
73
+ /**
74
+ * Getter function that returns the main Popups_For_Divi instance.
75
+ *
76
+ * @since 2.0.4
77
+ * @return PFD_App The main application instance.
78
+ */
79
+ function divi_popup() {
80
+ if ( empty( $GLOBALS['divi_popup'] ) ) {
81
+ $GLOBALS['divi_popup'] = new PFD_App();
82
+ $GLOBALS['divi_popup']->setup_on( 'plugins_loaded' );
83
  }
84
 
85
+ return $GLOBALS['divi_popup'];
 
86
  }
87
 
 
 
 
88
  /**
89
+ * Instead of using an autoloader that dynamically loads our classes, we have decided
90
+ * to include all dependencies during initialization.
91
  *
92
+ * We have the following reasons for this:
93
+ *
94
+ * 1. It makes the plugin structure more transparent: We can see all used files here.
95
+ * 2. The number of files is so small that autoloading does not save a lot of
96
+ * resources.
97
+ * 3. In a production build we want to make sure that files are always loaded in the
98
+ * same order, at the same time.
99
+ * 4. Every file is treated equal: No different treatment for classes vs function
100
+ * files.
101
+ *
102
+ * @since 2.2.2
103
  */
104
+ function divi_popup_load_core() {
105
+ // Load helpers.
106
+ require_once DIVI_POPUP_PATH . 'include/helper/exceptions.php';
107
+ require_once DIVI_POPUP_PATH . 'include/helper/plugin-compatibility.php';
108
+
109
+ // Load application modules.
110
+ require_once DIVI_POPUP_PATH . 'include/core/class-pfd-component.php';
111
+ require_once DIVI_POPUP_PATH . 'include/core/class-pfd-app.php';
112
+ require_once DIVI_POPUP_PATH . 'include/core/class-pfd-asset.php';
113
+ require_once DIVI_POPUP_PATH . 'include/core/class-pfd-editor.php';
114
+ require_once DIVI_POPUP_PATH . 'include/core/class-pfd-onboarding.php';
115
  }
116
 
117
+ // Load all dependencies.
118
+ divi_popup_load_core();
119
+
120
+ // Initialize the application.
121
+ divi_popup();
readme.txt CHANGED
@@ -2,7 +2,7 @@
2
  Contributors: strackerphil-1
3
  Tags: popup, marketing, divi
4
  Requires at least: 3.0.1
5
- Tested up to: 5.4.2
6
  Stable tag: trunk
7
  Requires PHP: 5.6
8
  License: GPLv2 or later
@@ -178,6 +178,17 @@ Attention: The JS API changes! Developers, please first read https://divimode.co
178
 
179
  == Changelog ==
180
 
 
 
 
 
 
 
 
 
 
 
 
181
  = 2.2.1 =
182
  * Fix: The close button does not trigger any scrollbars when hovered
183
  * Fix: Popups are now always hidden when the page loads - in some cases, Popups inside Headers/Footers were visible right when the page loaded
@@ -189,8 +200,6 @@ Attention: The JS API changes! Developers, please first read https://divimode.co
189
  * Improve: The close button is now outside the Popup container and can be positioned anywhere, via CSS
190
  * Improve: Minor performance optimizations in the JS code
191
 
192
- Plugin tested with WordPress 5.4.2 and Divi 4.4.8
193
-
194
  = 2.2.0 =
195
  * Change: Fully refactored JS API that is documented on https://divimode.com/knowledge-base/
196
  * Change: Some CSS class names have changed, e.g. "evr_fb_popup_modal" is now "da-overlay"
2
  Contributors: strackerphil-1
3
  Tags: popup, marketing, divi
4
  Requires at least: 3.0.1
5
+ Tested up to: 5.5.1
6
  Stable tag: trunk
7
  Requires PHP: 5.6
8
  License: GPLv2 or later
178
 
179
  == Changelog ==
180
 
181
+ = 2.2.2 =
182
+ * Improve: Images inside Areas are instantly loaded in Chrome (fixed a lazy-load bug).
183
+ * Improved: New logic to calculate Area size and position that supports orientation-change of mobile devices.
184
+ * Fix: WooCommerce pages now display all available Popups, not only the first one.
185
+ * Fix: Added support for IE 11.
186
+ * Fix: Popup text is no longer blurry in Windows browsers
187
+ * Change: New JS API function to identify an Area: `DiviAreaItem.hasId()`
188
+ * Change: Deprecated the "full-width" class, because it's not used anymore
189
+
190
+ Plugin tested with WordPress 5.5.6 and Divi 4.6.5
191
+
192
  = 2.2.1 =
193
  * Fix: The close button does not trigger any scrollbars when hovered
194
  * Fix: Popups are now always hidden when the page loads - in some cases, Popups inside Headers/Footers were visible right when the page loaded
200
  * Improve: The close button is now outside the Popup container and can be positioned anywhere, via CSS
201
  * Improve: Minor performance optimizations in the JS code
202
 
 
 
203
  = 2.2.0 =
204
  * Change: Fully refactored JS API that is documented on https://divimode.com/knowledge-base/
205
  * Change: Some CSS class names have changed, e.g. "evr_fb_popup_modal" is now "da-overlay"
wp-assets/banner-1544x500.jpg ADDED
Binary file
wp-assets/banner-772x250.jpg ADDED
Binary file
wp-assets/icon-128x128.jpg ADDED
Binary file
wp-assets/icon-256x256.jpg ADDED
Binary file
wp-assets/popups-for-divi-logo.jpg ADDED
Binary file
wp-assets/screenshot-1.png ADDED
Binary file
wp-assets/screenshot-2.png ADDED
Binary file
wp-assets/screenshot-3.png ADDED
Binary file
wp-assets/screenshot-4.png ADDED
Binary file
wp-assets/screenshot-5.png ADDED
Binary file