LoftLoader - Version 2.3.2

Version Description

  • Improved: Compatibility with WordPress 5.5
Download this release

Release Info

Developer loftocean
Plugin Icon 128x128 LoftLoader
Version 2.3.2
Comparing to
See all releases

Code changes from version 2.3.1 to 2.3.2

assets/css/loftloader-settings.css CHANGED
@@ -6,7 +6,7 @@
6
  * Author: Kaylolo Yinxi Chen @Loft.Ocean
7
  * Author URI: http://www.loftocean.com
8
  * Description: LoftLoader (Lite Version) is a plugin for adding beautiful and smooth preload animation to your WordPress website. With setting options, you can choose from preset animations, add custom logo image, choose colours to match your branding, and amuse and impress your visitors while loading site content.
9
- * Version: 2.3.1
10
  */
11
  @import url(https://fonts.googleapis.com/css?family=Lato:400,600);
12
  #customize-theme-controls.loftloader-controls-wrapper {
6
  * Author: Kaylolo Yinxi Chen @Loft.Ocean
7
  * Author URI: http://www.loftocean.com
8
  * Description: LoftLoader (Lite Version) is a plugin for adding beautiful and smooth preload animation to your WordPress website. With setting options, you can choose from preset animations, add custom logo image, choose colours to match your branding, and amuse and impress your visitors while loading site content.
9
+ * Version: 2.3.2
10
  */
11
  @import url(https://fonts.googleapis.com/css?family=Lato:400,600);
12
  #customize-theme-controls.loftloader-controls-wrapper {
assets/css/loftloader.css CHANGED
@@ -6,7 +6,7 @@
6
  * Author: Kaylolo Yinxi Chen @Loft.Ocean
7
  * Author URI: http://www.loftocean.com
8
  * Description: LoftLoader (Lite Version) is a plugin for adding beautiful and smooth preload animation to your WordPress website. With setting options, you can choose from preset animations, add custom logo image, choose colours to match your branding, and amuse and impress your visitors while loading site content.
9
- * Version: 2.3.1
10
  */
11
  @-webkit-keyframes spinReturn {
12
  0% {
6
  * Author: Kaylolo Yinxi Chen @Loft.Ocean
7
  * Author URI: http://www.loftocean.com
8
  * Description: LoftLoader (Lite Version) is a plugin for adding beautiful and smooth preload animation to your WordPress website. With setting options, you can choose from preset animations, add custom logo image, choose colours to match your branding, and amuse and impress your visitors while loading site content.
9
+ * Version: 2.3.2
10
  */
11
  @-webkit-keyframes spinReturn {
12
  0% {
assets/js/customize.js CHANGED
@@ -11,19 +11,16 @@
11
  return api.Section.prototype.initialize.apply( this, arguments );
12
  },
13
  ready: function(){
14
- var checked = this.container.find('input[name=loftloader-main-switch]').attr('checked') ? true : false;
15
- checked ? '' : $('#customize-theme-controls').addClass('loftloader-settings-disabled');
16
  $('#customize-theme-controls').addClass('loftloader-controls-wrapper');
17
  },
18
  attachEvents: function () {
19
  var container = this.container;
20
  container.on('change', 'input[name=loftloader-main-switch]', function(e){
21
- var checked = $(this).attr('checked') ? true : false,
22
- $element = container.find('#customize-control-loftloader_main_switch input[type=checkbox]'),
23
- controls_wrap = $('#customize-theme-controls');
24
 
25
- checked ? $element.attr('checked', 'checked') : $element.removeAttr('checked');
26
- $element.trigger('change');
27
  checked ? controls_wrap.removeClass('loftloader-settings-disabled') : controls_wrap.addClass('loftloader-settings-disabled');
28
  });
29
  }
@@ -101,11 +98,9 @@
101
  (val < min) ? $(this).val(min).trigger('change') : '';
102
  })
103
  .on('change', 'input.loftlader-checkbox', function(e){
104
- var checked = $(this).attr('checked') ? true : false,
105
- $element = $(this).siblings('input');
106
- if($element.length){
107
- checked ? $element.attr('checked', 'checked') : $element.removeAttr('checked');
108
- $element.trigger('change');
109
  }
110
  })
111
  .on('click', '.customize-more-toggle', function(e){
11
  return api.Section.prototype.initialize.apply( this, arguments );
12
  },
13
  ready: function(){
14
+ var checked = this.container.find('input[name=loftloader-main-switch]').is(':checked');
15
+ checked ? '' : $( '#customize-theme-controls' ).addClass( 'loftloader-settings-disabled' );
16
  $('#customize-theme-controls').addClass('loftloader-controls-wrapper');
17
  },
18
  attachEvents: function () {
19
  var container = this.container;
20
  container.on('change', 'input[name=loftloader-main-switch]', function(e){
21
+ var checked = $(this).is(':checked'), controls_wrap = $('#customize-theme-controls');
 
 
22
 
23
+ api( 'loftloader_main_switch' )( checked );
 
24
  checked ? controls_wrap.removeClass('loftloader-settings-disabled') : controls_wrap.addClass('loftloader-settings-disabled');
25
  });
26
  }
98
  (val < min) ? $(this).val(min).trigger('change') : '';
99
  })
100
  .on('change', 'input.loftlader-checkbox', function(e){
101
+ var $element = $(this).siblings('input');
102
+ if ( $element.length && $element.attr( 'data-customize-setting-link' ) ) {
103
+ api( $element.attr( 'data-customize-setting-link' ) )( $(this).is( ':checked' ) );
 
 
104
  }
105
  })
106
  .on('click', '.customize-more-toggle', function(e){
assets/js/customize.min.js CHANGED
@@ -1 +1 @@
1
- !function(s,c){function l(e){var t,o=s.get(),a=!!o[e]&&o[e];return"string"==typeof a&&(a=a.trim()),!0===(t=a)?"on":t}c("head").append(c("<style>",{id:"loftloader-hide-site-title",text:".site-title { opacity: 0; }"})),s.LoftLoaderSwitchSection=s.Section.extend({initialize:function(){return s.Section.prototype.initialize.apply(this,arguments)},ready:function(){this.container.find("input[name=loftloader-main-switch]").attr("checked")||c("#customize-theme-controls").addClass("loftloader-settings-disabled"),c("#customize-theme-controls").addClass("loftloader-controls-wrapper")},attachEvents:function(){var l=this.container;l.on("change","input[name=loftloader-main-switch]",function(e){var t=!!c(this).attr("checked"),o=l.find("#customize-control-loftloader_main_switch input[type=checkbox]"),a=c("#customize-theme-controls");t?o.attr("checked","checked"):o.removeAttr("checked"),o.trigger("change"),t?a.removeClass("loftloader-settings-disabled"):a.addClass("loftloader-settings-disabled")})}}),c.extend(s.sectionConstructor,{loftloader_switch:s.LoftLoaderSwitchSection}),s.controlConstructor.slider=s.Control.extend({ready:function(){var e=this.container.find(".loader-ui-slider"),o=this.container.find("input[data-customize-setting-link]");e.slider({range:"min",min:e.data("min"),max:e.data("max"),value:e.data("value"),step:e.data("step"),slide:function(e,t){o.val(t.value).trigger("change")}})}}),s.bind("ready",function(e){loftloader_lite_i18n&&c(".site-title").text(loftloader_lite_i18n.name),c("#loftloader-hide-site-title").remove();var t,o=document.createElement("a");o.href=s.previewer.previewUrl(),t=s.utils.parseQueryString(o.search.substr(1)),s.previewer.unbind("url").bind("url",function(e){var t,o=this,a=!1,l=document.createElement("a");l.href=e,l.search=c.param({plugin:"loftloader-lite"}),e=l.href,o.scroll=0,t=function(){a=!0},o.previewUrl.bind(t),o.previewUrl.set(e),o.previewUrl.unbind(t),a||o.refresh()}),t.plugin||(t.plugin="loftloader-lite",o.search=c.param(t),s.previewer.previewUrl.set(o.href));var a,l,i,r=s.get(),n=c("#customize-control-loftloader_custom_img");n.length&&!n.find(".attachment-thumb").length&&r&&r.loftloader_custom_img&&((a=r.loftloader_custom_img)&&(l=n.find(".attachment-media-view").addClass("attachment-media-view-image"),i=c("<div>",{class:"thumbnail thumbnail-image"}).append(c("<img>",{class:"attachment-thumb",src:a})),l.children(".placeholder").css("display","none").after(i).remove())),c("body").on("change","input[type=number]",function(e){var t=parseInt(c(this).val()),o=c(this).attr("min")?parseInt(c(this).attr("min")):1;t<o&&c(this).val(o).trigger("change")}).on("change","input.loftlader-checkbox",function(e){var t=!!c(this).attr("checked"),o=c(this).siblings("input");o.length&&(t?o.attr("checked","checked"):o.removeAttr("checked"),o.trigger("change"))}).on("click",".customize-more-toggle",function(e){e.preventDefault();var t=c(this),o=c(this).siblings(".customize-control-description");o.length&&(t.hasClass("expanded")?o.slideUp("slow"):o.slideDown("slow",function(){c(this).css("display","block")}),t.toggleClass("expanded"))}).on("click",".loftloader-any-page-generate",function(e){e.preventDefault();var t=s.loftloader_generate_parameters();c(this).siblings(".loftloader-any-page-shortcode").val("[loftloader "+t+"]").select()})}),s.loftloader_generate_parameters=function(){var e={loftloader_bg_color:{},loftloader_bg_opacity:{},loftloader_bg_animation:{},loftloader_loader_type:{sun:["loftloader_loader_color"],circles:["loftloader_loader_color"],wave:["loftloader_loader_color"],square:["loftloader_loader_color"],beating:["loftloader_loader_color"],frame:["loftloader_loader_color","loftloader_custom_img"],imgloading:["loftloader_custom_img","loftloader_img_width"]},loftloader_show_close_timer:{},loftloader_show_close_tip:{},loftloader_max_load_time:{},loftloader_inline_js:{}},t=type_value=loop="";if("on"===l("loftloader_main_switch"))for(var o in t="loftloader_main_switch=on loftloader_show_range=sitewide",e){switch(type_value=l(o),o){case"loftloader_show_close_tip":type_value=type_value?'"'+btoa(unescape(encodeURIComponent(type_value)))+'"':'""';case"loftloader_bg_color":case"loftloader_bg_opacity":case"loftloader_bg_animation":loop=[];break;case"loftloader_max_load_time":type_value=type_value||0;break;default:loop=e[o][type_value]?e[o][type_value]:[]}if(t+=" "+o+"="+type_value,loop)for(var a in loop)t+=" "+loop[a]+"="+l(loop[a])}else t="loftloader_main_switch=false";return t}}(wp.customize,jQuery);
1
+ !function(s,d){function l(e){var t,o=s.get(),a=!!o[e]&&o[e];return"string"==typeof a&&(a=a.trim()),!0===(t=a)?"on":t}d("head").append(d("<style>",{id:"loftloader-hide-site-title",text:".site-title { opacity: 0; }"})),s.LoftLoaderSwitchSection=s.Section.extend({initialize:function(){return s.Section.prototype.initialize.apply(this,arguments)},ready:function(){this.container.find("input[name=loftloader-main-switch]").is(":checked")||d("#customize-theme-controls").addClass("loftloader-settings-disabled"),d("#customize-theme-controls").addClass("loftloader-controls-wrapper")},attachEvents:function(){this.container.on("change","input[name=loftloader-main-switch]",function(e){var t=d(this).is(":checked"),o=d("#customize-theme-controls");s("loftloader_main_switch")(t),t?o.removeClass("loftloader-settings-disabled"):o.addClass("loftloader-settings-disabled")})}}),d.extend(s.sectionConstructor,{loftloader_switch:s.LoftLoaderSwitchSection}),s.controlConstructor.slider=s.Control.extend({ready:function(){var e=this.container.find(".loader-ui-slider"),o=this.container.find("input[data-customize-setting-link]");e.slider({range:"min",min:e.data("min"),max:e.data("max"),value:e.data("value"),step:e.data("step"),slide:function(e,t){o.val(t.value).trigger("change")}})}}),s.bind("ready",function(e){loftloader_lite_i18n&&d(".site-title").text(loftloader_lite_i18n.name),d("#loftloader-hide-site-title").remove();var t,o=document.createElement("a");o.href=s.previewer.previewUrl(),t=s.utils.parseQueryString(o.search.substr(1)),s.previewer.unbind("url").bind("url",function(e){var t,o=this,a=!1,l=document.createElement("a");l.href=e,l.search=d.param({plugin:"loftloader-lite"}),e=l.href,o.scroll=0,t=function(){a=!0},o.previewUrl.bind(t),o.previewUrl.set(e),o.previewUrl.unbind(t),a||o.refresh()}),t.plugin||(t.plugin="loftloader-lite",o.search=d.param(t),s.previewer.previewUrl.set(o.href));var a,l,i,r=s.get(),n=d("#customize-control-loftloader_custom_img");n.length&&!n.find(".attachment-thumb").length&&r&&r.loftloader_custom_img&&((a=r.loftloader_custom_img)&&(l=n.find(".attachment-media-view").addClass("attachment-media-view-image"),i=d("<div>",{class:"thumbnail thumbnail-image"}).append(d("<img>",{class:"attachment-thumb",src:a})),l.children(".placeholder").css("display","none").after(i).remove())),d("body").on("change","input[type=number]",function(e){var t=parseInt(d(this).val()),o=d(this).attr("min")?parseInt(d(this).attr("min")):1;t<o&&d(this).val(o).trigger("change")}).on("change","input.loftlader-checkbox",function(e){var t=d(this).siblings("input");t.length&&t.attr("data-customize-setting-link")&&s(t.attr("data-customize-setting-link"))(d(this).is(":checked"))}).on("click",".customize-more-toggle",function(e){e.preventDefault();var t=d(this),o=d(this).siblings(".customize-control-description");o.length&&(t.hasClass("expanded")?o.slideUp("slow"):o.slideDown("slow",function(){d(this).css("display","block")}),t.toggleClass("expanded"))}).on("click",".loftloader-any-page-generate",function(e){e.preventDefault();var t=s.loftloader_generate_parameters();d(this).siblings(".loftloader-any-page-shortcode").val("[loftloader "+t+"]").select()})}),s.loftloader_generate_parameters=function(){var e={loftloader_bg_color:{},loftloader_bg_opacity:{},loftloader_bg_animation:{},loftloader_loader_type:{sun:["loftloader_loader_color"],circles:["loftloader_loader_color"],wave:["loftloader_loader_color"],square:["loftloader_loader_color"],beating:["loftloader_loader_color"],frame:["loftloader_loader_color","loftloader_custom_img"],imgloading:["loftloader_custom_img","loftloader_img_width"]},loftloader_show_close_timer:{},loftloader_show_close_tip:{},loftloader_max_load_time:{},loftloader_inline_js:{}},t=type_value=loop="";if("on"===l("loftloader_main_switch"))for(var o in t="loftloader_main_switch=on loftloader_show_range=sitewide",e){switch(type_value=l(o),o){case"loftloader_show_close_tip":type_value=type_value?'"'+btoa(unescape(encodeURIComponent(type_value)))+'"':'""';case"loftloader_bg_color":case"loftloader_bg_opacity":case"loftloader_bg_animation":loop=[];break;case"loftloader_max_load_time":type_value=type_value||0;break;default:loop=e[o][type_value]?e[o][type_value]:[]}if(t+=" "+o+"="+type_value,loop)for(var a in loop)t+=" "+loop[a]+"="+l(loop[a])}else t="loftloader_main_switch=false";return t}}(wp.customize,jQuery);
assets/scss/loftloader-settings.scss CHANGED
@@ -6,7 +6,7 @@
6
  * Author: Kaylolo Yinxi Chen @Loft.Ocean
7
  * Author URI: http://www.loftocean.com
8
  * Description: LoftLoader (Lite Version) is a plugin for adding beautiful and smooth preload animation to your WordPress website. With setting options, you can choose from preset animations, add custom logo image, choose colours to match your branding, and amuse and impress your visitors while loading site content.
9
- * Version: 2.3.1
10
  */
11
 
12
 
6
  * Author: Kaylolo Yinxi Chen @Loft.Ocean
7
  * Author URI: http://www.loftocean.com
8
  * Description: LoftLoader (Lite Version) is a plugin for adding beautiful and smooth preload animation to your WordPress website. With setting options, you can choose from preset animations, add custom logo image, choose colours to match your branding, and amuse and impress your visitors while loading site content.
9
+ * Version: 2.3.2
10
  */
11
 
12
 
assets/scss/loftloader.scss CHANGED
@@ -6,7 +6,7 @@
6
  * Author: Kaylolo Yinxi Chen @Loft.Ocean
7
  * Author URI: http://www.loftocean.com
8
  * Description: LoftLoader (Lite Version) is a plugin for adding beautiful and smooth preload animation to your WordPress website. With setting options, you can choose from preset animations, add custom logo image, choose colours to match your branding, and amuse and impress your visitors while loading site content.
9
- * Version: 2.3.1
10
  */
11
 
12
  $primary-color: #248acc;
6
  * Author: Kaylolo Yinxi Chen @Loft.Ocean
7
  * Author URI: http://www.loftocean.com
8
  * Description: LoftLoader (Lite Version) is a plugin for adding beautiful and smooth preload animation to your WordPress website. With setting options, you can choose from preset animations, add custom logo image, choose colours to match your branding, and amuse and impress your visitors while loading site content.
9
+ * Version: 2.3.2
10
  */
11
 
12
  $primary-color: #248acc;
languages/loftloader.pot CHANGED
@@ -2,7 +2,7 @@
2
  # This file is distributed under the same license as the LoftLoader plugin.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: LoftLoader 2.3.1\n"
6
  "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/loftloader\n"
7
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
8
  "Language-Team: LANGUAGE <LL@li.org>\n"
2
  # This file is distributed under the same license as the LoftLoader plugin.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: LoftLoader 2.3.2\n"
6
  "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/loftloader\n"
7
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
8
  "Language-Team: LANGUAGE <LL@li.org>\n"
loftloader.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: LoftLoader
4
  Plugin URI: http://www.loftocean.com/
5
  Description: An easy to use plugin to add an animated preloader to your website with fully customisations.
6
- Version: 2.3.1
7
  Author: Loft.Ocean
8
  Author URI: http://www.loftocean.com/
9
  Text Domain: loftloader
@@ -32,7 +32,7 @@ if ( ! class_exists( 'LoftLoader' ) ) {
32
  define( 'LOFTLOADER_ROOT', dirname( __FILE__ ) . '/' );
33
  define( 'LOFTLOADER_NAME', plugin_basename( __FILE__ ) );
34
  define( 'LOFTLOADER_URI', plugin_dir_url( __FILE__ ) );
35
- define( 'LOFTLOADER_ASSET_VERSION', '2020081203' );
36
 
37
  class LoftLoader {
38
  public function __construct() {
3
  Plugin Name: LoftLoader
4
  Plugin URI: http://www.loftocean.com/
5
  Description: An easy to use plugin to add an animated preloader to your website with fully customisations.
6
+ Version: 2.3.2
7
  Author: Loft.Ocean
8
  Author URI: http://www.loftocean.com/
9
  Text Domain: loftloader
32
  define( 'LOFTLOADER_ROOT', dirname( __FILE__ ) . '/' );
33
  define( 'LOFTLOADER_NAME', plugin_basename( __FILE__ ) );
34
  define( 'LOFTLOADER_URI', plugin_dir_url( __FILE__ ) );
35
+ define( 'LOFTLOADER_ASSET_VERSION', '2020081301' );
36
 
37
  class LoftLoader {
38
  public function __construct() {
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: loader, load, preloader, page preloader, prelader spinner, preloader with
4
  Donate link:
5
  Requires at least: 4.7
6
  Tested up to: 5.5
7
- Stable tag: 2.3.1
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -96,6 +96,9 @@ Check some [examples](http://www.loftocean.com/loftloader/example-13/) created b
96
  8. Pro version: Load Time, Device Control & Smooth Page Transition
97
 
98
  == Changelog ==
 
 
 
99
  = 2.3.1 =
100
  * Fixed: The preview area is not displayed when setting the loader
101
 
4
  Donate link:
5
  Requires at least: 4.7
6
  Tested up to: 5.5
7
+ Stable tag: 2.3.2
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
96
  8. Pro version: Load Time, Device Control & Smooth Page Transition
97
 
98
  == Changelog ==
99
+ = 2.3.2 =
100
+ * Improved: Compatibility with WordPress 5.5
101
+
102
  = 2.3.1 =
103
  * Fixed: The preview area is not displayed when setting the loader
104