CMP – Coming Soon & Maintenance Plugin by NiteoThemes - Version 4.0.9

Version Description

Download this release

Release Info

Developer niteo
Plugin Icon 128x128 CMP – Coming Soon & Maintenance Plugin by NiteoThemes
Version 4.0.9
Comparing to
See all releases

Code changes from version 4.0.8 to 4.0.9

img/thumbnails/orion/screenshot1.jpg ADDED
Binary file
img/thumbnails/orion/screenshot2.jpg ADDED
Binary file
img/thumbnails/orion_thumbnail.jpg ADDED
Binary file
js/settings.js CHANGED
@@ -89,6 +89,7 @@ jQuery(document).ready(function ($) {
89
  toggle_settings('lang-switcher');
90
  toggle_settings('subscribe-popup');
91
  toggle_settings('inpage-subscribe');
 
92
 
93
  toggle_select('counter-action');
94
  toggle_select('subscribe-method');
@@ -96,6 +97,8 @@ jQuery(document).ready(function ($) {
96
  toggle_select('banner-video-source');
97
  toggle_select('progress-bar-type');
98
 
 
 
99
  // change all selects to select2
100
  jQuery(
101
  '.cmp-coming-soon-maintenance select:not(.headings-google-font):not(.content-google-font )'
@@ -1170,6 +1173,43 @@ jQuery(document).ready(function ($) {
1170
  });
1171
  }
1172
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1173
  // delete overlay color from premium themes after update 2.8
1174
  jQuery('.cmp-coming-soon-maintenance .table-wrapper.theme-setup h4').each(function () {
1175
  if (jQuery(this).html() == 'Overlay Color') {
89
  toggle_settings('lang-switcher');
90
  toggle_settings('subscribe-popup');
91
  toggle_settings('inpage-subscribe');
92
+ toggle_settings('tags');
93
 
94
  toggle_select('counter-action');
95
  toggle_select('subscribe-method');
97
  toggle_select('banner-video-source');
98
  toggle_select('progress-bar-type');
99
 
100
+ cmp_repeat_fields('tags');
101
+
102
  // change all selects to select2
103
  jQuery(
104
  '.cmp-coming-soon-maintenance select:not(.headings-google-font):not(.content-google-font )'
1173
  });
1174
  }
1175
 
1176
+ function cmp_repeat_fields(field_id) {
1177
+ if (!jQuery('#wrapper-' + field_id).length) {
1178
+ return;
1179
+ }
1180
+ jQuery('#add-' + field_id).click(function (e) {
1181
+ e.preventDefault();
1182
+ var $wrapper = jQuery('#wrapper-' + field_id);
1183
+ var $target = jQuery('#wrapper-' + field_id + ' .target-repeater-fields');
1184
+ var $fields = $wrapper.find('.source-repeater-fields').children().clone();
1185
+ $($fields[0]).val('');
1186
+ $($target).append($fields);
1187
+ });
1188
+
1189
+ cmp_delete_field(field_id);
1190
+ }
1191
+
1192
+ function cmp_delete_field(field_id) {
1193
+ jQuery('#wrapper-' + field_id + ' .target-repeater-fields').on(
1194
+ 'click',
1195
+ '.delete-' + field_id,
1196
+ function (e) {
1197
+ e.preventDefault();
1198
+ $(this).prev().remove();
1199
+ $(this).remove();
1200
+ }
1201
+ );
1202
+
1203
+ jQuery('#wrapper-' + field_id + ' .source-repeater-fields').on(
1204
+ 'click',
1205
+ '.delete-' + field_id,
1206
+ function (e) {
1207
+ e.preventDefault();
1208
+ $(this).prev().val('');
1209
+ }
1210
+ );
1211
+ }
1212
+
1213
  // delete overlay color from premium themes after update 2.8
1214
  jQuery('.cmp-coming-soon-maintenance .table-wrapper.theme-setup h4').each(function () {
1215
  if (jQuery(this).html() == 'Overlay Color') {
js/settings.min.js CHANGED
@@ -1 +1 @@
1
- jQuery(document).ready(function(e){var n=document.location.hash.substring(1),a=jQuery("#csoptions").attr("action"),t=jQuery("#csoptions fieldset:not(.skip-preview-validation *)").serialize();wp.codeEditor&&jQuery("#niteoCS_custom_css").length&&wp.codeEditor.initialize("niteoCS_custom_css"),navtab=function(e){jQuery(".cmp-coming-soon-maintenance .nav-tab-wrapper .nav-tab").removeClass("nav-tab-active"),jQuery(".nav-tab-wrapper ."+e).addClass("nav-tab-active"),jQuery(".cmp-coming-soon-maintenance .table-wrapper."+e).css("display","block"),jQuery(".cmp-coming-soon-maintenance .table-wrapper-css."+e).css("display","block"),jQuery(".cmp-coming-soon-maintenance .comingsoon."+e).css("display","block"),jQuery(".cmp-coming-soon-maintenance .table-wrapper:not(."+e+")").css("display","none"),jQuery(".cmp-coming-soon-maintenance .table-wrapper-css:not(."+e).css("display","none"),jQuery(".cmp-coming-soon-maintenance .comingsoon:not(."+e+")").css("display","none"),"install"==e?(jQuery(".cmp-coming-soon-maintenance .submit").css("display","none"),jQuery(".cmp-coming-soon-maintenance #csoptions").attr("action",a)):(jQuery(".cmp-coming-soon-maintenance .submit").css("display","block"),jQuery(".cmp-coming-soon-maintenance #csoptions").attr("action",a+"#"+e))},""!=n?navtab(n):jQuery(".cmp-coming-soon-maintenance .table-wrapper-css").css("display","none"),window.onhashchange=function(){n=document.location.hash.substring(1),navtab(n)},jQuery(".cmp-coming-soon-maintenance .nav-tab:not(.theme-preview):not(.advanced)").click(function(e){e.preventDefault(),n=jQuery(this).data("tab"),document.location.hash=n}),p(".cmp-coming-soon-maintenance .blur-range","span","html"),p(".cmp-coming-soon-maintenance .background-overlay-opacity","span","html"),p("#logo_size_slider","#niteoCS_logo_size","val"),p("#niteoCS_logo_size","#logo_size_slider","val"),l("logo",!1,"image","img"),l("favicon",!1,"image","img"),l("seo_img",!1,"image","img"),l("images",!0,"image","img"),l("mobile-images",!0,"image","img"),l("pattern",!1,"image","background"),l("video-thumb",!1,"image","img"),l("video-local",!1,"video","video"),l("subs-img",!1,"image","img"),l("subs-img-popup",!1,"image","img"),l("avatar",!1,"image","img"),l("gallery",!0,"image","img"),u("analytics"),u("contact-form"),u("subscribe"),u("background-effect"),u("special-effect"),u("cmp-logo"),u("background-type"),u("counter"),u("progress-bar"),u("overlay-text"),u("cmp-logo-size"),u("recaptcha-toggle"),u("login-icon"),u("custom-mobile-imgs"),u("lang-switcher"),u("subscribe-popup"),u("inpage-subscribe"),m("counter-action"),m("subscribe-method"),m("background-overlay"),m("banner-video-source"),m("progress-bar-type"),jQuery(".cmp-coming-soon-maintenance select:not(.headings-google-font):not(.content-google-font )").select2({width:"100%",minimumResultsForSearch:-1,placeholder:"Click to select.."}),jQuery(".cmp-coming-soon-maintenance #cmp-status").click(function(){jQuery(".cmp-coming-soon-maintenance .cmp-status input[type=radio]").prop("disabled",function(e,n){return!n}),jQuery("#cmp-toggle-adminbar").toggleClass("status-1"),jQuery(".cmp-status-pages").fadeToggle()}),jQuery(".cmp-status-pages input[type=radio]").change(function(){jQuery(".cmp-status-pages input[type=radio]").parent().removeClass("active"),jQuery(this).parent().addClass("active")}),jQuery(".cmp-coming-soon-maintenance .cmp-status.switch:not(.disabled)").click(function(){if(0!=jQuery(".cmp-coming-soon-maintenance #cmp-status").prop("checked")){var e=jQuery(this).children("input");e.prop("checked",!0),jQuery(".cmp-coming-soon-maintenance .cmp-status.switch").removeClass("active"),jQuery(this).addClass("active"),e.trigger("change"),"3"==e.val()?jQuery(".cmp-coming-soon-maintenance .redirect-inputs").fadeIn("fast"):jQuery(".cmp-coming-soon-maintenance .redirect-inputs").fadeOut("fast")}}),jQuery(".cmp-coming-soon-maintenance .table-wrapper h3").click(function(){jQuery(this).parent().toggleClass("closed")}),jQuery(".cmp-coming-soon-maintenance #test-unsplash").click(function(e){e.preventDefault();var n=jQuery(".cmp-coming-soon-maintenance #unsplash-media"),a=jQuery('.cmp-coming-soon-maintenance .unsplash_banner select[name^="unsplash_feed"] option:selected').val(),t="",i=jQuery(this).data("security");if(0==a){switch(a){case"0":t=jQuery(".cmp-coming-soon-maintenance #niteoCS-unsplash-0").val()}if(3==a||""!=t){var o={feed:a,url:t,feat:"",custom_str:""};jQuery(this).prop("disabled",!0),jQuery(this).html('<i class="fas fa-cog fa-spin fa-1x fa-fw"></i><span> loading..</span>');var r={action:"niteo_unsplash",security:i,params:o};jQuery.post(ajaxurl,r,function(e){var a=JSON.parse(e);jQuery("#unsplash_img").remove();var t=setTimeout(function(){jQuery("#test-unsplash").prop("disabled",!1),jQuery("#test-unsplash").text("Display Unsplash Photo"),jQuery("#unsplash-media").html('<p>It seems <a href="https://status.unsplash.com/" target="_blank">Unsplash API</a> is not responding. Please try again later.</p>')},5e3);if("200"==a.response){if((a=jQuery.parseJSON(a.body))[0])var i=a[0].urls.raw+"?ixlib=rb-0.3.5&q=80&fm=jpg&crop=entropy&cs=tinysrgb&fit=max&w=900",o=a[0].user.name,r=a[0].user.links.html,s=a[0].links.html,c=a[0].id;else i=a.urls.raw+"?ixlib=rb-0.3.5&q=80&fm=jpg&crop=entropy&cs=tinysrgb&fit=max&w=900",o=a.user.name,r=a.user.links.html,s=a.links.html,c=a.id;jQuery("<img />",{src:i,id:"unsplash_img"}).one("load",function(){jQuery(this).appendTo(n),jQuery(this).fadeIn(),jQuery("#test-unsplash").prop("disabled",!1),jQuery("#test-unsplash").text("Display Unsplash Photo"),jQuery(".unsplash-id").html('<a href="'+s+'" target="_blank">Photo</a> (ID: '+c+') by <a href="'+r+'" target="_blank">'+o+'</a> / <a href="https://unsplash.com/" target="_blank">Unsplash</a>'),jQuery(".blur-range").trigger("input"),clearTimeout(t)})}else jQuery(".cmp-coming-soon-maintenance #test-unsplash").prop("disabled",!1),jQuery(".cmp-coming-soon-maintenance #test-unsplash").text("Display Unsplash Photo"),jQuery(".cmp-coming-soon-maintenance #unsplash-media").html("<p>Error "+a.response+': <span style="text-transform:lowercase;">'+JSON.parse(a.body).errors+"</span></p>"),clearTimeout(t)})}else jQuery(".cmp-coming-soon-maintenance #unsplash_img").remove()}}),videoPreview=function(){if("5"==jQuery(".cmp-coming-soon-maintenance .background-type:checked").val()){var e=jQuery(".cmp-coming-soon-maintenance .banner-video-source").val();if("youtube"==e){var n=jQuery(".cmp-coming-soon-maintenance #niteoCS-youtube-url").val();if(""!=n){var a=n.match(/^.*((youtu.be\/)|(v\/)|(\/u\/\w\/)|(embed\/)|(watch\?))\??v?=?([^#\&\?]*).*/);if(a&&11==a[7].length){jQuery(".cmp-coming-soon-maintenance .video-yt-wrapper .video-yt-thumb-wrapper").html("");var t="https://img.youtube.com/vi/"+a[7]+"/maxresdefault.jpg";jQuery(".cmp-coming-soon-maintenance .video-yt-wrapper .video-yt-thumb-wrapper").append('<img src="'+t+'" alt=""/>'),jQuery(".cmp-coming-soon-maintenance .blur-range").trigger("input")}else jQuery(".cmp-coming-soon-maintenance .video-yt-wrapper .video-yt-thumb-wrapper").html("")}}if("local"==e){var i=jQuery("#niteoCS-video-local-id").data("url");""!=i&&jQuery(".cmp-coming-soon-maintenance .video-local-wrapper").html('<video width="600" height="400" controls><source src="'+i+'" type="video/mp4">Your browser does not support the video tag.</video>')}}},videoPreview(),jQuery(".cmp-coming-soon-maintenance .background-type").on("change",function(){videoPreview()}),jQuery(".cmp-coming-soon-maintenance #niteoCS-youtube-url").on("keyup",function(){videoPreview()}),jQuery(".cmp-coming-soon-maintenance .banner-video-source").on("change",function(){videoPreview()});var i=jQuery('.unsplash_banner select[name^="unsplash_feed"] option:selected').val();function o(e){switch(e){case"solid-color":jQuery(".thumbnail-overlay").css("background",jQuery("#niteoCS_overlay_color").val());break;case"gradient":jQuery(".cmp-coming-soon-maintenance select.overlay-gradient").trigger("change");break;case"disabled":jQuery(".cmp-coming-soon-maintenance .thumbnail-overlay").css("background","none")}}jQuery(".unsplash-feed-"+i).css("display","block"),jQuery('.unsplash_banner select[name^="unsplash_feed"]').on("change",function(){i=jQuery('.unsplash_banner select[name^="unsplash_feed"] option:selected').val(),jQuery(".unsplash-feed").css("display","none"),jQuery(".unsplash-feed-"+i).css("display","block"),jQuery("#test-unsplash").trigger("click")}),1==jQuery("#csoptions .niteoCS_banner:checked").val()&&jQuery("#test-unsplash").trigger("click"),jQuery(".cmp-coming-soon-maintenance select.background-gradient").on("change",function(){var e=jQuery(".cmp-coming-soon-maintenance select.background-gradient option:selected").val();"custom"==e?(jQuery(".cmp-coming-soon-maintenance .custom-gradient").css("display","block"),jQuery(".cmp-coming-soon-maintenance .gradient-preview").css({background:"-moz-linear-gradient(-45deg, "+jQuery("#niteoCS_gradient_one").val()+" 0%, "+jQuery("#niteoCS_gradient_two").val()+" 100%)",background:"-webkit-linear-gradient(-45deg, "+jQuery("#niteoCS_gradient_one").val()+" 0%, "+jQuery("#niteoCS_gradient_two").val()+" 100%)",background:"linear-gradient(135deg, "+jQuery("#niteoCS_gradient_one").val()+" 0%, "+jQuery("#niteoCS_gradient_two").val()+" 100%)"})):(colors=e.split(":"),jQuery(".cmp-coming-soon-maintenance .custom-gradient").css("display","none"),jQuery(".cmp-coming-soon-maintenance .gradient-preview").css({background:"-moz-linear-gradient(-45deg, "+colors[0]+" 0%, "+colors[1]+" 100%)",background:"-webkit-linear-gradient(-45deg, "+colors[0]+" 0%, "+colors[1]+" 100%)",background:"linear-gradient(135deg, "+colors[0]+" 0%, "+colors[1]+" 100%)"}))}).trigger("change"),jQuery(".cmp-coming-soon-maintenance #niteoCS_banner_color").wpColorPicker({change:function(e,n){jQuery(".color-preview").css("background-color",n.color.toString())}}),jQuery(".cmp-coming-soon-maintenance #niteoCS_gradient_one").wpColorPicker({change:function(e,n){jQuery(".gradient-preview").css({background:"-moz-linear-gradient(-45deg, "+n.color.toString()+" 0%, "+jQuery("#niteoCS_gradient_two").val()+" 100%)",background:"-webkit-linear-gradient(-45deg, "+n.color.toString()+" 0%, "+jQuery("#niteoCS_gradient_two").val()+" 100%)",background:"linear-gradient(135deg, "+n.color.toString()+" 0%, "+jQuery("#niteoCS_gradient_two").val()+" 100%)"})}}),jQuery(".cmp-coming-soon-maintenance #niteoCS_gradient_two").wpColorPicker({change:function(e,n){jQuery(".gradient-preview").css({background:"-moz-linear-gradient(-45deg, "+jQuery("#niteoCS_gradient_one").val()+" 0%, "+n.color.toString()+" 100%)",background:"-webkit-linear-gradient(-45deg, "+jQuery("#niteoCS_gradient_one").val()+" 0%, "+n.color.toString()+" 100%)",background:"linear-gradient(135deg, "+jQuery("#niteoCS_gradient_one").val()+" 0%, "+n.color.toString()+" 100%)"})}}),jQuery(".cmp-coming-soon-maintenance #niteoCS_overlay_color").wpColorPicker({change:function(e,n){jQuery(".thumbnail-overlay").css("background",n.color.toString())}}),jQuery(".cmp-coming-soon-maintenance .thumbnail-overlay").css("background",jQuery("#niteoCS_overlay_color").val()),jQuery(".cmp-coming-soon-maintenance select.overlay-gradient").on("change",function(){var e=jQuery("select.overlay-gradient option:selected").val();if("custom"==e){jQuery(".cmp-coming-soon-maintenance .custom-overlay-gradient").css("display","block");var n=jQuery("#niteoCS_overlay_gradient_one").val(),a=jQuery("#niteoCS_overlay_gradient_two").val();jQuery(".cmp-coming-soon-maintenance .thumbnail-overlay").css({background:"-moz-linear-gradient(-45deg, "+n+" 0%, "+a+" 100%)",background:"-webkit-linear-gradient(-45deg, "+n+" 0%, "+a+" 100%)",background:"linear-gradient(135deg, "+n+" 0%, "+a+" 100%)"})}else colors=e.split(":"),jQuery(".cmp-coming-soon-maintenance .custom-overlay-gradient").css("display","none"),jQuery(".cmp-coming-soon-maintenance .thumbnail-overlay").css({background:"-moz-linear-gradient(-45deg, "+colors[0]+" 0%, "+colors[1]+" 100%)",background:"-webkit-linear-gradient(-45deg, "+colors[0]+" 0%, "+colors[1]+" 100%)",background:"linear-gradient(135deg, "+colors[0]+" 0%, "+colors[1]+" 100%)"})}),jQuery("#niteoCS_overlay_gradient_one").wpColorPicker({change:function(e,n){jQuery(".thumbnail-overlay").css({background:"-moz-linear-gradient(-45deg, "+n.color.toString()+" 0%, "+jQuery("#niteoCS_overlay_gradient_two").val()+" 100%)",background:"-webkit-linear-gradient(-45deg, "+n.color.toString()+" 0%, "+jQuery("#niteoCS_overlay_gradient_two").val()+" 100%)",background:"linear-gradient(135deg, "+n.color.toString()+" 0%, "+jQuery("#niteoCS_overlay_gradient_two").val()+" 100%)"})}}),jQuery("#niteoCS_overlay_gradient_two").wpColorPicker({change:function(e,n){jQuery(".thumbnail-overlay").css({background:"-moz-linear-gradient(-45deg, "+jQuery("#niteoCS_overlay_gradient_one").val()+" 0%, "+n.color.toString()+" 100%)",background:"-webkit-linear-gradient(-45deg, "+jQuery("#niteoCS_overlay_gradient_one").val()+" 0%, "+n.color.toString()+" 100%)",background:"linear-gradient(135deg, "+jQuery("#niteoCS_overlay_gradient_one").val()+" 0%, "+n.color.toString()+" 100%)"})}}),jQuery(".background-overlay-opacity").on("input",function(){var e=jQuery(this).val();jQuery(".thumbnail-overlay").css("opacity",e)}).trigger("input"),o(jQuery(".cmp-coming-soon-maintenance .background-overlay").val()),jQuery(".cmp-coming-soon-maintenance .background-overlay").on("change",function(){o(jQuery(this).val())}),jQuery(".cmp-coming-soon-maintenance .blur-range").on("input",function(){var e=jQuery(this).val();jQuery(".cmp-coming-soon-maintenance .background-thumb-wrapper img:not(.no-blur)").css("filter","blur("+e+"px)")}).trigger("input"),jQuery('.cmp-coming-soon-maintenance select[name^="niteoCS_banner_pattern"]').on("change",function(){var e=jQuery('.cmp-coming-soon-maintenance select[name^="niteoCS_banner_pattern"] option:selected').val();if("custom"!=e){var n=jQuery(this).data("url");jQuery(".cmp-coming-soon-maintenance #add-pattern").css("display","none"),jQuery(".cmp-coming-soon-maintenance .pattern-wrapper").css("background-image","url('"+n+e+".png')")}else{n=jQuery(".cmp-coming-soon-maintenance #niteoCS_banner_pattern_custom").val();jQuery(".cmp-coming-soon-maintenance #add-pattern").css("display","block"),jQuery(".cmp-coming-soon-maintenance .pattern-wrapper").css("background-image","url('"+n+"')")}}),jQuery(".cmp-coming-soon-maintenance .heading-animation").on("change",function(){heading_anim=jQuery(".cmp-coming-soon-maintenance .heading-animation option:selected").val(),jQuery(".cmp-coming-soon-maintenance #heading-example").removeClass().addClass("animated "+heading_anim)}),jQuery(".cmp-coming-soon-maintenance .content-animation").on("change",function(){heading_anim=jQuery(".cmp-coming-soon-maintenance .content-animation option:selected").val(),jQuery(".cmp-coming-soon-maintenance #content-example").removeClass().addClass("animated "+heading_anim)});var r=function(e,n,a){var t=jQuery(".cmp-coming-soon-maintenance #niteoCS_socialmedia").attr("value");t=jQuery.parseJSON(t),jQuery.each(t,function(t,i){i.name==e&&(i[n]=a)}),jQuery(".cmp-coming-soon-maintenance #niteoCS_socialmedia").attr("value",JSON.stringify(t))};if(!/Mobi/.test(navigator.userAgent)){var s=jQuery(".cmp-coming-soon-maintenance .social-inputs"),c=function(e,n){var a=s.find('input[type="text"]');n.item.index();a.each(function(e,n){var a=jQuery(n).data("name");r(a,"order",e)})};s.sortable({stop:c}),s.on("sortchange",c)}function l(e,n,a,t){var i,o=jQuery("."+e+"-wrapper"),r=jQuery("#add-"+e),s=jQuery("#delete-"+e),c="",l=e.replace("-"," ");l=l[0].toUpperCase()+l.slice(1),""!=jQuery("#niteoCS-"+e+"-id").val()&&s.css("display","block"),r.click(function(r){if(r.preventDefault(),u)u.open();else var u=wp.media({title:"Select "+l,button:{text:"Insert "+l},multiple:n,library:{type:[a]}}).on("select",function(){var n=u.state().get("selection").toJSON();n.length>0&&(o.find("img").remove(),o.attr("class",e+"-wrapper custom-gallery"),o.addClass("gallery-"+n.length),jQuery(n).each(function(a){switch(i=n[a].sizes&&n[a].sizes.large?n[a].sizes.large.url:n[a].url,c+=(0===a?"":",")+n[a].id,t){case"video":o.append('<video width="600" height="400" controls><source src="'+i+'" type="video/mp4">Your browser does not support the video tag.</video>');break;case"background":o.css("background-image","url('"+i+"')");break;case"img":default:n.length>1&&0==a&&jQuery("."+e+"-wrapper .big-thumb").length?jQuery("."+e+"-wrapper .big-thumb").append('<img src="'+i+'" alt=""/>'):n.length>1&&0!==a?o.append('<img src="'+i+'" alt="" class="no-blur"/>'):o.find(".big-thumb").length?jQuery("."+e+"-wrapper .big-thumb").append('<img src="'+i+'" alt=""/>'):o.append('<img src="'+i+'" alt=""/>'),jQuery(".blur-range").trigger("input")}}),s.css("display","block")),jQuery("#niteoCS-"+e+"-id").val(c).trigger("change")}).open()}),s.click(function(n){jQuery(this).css("display","none"),o.find("img").remove(),jQuery("#niteoCS-"+e+"-id").val(""),jQuery("#niteoCS-"+e+"-id").trigger("change")})}function u(e){jQuery(".cmp-coming-soon-maintenance ."+e).change(function(){var n=jQuery(".cmp-coming-soon-maintenance ."+e+":checked").val();n=void 0===(n=jQuery.isNumeric(n)?"x"+n:n)?"off":n,jQuery(".cmp-coming-soon-maintenance ."+e+"-switch."+n).css("display","block"),jQuery(".cmp-coming-soon-maintenance ."+e+"-switch:not(."+n+")").css("display","none")}),jQuery(".cmp-coming-soon-maintenance ."+e).first().trigger("change")}function m(e){jQuery(".cmp-coming-soon-maintenance ."+e).change(function(){var n=jQuery("."+e).val();n=jQuery.isNumeric(n)?"x"+n:n,jQuery(".cmp-coming-soon-maintenance ."+e+"."+n).css("display","block"),jQuery(".cmp-coming-soon-maintenance ."+e+":not(."+n+")").css("display","none")}),jQuery("."+e).first().trigger("change")}function p(e,n,a){jQuery(e).on("input",function(){var e=jQuery(this).val();"html"===a&&jQuery(this).parent().find(n).html(e),"val"===a&&jQuery(this).parent().find(n).val(e)})}jQuery,jQuery.fn.toggleDisabled=function(){return this.each(function(){var e,n=jQuery(this),a=n.data("name");n.attr("disabled")?(n.prop("disabled",!1),e="1"):(n.prop("disabled",!0),e="0"),r(a,"active",e)})},jQuery('.cmp-coming-soon-maintenance .social-inputs input[type="text"]').focusout(function(){var e=jQuery(this).data("name"),n=jQuery(this).val();r(e,"url",n)}),jQuery('.cmp-coming-soon-maintenance .social-inputs input[type="checkbox"]').click(function(e){jQuery(this).siblings('input[type="text"]').toggleDisabled()}),jQuery(".cmp-coming-soon-maintenance .social-media i").click(function(){var e=jQuery(this).data("name");jQuery(this).toggleClass("active"),jQuery(".cmp-coming-soon-maintenance .social-inputs li."+e).toggleClass("active"),jQuery(".cmp-coming-soon-maintenance .social-inputs li."+e+" input").trigger("change"),jQuery(this).hasClass("active")?r(e,"hidden","0"):r(e,"hidden","1"),jQuery(".cmp-coming-soon-maintenance .social-media i.active").length?jQuery(".social-inputs .label").css("display","block"):jQuery(".cmp-coming-soon-maintenance .social-inputs .label").css("display","none")}),jQuery(".cmp-coming-soon-maintenance .social-media i.active").length&&jQuery(".cmp-coming-soon-maintenance .social-inputs .label").css("display","block"),jQuery(".cmp.update-theme").click(function(e){e.preventDefault();var n=jQuery(this),a=n.parents(".notice"),t=n.data("security"),i=n.data("slug"),o=n.data("name"),r={action:"cmp_theme_update_install",security:t,file:{name:i,tmp_name:"",url:jQuery(this).data("remote_url")+"?action=download&slug="+i}};a.find(".message").html('<i class="fas fa-cog fa-spin fa-1x fa-fw"></i><span class="sr-only">Updating heme...</span><span> working hard on updating Theme...</span>'),jQuery.post(ajaxurl,r,function(e){if("success"==(e=e.trim()))setTimeout(function(){a.removeClass("notice-warning").addClass("notice-success"),a.find(".message").html("<span> "+o+' CMP theme was updated sucessfully! You can enjoy latest features now :) </span><i class="far fa-smile" aria-hidden="true"></i>')},1500);else{e=e.slice(0,-1);var n=jQuery("p",jQuery(e)).text();a.removeClass("notice-warning").addClass("notice-error"),a.find(".message").html('<i class="far fa-frown" aria-hidden="true"></i><span> '+n+"</span>")}})}),jQuery(".cmp-coming-soon-maintenance .theme-update.button").one("click",function(e){e.preventDefault();var n=jQuery(this),a=n.closest(".theme-wrapper"),t=a.data("security"),i=a.data("slug"),o={action:"cmp_theme_update_install",security:t,file:{name:i,tmp_name:"",url:a.data("remote_url")+"?action=download&slug="+i}};n.html('<i class="fas fa-cog fa-spin fa-1x fa-fw"></i><span>Updating..</span>'),jQuery.post(ajaxurl,o,function(e){"success"==e?setTimeout(function(){n.html('<i class="far fa-smile" aria-hidden="true"></i><span>Updated!</span>'),setTimeout(function(){n.fadeOut()},1500)},1500):(e=e.slice(0,-1),n.html('<i class="far fa-frown" aria-hidden="true"></i><span>Update Failed!</span>'))})}),jQuery(".cmp-coming-soon-maintenance .theme-details").click(function(e){e.preventDefault();var n=jQuery(this).closest(".theme-wrapper"),a=n.data("slug"),t=n.data("version"),i=n.data("type"),o=n.data("purchased"),r=0,s={action:"niteo_themeinfo",security:jQuery(".theme-wrapper").data("security"),theme_slug:jQuery(this).parents(".theme-wrapper").data("slug")};jQuery.post(ajaxurl,s,function(e){var s="",c="";if("true"==(e=jQuery.parseJSON(e)).result){if(jQuery("body").addClass("modal-open"),"1"==o&&(c='<span class="theme-version">Installed version: '+t+"</span>"),"1"!=o&&"premium"==i)s='<button type="button" class="theme-purchase button hide"><a href="'+n.find(".cmp-purchase-theme").attr("href")+'" target="_blank"><i class="fas fa-cart-arrow-down" aria-hidden="true"></i>Get Theme</a></button>';var l=e.screenshots,u="";Object.keys(l).length>1&&(u='<div class="screenshots-nav"><div class="left"><i class="fas fa-chevron-left" aria-hidden="true"></i></div><div class="right"><i class="fas fa-chevron-right" aria-hidden="true"></i></div></div>');var m=jQuery(['<div class="theme-backdrop">','\t<div class="theme-wrap">','\t\t<div class="theme-header">','\t\t\t<button class="close dashicons dashicons-no"><span class="screen-reader-text">Close details dialog</span></button>',"\t\t</div>",'\t\t<div class="theme-about">','\t\t\t<div class="theme-screenshots">','\t\t\t\t<div class="screenshot" style="background-image:url(\''+l[0]+"')\">"+u+"</div>","\t\t\t</div>",'\t\t\t<div class="theme-info">','\t\t\t\t<h2 class="theme-name">'+e.name+c+"</h2>",'\t\t\t\t<p class="theme-author">By <a href="'+e.author_homepage+'" target="_blank">'+e.author+"</a></p>","",s,'\t\t\t\t<div class="theme-description">'+e.description+"</div>","\t\t\t</div>","\t\t</div>",'\t\t<div class="theme-actions">','\t\t\t<a href="https://niteothemes.com/cmp-coming-soon-maintenance/?theme='+a+"&utm_source=cmp&utm_medium=referral&utm_campaign="+a+'" class="button cmp-preview" target="_blank" aria-label="Preview '+e.name+'">Live Preview</a>',"\t\t</div>","\t</div>","</div>"].join("\n"));jQuery(".theme-overlay.cmp").append(m),jQuery(".theme-overlay.cmp .close").click(function(e){e.preventDefault(),jQuery("body").removeClass("modal-open"),jQuery(".theme-overlay.cmp .theme-backdrop").fadeOut("fast")}),jQuery(".screenshots-nav .right").click(function(){++r==Object.keys(l).length&&(r=0),r in l&&jQuery(".screenshot").css("background-image","url('"+l[r]+"')")}),jQuery(".screenshots-nav .left").click(function(){--r<0&&(r=Object.keys(l).length-1),r in l&&jQuery(".screenshot").css("background-image","url('"+l[r]+"')")})}})}),jQuery(".cmp-coming-soon-maintenance #connect-mailchimp").click(function(e){e.preventDefault();var n=jQuery('.cmp-coming-soon-maintenance input[name="niteoCS_mailchimp_apikey"]').val(),a=jQuery(this).data("security"),t=jQuery(this);if(""!=n){var i={apikey:n,security:a};jQuery(this).prop("disabled",!0),jQuery(this).html('<i class="fas fa-cog fa-spin fa-1x fa-fw"></i><span> retrieving lists..</span>');var o={action:"cmp_mailchimp_list_ajax",security:a,params:i};jQuery.post(ajaxurl,o,function(e){var n=JSON.parse(e);200==n.response?(jQuery("#niteoCS_mailchimp_list").empty().prop("disabled",!1),jQuery.each(n.lists,function(e,n){jQuery("#niteoCS_mailchimp_list").append('<option value="'+n.id+'">'+n.name+"</option>")})):jQuery("#niteoCS_mailchimp_list").empty().prop("disabled",!0).html('<option value="error">'+n.message+"</option>").trigger("change"),t.html("Retrieve Lists"),t.prop("disabled",!1)}).fail(function(){t.html("Retrieve Lists"),t.prop("disabled",!1)})}}),jQuery(".cmp-coming-soon-maintenance .table-wrapper.theme-setup h4").each(function(){if("Overlay Color"==jQuery(this).html())return jQuery(this).parents("tr").remove(),!1}),jQuery(".nav-tab-wrapper").on("click",".theme-preview",function(e){return!(jQuery("#csoptions fieldset:not(.skip-preview-validation *)").serialize()!=t&&!confirm("You have made changes that will not be visible in the preview until you save them. Please save changes first.\nContinue anyway?"))||(e.preventDefault(),!1)})});
1
+ jQuery(document).ready(function(e){var n=document.location.hash.substring(1),a=jQuery("#csoptions").attr("action"),t=jQuery("#csoptions fieldset:not(.skip-preview-validation *)").serialize();wp.codeEditor&&jQuery("#niteoCS_custom_css").length&&wp.codeEditor.initialize("niteoCS_custom_css"),navtab=function(e){jQuery(".cmp-coming-soon-maintenance .nav-tab-wrapper .nav-tab").removeClass("nav-tab-active"),jQuery(".nav-tab-wrapper ."+e).addClass("nav-tab-active"),jQuery(".cmp-coming-soon-maintenance .table-wrapper."+e).css("display","block"),jQuery(".cmp-coming-soon-maintenance .table-wrapper-css."+e).css("display","block"),jQuery(".cmp-coming-soon-maintenance .comingsoon."+e).css("display","block"),jQuery(".cmp-coming-soon-maintenance .table-wrapper:not(."+e+")").css("display","none"),jQuery(".cmp-coming-soon-maintenance .table-wrapper-css:not(."+e).css("display","none"),jQuery(".cmp-coming-soon-maintenance .comingsoon:not(."+e+")").css("display","none"),"install"==e?(jQuery(".cmp-coming-soon-maintenance .submit").css("display","none"),jQuery(".cmp-coming-soon-maintenance #csoptions").attr("action",a)):(jQuery(".cmp-coming-soon-maintenance .submit").css("display","block"),jQuery(".cmp-coming-soon-maintenance #csoptions").attr("action",a+"#"+e))},""!=n?navtab(n):jQuery(".cmp-coming-soon-maintenance .table-wrapper-css").css("display","none"),window.onhashchange=function(){n=document.location.hash.substring(1),navtab(n)},jQuery(".cmp-coming-soon-maintenance .nav-tab:not(.theme-preview):not(.advanced)").click(function(e){e.preventDefault(),n=jQuery(this).data("tab"),document.location.hash=n}),p(".cmp-coming-soon-maintenance .blur-range","span","html"),p(".cmp-coming-soon-maintenance .background-overlay-opacity","span","html"),p("#logo_size_slider","#niteoCS_logo_size","val"),p("#niteoCS_logo_size","#logo_size_slider","val"),l("logo",!1,"image","img"),l("favicon",!1,"image","img"),l("seo_img",!1,"image","img"),l("images",!0,"image","img"),l("mobile-images",!0,"image","img"),l("pattern",!1,"image","background"),l("video-thumb",!1,"image","img"),l("video-local",!1,"video","video"),l("subs-img",!1,"image","img"),l("subs-img-popup",!1,"image","img"),l("avatar",!1,"image","img"),l("gallery",!0,"image","img"),u("analytics"),u("contact-form"),u("subscribe"),u("background-effect"),u("special-effect"),u("cmp-logo"),u("background-type"),u("counter"),u("progress-bar"),u("overlay-text"),u("cmp-logo-size"),u("recaptcha-toggle"),u("login-icon"),u("custom-mobile-imgs"),u("lang-switcher"),u("subscribe-popup"),u("inpage-subscribe"),u("tags"),m("counter-action"),m("subscribe-method"),m("background-overlay"),m("banner-video-source"),m("progress-bar-type"),function(n){if(!jQuery("#wrapper-"+n).length)return;jQuery("#add-"+n).click(function(a){a.preventDefault();var t=jQuery("#wrapper-"+n),i=jQuery("#wrapper-"+n+" .target-repeater-fields"),o=t.find(".source-repeater-fields").children().clone();e(o[0]).val(""),e(i).append(o)}),function(n){jQuery("#wrapper-"+n+" .target-repeater-fields").on("click",".delete-"+n,function(n){n.preventDefault(),e(this).prev().remove(),e(this).remove()}),jQuery("#wrapper-"+n+" .source-repeater-fields").on("click",".delete-"+n,function(n){n.preventDefault(),e(this).prev().val("")})}(n)}("tags"),jQuery(".cmp-coming-soon-maintenance select:not(.headings-google-font):not(.content-google-font )").select2({width:"100%",minimumResultsForSearch:-1,placeholder:"Click to select.."}),jQuery(".cmp-coming-soon-maintenance #cmp-status").click(function(){jQuery(".cmp-coming-soon-maintenance .cmp-status input[type=radio]").prop("disabled",function(e,n){return!n}),jQuery("#cmp-toggle-adminbar").toggleClass("status-1"),jQuery(".cmp-status-pages").fadeToggle()}),jQuery(".cmp-status-pages input[type=radio]").change(function(){jQuery(".cmp-status-pages input[type=radio]").parent().removeClass("active"),jQuery(this).parent().addClass("active")}),jQuery(".cmp-coming-soon-maintenance .cmp-status.switch:not(.disabled)").click(function(){if(0!=jQuery(".cmp-coming-soon-maintenance #cmp-status").prop("checked")){var e=jQuery(this).children("input");e.prop("checked",!0),jQuery(".cmp-coming-soon-maintenance .cmp-status.switch").removeClass("active"),jQuery(this).addClass("active"),e.trigger("change"),"3"==e.val()?jQuery(".cmp-coming-soon-maintenance .redirect-inputs").fadeIn("fast"):jQuery(".cmp-coming-soon-maintenance .redirect-inputs").fadeOut("fast")}}),jQuery(".cmp-coming-soon-maintenance .table-wrapper h3").click(function(){jQuery(this).parent().toggleClass("closed")}),jQuery(".cmp-coming-soon-maintenance #test-unsplash").click(function(e){e.preventDefault();var n=jQuery(".cmp-coming-soon-maintenance #unsplash-media"),a=jQuery('.cmp-coming-soon-maintenance .unsplash_banner select[name^="unsplash_feed"] option:selected').val(),t="",i=jQuery(this).data("security");if(0==a){switch(a){case"0":t=jQuery(".cmp-coming-soon-maintenance #niteoCS-unsplash-0").val()}if(3==a||""!=t){var o={feed:a,url:t,feat:"",custom_str:""};jQuery(this).prop("disabled",!0),jQuery(this).html('<i class="fas fa-cog fa-spin fa-1x fa-fw"></i><span> loading..</span>');var r={action:"niteo_unsplash",security:i,params:o};jQuery.post(ajaxurl,r,function(e){var a=JSON.parse(e);jQuery("#unsplash_img").remove();var t=setTimeout(function(){jQuery("#test-unsplash").prop("disabled",!1),jQuery("#test-unsplash").text("Display Unsplash Photo"),jQuery("#unsplash-media").html('<p>It seems <a href="https://status.unsplash.com/" target="_blank">Unsplash API</a> is not responding. Please try again later.</p>')},5e3);if("200"==a.response){if((a=jQuery.parseJSON(a.body))[0])var i=a[0].urls.raw+"?ixlib=rb-0.3.5&q=80&fm=jpg&crop=entropy&cs=tinysrgb&fit=max&w=900",o=a[0].user.name,r=a[0].user.links.html,s=a[0].links.html,c=a[0].id;else i=a.urls.raw+"?ixlib=rb-0.3.5&q=80&fm=jpg&crop=entropy&cs=tinysrgb&fit=max&w=900",o=a.user.name,r=a.user.links.html,s=a.links.html,c=a.id;jQuery("<img />",{src:i,id:"unsplash_img"}).one("load",function(){jQuery(this).appendTo(n),jQuery(this).fadeIn(),jQuery("#test-unsplash").prop("disabled",!1),jQuery("#test-unsplash").text("Display Unsplash Photo"),jQuery(".unsplash-id").html('<a href="'+s+'" target="_blank">Photo</a> (ID: '+c+') by <a href="'+r+'" target="_blank">'+o+'</a> / <a href="https://unsplash.com/" target="_blank">Unsplash</a>'),jQuery(".blur-range").trigger("input"),clearTimeout(t)})}else jQuery(".cmp-coming-soon-maintenance #test-unsplash").prop("disabled",!1),jQuery(".cmp-coming-soon-maintenance #test-unsplash").text("Display Unsplash Photo"),jQuery(".cmp-coming-soon-maintenance #unsplash-media").html("<p>Error "+a.response+': <span style="text-transform:lowercase;">'+JSON.parse(a.body).errors+"</span></p>"),clearTimeout(t)})}else jQuery(".cmp-coming-soon-maintenance #unsplash_img").remove()}}),videoPreview=function(){if("5"==jQuery(".cmp-coming-soon-maintenance .background-type:checked").val()){var e=jQuery(".cmp-coming-soon-maintenance .banner-video-source").val();if("youtube"==e){var n=jQuery(".cmp-coming-soon-maintenance #niteoCS-youtube-url").val();if(""!=n){var a=n.match(/^.*((youtu.be\/)|(v\/)|(\/u\/\w\/)|(embed\/)|(watch\?))\??v?=?([^#\&\?]*).*/);if(a&&11==a[7].length){jQuery(".cmp-coming-soon-maintenance .video-yt-wrapper .video-yt-thumb-wrapper").html("");var t="https://img.youtube.com/vi/"+a[7]+"/maxresdefault.jpg";jQuery(".cmp-coming-soon-maintenance .video-yt-wrapper .video-yt-thumb-wrapper").append('<img src="'+t+'" alt=""/>'),jQuery(".cmp-coming-soon-maintenance .blur-range").trigger("input")}else jQuery(".cmp-coming-soon-maintenance .video-yt-wrapper .video-yt-thumb-wrapper").html("")}}if("local"==e){var i=jQuery("#niteoCS-video-local-id").data("url");""!=i&&jQuery(".cmp-coming-soon-maintenance .video-local-wrapper").html('<video width="600" height="400" controls><source src="'+i+'" type="video/mp4">Your browser does not support the video tag.</video>')}}},videoPreview(),jQuery(".cmp-coming-soon-maintenance .background-type").on("change",function(){videoPreview()}),jQuery(".cmp-coming-soon-maintenance #niteoCS-youtube-url").on("keyup",function(){videoPreview()}),jQuery(".cmp-coming-soon-maintenance .banner-video-source").on("change",function(){videoPreview()});var i=jQuery('.unsplash_banner select[name^="unsplash_feed"] option:selected').val();function o(e){switch(e){case"solid-color":jQuery(".thumbnail-overlay").css("background",jQuery("#niteoCS_overlay_color").val());break;case"gradient":jQuery(".cmp-coming-soon-maintenance select.overlay-gradient").trigger("change");break;case"disabled":jQuery(".cmp-coming-soon-maintenance .thumbnail-overlay").css("background","none")}}jQuery(".unsplash-feed-"+i).css("display","block"),jQuery('.unsplash_banner select[name^="unsplash_feed"]').on("change",function(){i=jQuery('.unsplash_banner select[name^="unsplash_feed"] option:selected').val(),jQuery(".unsplash-feed").css("display","none"),jQuery(".unsplash-feed-"+i).css("display","block"),jQuery("#test-unsplash").trigger("click")}),1==jQuery("#csoptions .niteoCS_banner:checked").val()&&jQuery("#test-unsplash").trigger("click"),jQuery(".cmp-coming-soon-maintenance select.background-gradient").on("change",function(){var e=jQuery(".cmp-coming-soon-maintenance select.background-gradient option:selected").val();"custom"==e?(jQuery(".cmp-coming-soon-maintenance .custom-gradient").css("display","block"),jQuery(".cmp-coming-soon-maintenance .gradient-preview").css({background:"-moz-linear-gradient(-45deg, "+jQuery("#niteoCS_gradient_one").val()+" 0%, "+jQuery("#niteoCS_gradient_two").val()+" 100%)",background:"-webkit-linear-gradient(-45deg, "+jQuery("#niteoCS_gradient_one").val()+" 0%, "+jQuery("#niteoCS_gradient_two").val()+" 100%)",background:"linear-gradient(135deg, "+jQuery("#niteoCS_gradient_one").val()+" 0%, "+jQuery("#niteoCS_gradient_two").val()+" 100%)"})):(colors=e.split(":"),jQuery(".cmp-coming-soon-maintenance .custom-gradient").css("display","none"),jQuery(".cmp-coming-soon-maintenance .gradient-preview").css({background:"-moz-linear-gradient(-45deg, "+colors[0]+" 0%, "+colors[1]+" 100%)",background:"-webkit-linear-gradient(-45deg, "+colors[0]+" 0%, "+colors[1]+" 100%)",background:"linear-gradient(135deg, "+colors[0]+" 0%, "+colors[1]+" 100%)"}))}).trigger("change"),jQuery(".cmp-coming-soon-maintenance #niteoCS_banner_color").wpColorPicker({change:function(e,n){jQuery(".color-preview").css("background-color",n.color.toString())}}),jQuery(".cmp-coming-soon-maintenance #niteoCS_gradient_one").wpColorPicker({change:function(e,n){jQuery(".gradient-preview").css({background:"-moz-linear-gradient(-45deg, "+n.color.toString()+" 0%, "+jQuery("#niteoCS_gradient_two").val()+" 100%)",background:"-webkit-linear-gradient(-45deg, "+n.color.toString()+" 0%, "+jQuery("#niteoCS_gradient_two").val()+" 100%)",background:"linear-gradient(135deg, "+n.color.toString()+" 0%, "+jQuery("#niteoCS_gradient_two").val()+" 100%)"})}}),jQuery(".cmp-coming-soon-maintenance #niteoCS_gradient_two").wpColorPicker({change:function(e,n){jQuery(".gradient-preview").css({background:"-moz-linear-gradient(-45deg, "+jQuery("#niteoCS_gradient_one").val()+" 0%, "+n.color.toString()+" 100%)",background:"-webkit-linear-gradient(-45deg, "+jQuery("#niteoCS_gradient_one").val()+" 0%, "+n.color.toString()+" 100%)",background:"linear-gradient(135deg, "+jQuery("#niteoCS_gradient_one").val()+" 0%, "+n.color.toString()+" 100%)"})}}),jQuery(".cmp-coming-soon-maintenance #niteoCS_overlay_color").wpColorPicker({change:function(e,n){jQuery(".thumbnail-overlay").css("background",n.color.toString())}}),jQuery(".cmp-coming-soon-maintenance .thumbnail-overlay").css("background",jQuery("#niteoCS_overlay_color").val()),jQuery(".cmp-coming-soon-maintenance select.overlay-gradient").on("change",function(){var e=jQuery("select.overlay-gradient option:selected").val();if("custom"==e){jQuery(".cmp-coming-soon-maintenance .custom-overlay-gradient").css("display","block");var n=jQuery("#niteoCS_overlay_gradient_one").val(),a=jQuery("#niteoCS_overlay_gradient_two").val();jQuery(".cmp-coming-soon-maintenance .thumbnail-overlay").css({background:"-moz-linear-gradient(-45deg, "+n+" 0%, "+a+" 100%)",background:"-webkit-linear-gradient(-45deg, "+n+" 0%, "+a+" 100%)",background:"linear-gradient(135deg, "+n+" 0%, "+a+" 100%)"})}else colors=e.split(":"),jQuery(".cmp-coming-soon-maintenance .custom-overlay-gradient").css("display","none"),jQuery(".cmp-coming-soon-maintenance .thumbnail-overlay").css({background:"-moz-linear-gradient(-45deg, "+colors[0]+" 0%, "+colors[1]+" 100%)",background:"-webkit-linear-gradient(-45deg, "+colors[0]+" 0%, "+colors[1]+" 100%)",background:"linear-gradient(135deg, "+colors[0]+" 0%, "+colors[1]+" 100%)"})}),jQuery("#niteoCS_overlay_gradient_one").wpColorPicker({change:function(e,n){jQuery(".thumbnail-overlay").css({background:"-moz-linear-gradient(-45deg, "+n.color.toString()+" 0%, "+jQuery("#niteoCS_overlay_gradient_two").val()+" 100%)",background:"-webkit-linear-gradient(-45deg, "+n.color.toString()+" 0%, "+jQuery("#niteoCS_overlay_gradient_two").val()+" 100%)",background:"linear-gradient(135deg, "+n.color.toString()+" 0%, "+jQuery("#niteoCS_overlay_gradient_two").val()+" 100%)"})}}),jQuery("#niteoCS_overlay_gradient_two").wpColorPicker({change:function(e,n){jQuery(".thumbnail-overlay").css({background:"-moz-linear-gradient(-45deg, "+jQuery("#niteoCS_overlay_gradient_one").val()+" 0%, "+n.color.toString()+" 100%)",background:"-webkit-linear-gradient(-45deg, "+jQuery("#niteoCS_overlay_gradient_one").val()+" 0%, "+n.color.toString()+" 100%)",background:"linear-gradient(135deg, "+jQuery("#niteoCS_overlay_gradient_one").val()+" 0%, "+n.color.toString()+" 100%)"})}}),jQuery(".background-overlay-opacity").on("input",function(){var e=jQuery(this).val();jQuery(".thumbnail-overlay").css("opacity",e)}).trigger("input"),o(jQuery(".cmp-coming-soon-maintenance .background-overlay").val()),jQuery(".cmp-coming-soon-maintenance .background-overlay").on("change",function(){o(jQuery(this).val())}),jQuery(".cmp-coming-soon-maintenance .blur-range").on("input",function(){var e=jQuery(this).val();jQuery(".cmp-coming-soon-maintenance .background-thumb-wrapper img:not(.no-blur)").css("filter","blur("+e+"px)")}).trigger("input"),jQuery('.cmp-coming-soon-maintenance select[name^="niteoCS_banner_pattern"]').on("change",function(){var e=jQuery('.cmp-coming-soon-maintenance select[name^="niteoCS_banner_pattern"] option:selected').val();if("custom"!=e){var n=jQuery(this).data("url");jQuery(".cmp-coming-soon-maintenance #add-pattern").css("display","none"),jQuery(".cmp-coming-soon-maintenance .pattern-wrapper").css("background-image","url('"+n+e+".png')")}else{n=jQuery(".cmp-coming-soon-maintenance #niteoCS_banner_pattern_custom").val();jQuery(".cmp-coming-soon-maintenance #add-pattern").css("display","block"),jQuery(".cmp-coming-soon-maintenance .pattern-wrapper").css("background-image","url('"+n+"')")}}),jQuery(".cmp-coming-soon-maintenance .heading-animation").on("change",function(){heading_anim=jQuery(".cmp-coming-soon-maintenance .heading-animation option:selected").val(),jQuery(".cmp-coming-soon-maintenance #heading-example").removeClass().addClass("animated "+heading_anim)}),jQuery(".cmp-coming-soon-maintenance .content-animation").on("change",function(){heading_anim=jQuery(".cmp-coming-soon-maintenance .content-animation option:selected").val(),jQuery(".cmp-coming-soon-maintenance #content-example").removeClass().addClass("animated "+heading_anim)});var r=function(e,n,a){var t=jQuery(".cmp-coming-soon-maintenance #niteoCS_socialmedia").attr("value");t=jQuery.parseJSON(t),jQuery.each(t,function(t,i){i.name==e&&(i[n]=a)}),jQuery(".cmp-coming-soon-maintenance #niteoCS_socialmedia").attr("value",JSON.stringify(t))};if(!/Mobi/.test(navigator.userAgent)){var s=jQuery(".cmp-coming-soon-maintenance .social-inputs"),c=function(e,n){var a=s.find('input[type="text"]');n.item.index();a.each(function(e,n){var a=jQuery(n).data("name");r(a,"order",e)})};s.sortable({stop:c}),s.on("sortchange",c)}function l(e,n,a,t){var i,o=jQuery("."+e+"-wrapper"),r=jQuery("#add-"+e),s=jQuery("#delete-"+e),c="",l=e.replace("-"," ");l=l[0].toUpperCase()+l.slice(1),""!=jQuery("#niteoCS-"+e+"-id").val()&&s.css("display","block"),r.click(function(r){if(r.preventDefault(),u)u.open();else var u=wp.media({title:"Select "+l,button:{text:"Insert "+l},multiple:n,library:{type:[a]}}).on("select",function(){var n=u.state().get("selection").toJSON();n.length>0&&(o.find("img").remove(),o.attr("class",e+"-wrapper custom-gallery"),o.addClass("gallery-"+n.length),jQuery(n).each(function(a){switch(i=n[a].sizes&&n[a].sizes.large?n[a].sizes.large.url:n[a].url,c+=(0===a?"":",")+n[a].id,t){case"video":o.append('<video width="600" height="400" controls><source src="'+i+'" type="video/mp4">Your browser does not support the video tag.</video>');break;case"background":o.css("background-image","url('"+i+"')");break;case"img":default:n.length>1&&0==a&&jQuery("."+e+"-wrapper .big-thumb").length?jQuery("."+e+"-wrapper .big-thumb").append('<img src="'+i+'" alt=""/>'):n.length>1&&0!==a?o.append('<img src="'+i+'" alt="" class="no-blur"/>'):o.find(".big-thumb").length?jQuery("."+e+"-wrapper .big-thumb").append('<img src="'+i+'" alt=""/>'):o.append('<img src="'+i+'" alt=""/>'),jQuery(".blur-range").trigger("input")}}),s.css("display","block")),jQuery("#niteoCS-"+e+"-id").val(c).trigger("change")}).open()}),s.click(function(n){jQuery(this).css("display","none"),o.find("img").remove(),jQuery("#niteoCS-"+e+"-id").val(""),jQuery("#niteoCS-"+e+"-id").trigger("change")})}function u(e){jQuery(".cmp-coming-soon-maintenance ."+e).change(function(){var n=jQuery(".cmp-coming-soon-maintenance ."+e+":checked").val();n=void 0===(n=jQuery.isNumeric(n)?"x"+n:n)?"off":n,jQuery(".cmp-coming-soon-maintenance ."+e+"-switch."+n).css("display","block"),jQuery(".cmp-coming-soon-maintenance ."+e+"-switch:not(."+n+")").css("display","none")}),jQuery(".cmp-coming-soon-maintenance ."+e).first().trigger("change")}function m(e){jQuery(".cmp-coming-soon-maintenance ."+e).change(function(){var n=jQuery("."+e).val();n=jQuery.isNumeric(n)?"x"+n:n,jQuery(".cmp-coming-soon-maintenance ."+e+"."+n).css("display","block"),jQuery(".cmp-coming-soon-maintenance ."+e+":not(."+n+")").css("display","none")}),jQuery("."+e).first().trigger("change")}function p(e,n,a){jQuery(e).on("input",function(){var e=jQuery(this).val();"html"===a&&jQuery(this).parent().find(n).html(e),"val"===a&&jQuery(this).parent().find(n).val(e)})}jQuery,jQuery.fn.toggleDisabled=function(){return this.each(function(){var e,n=jQuery(this),a=n.data("name");n.attr("disabled")?(n.prop("disabled",!1),e="1"):(n.prop("disabled",!0),e="0"),r(a,"active",e)})},jQuery('.cmp-coming-soon-maintenance .social-inputs input[type="text"]').focusout(function(){var e=jQuery(this).data("name"),n=jQuery(this).val();r(e,"url",n)}),jQuery('.cmp-coming-soon-maintenance .social-inputs input[type="checkbox"]').click(function(e){jQuery(this).siblings('input[type="text"]').toggleDisabled()}),jQuery(".cmp-coming-soon-maintenance .social-media i").click(function(){var e=jQuery(this).data("name");jQuery(this).toggleClass("active"),jQuery(".cmp-coming-soon-maintenance .social-inputs li."+e).toggleClass("active"),jQuery(".cmp-coming-soon-maintenance .social-inputs li."+e+" input").trigger("change"),jQuery(this).hasClass("active")?r(e,"hidden","0"):r(e,"hidden","1"),jQuery(".cmp-coming-soon-maintenance .social-media i.active").length?jQuery(".social-inputs .label").css("display","block"):jQuery(".cmp-coming-soon-maintenance .social-inputs .label").css("display","none")}),jQuery(".cmp-coming-soon-maintenance .social-media i.active").length&&jQuery(".cmp-coming-soon-maintenance .social-inputs .label").css("display","block"),jQuery(".cmp.update-theme").click(function(e){e.preventDefault();var n=jQuery(this),a=n.parents(".notice"),t=n.data("security"),i=n.data("slug"),o=n.data("name"),r={action:"cmp_theme_update_install",security:t,file:{name:i,tmp_name:"",url:jQuery(this).data("remote_url")+"?action=download&slug="+i}};a.find(".message").html('<i class="fas fa-cog fa-spin fa-1x fa-fw"></i><span class="sr-only">Updating heme...</span><span> working hard on updating Theme...</span>'),jQuery.post(ajaxurl,r,function(e){if("success"==(e=e.trim()))setTimeout(function(){a.removeClass("notice-warning").addClass("notice-success"),a.find(".message").html("<span> "+o+' CMP theme was updated sucessfully! You can enjoy latest features now :) </span><i class="far fa-smile" aria-hidden="true"></i>')},1500);else{e=e.slice(0,-1);var n=jQuery("p",jQuery(e)).text();a.removeClass("notice-warning").addClass("notice-error"),a.find(".message").html('<i class="far fa-frown" aria-hidden="true"></i><span> '+n+"</span>")}})}),jQuery(".cmp-coming-soon-maintenance .theme-update.button").one("click",function(e){e.preventDefault();var n=jQuery(this),a=n.closest(".theme-wrapper"),t=a.data("security"),i=a.data("slug"),o={action:"cmp_theme_update_install",security:t,file:{name:i,tmp_name:"",url:a.data("remote_url")+"?action=download&slug="+i}};n.html('<i class="fas fa-cog fa-spin fa-1x fa-fw"></i><span>Updating..</span>'),jQuery.post(ajaxurl,o,function(e){"success"==e?setTimeout(function(){n.html('<i class="far fa-smile" aria-hidden="true"></i><span>Updated!</span>'),setTimeout(function(){n.fadeOut()},1500)},1500):(e=e.slice(0,-1),n.html('<i class="far fa-frown" aria-hidden="true"></i><span>Update Failed!</span>'))})}),jQuery(".cmp-coming-soon-maintenance .theme-details").click(function(e){e.preventDefault();var n=jQuery(this).closest(".theme-wrapper"),a=n.data("slug"),t=n.data("version"),i=n.data("type"),o=n.data("purchased"),r=0,s={action:"niteo_themeinfo",security:jQuery(".theme-wrapper").data("security"),theme_slug:jQuery(this).parents(".theme-wrapper").data("slug")};jQuery.post(ajaxurl,s,function(e){var s="",c="";if("true"==(e=jQuery.parseJSON(e)).result){if(jQuery("body").addClass("modal-open"),"1"==o&&(c='<span class="theme-version">Installed version: '+t+"</span>"),"1"!=o&&"premium"==i)s='<button type="button" class="theme-purchase button hide"><a href="'+n.find(".cmp-purchase-theme").attr("href")+'" target="_blank"><i class="fas fa-cart-arrow-down" aria-hidden="true"></i>Get Theme</a></button>';var l=e.screenshots,u="";Object.keys(l).length>1&&(u='<div class="screenshots-nav"><div class="left"><i class="fas fa-chevron-left" aria-hidden="true"></i></div><div class="right"><i class="fas fa-chevron-right" aria-hidden="true"></i></div></div>');var m=jQuery(['<div class="theme-backdrop">','\t<div class="theme-wrap">','\t\t<div class="theme-header">','\t\t\t<button class="close dashicons dashicons-no"><span class="screen-reader-text">Close details dialog</span></button>',"\t\t</div>",'\t\t<div class="theme-about">','\t\t\t<div class="theme-screenshots">','\t\t\t\t<div class="screenshot" style="background-image:url(\''+l[0]+"')\">"+u+"</div>","\t\t\t</div>",'\t\t\t<div class="theme-info">','\t\t\t\t<h2 class="theme-name">'+e.name+c+"</h2>",'\t\t\t\t<p class="theme-author">By <a href="'+e.author_homepage+'" target="_blank">'+e.author+"</a></p>","",s,'\t\t\t\t<div class="theme-description">'+e.description+"</div>","\t\t\t</div>","\t\t</div>",'\t\t<div class="theme-actions">','\t\t\t<a href="https://niteothemes.com/cmp-coming-soon-maintenance/?theme='+a+"&utm_source=cmp&utm_medium=referral&utm_campaign="+a+'" class="button cmp-preview" target="_blank" aria-label="Preview '+e.name+'">Live Preview</a>',"\t\t</div>","\t</div>","</div>"].join("\n"));jQuery(".theme-overlay.cmp").append(m),jQuery(".theme-overlay.cmp .close").click(function(e){e.preventDefault(),jQuery("body").removeClass("modal-open"),jQuery(".theme-overlay.cmp .theme-backdrop").fadeOut("fast")}),jQuery(".screenshots-nav .right").click(function(){++r==Object.keys(l).length&&(r=0),r in l&&jQuery(".screenshot").css("background-image","url('"+l[r]+"')")}),jQuery(".screenshots-nav .left").click(function(){--r<0&&(r=Object.keys(l).length-1),r in l&&jQuery(".screenshot").css("background-image","url('"+l[r]+"')")})}})}),jQuery(".cmp-coming-soon-maintenance #connect-mailchimp").click(function(e){e.preventDefault();var n=jQuery('.cmp-coming-soon-maintenance input[name="niteoCS_mailchimp_apikey"]').val(),a=jQuery(this).data("security"),t=jQuery(this);if(""!=n){var i={apikey:n,security:a};jQuery(this).prop("disabled",!0),jQuery(this).html('<i class="fas fa-cog fa-spin fa-1x fa-fw"></i><span> retrieving lists..</span>');var o={action:"cmp_mailchimp_list_ajax",security:a,params:i};jQuery.post(ajaxurl,o,function(e){var n=JSON.parse(e);200==n.response?(jQuery("#niteoCS_mailchimp_list").empty().prop("disabled",!1),jQuery.each(n.lists,function(e,n){jQuery("#niteoCS_mailchimp_list").append('<option value="'+n.id+'">'+n.name+"</option>")})):jQuery("#niteoCS_mailchimp_list").empty().prop("disabled",!0).html('<option value="error">'+n.message+"</option>").trigger("change"),t.html("Retrieve Lists"),t.prop("disabled",!1)}).fail(function(){t.html("Retrieve Lists"),t.prop("disabled",!1)})}}),jQuery(".cmp-coming-soon-maintenance .table-wrapper.theme-setup h4").each(function(){if("Overlay Color"==jQuery(this).html())return jQuery(this).parents("tr").remove(),!1}),jQuery(".nav-tab-wrapper").on("click",".theme-preview",function(e){return!(jQuery("#csoptions fieldset:not(.skip-preview-validation *)").serialize()!=t&&!confirm("You have made changes that will not be visible in the preview until you save them. Please save changes first.\nContinue anyway?"))||(e.preventDefault(),!1)})});
niteo-cmp.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: CMP - Coming Soon & Maintenance Plugin
4
  Plugin URI: https://wordpress.org/plugins/cmp-coming-soon-maintenance/
5
  Description: Display customizable landing page for Coming Soon, Maintenance & Under Construction page.
6
- Version: 4.0.8
7
  Author: NiteoThemes
8
  Author URI: https://www.niteothemes.com
9
  Text Domain: cmp-coming-soon-maintenance
@@ -62,8 +62,8 @@ if ( ! class_exists( 'CMP_Coming_Soon_and_Maintenance' ) ) :
62
 
63
  // define constants
64
  private function constants() {
65
- $this->define( 'CMP_VERSION', '4.0.8' );
66
- $this->define( 'CMP_DEBUG', FALSE );
67
  $this->define( 'CMP_AUTHOR', 'NiteoThemes' );
68
  $this->define( 'CMP_AUTHOR_HOMEPAGE', 'https://niteothemes.com' );
69
  $this->define( 'CMP_PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
@@ -463,6 +463,7 @@ if ( ! class_exists( 'CMP_Coming_Soon_and_Maintenance' ) ) :
463
  public function cmp_premium_themes() {
464
 
465
  $premium_themes = array();
 
466
  array_push( $premium_themes, array('name' => 'titan', 'url' => 'https://niteothemes.com/downloads/cmp-titan-theme/?utm_source=cmp&utm_medium=referral&utm_campaign=titan', 'price' => '12') );
467
  array_push( $premium_themes, array('name' => 'saturn', 'url' => 'https://niteothemes.com/downloads/cmp-saturn-theme/?utm_source=cmp&utm_medium=referral&utm_campaign=saturn', 'price' => '12') );
468
  array_push( $premium_themes, array('name' => 'mercury', 'url' => 'https://niteothemes.com/downloads/cmp-mercury-theme/?utm_source=cmp&utm_medium=referral&utm_campaign=mercury', 'price' => '10') );
3
  Plugin Name: CMP - Coming Soon & Maintenance Plugin
4
  Plugin URI: https://wordpress.org/plugins/cmp-coming-soon-maintenance/
5
  Description: Display customizable landing page for Coming Soon, Maintenance & Under Construction page.
6
+ Version: 4.0.9
7
  Author: NiteoThemes
8
  Author URI: https://www.niteothemes.com
9
  Text Domain: cmp-coming-soon-maintenance
62
 
63
  // define constants
64
  private function constants() {
65
+ $this->define( 'CMP_VERSION', '4.0.9' );
66
+ $this->define( 'CMP_DEBUG', false );
67
  $this->define( 'CMP_AUTHOR', 'NiteoThemes' );
68
  $this->define( 'CMP_AUTHOR_HOMEPAGE', 'https://niteothemes.com' );
69
  $this->define( 'CMP_PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
463
  public function cmp_premium_themes() {
464
 
465
  $premium_themes = array();
466
+ array_push( $premium_themes, array('name' => 'orion', 'url' => 'https://niteothemes.com/downloads/cmp-orion-theme/?utm_source=cmp&utm_medium=referral&utm_campaign=orion', 'price' => '12') );
467
  array_push( $premium_themes, array('name' => 'titan', 'url' => 'https://niteothemes.com/downloads/cmp-titan-theme/?utm_source=cmp&utm_medium=referral&utm_campaign=titan', 'price' => '12') );
468
  array_push( $premium_themes, array('name' => 'saturn', 'url' => 'https://niteothemes.com/downloads/cmp-saturn-theme/?utm_source=cmp&utm_medium=referral&utm_campaign=saturn', 'price' => '12') );
469
  array_push( $premium_themes, array('name' => 'mercury', 'url' => 'https://niteothemes.com/downloads/cmp-mercury-theme/?utm_source=cmp&utm_medium=referral&utm_campaign=mercury', 'price' => '10') );
readme.txt CHANGED
@@ -5,7 +5,7 @@ Tags: coming soon, coming soon page, launch page, maintenance mode, under constr
5
  Requires at least: 3.0
6
  Requires PHP: 5.6
7
  Tested up to: 5.7
8
- Stable tag: 4.0.8
9
  License: GPLv2 or later
10
  License URI: https://www.gnu.org/licenses/gpl-2.0.html
11
 
@@ -160,6 +160,11 @@ https://www.youtube.com/watch?v=uxuJfHzwdtE
160
  <p>Nothing is better than a good feedback! Please go to <a href="https://wordpress.org/support/plugin/cmp-coming-soon-maintenance/reviews/">Plugin reviews</a> and rate it! Alternatively you can click on a Donate button too!:)</p>
161
 
162
  == Changelog ==
 
 
 
 
 
163
  <h4>CMP 4.0.8 - 16-Mar-21</h4>
164
  <ul>
165
  <li>Resolved Unsplash Image loading, broken since API Unsplash changes.</li>
5
  Requires at least: 3.0
6
  Requires PHP: 5.6
7
  Tested up to: 5.7
8
+ Stable tag: 4.0.9
9
  License: GPLv2 or later
10
  License URI: https://www.gnu.org/licenses/gpl-2.0.html
11
 
160
  <p>Nothing is better than a good feedback! Please go to <a href="https://wordpress.org/support/plugin/cmp-coming-soon-maintenance/reviews/">Plugin reviews</a> and rate it! Alternatively you can click on a Donate button too!:)</p>
161
 
162
  == Changelog ==
163
+ <h4>CMP 4.0.9 - 13-Apr-21</h4>
164
+ <ul>
165
+ <li>Orion - New CMP theme available!</li>
166
+ <li>Some minor code changes.</li>
167
+ </ul>
168
  <h4>CMP 4.0.8 - 16-Mar-21</h4>
169
  <ul>
170
  <li>Resolved Unsplash Image loading, broken since API Unsplash changes.</li>
themes/orion.txt ADDED
@@ -0,0 +1,4 @@
 
 
 
 
1
+ /*
2
+ Theme Name: Orion
3
+ Description: <p>CMP Orion, is a template supporting all available functions of our plugin. In addition, you can add a so-called POI - point of interest to better specify what you are doing or what interests you. Of course you can edit the logo, fonts, subscribe form, links to social networks, background effects, footer. You can also activate the symbol on the login page and the language translation switch.</p><h4>Main Features</h4><ul><li class="supported"><i class="far fa-check-square" aria-hidden="true"></i> Custom Logo</li><li class="supported"><i class="far fa-check-square" aria-hidden="true"></i> Custom Content</li><li class="supported"><i class="far fa-check-square" aria-hidden="true"></i> Graphic Background including videos</li><li class="supported"><i class="far fa-check-square" aria-hidden="true"></i> Graphic Image Slider Background</li><li class="supported"><i class="far fa-check-square" aria-hidden="true"></i> Countdown Timer</li><li class="supported"><i class="far fa-check-square" aria-hidden="true"></i> Subscribe Form</li><li class="supported"><i class="far fa-check-square" aria-hidden="true"></i> Social Media</li><li class="supported"><i class="far fa-check-square" aria-hidden="true"></i> Custom Colors</li><li class="supported"><i class="far fa-check-square" aria-hidden="true"></i> Custom Fonts</li><li class="supported"><i class="far fa-check-square" aria-hidden="true"></i> Background Blur Effect</li><li class="supported"><i class="far fa-check-square" aria-hidden="true"></i> Background Special Effects</li><li class="supported"><i class="far fa-check-square" aria-hidden="true"></i> Responsive Design</li></ul>
4
+