SiteOrigin Widgets Bundle - Version 1.33.1

Version Description

  • 30 April 2022 =
  • Accordion and Tabs: Added support for the SiteOrigin Premium Anchor ID Addon.
  • Anything Carousel: Resolved a Previous Nav Arrow error.
  • Anything Carousel: Improved theme compatibility by preventing nav arrow container overflow hidden.
  • Lottie Player: Fixed an error in the closing </div> tag.
Download this release

Release Info

Developer SiteOrigin
Plugin Icon 128x128 SiteOrigin Widgets Bundle
Version 1.33.1
Comparing to
See all releases

Code changes from version 1.33.0 to 1.33.1

js/carousel.js CHANGED
@@ -170,6 +170,8 @@ jQuery( function ( $ ) {
170
  } else if ( $( this ).hasClass( 'sow-carousel-previous' ) ) {
171
  if ( $$.data( 'carousel_settings' ).loop && $items.slick( 'slickCurrentSlide' ) == 0 ) {
172
  $items.slick( 'slickGoTo', lastPosition );
 
 
173
  } else {
174
  $items.slick( 'slickPrev' );
175
  }
170
  } else if ( $( this ).hasClass( 'sow-carousel-previous' ) ) {
171
  if ( $$.data( 'carousel_settings' ).loop && $items.slick( 'slickCurrentSlide' ) == 0 ) {
172
  $items.slick( 'slickGoTo', lastPosition );
173
+ } else if ( ! $$.data( 'carousel_settings' ).loop && $items.slick( 'slickCurrentSlide' ) <= slidesToScroll ) {
174
+ $items.slick( 'slickGoTo', 1 );
175
  } else {
176
  $items.slick( 'slickPrev' );
177
  }
js/carousel.min.js CHANGED
@@ -1 +1 @@
1
- var sowb=window.sowb||{};jQuery((function(i){sowb.setupCarousel=function(){i.fn.setSlideTo=function(s){$item=i(this);var e=$item.slick("slickGetOption","slidesToShow"),t=$item.slick("slickGetOption","slidesToScroll");$item.slick("slickSetOption","slidesToShow",1),$item.slick("slickSetOption","slidesToScroll",1),$item.slick("slickGoTo",s),$item.slick("slickSetOption","slidesToShow",e),$item.slick("slickSetOption","slidesToScroll",t)},i(".sow-carousel-wrapper").on("init",(function(s,e){i(this).css("opacity",1)})),i(".sow-carousel-wrapper").each((function(){var s=i(this),e=s.find(".sow-carousel-items"),t=s.data("responsive"),o=s.data("carousel_settings");if(e.not(".slick-initialized").slick({arrows:!1,dots:o.dots,appendDots:o.appendDots?s.find(".sow-carousel-nav"):s,rows:0,rtl:"rtl"==s.data("dir"),touchThreshold:20,infinite:o.loop&&(!s.data("ajax-url")||s.data("ajax-url")&&o.autoplay_continuous_scroll&&o.autoplay),variableWidth:s.data("variable_width"),accessibility:!1,cssEase:o.animation,speed:o.animation_speed,slidesToScroll:t.desktop_slides_to_scroll,slidesToShow:void 0===t.desktop_slides_to_show?t.desktop_slides_to_scroll:t.desktop_slides_to_show,responsive:[{breakpoint:t.tablet_portrait_breakpoint,settings:{slidesToScroll:t.tablet_portrait_slides_to_scroll,slidesToShow:void 0===t.tablet_portrait_slides_to_show?t.tablet_portrait_slides_to_scroll:t.tablet_portrait_slides_to_show}},{breakpoint:t.mobile_breakpoint,settings:{slidesToScroll:t.mobile_slides_to_scroll,slidesToShow:void 0===t.mobile_slides_to_show?t.mobile_slides_to_scroll:t.mobile_slides_to_show}}]}),o.item_overflow&&(e.css("width",""),e.css("opacity","")),e.on("swipe",(function(i,e,t){s.parent().parent().find(".sow-carousel-"+("left"==t?"next":"prev")).trigger("touchend")})),o.autoplay){var l=!1,a=s.parent().parent().find(".sow-carousel-"+("ltr"==s.data("dir")?"next":"prev"));setInterval((function(){l||a.trigger("click")}),o.autoplaySpeed),o.pauseOnHover&&(e.on("mouseenter.slick",(function(){l=!0})),e.on("mouseleave.slick",(function(){l=!1})))}if(s.parent().parent().find(".sow-carousel-previous, .sow-carousel-next").on("click touchend",(function(e,t){e.preventDefault();var l=s.find(".sow-carousel-items"),a=l.find(".sow-carousel-item").length,c=a>=s.data("item_count"),n=Math.ceil(l.outerWidth()/l.find(".sow-carousel-item").outerWidth(!0)),r=l.slick("slickGetOption","slidesToScroll"),d=a-n,u=!1;"post"==s.data("widget")&&"undefined"!=s.data("carousel_settings").theme&&c&&d++,c||(l.slick("slickCurrentSlide")+n>=a-1||l.slick("slickCurrentSlide")+r>d)&&(i(sowb).trigger("carousel_load_new_items",[s,l,t]),u=!0),i(this).hasClass("sow-carousel-next")&&!u?c&&l.slick("slickCurrentSlide")>=d?s.data("carousel_settings").loop&&l.slick("slickGoTo",0):l.slick("slickCurrentSlide")+r>d?l.setSlideTo(d):l.slick("slickNext"):i(this).hasClass("sow-carousel-previous")&&(s.data("carousel_settings").loop&&0==l.slick("slickCurrentSlide")?l.slick("slickGoTo",d):l.slick("slickPrev")),o.dots&&"post"==s.data("widget")&&(s.find("li.slick-active").removeClass("slick-active"),s.find(".slick-dots li").eq(Math.ceil(s.find(".sow-carousel-items").slick("slickCurrentSlide")/r)).addClass("slick-active"))})),o.dots&&(s.data("variable_width")||s.data("carousel_settings").theme)){s.find(".slick-dots li").off("click.slick");var c=function(){e=s.find(".sow-carousel-items");var t=i(this).index(),o=e.slick("slickGetOption","slidesToScroll"),l=e.find(".sow-carousel-item").length,a=Math.ceil(e.outerWidth()/e.find(".sow-carousel-item").outerWidth(!0)),c=l-a;(t+a>=l?(e.slick("slickGoTo",c),$dots=i(this).parent(),$dots.find(".slick-active").removeClass("slick-active"),$dots.children().eq(t).addClass("slick-active")):("post"==s.data("widget")&&(t=Math.ceil(i(this).index()*o)),e.slick("slickGoTo",t)),"post"==s.data("widget"))&&(l>=s.data("item_count")||(e.slick("slickCurrentSlide")+a>=l-1||e.slick("slickCurrentSlide")+o>c)&&i(sowb).trigger("carousel_load_new_items",[s,e,!1]))};s.find(".slick-dots li").on("click touchend",c),i(sowb).on("carousel_posts_added",(function(){s.find(".slick-dots li").on("click touchend",c)}))}})),i(sowb).trigger("carousel_setup"),i(document).on("keydown",".sow-carousel-navigation a",(function(s){13!=s.keyCode&&32!=s.keyCode||(s.preventDefault(),i(this).trigger("click"))})),i(document).on("keyup",".sow-carousel-item",(function(s){if(13==s.keyCode&&i(this).find("h3 a")[0].click(),37==s.keyCode||39==s.keyCode){var e=i(this).parents(".sow-carousel-wrapper"),t=e.find(".sow-carousel-items"),o=t.find(".sow-carousel-item").length,l=i(this).data("slick-index"),a=o-(o===e.data("item_count")?0:1);if(37==s.keyCode)--l<0&&(l=a);else if(39==s.keyCode&&++l>=a){if(e.data("fetching"))return;e.parent().find(".sow-carousel-next").trigger("click",!0)}t.slick("slickGoTo",l,!0),e.find(".sow-carousel-item").prop("tabindex",-1),e.find('.sow-carousel-item[data-slick-index="'+l+'"]').trigger("focus").prop("tabindex",0)}}));var s=function(){i(".sow-carousel-wrapper").each((function(){var s=i(this),e=s.find(".sow-carousel-items.slick-initialized"),t=Math.ceil(e.outerWidth()/e.find(".sow-carousel-item").outerWidth(!0)),o=s.parent().parent().find(".sow-carousel-navigation");t>=s.data("item_count")?(o.hide(),e.slick("slickSetOption","touchMove",!1),e.slick("slickSetOption","draggable",!1)):o.not(":visible")&&(o.show(),e.slick("slickSetOption","touchMove",!0),e.slick("slickSetOption","draggable",!0));var l=s.data("responsive");window.matchMedia("(min-width: "+l.tablet_portrait_breakpoint+"px) and (max-width: "+l.tablet_landscape_breakpoint+"px) and (orientation: landscape)").matches&&(e.slick("slickSetOption","slidesToShow",l.tablet_landscape_slides_to_show),e.slick("slickSetOption","slidesToScroll",l.tablet_landscape_slides_to_scroll))})),i(".sow-carousel-item:first-of-type").prop("tabindex",0)};s(),i(window).on("resize load",s)},sowb.setupCarousel(),i(sowb).on("setup_widgets",sowb.setupCarousel)})),window.sowb=sowb;
1
+ var sowb=window.sowb||{};jQuery((function(i){sowb.setupCarousel=function(){i.fn.setSlideTo=function(s){$item=i(this);var e=$item.slick("slickGetOption","slidesToShow"),t=$item.slick("slickGetOption","slidesToScroll");$item.slick("slickSetOption","slidesToShow",1),$item.slick("slickSetOption","slidesToScroll",1),$item.slick("slickGoTo",s),$item.slick("slickSetOption","slidesToShow",e),$item.slick("slickSetOption","slidesToScroll",t)},i(".sow-carousel-wrapper").on("init",(function(s,e){i(this).css("opacity",1)})),i(".sow-carousel-wrapper").each((function(){var s=i(this),e=s.find(".sow-carousel-items"),t=s.data("responsive"),o=s.data("carousel_settings");if(e.not(".slick-initialized").slick({arrows:!1,dots:o.dots,appendDots:o.appendDots?s.find(".sow-carousel-nav"):s,rows:0,rtl:"rtl"==s.data("dir"),touchThreshold:20,infinite:o.loop&&(!s.data("ajax-url")||s.data("ajax-url")&&o.autoplay_continuous_scroll&&o.autoplay),variableWidth:s.data("variable_width"),accessibility:!1,cssEase:o.animation,speed:o.animation_speed,slidesToScroll:t.desktop_slides_to_scroll,slidesToShow:void 0===t.desktop_slides_to_show?t.desktop_slides_to_scroll:t.desktop_slides_to_show,responsive:[{breakpoint:t.tablet_portrait_breakpoint,settings:{slidesToScroll:t.tablet_portrait_slides_to_scroll,slidesToShow:void 0===t.tablet_portrait_slides_to_show?t.tablet_portrait_slides_to_scroll:t.tablet_portrait_slides_to_show}},{breakpoint:t.mobile_breakpoint,settings:{slidesToScroll:t.mobile_slides_to_scroll,slidesToShow:void 0===t.mobile_slides_to_show?t.mobile_slides_to_scroll:t.mobile_slides_to_show}}]}),o.item_overflow&&(e.css("width",""),e.css("opacity","")),e.on("swipe",(function(i,e,t){s.parent().parent().find(".sow-carousel-"+("left"==t?"next":"prev")).trigger("touchend")})),o.autoplay){var l=!1,a=s.parent().parent().find(".sow-carousel-"+("ltr"==s.data("dir")?"next":"prev"));setInterval((function(){l||a.trigger("click")}),o.autoplaySpeed),o.pauseOnHover&&(e.on("mouseenter.slick",(function(){l=!0})),e.on("mouseleave.slick",(function(){l=!1})))}if(s.parent().parent().find(".sow-carousel-previous, .sow-carousel-next").on("click touchend",(function(e,t){e.preventDefault();var l=s.find(".sow-carousel-items"),a=l.find(".sow-carousel-item").length,c=a>=s.data("item_count"),n=Math.ceil(l.outerWidth()/l.find(".sow-carousel-item").outerWidth(!0)),r=l.slick("slickGetOption","slidesToScroll"),d=a-n,u=!1;"post"==s.data("widget")&&"undefined"!=s.data("carousel_settings").theme&&c&&d++,c||(l.slick("slickCurrentSlide")+n>=a-1||l.slick("slickCurrentSlide")+r>d)&&(i(sowb).trigger("carousel_load_new_items",[s,l,t]),u=!0),i(this).hasClass("sow-carousel-next")&&!u?c&&l.slick("slickCurrentSlide")>=d?s.data("carousel_settings").loop&&l.slick("slickGoTo",0):l.slick("slickCurrentSlide")+r>d?l.setSlideTo(d):l.slick("slickNext"):i(this).hasClass("sow-carousel-previous")&&(s.data("carousel_settings").loop&&0==l.slick("slickCurrentSlide")?l.slick("slickGoTo",d):!s.data("carousel_settings").loop&&l.slick("slickCurrentSlide")<=r?l.slick("slickGoTo",1):l.slick("slickPrev")),o.dots&&"post"==s.data("widget")&&(s.find("li.slick-active").removeClass("slick-active"),s.find(".slick-dots li").eq(Math.ceil(s.find(".sow-carousel-items").slick("slickCurrentSlide")/r)).addClass("slick-active"))})),o.dots&&(s.data("variable_width")||s.data("carousel_settings").theme)){s.find(".slick-dots li").off("click.slick");var c=function(){e=s.find(".sow-carousel-items");var t=i(this).index(),o=e.slick("slickGetOption","slidesToScroll"),l=e.find(".sow-carousel-item").length,a=Math.ceil(e.outerWidth()/e.find(".sow-carousel-item").outerWidth(!0)),c=l-a;(t+a>=l?(e.slick("slickGoTo",c),$dots=i(this).parent(),$dots.find(".slick-active").removeClass("slick-active"),$dots.children().eq(t).addClass("slick-active")):("post"==s.data("widget")&&(t=Math.ceil(i(this).index()*o)),e.slick("slickGoTo",t)),"post"==s.data("widget"))&&(l>=s.data("item_count")||(e.slick("slickCurrentSlide")+a>=l-1||e.slick("slickCurrentSlide")+o>c)&&i(sowb).trigger("carousel_load_new_items",[s,e,!1]))};s.find(".slick-dots li").on("click touchend",c),i(sowb).on("carousel_posts_added",(function(){s.find(".slick-dots li").on("click touchend",c)}))}})),i(sowb).trigger("carousel_setup"),i(document).on("keydown",".sow-carousel-navigation a",(function(s){13!=s.keyCode&&32!=s.keyCode||(s.preventDefault(),i(this).trigger("click"))})),i(document).on("keyup",".sow-carousel-item",(function(s){if(13==s.keyCode&&i(this).find("h3 a")[0].click(),37==s.keyCode||39==s.keyCode){var e=i(this).parents(".sow-carousel-wrapper"),t=e.find(".sow-carousel-items"),o=t.find(".sow-carousel-item").length,l=i(this).data("slick-index"),a=o-(o===e.data("item_count")?0:1);if(37==s.keyCode)--l<0&&(l=a);else if(39==s.keyCode&&++l>=a){if(e.data("fetching"))return;e.parent().find(".sow-carousel-next").trigger("click",!0)}t.slick("slickGoTo",l,!0),e.find(".sow-carousel-item").prop("tabindex",-1),e.find('.sow-carousel-item[data-slick-index="'+l+'"]').trigger("focus").prop("tabindex",0)}}));var s=function(){i(".sow-carousel-wrapper").each((function(){var s=i(this),e=s.find(".sow-carousel-items.slick-initialized"),t=Math.ceil(e.outerWidth()/e.find(".sow-carousel-item").outerWidth(!0)),o=s.parent().parent().find(".sow-carousel-navigation");t>=s.data("item_count")?(o.hide(),e.slick("slickSetOption","touchMove",!1),e.slick("slickSetOption","draggable",!1)):o.not(":visible")&&(o.show(),e.slick("slickSetOption","touchMove",!0),e.slick("slickSetOption","draggable",!0));var l=s.data("responsive");window.matchMedia("(min-width: "+l.tablet_portrait_breakpoint+"px) and (max-width: "+l.tablet_landscape_breakpoint+"px) and (orientation: landscape)").matches&&(e.slick("slickSetOption","slidesToShow",l.tablet_landscape_slides_to_show),e.slick("slickSetOption","slidesToScroll",l.tablet_landscape_slides_to_scroll))})),i(".sow-carousel-item:first-of-type").prop("tabindex",0)};s(),i(window).on("resize load",s)},sowb.setupCarousel(),i(sowb).on("setup_widgets",sowb.setupCarousel)})),window.sowb=sowb;
readme.txt CHANGED
@@ -1,10 +1,10 @@
1
  === SiteOrigin Widgets Bundle ===
2
- Tags: widget, button, slider, hero, google maps, image, carousel, features, icons, price table, tinymce, social icons
3
  Requires at least: 4.2
4
  Tested up to: 5.9
5
  Requires PHP: 5.6.20
6
- Stable tag: 1.33.0
7
- Build time: 2022-04-23T20:30:21+02:00
8
  License: GPLv3 or later
9
  Contributors: gpriday, braam-genis, alexgso
10
  Donate link: https://siteorigin.com/downloads/premium/
@@ -105,6 +105,12 @@ The Widgets Bundle global interface is available at Plugins > SiteOrigin Widgets
105
 
106
  == Changelog ==
107
 
 
 
 
 
 
 
108
  = 1.33.0 - 23 April 2022 =
109
  * New Widget! Introducing the SiteOrigin Lottie Player Widget.
110
  * Carousel Widgets: Resolved a dot navigation miscalculation when multiple carousels present.
1
  === SiteOrigin Widgets Bundle ===
2
+ Tags: widget, button, slider, hero, google maps, image, carousel, lottie, features, icons, price table, tinymce, social icons
3
  Requires at least: 4.2
4
  Tested up to: 5.9
5
  Requires PHP: 5.6.20
6
+ Stable tag: 1.33.1
7
+ Build time: 2022-04-30T21:56:36+02:00
8
  License: GPLv3 or later
9
  Contributors: gpriday, braam-genis, alexgso
10
  Donate link: https://siteorigin.com/downloads/premium/
105
 
106
  == Changelog ==
107
 
108
+ = 1.33.1 - 30 April 2022 =
109
+ * Accordion and Tabs: Added support for the SiteOrigin Premium Anchor ID Addon.
110
+ * Anything Carousel: Resolved a `Previous Nav Arrow` error.
111
+ * Anything Carousel: Improved theme compatibility by preventing nav arrow container overflow hidden.
112
+ * Lottie Player: Fixed an error in the closing `</div>` tag.
113
+
114
  = 1.33.0 - 23 April 2022 =
115
  * New Widget! Introducing the SiteOrigin Lottie Player Widget.
116
  * Carousel Widgets: Resolved a dot navigation miscalculation when multiple carousels present.
so-widgets-bundle.php CHANGED
@@ -2,7 +2,7 @@
2
  /*
3
  Plugin Name: SiteOrigin Widgets Bundle
4
  Description: A highly customizable collection of widgets, ready to be used anywhere, neatly bundled into a single plugin.
5
- Version: 1.33.0
6
  Text Domain: so-widgets-bundle
7
  Domain Path: /lang
8
  Author: SiteOrigin
@@ -12,7 +12,7 @@ License: GPL3
12
  License URI: https://www.gnu.org/licenses/gpl-3.0.txt
13
  */
14
 
15
- define( 'SOW_BUNDLE_VERSION', '1.33.0' );
16
  define( 'SOW_BUNDLE_BASE_FILE', __FILE__ );
17
 
18
  // Allow JS suffix to be pre-set.
2
  /*
3
  Plugin Name: SiteOrigin Widgets Bundle
4
  Description: A highly customizable collection of widgets, ready to be used anywhere, neatly bundled into a single plugin.
5
+ Version: 1.33.1
6
  Text Domain: so-widgets-bundle
7
  Domain Path: /lang
8
  Author: SiteOrigin
12
  License URI: https://www.gnu.org/licenses/gpl-3.0.txt
13
  */
14
 
15
+ define( 'SOW_BUNDLE_VERSION', '1.33.1' );
16
  define( 'SOW_BUNDLE_BASE_FILE', __FILE__ );
17
 
18
  // Allow JS suffix to be pre-set.
widgets/accordion/js/accordion.js CHANGED
@@ -114,9 +114,11 @@ jQuery( function ( $ ) {
114
  } );
115
  }
116
  } );
117
-
118
- if ( $widget.data( 'useAnchorTags' ) ) {
 
119
  var timeoutId;
 
120
  updateHash = function () {
121
  if ( timeoutId ) {
122
  clearTimeout( timeoutId );
@@ -127,6 +129,10 @@ jQuery( function ( $ ) {
127
  var allOpenPanels = $( '.sow-accordion-panel-open' ).toArray();
128
  for ( var i = 0; i < allOpenPanels.length; i++ ) {
129
  var anchor = $( allOpenPanels[ i ] ).data( 'anchor' );
 
 
 
 
130
  if ( anchor ) {
131
  var $parentPanel = $( allOpenPanels[ i ] ).parents( '.sow-accordion-panel' );
132
  if ( ! $parentPanel.length || ( $parentPanel.length && $parentPanel.hasClass( 'sow-accordion-panel-open' ) ) ) {
@@ -149,9 +155,15 @@ jQuery( function ( $ ) {
149
  for ( var i = 0; i < panels.length; i++ ) {
150
  var panel = panels[ i ];
151
  var panelAnchor = $( panel ).data( 'anchor' );
152
- var panelOpen = anchors.some(function (anchor) {
 
 
 
 
 
153
  return decodeURI( panelAnchor ) === decodeURI( anchor );
154
  });
 
155
  if ( panelOpen ) {
156
  openPanel( panel, true, true );
157
  } else {
114
  } );
115
  }
116
  } );
117
+
118
+ if ( $widget.data( 'anchor-id' ) || $widget.data( 'use-anchor-tags' ) ) {
119
+ var anchorId = $widget.data( 'anchor-id' ) ? $widget.data( 'anchor-id' ) : false;
120
  var timeoutId;
121
+
122
  updateHash = function () {
123
  if ( timeoutId ) {
124
  clearTimeout( timeoutId );
129
  var allOpenPanels = $( '.sow-accordion-panel-open' ).toArray();
130
  for ( var i = 0; i < allOpenPanels.length; i++ ) {
131
  var anchor = $( allOpenPanels[ i ] ).data( 'anchor' );
132
+ if ( anchorId && anchorId != 1 ) {
133
+ anchor = anchorId + anchor;
134
+ }
135
+
136
  if ( anchor ) {
137
  var $parentPanel = $( allOpenPanels[ i ] ).parents( '.sow-accordion-panel' );
138
  if ( ! $parentPanel.length || ( $parentPanel.length && $parentPanel.hasClass( 'sow-accordion-panel-open' ) ) ) {
155
  for ( var i = 0; i < panels.length; i++ ) {
156
  var panel = panels[ i ];
157
  var panelAnchor = $( panel ).data( 'anchor' );
158
+ var anchorId = $widget.data( 'anchor-id' ) ? $widget.data( 'anchor-id' ) : false;
159
+
160
+ if ( anchorId && anchorId != 1 ) {
161
+ panelAnchor = $widget.data( 'anchor-id' ) + panelAnchor;
162
+ }
163
+ var panelOpen = anchors.some( function ( anchor ) {
164
  return decodeURI( panelAnchor ) === decodeURI( anchor );
165
  });
166
+
167
  if ( panelOpen ) {
168
  openPanel( panel, true, true );
169
  } else {
widgets/accordion/js/accordion.min.js CHANGED
@@ -1 +1 @@
1
- var sowb=window.sowb||{};jQuery((function(o){sowb.setupAccordion=function(){o(".sow-accordion").each((function(n,e){var a=o(this).closest(".so-widget-sow-accordion");if(a.data("initialized"))return o(this);var i=o(e).find("> .sow-accordion-panel"),t=i.filter(".sow-accordion-panel-open").toArray(),c=function(){},s=function(n,e){var a=sowAccordion.scrollto_offset?sowAccordion.scrollto_offset:80,i=n.offset().top-a;e?o("body,html").animate({scrollTop:i},200):window.scrollTo(0,i)},r=function(n,e,a){var i=o(n);if(!i.is(".sow-accordion-panel-open")){i.find("> .sow-accordion-panel-content").slideDown({start:function(){o(window).trigger("resize"),o(sowb).trigger("setup_widgets")},complete:function(){a&&sowAccordion.scrollto_after_change&&(i.offset().top<window.scrollY||i.offset().top+i.height()>window.scrollY)&&s(i,!0),o(this).trigger("show")}}),i.find("> .sow-accordion-panel-header-container > .sow-accordion-panel-header").attr("aria-expanded",!0),i.addClass("sow-accordion-panel-open"),t.push(n);var d=o(n).parents(".sow-accordion-panel");d.length&&!d.hasClass("sow-accordion-panel-open")&&r(d.get(0),!0),e||c()}},d=function(n,e){var a=o(n);a.is(".sow-accordion-panel-open")&&(a.find("> .sow-accordion-panel-content").slideUp((function(){o(this).trigger("hide")})),a.find("> .sow-accordion-panel-header-container > .sow-accordion-panel-header").attr("aria-expanded",!1),a.removeClass("sow-accordion-panel-open"),t.splice(t.indexOf(n),1),e||c())};if(i.find("> .sow-accordion-panel-header-container > .sow-accordion-panel-header").on("click keydown",(function(n){if("keydown"==n.type){if(13!==n.keyCode&&32!==n.keyCode)return;n.preventDefault()}var e=o(this),i=a.data("maxOpenPanels"),c=e.closest(".sow-accordion-panel");if(c.is(".sow-accordion-panel-open")?d(c.get(0)):r(c.get(0),!1,!0),!isNaN(i)&&i>0&&t.length>i){var s=0;o.each(t.reverse(),(function(o,n){s!==i?s++:d(t[o])}))}})),a.data("useAnchorTags")){var l;c=function(){l&&clearTimeout(l),l=setTimeout((function(){for(var n=[],e=o(".sow-accordion-panel-open").toArray(),a=0;a<e.length;a++){var i=o(e[a]).data("anchor");if(i){var t=o(e[a]).parents(".sow-accordion-panel");(!t.length||t.length&&t.hasClass("sow-accordion-panel-open"))&&(n[a]=i)}}n&&n.length?window.location.hash=n.join(","):window.location.hash&&window.history.pushState("",document.title,window.location.pathname+window.location.search)}),100)};var w=function(){for(var n=i.toArray(),e=window.location.hash.substring(1).split(","),a=0;a<n.length;a++){var t=n[a],c=o(t).data("anchor");e.some((function(o){return decodeURI(c)===decodeURI(o)}))?r(t,!0,!0):d(t,!0)}};o(window).on("hashchange",w),window.location.hash?w():c();var p=a.data("initialScrollPanel");if(window.location.hash&&t.length)setTimeout((function(){s(o(t[0]))}),500);else if(p>0){var h=p>i.length?i.last():i.eq(p-1);setTimeout((function(){s(h)}),500)}}a.data("initialized",!0)}))},sowb.setupAccordion(),o(sowb).on("setup_widgets",sowb.setupAccordion)})),window.sowb=sowb;
1
+ var sowb=window.sowb||{};jQuery((function(o){sowb.setupAccordion=function(){o(".sow-accordion").each((function(n,a){var e=o(this).closest(".so-widget-sow-accordion");if(e.data("initialized"))return o(this);var i=o(a).find("> .sow-accordion-panel"),t=i.filter(".sow-accordion-panel-open").toArray(),c=function(){},r=function(n,a){var e=sowAccordion.scrollto_offset?sowAccordion.scrollto_offset:80,i=n.offset().top-e;a?o("body,html").animate({scrollTop:i},200):window.scrollTo(0,i)},s=function(n,a,e){var i=o(n);if(!i.is(".sow-accordion-panel-open")){i.find("> .sow-accordion-panel-content").slideDown({start:function(){o(window).trigger("resize"),o(sowb).trigger("setup_widgets")},complete:function(){e&&sowAccordion.scrollto_after_change&&(i.offset().top<window.scrollY||i.offset().top+i.height()>window.scrollY)&&r(i,!0),o(this).trigger("show")}}),i.find("> .sow-accordion-panel-header-container > .sow-accordion-panel-header").attr("aria-expanded",!0),i.addClass("sow-accordion-panel-open"),t.push(n);var d=o(n).parents(".sow-accordion-panel");d.length&&!d.hasClass("sow-accordion-panel-open")&&s(d.get(0),!0),a||c()}},d=function(n,a){var e=o(n);e.is(".sow-accordion-panel-open")&&(e.find("> .sow-accordion-panel-content").slideUp((function(){o(this).trigger("hide")})),e.find("> .sow-accordion-panel-header-container > .sow-accordion-panel-header").attr("aria-expanded",!1),e.removeClass("sow-accordion-panel-open"),t.splice(t.indexOf(n),1),a||c())};if(i.find("> .sow-accordion-panel-header-container > .sow-accordion-panel-header").on("click keydown",(function(n){if("keydown"==n.type){if(13!==n.keyCode&&32!==n.keyCode)return;n.preventDefault()}var a=o(this),i=e.data("maxOpenPanels"),c=a.closest(".sow-accordion-panel");if(c.is(".sow-accordion-panel-open")?d(c.get(0)):s(c.get(0),!1,!0),!isNaN(i)&&i>0&&t.length>i){var r=0;o.each(t.reverse(),(function(o,n){r!==i?r++:d(t[o])}))}})),e.data("anchor-id")||e.data("use-anchor-tags")){var l,w=!!e.data("anchor-id")&&e.data("anchor-id");c=function(){l&&clearTimeout(l),l=setTimeout((function(){for(var n=[],a=o(".sow-accordion-panel-open").toArray(),e=0;e<a.length;e++){var i=o(a[e]).data("anchor");if(w&&1!=w&&(i=w+i),i){var t=o(a[e]).parents(".sow-accordion-panel");(!t.length||t.length&&t.hasClass("sow-accordion-panel-open"))&&(n[e]=i)}}n&&n.length?window.location.hash=n.join(","):window.location.hash&&window.history.pushState("",document.title,window.location.pathname+window.location.search)}),100)};var h=function(){for(var n=i.toArray(),a=window.location.hash.substring(1).split(","),t=0;t<n.length;t++){var c=n[t],r=o(c).data("anchor"),l=!!e.data("anchor-id")&&e.data("anchor-id");l&&1!=l&&(r=e.data("anchor-id")+r),a.some((function(o){return decodeURI(r)===decodeURI(o)}))?s(c,!0,!0):d(c,!0)}};o(window).on("hashchange",h),window.location.hash?h():c();var p=e.data("initialScrollPanel");if(window.location.hash&&t.length)setTimeout((function(){r(o(t[0]))}),500);else if(p>0){var f=p>i.length?i.last():i.eq(p-1);setTimeout((function(){r(f)}),500)}}e.data("initialized",!0)}))},sowb.setupAccordion(),o(sowb).on("setup_widgets",sowb.setupAccordion)})),window.sowb=sowb;
widgets/anything-carousel/styles/base.less CHANGED
@@ -35,20 +35,27 @@
35
  @navigation_dots_mobile: default;
36
 
37
  .sow-carousel-container {
38
- a.sow-carousel-next {
39
  margin-left: @navigation_arrow_margin;
 
40
 
41
- &:after {
42
- content: "\e601";
43
- }
44
  }
45
 
46
- a.sow-carousel-previous {
47
  margin-right: @navigation_arrow_margin;
 
48
 
49
- &:before {
50
- content: "\e600";
51
- }
 
 
 
 
 
 
52
  }
53
 
54
  a.sow-carousel-previous,
@@ -61,7 +68,6 @@
61
  font-size: 14px;
62
  height: 32px;
63
  justify-content: center;
64
- min-width: 32px; // FF may ignore width due to the parent being a flexbox. It won't ignore min-width.
65
  width: 32px;
66
 
67
  &:focus,
35
  @navigation_dots_mobile: default;
36
 
37
  .sow-carousel-container {
38
+ .sow-carousel-navigation-next {
39
  margin-left: @navigation_arrow_margin;
40
+ }
41
 
42
+ a.sow-carousel-next:after {
43
+ content: "\e601";
 
44
  }
45
 
46
+ .sow-carousel-navigation-prev {
47
  margin-right: @navigation_arrow_margin;
48
+ }
49
 
50
+ a.sow-carousel-previous:before {
51
+ content: "\e600";
52
+ }
53
+
54
+ .sow-carousel-navigation {
55
+ margin-top: 0;
56
+ margin-bottom: 0;
57
+ min-width: 34px; // FF may ignore width due to the parent being a flexbox. It won't ignore min-width.
58
+ width: 34px;
59
  }
60
 
61
  a.sow-carousel-previous,
68
  font-size: 14px;
69
  height: 32px;
70
  justify-content: center;
 
71
  width: 32px;
72
 
73
  &:focus,
widgets/lottie-player/tpl/default.php CHANGED
@@ -32,4 +32,4 @@ if ( empty( $file ) ) {
32
  src="<?php echo sow_esc_url( $file ); ?>"
33
  >
34
  </lottie-player>
35
- <div>
32
  src="<?php echo sow_esc_url( $file ); ?>"
33
  >
34
  </lottie-player>
35
+ </div>
widgets/tabs/js/tabs.js CHANGED
@@ -11,8 +11,7 @@ jQuery( function ( $ ) {
11
  if ( $widget.data( 'initialized' ) ) {
12
  return $( this );
13
  }
14
- var useAnchorTags = $widget.data( 'useAnchorTags' );
15
-
16
  var $tabPanelsContainer = $this.find( '> .sow-tabs-panel-container' );
17
 
18
  var $tabs = $this.find( '> .sow-tabs-tab-container > .sow-tabs-tab' );
@@ -99,9 +98,17 @@ jQuery( function ( $ ) {
99
  }
100
  );
101
  $tab.addClass( 'sow-tabs-tab-selected' );
102
-
103
- if ( useAnchorTags && !preventHashChange ) {
104
- window.location.hash = $tab.data( 'anchor' );
 
 
 
 
 
 
 
 
105
  }
106
  }
107
  };
@@ -144,13 +151,17 @@ jQuery( function ( $ ) {
144
  selectTab( $newTab.get(0) );
145
  } );
146
 
147
- if ( useAnchorTags ) {
148
  var updateSelectedTab = function () {
149
  if ( window.location.hash ) {
150
  var anchors = window.location.hash.substring(1).split( ',' );
151
  anchors.forEach( function ( anchor ) {
152
  var tab = $tabs.filter( function ( index, element ) {
153
- return decodeURI( anchor ) === decodeURI( $( element ).data( 'anchor' ) );
 
 
 
 
154
  } );
155
  if ( tab.length > 0 ) {
156
  selectTab( tab, true );
11
  if ( $widget.data( 'initialized' ) ) {
12
  return $( this );
13
  }
14
+ var anchorId = $widget.data( 'anchor-id' ) ? $widget.data( 'anchor-id' ) : false;
 
15
  var $tabPanelsContainer = $this.find( '> .sow-tabs-panel-container' );
16
 
17
  var $tabs = $this.find( '> .sow-tabs-tab-container > .sow-tabs-tab' );
98
  }
99
  );
100
  $tab.addClass( 'sow-tabs-tab-selected' );
101
+
102
+ if ( ! preventHashChange ) {
103
+ if ( ! anchorId ) {
104
+ window.location.hash = $tab.data( 'anchor' );
105
+ } else {
106
+ var anchor = $tab.data( 'anchor' );
107
+ if ( $widget.data( 'anchor-id' ) != 1 ) {
108
+ anchor = $widget.data( 'anchor-id' ) + '-' + anchor;
109
+ }
110
+ window.location.hash = anchor;
111
+ }
112
  }
113
  }
114
  };
151
  selectTab( $newTab.get(0) );
152
  } );
153
 
154
+ if ( $widget.data( 'anchor-id' ) || $widget.data( 'use-anchor-tags' ) ) {
155
  var updateSelectedTab = function () {
156
  if ( window.location.hash ) {
157
  var anchors = window.location.hash.substring(1).split( ',' );
158
  anchors.forEach( function ( anchor ) {
159
  var tab = $tabs.filter( function ( index, element ) {
160
+ var tabAnchor = $( element ).data( 'anchor' );
161
+ if ( $widget.data( 'anchor-id' ) && $widget.data( 'anchor-id' ) != 1 ) {
162
+ tabAnchor = $widget.data( 'anchor-id' ) + '-' + tabAnchor;
163
+ }
164
+ return decodeURI( anchor ) === decodeURI( tabAnchor );
165
  } );
166
  if ( tab.length > 0 ) {
167
  selectTab( tab, true );
widgets/tabs/js/tabs.min.js CHANGED
@@ -1 +1 @@
1
- var sowb=window.sowb||{};jQuery((function(t){sowb.setupTabs=function(){t(".sow-tabs").each((function(e,o){var s=t(o),a=s.closest(".so-widget-sow-tabs");if(a.data("initialized"))return t(this);var i,n=a.data("useAnchorTags"),r=s.find("> .sow-tabs-panel-container"),d=s.find("> .sow-tabs-tab-container > .sow-tabs-tab"),c=s.find(".sow-tabs-tab-selected").index(),w=r.find("> .sow-tabs-panel");w.not(":eq("+c+")").hide();var l=function(e){var o=sowTabs.scrollto_offset?sowTabs.scrollto_offset:90,s=a.offset().top-o;e?t("body,html").animate({scrollTop:s},200):window.scrollTo(0,s)},f=function(t){return sowTabs.scrollto_after_change&&(t.offset().top<window.scrollY||t.offset().top+t.height()>window.scrollY)},b=function(e,o){var s=t(e);if(s.is(".sow-tabs-tab-selected"))return f(s)&&l(!0),!0;var a=s.index();if(a>-1){i&&i.finish();var r=d.filter(".sow-tabs-tab-selected");r.removeClass("sow-tabs-tab-selected");var c=r.index(),b=w.eq(c).children(),h=w.eq(a).children();r.attr("tabindex",-1),r.attr("aria-selected",!1),b.attr("tabindex",-1),s.attr("tabindex",0),s.attr("aria-selected",!0),h.attr("tabindex",0),b.attr("aria-hidden","true"),i=w.eq(c).fadeOut("fast",(function(){t(this).trigger("hide"),h.removeAttr("aria-hidden"),w.eq(a).fadeIn({duration:"fast",start:function(){t(window).trigger("resize"),t(sowb).trigger("setup_widgets")},complete:function(){t(this).trigger("show"),(o||f(s))&&l(!0)}})})),s.addClass("sow-tabs-tab-selected"),n&&!o&&(window.location.hash=s.data("anchor"))}};if(d.on("click",(function(){b(this)})),d.on("keyup",(function(e){var o,s=t(this);37!==e.keyCode&&39!==e.keyCode||(37===e.keyCode&&(o=s.prev().get(0)?s.prev():s.siblings().last()),39===e.keyCode&&(o=s.next().get(0)?s.next():s.siblings().first()),s!==o&&(o.trigger("focus"),b(o.get(0))))})),n){var h=function(){window.location.hash&&window.location.hash.substring(1).split(",").forEach((function(e){var o=d.filter((function(o,s){return decodeURI(e)===decodeURI(t(s).data("anchor"))}));o.length>0&&b(o,!0)}))};t(window).on("hashchange",h),window.location.hash&&h()}a.data("initialized",!0)}))},sowb.setupTabs(),t(sowb).on("setup_widgets",sowb.setupTabs)})),window.sowb=sowb;
1
+ var sowb=window.sowb||{};jQuery((function(t){sowb.setupTabs=function(){t(".sow-tabs").each((function(a,o){var e=t(o),i=e.closest(".so-widget-sow-tabs");if(i.data("initialized"))return t(this);var s,n=!!i.data("anchor-id")&&i.data("anchor-id"),r=e.find("> .sow-tabs-panel-container"),d=e.find("> .sow-tabs-tab-container > .sow-tabs-tab"),c=e.find(".sow-tabs-tab-selected").index(),w=r.find("> .sow-tabs-panel");w.not(":eq("+c+")").hide();var l=function(a){var o=sowTabs.scrollto_offset?sowTabs.scrollto_offset:90,e=i.offset().top-o;a?t("body,html").animate({scrollTop:e},200):window.scrollTo(0,e)},f=function(t){return sowTabs.scrollto_after_change&&(t.offset().top<window.scrollY||t.offset().top+t.height()>window.scrollY)},h=function(a,o){var e=t(a);if(e.is(".sow-tabs-tab-selected"))return f(e)&&l(!0),!0;var r=e.index();if(r>-1){s&&s.finish();var c=d.filter(".sow-tabs-tab-selected");c.removeClass("sow-tabs-tab-selected");var h=c.index(),b=w.eq(h).children(),u=w.eq(r).children();if(c.attr("tabindex",-1),c.attr("aria-selected",!1),b.attr("tabindex",-1),e.attr("tabindex",0),e.attr("aria-selected",!0),u.attr("tabindex",0),b.attr("aria-hidden","true"),s=w.eq(h).fadeOut("fast",(function(){t(this).trigger("hide"),u.removeAttr("aria-hidden"),w.eq(r).fadeIn({duration:"fast",start:function(){t(window).trigger("resize"),t(sowb).trigger("setup_widgets")},complete:function(){t(this).trigger("show"),(o||f(e))&&l(!0)}})})),e.addClass("sow-tabs-tab-selected"),!o)if(n){var g=e.data("anchor");1!=i.data("anchor-id")&&(g=i.data("anchor-id")+"-"+g),window.location.hash=g}else window.location.hash=e.data("anchor")}};if(d.on("click",(function(){h(this)})),d.on("keyup",(function(a){var o,e=t(this);37!==a.keyCode&&39!==a.keyCode||(37===a.keyCode&&(o=e.prev().get(0)?e.prev():e.siblings().last()),39===a.keyCode&&(o=e.next().get(0)?e.next():e.siblings().first()),e!==o&&(o.trigger("focus"),h(o.get(0))))})),i.data("anchor-id")||i.data("use-anchor-tags")){var b=function(){window.location.hash&&window.location.hash.substring(1).split(",").forEach((function(a){var o=d.filter((function(o,e){var s=t(e).data("anchor");return i.data("anchor-id")&&1!=i.data("anchor-id")&&(s=i.data("anchor-id")+"-"+s),decodeURI(a)===decodeURI(s)}));o.length>0&&h(o,!0)}))};t(window).on("hashchange",b),window.location.hash&&b()}i.data("initialized",!0)}))},sowb.setupTabs(),t(sowb).on("setup_widgets",sowb.setupTabs)})),window.sowb=sowb;