Ultimate Responsive Image Slider Plugin - Version 2.8

Version Description

Download this release

Release Info

Developer weblizar
Plugin Icon 128x128 Ultimate Responsive Image Slider Plugin
Version 2.8
Comparing to
See all releases

Code changes from version 2.7 to 2.8

css/slider-pro.css CHANGED
@@ -1,5 +1,5 @@
1
  /*!
2
- * - v1.1.0
3
  * Homepage: http://bqworks.com/slider-pro/
4
  * Author: bqworks
5
  * Author URL: http://bqworks.com/
@@ -9,7 +9,8 @@
9
  .slider-pro {
10
  position: relative;
11
  margin: 0 auto;
12
- margin-bottom: 10px;
 
13
  }
14
 
15
  .sp-slides-container {
@@ -745,8 +746,8 @@ a.sp-video:after {
745
  --------------------------------------------------*/
746
  .slider-pro img.sp-image,
747
  .slider-pro img.sp-thumbnail {
748
- max-width: none !important;
749
- max-height: none !important;
750
  border: none !important;
751
  border-radius: 0 !important;
752
  padding: 0 !important;
@@ -777,7 +778,7 @@ a.sp-video:after {
777
  }
778
 
779
  .slider-pro p.sp-layer {
780
- font-size: 14px ;
781
  line-height: 1.4;
782
  margin: 0;
783
  }
@@ -820,13 +821,4 @@ a.sp-video:after {
820
 
821
  .slider-pro img.sp-layer {
822
  border: none;
823
- }
824
-
825
- .uris-slider-title{
826
- font-weight: bolder !important;
827
- padding-bottom: 5px !important;
828
- border-bottom: 2px solid #f2f2f2 !important;
829
- text-align: center !important;
830
- margin-bottom: 20px !important;
831
- font-size: 18px !important;
832
  }
1
  /*!
2
+ * - v1.2.4
3
  * Homepage: http://bqworks.com/slider-pro/
4
  * Author: bqworks
5
  * Author URL: http://bqworks.com/
9
  .slider-pro {
10
  position: relative;
11
  margin: 0 auto;
12
+ -moz-box-sizing: content-box;
13
+ box-sizing: content-box;
14
  }
15
 
16
  .sp-slides-container {
746
  --------------------------------------------------*/
747
  .slider-pro img.sp-image,
748
  .slider-pro img.sp-thumbnail {
749
+ max-width: none;
750
+ max-height: none;
751
  border: none !important;
752
  border-radius: 0 !important;
753
  padding: 0 !important;
778
  }
779
 
780
  .slider-pro p.sp-layer {
781
+ font-size: 14px;
782
  line-height: 1.4;
783
  margin: 0;
784
  }
821
 
822
  .slider-pro img.sp-layer {
823
  border: none;
 
 
 
 
 
 
 
 
 
824
  }
get-uris-pro.php CHANGED
@@ -20,7 +20,6 @@
20
  </div>
21
 
22
  </div>
23
-
24
  </div>
25
  <div class="plan-name" style="padding-top:40px; text-align: center;display:block;width:100%;overflow:hidden">
26
 
20
  </div>
21
 
22
  </div>
 
23
  </div>
24
  <div class="plan-name" style="padding-top:40px; text-align: center;display:block;width:100%;overflow:hidden">
25
 
help_and_support.php CHANGED
@@ -6,7 +6,7 @@
6
  <hr>
7
  <div class="purchase_btn_div" style="margin-top:20px; margin-left:30px;">
8
  <h2 style="font-weight: bold;font-size: 24px;padding-top: 30px;">View Support Docs or Open a Ticket</h2>
9
- <a style= "margin-right:10px; margin-left:40px; margin-top:30px; text-decoration:none;" href="https://wordpress.org/support/plugin/ultimate-responsive-image-slider" target="_new" class="btn btn-primary btn-lg"><?php _e('View Support Docs or Open a Ticket','')?></a>
10
  </div>
11
  <hr>
12
 
@@ -49,16 +49,14 @@
49
  <hr>
50
  <div style="margin-top:30px;margin-left:30px;">
51
  <h2 style="font-weight: bold;font-size: 28px;padding-top:10px;">Language Contribution </h2>
52
- <h6 style="font-size: 18px;padding-top: 20px;padding-bottom: 10px;line-height:30px;margin-left:30px;">Translate this plugin into your language <br> Question : How to convert Plguin into My Language ? <br> Answer : Contact as to lizarweb@gmail.com for translate this plugin into your language.</h6>
53
-
54
  </div>
55
  <hr>
56
  <div style="margin-top:30px;margin-left:30px;">
57
- <h2 style="font-weight: bold;font-size: 28px;padding-top:10px;">Change Old Server Image URL</h2>
58
  <form action="" method="post">
59
- <input type="submit" value="Change image URL" name= "urispchangeurl" style= "margin-top:10px; margin-right:10px; margin-left:30px; background:#31B0D5; text-decoration:none;" class="btn btn-primary btn-lg">
60
-
61
- <h6 style="font-size: 22px;padding-top: 10px;padding-bottom: 10px;line-height:40px"><b>Note:</b> Use this option after import <b>Ultimate Responsive Image Slider Settings</b> to change old server image url to new server image url.</h6>
62
  </form>
63
  </div>
64
  </div>
6
  <hr>
7
  <div class="purchase_btn_div" style="margin-top:20px; margin-left:30px;">
8
  <h2 style="font-weight: bold;font-size: 24px;padding-top: 30px;">View Support Docs or Open a Ticket</h2>
9
+ <a style= "margin-right:10px; margin-left:40px; margin-top:30px; text-decoration:none;" href="https://wordpress.org/support/plugin/ultimate-responsive-image-slider" target="_new" class="btn btn-primary btn-lg">View Support Docs or Open a Ticket</a>
10
  </div>
11
  <hr>
12
 
49
  <hr>
50
  <div style="margin-top:30px;margin-left:30px;">
51
  <h2 style="font-weight: bold;font-size: 28px;padding-top:10px;">Language Contribution </h2>
52
+ <h6 style="font-size: 18px;padding-top: 20px;padding-bottom: 10px;line-height:30px; margin-left:30px;">Translate this plugin into your language <br> <strong>Question :</strong> How to convert Plguin into My Language ? <br> <strong>Answer :</strong> Contact as to lizarweb@gmail.com for translate this plugin into your language. We will guide you in better manner.</h6>
 
53
  </div>
54
  <hr>
55
  <div style="margin-top:30px;margin-left:30px;">
56
+ <h2 style="font-weight: bold;font-size: 28px;padding-top:10px;">Change Old Server URLs</h2>
57
  <form action="" method="post">
58
+ <input type="submit" value="Change All URLs" name= "urispchangeurl" style= "margin-top:10px; margin-right:10px; margin-left:30px; background:#31B0D5; text-decoration:none;" class="btn btn-primary btn-lg">
59
+ <h6 style="font-size: 22px;padding-top: 10px;padding-bottom: 10px;line-height:40px"><b>Note:</b> Use this option after successfully imported <b>Ultimate Responsive Image Slider</b> Plugin and Uploads directory from old server to new server.</h6>
 
60
  </form>
61
  </div>
62
  </div>
img/Thumbs.db ADDED
Binary file
img/desc-bg-color.jpg ADDED
Binary file
img/desc-color.jpg ADDED
Binary file
img/navigation-color.jpg ADDED
Binary file
img/slide-distance.jpg ADDED
Binary file
img/title-bg-color.jpg ADDED
Binary file
img/title-color.jpg ADDED
Binary file
js/jquery.sliderPro.js CHANGED
@@ -1,2167 +1,5927 @@
1
  /*!
2
- * - v1.1.0
3
- * Homepage: http://bqworks.com/slider-pro/
4
- * Author: bqworks
5
- * Author URL: http://bqworks.com/
6
- */
7
- ! function(a, b) {
8
- "use strict";
9
- b.SliderPro = {
10
- modules: [],
11
- addModule: function(a, c) {
12
- this.modules.push(a), b.extend(d.prototype, c)
13
- }
14
- };
15
- var c = b.SliderPro.namespace = "SliderPro",
16
- d = function(a, c) {
17
- this.instance = a, this.$slider = b(this.instance), this.$slides = null, this.$slidesMask = null, this.$slidesContainer = null, this.slides = [], this.slidesOrder = [], this.options = c, this.settings = {}, this.originalSettings = {}, this.originalGotoSlide = null, this.selectedSlideIndex = 0, this.previousSlideIndex = 0, this.middleSlidePosition = 0, this.supportedAnimation = null, this.vendorPrefix = null, this.transitionEvent = null, this.positionProperty = null, this.isIE = null, this.slidesPosition = 0, this.slideWidth = 0, this.slideHeight = 0, this.slideSize = 0, this.previousSlideWidth = 0, this.previousSlideHeight = 0, this.previousWindowWidth = 0, this.previousWindowHeight = 0, this.visibleOffset = 0, this.allowResize = !0, this.uniqueId = (new Date).valueOf(), this.breakpoints = [], this.currentBreakpoint = -1, this.shuffledIndexes = [], this._init()
18
- };
19
- d.prototype = {
20
- _init: function() {
21
- var d = this;
22
- this.supportedAnimation = f.getSupportedAnimation(), this.vendorPrefix = f.getVendorPrefix(), this.transitionEvent = f.getTransitionEvent(), this.isIE = f.checkIE(), this.$slider.removeClass("sp-no-js"), a.navigator.userAgent.match(/(iPad|iPhone|iPod)/g) && this.$slider.addClass("ios");
23
- var e = /(msie) ([\w.]+)/,
24
- g = e.exec(a.navigator.userAgent.toLowerCase());
25
- this.isIE && this.$slider.addClass("ie"), null !== g && this.$slider.addClass("ie" + parseInt(g[2], 10)), this.$slidesContainer = b('<div class="sp-slides-container"></div>').appendTo(this.$slider), this.$slidesMask = b('<div class="sp-mask"></div>').appendTo(this.$slidesContainer), this.$slides = this.$slider.find(".sp-slides").appendTo(this.$slidesMask), this.$slider.find(".sp-slide").appendTo(this.$slides);
26
- var h = b.SliderPro.modules;
27
- if ("undefined" != typeof h)
28
- for (var i = 0; i < h.length; i++) {
29
- var j = h[i].substring(0, 1).toLowerCase() + h[i].substring(1) + "Defaults";
30
- "undefined" != typeof this[j] && b.extend(this.defaults, this[j])
31
- }
32
- if (this.settings = b.extend({}, this.defaults, this.options), "undefined" != typeof h)
33
- for (var k = 0; k < h.length; k++) "undefined" != typeof this["init" + h[k]] && this["init" + h[k]]();
34
- if (this.originalSettings = b.extend({}, this.settings), this.originalGotoSlide = this.gotoSlide, null !== this.settings.breakpoints) {
35
- for (var l in this.settings.breakpoints) this.breakpoints.push({
36
- size: parseInt(l, 10),
37
- properties: this.settings.breakpoints[l]
38
- });
39
- this.breakpoints = this.breakpoints.sort(function(a, b) {
40
- return a.size >= b.size ? 1 : -1
41
- })
42
- }
43
- if (this.selectedSlideIndex = this.settings.startSlide, this.settings.shuffle === !0) {
44
- var m = this.$slides.find(".sp-slide"),
45
- n = [];
46
- m.each(function(a) {
47
- d.shuffledIndexes.push(a)
48
- });
49
- for (var o = this.shuffledIndexes.length - 1; o > 0; o--) {
50
- var p = Math.floor(Math.random() * (o + 1)),
51
- q = this.shuffledIndexes[o];
52
- this.shuffledIndexes[o] = this.shuffledIndexes[p], this.shuffledIndexes[p] = q
53
- }
54
- b.each(this.shuffledIndexes, function(a, b) {
55
- n.push(m[b])
56
- }), this.$slides.empty().append(n)
57
- }
58
- b(a).on("resize." + this.uniqueId + "." + c, function() {
59
- var c = b(a).width(),
60
- e = b(a).height();
61
- d.allowResize === !1 || d.previousWindowWidth === c && d.previousWindowHeight === e || (d.previousWindowWidth = c, d.previousWindowHeight = e, d.allowResize = !1, setTimeout(function() {
62
- d.resize(), d.allowResize = !0
63
- }, 200))
64
- }), this.on("update." + c, function() {
65
- d.previousSlideWidth = 0, d.resize()
66
- }), this.update(), this.trigger({
67
- type: "init"
68
- }), b.isFunction(this.settings.init) && this.settings.init.call(this, {
69
- type: "init"
70
- })
71
- },
72
- update: function() {
73
- var a = this;
74
- "horizontal" === this.settings.orientation ? (this.$slider.removeClass("sp-vertical").addClass("sp-horizontal"), this.$slider.css({
75
- height: "",
76
- "max-height": ""
77
- }), this.$slides.find(".sp-slide").css("top", "")) : "vertical" === this.settings.orientation && (this.$slider.removeClass("sp-horizontal").addClass("sp-vertical"), this.$slides.find(".sp-slide").css("left", "")), this.positionProperty = "horizontal" === this.settings.orientation ? "left" : "top", this.gotoSlide = this.originalGotoSlide;
78
- for (var c = this.slides.length - 1; c >= 0; c--)
79
- if (0 === this.$slider.find('.sp-slide[data-index="' + c + '"]').length) {
80
- var d = this.slides[c];
81
- d.destroy(), this.slides.splice(c, 1)
82
- }
83
- this.slidesOrder.length = 0, this.$slider.find(".sp-slide").each(function(c) {
84
- var d = b(this);
85
- "undefined" == typeof d.attr("data-init") ? a._createSlide(c, d) : a.slides[c].setIndex(c), a.slidesOrder.push(c)
86
- }), this.middleSlidePosition = parseInt((a.slidesOrder.length - 1) / 2, 10), this.settings.loop === !0 && this._updateSlidesOrder(), this.trigger({
87
- type: "update"
88
- }), b.isFunction(this.settings.update) && this.settings.update.call(this, {
89
- type: "update"
90
- })
91
- },
92
- _createSlide: function(a, c) {
93
- var d = new e(b(c), a, this.settings);
94
- this.slides.splice(a, 0, d)
95
- },
96
- _updateSlidesOrder: function() {
97
- var a, c, d = b.inArray(this.selectedSlideIndex, this.slidesOrder) - this.middleSlidePosition;
98
- if (0 > d)
99
- for (a = this.slidesOrder.splice(d, Math.abs(d)), c = a.length - 1; c >= 0; c--) this.slidesOrder.unshift(a[c]);
100
- else if (d > 0)
101
- for (a = this.slidesOrder.splice(0, d), c = 0; c <= a.length - 1; c++) this.slidesOrder.push(a[c])
102
- },
103
- _updateSlidesPosition: function() {
104
- for (var a = parseInt(this.$slides.find(".sp-slide").eq(this.selectedSlideIndex).css(this.positionProperty), 10), b = 0; b < this.slidesOrder.length; b++) {
105
- var c = this.$slides.find(".sp-slide").eq(this.slidesOrder[b]);
106
- c.css(this.positionProperty, a + (b - this.middleSlidePosition) * (this.slideSize + this.settings.slideDistance))
107
- }
108
- },
109
- _resetSlidesPosition: function() {
110
- for (var a = 0; a < this.slidesOrder.length; a++) {
111
- var b = this.$slides.find(".sp-slide").eq(this.slidesOrder[a]);
112
- b.css(this.positionProperty, a * (this.slideSize + this.settings.slideDistance))
113
- }
114
- var c = -parseInt(this.$slides.find(".sp-slide").eq(this.selectedSlideIndex).css(this.positionProperty), 10) + this.visibleOffset;
115
- this._moveTo(c, !0)
116
- },
117
- resize: function() {
118
- var c = this;
119
- if (null !== this.settings.breakpoints && this.breakpoints.length > 0)
120
- if (b(a).width() > this.breakpoints[this.breakpoints.length - 1].size && -1 !== this.currentBreakpoint) this.currentBreakpoint = -1, this._setProperties(this.originalSettings, !1);
121
- else
122
- for (var d = 0, e = this.breakpoints.length; e > d; d++)
123
- if (b(a).width() <= this.breakpoints[d].size) {
124
- if (this.currentBreakpoint !== this.breakpoints[d].size) {
125
- var f = {
126
- type: "breakpointReach",
127
- size: this.breakpoints[d].size,
128
- settings: this.breakpoints[d].properties
129
- };
130
- this.trigger(f), b.isFunction(this.settings.breakpointReach) && this.settings.breakpointReach.call(this, f), this.currentBreakpoint = this.breakpoints[d].size;
131
- var g = b.extend({}, this.originalSettings, this.breakpoints[d].properties);
132
- return void this._setProperties(g, !1)
133
- }
134
- break
135
- }
136
- this.settings.responsive === !0 ? "fullWidth" !== this.settings.forceSize && "fullWindow" !== this.settings.forceSize || "auto" !== this.settings.visibleSize && ("auto" === this.settings.visibleSize || "vertical" !== this.settings.orientation) ? this.$slider.css({
137
- width: "100%",
138
- "max-width": this.settings.width,
139
- marginLeft: ""
140
- }) : (this.$slider.css("margin", 0), this.$slider.css({
141
- width: b(a).width(),
142
- "max-width": "",
143
- marginLeft: -this.$slider.offset().left
144
- })) : this.$slider.css({
145
- width: this.settings.width
146
- }), -1 === this.settings.aspectRatio && (this.settings.aspectRatio = this.settings.width / this.settings.height), this.slideWidth = this.$slider.width(), this.slideHeight = "fullWindow" === this.settings.forceSize ? b(a).height() : isNaN(this.settings.aspectRatio) ? this.settings.height : this.slideWidth / this.settings.aspectRatio, (this.previousSlideWidth !== this.slideWidth || this.previousSlideHeight !== this.slideHeight || "auto" !== this.settings.visibleSize || this.$slider.outerWidth() > this.$slider.parent().width() || this.$slider.width() !== this.$slidesMask.width()) && (this.previousSlideWidth = this.slideWidth, this.previousSlideHeight = this.slideHeight, this.slideSize = "horizontal" === this.settings.orientation ? this.slideWidth : this.slideHeight, this.visibleSlidesSize = this.slideSize, this.visibleOffset = 0, b.each(this.slides, function(a, b) {
147
- b.setSize(c.slideWidth, c.slideHeight)
148
- }), this.$slidesMask.css({
149
- width: this.slideWidth,
150
- height: this.slideHeight
151
- }), this.settings.autoHeight === !0 ? setTimeout(function() {
152
- c._resizeHeight()
153
- }, 1) : this.$slidesMask.css(this.vendorPrefix + "transition", ""), "auto" !== this.settings.visibleSize && ("horizontal" === this.settings.orientation ? ("fullWidth" === this.settings.forceSize || "fullWindow" === this.settings.forceSize ? (this.$slider.css("margin", 0), this.$slider.css({
154
- width: b(a).width(),
155
- "max-width": "",
156
- marginLeft: -this.$slider.offset().left
157
- })) : this.$slider.css({
158
- width: this.settings.visibleSize,
159
- "max-width": "100%",
160
- marginLeft: 0
161
- }), this.$slidesMask.css("width", this.$slider.width()), this.visibleSlidesSize = this.$slidesMask.width(), this.visibleOffset = Math.round((this.$slider.width() - this.slideWidth) / 2)) : (this.$slider.css("fullWindow" === this.settings.forceSize ? {
162
- height: b(a).height(),
163
- "max-height": ""
164
- } : {
165
- height: this.settings.visibleSize,
166
- "max-height": "100%"
167
- }), this.$slidesMask.css("height", this.$slider.height()), this.visibleSlidesSize = this.$slidesMask.height(), this.visibleOffset = Math.round((this.$slider.height() - this.slideHeight) / 2))), this._resetSlidesPosition(), this.trigger({
168
- type: "sliderResize"
169
- }), b.isFunction(this.settings.sliderResize) && this.settings.sliderResize.call(this, {
170
- type: "sliderResize"
171
- }))
172
- },
173
- _resizeHeight: function() {
174
- var a = this,
175
- b = this.getSlideAt(this.selectedSlideIndex),
176
- d = b.getSize();
177
- b.off("imagesLoaded." + c), b.on("imagesLoaded." + c, function(c) {
178
- if (c.index === a.selectedSlideIndex) {
179
- var d = b.getSize();
180
- a._resizeHeightTo(d.height)
181
- }
182
- }), "loading" !== d && this._resizeHeightTo(d.height)
183
- },
184
- gotoSlide: function(a) {
185
- if (a !== this.selectedSlideIndex && "undefined" != typeof this.slides[a]) {
186
- var c = this;
187
- this.previousSlideIndex = this.selectedSlideIndex, this.selectedSlideIndex = a, this.$slides.find(".sp-selected").removeClass("sp-selected"), this.$slides.find(".sp-slide").eq(this.selectedSlideIndex).addClass("sp-selected"), this.settings.loop === !0 && (this._updateSlidesOrder(), this._updateSlidesPosition()), this.settings.autoHeight === !0 && this._resizeHeight();
188
- var d = -parseInt(this.$slides.find(".sp-slide").eq(this.selectedSlideIndex).css(this.positionProperty), 10) + this.visibleOffset;
189
- this._moveTo(d, !1, function() {
190
- c.settings.loop === !0 && c._resetSlidesPosition(), c.trigger({
191
- type: "gotoSlideComplete",
192
- index: a,
193
- previousIndex: c.previousSlideIndex
194
- }), b.isFunction(c.settings.gotoSlideComplete) && c.settings.gotoSlideComplete.call(c, {
195
- type: "gotoSlideComplete",
196
- index: a,
197
- previousIndex: c.previousSlideIndex
198
- })
199
- }), this.trigger({
200
- type: "gotoSlide",
201
- index: a,
202
- previousIndex: this.previousSlideIndex
203
- }), b.isFunction(this.settings.gotoSlide) && this.settings.gotoSlide.call(this, {
204
- type: "gotoSlide",
205
- index: a,
206
- previousIndex: this.previousSlideIndex
207
- })
208
- }
209
- },
210
- nextSlide: function() {
211
- var a = this.selectedSlideIndex >= this.getTotalSlides() - 1 ? 0 : this.selectedSlideIndex + 1;
212
- this.gotoSlide(a)
213
- },
214
- previousSlide: function() {
215
- var a = this.selectedSlideIndex <= 0 ? this.getTotalSlides() - 1 : this.selectedSlideIndex - 1;
216
- this.gotoSlide(a)
217
- },
218
- _moveTo: function(a, b, c) {
219
- var d = this,
220
- e = {};
221
- if (a !== this.slidesPosition)
222
- if (this.slidesPosition = a, "css-3d" !== this.supportedAnimation && "css-2d" !== this.supportedAnimation || this.isIE !== !1) e["margin-" + this.positionProperty] = a, "undefined" != typeof b && b === !0 ? this.$slides.css(e) : (this.$slides.addClass("sp-animated"), this.$slides.animate(e, this.settings.slideAnimationDuration, function() {
223
- d.$slides.removeClass("sp-animated"), "function" == typeof c && c()
224
- }));
225
- else {
226
- var f, g = "horizontal" === this.settings.orientation ? a : 0,
227
- h = "horizontal" === this.settings.orientation ? 0 : a;
228
- e[this.vendorPrefix + "transform"] = "css-3d" === this.supportedAnimation ? "translate3d(" + g + "px, " + h + "px, 0)" : "translate(" + g + "px, " + h + "px)", "undefined" != typeof b && b === !0 ? f = "" : (this.$slides.addClass("sp-animated"), f = this.vendorPrefix + "transform " + this.settings.slideAnimationDuration / 1e3 + "s", this.$slides.on(this.transitionEvent, function(a) {
229
- a.target === a.currentTarget && (d.$slides.off(d.transitionEvent), d.$slides.removeClass("sp-animated"), "function" == typeof c && c())
230
- })), e[this.vendorPrefix + "transition"] = f, this.$slides.css(e)
231
- }
232
- },
233
- _stopMovement: function() {
234
- var a = {};
235
- if ("css-3d" !== this.supportedAnimation && "css-2d" !== this.supportedAnimation || this.isIE !== !1) this.$slides.stop(), this.slidesPosition = parseInt(this.$slides.css("margin-" + this.positionProperty), 10);
236
- else {
237
- var b = this.$slides.css(this.vendorPrefix + "transform"),
238
- c = -1 !== b.indexOf("matrix3d") ? "matrix3d" : "matrix",
239
- d = b.replace(c, "").match(/-?[0-9\.]+/g),
240
- e = "matrix3d" === c ? parseInt(d[12], 10) : parseInt(d[4], 10),
241
- f = "matrix3d" === c ? parseInt(d[13], 10) : parseInt(d[5], 10);
242
- a[this.vendorPrefix + "transform"] = "css-3d" === this.supportedAnimation ? "translate3d(" + e + "px, " + f + "px, 0)" : "translate(" + e + "px, " + f + "px)", a[this.vendorPrefix + "transition"] = "", this.$slides.css(a), this.$slides.off(this.transitionEvent), this.slidesPosition = "horizontal" === this.settings.orientation ? e : f
243
- }
244
- this.$slides.removeClass("sp-animated")
245
- },
246
- _resizeHeightTo: function(a) {
247
- var b = {
248
- height: a
249
- };
250
- "css-3d" === this.supportedAnimation || "css-2d" === this.supportedAnimation ? (b[this.vendorPrefix + "transition"] = "height " + this.settings.heightAnimationDuration / 1e3 + "s", this.$slidesMask.css(b)) : this.$slidesMask.animate(b, this.settings.heightAnimationDuration)
251
- },
252
- destroy: function() {
253
- this.$slider.removeData("sliderPro"), this.$slider.removeAttr("style"), this.$slides.removeAttr("style"), this.off("update." + c), b(a).off("resize." + this.uniqueId + "." + c);
254
- var d = b.SliderPro.modules;
255
- if ("undefined" != typeof d)
256
- for (var e = 0; e < d.length; e++) "undefined" != typeof this["destroy" + d[e]] && this["destroy" + d[e]]();
257
- b.each(this.slides, function(a, b) {
258
- b.destroy()
259
- }), this.slides.length = 0, this.$slides.prependTo(this.$slider), this.$slidesContainer.remove()
260
- },
261
- _setProperties: function(a, b) {
262
- for (var c in a) this.settings[c] = a[c], b !== !1 && (this.originalSettings[c] = a[c]);
263
- this.update()
264
- },
265
- on: function(a, b) {
266
- return this.$slider.on(a, b)
267
- },
268
- off: function(a) {
269
- return this.$slider.off(a)
270
- },
271
- trigger: function(a) {
272
- return this.$slider.triggerHandler(a)
273
- },
274
- getSlideAt: function(a) {
275
- return this.slides[a]
276
- },
277
- getSelectedSlide: function() {
278
- return this.selectedSlideIndex
279
- },
280
- getTotalSlides: function() {
281
- return this.slides.length
282
- },
283
- defaults: {
284
- width: 500,
285
- height: 300,
286
- responsive: !0,
287
- aspectRatio: -1,
288
- imageScaleMode: "cover",
289
- centerImage: !0,
290
- autoHeight: !1,
291
- startSlide: 0,
292
- shuffle: !1,
293
- orientation: "horizontal",
294
- forceSize: "none",
295
- loop: !0,
296
- slideDistance: 10,
297
- slideAnimationDuration: 700,
298
- heightAnimationDuration: 700,
299
- visibleSize: "auto",
300
- breakpoints: null,
301
- init: function() {},
302
- update: function() {},
303
- sliderResize: function() {},
304
- gotoSlide: function() {},
305
- gotoSlideComplete: function() {},
306
- breakpointReach: function() {}
307
- }
308
- };
309
- var e = function(a, b, c) {
310
- this.$slide = a, this.$mainImage = null, this.$imageContainer = null, this.hasMainImage = !1, this.isMainImageLoaded = !1, this.isMainImageLoading = !1, this.hasImages = !1, this.areImagesLoaded = !1, this.width = 0, this.height = 0, this.settings = c, this.setIndex(b), this._init()
311
- };
312
- e.prototype = {
313
- _init: function() {
314
- this.$slide.attr("data-init", !0), this.$mainImage = 0 !== this.$slide.find(".sp-image").length ? this.$slide.find(".sp-image") : null, null !== this.$mainImage && (this.hasMainImage = !0, this.$imageContainer = b('<div class="sp-image-container"></div>').prependTo(this.$slide), 0 !== this.$mainImage.parent("a").length ? this.$mainImage.parent("a").appendTo(this.$imageContainer) : this.$mainImage.appendTo(this.$imageContainer)), this.hasImages = 0 !== this.$slide.find("img").length ? !0 : !1
315
- },
316
- setSize: function(a, b) {
317
- this.width = a, this.height = this.settings.autoHeight === !0 ? "auto" : b, this.$slide.css({
318
- width: this.width,
319
- height: this.height
320
- }), this.hasMainImage === !0 && (this.$imageContainer.css({
321
- width: this.width,
322
- height: this.height
323
- }), "undefined" == typeof this.$mainImage.attr("data-src") && this.resizeMainImage())
324
- },
325
- getSize: function() {
326
- var a, b = this;
327
- if (this.hasImages === !0 && this.areImagesLoaded === !1 && "undefined" == typeof this.$slide.attr("data-loading")) {
328
- this.$slide.attr("data-loading", !0);
329
- var d = f.checkImagesComplete(this.$slide, function() {
330
- b.areImagesLoaded = !0, b.$slide.removeAttr("data-loading"), b.trigger({
331
- type: "imagesLoaded." + c,
332
- index: b.index
333
- })
334
- });
335
- return "complete" === d ? (a = this.calculateSize(), {
336
- width: a.width,
337
- height: a.height
338
- }) : "loading"
339
- }
340
- return a = this.calculateSize(), {
341
- width: a.width,
342
- height: a.height
343
- }
344
- },
345
- calculateSize: function() {
346
- var a = this.$slide.width(),
347
- c = this.$slide.height();
348
- return this.$slide.children().each(function(d, e) {
349
- var f = b(e);
350
- if (f.is(":hidden") !== !0) {
351
- var g = e.getBoundingClientRect(),
352
- h = f.position().top + (g.bottom - g.top),
353
- i = f.position().left + (g.right - g.left);
354
- h > c && (c = h), i > a && (a = i)
355
- }
356
- }), {
357
- width: a,
358
- height: c
359
- }
360
- },
361
- resizeMainImage: function(a) {
362
- var b = this;
363
- return a === !0 && (this.isMainImageLoaded = !1, this.isMainImageLoading = !1), this.isMainImageLoaded === !1 && this.isMainImageLoading === !1 ? (this.isMainImageLoading = !0, void f.checkImagesComplete(this.$mainImage, function() {
364
- b.isMainImageLoaded = !0, b.isMainImageLoading = !1, b.resizeMainImage(), b.trigger({
365
- type: "imagesLoaded." + c,
366
- index: b.index
367
- })
368
- })) : void(this.settings.autoHeight === !0 ? this.$mainImage.css({
369
- width: "100%",
370
- height: "auto",
371
- marginLeft: "",
372
- marginTop: ""
373
- }) : ("cover" === this.settings.imageScaleMode ? this.$mainImage.css(this.$mainImage.width() / this.$mainImage.height() <= this.width / this.height ? {
374
- width: "100%",
375
- height: "auto"
376
- } : {
377
- width: "auto",
378
- height: "100%"
379
- }) : "contain" === this.settings.imageScaleMode ? this.$mainImage.css(this.$mainImage.width() / this.$mainImage.height() >= this.width / this.height ? {
380
- width: "100%",
381
- height: "auto"
382
- } : {
383
- width: "auto",
384
- height: "100%"
385
- }) : "exact" === this.settings.imageScaleMode && this.$mainImage.css({
386
- width: "100%",
387
- height: "100%"
388
- }), this.settings.centerImage === !0 && this.$mainImage.css({
389
- marginLeft: .5 * (this.$imageContainer.width() - this.$mainImage.width()),
390
- marginTop: .5 * (this.$imageContainer.height() - this.$mainImage.height())
391
- })))
392
- },
393
- destroy: function() {
394
- this.$slide.removeAttr("style"), this.$slide.removeAttr("data-init"), this.$slide.removeAttr("data-index"), this.$slide.removeAttr("data-loaded"), this.hasMainImage === !0 && (this.$slide.find(".sp-image").removeAttr("style").appendTo(this.$slide), this.$slide.find(".sp-image-container").remove())
395
- },
396
- getIndex: function() {
397
- return this.index
398
- },
399
- setIndex: function(a) {
400
- this.index = a, this.$slide.attr("data-index", this.index)
401
- },
402
- on: function(a, b) {
403
- return this.$slide.on(a, b)
404
- },
405
- off: function(a) {
406
- return this.$slide.off(a)
407
- },
408
- trigger: function(a) {
409
- return this.$slide.triggerHandler(a)
410
- }
411
- }, a.SliderPro = d, a.SliderProSlide = e, b.fn.sliderPro = function(a) {
412
- var c = Array.prototype.slice.call(arguments, 1);
413
- return this.each(function() {
414
- if ("undefined" == typeof b(this).data("sliderPro")) {
415
- var e = new d(this, a);
416
- b(this).data("sliderPro", e)
417
- } else if ("undefined" != typeof a) {
418
- var f = b(this).data("sliderPro");
419
- if ("function" == typeof f[a]) f[a].apply(f, c);
420
- else if ("undefined" != typeof f.settings[a]) {
421
- var g = {};
422
- g[a] = c[0], f._setProperties(g)
423
- } else "object" == typeof a ? f._setProperties(a) : b.error(a + " does not exist in sliderPro.")
424
- }
425
- })
426
- };
427
- var f = {
428
- supportedAnimation: null,
429
- vendorPrefix: null,
430
- transitionEvent: null,
431
- isIE: null,
432
- getSupportedAnimation: function() {
433
- if (null !== this.supportedAnimation) return this.supportedAnimation;
434
- var a = document.body || document.documentElement,
435
- b = a.style,
436
- c = "undefined" != typeof b.transition || "undefined" != typeof b.WebkitTransition || "undefined" != typeof b.MozTransition || "undefined" != typeof b.OTransition;
437
- if (c === !0) {
438
- var d = document.createElement("div");
439
- if (("undefined" != typeof d.style.WebkitPerspective || "undefined" != typeof d.style.perspective) && (this.supportedAnimation = "css-3d"), "css-3d" === this.supportedAnimation && "undefined" != typeof d.styleWebkitPerspective) {
440
- var e = document.createElement("style");
441
- e.textContent = "@media (transform-3d),(-webkit-transform-3d){#test-3d{left:9px;position:absolute;height:5px;margin:0;padding:0;border:0;}}", document.getElementsByTagName("head")[0].appendChild(e), d.id = "test-3d", document.body.appendChild(d), (9 !== d.offsetLeft || 5 !== d.offsetHeight) && (this.supportedAnimation = null), e.parentNode.removeChild(e), d.parentNode.removeChild(d)
442
- }
443
- null !== this.supportedAnimation || "undefined" == typeof d.style["-webkit-transform"] && "undefined" == typeof d.style.transform || (this.supportedAnimation = "css-2d")
444
- } else this.supportedAnimation = "javascript";
445
- return this.supportedAnimation
446
- },
447
- getVendorPrefix: function() {
448
- if (null !== this.vendorPrefix) return this.vendorPrefix;
449
- var a = document.createElement("div"),
450
- b = ["Webkit", "Moz", "ms", "O"];
451
- if ("transform" in a.style) return this.vendorPrefix = "", this.vendorPrefix;
452
- for (var c = 0; c < b.length; c++)
453
- if (b[c] + "Transform" in a.style) {
454
- this.vendorPrefix = "-" + b[c].toLowerCase() + "-";
455
- break
456
- }
457
- return this.vendorPrefix
458
- },
459
- getTransitionEvent: function() {
460
- if (null !== this.transitionEvent) return this.transitionEvent;
461
- var a = document.createElement("div"),
462
- b = {
463
- transition: "transitionend",
464
- WebkitTransition: "webkitTransitionEnd",
465
- MozTransition: "transitionend",
466
- OTransition: "oTransitionEnd"
467
- };
468
- for (var c in b)
469
- if (c in a.style) {
470
- this.transitionEvent = b[c];
471
- break
472
- }
473
- return this.transitionEvent
474
- },
475
- checkImagesComplete: function(a, b) {
476
- var c = this,
477
- d = this.checkImagesStatus(a);
478
- if ("loading" === d) var e = setInterval(function() {
479
- d = c.checkImagesStatus(a), "complete" === d && (clearInterval(e), "function" == typeof b && b())
480
- }, 100);
481
- else "function" == typeof b && b();
482
- return d
483
- },
484
- checkImagesStatus: function(a) {
485
- var c = "complete";
486
- return a.is("img") && a[0].complete === !1 ? c = "loading" : a.find("img").each(function() {
487
- var a = b(this)[0];
488
- a.complete === !1 && (c = "loading")
489
- }), c
490
- },
491
- checkIE: function() {
492
- if (null !== this.isIE) return this.isIE; {
493
- var b = a.navigator.userAgent;
494
- b.indexOf("MSIE")
495
- }
496
- return this.isIE = -1 !== b.indexOf("MSIE") || b.match(/Trident.*rv\:11\./) ? !0 : !1, this.isIE
497
- }
498
- };
499
- a.SliderProUtils = f
500
- }(window, jQuery),
501
- function(a, b) {
502
- "use strict";
503
- var c = "Thumbnails." + b.SliderPro.namespace,
504
- d = {
505
- $thumbnails: null,
506
- $thumbnailsContainer: null,
507
- thumbnails: null,
508
- selectedThumbnailIndex: 0,
509
- thumbnailsSize: 0,
510
- thumbnailsContainerSize: 0,
511
- thumbnailsPosition: 0,
512
- thumbnailsOrientation: null,
513
- thumbnailsPositionProperty: null,
514
- isThumbnailScroller: !1,
515
- initThumbnails: function() {
516
- var a = this;
517
- this.thumbnails = [], this.on("update." + c, b.proxy(this._thumbnailsOnUpdate, this)), this.on("sliderResize." + c, b.proxy(this._thumbnailsOnResize, this)), this.on("gotoSlide." + c, function(b) {
518
- a._gotoThumbnail(b.index)
519
- })
520
- },
521
- _thumbnailsOnUpdate: function() {
522
- var a = this;
523
- if (0 === this.$slider.find(".sp-thumbnail").length && 0 === this.thumbnails.length) return void(this.isThumbnailScroller = !1);
524
- if (this.isThumbnailScroller = !0, null === this.$thumbnailsContainer && (this.$thumbnailsContainer = b('<div class="sp-thumbnails-container"></div>').insertAfter(this.$slidesContainer)), null === this.$thumbnails)
525
- if (0 !== this.$slider.find(".sp-thumbnails").length) {
526
- if (this.$thumbnails = this.$slider.find(".sp-thumbnails").appendTo(this.$thumbnailsContainer), this.settings.shuffle === !0) {
527
- var c = this.$thumbnails.find(".sp-thumbnail"),
528
- d = [];
529
- b.each(this.shuffledIndexes, function(a, e) {
530
- var f = b(c[e]);
531
- 0 !== f.parent("a").length && (f = f.parent("a")), d.push(f)
532
- }), this.$thumbnails.empty().append(d)
533
- }
534
- } else this.$thumbnails = b('<div class="sp-thumbnails"></div>').appendTo(this.$thumbnailsContainer);
535
- this.$slides.find(".sp-thumbnail").each(function() {
536
- var c = b(this),
537
- d = c.parents(".sp-slide").index(),
538
- e = a.$thumbnails.find(".sp-thumbnail").length - 1;
539
- d > e ? c.appendTo(a.$thumbnails) : c.insertBefore(a.$thumbnails.find(".sp-thumbnail").eq(d))
540
- });
541
- for (var e = this.thumbnails.length - 1; e >= 0; e--)
542
- if (0 === this.$thumbnails.find('.sp-thumbnail[data-index="' + e + '"]').length) {
543
- var f = this.thumbnails[e];
544
- f.destroy(), this.thumbnails.splice(e, 1)
545
- }
546
- this.$thumbnails.find(".sp-thumbnail").each(function(c) {
547
- var d = b(this);
548
- "undefined" == typeof d.attr("data-init") ? a._createThumbnail(d, c) : a.thumbnails[c].setIndex(c)
549
- }), this.$thumbnailsContainer.removeClass("sp-top-thumbnails sp-bottom-thumbnails sp-left-thumbnails sp-right-thumbnails"), "top" === this.settings.thumbnailsPosition ? (this.$thumbnailsContainer.addClass("sp-top-thumbnails"), this.thumbnailsOrientation = "horizontal") : "bottom" === this.settings.thumbnailsPosition ? (this.$thumbnailsContainer.addClass("sp-bottom-thumbnails"), this.thumbnailsOrientation = "horizontal") : "left" === this.settings.thumbnailsPosition ? (this.$thumbnailsContainer.addClass("sp-left-thumbnails"), this.thumbnailsOrientation = "vertical") : "right" === this.settings.thumbnailsPosition && (this.$thumbnailsContainer.addClass("sp-right-thumbnails"), this.thumbnailsOrientation = "vertical"), this.settings.thumbnailPointer === !0 ? this.$thumbnailsContainer.addClass("sp-has-pointer") : this.$thumbnailsContainer.removeClass("sp-has-pointer"), this.selectedThumbnailIndex = this.selectedSlideIndex, this.$thumbnails.find(".sp-thumbnail-container").eq(this.selectedThumbnailIndex).addClass("sp-selected-thumbnail"), this.thumbnailsSize = 0, b.each(this.thumbnails, function(b, c) {
550
- c.setSize(a.settings.thumbnailWidth, a.settings.thumbnailHeight), a.thumbnailsSize += "horizontal" === a.thumbnailsOrientation ? c.getSize().width : c.getSize().height
551
- }), "horizontal" === this.thumbnailsOrientation ? (this.$thumbnails.css({
552
- width: this.thumbnailsSize,
553
- height: this.settings.thumbnailHeight
554
- }), this.$thumbnailsContainer.css("height", ""), this.thumbnailsPositionProperty = "left") : (this.$thumbnails.css({
555
- width: this.settings.thumbnailWidth,
556
- height: this.thumbnailsSize
557
- }), this.$thumbnailsContainer.css("width", ""), this.thumbnailsPositionProperty = "top"), this.trigger({
558
- type: "thumbnailsUpdate"
559
- }), b.isFunction(this.settings.thumbnailsUpdate) && this.settings.thumbnailsUpdate.call(this, {
560
- type: "thumbnailsUpdate"
561
- })
562
- },
563
- _createThumbnail: function(a, b) {
564
- var d = this,
565
- f = new e(a, this.$thumbnails, b);
566
- f.on("thumbnailClick." + c, function(a) {
567
- d.gotoSlide(a.index)
568
- }), this.thumbnails.splice(b, 0, f)
569
- },
570
- _thumbnailsOnResize: function() {
571
- if (this.isThumbnailScroller !== !1) {
572
- var c, d = this;
573
- "horizontal" === this.thumbnailsOrientation ? (this.thumbnailsContainerSize = Math.min(this.$slidesMask.width(), this.thumbnailsSize), this.$thumbnailsContainer.css("width", this.thumbnailsContainerSize), "fullWindow" === this.settings.forceSize && (this.$slidesMask.css("height", this.$slidesMask.height() - this.$thumbnailsContainer.outerHeight(!0)), this.slideHeight = this.$slidesMask.height(), b.each(this.slides, function(a, b) {
574
- b.setSize(d.slideWidth, d.slideHeight)
575
- }))) : "vertical" === this.thumbnailsOrientation && (this.$slidesMask.width() + this.$thumbnailsContainer.outerWidth(!0) > this.$slider.parent().width() && ("fullWidth" === this.settings.forceSize || "fullWindow" === this.settings.forceSize ? this.$slider.css("max-width", b(a).width() - this.$thumbnailsContainer.outerWidth(!0)) : this.$slider.css("max-width", this.$slider.parent().width() - this.$thumbnailsContainer.outerWidth(!0)), this.$slidesMask.css("width", this.$slider.width()), "horizontal" === this.settings.orientation ? (this.visibleOffset = Math.round((this.$slider.width() - this.slideSize) / 2), this.visibleSlidesSize = this.$slidesMask.width()) : "vertical" === this.settings.orientation && (this.slideWidth = this.$slider.width(), b.each(this.slides, function(a, b) {
576
- b.setSize(d.slideWidth, d.slideHeight)
577
- })), this._resetSlidesPosition()), this.thumbnailsContainerSize = Math.min(this.$slidesMask.height(), this.thumbnailsSize), this.$thumbnailsContainer.css("height", this.thumbnailsContainerSize)), c = this.thumbnailsSize <= this.thumbnailsContainerSize || 0 === this.$thumbnails.find(".sp-selected-thumbnail").length ? 0 : Math.max(-this.thumbnails[this.selectedThumbnailIndex].getPosition()[this.thumbnailsPositionProperty], this.thumbnailsContainerSize - this.thumbnailsSize), "top" === this.settings.thumbnailsPosition ? this.$slider.css({
578
- paddingTop: this.$thumbnailsContainer.outerHeight(!0),
579
- paddingLeft: "",
580
- paddingRight: ""
581
- }) : "bottom" === this.settings.thumbnailsPosition ? this.$slider.css({
582
- paddingTop: "",
583
- paddingLeft: "",
584
- paddingRight: ""
585
- }) : "left" === this.settings.thumbnailsPosition ? this.$slider.css({
586
- paddingTop: "",
587
- paddingLeft: this.$thumbnailsContainer.outerWidth(!0),
588
- paddingRight: ""
589
- }) : "right" === this.settings.thumbnailsPosition && this.$slider.css({
590
- paddingTop: "",
591
- paddingLeft: "",
592
- paddingRight: this.$thumbnailsContainer.outerWidth(!0)
593
- }), this._moveThumbnailsTo(c, !0)
594
- }
595
- },
596
- _gotoThumbnail: function(a) {
597
- if (this.isThumbnailScroller !== !1 && "undefined" != typeof this.thumbnails[a]) {
598
- var c = this.selectedThumbnailIndex,
599
- d = this.thumbnailsPosition;
600
- if (this.selectedThumbnailIndex = a, this.$thumbnails.find(".sp-selected-thumbnail").removeClass("sp-selected-thumbnail"), this.$thumbnails.find(".sp-thumbnail-container").eq(this.selectedThumbnailIndex).addClass("sp-selected-thumbnail"), this.selectedThumbnailIndex >= c) {
601
- var e = this.selectedThumbnailIndex === this.thumbnails.length - 1 ? this.selectedThumbnailIndex : this.selectedThumbnailIndex + 1,
602
- f = this.thumbnails[e],
603
- g = "horizontal" === this.thumbnailsOrientation ? f.getPosition().right : f.getPosition().bottom,
604
- h = -this.thumbnailsPosition + this.thumbnailsContainerSize;
605
- g > h && (d = this.thumbnailsPosition - (g - h))
606
- } else if (this.selectedThumbnailIndex < c) {
607
- var i = 0 === this.selectedThumbnailIndex ? this.selectedThumbnailIndex : this.selectedThumbnailIndex - 1,
608
- j = this.thumbnails[i],
609
- k = "horizontal" === this.thumbnailsOrientation ? j.getPosition().left : j.getPosition().top;
610
- k < -this.thumbnailsPosition && (d = -k)
611
- }
612
- this._moveThumbnailsTo(d), this.trigger({
613
- type: "gotoThumbnail"
614
- }), b.isFunction(this.settings.gotoThumbnail) && this.settings.gotoThumbnail.call(this, {
615
- type: "gotoThumbnail"
616
- })
617
- }
618
- },
619
- _moveThumbnailsTo: function(a, c, d) {
620
- var e = this,
621
- f = {};
622
- if (a !== this.thumbnailsPosition)
623
- if (this.thumbnailsPosition = a, "css-3d" === this.supportedAnimation || "css-2d" === this.supportedAnimation) {
624
- var g, h = "horizontal" === this.thumbnailsOrientation ? a : 0,
625
- i = "horizontal" === this.thumbnailsOrientation ? 0 : a;
626
- f[this.vendorPrefix + "transform"] = "css-3d" === this.supportedAnimation ? "translate3d(" + h + "px, " + i + "px, 0)" : "translate(" + h + "px, " + i + "px)", "undefined" != typeof c && c === !0 ? g = "" : (this.$thumbnails.addClass("sp-animated"), g = this.vendorPrefix + "transform 0.7s", this.$thumbnails.on(this.transitionEvent, function(a) {
627
- a.target === a.currentTarget && (e.$thumbnails.off(e.transitionEvent), e.$thumbnails.removeClass("sp-animated"), "function" == typeof d && d(), e.trigger({
628
- type: "thumbnailsMoveComplete"
629
- }), b.isFunction(e.settings.thumbnailsMoveComplete) && e.settings.thumbnailsMoveComplete.call(e, {
630
- type: "thumbnailsMoveComplete"
631
- }))
632
- })), f[this.vendorPrefix + "transition"] = g, this.$thumbnails.css(f)
633
- } else f["margin-" + this.thumbnailsPositionProperty] = a, "undefined" != typeof c && c === !0 ? this.$thumbnails.css(f) : this.$thumbnails.addClass("sp-animated").animate(f, 700, function() {
634
- e.$thumbnails.removeClass("sp-animated"), "function" == typeof d && d(), e.trigger({
635
- type: "thumbnailsMoveComplete"
636
- }), b.isFunction(e.settings.thumbnailsMoveComplete) && e.settings.thumbnailsMoveComplete.call(e, {
637
- type: "thumbnailsMoveComplete"
638
- })
639
- })
640
- },
641
- _stopThumbnailsMovement: function() {
642
- var a = {};
643
- if ("css-3d" === this.supportedAnimation || "css-2d" === this.supportedAnimation) {
644
- var b = this.$thumbnails.css(this.vendorPrefix + "transform"),
645
- c = -1 !== b.indexOf("matrix3d") ? "matrix3d" : "matrix",
646
- d = b.replace(c, "").match(/-?[0-9\.]+/g),
647
- e = "matrix3d" === c ? parseInt(d[12], 10) : parseInt(d[4], 10),
648
- f = "matrix3d" === c ? parseInt(d[13], 10) : parseInt(d[5], 10);
649
- a[this.vendorPrefix + "transform"] = "css-3d" === this.supportedAnimation ? "translate3d(" + e + "px, " + f + "px, 0)" : "translate(" + e + "px, " + f + "px)", a[this.vendorPrefix + "transition"] = "", this.$thumbnails.css(a), this.$thumbnails.off(this.transitionEvent), this.thumbnailsPosition = "horizontal" === this.thumbnailsOrientation ? parseInt(d[4], 10) : parseInt(d[5], 10)
650
- } else this.$thumbnails.stop(), this.thumbnailsPosition = parseInt(this.$thumbnails.css("margin-" + this.thumbnailsPositionProperty), 10);
651
- this.$thumbnails.removeClass("sp-animated")
652
- },
653
- destroyThumbnails: function() {
654
- var d = this;
655
- this.off("update." + c), this.isThumbnailScroller !== !1 && (this.off("sliderResize." + c), this.off("gotoSlide." + c), b(a).off("resize." + this.uniqueId + "." + c), this.$thumbnails.find(".sp-thumbnail").each(function() {
656
- var a = b(this),
657
- e = parseInt(a.attr("data-index"), 10),
658
- f = d.thumbnails[e];
659
- f.off("thumbnailClick." + c), f.destroy()
660
- }), this.thumbnails.length = 0, this.$thumbnails.appendTo(this.$slider), this.$thumbnailsContainer.remove(), this.$slider.css({
661
- paddingTop: "",
662
- paddingLeft: "",
663
- paddingRight: ""
664
- }))
665
- },
666
- thumbnailsDefaults: {
667
- thumbnailWidth: 100,
668
- thumbnailHeight: 80,
669
- thumbnailsPosition: "bottom",
670
- thumbnailPointer: !1,
671
- thumbnailsUpdate: function() {},
672
- gotoThumbnail: function() {},
673
- thumbnailsMoveComplete: function() {}
674
- }
675
- },
676
- e = function(a, b, c) {
677
- this.$thumbnail = a, this.$thumbnails = b, this.$thumbnailContainer = null, this.width = 0, this.height = 0, this.isImageLoaded = !1, this.setIndex(c), this._init()
678
- };
679
- e.prototype = {
680
- _init: function() {
681
- var a = this;
682
- this.$thumbnail.attr("data-init", !0), this.$thumbnailContainer = b('<div class="sp-thumbnail-container"></div>').appendTo(this.$thumbnails), 0 !== this.$thumbnail.parent("a").length ? this.$thumbnail.parent("a").appendTo(this.$thumbnailContainer) : this.$thumbnail.appendTo(this.$thumbnailContainer), this.$thumbnailContainer.on("click." + c, function() {
683
- a.trigger({
684
- type: "thumbnailClick." + c,
685
- index: a.index
686
- })
687
- })
688
- },
689
- setSize: function(a, b) {
690
- this.width = a, this.height = b, this.$thumbnailContainer.css({
691
- width: this.width,
692
- height: this.height
693
- }), this.$thumbnail.is("img") && "undefined" == typeof this.$thumbnail.attr("data-src") && this.resizeImage()
694
- },
695
- getSize: function() {
696
- return {
697
- width: this.$thumbnailContainer.outerWidth(!0),
698
- height: this.$thumbnailContainer.outerHeight(!0)
699
- }
700
- },
701
- getPosition: function() {
702
- return {
703
- left: this.$thumbnailContainer.position().left + parseInt(this.$thumbnailContainer.css("marginLeft"), 10),
704
- right: this.$thumbnailContainer.position().left + parseInt(this.$thumbnailContainer.css("marginLeft"), 10) + this.$thumbnailContainer.outerWidth(),
705
- top: this.$thumbnailContainer.position().top + parseInt(this.$thumbnailContainer.css("marginTop"), 10),
706
- bottom: this.$thumbnailContainer.position().top + parseInt(this.$thumbnailContainer.css("marginTop"), 10) + this.$thumbnailContainer.outerHeight()
707
- }
708
- },
709
- setIndex: function(a) {
710
- this.index = a, this.$thumbnail.attr("data-index", this.index)
711
- },
712
- resizeImage: function() {
713
- var a = this;
714
- if (this.isImageLoaded === !1) return void SliderProUtils.checkImagesComplete(this.$thumbnailContainer, function() {
715
- a.isImageLoaded = !0, a.resizeImage()
716
- });
717
- this.$thumbnail = this.$thumbnailContainer.find(".sp-thumbnail");
718
- var b = this.$thumbnail.width(),
719
- c = this.$thumbnail.height();
720
- this.$thumbnail.css(b / c <= this.width / this.height ? {
721
- width: "100%",
722
- height: "auto"
723
- } : {
724
- width: "auto",
725
- height: "100%"
726
- }), this.$thumbnail.css({
727
- marginLeft: .5 * (this.$thumbnailContainer.width() - this.$thumbnail.width()),
728
- marginTop: .5 * (this.$thumbnailContainer.height() - this.$thumbnail.height())
729
- })
730
- },
731
- destroy: function() {
732
- this.$thumbnailContainer.off("click." + c), this.$thumbnail.removeAttr("data-init"), this.$thumbnail.removeAttr("data-index"), 0 !== this.$thumbnail.parent("a").length ? this.$thumbnail.parent("a").insertBefore(this.$thumbnailContainer) : this.$thumbnail.insertBefore(this.$thumbnailContainer), this.$thumbnailContainer.remove()
733
- },
734
- on: function(a, b) {
735
- return this.$thumbnailContainer.on(a, b)
736
- },
737
- off: function(a) {
738
- return this.$thumbnailContainer.off(a)
739
- },
740
- trigger: function(a) {
741
- return this.$thumbnailContainer.triggerHandler(a)
742
- }
743
- }, b.SliderPro.addModule("Thumbnails", d)
744
- }(window, jQuery),
745
- function(a, b) {
746
- "use strict";
747
- var c = "ConditionalImages." + b.SliderPro.namespace,
748
- d = {
749
- previousImageSize: null,
750
- currentImageSize: null,
751
- isRetinaScreen: !1,
752
- initConditionalImages: function() {
753
- this.currentImageSize = this.previousImageSize = "default", this.isRetinaScreen = "undefined" != typeof this._isRetina && this._isRetina() === !0, this.on("update." + c, b.proxy(this._conditionalImagesOnUpdate, this)), this.on("sliderResize." + c, b.proxy(this._conditionalImagesOnResize, this))
754
- },
755
- _conditionalImagesOnUpdate: function() {
756
- b.each(this.slides, function(a, c) {
757
- var d = c.$slide;
758
- d.find("img:not([ data-default ])").each(function() {
759
- var a = b(this);
760
- "undefined" != typeof a.attr("data-src") ? a.attr("data-default", a.attr("data-src")) : a.attr("data-default", a.attr("src"))
761
- })
762
- })
763
- },
764
- _conditionalImagesOnResize: function() {
765
- if (this.currentImageSize = this.slideWidth <= this.settings.smallSize ? "small" : this.slideWidth <= this.settings.mediumSize ? "medium" : this.slideWidth <= this.settings.largeSize ? "large" : "default", this.previousImageSize !== this.currentImageSize) {
766
- var a = this;
767
- b.each(this.slides, function(c, d) {
768
- var e = d.$slide;
769
- e.find("img").each(function() {
770
- var c = b(this),
771
- e = "";
772
- a.isRetinaScreen === !0 && "undefined" != typeof c.attr("data-retina" + a.currentImageSize) ? (e = c.attr("data-retina" + a.currentImageSize), "undefined" != typeof c.attr("data-retina") && c.attr("data-retina") !== e && c.attr("data-retina", e)) : (a.isRetinaScreen === !1 || a.isRetinaScreen === !0 && "undefined" == typeof c.attr("data-retina")) && "undefined" != typeof c.attr("data-" + a.currentImageSize) && (e = c.attr("data-" + a.currentImageSize), "undefined" != typeof c.attr("data-src") && c.attr("data-src") !== e && c.attr("data-src", e)), "" !== e && "undefined" == typeof c.attr("data-src") && c.attr("src") !== e && a._loadConditionalImage(c, e, function(a) {
773
- a.hasClass("sp-image") && (d.$mainImage = a, d.resizeMainImage(!0))
774
- })
775
- })
776
- }), this.previousImageSize = this.currentImageSize
777
- }
778
- },
779
- _loadConditionalImage: function(a, c, d) {
780
- var e = b(new Image);
781
- e.attr("class", a.attr("class")), e.attr("style", a.attr("style")), b.each(a.data(), function(a, b) {
782
- e.attr("data-" + a, b)
783
- }), "undefined" != typeof a.attr("width") && e.attr("width", a.attr("width")), "undefined" != typeof a.attr("height") && e.attr("height", a.attr("height")), "undefined" != typeof a.attr("alt") && e.attr("alt", a.attr("alt")), "undefined" != typeof a.attr("title") && e.attr("title", a.attr("title")), e.attr("src", c), e.insertAfter(a), a.remove(), a = null, "function" == typeof d && d(e)
784
- },
785
- destroyConditionalImages: function() {
786
- this.off("update." + c), this.off("sliderResize." + c)
787
- },
788
- conditionalImagesDefaults: {
789
- smallSize: 480,
790
- mediumSize: 768,
791
- largeSize: 1024
792
- }
793
- };
794
- b.SliderPro.addModule("ConditionalImages", d)
795
- }(window, jQuery),
796
- function(a, b) {
797
- "use strict";
798
- var c = "Retina." + b.SliderPro.namespace,
799
- d = {
800
- initRetina: function() {
801
- this._isRetina() !== !1 && (this.on("update." + c, b.proxy(this._checkRetinaImages, this)), 0 !== this.$slider.find(".sp-thumbnail").length && this.on("update.Thumbnails." + c, b.proxy(this._checkRetinaThumbnailImages, this)))
802
- },
803
- _isRetina: function() {
804
- return a.devicePixelRatio >= 2 ? !0 : a.matchMedia && a.matchMedia("(-webkit-min-device-pixel-ratio: 2),(min-resolution: 2dppx)").matches ? !0 : !1
805
- },
806
- _checkRetinaImages: function() {
807
- var a = this;
808
- b.each(this.slides, function(c, d) {
809
- var e = d.$slide;
810
- "undefined" == typeof e.attr("data-retina-loaded") && (e.attr("data-retina-loaded", !0), e.find("img[data-retina]").each(function() {
811
- var c = b(this);
812
- "undefined" != typeof c.attr("data-src") ? c.attr("data-src", c.attr("data-retina")) : a._loadRetinaImage(c, function(a) {
813
- a.hasClass("sp-image") && (d.$mainImage = a, d.resizeMainImage(!0))
814
- })
815
- }))
816
- })
817
- },
818
- _checkRetinaThumbnailImages: function() {
819
- var a = this;
820
- b.each(this.thumbnails, function(c, d) {
821
- var e = d.$thumbnailContainer;
822
- "undefined" == typeof e.attr("data-retina-loaded") && (e.attr("data-retina-loaded", !0), e.find("img[data-retina]").each(function() {
823
- var c = b(this);
824
- "undefined" != typeof c.attr("data-src") ? c.attr("data-src", c.attr("data-retina")) : a._loadRetinaImage(c, function(a) {
825
- a.hasClass("sp-thumbnail") && d.resizeImage()
826
- })
827
- }))
828
- })
829
- },
830
- _loadRetinaImage: function(a, c) {
831
- var d = !1,
832
- e = "";
833
- if ("undefined" != typeof a.attr("data-retina") && (d = !0, e = a.attr("data-retina")), "undefined" != typeof a.attr("data-src") && (d === !1 && (e = a.attr("data-src")), a.removeAttr("data-src")), "" !== e) {
834
- var f = b(new Image);
835
- f.attr("class", a.attr("class")), f.attr("style", a.attr("style")), b.each(a.data(), function(a, b) {
836
- f.attr("data-" + a, b)
837
- }), "undefined" != typeof a.attr("width") && f.attr("width", a.attr("width")), "undefined" != typeof a.attr("height") && f.attr("height", a.attr("height")), "undefined" != typeof a.attr("alt") && f.attr("alt", a.attr("alt")), "undefined" != typeof a.attr("title") && f.attr("title", a.attr("title")), f.insertAfter(a), a.remove(), a = null, f.attr("src", e), "function" == typeof c && c(f)
838
- }
839
- },
840
- destroyRetina: function() {
841
- this.off("update." + c), this.off("update.Thumbnails." + c)
842
- }
843
- };
844
- b.SliderPro.addModule("Retina", d)
845
- }(window, jQuery),
846
- function(a, b) {
847
- "use strict";
848
- var c = "LazyLoading." + b.SliderPro.namespace,
849
- d = {
850
- allowLazyLoadingCheck: !0,
851
- initLazyLoading: function() {
852
- this.on("sliderResize." + c, b.proxy(this._lazyLoadingOnResize, this)), this.on("gotoSlide." + c, b.proxy(this._checkAndLoadVisibleImages, this)), this.on("thumbnailsUpdate." + c + " thumbnailsMoveComplete." + c, b.proxy(this._checkAndLoadVisibleThumbnailImages, this))
853
- },
854
- _lazyLoadingOnResize: function() {
855
- var a = this;
856
- this.allowLazyLoadingCheck !== !1 && (this.allowLazyLoadingCheck = !1, this._checkAndLoadVisibleImages(), 0 !== this.$slider.find(".sp-thumbnail").length && this._checkAndLoadVisibleThumbnailImages(), setTimeout(function() {
857
- a.allowLazyLoadingCheck = !0
858
- }, 500))
859
- },
860
- _checkAndLoadVisibleImages: function() {
861
- if (0 !== this.$slider.find(".sp-slide:not([ data-loaded ])").length) {
862
- var a = this,
863
- c = this.settings.loop === !0 ? this.middleSlidePosition : this.selectedSlideIndex,
864
- d = Math.ceil((this.visibleSlidesSize - this.slideSize) / 2 / this.slideSize),
865
- e = c - d - 1 > 0 ? c - d - 1 : 0,
866
- f = c + d + 1 < this.getTotalSlides() - 1 ? c + d + 1 : this.getTotalSlides() - 1,
867
- g = this.slidesOrder.slice(e, f + 1);
868
- b.each(g, function(c, d) {
869
- var e = a.slides[d],
870
- f = e.$slide;
871
- "undefined" == typeof f.attr("data-loaded") && (f.attr("data-loaded", !0), f.find("img[ data-src ]").each(function() {
872
- var c = b(this);
873
- a._loadImage(c, function(a) {
874
- a.hasClass("sp-image") && (e.$mainImage = a, e.resizeMainImage(!0))
875
- })
876
- }))
877
- })
878
- }
879
- },
880
- _checkAndLoadVisibleThumbnailImages: function() {
881
- if (0 !== this.$slider.find(".sp-thumbnail-container:not([ data-loaded ])").length) {
882
- var a = this,
883
- c = this.thumbnailsSize / this.thumbnails.length,
884
- d = Math.floor(Math.abs(this.thumbnailsPosition / c)),
885
- e = Math.floor((-this.thumbnailsPosition + this.thumbnailsContainerSize) / c),
886
- f = this.thumbnails.slice(d, e + 1);
887
- b.each(f, function(c, d) {
888
- var e = d.$thumbnailContainer;
889
- "undefined" == typeof e.attr("data-loaded") && (e.attr("data-loaded", !0), e.find("img[ data-src ]").each(function() {
890
- var c = b(this);
891
- a._loadImage(c, function() {
892
- d.resizeImage()
893
- })
894
- }))
895
- })
896
- }
897
- },
898
- _loadImage: function(a, c) {
899
- var d = b(new Image);
900
- d.attr("class", a.attr("class")), d.attr("style", a.attr("style")), b.each(a.data(), function(a, b) {
901
- d.attr("data-" + a, b)
902
- }), "undefined" != typeof a.attr("width") && d.attr("width", a.attr("width")), "undefined" != typeof a.attr("height") && d.attr("height", a.attr("height")), "undefined" != typeof a.attr("alt") && d.attr("alt", a.attr("alt")), "undefined" != typeof a.attr("title") && d.attr("title", a.attr("title")), d.attr("src", a.attr("data-src")), d.removeAttr("data-src"), d.insertAfter(a), a.remove(), a = null, "function" == typeof c && c(d)
903
- },
904
- destroyLazyLoading: function() {
905
- this.off("update." + c), this.off("gotoSlide." + c), this.off("sliderResize." + c), this.off("thumbnailsUpdate." + c), this.off("thumbnailsMoveComplete." + c)
906
- }
907
- };
908
- b.SliderPro.addModule("LazyLoading", d)
909
- }(window, jQuery),
910
- function(a, b) {
911
- "use strict";
912
- var c = "Layers." + b.SliderPro.namespace,
913
- d = {
914
- layersGotoSlideReference: null,
915
- waitForLayersTimer: null,
916
- initLayers: function() {
917
- this.on("update." + c, b.proxy(this._layersOnUpdate, this)), this.on("sliderResize." + c, b.proxy(this._layersOnResize, this)), this.on("gotoSlide." + c, b.proxy(this._layersOnGotoSlide, this))
918
- },
919
- _layersOnUpdate: function() {
920
- var a = this;
921
- b.each(this.slides, function(a, c) {
922
- c.$slide;
923
- this.$slide.find(".sp-layer:not([ data-init ])").each(function() {
924
- var a = new f(b(this));
925
- "undefined" == typeof c.layers && (c.layers = []), c.layers.push(a), b(this).hasClass("sp-static") === !1 && ("undefined" == typeof c.animatedLayers && (c.animatedLayers = []), c.animatedLayers.push(a))
926
- })
927
- }), this.settings.waitForLayers === !0 && (clearTimeout(this.waitForLayersTimer), this.waitForLayersTimer = setTimeout(function() {
928
- a.layersGotoSlideReference = a.gotoSlide, a.gotoSlide = a._layersGotoSlide
929
- }, 1))
930
- },
931
- _layersOnResize: function() {
932
- var a, c, d = this,
933
- e = this.settings.autoScaleLayers;
934
- return this.settings.autoScaleLayers === !1 ? void this.showLayers(this.selectedSlideIndex) : (-1 === this.settings.autoScaleReference ? "string" == typeof this.settings.width && -1 !== this.settings.width.indexOf("%") ? e = !1 : a = parseInt(this.settings.width, 10) : a = this.settings.autoScaleReference, c = e === !0 && this.slideWidth < a ? d.slideWidth / a : 1, b.each(this.slides, function(a, d) {
935
- "undefined" != typeof d.layers && b.each(d.layers, function(a, b) {
936
- b.scale(c)
937
- })
938
- }), void this.showLayers(this.selectedSlideIndex))
939
- },
940
- _layersGotoSlide: function(a) {
941
- var b = this,
942
- d = this.slides[this.selectedSlideIndex].animatedLayers;
943
- this.$slider.hasClass("sp-swiping") || "undefined" == typeof d || 0 === d.length ? this.layersGotoSlideReference(a) : (this.on("hideLayersComplete." + c, function() {
944
- b.off("hideLayersComplete." + c), b.layersGotoSlideReference(a)
945
- }), this.hideLayers(this.selectedSlideIndex))
946
- },
947
- _layersOnGotoSlide: function() {
948
- this.previousSlideIndex !== this.selectedSlideIndex && this.hideLayers(this.previousSlideIndex), this.showLayers(this.selectedSlideIndex)
949
- },
950
- showLayers: function(a) {
951
- var c = this,
952
- d = this.slides[a].animatedLayers,
953
- e = 0;
954
- "undefined" != typeof d && b.each(d, function(a, f) {
955
- f.isVisible() === !0 ? (e++, e === d.length && (c.trigger({
956
- type: "showLayersComplete",
957
- index: a
958
- }), b.isFunction(c.settings.showLayersComplete) && c.settings.showLayersComplete.call(c, {
959
- type: "showLayersComplete",
960
- index: a
961
- }))) : f.show(function() {
962
- e++, e === d.length && (c.trigger({
963
- type: "showLayersComplete",
964
- index: a
965
- }), b.isFunction(c.settings.showLayersComplete) && c.settings.showLayersComplete.call(c, {
966
- type: "showLayersComplete",
967
- index: a
968
- }))
969
- })
970
- })
971
- },
972
- hideLayers: function(a) {
973
- var c = this,
974
- d = this.slides[a].animatedLayers,
975
- e = 0;
976
- "undefined" != typeof d && b.each(d, function(a, f) {
977
- f.isVisible() === !1 ? (e++, e === d.length && (c.trigger({
978
- type: "hideLayersComplete",
979
- index: a
980
- }), b.isFunction(c.settings.hideLayersComplete) && c.settings.hideLayersComplete.call(c, {
981
- type: "hideLayersComplete",
982
- index: a
983
- }))) : f.hide(function() {
984
- e++, e === d.length && (c.trigger({
985
- type: "hideLayersComplete",
986
- index: a
987
- }), b.isFunction(c.settings.hideLayersComplete) && c.settings.hideLayersComplete.call(c, {
988
- type: "hideLayersComplete",
989
- index: a
990
- }))
991
- })
992
- })
993
- },
994
- destroyLayers: function() {
995
- this.off("update." + c), this.off("resize." + c), this.off("gotoSlide." + c), this.off("hideLayersComplete." + c)
996
- },
997
- layersDefaults: {
998
- waitForLayers: !1,
999
- autoScaleLayers: !0,
1000
- autoScaleReference: -1,
1001
- showLayersComplete: function() {},
1002
- hideLayersComplete: function() {}
1003
- }
1004
- },
1005
- e = a.SliderProSlide.prototype.destroy;
1006
- a.SliderProSlide.prototype.destroy = function() {
1007
- "undefined" != typeof this.layers && (b.each(this.layers, function(a, b) {
1008
- b.destroy()
1009
- }), this.layers.length = 0), "undefined" != typeof this.animatedLayers && (this.animatedLayers.length = 0), e.apply(this)
1010
- };
1011
- var f = function(a) {
1012
- this.$layer = a, this.visible = !1, this.styled = !1, this.data = null, this.position = null, this.horizontalProperty = null, this.verticalProperty = null, this.horizontalPosition = null, this.verticalPosition = null, this.scaleRatio = 1, this.supportedAnimation = SliderProUtils.getSupportedAnimation(), this.vendorPrefix = SliderProUtils.getVendorPrefix(), this.transitionEvent = SliderProUtils.getTransitionEvent(), this.stayTimer = null, this._init()
1013
- };
1014
- f.prototype = {
1015
- _init: function() {
1016
- this.$layer.attr("data-init", !0), this.$layer.hasClass("sp-static") ? this._setStyle() : this.$layer.css({
1017
- visibility: "hidden",
1018
- display: "none"
1019
- })
1020
- },
1021
- _setStyle: function() {
1022
- this.styled = !0, this.$layer.css("display", ""), this.data = this.$layer.data(), "undefined" != typeof this.data.width && this.$layer.css("width", this.data.width), "undefined" != typeof this.data.height && this.$layer.css("height", this.data.height), "undefined" != typeof this.data.depth && this.$layer.css("z-index", this.data.depth), this.position = this.data.position ? this.data.position.toLowerCase() : "topleft", this.horizontalProperty = -1 !== this.position.indexOf("right") ? "right" : -1 !== this.position.indexOf("left") ? "left" : "center", this.verticalProperty = -1 !== this.position.indexOf("bottom") ? "bottom" : -1 !== this.position.indexOf("top") ? "top" : "center", this._setPosition(), this.scale(this.scaleRatio)
1023
- },
1024
- _setPosition: function() {
1025
- var a = this.$layer.attr("style");
1026
- this.horizontalPosition = "undefined" != typeof this.data.horizontal ? this.data.horizontal : 0, this.verticalPosition = "undefined" != typeof this.data.vertical ? this.data.vertical : 0, "center" === this.horizontalProperty ? (("undefined" == typeof a || "undefined" != typeof a && -1 === a.indexOf("width")) && (this.$layer.css("white-space", ""), this.$layer.css("width", this.$layer.outerWidth(!0))), this.$layer.css({
1027
- marginLeft: "auto",
1028
- marginRight: "auto",
1029
- left: this.horizontalPosition,
1030
- right: 0
1031
- })) : this.$layer.css(this.horizontalProperty, this.horizontalPosition), "center" === this.verticalProperty ? (("undefined" == typeof a || "undefined" != typeof a && -1 === a.indexOf("height")) && (this.$layer.css("white-space", ""), this.$layer.css("height", this.$layer.outerHeight(!0))), this.$layer.css({
1032
- marginTop: "auto",
1033
- marginBottom: "auto",
1034
- top: this.verticalPosition,
1035
- bottom: 0
1036
- })) : this.$layer.css(this.verticalProperty, this.verticalPosition)
1037
- },
1038
- scale: function(a) {
1039
- if (!this.$layer.hasClass("sp-no-scale") && (this.scaleRatio = a, this.styled !== !1)) {
1040
- var b = "center" === this.horizontalProperty ? "left" : this.horizontalProperty,
1041
- c = "center" === this.verticalProperty ? "top" : this.verticalProperty,
1042
- d = {};
1043
- d[this.vendorPrefix + "transform-origin"] = this.horizontalProperty + " " + this.verticalProperty, d[this.vendorPrefix + "transform"] = "scale(" + this.scaleRatio + ")", "string" != typeof this.horizontalPosition && (d[b] = this.horizontalPosition * this.scaleRatio), "string" != typeof this.verticalPosition && (d[c] = this.verticalPosition * this.scaleRatio), "string" == typeof this.data.width && -1 !== this.data.width.indexOf("%") && (d.width = (parseInt(this.data.width, 10) / this.scaleRatio).toString() + "%"), "string" == typeof this.data.height && -1 !== this.data.height.indexOf("%") && (d.height = (parseInt(this.data.height, 10) / this.scaleRatio).toString() + "%"), this.$layer.css(d)
1044
- }
1045
- },
1046
- show: function(a) {
1047
- if (this.visible !== !0) {
1048
- this.visible = !0, this.styled === !1 && this._setStyle();
1049
- var b = this,
1050
- c = "undefined" != typeof this.data.showOffset ? this.data.showOffset : 50,
1051
- d = "undefined" != typeof this.data.showDuration ? this.data.showDuration / 1e3 : .4,
1052
- e = "undefined" != typeof this.data.showDelay ? this.data.showDelay : 10,
1053
- f = "undefined" != typeof b.data.stayDuration ? parseInt(b.data.stayDuration, 10) : -1;
1054
- if ("javascript" === this.supportedAnimation) this.$layer.stop().delay(e).css({
1055
- opacity: 0,
1056
- visibility: "visible"
1057
- }).animate({
1058
- opacity: 1
1059
- }, 1e3 * d, function() {
1060
- -1 !== f && (b.stayTimer = setTimeout(function() {
1061
- b.hide(), b.stayTimer = null
1062
- }, f)), "undefined" != typeof a && a()
1063
- });
1064
- else {
1065
- var g = {
1066
- opacity: 0,
1067
- visibility: "visible"
1068
- },
1069
- h = {
1070
- opacity: 1
1071
- },
1072
- i = "";
1073
- g[this.vendorPrefix + "transform"] = "scale(" + this.scaleRatio + ")", h[this.vendorPrefix + "transform"] = "scale(" + this.scaleRatio + ")", h[this.vendorPrefix + "transition"] = "opacity " + d + "s", "undefined" != typeof this.data.showTransition && ("left" === this.data.showTransition ? i = c + "px, 0" : "right" === this.data.showTransition ? i = "-" + c + "px, 0" : "up" === this.data.showTransition ? i = "0, " + c + "px" : "down" === this.data.showTransition && (i = "0, -" + c + "px"), g[this.vendorPrefix + "transform"] += "css-3d" === this.supportedAnimation ? " translate3d(" + i + ", 0)" : " translate(" + i + ")", h[this.vendorPrefix + "transform"] += "css-3d" === this.supportedAnimation ? " translate3d(0, 0, 0)" : " translate(0, 0)", h[this.vendorPrefix + "transition"] += ", " + this.vendorPrefix + "transform " + d + "s"), this.$layer.on(this.transitionEvent, function(c) {
1074
- c.target === c.currentTarget && (b.$layer.off(b.transitionEvent).css(b.vendorPrefix + "transition", ""), -1 !== f && (b.stayTimer = setTimeout(function() {
1075
- b.hide(), b.stayTimer = null
1076
- }, f)), "undefined" != typeof a && a())
1077
- }), this.$layer.css(g), setTimeout(function() {
1078
- b.$layer.css(h)
1079
- }, e)
1080
- }
1081
- }
1082
- },
1083
- hide: function(a) {
1084
- if (this.visible !== !1) {
1085
- var c = this,
1086
- d = "undefined" != typeof this.data.hideOffset ? this.data.hideOffset : 50,
1087
- e = "undefined" != typeof this.data.hideDuration ? this.data.hideDuration / 1e3 : .4,
1088
- f = "undefined" != typeof this.data.hideDelay ? this.data.hideDelay : 10;
1089
- if (this.visible = !1, null !== this.stayTimer && clearTimeout(this.stayTimer), "javascript" === this.supportedAnimation) this.$layer.stop().delay(f).animate({
1090
- opacity: 0
1091
- }, 1e3 * e, function() {
1092
- b(this).css("visibility", "hidden"), "undefined" != typeof a && a()
1093
- });
1094
- else {
1095
- var g = "",
1096
- h = {
1097
- opacity: 0
1098
- };
1099
- h[this.vendorPrefix + "transform"] = "scale(" + this.scaleRatio + ")", h[this.vendorPrefix + "transition"] = "opacity " + e + "s", "undefined" != typeof this.data.hideTransition && ("left" === this.data.hideTransition ? g = "-" + d + "px, 0" : "right" === this.data.hideTransition ? g = d + "px, 0" : "up" === this.data.hideTransition ? g = "0, -" + d + "px" : "down" === this.data.hideTransition && (g = "0, " + d + "px"), h[this.vendorPrefix + "transform"] += "css-3d" === this.supportedAnimation ? " translate3d(" + g + ", 0)" : " translate(" + g + ")", h[this.vendorPrefix + "transition"] += ", " + this.vendorPrefix + "transform " + e + "s"), this.$layer.on(this.transitionEvent, function(b) {
1100
- b.target === b.currentTarget && (c.$layer.off(c.transitionEvent).css(c.vendorPrefix + "transition", ""), c.visible === !1 && c.$layer.css("visibility", "hidden"), "undefined" != typeof a && a())
1101
- }), setTimeout(function() {
1102
- c.$layer.css(h)
1103
- }, f)
1104
- }
1105
- }
1106
- },
1107
- isVisible: function() {
1108
- return this.visible === !1 || this.$layer.is(":hidden") ? !1 : !0
1109
- },
1110
- destroy: function() {
1111
- this.$layer.removeAttr("style"), this.$layer.removeAttr("data-init")
1112
- }
1113
- }, b.SliderPro.addModule("Layers", d)
1114
- }(window, jQuery),
1115
- function(a, b) {
1116
- "use strict";
1117
- var c = "Fade." + b.SliderPro.namespace,
1118
- d = {
1119
- fadeGotoSlideReference: null,
1120
- initFade: function() {
1121
- this.on("update." + c, b.proxy(this._fadeOnUpdate, this))
1122
- },
1123
- _fadeOnUpdate: function() {
1124
- this.settings.fade === !0 && (this.fadeGotoSlideReference = this.gotoSlide, this.gotoSlide = this._fadeGotoSlide)
1125
- },
1126
- _fadeGotoSlide: function(a) {
1127
- if (a !== this.selectedSlideIndex)
1128
- if (this.$slider.hasClass("sp-swiping")) this.fadeGotoSlideReference(a);
1129
- else {
1130
- var c, d, e = this,
1131
- f = a;
1132
- b.each(this.slides, function(a, b) {
1133
- var g = b.getIndex(),
1134
- h = b.$slide;
1135
- g === f ? (h.css({
1136
- opacity: 0,
1137
- left: 0,
1138
- top: 0,
1139
- "z-index": 20
1140
- }), c = h) : g === e.selectedSlideIndex ? (h.css({
1141
- opacity: 1,
1142
- left: 0,
1143
- top: 0,
1144
- "z-index": 10
1145
- }), d = h) : h.css("visibility", "hidden")
1146
- }), this.previousSlideIndex = this.selectedSlideIndex, this.selectedSlideIndex = a, e.settings.loop === !0 && e._updateSlidesOrder(), this._moveTo(this.visibleOffset, !0), this.settings.fadeOutPreviousSlide === !0 && this._fadeSlideTo(d, 0), this._fadeSlideTo(c, 1, function() {
1147
- b.each(e.slides, function(a, b) {
1148
- var c = b.$slide;
1149
- c.css({
1150
- visibility: "",
1151
- opacity: "",
1152
- "z-index": ""
1153
- })
1154
- }), e._resetSlidesPosition(), e.trigger({
1155
- type: "gotoSlideComplete",
1156
- index: a,
1157
- previousIndex: e.previousSlideIndex
1158
- }), b.isFunction(e.settings.gotoSlideComplete) && e.settings.gotoSlideComplete.call(e, {
1159
- type: "gotoSlideComplete",
1160
- index: a,
1161
- previousIndex: e.previousSlideIndex
1162
- })
1163
- }), this.settings.autoHeight === !0 && this._resizeHeight(), this.trigger({
1164
- type: "gotoSlide",
1165
- index: a,
1166
- previousIndex: this.previousSlideIndex
1167
- }), b.isFunction(this.settings.gotoSlide) && this.settings.gotoSlide.call(this, {
1168
- type: "gotoSlide",
1169
- index: a,
1170
- previousIndex: this.previousSlideIndex
1171
- })
1172
- }
1173
- },
1174
- _fadeSlideTo: function(a, b, c) {
1175
- var d = this;
1176
- "css-3d" === this.supportedAnimation || "css-2d" === this.supportedAnimation ? (setTimeout(function() {
1177
- var c = {
1178
- opacity: b
1179
- };
1180
- c[d.vendorPrefix + "transition"] = "opacity " + d.settings.fadeDuration / 1e3 + "s", a.css(c)
1181
- }, 1), a.on(this.transitionEvent, function(b) {
1182
- b.target === b.currentTarget && (a.off(d.transitionEvent), a.css(d.vendorPrefix + "transition", ""), "function" == typeof c && c())
1183
- })) : a.stop().animate({
1184
- opacity: b
1185
- }, this.settings.fadeDuration, function() {
1186
- "function" == typeof c && c()
1187
- })
1188
- },
1189
- destroyFade: function() {
1190
- this.off("update." + c), null !== this.fadeGotoSlideReference && (this.gotoSlide = this.fadeGotoSlideReference)
1191
- },
1192
- fadeDefaults: {
1193
- fade: !1,
1194
- fadeOutPreviousSlide: !0,
1195
- fadeDuration: 500
1196
- }
1197
- };
1198
- b.SliderPro.addModule("Fade", d)
1199
- }(window, jQuery),
1200
- function(a, b) {
1201
- "use strict";
1202
- var c = "TouchSwipe." + b.SliderPro.namespace,
1203
- d = {
1204
- isTouchSupport: !1,
1205
- touchStartPoint: {
1206
- x: 0,
1207
- y: 0
1208
- },
1209
- touchEndPoint: {
1210
- x: 0,
1211
- y: 0
1212
- },
1213
- touchDistance: {
1214
- x: 0,
1215
- y: 0
1216
- },
1217
- touchStartPosition: 0,
1218
- isTouchMoving: !1,
1219
- touchSwipeEvents: {
1220
- startEvent: "",
1221
- moveEvent: "",
1222
- endEvent: ""
1223
- },
1224
- initTouchSwipe: function() {
1225
- this.settings.touchSwipe !== !1 && (this.isTouchSupport = "ontouchstart" in a, this.isTouchSupport === !0 ? (this.touchSwipeEvents.startEvent = "touchstart", this.touchSwipeEvents.moveEvent = "touchmove", this.touchSwipeEvents.endEvent = "touchend") : (this.touchSwipeEvents.startEvent = "mousedown", this.touchSwipeEvents.moveEvent = "mousemove", this.touchSwipeEvents.endEvent = "mouseup"), this.$slidesMask.on(this.touchSwipeEvents.startEvent + "." + c, b.proxy(this._onTouchStart, this)), this.$slidesMask.on("dragstart." + c, function(a) {
1226
- a.preventDefault()
1227
- }), this.$slidesMask.addClass("sp-grab"))
1228
- },
1229
- _onTouchStart: function(a) {
1230
- if (!(b(a.target).closest(".sp-selectable").length >= 1)) {
1231
- var d = this.isTouchSupport ? a.originalEvent.touches[0] : a.originalEvent;
1232
- this.isTouchSupport === !1 && a.preventDefault(), b(a.target).parents(".sp-slide").find("a").one("click." + c, function(a) {
1233
- a.preventDefault()
1234
- }), this.touchStartPoint.x = d.pageX || d.clientX, this.touchStartPoint.y = d.pageY || d.clientY, this.touchStartPosition = this.slidesPosition, this.touchDistance.x = this.touchDistance.y = 0, this.$slides.hasClass("sp-animated") && (this.isTouchMoving = !0, this._stopMovement(), this.touchStartPosition = this.slidesPosition), this.$slidesMask.on(this.touchSwipeEvents.moveEvent + "." + c, b.proxy(this._onTouchMove, this)), b(document).on(this.touchSwipeEvents.endEvent + "." + this.uniqueId + "." + c, b.proxy(this._onTouchEnd, this)), this.$slidesMask.removeClass("sp-grab").addClass("sp-grabbing"), this.$slider.addClass("sp-swiping")
1235
- }
1236
- },
1237
- _onTouchMove: function(a) {
1238
- var b = this.isTouchSupport ? a.originalEvent.touches[0] : a.originalEvent;
1239
- this.isTouchMoving = !0, this.touchEndPoint.x = b.pageX || b.clientX, this.touchEndPoint.y = b.pageY || b.clientY, this.touchDistance.x = this.touchEndPoint.x - this.touchStartPoint.x, this.touchDistance.y = this.touchEndPoint.y - this.touchStartPoint.y;
1240
- var c = "horizontal" === this.settings.orientation ? this.touchDistance.x : this.touchDistance.y,
1241
- d = "horizontal" === this.settings.orientation ? this.touchDistance.y : this.touchDistance.x;
1242
- Math.abs(c) > Math.abs(d) && (a.preventDefault(), this.settings.loop === !1 && (this.slidesPosition > this.touchStartPosition && 0 === this.selectedSlideIndex || this.slidesPosition < this.touchStartPosition && this.selectedSlideIndex === this.getTotalSlides() - 1) && (c = .2 * c), this._moveTo(this.touchStartPosition + c, !0))
1243
- },
1244
- _onTouchEnd: function(a) {
1245
- var d = this,
1246
- e = "horizontal" === this.settings.orientation ? this.touchDistance.x : this.touchDistance.y;
1247
- if (this.$slidesMask.off(this.touchSwipeEvents.moveEvent + "." + c), b(document).off(this.touchSwipeEvents.endEvent + "." + this.uniqueId + "." + c), this.$slidesMask.removeClass("sp-grabbing").addClass("sp-grab"), (this.isTouchMoving === !1 || this.isTouchMoving === !0 && Math.abs(this.touchDistance.x) < 10 && Math.abs(this.touchDistance.y) < 10) && (b(a.target).parents(".sp-slide").find("a").off("click." + c), this.$slider.removeClass("sp-swiping")), setTimeout(function() {
1248
- d.$slider.removeClass("sp-swiping")
1249
- }, 1), this.isTouchMoving !== !1) {
1250
- this.isTouchMoving = !1, b(a.target).parents(".sp-slide").one("click", function(a) {
1251
- a.preventDefault()
1252
- });
1253
- var f = -parseInt(this.$slides.find(".sp-slide").eq(this.selectedSlideIndex).css(this.positionProperty), 10) + this.visibleOffset;
1254
- if (Math.abs(e) < this.settings.touchSwipeThreshold) this._moveTo(f);
1255
- else {
1256
- var g = e / (this.slideSize + this.settings.slideDistance);
1257
- g = parseInt(g, 10) + (g > 0 ? 1 : -1);
1258
- var h = this.slidesOrder[b.inArray(this.selectedSlideIndex, this.slidesOrder) - g];
1259
- this.settings.loop === !0 ? this.gotoSlide(h) : "undefined" != typeof h ? this.gotoSlide(h) : this._moveTo(f)
1260
- }
1261
- }
1262
- },
1263
- destroyTouchSwipe: function() {
1264
- this.$slidesMask.off(this.touchSwipeEvents.startEvent + "." + c), this.$slidesMask.off(this.touchSwipeEvents.moveEvent + "." + c), this.$slidesMask.off("dragstart." + c), b(document).off(this.touchSwipeEvents.endEvent + "." + this.uniqueId + "." + c), this.$slidesMask.removeClass("sp-grab")
1265
- },
1266
- touchSwipeDefaults: {
1267
- touchSwipe: !0,
1268
- touchSwipeThreshold: 50
1269
- }
1270
- };
1271
- b.SliderPro.addModule("TouchSwipe", d)
1272
- }(window, jQuery),
1273
- function(a, b) {
1274
- "use strict";
1275
- var c = "Caption." + b.SliderPro.namespace,
1276
- d = {
1277
- $captionContainer: null,
1278
- captionContent: "",
1279
- initCaption: function() {
1280
- this.on("update." + c, b.proxy(this._captionOnUpdate, this)), this.on("gotoSlide." + c, b.proxy(this._updateCaptionContent, this))
1281
- },
1282
- _captionOnUpdate: function() {
1283
- this.$captionContainer = this.$slider.find(".sp-caption-container"), this.$slider.find(".sp-caption").length && 0 === this.$captionContainer.length && (this.$captionContainer = b('<div class="sp-caption-container"></div>').appendTo(this.$slider), this._updateCaptionContent()), this.$slides.find(".sp-caption").each(function() {
1284
- b(this).css("display", "none")
1285
- })
1286
- },
1287
- _updateCaptionContent: function() {
1288
- var a = this,
1289
- b = this.$slider.find(".sp-slide").eq(this.selectedSlideIndex).find(".sp-caption"),
1290
- c = 0 !== b.length ? b.html() : "";
1291
- this.settings.fadeCaption === !0 ? "" !== this.captionContent ? (0 === parseFloat(this.$captionContainer.css("opacity"), 10) && (this.$captionContainer.css(this.vendorPrefix + "transition", ""), this.$captionContainer.css("opacity", 1)), this._fadeCaptionTo(0, function() {
1292
- a.captionContent = c, "" !== c ? (a.$captionContainer.html(a.captionContent), a._fadeCaptionTo(1)) : a.$captionContainer.empty()
1293
- })) : (this.captionContent = c, this.$captionContainer.html(this.captionContent), this.$captionContainer.css("opacity", 0), this._fadeCaptionTo(1)) : (this.captionContent = c, this.$captionContainer.html(this.captionContent))
1294
- },
1295
- _fadeCaptionTo: function(a, b) {
1296
- var c = this;
1297
- "css-3d" === this.supportedAnimation || "css-2d" === this.supportedAnimation ? (setTimeout(function() {
1298
- var b = {
1299
- opacity: a
1300
- };
1301
- b[c.vendorPrefix + "transition"] = "opacity " + c.settings.captionFadeDuration / 1e3 + "s", c.$captionContainer.css(b)
1302
- }, 1), this.$captionContainer.on(this.transitionEvent, function(a) {
1303
- a.target === a.currentTarget && (c.$captionContainer.off(c.transitionEvent), c.$captionContainer.css(c.vendorPrefix + "transition", ""), "function" == typeof b && b())
1304
- })) : this.$captionContainer.stop().animate({
1305
- opacity: a
1306
- }, this.settings.captionFadeDuration, function() {
1307
- "function" == typeof b && b()
1308
- })
1309
- },
1310
- destroyCaption: function() {
1311
- this.off("update." + c), this.off("gotoSlide." + c), this.$captionContainer.remove(), this.$slider.find(".sp-caption").each(function() {
1312
- b(this).css("display", "")
1313
- })
1314
- },
1315
- captionDefaults: {
1316
- fadeCaption: !0,
1317
- captionFadeDuration: 500
1318
- }
1319
- };
1320
- b.SliderPro.addModule("Caption", d)
1321
- }(window, jQuery),
1322
- function(a, b) {
1323
- "use strict";
1324
- var c = "DeepLinking." + b.SliderPro.namespace,
1325
- d = {
1326
- initDeepLinking: function() {
1327
- var d = this,
1328
- e = !0;
1329
- this.on("init." + c, function() {
1330
- d._gotoHash(a.location.hash)
1331
- }), this.on("gotoSlide." + c, function(b) {
1332
- e = !1, d.settings.updateHash === !0 && (a.location.hash = d.$slider.attr("id") + "/" + b.index)
1333
- }), b(a).on("hashchange." + this.uniqueId + "." + c, function() {
1334
- e === !0 && d._gotoHash(a.location.hash), e = !0
1335
- })
1336
- },
1337
- _parseHash: function(a) {
1338
- if ("" !== a) {
1339
- a = a.substring(1);
1340
- var b = a.split("/"),
1341
- c = b.pop(),
1342
- d = a.slice(0, -c.toString().length - 1);
1343
- if (this.$slider.attr("id") === d) return {
1344
- sliderID: d,
1345
- slideId: c
1346
- }
1347
- }
1348
- return !1
1349
- },
1350
- _gotoHash: function(a) {
1351
- var b = this._parseHash(a);
1352
- if (b !== !1) {
1353
- var c = b.slideId,
1354
- d = parseInt(c, 10);
1355
- if (isNaN(d)) {
1356
- var e = this.$slider.find(".sp-slide#" + c).index(); - 1 !== e && this.gotoSlide(e)
1357
- } else this.gotoSlide(d)
1358
- }
1359
- },
1360
- destroyDeepLinking: function() {
1361
- this.off("init." + c), this.off("gotoSlide." + c), b(a).off("hashchange." + this.uniqueId + "." + c)
1362
- },
1363
- deepLinkingDefaults: {
1364
- updateHash: !1
1365
- }
1366
- };
1367
- b.SliderPro.addModule("DeepLinking", d)
1368
- }(window, jQuery),
1369
- function(a, b) {
1370
- "use strict";
1371
- var c = "Autoplay." + b.SliderPro.namespace,
1372
- d = {
1373
- autoplayTimer: null,
1374
- isTimerRunning: !1,
1375
- isTimerPaused: !1,
1376
- initAutoplay: function() {
1377
- this.on("update." + c, b.proxy(this._autoplayOnUpdate, this))
1378
- },
1379
- _autoplayOnUpdate: function() {
1380
- this.settings.autoplay === !0 ? (this.on("gotoSlide." + c, b.proxy(this._autoplayOnGotoSlide, this)), this.on("mouseenter." + c, b.proxy(this._autoplayOnMouseEnter, this)), this.on("mouseleave." + c, b.proxy(this._autoplayOnMouseLeave, this)), this.startAutoplay()) : (this.off("gotoSlide." + c), this.off("mouseenter." + c), this.off("mouseleave." + c), this.stopAutoplay())
1381
- },
1382
- _autoplayOnGotoSlide: function() {
1383
- this.isTimerRunning === !0 && this.stopAutoplay(), this.isTimerPaused === !1 && this.startAutoplay()
1384
- },
1385
- _autoplayOnMouseEnter: function() {
1386
- !this.isTimerRunning || "pause" !== this.settings.autoplayOnHover && "stop" !== this.settings.autoplayOnHover || (this.stopAutoplay(), this.isTimerPaused = !0)
1387
- },
1388
- _autoplayOnMouseLeave: function() {
1389
- this.settings.autoplay === !0 && this.isTimerRunning === !1 && "stop" !== this.settings.autoplayOnHover && (this.startAutoplay(), this.isTimerPaused = !1)
1390
- },
1391
- startAutoplay: function() {
1392
- var a = this;
1393
- this.isTimerRunning = !0, this.autoplayTimer = setTimeout(function() {
1394
- "normal" === a.settings.autoplayDirection ? a.nextSlide() : "backwards" === a.settings.autoplayDirection && a.previousSlide()
1395
- }, this.settings.autoplayDelay)
1396
- },
1397
- stopAutoplay: function() {
1398
- this.isTimerRunning = !1, clearTimeout(this.autoplayTimer)
1399
- },
1400
- destroyAutoplay: function() {
1401
- clearTimeout(this.autoplayTimer), this.off("update." + c), this.off("gotoSlide." + c), this.off("mouseenter." + c), this.off("mouseleave." + c)
1402
- },
1403
- autoplayDefaults: {
1404
- autoplay: !0,
1405
- autoplayDelay: 5e3,
1406
- autoplayDirection: "normal",
1407
- autoplayOnHover: "pause"
1408
- }
1409
- };
1410
- b.SliderPro.addModule("Autoplay", d)
1411
- }(window, jQuery),
1412
- function(a, b) {
1413
- "use strict";
1414
- var c = "Keyboard." + b.SliderPro.namespace,
1415
- d = {
1416
- initKeyboard: function() {
1417
- var a = this,
1418
- d = !1;
1419
- this.settings.keyboard !== !1 && (this.$slider.on("focus." + c, function() {
1420
- d = !0
1421
- }), this.$slider.on("blur." + c, function() {
1422
- d = !1
1423
- }), b(document).on("keydown." + this.uniqueId + "." + c, function(b) {
1424
- (a.settings.keyboardOnlyOnFocus !== !0 || d !== !1) && (37 === b.which ? a.previousSlide() : 39 === b.which ? a.nextSlide() : 13 === b.which && a.$slider.find(".sp-slide").eq(a.selectedSlideIndex).find(".sp-image-container a")[0].click())
1425
- }))
1426
- },
1427
- destroyKeyboard: function() {
1428
- this.$slider.off("focus." + c), this.$slider.off("blur." + c), b(document).off("keydown." + this.uniqueId + "." + c)
1429
- },
1430
- keyboardDefaults: {
1431
- keyboard: !0,
1432
- keyboardOnlyOnFocus: !1
1433
- }
1434
- };
1435
- b.SliderPro.addModule("Keyboard", d)
1436
- }(window, jQuery),
1437
- function(a, b) {
1438
- "use strict";
1439
- var c = "FullScreen." + b.SliderPro.namespace,
1440
- d = {
1441
- isFullScreen: !1,
1442
- $fullScreenButton: null,
1443
- sizeBeforeFullScreen: {},
1444
- initFullScreen: function() {
1445
- (document.fullscreenEnabled || document.webkitFullscreenEnabled || document.mozFullScreenEnabled || document.msFullscreenEnabled) && this.on("update." + c, b.proxy(this._fullScreenOnUpdate, this))
1446
- },
1447
- _fullScreenOnUpdate: function() {
1448
- this.settings.fullScreen === !0 && null === this.$fullScreenButton ? this._addFullScreen() : this.settings.fullScreen === !1 && null !== this.$fullScreenButton && this._removeFullScreen(), this.settings.fullScreen === !0 && (this.settings.fadeFullScreen === !0 ? this.$fullScreenButton.addClass("sp-fade-full-screen") : this.settings.fadeFullScreen === !1 && this.$fullScreenButton.removeClass("sp-fade-full-screen"))
1449
- },
1450
- _addFullScreen: function() {
1451
- this.$fullScreenButton = b('<div class="sp-full-screen-button"></div>').appendTo(this.$slider), this.$fullScreenButton.on("click." + c, b.proxy(this._onFullScreenButtonClick, this)), document.addEventListener("fullscreenchange", b.proxy(this._onFullScreenChange, this)), document.addEventListener("mozfullscreenchange", b.proxy(this._onFullScreenChange, this)), document.addEventListener("webkitfullscreenchange", b.proxy(this._onFullScreenChange, this)), document.addEventListener("MSFullscreenChange", b.proxy(this._onFullScreenChange, this))
1452
- },
1453
- _removeFullScreen: function() {
1454
- null !== this.$fullScreenButton && (this.$fullScreenButton.off("click." + c), this.$fullScreenButton.remove(), this.$fullScreenButton = null, document.removeEventListener("fullscreenchange", this._onFullScreenChange), document.removeEventListener("mozfullscreenchange", this._onFullScreenChange), document.removeEventListener("webkitfullscreenchange", this._onFullScreenChange), document.removeEventListener("MSFullscreenChange", this._onFullScreenChange))
1455
- },
1456
- _onFullScreenButtonClick: function() {
1457
- this.isFullScreen === !1 ? this.instance.requestFullScreen ? this.instance.requestFullScreen() : this.instance.mozRequestFullScreen ? this.instance.mozRequestFullScreen() : this.instance.webkitRequestFullScreen ? this.instance.webkitRequestFullScreen() : this.instance.msRequestFullscreen && this.instance.msRequestFullscreen() : document.exitFullScreen ? document.exitFullScreen() : document.mozCancelFullScreen ? document.mozCancelFullScreen() : document.webkitCancelFullScreen ? document.webkitCancelFullScreen() : document.msExitFullscreen && document.msExitFullscreen()
1458
- },
1459
- _onFullScreenChange: function() {
1460
- this.isFullScreen = document.fullscreenElement || document.webkitFullscreenElement || document.mozFullScreenElement || document.msFullscreenElement ? !0 : !1, this.isFullScreen === !0 ? (this.sizeBeforeFullScreen = {
1461
- forceSize: this.settings.forceSize,
1462
- autoHeight: this.settings.autoHeight
1463
- }, this.$slider.addClass("sp-full-screen"), this.settings.forceSize = "fullWindow", this.settings.autoHeight = !1) : (this.$slider.css("margin", ""), this.$slider.removeClass("sp-full-screen"), this.settings.forceSize = this.sizeBeforeFullScreen.forceSize, this.settings.autoHeight = this.sizeBeforeFullScreen.autoHeight), this.resize()
1464
- },
1465
- destroyFullScreen: function() {
1466
- this.off("update." + c), this._removeFullScreen()
1467
- },
1468
- fullScreenDefaults: {
1469
- fullScreen: !1,
1470
- fadeFullScreen: !0
1471
- }
1472
- };
1473
- b.SliderPro.addModule("FullScreen", d)
1474
- }(window, jQuery),
1475
- function(a, b) {
1476
- "use strict";
1477
- var c = "Buttons." + b.SliderPro.namespace,
1478
- d = {
1479
- $buttons: null,
1480
- initButtons: function() {
1481
- this.on("update." + c, b.proxy(this._buttonsOnUpdate, this))
1482
- },
1483
- _buttonsOnUpdate: function() {
1484
- this.$buttons = this.$slider.find(".sp-buttons"), this.settings.buttons === !0 && this.getTotalSlides() > 1 && 0 === this.$buttons.length ? this._createButtons() : this.settings.buttons === !0 && this.getTotalSlides() !== this.$buttons.find(".sp-button").length && 0 !== this.$buttons.length ? this._adjustButtons() : (this.settings.buttons === !1 || this.getTotalSlides() <= 1 && 0 !== this.$buttons.length) && this._removeButtons()
1485
- },
1486
- _createButtons: function() {
1487
- var a = this;
1488
- this.$buttons = b('<div class="sp-buttons"></div>').appendTo(this.$slider);
1489
- for (var d = 0; d < this.getTotalSlides(); d++) b('<div class="sp-button"></div>').appendTo(this.$buttons);
1490
- this.$buttons.on("click." + c, ".sp-button", function() {
1491
- a.gotoSlide(b(this).index())
1492
- }), this.$buttons.find(".sp-button").eq(this.selectedSlideIndex).addClass("sp-selected-button"), this.on("gotoSlide." + c, function(b) {
1493
- a.$buttons.find(".sp-selected-button").removeClass("sp-selected-button"), a.$buttons.find(".sp-button").eq(b.index).addClass("sp-selected-button")
1494
- }), this.$slider.addClass("sp-has-buttons")
1495
- },
1496
- _adjustButtons: function() {
1497
- this.$buttons.empty();
1498
- for (var a = 0; a < this.getTotalSlides(); a++) b('<div class="sp-button"></div>').appendTo(this.$buttons);
1499
- this.$buttons.find(".sp-selected-button").removeClass("sp-selected-button"), this.$buttons.find(".sp-button").eq(this.selectedSlideIndex).addClass("sp-selected-button")
1500
- },
1501
- _removeButtons: function() {
1502
- this.$buttons.off("click." + c, ".sp-button"), this.off("gotoSlide." + c), this.$buttons.remove(), this.$slider.removeClass("sp-has-buttons")
1503
- },
1504
- destroyButtons: function() {
1505
- this._removeButtons(), this.off("update." + c)
1506
- },
1507
- buttonsDefaults: {
1508
- buttons: !0
1509
- }
1510
- };
1511
- b.SliderPro.addModule("Buttons", d)
1512
- }(window, jQuery),
1513
- function(a, b) {
1514
- "use strict";
1515
- var c = "Arrows." + b.SliderPro.namespace,
1516
- d = {
1517
- $arrows: null,
1518
- $previousArrow: null,
1519
- $nextArrow: null,
1520
- initArrows: function() {
1521
- this.on("update." + c, b.proxy(this._arrowsOnUpdate, this)), this.on("gotoSlide." + c, b.proxy(this._checkArrowsVisibility, this))
1522
- },
1523
- _arrowsOnUpdate: function() {
1524
- var a = this;
1525
- this.settings.arrows === !0 && null === this.$arrows ? (this.$arrows = b('<div class="sp-arrows"></div>').appendTo(this.$slidesContainer), this.$previousArrow = b('<div class="sp-arrow sp-previous-arrow"></div>').appendTo(this.$arrows), this.$nextArrow = b('<div class="sp-arrow sp-next-arrow"></div>').appendTo(this.$arrows), this.$previousArrow.on("click." + c, function() {
1526
- a.previousSlide()
1527
- }), this.$nextArrow.on("click." + c, function() {
1528
- a.nextSlide()
1529
- }), this._checkArrowsVisibility()) : this.settings.arrows === !1 && null !== this.$arrows && this._removeArrows(), this.settings.arrows === !0 && (this.settings.fadeArrows === !0 ? this.$arrows.addClass("sp-fade-arrows") : this.settings.fadeArrows === !1 && this.$arrows.removeClass("sp-fade-arrows"))
1530
- },
1531
- _checkArrowsVisibility: function() {
1532
- this.settings.arrows !== !1 && this.settings.loop !== !0 && (0 === this.selectedSlideIndex ? this.$previousArrow.css("display", "none") : this.$previousArrow.css("display", "block"), this.selectedSlideIndex === this.getTotalSlides() - 1 ? this.$nextArrow.css("display", "none") : this.$nextArrow.css("display", "block"))
1533
- },
1534
- _removeArrows: function() {
1535
- null !== this.$arrows && (this.$previousArrow.off("click." + c), this.$nextArrow.off("click." + c), this.$arrows.remove(), this.$arrows = null)
1536
- },
1537
- destroyArrows: function() {
1538
- this._removeArrows(), this.off("update." + c), this.off("gotoSlide." + c)
1539
- },
1540
- arrowsDefaults: {
1541
- arrows: !1,
1542
- fadeArrows: !0
1543
- }
1544
- };
1545
- b.SliderPro.addModule("Arrows", d)
1546
- }(window, jQuery),
1547
- function(a, b) {
1548
- "use strict";
1549
- var c = "ThumbnailTouchSwipe." + b.SliderPro.namespace,
1550
- d = {
1551
- isThumbnailTouchSupport: !1,
1552
- thumbnailTouchStartPoint: {
1553
- x: 0,
1554
- y: 0
1555
- },
1556
- thumbnailTouchEndPoint: {
1557
- x: 0,
1558
- y: 0
1559
- },
1560
- thumbnailTouchDistance: {
1561
- x: 0,
1562
- y: 0
1563
- },
1564
- thumbnailTouchStartPosition: 0,
1565
- isThumbnailTouchMoving: !1,
1566
- isThumbnailTouchSwipe: !1,
1567
- thumbnailTouchSwipeEvents: {
1568
- startEvent: "",
1569
- moveEvent: "",
1570
- endEvent: ""
1571
- },
1572
- initThumbnailTouchSwipe: function() {
1573
- this.on("update." + c, b.proxy(this._thumbnailTouchSwipeOnUpdate, this))
1574
- },
1575
- _thumbnailTouchSwipeOnUpdate: function() {
1576
- this.isThumbnailScroller !== !1 && (this.settings.thumbnailTouchSwipe === !0 && this.isThumbnailTouchSwipe === !1 && (this.isThumbnailTouchSwipe = !0, this.isThumbnailTouchSupport = "ontouchstart" in a, this.isThumbnailTouchSupport === !0 ? (this.thumbnailTouchSwipeEvents.startEvent = "touchstart", this.thumbnailTouchSwipeEvents.moveEvent = "touchmove", this.thumbnailTouchSwipeEvents.endEvent = "touchend") : (this.thumbnailTouchSwipeEvents.startEvent = "mousedown", this.thumbnailTouchSwipeEvents.moveEvent = "mousemove", this.thumbnailTouchSwipeEvents.endEvent = "mouseup"), this.$thumbnails.on(this.thumbnailTouchSwipeEvents.startEvent + "." + c, b.proxy(this._onThumbnailTouchStart, this)), this.$thumbnails.on("dragstart." + c, function(a) {
1577
- a.preventDefault()
1578
- }), this.$thumbnails.addClass("sp-grab")), b.each(this.thumbnails, function(a, b) {
1579
- b.off("thumbnailClick")
1580
- }))
1581
- },
1582
- _onThumbnailTouchStart: function(a) {
1583
- if (!(b(a.target).closest(".sp-selectable").length >= 1)) {
1584
- var d = this.isThumbnailTouchSupport ? a.originalEvent.touches[0] : a.originalEvent;
1585
- this.isThumbnailTouchSupport === !1 && a.preventDefault(), b(a.target).parents(".sp-thumbnail-container").find("a").one("click." + c, function(a) {
1586
- a.preventDefault()
1587
- }), this.thumbnailTouchStartPoint.x = d.pageX || d.clientX, this.thumbnailTouchStartPoint.y = d.pageY || d.clientY, this.thumbnailTouchStartPosition = this.thumbnailsPosition, this.thumbnailTouchDistance.x = this.thumbnailTouchDistance.y = 0, this.$thumbnails.hasClass("sp-animated") && (this.isThumbnailTouchMoving = !0, this._stopThumbnailsMovement(), this.thumbnailTouchStartPosition = this.thumbnailsPosition), this.$thumbnails.on(this.thumbnailTouchSwipeEvents.moveEvent + "." + c, b.proxy(this._onThumbnailTouchMove, this)), b(document).on(this.thumbnailTouchSwipeEvents.endEvent + "." + this.uniqueId + "." + c, b.proxy(this._onThumbnailTouchEnd, this)), this.$thumbnails.removeClass("sp-grab").addClass("sp-grabbing"), this.$thumbnailsContainer.addClass("sp-swiping")
1588
- }
1589
- },
1590
- _onThumbnailTouchMove: function(a) {
1591
- var b = this.isThumbnailTouchSupport ? a.originalEvent.touches[0] : a.originalEvent;
1592
- this.isThumbnailTouchMoving = !0, this.thumbnailTouchEndPoint.x = b.pageX || b.clientX, this.thumbnailTouchEndPoint.y = b.pageY || b.clientY, this.thumbnailTouchDistance.x = this.thumbnailTouchEndPoint.x - this.thumbnailTouchStartPoint.x, this.thumbnailTouchDistance.y = this.thumbnailTouchEndPoint.y - this.thumbnailTouchStartPoint.y;
1593
- var c = "horizontal" === this.thumbnailsOrientation ? this.thumbnailTouchDistance.x : this.thumbnailTouchDistance.y,
1594
- d = "horizontal" === this.thumbnailsOrientation ? this.thumbnailTouchDistance.y : this.thumbnailTouchDistance.x;
1595
- if (Math.abs(c) > Math.abs(d)) {
1596
- if (a.preventDefault(), this.thumbnailsPosition >= 0) {
1597
- var e = -this.thumbnailTouchStartPosition;
1598
- c = e + .2 * (c - e)
1599
- } else if (this.thumbnailsPosition <= -this.thumbnailsSize + this.thumbnailsContainerSize) {
1600
- var f = this.thumbnailsSize - this.thumbnailsContainerSize + this.thumbnailTouchStartPosition;
1601
- c = -f + .2 * (c + f)
1602
- }
1603
- this._moveThumbnailsTo(this.thumbnailTouchStartPosition + c, !0)
1604
- }
1605
- },
1606
- _onThumbnailTouchEnd: function(a) {
1607
- {
1608
- var d = this;
1609
- "horizontal" === this.thumbnailsOrientation ? this.thumbnailTouchDistance.x : this.thumbnailTouchDistance.y
1610
- }
1611
- if (this.$thumbnails.off(this.thumbnailTouchSwipeEvents.moveEvent + "." + c), b(document).off(this.thumbnailTouchSwipeEvents.endEvent + "." + this.uniqueId + "." + c), this.$thumbnails.removeClass("sp-grabbing").addClass("sp-grab"), this.isThumbnailTouchMoving === !1 || this.isThumbnailTouchMoving === !0 && Math.abs(this.thumbnailTouchDistance.x) < 10 && Math.abs(this.thumbnailTouchDistance.y) < 10) {
1612
- var e = b(a.target).hasClass("sp-thumbnail-container") ? b(a.target) : b(a.target).parents(".sp-thumbnail-container"),
1613
- f = e.index();
1614
- return void(0 !== b(a.target).parents("a").length ? (b(a.target).parents("a").off("click." + c), this.$thumbnailsContainer.removeClass("sp-swiping")) : f !== this.selectedThumbnailIndex && -1 !== f && this.gotoSlide(f))
1615
- }
1616
- this.isThumbnailTouchMoving = !1, b(a.target).parents(".sp-thumbnail").one("click", function(a) {
1617
- a.preventDefault()
1618
- }), setTimeout(function() {
1619
- d.$thumbnailsContainer.removeClass("sp-swiping")
1620
- }, 1), this.thumbnailsPosition > 0 ? this._moveThumbnailsTo(0) : this.thumbnailsPosition < this.thumbnailsContainerSize - this.thumbnailsSize && this._moveThumbnailsTo(this.thumbnailsContainerSize - this.thumbnailsSize), this.trigger({
1621
- type: "thumbnailsMoveComplete"
1622
- }), b.isFunction(this.settings.thumbnailsMoveComplete) && this.settings.thumbnailsMoveComplete.call(this, {
1623
- type: "thumbnailsMoveComplete"
1624
- })
1625
- },
1626
- destroyThumbnailTouchSwipe: function() {
1627
- this.off("update." + c), this.isThumbnailScroller !== !1 && (this.$thumbnails.off(this.thumbnailTouchSwipeEvents.startEvent + "." + c), this.$thumbnails.off(this.thumbnailTouchSwipeEvents.moveEvent + "." + c), this.$thumbnails.off("dragstart." + c), b(document).off(this.thumbnailTouchSwipeEvents.endEvent + "." + this.uniqueId + "." + c), this.$thumbnails.removeClass("sp-grab"))
1628
- },
1629
- thumbnailTouchSwipeDefaults: {
1630
- thumbnailTouchSwipe: !0
1631
- }
1632
- };
1633
- b.SliderPro.addModule("ThumbnailTouchSwipe", d)
1634
- }(window, jQuery),
1635
- function(a, b) {
1636
- "use strict";
1637
- var c = "ThumbnailArrows." + b.SliderPro.namespace,
1638
- d = {
1639
- $thumbnailArrows: null,
1640
- $previousThumbnailArrow: null,
1641
- $nextThumbnailArrow: null,
1642
- initThumbnailArrows: function() {
1643
- var a = this;
1644
- this.on("update." + c, b.proxy(this._thumbnailArrowsOnUpdate, this)), this.on("sliderResize." + c + " thumbnailsMoveComplete." + c, function() {
1645
- a.isThumbnailScroller === !0 && a.settings.thumbnailArrows === !0 && a._checkThumbnailArrowsVisibility()
1646
- })
1647
- },
1648
- _thumbnailArrowsOnUpdate: function() {
1649
- var a = this;
1650
- this.isThumbnailScroller !== !1 && (this.settings.thumbnailArrows === !0 && null === this.$thumbnailArrows ? (this.$thumbnailArrows = b('<div class="sp-thumbnail-arrows"></div>').appendTo(this.$thumbnailsContainer), this.$previousThumbnailArrow = b('<div class="sp-thumbnail-arrow sp-previous-thumbnail-arrow"></div>').appendTo(this.$thumbnailArrows), this.$nextThumbnailArrow = b('<div class="sp-thumbnail-arrow sp-next-thumbnail-arrow"></div>').appendTo(this.$thumbnailArrows), this.$previousThumbnailArrow.on("click." + c, function() {
1651
- var b = Math.min(0, a.thumbnailsPosition + a.thumbnailsContainerSize);
1652
- a._moveThumbnailsTo(b)
1653
- }), this.$nextThumbnailArrow.on("click." + c, function() {
1654
- var b = Math.max(a.thumbnailsContainerSize - a.thumbnailsSize, a.thumbnailsPosition - a.thumbnailsContainerSize);
1655
- a._moveThumbnailsTo(b)
1656
- })) : this.settings.thumbnailArrows === !1 && null !== this.$thumbnailArrows && this._removeThumbnailArrows(), this.settings.thumbnailArrows === !0 && (this.settings.fadeThumbnailArrows === !0 ? this.$thumbnailArrows.addClass("sp-fade-thumbnail-arrows") : this.settings.fadeThumbnailArrows === !1 && this.$thumbnailArrows.removeClass("sp-fade-thumbnail-arrows"), this._checkThumbnailArrowsVisibility()))
1657
- },
1658
- _checkThumbnailArrowsVisibility: function() {
1659
- 0 === this.thumbnailsPosition ? this.$previousThumbnailArrow.css("display", "none") : this.$previousThumbnailArrow.css("display", "block"), this.thumbnailsPosition === this.thumbnailsContainerSize - this.thumbnailsSize ? this.$nextThumbnailArrow.css("display", "none") : this.$nextThumbnailArrow.css("display", "block")
1660
- },
1661
- _removeThumbnailArrows: function() {
1662
- null !== this.$thumbnailArrows && (this.$previousThumbnailArrow.off("click." + c), this.$nextThumbnailArrow.off("click." + c), this.$thumbnailArrows.remove(), this.$thumbnailArrows = null)
1663
- },
1664
- destroyThumbnailArrows: function() {
1665
- this._removeThumbnailArrows(), this.off("update." + c), this.off("sliderResize." + c), this.off("thumbnailsMoveComplete." + c)
1666
- },
1667
- thumbnailArrowsDefaults: {
1668
- thumbnailArrows: !1,
1669
- fadeThumbnailArrows: !0
1670
- }
1671
- };
1672
- b.SliderPro.addModule("ThumbnailArrows", d)
1673
- }(window, jQuery),
1674
- function(a, b) {
1675
- "use strict";
1676
- var c = "Video." + b.SliderPro.namespace,
1677
- d = {
1678
- initVideo: function() {
1679
- this.on("update." + c, b.proxy(this._videoOnUpdate, this)), this.on("gotoSlideComplete." + c, b.proxy(this._videoOnGotoSlideComplete, this))
1680
- },
1681
- _videoOnUpdate: function() {
1682
- var a = this;
1683
- this.$slider.find(".sp-video").not("a, [data-init]").each(function() {
1684
- var c = b(this);
1685
- a._initVideo(c)
1686
- }), this.$slider.find("a.sp-video").not("[data-preinit]").each(function() {
1687
- var c = b(this);
1688
- a._preinitVideo(c)
1689
- })
1690
- },
1691
- _initVideo: function(a) {
1692
- var d = this;
1693
- a.attr("data-init", !0).videoController(), a.on("videoPlay." + c, function() {
1694
- "stopAutoplay" === d.settings.playVideoAction && "undefined" != typeof d.stopAutoplay && (d.stopAutoplay(), d.settings.autoplay = !1);
1695
- var c = {
1696
- type: "videoPlay",
1697
- video: a
1698
- };
1699
- d.trigger(c), b.isFunction(d.settings.videoPlay) && d.settings.videoPlay.call(d, c)
1700
- }), a.on("videoPause." + c, function() {
1701
- "startAutoplay" === d.settings.pauseVideoAction && "undefined" != typeof d.startAutoplay && (d.startAutoplay(), d.settings.autoplay = !0);
1702
- var c = {
1703
- type: "videoPause",
1704
- video: a
1705
- };
1706
- d.trigger(c), b.isFunction(d.settings.videoPause) && d.settings.videoPause.call(d, c)
1707
- }), a.on("videoEnded." + c, function() {
1708
- "startAutoplay" === d.settings.endVideoAction && "undefined" != typeof d.startAutoplay ? (d.startAutoplay(), d.settings.autoplay = !0) : "nextSlide" === d.settings.endVideoAction ? d.nextSlide() : "replayVideo" === d.settings.endVideoAction && a.videoController("replay");
1709
- var c = {
1710
- type: "videoEnd",
1711
- video: a
1712
- };
1713
- d.trigger(c), b.isFunction(d.settings.videoEnd) && d.settings.videoEnd.call(d, c)
1714
- })
1715
- },
1716
- _preinitVideo: function(a) {
1717
- var d = this;
1718
- a.attr("data-preinit", !0), a.on("click." + c, function(c) {
1719
- if (!d.$slider.hasClass("sp-swiping")) {
1720
- c.preventDefault();
1721
- var e, f, g, h, i, j, k, l = a.attr("href"),
1722
- m = a.children("img").attr("width"),
1723
- n = a.children("img").attr("height"); - 1 !== l.indexOf("youtube") || -1 !== l.indexOf("youtu.be") ? f = "youtube" : -1 !== l.indexOf("vimeo") && (f = "vimeo"), g = "youtube" === f ? /^.*(youtu.be\/|v\/|u\/\w\/|embed\/|watch\?v=|\&v=)([^#\&\?]*).*/ : /http:\/\/(www\.)?vimeo.com\/(\d+)/, h = l.match(g), i = h[2], j = "youtube" === f ? "http://www.youtube.com/embed/" + i + "?enablejsapi=1&wmode=opaque" : "http://player.vimeo.com/video/" + i + "?api=1", k = l.split("?")[1], "undefined" != typeof k && (k = k.split("&"), b.each(k, function(a, b) {
1724
- -1 === b.indexOf(i) && (j += "&" + b)
1725
- })), e = b("<iframe></iframe>").attr({
1726
- src: j,
1727
- width: m,
1728
- height: n,
1729
- "class": a.attr("class"),
1730
- frameborder: 0
1731
- }).insertBefore(a), d._initVideo(e), e.videoController("play"), a.css("display", "none")
1732
- }
1733
- })
1734
- },
1735
- _videoOnGotoSlideComplete: function(a) {
1736
- var b = this.$slides.find(".sp-slide").eq(a.previousIndex).find(".sp-video[data-init]");
1737
- if (-1 !== a.previousIndex && 0 !== b.length && ("stopVideo" === this.settings.leaveVideoAction ? b.videoController("stop") : "pauseVideo" === this.settings.leaveVideoAction ? b.videoController("pause") : "removeVideo" === this.settings.leaveVideoAction && (0 !== b.siblings("a.sp-video").length ? (b.siblings("a.sp-video").css("display", ""), b.videoController("destroy"), b.remove()) : b.videoController("stop"))), "playVideo" === this.settings.reachVideoAction) {
1738
- var d = this.$slides.find(".sp-slide").eq(a.index).find(".sp-video[data-init]"),
1739
- e = this.$slides.find(".sp-slide").eq(a.index).find(".sp-video[data-preinit]");
1740
- 0 !== d.length ? d.videoController("play") : 0 !== e.length && e.trigger("click." + c)
1741
- }
1742
- },
1743
- destroyVideo: function() {
1744
- this.$slider.find(".sp-video[ data-preinit ]").each(function() {
1745
- var a = b(this);
1746
- a.removeAttr("data-preinit"), a.off("click." + c)
1747
- }), this.$slider.find(".sp-video[ data-init ]").each(function() {
1748
- var a = b(this);
1749
- a.removeAttr("data-init"), a.off("Video"), a.videoController("destroy")
1750
- }), this.off("update." + c), this.off("gotoSlideComplete." + c)
1751
- },
1752
- videoDefaults: {
1753
- reachVideoAction: "none",
1754
- leaveVideoAction: "pauseVideo",
1755
- playVideoAction: "stopAutoplay",
1756
- pauseVideoAction: "none",
1757
- endVideoAction: "none",
1758
- videoPlay: function() {},
1759
- videoPause: function() {},
1760
- videoEnd: function() {}
1761
- }
1762
- };
1763
- b.SliderPro.addModule("Video", d)
1764
- }(window, jQuery),
1765
- function(a) {
1766
- "use strict";
1767
- var b = window.navigator.userAgent.match(/(iPad|iPhone|iPod)/g) ? !0 : !1,
1768
- c = function(b, c) {
1769
- this.$video = a(b), this.options = c, this.settings = {}, this.player = null, this._init()
1770
- };
1771
- c.prototype = {
1772
- _init: function() {
1773
- this.settings = a.extend({}, this.defaults, this.options);
1774
- var b = this,
1775
- c = a.VideoController.players,
1776
- d = this.$video.attr("id");
1777
- for (var e in c)
1778
- if ("undefined" != typeof c[e] && c[e].isType(this.$video)) {
1779
- this.player = new c[e](this.$video);
1780
- break
1781
- }
1782
- if (null !== this.player) {
1783
- var f = ["ready", "start", "play", "pause", "ended"];
1784
- a.each(f, function(c, e) {
1785
- var f = "video" + e.charAt(0).toUpperCase() + e.slice(1);
1786
- b.player.on(e, function() {
1787
- b.trigger({
1788
- type: f,
1789
- video: d
1790
- }), a.isFunction(b.settings[f]) && b.settings[f].call(b, {
1791
- type: f,
1792
- video: d
1793
- })
1794
- })
1795
- })
1796
- }
1797
- },
1798
- play: function() {
1799
- b === !0 && this.player.isStarted() === !1 || "playing" === this.player.getState() || this.player.play()
1800
- },
1801
- stop: function() {
1802
- b === !0 && this.player.isStarted() === !1 || "stopped" === this.player.getState() || this.player.stop()
1803
- },
1804
- pause: function() {
1805
- b === !0 && this.player.isStarted() === !1 || "paused" === this.player.getState() || this.player.pause()
1806
- },
1807
- replay: function() {
1808
- (b !== !0 || this.player.isStarted() !== !1) && this.player.replay()
1809
- },
1810
- on: function(a, b) {
1811
- return this.$video.on(a, b)
1812
- },
1813
- off: function(a) {
1814
- return this.$video.off(a)
1815
- },
1816
- trigger: function(a) {
1817
- return this.$video.triggerHandler(a)
1818
- },
1819
- destroy: function() {
1820
- this.player.isStarted() === !0 && this.stop(), this.player.off("ready"), this.player.off("start"), this.player.off("play"), this.player.off("pause"), this.player.off("ended"), this.$video.removeData("videoController")
1821
- },
1822
- defaults: {
1823
- videoReady: function() {},
1824
- videoStart: function() {},
1825
- videoPlay: function() {},
1826
- videoPause: function() {},
1827
- videoEnded: function() {}
1828
- }
1829
- }, a.VideoController = {
1830
- players: {},
1831
- addPlayer: function(a, b) {
1832
- this.players[a] = b
1833
- }
1834
- }, a.fn.videoController = function(b) {
1835
- var d = Array.prototype.slice.call(arguments, 1);
1836
- return this.each(function() {
1837
- if ("undefined" == typeof a(this).data("videoController")) {
1838
- var e = new c(this, b);
1839
- a(this).data("videoController", e)
1840
- } else if ("undefined" != typeof b) {
1841
- var f = a(this).data("videoController");
1842
- "function" == typeof f[b] ? f[b].apply(f, d) : a.error(b + " does not exist in videoController.")
1843
- }
1844
- })
1845
- };
1846
- var d = function(b) {
1847
- this.$video = b, this.player = null, this.ready = !1, this.started = !1, this.state = "", this.events = a({}), this._init()
1848
- };
1849
- d.prototype = {
1850
- _init: function() {},
1851
- play: function() {},
1852
- pause: function() {},
1853
- stop: function() {},
1854
- replay: function() {},
1855
- isType: function() {},
1856
- isReady: function() {
1857
- return this.ready
1858
- },
1859
- isStarted: function() {
1860
- return this.started
1861
- },
1862
- getState: function() {
1863
- return this.state
1864
- },
1865
- on: function(a, b) {
1866
- return this.events.on(a, b)
1867
- },
1868
- off: function(a) {
1869
- return this.events.off(a)
1870
- },
1871
- trigger: function(a) {
1872
- return this.events.triggerHandler(a)
1873
- }
1874
- };
1875
- var e = {
1876
- youtubeAPIAdded: !1,
1877
- youtubeVideos: []
1878
- },
1879
- f = function(b) {
1880
- this.init = !1;
1881
- var c = window.YT && window.YT.Player;
1882
- if ("undefined" != typeof c) d.call(this, b);
1883
- else if (e.youtubeVideos.push({
1884
- video: b,
1885
- scope: this
1886
- }), e.youtubeAPIAdded === !1) {
1887
- e.youtubeAPIAdded = !0;
1888
- var f = document.createElement("script");
1889
- f.src = "http://www.youtube.com/player_api";
1890
- var g = document.getElementsByTagName("script")[0];
1891
- g.parentNode.insertBefore(f, g), window.onYouTubePlayerAPIReady = function() {
1892
- a.each(e.youtubeVideos, function(a, b) {
1893
- d.call(b.scope, b.video)
1894
- })
1895
- }
1896
- }
1897
- };
1898
- f.prototype = new d, f.prototype.constructor = f, a.VideoController.addPlayer("YoutubeVideo", f), f.isType = function(a) {
1899
- if (a.is("iframe")) {
1900
- var b = a.attr("src");
1901
- if (-1 !== b.indexOf("youtube.com") || -1 !== b.indexOf("youtu.be")) return !0
1902
- }
1903
- return !1
1904
- }, f.prototype._init = function() {
1905
- this.init = !0, this._setup()
1906
- }, f.prototype._setup = function() {
1907
- var a = this;
1908
- this.player = new YT.Player(this.$video[0], {
1909
- events: {
1910
- onReady: function() {
1911
- a.trigger({
1912
- type: "ready"
1913
- }), a.ready = !0
1914
- },
1915
- onStateChange: function(b) {
1916
- switch (b.data) {
1917
- case YT.PlayerState.PLAYING:
1918
- a.started === !1 && (a.started = !0, a.trigger({
1919
- type: "start"
1920
- })), a.state = "playing", a.trigger({
1921
- type: "play"
1922
- });
1923
- break;
1924
- case YT.PlayerState.PAUSED:
1925
- a.state = "paused", a.trigger({
1926
- type: "pause"
1927
- });
1928
- break;
1929
- case YT.PlayerState.ENDED:
1930
- a.state = "ended", a.trigger({
1931
- type: "ended"
1932
- })
1933
- }
1934
- }
1935
- }
1936
- })
1937
- }, f.prototype.play = function() {
1938
- var a = this;
1939
- if (this.ready === !0) this.player.playVideo();
1940
- else var b = setInterval(function() {
1941
- a.ready === !0 && (clearInterval(b), a.player.playVideo())
1942
- }, 100)
1943
- }, f.prototype.pause = function() {
1944
- b === !0 ? this.stop() : this.player.pauseVideo()
1945
- }, f.prototype.stop = function() {
1946
- this.player.seekTo(1), this.player.stopVideo(), this.state = "stopped"
1947
- }, f.prototype.replay = function() {
1948
- this.player.seekTo(1), this.player.playVideo()
1949
- }, f.prototype.on = function(a, b) {
1950
- var c = this;
1951
- if (this.init === !0) d.prototype.on.call(this, a, b);
1952
- else var e = setInterval(function() {
1953
- c.init === !0 && (clearInterval(e), d.prototype.on.call(c, a, b))
1954
- }, 100)
1955
- };
1956
- var g = {
1957
- vimeoAPIAdded: !1,
1958
- vimeoVideos: []
1959
- },
1960
- h = function(b) {
1961
- if (this.init = !1, "undefined" != typeof window.Froogaloop) d.call(this, b);
1962
- else if (g.vimeoVideos.push({
1963
- video: b,
1964
- scope: this
1965
- }), g.vimeoAPIAdded === !1) {
1966
- g.vimeoAPIAdded = !0;
1967
- var c = document.createElement("script");
1968
- c.src = "http://a.vimeocdn.com/js/froogaloop2.min.js";
1969
- var e = document.getElementsByTagName("script")[0];
1970
- e.parentNode.insertBefore(c, e);
1971
- var f = setInterval(function() {
1972
- "undefined" != typeof window.Froogaloop && (clearInterval(f), a.each(g.vimeoVideos, function(a, b) {
1973
- d.call(b.scope, b.video)
1974
- }))
1975
- }, 100)
1976
- }
1977
- };
1978
- h.prototype = new d, h.prototype.constructor = h, a.VideoController.addPlayer("VimeoVideo", h), h.isType = function(a) {
1979
- if (a.is("iframe")) {
1980
- var b = a.attr("src");
1981
- if (-1 !== b.indexOf("vimeo.com")) return !0
1982
- }
1983
- return !1
1984
- }, h.prototype._init = function() {
1985
- this.init = !0, this._setup()
1986
- }, h.prototype._setup = function() {
1987
- var a = this;
1988
- this.player = $f(this.$video[0]), this.player.addEvent("ready", function() {
1989
- a.ready = !0, a.trigger({
1990
- type: "ready"
1991
- }), a.player.addEvent("play", function() {
1992
- a.started === !1 && (a.started = !0, a.trigger({
1993
- type: "start"
1994
- })), a.state = "playing", a.trigger({
1995
- type: "play"
1996
- })
1997
- }), a.player.addEvent("pause", function() {
1998
- a.state = "paused", a.trigger({
1999
- type: "pause"
2000
- })
2001
- }), a.player.addEvent("finish", function() {
2002
- a.state = "ended", a.trigger({
2003
- type: "ended"
2004
- })
2005
- })
2006
- })
2007
- }, h.prototype.play = function() {
2008
- var a = this;
2009
- if (this.ready === !0) this.player.api("play");
2010
- else var b = setInterval(function() {
2011
- a.ready === !0 && (clearInterval(b), a.player.api("play"))
2012
- }, 100)
2013
- }, h.prototype.pause = function() {
2014
- this.player.api("pause")
2015
- }, h.prototype.stop = function() {
2016
- this.player.api("seekTo", 0), this.player.api("pause"), this.state = "stopped"
2017
- }, h.prototype.replay = function() {
2018
- this.player.api("seekTo", 0), this.player.api("play")
2019
- }, h.prototype.on = function(a, b) {
2020
- var c = this;
2021
- if (this.init === !0) d.prototype.on.call(this, a, b);
2022
- else var e = setInterval(function() {
2023
- c.init === !0 && (clearInterval(e), d.prototype.on.call(c, a, b))
2024
- }, 100)
2025
- };
2026
- var i = function(a) {
2027
- d.call(this, a)
2028
- };
2029
- i.prototype = new d, i.prototype.constructor = i, a.VideoController.addPlayer("HTML5Video", i), i.isType = function(a) {
2030
- return a.is("video") && a.hasClass("video-js") === !1 && a.hasClass("sublime") === !1 ? !0 : !1
2031
- }, i.prototype._init = function() {
2032
- var a = this;
2033
- this.player = this.$video[0], this.ready = !0, this.player.addEventListener("play", function() {
2034
- a.started === !1 && (a.started = !0, a.trigger({
2035
- type: "start"
2036
- })), a.state = "playing", a.trigger({
2037
- type: "play"
2038
- })
2039
- }), this.player.addEventListener("pause", function() {
2040
- a.state = "paused", a.trigger({
2041
- type: "pause"
2042
- })
2043
- }), this.player.addEventListener("ended", function() {
2044
- a.state = "ended", a.trigger({
2045
- type: "ended"
2046
- })
2047
- })
2048
- }, i.prototype.play = function() {
2049
- this.player.play()
2050
- }, i.prototype.pause = function() {
2051
- this.player.pause()
2052
- }, i.prototype.stop = function() {
2053
- this.player.currentTime = 0, this.player.pause(), this.state = "stopped"
2054
- }, i.prototype.replay = function() {
2055
- this.player.currentTime = 0, this.player.play()
2056
- };
2057
- var j = function(a) {
2058
- d.call(this, a)
2059
- };
2060
- j.prototype = new d, j.prototype.constructor = j, a.VideoController.addPlayer("VideoJSVideo", j), j.isType = function(a) {
2061
- return "undefined" == typeof a.attr("data-videojs-id") && !a.hasClass("video-js") || "undefined" == typeof videojs ? !1 : !0
2062
- }, j.prototype._init = function() {
2063
- var a = this,
2064
- b = this.$video.attr(this.$video.hasClass("video-js") ? "id" : "data-videojs-id");
2065
- this.player = videojs(b), this.player.ready(function() {
2066
- a.ready = !0, a.trigger({
2067
- type: "ready"
2068
- }), a.player.on("play", function() {
2069
- a.started === !1 && (a.started = !0, a.trigger({
2070
- type: "start"
2071
- })), a.state = "playing", a.trigger({
2072
- type: "play"
2073
- })
2074
- }), a.player.on("pause", function() {
2075
- a.state = "paused", a.trigger({
2076
- type: "pause"
2077
- })
2078
- }), a.player.on("ended", function() {
2079
- a.state = "ended", a.trigger({
2080
- type: "ended"
2081
- })
2082
- })
2083
- })
2084
- }, j.prototype.play = function() {
2085
- this.player.play()
2086
- }, j.prototype.pause = function() {
2087
- this.player.pause()
2088
- }, j.prototype.stop = function() {
2089
- this.player.currentTime(0), this.player.pause(), this.state = "stopped"
2090
- }, j.prototype.replay = function() {
2091
- this.player.currentTime(0), this.player.play()
2092
- };
2093
- var k = function(a) {
2094
- d.call(this, a)
2095
- };
2096
- k.prototype = new d, k.prototype.constructor = k, a.VideoController.addPlayer("SublimeVideo", k), k.isType = function(a) {
2097
- return a.hasClass("sublime") && "undefined" != typeof sublime ? !0 : !1
2098
- }, k.prototype._init = function() {
2099
- var a = this;
2100
- sublime.ready(function() {
2101
- a.player = sublime.player(a.$video.attr("id")), a.ready = !0, a.trigger({
2102
- type: "ready"
2103
- }), a.player.on("play", function() {
2104
- a.started === !1 && (a.started = !0, a.trigger({
2105
- type: "start"
2106
- })), a.state = "playing", a.trigger({
2107
- type: "play"
2108
- })
2109
- }), a.player.on("pause", function() {
2110
- a.state = "paused", a.trigger({
2111
- type: "pause"
2112
- })
2113
- }), a.player.on("stop", function() {
2114
- a.state = "stopped", a.trigger({
2115
- type: "stop"
2116
- })
2117
- }), a.player.on("end", function() {
2118
- a.state = "ended", a.trigger({
2119
- type: "ended"
2120
- })
2121
- })
2122
- })
2123
- }, k.prototype.play = function() {
2124
- this.player.play()
2125
- }, k.prototype.pause = function() {
2126
- this.player.pause()
2127
- }, k.prototype.stop = function() {
2128
- this.player.stop()
2129
- }, k.prototype.replay = function() {
2130
- this.player.stop(), this.player.play()
2131
- };
2132
- var l = function(a) {
2133
- d.call(this, a)
2134
- };
2135
- l.prototype = new d, l.prototype.constructor = l, a.VideoController.addPlayer("JWPlayerVideo", l), l.isType = function(a) {
2136
- return "undefined" == typeof a.attr("data-jwplayer-id") && !a.hasClass("jwplayer") && 0 === a.find("object[data*='jwplayer']").length || "undefined" == typeof jwplayer ? !1 : !0
2137
- }, l.prototype._init = function() {
2138
- var a, b = this;
2139
- this.$video.hasClass("jwplayer") ? a = this.$video.attr("id") : "undefined" != typeof this.$video.attr("data-jwplayer-id") ? a = this.$video.attr("data-jwplayer-id") : 0 !== this.$video.find("object[data*='jwplayer']").length && (a = this.$video.find("object").attr("id")), this.player = jwplayer(a), this.player.onReady(function() {
2140
- b.ready = !0, b.trigger({
2141
- type: "ready"
2142
- }), b.player.onPlay(function() {
2143
- b.started === !1 && (b.started = !0, b.trigger({
2144
- type: "start"
2145
- })), b.state = "playing", b.trigger({
2146
- type: "play"
2147
- })
2148
- }), b.player.onPause(function() {
2149
- b.state = "paused", b.trigger({
2150
- type: "pause"
2151
- })
2152
- }), b.player.onComplete(function() {
2153
- b.state = "ended", b.trigger({
2154
- type: "ended"
2155
- })
2156
- })
2157
- })
2158
- }, l.prototype.play = function() {
2159
- this.player.play(!0)
2160
- }, l.prototype.pause = function() {
2161
- this.player.pause(!0)
2162
- }, l.prototype.stop = function() {
2163
- this.player.stop(), this.state = "stopped"
2164
- }, l.prototype.replay = function() {
2165
- this.player.seek(0), this.player.play(!0)
2166
- }
2167
- }(jQuery);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  /*!
2
+ * - v1.2.4
3
+ * Homepage: http://bqworks.com/slider-pro/
4
+ * Author: bqworks
5
+ * Author URL: http://bqworks.com/
6
+ */
7
+ ;(function( window, $ ) {
8
+
9
+ "use strict";
10
+
11
+ // Static methods for Slider Pro
12
+ $.SliderPro = {
13
+
14
+ // List of added modules
15
+ modules: [],
16
+
17
+ // Add a module by extending the core prototype
18
+ addModule: function( name, module ) {
19
+ this.modules.push( name );
20
+ $.extend( SliderPro.prototype, module );
21
+ }
22
+ };
23
+
24
+ // namespace
25
+ var NS = $.SliderPro.namespace = 'SliderPro';
26
+
27
+ var SliderPro = function( instance, options ) {
28
+
29
+ // Reference to the slider instance
30
+ this.instance = instance;
31
+
32
+ // Reference to the slider jQuery element
33
+ this.$slider = $( this.instance );
34
+
35
+ // Reference to the slides (sp-slides) jQuery element
36
+ this.$slides = null;
37
+
38
+ // Reference to the mask (sp-mask) jQuery element
39
+ this.$slidesMask = null;
40
+
41
+ // Reference to the slides (sp-slides-container) jQuery element
42
+ this.$slidesContainer = null;
43
+
44
+ // Array of SliderProSlide objects, ordered by their DOM index
45
+ this.slides = [];
46
+
47
+ // Array of SliderProSlide objects, ordered by their left/top position in the slider.
48
+ // This will be updated continuously if the slider is loopable.
49
+ this.slidesOrder = [];
50
+
51
+ // Holds the options passed to the slider when it was instantiated
52
+ this.options = options;
53
+
54
+ // Holds the final settings of the slider after merging the specified
55
+ // ones with the default ones.
56
+ this.settings = {};
57
+
58
+ // Another reference to the settings which will not be altered by breakpoints or by other means
59
+ this.originalSettings = {};
60
+
61
+ // Reference to the original 'gotoSlide' method
62
+ this.originalGotoSlide = null;
63
+
64
+ // The index of the currently selected slide (starts with 0)
65
+ this.selectedSlideIndex = 0;
66
+
67
+ // The index of the previously selected slide
68
+ this.previousSlideIndex = 0;
69
+
70
+ // Indicates the position of the slide considered to be in the middle.
71
+ // If there are 5 slides (0, 1, 2, 3, 4) the middle position will be 2.
72
+ // If there are 6 slides (0, 1, 2, 3, 4, 5) the middle position will be approximated to 2.
73
+ this.middleSlidePosition = 0;
74
+
75
+ // Indicates the type of supported transition (CSS3 2D, CSS3 3D or JavaScript)
76
+ this.supportedAnimation = null;
77
+
78
+ // Indicates the required vendor prefix for CSS (i.e., -webkit, -moz, etc.)
79
+ this.vendorPrefix = null;
80
+
81
+ // Indicates the name of the CSS transition's complete event (i.e., transitionend, webkitTransitionEnd, etc.)
82
+ this.transitionEvent = null;
83
+
84
+ // Indicates the 'left' or 'top' position
85
+ this.positionProperty = null;
86
+
87
+ // Indicates if the current browser is IE
88
+ this.isIE = null;
89
+
90
+ // The position of the slides container
91
+ this.slidesPosition = 0;
92
+
93
+ // The width of the individual slide
94
+ this.slideWidth = 0;
95
+
96
+ // The height of the individual slide
97
+ this.slideHeight = 0;
98
+
99
+ // The width or height, depending on the orientation, of the individual slide
100
+ this.slideSize = 0;
101
+
102
+ // Reference to the old slide width, used to check if the width has changed
103
+ this.previousSlideWidth = 0;
104
+
105
+ // Reference to the old slide height, used to check if the height has changed
106
+ this.previousSlideHeight = 0;
107
+
108
+ // Reference to the old window width, used to check if the window width has changed
109
+ this.previousWindowWidth = 0;
110
+
111
+ // Reference to the old window height, used to check if the window height has changed
112
+ this.previousWindowHeight = 0;
113
+
114
+ // The distance from the margin of the slider to the left/top of the selected slide.
115
+ // This is useful in calculating the position of the selected slide when there are
116
+ // more visible slides.
117
+ this.visibleOffset = 0;
118
+
119
+ // Property used for deferring the resizing of the slider
120
+ this.allowResize = true;
121
+
122
+ // Unique ID to be used for event listening
123
+ this.uniqueId = new Date().valueOf();
124
+
125
+ // Stores size breakpoints
126
+ this.breakpoints = [];
127
+
128
+ // Indicates the current size breakpoint
129
+ this.currentBreakpoint = -1;
130
+
131
+ // An array of shuffled indexes, based on which the slides will be shuffled
132
+ this.shuffledIndexes = [];
133
+
134
+ // Initialize the slider
135
+ this._init();
136
+ };
137
+
138
+ SliderPro.prototype = {
139
+
140
+ // The starting place for the slider
141
+ _init: function() {
142
+ var that = this;
143
+
144
+ this.supportedAnimation = SliderProUtils.getSupportedAnimation();
145
+ this.vendorPrefix = SliderProUtils.getVendorPrefix();
146
+ this.transitionEvent = SliderProUtils.getTransitionEvent();
147
+ this.isIE = SliderProUtils.checkIE();
148
+
149
+ // Remove the 'sp-no-js' when the slider's JavaScript code starts running
150
+ this.$slider.removeClass( 'sp-no-js' );
151
+
152
+ // Add the 'ios' class if it's an iOS device
153
+ if ( window.navigator.userAgent.match( /(iPad|iPhone|iPod)/g ) ) {
154
+ this.$slider.addClass( 'ios' );
155
+ }
156
+
157
+ // Check if IE (older than 11) is used and add the version number as a class to the slider since
158
+ // older IE versions might need CSS tweaks.
159
+ var rmsie = /(msie) ([\w.]+)/,
160
+ ieVersion = rmsie.exec( window.navigator.userAgent.toLowerCase() );
161
+
162
+ if ( this.isIE ) {
163
+ this.$slider.addClass( 'ie' );
164
+ }
165
+
166
+ if ( ieVersion !== null ) {
167
+ this.$slider.addClass( 'ie' + parseInt( ieVersion[2], 10 ) );
168
+ }
169
+
170
+ // Set up the slides containers
171
+ // slider-pro > sp-slides-container > sp-mask > sp-slides > sp-slide
172
+ this.$slidesContainer = $( '<div class="sp-slides-container"></div>' ).appendTo( this.$slider );
173
+ this.$slidesMask = $( '<div class="sp-mask"></div>' ).appendTo( this.$slidesContainer );
174
+ this.$slides = this.$slider.find( '.sp-slides' ).appendTo( this.$slidesMask );
175
+ this.$slider.find( '.sp-slide' ).appendTo( this.$slides );
176
+
177
+ var modules = $.SliderPro.modules;
178
+
179
+ // Merge the modules' default settings with the core's default settings
180
+ if ( typeof modules !== 'undefined' ) {
181
+ for ( var i = 0; i < modules.length; i++ ) {
182
+ var defaults = modules[ i ].substring( 0, 1 ).toLowerCase() + modules[ i ].substring( 1 ) + 'Defaults';
183
+
184
+ if ( typeof this[ defaults ] !== 'undefined' ) {
185
+ $.extend( this.defaults, this[ defaults ] );
186
+ }
187
+ }
188
+ }
189
+
190
+ // Merge the specified setting with the default ones
191
+ this.settings = $.extend( {}, this.defaults, this.options );
192
+
193
+ // Initialize the modules
194
+ if ( typeof modules !== 'undefined' ) {
195
+ for ( var j = 0; j < modules.length; j++ ) {
196
+ if ( typeof this[ 'init' + modules[ j ] ] !== 'undefined' ) {
197
+ this[ 'init' + modules[ j ] ]();
198
+ }
199
+ }
200
+ }
201
+
202
+ // Keep a reference of the original settings and use it
203
+ // to restore the settings when the breakpoints are used.
204
+ this.originalSettings = $.extend( {}, this.settings );
205
+
206
+ // Get the reference to the 'gotoSlide' method
207
+ this.originalGotoSlide = this.gotoSlide;
208
+
209
+ // Parse the breakpoints object and store the values into an array,
210
+ // sorting them in ascending order based on the specified size.
211
+ if ( this.settings.breakpoints !== null ) {
212
+ for ( var sizes in this.settings.breakpoints ) {
213
+ this.breakpoints.push({ size: parseInt( sizes, 10 ), properties:this.settings.breakpoints[ sizes ] });
214
+ }
215
+
216
+ this.breakpoints = this.breakpoints.sort(function( a, b ) {
217
+ return a.size >= b.size ? 1: -1;
218
+ });
219
+ }
220
+
221
+ // Set which slide should be selected initially
222
+ this.selectedSlideIndex = this.settings.startSlide;
223
+
224
+ // Shuffle/randomize the slides
225
+ if ( this.settings.shuffle === true ) {
226
+ var slides = this.$slides.find( '.sp-slide' ),
227
+ shuffledSlides = [];
228
+
229
+ // Populate the 'shuffledIndexes' with index numbers
230
+ slides.each(function( index ) {
231
+ that.shuffledIndexes.push( index );
232
+ });
233
+
234
+ for ( var k = this.shuffledIndexes.length - 1; k > 0; k-- ) {
235
+ var l = Math.floor( Math.random() * ( k + 1 ) ),
236
+ temp = this.shuffledIndexes[ k ];
237
+
238
+ this.shuffledIndexes[ k ] = this.shuffledIndexes[ l ];
239
+ this.shuffledIndexes[ l ] = temp;
240
+ }
241
+
242
+ // Reposition the slides based on the order of the indexes in the
243
+ // 'shuffledIndexes' array
244
+ $.each( this.shuffledIndexes, function( index, element ) {
245
+ shuffledSlides.push( slides[ element ] );
246
+ });
247
+
248
+ // Append the sorted slides to the slider
249
+ this.$slides.empty().append( shuffledSlides ) ;
250
+ }
251
+
252
+ // Resize the slider when the browser window resizes.
253
+ // Also, deffer the resizing in order to not allow multiple
254
+ // resizes in a 200 milliseconds interval.
255
+ $( window ).on( 'resize.' + this.uniqueId + '.' + NS, function() {
256
+
257
+ // Get the current width and height of the window
258
+ var newWindowWidth = $( window ).width(),
259
+ newWindowHeight = $( window ).height();
260
+
261
+ // If the resize is not allowed yet or if the window size hasn't changed (this needs to be verified
262
+ // because in IE8 and lower the resize event is triggered whenever an element from the page changes
263
+ // its size) return early.
264
+ if ( that.allowResize === false ||
265
+ ( that.previousWindowWidth === newWindowWidth && that.previousWindowHeight === newWindowHeight ) ) {
266
+ return;
267
+ }
268
+
269
+ // Asign the new values for the window width and height
270
+ that.previousWindowWidth = newWindowWidth;
271
+ that.previousWindowHeight = newWindowHeight;
272
+
273
+ that.allowResize = false;
274
+
275
+ setTimeout(function() {
276
+ that.resize();
277
+ that.allowResize = true;
278
+ }, 200 );
279
+ });
280
+
281
+ // Resize the slider when the 'update' method is called.
282
+ this.on( 'update.' + NS, function() {
283
+
284
+ // Reset the previous slide width
285
+ that.previousSlideWidth = 0;
286
+
287
+ // Some updates might require a resize
288
+ that.resize();
289
+ });
290
+
291
+ this.update();
292
+
293
+ // add the 'sp-selected' class to the initially selected slide
294
+ this.$slides.find( '.sp-slide' ).eq( this.selectedSlideIndex ).addClass( 'sp-selected' );
295
+
296
+ // Fire the 'init' event
297
+ this.trigger({ type: 'init' });
298
+ if ( $.isFunction( this.settings.init ) ) {
299
+ this.settings.init.call( this, { type: 'init' });
300
+ }
301
+ },
302
+
303
+ // Update the slider by checking for setting changes and for slides
304
+ // that weren't initialized yet.
305
+ update: function() {
306
+ var that = this;
307
+
308
+ // Check the current slider orientation and reset CSS that might have been
309
+ // added for a different orientation, since the orientation can be changed
310
+ // at runtime.
311
+ if ( this.settings.orientation === 'horizontal' ) {
312
+ this.$slider.removeClass( 'sp-vertical' ).addClass( 'sp-horizontal' );
313
+ this.$slider.css({ 'height': '', 'max-height': '' });
314
+ this.$slides.find( '.sp-slide' ).css( 'top', '' );
315
+ } else if ( this.settings.orientation === 'vertical' ) {
316
+ this.$slider.removeClass( 'sp-horizontal' ).addClass( 'sp-vertical' );
317
+ this.$slides.find( '.sp-slide' ).css( 'left', '' );
318
+ }
319
+
320
+ // Set the position that will be used to arrange elements, like the slides,
321
+ // based on the orientation.
322
+ this.positionProperty = this.settings.orientation === 'horizontal' ? 'left' : 'top';
323
+
324
+ // Reset the 'gotoSlide' method
325
+ this.gotoSlide = this.originalGotoSlide;
326
+
327
+ // Loop through the array of SliderProSlide objects and if a stored slide is found
328
+ // which is not in the DOM anymore, destroy that slide.
329
+ for ( var i = this.slides.length - 1; i >= 0; i-- ) {
330
+ if ( this.$slider.find( '.sp-slide[data-index="' + i + '"]' ).length === 0 ) {
331
+ var slide = this.slides[ i ];
332
+
333
+ slide.destroy();
334
+ this.slides.splice( i, 1 );
335
+ }
336
+ }
337
+
338
+ this.slidesOrder.length = 0;
339
+
340
+ // Loop through the list of slides and initialize newly added slides if any,
341
+ // and reset the index of each slide.
342
+ this.$slider.find( '.sp-slide' ).each(function( index ) {
343
+ var $slide = $( this );
344
+
345
+ if ( typeof $slide.attr( 'data-init' ) === 'undefined' ) {
346
+ that._createSlide( index, $slide );
347
+ } else {
348
+ that.slides[ index ].setIndex( index );
349
+ }
350
+
351
+ that.slidesOrder.push( index );
352
+ });
353
+
354
+ // Calculate the position/index of the middle slide
355
+ this.middleSlidePosition = parseInt( ( that.slidesOrder.length - 1 ) / 2, 10 );
356
+
357
+ // Arrange the slides in a loop
358
+ if ( this.settings.loop === true ) {
359
+ this._updateSlidesOrder();
360
+ }
361
+
362
+ // Fire the 'update' event
363
+ this.trigger({ type: 'update' });
364
+ if ( $.isFunction( this.settings.update ) ) {
365
+ this.settings.update.call( this, { type: 'update' } );
366
+ }
367
+ },
368
+
369
+ // Create a SliderProSlide instance for the slide passed as a jQuery element
370
+ _createSlide: function( index, element ) {
371
+ var that = this,
372
+ slide = new SliderProSlide( $( element ), index, this.settings );
373
+
374
+ this.slides.splice( index, 0, slide );
375
+ },
376
+
377
+ // Arrange the slide elements in a loop inside the 'slidesOrder' array
378
+ _updateSlidesOrder: function() {
379
+ var slicedItems,
380
+ i,
381
+
382
+ // Calculate the distance between the selected element and the middle position
383
+ distance = $.inArray( this.selectedSlideIndex, this.slidesOrder ) - this.middleSlidePosition;
384
+
385
+ // If the distance is negative it means that the selected slider is before the middle position, so
386
+ // slides from the end of the array will be added at the beginning, in order to shift the selected slide
387
+ // forward.
388
+ //
389
+ // If the distance is positive, slides from the beginning of the array will be added at the end.
390
+ if ( distance < 0 ) {
391
+ slicedItems = this.slidesOrder.splice( distance, Math.abs( distance ) );
392
+
393
+ for ( i = slicedItems.length - 1; i >= 0; i-- ) {
394
+ this.slidesOrder.unshift( slicedItems[ i ] );
395
+ }
396
+ } else if ( distance > 0 ) {
397
+ slicedItems = this.slidesOrder.splice( 0, distance );
398
+
399
+ for ( i = 0; i <= slicedItems.length - 1; i++ ) {
400
+ this.slidesOrder.push( slicedItems[ i ] );
401
+ }
402
+ }
403
+ },
404
+
405
+ // Set the left/top position of the slides based on their position in the 'slidesOrder' array
406
+ _updateSlidesPosition: function() {
407
+ var selectedSlidePixelPosition = parseInt( this.$slides.find( '.sp-slide' ).eq( this.selectedSlideIndex ).css( this.positionProperty ), 10 );
408
+
409
+ for ( var slideIndex = 0; slideIndex < this.slidesOrder.length; slideIndex++ ) {
410
+ var slide = this.$slides.find( '.sp-slide' ).eq( this.slidesOrder[ slideIndex ] );
411
+ slide.css( this.positionProperty, selectedSlidePixelPosition + ( slideIndex - this.middleSlidePosition ) * ( this.slideSize + this.settings.slideDistance ) );
412
+ }
413
+ },
414
+
415
+ // Set the left/top position of the slides based on their position in the 'slidesOrder' array,
416
+ // and also set the position of the slides container.
417
+ _resetSlidesPosition: function() {
418
+ for ( var slideIndex = 0; slideIndex < this.slidesOrder.length; slideIndex++ ) {
419
+ var slide = this.$slides.find( '.sp-slide' ).eq( this.slidesOrder[ slideIndex ] );
420
+ slide.css( this.positionProperty, slideIndex * ( this.slideSize + this.settings.slideDistance ) );
421
+ }
422
+
423
+ var newSlidesPosition = - parseInt( this.$slides.find( '.sp-slide' ).eq( this.selectedSlideIndex ).css( this.positionProperty ), 10 ) + this.visibleOffset;
424
+ this._moveTo( newSlidesPosition, true );
425
+ },
426
+
427
+ // Called when the slider needs to resize
428
+ resize: function() {
429
+ var that = this;
430
+
431
+ // Check if the current window width is bigger than the biggest breakpoint
432
+ // and if necessary reset the properties to the original settings.
433
+ //
434
+ // If the window width is smaller than a certain breakpoint, apply the settings specified
435
+ // for that breakpoint but only after merging them with the original settings
436
+ // in order to make sure that only the specified settings for the breakpoint are applied
437
+ if ( this.settings.breakpoints !== null && this.breakpoints.length > 0 ) {
438
+ if ( $( window ).width() > this.breakpoints[ this.breakpoints.length - 1 ].size && this.currentBreakpoint !== -1 ) {
439
+ this.currentBreakpoint = -1;
440
+ this._setProperties( this.originalSettings, false );
441
+ } else {
442
+ for ( var i = 0, n = this.breakpoints.length; i < n; i++ ) {
443
+ if ( $( window ).width() <= this.breakpoints[ i ].size ) {
444
+ if ( this.currentBreakpoint !== this.breakpoints[ i ].size ) {
445
+ var eventObject = { type: 'breakpointReach', size: this.breakpoints[ i ].size, settings: this.breakpoints[ i ].properties };
446
+ this.trigger( eventObject );
447
+ if ( $.isFunction( this.settings.breakpointReach ) )
448
+ this.settings.breakpointReach.call( this, eventObject );
449
+
450
+ this.currentBreakpoint = this.breakpoints[ i ].size;
451
+ var settings = $.extend( {}, this.originalSettings, this.breakpoints[ i ].properties );
452
+ this._setProperties( settings, false );
453
+
454
+ return;
455
+ }
456
+
457
+ break;
458
+ }
459
+ }
460
+ }
461
+ }
462
+
463
+ // Set the width of the main slider container based on whether or not the slider is responsive,
464
+ // full width or full size
465
+ if ( this.settings.responsive === true ) {
466
+ if ( ( this.settings.forceSize === 'fullWidth' || this.settings.forceSize === 'fullWindow' ) &&
467
+ ( this.settings.visibleSize === 'auto' || this.settings.visibleSize !== 'auto' && this.settings.orientation === 'vertical' )
468
+ ) {
469
+ this.$slider.css( 'margin', 0 );
470
+ this.$slider.css({ 'width': $( window ).width(), 'max-width': '', 'marginLeft': - this.$slider.offset().left });
471
+ } else {
472
+ this.$slider.css({ 'width': '100%', 'max-width': this.settings.width, 'marginLeft': '' });
473
+ }
474
+ } else {
475
+ this.$slider.css({ 'width': this.settings.width });
476
+ }
477
+
478
+ // Calculate the aspect ratio of the slider
479
+ if ( this.settings.aspectRatio === -1 ) {
480
+ this.settings.aspectRatio = this.settings.width / this.settings.height;
481
+ }
482
+
483
+ // Initially set the slide width to the size of the slider.
484
+ // Later, this will be set to less if there are multiple visible slides.
485
+ this.slideWidth = this.$slider.width();
486
+
487
+ // Set the height to the same size as the browser window if the slider is set to be 'fullWindow',
488
+ // or calculate the height based on the width and the aspect ratio.
489
+ if ( this.settings.forceSize === 'fullWindow' ) {
490
+ this.slideHeight = $( window ).height();
491
+ } else {
492
+ this.slideHeight = isNaN( this.settings.aspectRatio ) ? this.settings.height : this.slideWidth / this.settings.aspectRatio;
493
+ }
494
+
495
+ // Resize the slider only if the size of the slider has changed
496
+ // If it hasn't, return.
497
+ if ( this.previousSlideWidth !== this.slideWidth ||
498
+ this.previousSlideHeight !== this.slideHeight ||
499
+ this.settings.visibleSize !== 'auto' ||
500
+ this.$slider.outerWidth() > this.$slider.parent().width() ||
501
+ this.$slider.width() !== this.$slidesMask.width()
502
+ ) {
503
+ this.previousSlideWidth = this.slideWidth;
504
+ this.previousSlideHeight = this.slideHeight;
505
+ } else {
506
+ return;
507
+ }
508
+
509
+ // The slide width or slide height is needed for several calculation, so create a reference to it
510
+ // based on the current orientation.
511
+ this.slideSize = this.settings.orientation === 'horizontal' ? this.slideWidth : this.slideHeight;
512
+
513
+ // Initially set the visible size of the slides and the offset of the selected slide as if there is only
514
+ // on visible slide.
515
+ // If there will be multiple visible slides (when 'visibleSize' is different than 'auto'), these will
516
+ // be updated accordingly.
517
+ this.visibleSlidesSize = this.slideSize;
518
+ this.visibleOffset = 0;
519
+
520
+ // Loop through the existing slides and reset their size.
521
+ $.each( this.slides, function( index, element ) {
522
+ element.setSize( that.slideWidth, that.slideHeight );
523
+ });
524
+
525
+ // Set the initial size of the mask container to the size of an individual slide
526
+ this.$slidesMask.css({ 'width': this.slideWidth, 'height': this.slideHeight });
527
+
528
+ // Adjust the height if it's set to 'auto'
529
+ if ( this.settings.autoHeight === true ) {
530
+
531
+ // Delay the resizing of the height to allow for other resize handlers
532
+ // to execute first before calculating the final height of the slide
533
+ setTimeout( function() {
534
+ that._resizeHeight();
535
+ }, 1 );
536
+ } else {
537
+ this.$slidesMask.css( this.vendorPrefix + 'transition', '' );
538
+ }
539
+
540
+ // The 'visibleSize' option can be set to fixed or percentage size to make more slides
541
+ // visible at a time.
542
+ // By default it's set to 'auto'.
543
+ if ( this.settings.visibleSize !== 'auto' ) {
544
+ if ( this.settings.orientation === 'horizontal' ) {
545
+
546
+ // If the size is forced to full width or full window, the 'visibleSize' option will be
547
+ // ignored and the slider will become as wide as the browser window.
548
+ if ( this.settings.forceSize === 'fullWidth' || this.settings.forceSize === 'fullWindow' ) {
549
+ this.$slider.css( 'margin', 0 );
550
+ this.$slider.css({ 'width': $( window ).width(), 'max-width': '', 'marginLeft': - this.$slider.offset().left });
551
+ } else {
552
+ this.$slider.css({ 'width': this.settings.visibleSize, 'max-width': '100%', 'marginLeft': 0 });
553
+ }
554
+
555
+ this.$slidesMask.css( 'width', this.$slider.width() );
556
+
557
+ this.visibleSlidesSize = this.$slidesMask.width();
558
+ this.visibleOffset = Math.round( ( this.$slider.width() - this.slideWidth ) / 2 );
559
+ } else {
560
+
561
+ // If the size is forced to full window, the 'visibleSize' option will be
562
+ // ignored and the slider will become as high as the browser window.
563
+ if ( this.settings.forceSize === 'fullWindow' ) {
564
+ this.$slider.css({ 'height': $( window ).height(), 'max-height': '' });
565
+ } else {
566
+ this.$slider.css({ 'height': this.settings.visibleSize, 'max-height': '100%' });
567
+ }
568
+
569
+ this.$slidesMask.css( 'height', this.$slider.height() );
570
+
571
+ this.visibleSlidesSize = this.$slidesMask.height();
572
+ this.visibleOffset = Math.round( ( this.$slider.height() - this.slideHeight ) / 2 );
573
+ }
574
+ }
575
+
576
+ this._resetSlidesPosition();
577
+
578
+ // Fire the 'sliderResize' event
579
+ this.trigger({ type: 'sliderResize' });
580
+ if ( $.isFunction( this.settings.sliderResize ) ) {
581
+ this.settings.sliderResize.call( this, { type: 'sliderResize' });
582
+ }
583
+ },
584
+
585
+ // Resize the height of the slider to the height of the selected slide.
586
+ // It's used when the 'autoHeight' option is set to 'true'.
587
+ _resizeHeight: function() {
588
+ var that = this,
589
+ selectedSlide = this.getSlideAt( this.selectedSlideIndex ),
590
+ size = selectedSlide.getSize();
591
+
592
+ selectedSlide.off( 'imagesLoaded.' + NS );
593
+ selectedSlide.on( 'imagesLoaded.' + NS, function( event ) {
594
+ if ( event.index === that.selectedSlideIndex ) {
595
+ var size = selectedSlide.getSize();
596
+ that._resizeHeightTo( size.height );
597
+ }
598
+ });
599
+
600
+ // If the selected slide contains images which are still loading,
601
+ // wait for the loading to complete and then request the size again.
602
+ if ( size !== 'loading' ) {
603
+ this._resizeHeightTo( size.height );
604
+ }
605
+ },
606
+
607
+ // Open the slide at the specified index
608
+ gotoSlide: function( index ) {
609
+ if ( index === this.selectedSlideIndex || typeof this.slides[ index ] === 'undefined' ) {
610
+ return;
611
+ }
612
+
613
+ var that = this;
614
+
615
+ this.previousSlideIndex = this.selectedSlideIndex;
616
+ this.selectedSlideIndex = index;
617
+
618
+ // Re-assign the 'sp-selected' class to the currently selected slide
619
+ this.$slides.find( '.sp-selected' ).removeClass( 'sp-selected' );
620
+ this.$slides.find( '.sp-slide' ).eq( this.selectedSlideIndex ).addClass( 'sp-selected' );
621
+
622
+ // If the slider is loopable reorder the slides to have the selected slide in the middle
623
+ // and update the slides' position.
624
+ if ( this.settings.loop === true ) {
625
+ this._updateSlidesOrder();
626
+ this._updateSlidesPosition();
627
+ }
628
+
629
+ // Adjust the height of the slider
630
+ if ( this.settings.autoHeight === true ) {
631
+ this._resizeHeight();
632
+ }
633
+
634
+ // Calculate the new position that the slides container need to take
635
+ var newSlidesPosition = - parseInt( this.$slides.find( '.sp-slide' ).eq( this.selectedSlideIndex ).css( this.positionProperty ), 10 ) + this.visibleOffset;
636
+
637
+ // Move the slides container to the new position
638
+ this._moveTo( newSlidesPosition, false, function() {
639
+ if ( that.settings.loop === true ) {
640
+ that._resetSlidesPosition();
641
+ }
642
+
643
+ // Fire the 'gotoSlideComplete' event
644
+ that.trigger({ type: 'gotoSlideComplete', index: index, previousIndex: that.previousSlideIndex });
645
+ if ( $.isFunction( that.settings.gotoSlideComplete ) ) {
646
+ that.settings.gotoSlideComplete.call( that, { type: 'gotoSlideComplete', index: index, previousIndex: that.previousSlideIndex } );
647
+ }
648
+ });
649
+
650
+ // Fire the 'gotoSlide' event
651
+ this.trigger({ type: 'gotoSlide', index: index, previousIndex: this.previousSlideIndex });
652
+ if ( $.isFunction( this.settings.gotoSlide ) ) {
653
+ this.settings.gotoSlide.call( this, { type: 'gotoSlide', index: index, previousIndex: this.previousSlideIndex } );
654
+ }
655
+ },
656
+
657
+ // Open the next slide
658
+ nextSlide: function() {
659
+ var index = ( this.selectedSlideIndex >= this.getTotalSlides() - 1 ) ? 0 : ( this.selectedSlideIndex + 1 );
660
+ this.gotoSlide( index );
661
+ },
662
+
663
+ // Open the previous slide
664
+ previousSlide: function() {
665
+ var index = this.selectedSlideIndex <= 0 ? ( this.getTotalSlides() - 1 ) : ( this.selectedSlideIndex - 1 );
666
+ this.gotoSlide( index );
667
+ },
668
+
669
+ // Move the slides container to the specified position.
670
+ // The movement can be instant or animated.
671
+ _moveTo: function( position, instant, callback ) {
672
+ var that = this,
673
+ css = {};
674
+
675
+ if ( position === this.slidesPosition ) {
676
+ return;
677
+ }
678
+
679
+ this.slidesPosition = position;
680
+
681
+ if ( ( this.supportedAnimation === 'css-3d' || this.supportedAnimation === 'css-2d' ) && this.isIE === false ) {
682
+ var transition,
683
+ left = this.settings.orientation === 'horizontal' ? position : 0,
684
+ top = this.settings.orientation === 'horizontal' ? 0 : position;
685
+
686
+ if ( this.supportedAnimation === 'css-3d' ) {
687
+ css[ this.vendorPrefix + 'transform' ] = 'translate3d(' + left + 'px, ' + top + 'px, 0)';
688
+ } else {
689
+ css[ this.vendorPrefix + 'transform' ] = 'translate(' + left + 'px, ' + top + 'px)';
690
+ }
691
+
692
+ if ( typeof instant !== 'undefined' && instant === true ) {
693
+ transition = '';
694
+ } else {
695
+ this.$slides.addClass( 'sp-animated' );
696
+ transition = this.vendorPrefix + 'transform ' + this.settings.slideAnimationDuration / 1000 + 's';
697
+
698
+ this.$slides.on( this.transitionEvent, function( event ) {
699
+ if ( event.target !== event.currentTarget ) {
700
+ return;
701
+ }
702
+
703
+ that.$slides.off( that.transitionEvent );
704
+ that.$slides.removeClass( 'sp-animated' );
705
+
706
+ if ( typeof callback === 'function' ) {
707
+ callback();
708
+ }
709
+ });
710
+ }
711
+
712
+ css[ this.vendorPrefix + 'transition' ] = transition;
713
+
714
+ this.$slides.css( css );
715
+ } else {
716
+ css[ 'margin-' + this.positionProperty ] = position;
717
+
718
+ if ( typeof instant !== 'undefined' && instant === true ) {
719
+ this.$slides.css( css );
720
+ } else {
721
+ this.$slides.addClass( 'sp-animated' );
722
+ this.$slides.animate( css, this.settings.slideAnimationDuration, function() {
723
+ that.$slides.removeClass( 'sp-animated' );
724
+
725
+ if ( typeof callback === 'function' ) {
726
+ callback();
727
+ }
728
+ });
729
+ }
730
+ }
731
+ },
732
+
733
+ // Stop the movement of the slides
734
+ _stopMovement: function() {
735
+ var css = {};
736
+
737
+ if ( ( this.supportedAnimation === 'css-3d' || this.supportedAnimation === 'css-2d' ) && this.isIE === false) {
738
+
739
+ // Get the current position of the slides by parsing the 'transform' property
740
+ var matrixString = this.$slides.css( this.vendorPrefix + 'transform' ),
741
+ matrixType = matrixString.indexOf( 'matrix3d' ) !== -1 ? 'matrix3d' : 'matrix',
742
+ matrixArray = matrixString.replace( matrixType, '' ).match( /-?[0-9\.]+/g ),
743
+ left = matrixType === 'matrix3d' ? parseInt( matrixArray[ 12 ], 10 ) : parseInt( matrixArray[ 4 ], 10 ),
744
+ top = matrixType === 'matrix3d' ? parseInt( matrixArray[ 13 ], 10 ) : parseInt( matrixArray[ 5 ], 10 );
745
+
746
+ // Set the transform property to the value that the transform had when the function was called
747
+ if ( this.supportedAnimation === 'css-3d' ) {
748
+ css[ this.vendorPrefix + 'transform' ] = 'translate3d(' + left + 'px, ' + top + 'px, 0)';
749
+ } else {
750
+ css[ this.vendorPrefix + 'transform' ] = 'translate(' + left + 'px, ' + top + 'px)';
751
+ }
752
+
753
+ css[ this.vendorPrefix + 'transition' ] = '';
754
+
755
+ this.$slides.css( css );
756
+ this.$slides.off( this.transitionEvent );
757
+ this.slidesPosition = this.settings.orientation === 'horizontal' ? left : top;
758
+ } else {
759
+ this.$slides.stop();
760
+ this.slidesPosition = parseInt( this.$slides.css( 'margin-' + this.positionProperty ), 10 );
761
+ }
762
+
763
+ this.$slides.removeClass( 'sp-animated' );
764
+ },
765
+
766
+ // Resize the height of the slider to the specified value
767
+ _resizeHeightTo: function( height ) {
768
+ var that = this,
769
+ css = { 'height': height };
770
+
771
+ if ( this.supportedAnimation === 'css-3d' || this.supportedAnimation === 'css-2d' ) {
772
+ css[ this.vendorPrefix + 'transition' ] = 'height ' + this.settings.heightAnimationDuration / 1000 + 's';
773
+
774
+ this.$slidesMask.off( this.transitionEvent );
775
+ this.$slidesMask.on( this.transitionEvent, function( event ) {
776
+ if ( event.target !== event.currentTarget ) {
777
+ return;
778
+ }
779
+
780
+ that.$slidesMask.off( that.transitionEvent );
781
+
782
+ // Fire the 'resizeHeightComplete' event
783
+ that.trigger({ type: 'resizeHeightComplete' });
784
+ if ( $.isFunction( that.settings.resizeHeightComplete ) ) {
785
+ that.settings.resizeHeightComplete.call( that, { type: 'resizeHeightComplete' } );
786
+ }
787
+ });
788
+
789
+ this.$slidesMask.css( css );
790
+ } else {
791
+ this.$slidesMask.stop().animate( css, this.settings.heightAnimationDuration, function( event ) {
792
+ // Fire the 'resizeHeightComplete' event
793
+ that.trigger({ type: 'resizeHeightComplete' });
794
+ if ( $.isFunction( that.settings.resizeHeightComplete ) ) {
795
+ that.settings.resizeHeightComplete.call( that, { type: 'resizeHeightComplete' } );
796
+ }
797
+ });
798
+ }
799
+ },
800
+
801
+ // Destroy the slider instance
802
+ destroy: function() {
803
+ // Remove the stored reference to this instance
804
+ this.$slider.removeData( 'sliderPro' );
805
+
806
+ // Clean the CSS
807
+ this.$slider.removeAttr( 'style' );
808
+ this.$slides.removeAttr( 'style' );
809
+
810
+ // Remove event listeners
811
+ this.off( 'update.' + NS );
812
+ $( window ).off( 'resize.' + this.uniqueId + '.' + NS );
813
+
814
+ // Destroy modules
815
+ var modules = $.SliderPro.modules;
816
+
817
+ if ( typeof modules !== 'undefined' ) {
818
+ for ( var i = 0; i < modules.length; i++ ) {
819
+ if ( typeof this[ 'destroy' + modules[ i ] ] !== 'undefined' ) {
820
+ this[ 'destroy' + modules[ i ] ]();
821
+ }
822
+ }
823
+ }
824
+
825
+ // Destroy all slides
826
+ $.each( this.slides, function( index, element ) {
827
+ element.destroy();
828
+ });
829
+
830
+ this.slides.length = 0;
831
+
832
+ // Move the slides to their initial position in the DOM and
833
+ // remove the container elements created dynamically.
834
+ this.$slides.prependTo( this.$slider );
835
+ this.$slidesContainer.remove();
836
+ },
837
+
838
+ // Set properties on runtime
839
+ _setProperties: function( properties, store ) {
840
+ // Parse the properties passed as an object
841
+ for ( var prop in properties ) {
842
+ this.settings[ prop ] = properties[ prop ];
843
+
844
+ // Alter the original settings as well unless 'false' is passed to the 'store' parameter
845
+ if ( store !== false ) {
846
+ this.originalSettings[ prop ] = properties[ prop ];
847
+ }
848
+ }
849
+
850
+ this.update();
851
+ },
852
+
853
+ // Attach an event handler to the slider
854
+ on: function( type, callback ) {
855
+ return this.$slider.on( type, callback );
856
+ },
857
+
858
+ // Detach an event handler
859
+ off: function( type ) {
860
+ return this.$slider.off( type );
861
+ },
862
+
863
+ // Trigger an event on the slider
864
+ trigger: function( data ) {
865
+ return this.$slider.triggerHandler( data );
866
+ },
867
+
868
+ // Return the slide at the specified index
869
+ getSlideAt: function( index ) {
870
+ return this.slides[ index ];
871
+ },
872
+
873
+ // Return the index of the currently opened slide
874
+ getSelectedSlide: function() {
875
+ return this.selectedSlideIndex;
876
+ },
877
+
878
+ // Return the total amount of slides
879
+ getTotalSlides: function() {
880
+ return this.slides.length;
881
+ },
882
+
883
+ // The default options of the slider
884
+ defaults: {
885
+ // Width of the slide
886
+ width: 500,
887
+
888
+ // Height of the slide
889
+ height: 300,
890
+
891
+ // Indicates if the slider is responsive
892
+ responsive: true,
893
+
894
+ // The aspect ratio of the slider (width/height)
895
+ aspectRatio: -1,
896
+
897
+ // The scale mode for images (cover, contain, exact and none)
898
+ imageScaleMode: 'cover',
899
+
900
+ // Indicates if the image will be centered
901
+ centerImage: true,
902
+
903
+ // Indicates if the image can be scaled up more than its original size
904
+ allowScaleUp: true,
905
+
906
+ // Indicates if height of the slider will be adjusted to the
907
+ // height of the selected slide
908
+ autoHeight: false,
909
+
910
+ // Indicates the initially selected slide
911
+ startSlide: 0,
912
+
913
+ // Indicates if the slides will be shuffled
914
+ shuffle: false,
915
+
916
+ // Indicates whether the slides will be arranged horizontally
917
+ // or vertically. Can be set to 'horizontal' or 'vertical'.
918
+ orientation: 'horizontal',
919
+
920
+ // Indicates if the size of the slider will be forced to 'fullWidth' or 'fullWindow'
921
+ forceSize: 'none',
922
+
923
+ // Indicates if the slider will be loopable
924
+ loop: true,
925
+
926
+ // The distance between slides
927
+ slideDistance: 10,
928
+
929
+ // The duration of the slide animation
930
+ slideAnimationDuration: 700,
931
+
932
+ // The duration of the height animation
933
+ heightAnimationDuration: 700,
934
+
935
+ // Sets the size of the visible area, allowing the increase of it in order
936
+ // to make more slides visible.
937
+ // By default, only the selected slide will be visible.
938
+ visibleSize: 'auto',
939
+
940
+ // Breakpoints for allowing the slider's options to be changed
941
+ // based on the size of the window.
942
+ breakpoints: null,
943
+
944
+ // Called when the slider is initialized
945
+ init: function() {},
946
+
947
+ // Called when the slider is updates
948
+ update: function() {},
949
+
950
+ // Called when the slider is resized
951
+ sliderResize: function() {},
952
+
953
+ // Called when a new slide is selected
954
+ gotoSlide: function() {},
955
+
956
+ // Called when the navigation to the newly selected slide is complete
957
+ gotoSlideComplete: function() {},
958
+
959
+ // Called when the height animation of the slider is complete
960
+ resizeHeightComplete: function() {},
961
+
962
+ // Called when a breakpoint is reached
963
+ breakpointReach: function() {}
964
+ }
965
+ };
966
+
967
+ var SliderProSlide = function( slide, index, settings ) {
968
+
969
+ // Reference to the slide jQuery element
970
+ this.$slide = slide;
971
+
972
+ // Reference to the main slide image
973
+ this.$mainImage = null;
974
+
975
+ // Reference to the container that will hold the main image
976
+ this.$imageContainer = null;
977
+
978
+ // Indicates whether the slide has a main image
979
+ this.hasMainImage = false;
980
+
981
+ // Indicates whether the main image is loaded
982
+ this.isMainImageLoaded = false;
983
+
984
+ // Indicates whether the main image is in the process of being loaded
985
+ this.isMainImageLoading = false;
986
+
987
+ // Indicates whether the slide has any image. There could be other images (i.e., in layers)
988
+ // besides the main slide image.
989
+ this.hasImages = false;
990
+
991
+ // Indicates if all the images in the slide are loaded
992
+ this.areImagesLoaded = false;
993
+
994
+ // The width and height of the slide
995
+ this.width = 0;
996
+ this.height = 0;
997
+
998
+ // Reference to the global settings of the slider
999
+ this.settings = settings;
1000
+
1001
+ // Set the index of the slide
1002
+ this.setIndex( index );
1003
+
1004
+ // Initialize the slide
1005
+ this._init();
1006
+ };
1007
+
1008
+ SliderProSlide.prototype = {
1009
+
1010
+ // The starting point for the slide
1011
+ _init: function() {
1012
+ var that = this;
1013
+
1014
+ // Mark the slide as initialized
1015
+ this.$slide.attr( 'data-init', true );
1016
+
1017
+ // Get the main slide image if there is one
1018
+ this.$mainImage = this.$slide.find( '.sp-image' ).length !== 0 ? this.$slide.find( '.sp-image' ) : null;
1019
+
1020
+ // If there is a main slide image, create a container for it and add the image to this container.
1021
+ // The container will allow the isolation of the image from the rest of the slide's content. This is
1022
+ // helpful when you want to show some content below the image and not cover it.
1023
+ if ( this.$mainImage !== null ) {
1024
+ this.hasMainImage = true;
1025
+
1026
+ this.$imageContainer = $( '<div class="sp-image-container"></div>' ).prependTo( this.$slide );
1027
+
1028
+ if ( this.$mainImage.parent( 'a' ).length !== 0 ) {
1029
+ this.$mainImage.parent( 'a' ).appendTo( this.$imageContainer );
1030
+ } else {
1031
+ this.$mainImage.appendTo( this.$imageContainer );
1032
+ }
1033
+ }
1034
+
1035
+ this.hasImages = this.$slide.find( 'img' ).length !== 0 ? true : false;
1036
+ },
1037
+
1038
+ // Set the size of the slide
1039
+ setSize: function( width, height ) {
1040
+ var that = this;
1041
+
1042
+ this.width = width;
1043
+ this.height = this.settings.autoHeight === true ? 'auto' : height;
1044
+
1045
+ this.$slide.css({
1046
+ 'width': this.width,
1047
+ 'height': this.height
1048
+ });
1049
+
1050
+ if ( this.hasMainImage === true ) {
1051
+ this.$imageContainer.css({
1052
+ 'width': this.width,
1053
+ 'height': this.height
1054
+ });
1055
+
1056
+ // Resize the main image if it's loaded. If the 'data-src' attribute is present it means
1057
+ // that the image will be lazy-loaded
1058
+ if ( typeof this.$mainImage.attr( 'data-src' ) === 'undefined' ) {
1059
+ this.resizeMainImage();
1060
+ }
1061
+ }
1062
+ },
1063
+
1064
+ // Get the size (width and height) of the slide
1065
+ getSize: function() {
1066
+ var that = this,
1067
+ size;
1068
+
1069
+ // Check if all images have loaded, and if they have, return the size, else, return 'loading'
1070
+ if ( this.hasImages === true && this.areImagesLoaded === false && typeof this.$slide.attr( 'data-loading' ) === 'undefined' ) {
1071
+ this.$slide.attr( 'data-loading', true );
1072
+
1073
+ var status = SliderProUtils.checkImagesComplete( this.$slide, function() {
1074
+ that.areImagesLoaded = true;
1075
+ that.$slide.removeAttr( 'data-loading' );
1076
+ that.trigger({ type: 'imagesLoaded.' + NS, index: that.index });
1077
+ });
1078
+
1079
+ if ( status === 'complete' ) {
1080
+ size = this.calculateSize();
1081
+
1082
+ return {
1083
+ 'width': size.width,
1084
+ 'height': size.height
1085
+ };
1086
+ } else {
1087
+ return 'loading';
1088
+ }
1089
+ } else {
1090
+ size = this.calculateSize();
1091
+
1092
+ return {
1093
+ 'width': size.width,
1094
+ 'height': size.height
1095
+ };
1096
+ }
1097
+ },
1098
+
1099
+ // Calculate the width and height of the slide by going
1100
+ // through all the child elements and measuring their 'bottom'
1101
+ // and 'right' properties. The element with the biggest
1102
+ // 'right'/'bottom' property will determine the slide's
1103
+ // width/height.
1104
+ calculateSize: function() {
1105
+ var width = this.$slide.width(),
1106
+ height = this.$slide.height();
1107
+
1108
+ this.$slide.children().each(function( index, element ) {
1109
+ var child = $( element );
1110
+
1111
+ if ( child.is( ':hidden' ) === true ) {
1112
+ return;
1113
+ }
1114
+
1115
+ var rect = element.getBoundingClientRect(),
1116
+ bottom = child.position().top + ( rect.bottom - rect.top ),
1117
+ right = child.position().left + ( rect.right - rect.left );
1118
+
1119
+ if ( bottom > height ) {
1120
+ height = bottom;
1121
+ }
1122
+
1123
+ if ( right > width ) {
1124
+ width = right;
1125
+ }
1126
+ });
1127
+
1128
+ return { width: width, height: height };
1129
+ },
1130
+
1131
+ // Resize the main image.
1132
+ //
1133
+ // Call this when the slide resizes or when the main image has changed to a different image.
1134
+ resizeMainImage: function( isNewImage ) {
1135
+ var that = this;
1136
+
1137
+ // If the main image has changed, reset the 'flags'
1138
+ if ( isNewImage === true ) {
1139
+ this.isMainImageLoaded = false;
1140
+ this.isMainImageLoading = false;
1141
+ }
1142
+
1143
+ // If the image was not loaded yet and it's not in the process of being loaded, load it
1144
+ if ( this.isMainImageLoaded === false && this.isMainImageLoading === false ) {
1145
+ this.isMainImageLoading = true;
1146
+
1147
+ SliderProUtils.checkImagesComplete( this.$mainImage, function() {
1148
+ that.isMainImageLoaded = true;
1149
+ that.isMainImageLoading = false;
1150
+ that.resizeMainImage();
1151
+ that.trigger({ type: 'imagesLoaded.' + NS, index: that.index });
1152
+ });
1153
+
1154
+ return;
1155
+ }
1156
+
1157
+ if ( this.settings.allowScaleUp === false ) {
1158
+ this.$mainImage.css({ 'width': '', 'height': '', 'maxWidth': '', 'maxHeight': '' });
1159
+
1160
+ var naturalWidth = this.$mainImage.width(),
1161
+ naturalHeight = this.$mainImage.height();
1162
+
1163
+ this.$mainImage.css({ 'maxWidth': naturalWidth, 'maxHeight': naturalHeight });
1164
+ }
1165
+
1166
+ // After the main image has loaded, resize it
1167
+ if ( this.settings.autoHeight === true ) {
1168
+ this.$mainImage.css({ width: '100%', height: 'auto' });
1169
+ } else {
1170
+ if ( this.settings.imageScaleMode === 'cover' ) {
1171
+ if ( this.$mainImage.width() / this.$mainImage.height() <= this.width / this.height ) {
1172
+ this.$mainImage.css({ width: '100%', height: 'auto' });
1173
+ } else {
1174
+ this.$mainImage.css({ width: 'auto', height: '100%' });
1175
+ }
1176
+ } else if ( this.settings.imageScaleMode === 'contain' ) {
1177
+ if ( this.$mainImage.width() / this.$mainImage.height() >= this.width / this.height ) {
1178
+ this.$mainImage.css({ width: '100%', height: 'auto' });
1179
+ } else {
1180
+ this.$mainImage.css({ width: 'auto', height: '100%' });
1181
+ }
1182
+ } else if ( this.settings.imageScaleMode === 'exact' ) {
1183
+ this.$mainImage.css({ width: '100%', height: '100%' });
1184
+ }
1185
+ }
1186
+
1187
+ if ( this.settings.centerImage === true ) {
1188
+ this.$mainImage.css({ 'marginLeft': ( this.$imageContainer.width() - this.$mainImage.width() ) * 0.5, 'marginTop': ( this.$imageContainer.height() - this.$mainImage.height() ) * 0.5 });
1189
+ }
1190
+ },
1191
+
1192
+ // Destroy the slide
1193
+ destroy: function() {
1194
+ // Clean the slide element from attached styles and data
1195
+ this.$slide.removeAttr( 'style' );
1196
+ this.$slide.removeAttr( 'data-init' );
1197
+ this.$slide.removeAttr( 'data-index' );
1198
+ this.$slide.removeAttr( 'data-loaded' );
1199
+
1200
+ // If there is a main image, remove its container
1201
+ if ( this.hasMainImage === true ) {
1202
+ this.$slide.find( '.sp-image' )
1203
+ .removeAttr( 'style' )
1204
+ .appendTo( this.$slide );
1205
+
1206
+ this.$slide.find( '.sp-image-container' ).remove();
1207
+ }
1208
+ },
1209
+
1210
+ // Return the index of the slide
1211
+ getIndex: function() {
1212
+ return this.index;
1213
+ },
1214
+
1215
+ // Set the index of the slide
1216
+ setIndex: function( index ) {
1217
+ this.index = index;
1218
+ this.$slide.attr( 'data-index', this.index );
1219
+ },
1220
+
1221
+ // Attach an event handler to the slide
1222
+ on: function( type, callback ) {
1223
+ return this.$slide.on( type, callback );
1224
+ },
1225
+
1226
+ // Detach an event handler to the slide
1227
+ off: function( type ) {
1228
+ return this.$slide.off( type );
1229
+ },
1230
+
1231
+ // Trigger an event on the slide
1232
+ trigger: function( data ) {
1233
+ return this.$slide.triggerHandler( data );
1234
+ }
1235
+ };
1236
+
1237
+ window.SliderPro = SliderPro;
1238
+ window.SliderProSlide = SliderProSlide;
1239
+
1240
+ $.fn.sliderPro = function( options ) {
1241
+ var args = Array.prototype.slice.call( arguments, 1 );
1242
+
1243
+ return this.each(function() {
1244
+ // Instantiate the slider or alter it
1245
+ if ( typeof $( this ).data( 'sliderPro' ) === 'undefined' ) {
1246
+ var newInstance = new SliderPro( this, options );
1247
+
1248
+ // Store a reference to the instance created
1249
+ $( this ).data( 'sliderPro', newInstance );
1250
+ } else if ( typeof options !== 'undefined' ) {
1251
+ var currentInstance = $( this ).data( 'sliderPro' );
1252
+
1253
+ // Check the type of argument passed
1254
+ if ( typeof currentInstance[ options ] === 'function' ) {
1255
+ currentInstance[ options ].apply( currentInstance, args );
1256
+ } else if ( typeof currentInstance.settings[ options ] !== 'undefined' ) {
1257
+ var obj = {};
1258
+ obj[ options ] = args[ 0 ];
1259
+ currentInstance._setProperties( obj );
1260
+ } else if ( typeof options === 'object' ) {
1261
+ currentInstance._setProperties( options );
1262
+ } else {
1263
+ $.error( options + ' does not exist in sliderPro.' );
1264
+ }
1265
+ }
1266
+ });
1267
+ };
1268
+
1269
+ // Contains useful utility functions
1270
+ var SliderProUtils = {
1271
+
1272
+ // Indicates what type of animations are supported in the current browser
1273
+ // Can be CSS 3D, CSS 2D or JavaScript
1274
+ supportedAnimation: null,
1275
+
1276
+ // Indicates the required vendor prefix for the current browser
1277
+ vendorPrefix: null,
1278
+
1279
+ // Indicates the name of the transition's complete event for the current browser
1280
+ transitionEvent: null,
1281
+
1282
+ // Indicates if the current browser is Internet Explorer (any version)
1283
+ isIE: null,
1284
+
1285
+ // Check whether CSS3 3D or 2D transforms are supported. If they aren't, use JavaScript animations
1286
+ getSupportedAnimation: function() {
1287
+ if ( this.supportedAnimation !== null ) {
1288
+ return this.supportedAnimation;
1289
+ }
1290
+
1291
+ var element = document.body || document.documentElement,
1292
+ elementStyle = element.style,
1293
+ isCSSTransitions = typeof elementStyle.transition !== 'undefined' ||
1294
+ typeof elementStyle.WebkitTransition !== 'undefined' ||
1295
+ typeof elementStyle.MozTransition !== 'undefined' ||
1296
+ typeof elementStyle.OTransition !== 'undefined';
1297
+
1298
+ if ( isCSSTransitions === true ) {
1299
+ var div = document.createElement( 'div' );
1300
+
1301
+ // Check if 3D transforms are supported
1302
+ if ( typeof div.style.WebkitPerspective !== 'undefined' || typeof div.style.perspective !== 'undefined' ) {
1303
+ this.supportedAnimation = 'css-3d';
1304
+ }
1305
+
1306
+ // Additional checks for Webkit
1307
+ if ( this.supportedAnimation === 'css-3d' && typeof div.styleWebkitPerspective !== 'undefined' ) {
1308
+ var style = document.createElement( 'style' );
1309
+ style.textContent = '@media (transform-3d),(-webkit-transform-3d){#test-3d{left:9px;position:absolute;height:5px;margin:0;padding:0;border:0;}}';
1310
+ document.getElementsByTagName( 'head' )[0].appendChild( style );
1311
+
1312
+ div.id = 'test-3d';
1313
+ document.body.appendChild( div );
1314
+
1315
+ if ( ! ( div.offsetLeft === 9 && div.offsetHeight === 5 ) ) {
1316
+ this.supportedAnimation = null;
1317
+ }
1318
+
1319
+ style.parentNode.removeChild( style );
1320
+ div.parentNode.removeChild( div );
1321
+ }
1322
+
1323
+ // If CSS 3D transforms are not supported, check if 2D transforms are supported
1324
+ if ( this.supportedAnimation === null && ( typeof div.style['-webkit-transform'] !== 'undefined' || typeof div.style.transform !== 'undefined' ) ) {
1325
+ this.supportedAnimation = 'css-2d';
1326
+ }
1327
+ } else {
1328
+ this.supportedAnimation = 'javascript';
1329
+ }
1330
+
1331
+ return this.supportedAnimation;
1332
+ },
1333
+
1334
+ // Check what vendor prefix should be used in the current browser
1335
+ getVendorPrefix: function() {
1336
+ if ( this.vendorPrefix !== null ) {
1337
+ return this.vendorPrefix;
1338
+ }
1339
+
1340
+ var div = document.createElement( 'div' ),
1341
+ prefixes = [ 'Webkit', 'Moz', 'ms', 'O' ];
1342
+
1343
+ if ( 'transform' in div.style ) {
1344
+ this.vendorPrefix = '';
1345
+ return this.vendorPrefix;
1346
+ }
1347
+
1348
+ for ( var i = 0; i < prefixes.length; i++ ) {
1349
+ if ( ( prefixes[ i ] + 'Transform' ) in div.style ) {
1350
+ this.vendorPrefix = '-' + prefixes[ i ].toLowerCase() + '-';
1351
+ break;
1352
+ }
1353
+ }
1354
+
1355
+ return this.vendorPrefix;
1356
+ },
1357
+
1358
+ // Check the name of the transition's complete event in the current browser
1359
+ getTransitionEvent: function() {
1360
+ if ( this.transitionEvent !== null ) {
1361
+ return this.transitionEvent;
1362
+ }
1363
+
1364
+ var div = document.createElement( 'div' ),
1365
+ transitions = {
1366
+ 'transition': 'transitionend',
1367
+ 'WebkitTransition': 'webkitTransitionEnd',
1368
+ 'MozTransition': 'transitionend',
1369
+ 'OTransition': 'oTransitionEnd'
1370
+ };
1371
+
1372
+ for ( var transition in transitions ) {
1373
+ if ( transition in div.style ) {
1374
+ this.transitionEvent = transitions[ transition ];
1375
+ break;
1376
+ }
1377
+ }
1378
+
1379
+ return this.transitionEvent;
1380
+ },
1381
+
1382
+ // If a single image is passed, check if it's loaded.
1383
+ // If a different element is passed, check if there are images
1384
+ // inside it, and check if these images are loaded.
1385
+ checkImagesComplete: function( target, callback ) {
1386
+ var that = this,
1387
+
1388
+ // Check the initial status of the image(s)
1389
+ status = this.checkImagesStatus( target );
1390
+
1391
+ // If there are loading images, wait for them to load.
1392
+ // If the images are loaded, call the callback function directly.
1393
+ if ( status === 'loading' ) {
1394
+ var checkImages = setInterval(function() {
1395
+ status = that.checkImagesStatus( target );
1396
+
1397
+ if ( status === 'complete' ) {
1398
+ clearInterval( checkImages );
1399
+
1400
+ if ( typeof callback === 'function' ) {
1401
+ callback();
1402
+ }
1403
+ }
1404
+ }, 100 );
1405
+ } else if ( typeof callback === 'function' ) {
1406
+ callback();
1407
+ }
1408
+
1409
+ return status;
1410
+ },
1411
+
1412
+ checkImagesStatus: function( target ) {
1413
+ var status = 'complete';
1414
+
1415
+ if ( target.is( 'img' ) && target[0].complete === false ) {
1416
+ status = 'loading';
1417
+ } else {
1418
+ target.find( 'img' ).each(function( index ) {
1419
+ var image = $( this )[0];
1420
+
1421
+ if ( image.complete === false ) {
1422
+ status = 'loading';
1423
+ }
1424
+ });
1425
+ }
1426
+
1427
+ return status;
1428
+ },
1429
+
1430
+ checkIE: function() {
1431
+ if ( this.isIE !== null ) {
1432
+ return this.isIE;
1433
+ }
1434
+
1435
+ var userAgent = window.navigator.userAgent,
1436
+ msie = userAgent.indexOf( 'MSIE' );
1437
+
1438
+ if ( userAgent.indexOf( 'MSIE' ) !== -1 || userAgent.match( /Trident.*rv\:11\./ ) ) {
1439
+ this.isIE = true;
1440
+ } else {
1441
+ this.isIE = false;
1442
+ }
1443
+
1444
+ return this.isIE;
1445
+ }
1446
+ };
1447
+
1448
+ window.SliderProUtils = SliderProUtils;
1449
+
1450
+ })( window, jQuery );
1451
+
1452
+ // Thumbnails module for Slider Pro.
1453
+ //
1454
+ // Adds the possibility to create a thumbnail scroller, each thumbnail
1455
+ // corresponding to a slide.
1456
+ ;(function( window, $ ) {
1457
+
1458
+ "use strict";
1459
+
1460
+ var NS = 'Thumbnails.' + $.SliderPro.namespace;
1461
+
1462
+ var Thumbnails = {
1463
+
1464
+ // Reference to the thumbnail scroller
1465
+ $thumbnails: null,
1466
+
1467
+ // Reference to the container of the thumbnail scroller
1468
+ $thumbnailsContainer: null,
1469
+
1470
+ // List of Thumbnail objects
1471
+ thumbnails: null,
1472
+
1473
+ // Index of the selected thumbnail
1474
+ selectedThumbnailIndex: 0,
1475
+
1476
+ // Total size (width or height, depending on the orientation) of the thumbnails
1477
+ thumbnailsSize: 0,
1478
+
1479
+ // Size of the thumbnail's container
1480
+ thumbnailsContainerSize: 0,
1481
+
1482
+ // The position of the thumbnail scroller inside its container
1483
+ thumbnailsPosition: 0,
1484
+
1485
+ // Orientation of the thumbnails
1486
+ thumbnailsOrientation: null,
1487
+
1488
+ // Indicates the 'left' or 'top' position based on the orientation of the thumbnails
1489
+ thumbnailsPositionProperty: null,
1490
+
1491
+ // Indicates if there are thumbnails in the slider
1492
+ isThumbnailScroller: false,
1493
+
1494
+ initThumbnails: function() {
1495
+ var that = this;
1496
+
1497
+ this.thumbnails = [];
1498
+
1499
+ this.on( 'update.' + NS, $.proxy( this._thumbnailsOnUpdate, this ) );
1500
+ this.on( 'sliderResize.' + NS, $.proxy( this._thumbnailsOnResize, this ) );
1501
+ this.on( 'gotoSlide.' + NS, function( event ) {
1502
+ that._gotoThumbnail( event.index );
1503
+ });
1504
+ },
1505
+
1506
+ // Called when the slider is updated
1507
+ _thumbnailsOnUpdate: function() {
1508
+ var that = this;
1509
+
1510
+ if ( this.$slider.find( '.sp-thumbnail' ).length === 0 && this.thumbnails.length === 0 ) {
1511
+ this.isThumbnailScroller = false;
1512
+ return;
1513
+ }
1514
+
1515
+ this.isThumbnailScroller = true;
1516
+
1517
+ // Create the container of the thumbnail scroller, if it wasn't created yet
1518
+ if ( this.$thumbnailsContainer === null ) {
1519
+ this.$thumbnailsContainer = $( '<div class="sp-thumbnails-container"></div>' ).insertAfter( this.$slidesContainer );
1520
+ }
1521
+
1522
+ // If the thumbnails' main container doesn't exist, create it, and get a reference to it
1523
+ if ( this.$thumbnails === null ) {
1524
+ if ( this.$slider.find( '.sp-thumbnails' ).length !== 0 ) {
1525
+ this.$thumbnails = this.$slider.find( '.sp-thumbnails' ).appendTo( this.$thumbnailsContainer );
1526
+
1527
+ // Shuffle/randomize the thumbnails
1528
+ if ( this.settings.shuffle === true ) {
1529
+ var thumbnails = this.$thumbnails.find( '.sp-thumbnail' ),
1530
+ shuffledThumbnails = [];
1531
+
1532
+ // Reposition the thumbnails based on the order of the indexes in the
1533
+ // 'shuffledIndexes' array
1534
+ $.each( this.shuffledIndexes, function( index, element ) {
1535
+ var $thumbnail = $( thumbnails[ element ] );
1536
+
1537
+ if ( $thumbnail.parent( 'a' ).length !== 0 ) {
1538
+ $thumbnail = $thumbnail.parent( 'a' );
1539
+ }
1540
+
1541
+ shuffledThumbnails.push( $thumbnail );
1542
+ });
1543
+
1544
+ // Append the sorted thumbnails to the thumbnail scroller
1545
+ this.$thumbnails.empty().append( shuffledThumbnails ) ;
1546
+ }
1547
+ } else {
1548
+ this.$thumbnails = $( '<div class="sp-thumbnails"></div>' ).appendTo( this.$thumbnailsContainer );
1549
+ }
1550
+ }
1551
+
1552
+ // Check if there are thumbnails inside the slides and move them in the thumbnails container
1553
+ this.$slides.find( '.sp-thumbnail' ).each( function( index ) {
1554
+ var $thumbnail = $( this ),
1555
+ thumbnailIndex = $thumbnail.parents( '.sp-slide' ).index(),
1556
+ lastThumbnailIndex = that.$thumbnails.find( '.sp-thumbnail' ).length - 1;
1557
+
1558
+ if ( $thumbnail.parent( 'a' ).length !== 0 ) {
1559
+ $thumbnail = $thumbnail.parent( 'a' );
1560
+ }
1561
+
1562
+ // If the index of the slide that contains the thumbnail is greater than the total number
1563
+ // of thumbnails from the thumbnails container, position the thumbnail at the end.
1564
+ // Otherwise, add the thumbnails at the corresponding position.
1565
+ if ( thumbnailIndex > lastThumbnailIndex ) {
1566
+ $thumbnail.appendTo( that.$thumbnails );
1567
+ } else {
1568
+ $thumbnail.insertBefore( that.$thumbnails.find( '.sp-thumbnail' ).eq( thumbnailIndex ) );
1569
+ }
1570
+ });
1571
+
1572
+ // Loop through the Thumbnail objects and if a corresponding element is not found in the DOM,
1573
+ // it means that the thumbnail might have been removed. In this case, destroy that Thumbnail instance.
1574
+ for ( var i = this.thumbnails.length - 1; i >= 0; i-- ) {
1575
+ if ( this.$thumbnails.find( '.sp-thumbnail[data-index="' + i + '"]' ).length === 0 ) {
1576
+ var thumbnail = this.thumbnails[ i ];
1577
+
1578
+ thumbnail.destroy();
1579
+ this.thumbnails.splice( i, 1 );
1580
+ }
1581
+ }
1582
+
1583
+ // Loop through the thumbnails and if there is any uninitialized thumbnail,
1584
+ // initialize it, else update the thumbnail's index.
1585
+ this.$thumbnails.find( '.sp-thumbnail' ).each(function( index ) {
1586
+ var $thumbnail = $( this );
1587
+
1588
+ if ( typeof $thumbnail.attr( 'data-init' ) === 'undefined' ) {
1589
+ that._createThumbnail( $thumbnail, index );
1590
+ } else {
1591
+ that.thumbnails[ index ].setIndex( index );
1592
+ }
1593
+ });
1594
+
1595
+ // Remove the previous class that corresponds to the position of the thumbnail scroller
1596
+ this.$thumbnailsContainer.removeClass( 'sp-top-thumbnails sp-bottom-thumbnails sp-left-thumbnails sp-right-thumbnails' );
1597
+
1598
+ // Check the position of the thumbnail scroller and assign it the appropriate class and styling
1599
+ if ( this.settings.thumbnailsPosition === 'top' ) {
1600
+ this.$thumbnailsContainer.addClass( 'sp-top-thumbnails' );
1601
+ this.thumbnailsOrientation = 'horizontal';
1602
+ } else if ( this.settings.thumbnailsPosition === 'bottom' ) {
1603
+ this.$thumbnailsContainer.addClass( 'sp-bottom-thumbnails' );
1604
+ this.thumbnailsOrientation = 'horizontal';
1605
+ } else if ( this.settings.thumbnailsPosition === 'left' ) {
1606
+ this.$thumbnailsContainer.addClass( 'sp-left-thumbnails' );
1607
+ this.thumbnailsOrientation = 'vertical';
1608
+ } else if ( this.settings.thumbnailsPosition === 'right' ) {
1609
+ this.$thumbnailsContainer.addClass( 'sp-right-thumbnails' );
1610
+ this.thumbnailsOrientation = 'vertical';
1611
+ }
1612
+
1613
+ // Check if the pointer needs to be created
1614
+ if ( this.settings.thumbnailPointer === true ) {
1615
+ this.$thumbnailsContainer.addClass( 'sp-has-pointer' );
1616
+ } else {
1617
+ this.$thumbnailsContainer.removeClass( 'sp-has-pointer' );
1618
+ }
1619
+
1620
+ // Mark the thumbnail that corresponds to the selected slide
1621
+ this.selectedThumbnailIndex = this.selectedSlideIndex;
1622
+ this.$thumbnails.find( '.sp-thumbnail-container' ).eq( this.selectedThumbnailIndex ).addClass( 'sp-selected-thumbnail' );
1623
+
1624
+ // Calculate the total size of the thumbnails
1625
+ this.thumbnailsSize = 0;
1626
+
1627
+ $.each( this.thumbnails, function( index, thumbnail ) {
1628
+ thumbnail.setSize( that.settings.thumbnailWidth, that.settings.thumbnailHeight );
1629
+ that.thumbnailsSize += that.thumbnailsOrientation === 'horizontal' ? thumbnail.getSize().width : thumbnail.getSize().height;
1630
+ });
1631
+
1632
+ // Set the size of the thumbnails
1633
+ if ( this.thumbnailsOrientation === 'horizontal' ) {
1634
+ this.$thumbnails.css({ 'width': this.thumbnailsSize, 'height': this.settings.thumbnailHeight });
1635
+ this.$thumbnailsContainer.css( 'height', '' );
1636
+ this.thumbnailsPositionProperty = 'left';
1637
+ } else {
1638
+ this.$thumbnails.css({ 'width': this.settings.thumbnailWidth, 'height': this.thumbnailsSize });
1639
+ this.$thumbnailsContainer.css( 'width', '' );
1640
+ this.thumbnailsPositionProperty = 'top';
1641
+ }
1642
+
1643
+ // Fire the 'thumbnailsUpdate' event
1644
+ this.trigger({ type: 'thumbnailsUpdate' });
1645
+ if ( $.isFunction( this.settings.thumbnailsUpdate ) ) {
1646
+ this.settings.thumbnailsUpdate.call( this, { type: 'thumbnailsUpdate' } );
1647
+ }
1648
+ },
1649
+
1650
+ // Create an individual thumbnail
1651
+ _createThumbnail: function( element, index ) {
1652
+ var that = this,
1653
+ thumbnail = new Thumbnail( element, this.$thumbnails, index );
1654
+
1655
+ // When the thumbnail is clicked, navigate to the corresponding slide
1656
+ thumbnail.on( 'thumbnailClick.' + NS, function( event ) {
1657
+ that.gotoSlide( event.index );
1658
+ });
1659
+
1660
+ // Add the thumbnail at the specified index
1661
+ this.thumbnails.splice( index, 0, thumbnail );
1662
+ },
1663
+
1664
+ // Called when the slider is resized.
1665
+ // Resets the size and position of the thumbnail scroller container.
1666
+ _thumbnailsOnResize: function() {
1667
+ if ( this.isThumbnailScroller === false ) {
1668
+ return;
1669
+ }
1670
+
1671
+ var that = this,
1672
+ newThumbnailsPosition;
1673
+
1674
+ if ( this.thumbnailsOrientation === 'horizontal' ) {
1675
+ this.thumbnailsContainerSize = Math.min( this.$slidesMask.width(), this.thumbnailsSize );
1676
+ this.$thumbnailsContainer.css( 'width', this.thumbnailsContainerSize );
1677
+
1678
+ // Reduce the slide mask's height, to make room for the thumbnails
1679
+ if ( this.settings.forceSize === 'fullWindow' ) {
1680
+ this.$slidesMask.css( 'height', this.$slidesMask.height() - this.$thumbnailsContainer.outerHeight( true ) );
1681
+
1682
+ // Resize the slide
1683
+ this.slideHeight = this.$slidesMask.height();
1684
+
1685
+ $.each( this.slides, function( index, element ) {
1686
+ element.setSize( that.slideWidth, that.slideHeight );
1687
+ });
1688
+ }
1689
+ } else if ( this.thumbnailsOrientation === 'vertical' ) {
1690
+
1691
+ // Check if the width of the slide mask plus the width of the thumbnail scroller is greater than
1692
+ // the width of the slider's container and if that's the case, reduce the slides container width
1693
+ // in order to make the entire slider fit inside the slider's container.
1694
+ if ( this.$slidesMask.width() + this.$thumbnailsContainer.outerWidth( true ) > this.$slider.parent().width() ) {
1695
+ // Reduce the slider's width, to make room for the thumbnails
1696
+ if ( this.settings.forceSize === 'fullWidth' || this.settings.forceSize === 'fullWindow' ) {
1697
+ this.$slider.css( 'max-width', $( window ).width() - this.$thumbnailsContainer.outerWidth( true ) );
1698
+ } else {
1699
+ this.$slider.css( 'max-width', this.$slider.parent().width() - this.$thumbnailsContainer.outerWidth( true ) );
1700
+ }
1701
+
1702
+ this.$slidesMask.css( 'width', this.$slider.width() );
1703
+
1704
+ // If the slides are horizontally oriented, update the visible size and the offset
1705
+ // of the selected slide, since the slider's size was reduced to make room for the thumbnails.
1706
+ //
1707
+ // If the slides are vertically oriented, update the width and height (to maintain the aspect ratio)
1708
+ // of the slides.
1709
+ if ( this.settings.orientation === 'horizontal' ) {
1710
+ this.visibleOffset = Math.round( ( this.$slider.width() - this.slideSize ) / 2 );
1711
+ this.visibleSlidesSize = this.$slidesMask.width();
1712
+ } else if ( this.settings.orientation === 'vertical' ) {
1713
+ this.slideWidth = this.$slider.width();
1714
+
1715
+ $.each( this.slides, function( index, element ) {
1716
+ element.setSize( that.slideWidth, that.slideHeight );
1717
+ });
1718
+ }
1719
+
1720
+ // Re-arrange the slides
1721
+ this._resetSlidesPosition();
1722
+ }
1723
+
1724
+ this.thumbnailsContainerSize = Math.min( this.$slidesMask.height(), this.thumbnailsSize );
1725
+ this.$thumbnailsContainer.css( 'height', this.thumbnailsContainerSize );
1726
+ }
1727
+
1728
+ // If the total size of the thumbnails is smaller than the thumbnail scroller' container (which has
1729
+ // the same size as the slides container), it means that all the thumbnails will be visible, so set
1730
+ // the position of the thumbnail scroller to 0.
1731
+ //
1732
+ // If that's not the case, the thumbnail scroller will be positioned based on which thumbnail is selected.
1733
+ if ( this.thumbnailsSize <= this.thumbnailsContainerSize || this.$thumbnails.find( '.sp-selected-thumbnail' ).length === 0 ) {
1734
+ newThumbnailsPosition = 0;
1735
+ } else {
1736
+ newThumbnailsPosition = Math.max( - this.thumbnails[ this.selectedThumbnailIndex ].getPosition()[ this.thumbnailsPositionProperty ], this.thumbnailsContainerSize - this.thumbnailsSize );
1737
+ }
1738
+
1739
+ // Add a padding to the slider, based on the thumbnail scroller's orientation, to make room
1740
+ // for the thumbnails.
1741
+ if ( this.settings.thumbnailsPosition === 'top' ) {
1742
+ this.$slider.css({ 'paddingTop': this.$thumbnailsContainer.outerHeight( true ), 'paddingLeft': '', 'paddingRight': '' });
1743
+ } else if ( this.settings.thumbnailsPosition === 'bottom' ) {
1744
+ this.$slider.css({ 'paddingTop': '', 'paddingLeft': '', 'paddingRight': '' });
1745
+ } else if ( this.settings.thumbnailsPosition === 'left' ) {
1746
+ this.$slider.css({ 'paddingTop': '', 'paddingLeft': this.$thumbnailsContainer.outerWidth( true ), 'paddingRight': '' });
1747
+ } else if ( this.settings.thumbnailsPosition === 'right' ) {
1748
+ this.$slider.css({ 'paddingTop': '', 'paddingLeft': '', 'paddingRight': this.$thumbnailsContainer.outerWidth( true ) });
1749
+ }
1750
+
1751
+ this._moveThumbnailsTo( newThumbnailsPosition, true );
1752
+ },
1753
+
1754
+ // Selects the thumbnail at the indicated index and moves the thumbnail scroller
1755
+ // accordingly.
1756
+ _gotoThumbnail: function( index ) {
1757
+ if ( this.isThumbnailScroller === false || typeof this.thumbnails[ index ] === 'undefined' ) {
1758
+ return;
1759
+ }
1760
+
1761
+ var previousIndex = this.selectedThumbnailIndex,
1762
+ newThumbnailsPosition = this.thumbnailsPosition;
1763
+
1764
+ this.selectedThumbnailIndex = index;
1765
+
1766
+ // Set the 'selected' class to the appropriate thumbnail
1767
+ this.$thumbnails.find( '.sp-selected-thumbnail' ).removeClass( 'sp-selected-thumbnail' );
1768
+ this.$thumbnails.find( '.sp-thumbnail-container' ).eq( this.selectedThumbnailIndex ).addClass( 'sp-selected-thumbnail' );
1769
+
1770
+ // Calculate the new position that the thumbnail scroller needs to go to.
1771
+ //
1772
+ // If the selected thumbnail has a higher index than the previous one, make sure that the thumbnail
1773
+ // that comes after the selected thumbnail will be visible, if the selected thumbnail is not the
1774
+ // last thumbnail in the list.
1775
+ //
1776
+ // If the selected thumbnail has a lower index than the previous one, make sure that the thumbnail
1777
+ // that's before the selected thumbnail will be visible, if the selected thumbnail is not the
1778
+ // first thumbnail in the list.
1779
+ if ( this.selectedThumbnailIndex >= previousIndex ) {
1780
+ var nextThumbnailIndex = this.selectedThumbnailIndex === this.thumbnails.length - 1 ? this.selectedThumbnailIndex : this.selectedThumbnailIndex + 1,
1781
+ nextThumbnail = this.thumbnails[ nextThumbnailIndex ],
1782
+ nextThumbnailPosition = this.thumbnailsOrientation === 'horizontal' ? nextThumbnail.getPosition().right : nextThumbnail.getPosition().bottom,
1783
+ thumbnailsRightPosition = - this.thumbnailsPosition + this.thumbnailsContainerSize;
1784
+
1785
+ if ( nextThumbnailPosition > thumbnailsRightPosition ) {
1786
+ newThumbnailsPosition = this.thumbnailsPosition - ( nextThumbnailPosition - thumbnailsRightPosition );
1787
+ }
1788
+ } else if ( this.selectedThumbnailIndex < previousIndex ) {
1789
+ var previousThumbnailIndex = this.selectedThumbnailIndex === 0 ? this.selectedThumbnailIndex : this.selectedThumbnailIndex - 1,
1790
+ previousThumbnail = this.thumbnails[ previousThumbnailIndex ],
1791
+ previousThumbnailPosition = this.thumbnailsOrientation === 'horizontal' ? previousThumbnail.getPosition().left : previousThumbnail.getPosition().top;
1792
+
1793
+ if ( previousThumbnailPosition < - this.thumbnailsPosition ) {
1794
+ newThumbnailsPosition = - previousThumbnailPosition;
1795
+ }
1796
+ }
1797
+
1798
+ // Move the thumbnail scroller to the calculated position
1799
+ this._moveThumbnailsTo( newThumbnailsPosition );
1800
+
1801
+ // Fire the 'gotoThumbnail' event
1802
+ this.trigger({ type: 'gotoThumbnail' });
1803
+ if ( $.isFunction( this.settings.gotoThumbnail ) ) {
1804
+ this.settings.gotoThumbnail.call( this, { type: 'gotoThumbnail' });
1805
+ }
1806
+ },
1807
+
1808
+ // Move the thumbnail scroller to the indicated position
1809
+ _moveThumbnailsTo: function( position, instant, callback ) {
1810
+ var that = this,
1811
+ css = {};
1812
+
1813
+ // Return if the position hasn't changed
1814
+ if ( position === this.thumbnailsPosition ) {
1815
+ return;
1816
+ }
1817
+
1818
+ this.thumbnailsPosition = position;
1819
+
1820
+ // Use CSS transitions if they are supported. If not, use JavaScript animation
1821
+ if ( this.supportedAnimation === 'css-3d' || this.supportedAnimation === 'css-2d' ) {
1822
+ var transition,
1823
+ left = this.thumbnailsOrientation === 'horizontal' ? position : 0,
1824
+ top = this.thumbnailsOrientation === 'horizontal' ? 0 : position;
1825
+
1826
+ if ( this.supportedAnimation === 'css-3d' ) {
1827
+ css[ this.vendorPrefix + 'transform' ] = 'translate3d(' + left + 'px, ' + top + 'px, 0)';
1828
+ } else {
1829
+ css[ this.vendorPrefix + 'transform' ] = 'translate(' + left + 'px, ' + top + 'px)';
1830
+ }
1831
+
1832
+ if ( typeof instant !== 'undefined' && instant === true ) {
1833
+ transition = '';
1834
+ } else {
1835
+ this.$thumbnails.addClass( 'sp-animated' );
1836
+ transition = this.vendorPrefix + 'transform ' + 700 / 1000 + 's';
1837
+
1838
+ this.$thumbnails.on( this.transitionEvent, function( event ) {
1839
+ if ( event.target !== event.currentTarget ) {
1840
+ return;
1841
+ }
1842
+
1843
+ that.$thumbnails.off( that.transitionEvent );
1844
+ that.$thumbnails.removeClass( 'sp-animated' );
1845
+
1846
+ if ( typeof callback === 'function' ) {
1847
+ callback();
1848
+ }
1849
+
1850
+ // Fire the 'thumbnailsMoveComplete' event
1851
+ that.trigger({ type: 'thumbnailsMoveComplete' });
1852
+ if ( $.isFunction( that.settings.thumbnailsMoveComplete ) ) {
1853
+ that.settings.thumbnailsMoveComplete.call( that, { type: 'thumbnailsMoveComplete' });
1854
+ }
1855
+ });
1856
+ }
1857
+
1858
+ css[ this.vendorPrefix + 'transition' ] = transition;
1859
+
1860
+ this.$thumbnails.css( css );
1861
+ } else {
1862
+ css[ 'margin-' + this.thumbnailsPositionProperty ] = position;
1863
+
1864
+ if ( typeof instant !== 'undefined' && instant === true ) {
1865
+ this.$thumbnails.css( css );
1866
+ } else {
1867
+ this.$thumbnails
1868
+ .addClass( 'sp-animated' )
1869
+ .animate( css, 700, function() {
1870
+ that.$thumbnails.removeClass( 'sp-animated' );
1871
+
1872
+ if ( typeof callback === 'function' ) {
1873
+ callback();
1874
+ }
1875
+
1876
+ // Fire the 'thumbnailsMoveComplete' event
1877
+ that.trigger({ type: 'thumbnailsMoveComplete' });
1878
+ if ( $.isFunction( that.settings.thumbnailsMoveComplete ) ) {
1879
+ that.settings.thumbnailsMoveComplete.call( that, { type: 'thumbnailsMoveComplete' });
1880
+ }
1881
+ });
1882
+ }
1883
+ }
1884
+ },
1885
+
1886
+ // Stop the movement of the thumbnail scroller
1887
+ _stopThumbnailsMovement: function() {
1888
+ var css = {};
1889
+
1890
+ if ( this.supportedAnimation === 'css-3d' || this.supportedAnimation === 'css-2d' ) {
1891
+ var matrixString = this.$thumbnails.css( this.vendorPrefix + 'transform' ),
1892
+ matrixType = matrixString.indexOf( 'matrix3d' ) !== -1 ? 'matrix3d' : 'matrix',
1893
+ matrixArray = matrixString.replace( matrixType, '' ).match( /-?[0-9\.]+/g ),
1894
+ left = matrixType === 'matrix3d' ? parseInt( matrixArray[ 12 ], 10 ) : parseInt( matrixArray[ 4 ], 10 ),
1895
+ top = matrixType === 'matrix3d' ? parseInt( matrixArray[ 13 ], 10 ) : parseInt( matrixArray[ 5 ], 10 );
1896
+
1897
+ if ( this.supportedAnimation === 'css-3d' ) {
1898
+ css[ this.vendorPrefix + 'transform' ] = 'translate3d(' + left + 'px, ' + top + 'px, 0)';
1899
+ } else {
1900
+ css[ this.vendorPrefix + 'transform' ] = 'translate(' + left + 'px, ' + top + 'px)';
1901
+ }
1902
+
1903
+ css[ this.vendorPrefix + 'transition' ] = '';
1904
+
1905
+ this.$thumbnails.css( css );
1906
+ this.$thumbnails.off( this.transitionEvent );
1907
+ this.thumbnailsPosition = this.thumbnailsOrientation === 'horizontal' ? parseInt( matrixArray[ 4 ] , 10 ) : parseInt( matrixArray[ 5 ] , 10 );
1908
+ } else {
1909
+ this.$thumbnails.stop();
1910
+ this.thumbnailsPosition = parseInt( this.$thumbnails.css( 'margin-' + this.thumbnailsPositionProperty ), 10 );
1911
+ }
1912
+
1913
+ this.$thumbnails.removeClass( 'sp-animated' );
1914
+ },
1915
+
1916
+ // Destroy the module
1917
+ destroyThumbnails: function() {
1918
+ var that = this;
1919
+
1920
+ // Remove event listeners
1921
+ this.off( 'update.' + NS );
1922
+
1923
+ if ( this.isThumbnailScroller === false ) {
1924
+ return;
1925
+ }
1926
+
1927
+ this.off( 'sliderResize.' + NS );
1928
+ this.off( 'gotoSlide.' + NS );
1929
+ $( window ).off( 'resize.' + this.uniqueId + '.' + NS );
1930
+
1931
+ // Destroy the individual thumbnails
1932
+ this.$thumbnails.find( '.sp-thumbnail' ).each( function() {
1933
+ var $thumbnail = $( this ),
1934
+ index = parseInt( $thumbnail.attr( 'data-index' ), 10 ),
1935
+ thumbnail = that.thumbnails[ index ];
1936
+
1937
+ thumbnail.off( 'thumbnailClick.' + NS );
1938
+ thumbnail.destroy();
1939
+ });
1940
+
1941
+ this.thumbnails.length = 0;
1942
+
1943
+ // Add the thumbnail scroller directly in the slider and
1944
+ // remove the thumbnail scroller container
1945
+ this.$thumbnails.appendTo( this.$slider );
1946
+ this.$thumbnailsContainer.remove();
1947
+
1948
+ // Remove any created padding
1949
+ this.$slider.css({ 'paddingTop': '', 'paddingLeft': '', 'paddingRight': '' });
1950
+ },
1951
+
1952
+ thumbnailsDefaults: {
1953
+
1954
+ // Sets the width of the thumbnail
1955
+ thumbnailWidth: 100,
1956
+
1957
+ // Sets the height of the thumbnail
1958
+ thumbnailHeight: 80,
1959
+
1960
+ // Sets the position of the thumbnail scroller (top, bottom, right, left)
1961
+ thumbnailsPosition: 'bottom',
1962
+
1963
+ // Indicates if a pointer will be displayed for the selected thumbnail
1964
+ thumbnailPointer: false,
1965
+
1966
+ // Called when the thumbnails are updated
1967
+ thumbnailsUpdate: function() {},
1968
+
1969
+ // Called when a new thumbnail is selected
1970
+ gotoThumbnail: function() {},
1971
+
1972
+ // Called when the thumbnail scroller has moved
1973
+ thumbnailsMoveComplete: function() {}
1974
+ }
1975
+ };
1976
+
1977
+ var Thumbnail = function( thumbnail, thumbnails, index ) {
1978
+
1979
+ // Reference to the thumbnail jQuery element
1980
+ this.$thumbnail = thumbnail;
1981
+
1982
+ // Reference to the thumbnail scroller
1983
+ this.$thumbnails = thumbnails;
1984
+
1985
+ // Reference to the thumbnail's container, which will be
1986
+ // created dynamically.
1987
+ this.$thumbnailContainer = null;
1988
+
1989
+ // The width and height of the thumbnail
1990
+ this.width = 0;
1991
+ this.height = 0;
1992
+
1993
+ // Indicates whether the thumbnail's image is loaded
1994
+ this.isImageLoaded = false;
1995
+
1996
+ // Set the index of the slide
1997
+ this.setIndex( index );
1998
+
1999
+ // Initialize the thumbnail
2000
+ this._init();
2001
+ };
2002
+
2003
+ Thumbnail.prototype = {
2004
+
2005
+ _init: function() {
2006
+ var that = this;
2007
+
2008
+ // Mark the thumbnail as initialized
2009
+ this.$thumbnail.attr( 'data-init', true );
2010
+
2011
+ // Create a container for the thumbnail and add the original thumbnail to this container.
2012
+ // Having a container will help crop the thumbnail image if it's too large.
2013
+ this.$thumbnailContainer = $( '<div class="sp-thumbnail-container"></div>' ).appendTo( this.$thumbnails );
2014
+
2015
+ if ( this.$thumbnail.parent( 'a' ).length !== 0 ) {
2016
+ this.$thumbnail.parent( 'a' ).appendTo( this.$thumbnailContainer );
2017
+ } else {
2018
+ this.$thumbnail.appendTo( this.$thumbnailContainer );
2019
+ }
2020
+
2021
+ // When the thumbnail container is clicked, fire an event
2022
+ this.$thumbnailContainer.on( 'click.' + NS, function() {
2023
+ that.trigger({ type: 'thumbnailClick.' + NS, index: that.index });
2024
+ });
2025
+ },
2026
+
2027
+ // Set the width and height of the thumbnail
2028
+ setSize: function( width, height ) {
2029
+ this.width = width;
2030
+ this.height = height;
2031
+
2032
+ // Apply the width and height to the thumbnail's container
2033
+ this.$thumbnailContainer.css({ 'width': this.width, 'height': this.height });
2034
+
2035
+ // If there is an image, resize it to fit the thumbnail container
2036
+ if ( this.$thumbnail.is( 'img' ) && typeof this.$thumbnail.attr( 'data-src' ) === 'undefined' ) {
2037
+ this.resizeImage();
2038
+ }
2039
+ },
2040
+
2041
+ // Return the width and height of the thumbnail
2042
+ getSize: function() {
2043
+ return {
2044
+ width: this.$thumbnailContainer.outerWidth( true ),
2045
+ height: this.$thumbnailContainer.outerHeight( true )
2046
+ };
2047
+ },
2048
+
2049
+ // Return the top, bottom, left and right position of the thumbnail
2050
+ getPosition: function() {
2051
+ return {
2052
+ left: this.$thumbnailContainer.position().left + parseInt( this.$thumbnailContainer.css( 'marginLeft' ) , 10 ),
2053
+ right: this.$thumbnailContainer.position().left + parseInt( this.$thumbnailContainer.css( 'marginLeft' ) , 10 ) + this.$thumbnailContainer.outerWidth(),
2054
+ top: this.$thumbnailContainer.position().top + parseInt( this.$thumbnailContainer.css( 'marginTop' ) , 10 ),
2055
+ bottom: this.$thumbnailContainer.position().top + parseInt( this.$thumbnailContainer.css( 'marginTop' ) , 10 ) + this.$thumbnailContainer.outerHeight()
2056
+ };
2057
+ },
2058
+
2059
+ // Set the index of the thumbnail
2060
+ setIndex: function( index ) {
2061
+ this.index = index;
2062
+ this.$thumbnail.attr( 'data-index', this.index );
2063
+ },
2064
+
2065
+ // Resize the thumbnail's image
2066
+ resizeImage: function() {
2067
+ var that = this;
2068
+
2069
+ // If the image is not loaded yet, load it
2070
+ if ( this.isImageLoaded === false ) {
2071
+ SliderProUtils.checkImagesComplete( this.$thumbnailContainer , function() {
2072
+ that.isImageLoaded = true;
2073
+ that.resizeImage();
2074
+ });
2075
+
2076
+ return;
2077
+ }
2078
+
2079
+ // Get the reference to the thumbnail image again because it was replaced by
2080
+ // another img element during the loading process
2081
+ this.$thumbnail = this.$thumbnailContainer.find( '.sp-thumbnail' );
2082
+
2083
+ // Calculate whether the image should stretch horizontally or vertically
2084
+ var imageWidth = this.$thumbnail.width(),
2085
+ imageHeight = this.$thumbnail.height();
2086
+
2087
+ if ( imageWidth / imageHeight <= this.width / this.height ) {
2088
+ this.$thumbnail.css({ width: '100%', height: 'auto' });
2089
+ } else {
2090
+ this.$thumbnail.css({ width: 'auto', height: '100%' });
2091
+ }
2092
+
2093
+ this.$thumbnail.css({ 'marginLeft': ( this.$thumbnailContainer.width() - this.$thumbnail.width() ) * 0.5, 'marginTop': ( this.$thumbnailContainer.height() - this.$thumbnail.height() ) * 0.5 });
2094
+ },
2095
+
2096
+ // Destroy the thumbnail
2097
+ destroy: function() {
2098
+ this.$thumbnailContainer.off( 'click.' + NS );
2099
+
2100
+ // Remove added attributes
2101
+ this.$thumbnail.removeAttr( 'data-init' );
2102
+ this.$thumbnail.removeAttr( 'data-index' );
2103
+
2104
+ // Remove the thumbnail's container and add the thumbnail
2105
+ // back to the thumbnail scroller container
2106
+ if ( this.$thumbnail.parent( 'a' ).length !== 0 ) {
2107
+ this.$thumbnail.parent( 'a' ).insertBefore( this.$thumbnailContainer );
2108
+ } else {
2109
+ this.$thumbnail.insertBefore( this.$thumbnailContainer );
2110
+ }
2111
+
2112
+ this.$thumbnailContainer.remove();
2113
+ },
2114
+
2115
+ // Attach an event handler to the slide
2116
+ on: function( type, callback ) {
2117
+ return this.$thumbnailContainer.on( type, callback );
2118
+ },
2119
+
2120
+ // Detach an event handler to the slide
2121
+ off: function( type ) {
2122
+ return this.$thumbnailContainer.off( type );
2123
+ },
2124
+
2125
+ // Trigger an event on the slide
2126
+ trigger: function( data ) {
2127
+ return this.$thumbnailContainer.triggerHandler( data );
2128
+ }
2129
+ };
2130
+
2131
+ $.SliderPro.addModule( 'Thumbnails', Thumbnails );
2132
+
2133
+ })( window, jQuery );
2134
+
2135
+ // ConditionalImages module for Slider Pro.
2136
+ //
2137
+ // Adds the possibility to specify multiple sources for each image and
2138
+ // load the image that's the most appropriate for the size of the slider.
2139
+ // For example, instead of loading a large image even if the slider will be small
2140
+ // you can specify a smaller image that will be loaded instead.
2141
+ ;(function( window, $ ) {
2142
+
2143
+ "use strict";
2144
+
2145
+ var NS = 'ConditionalImages.' + $.SliderPro.namespace;
2146
+
2147
+ var ConditionalImages = {
2148
+
2149
+ // Reference to the previous size
2150
+ previousImageSize: null,
2151
+
2152
+ // Reference to the current size
2153
+ currentImageSize: null,
2154
+
2155
+ // Indicates if the current display supports high PPI
2156
+ isRetinaScreen: false,
2157
+
2158
+ initConditionalImages: function() {
2159
+ this.currentImageSize = this.previousImageSize = 'default';
2160
+ this.isRetinaScreen = ( typeof this._isRetina !== 'undefined' ) && ( this._isRetina() === true );
2161
+
2162
+ this.on( 'update.' + NS, $.proxy( this._conditionalImagesOnUpdate, this ) );
2163
+ this.on( 'sliderResize.' + NS, $.proxy( this._conditionalImagesOnResize, this ) );
2164
+ },
2165
+
2166
+ // Loop through all the existing images and specify the original path of the image
2167
+ // inside the 'data-default' attribute.
2168
+ _conditionalImagesOnUpdate: function() {
2169
+ $.each( this.slides, function( index, element ) {
2170
+ var $slide = element.$slide;
2171
+
2172
+ $slide.find( 'img:not([ data-default ])' ).each(function() {
2173
+ var $image = $( this );
2174
+
2175
+ if ( typeof $image.attr( 'data-src' ) !== 'undefined' ) {
2176
+ $image.attr( 'data-default', $image.attr( 'data-src' ) );
2177
+ } else {
2178
+ $image.attr( 'data-default', $image.attr( 'src' ) );
2179
+ }
2180
+ });
2181
+ });
2182
+ },
2183
+
2184
+ // When the window resizes, identify the applyable image size based on the current size of the slider
2185
+ // and apply it to all images that have a version of the image specified for this size.
2186
+ _conditionalImagesOnResize: function() {
2187
+ if ( this.slideWidth <= this.settings.smallSize ) {
2188
+ this.currentImageSize = 'small';
2189
+ } else if ( this.slideWidth <= this.settings.mediumSize ) {
2190
+ this.currentImageSize = 'medium';
2191
+ } else if ( this.slideWidth <= this.settings.largeSize ) {
2192
+ this.currentImageSize = 'large';
2193
+ } else {
2194
+ this.currentImageSize = 'default';
2195
+ }
2196
+
2197
+ if ( this.previousImageSize !== this.currentImageSize ) {
2198
+ var that = this;
2199
+
2200
+ $.each( this.slides, function( index, element ) {
2201
+ var $slide = element.$slide;
2202
+
2203
+ $slide.find( 'img' ).each(function() {
2204
+ var $image = $( this ),
2205
+ imageSource = '';
2206
+
2207
+ // Check if the current display supports high PPI and if a retina version of the current size was specified
2208
+ if ( that.isRetinaScreen === true && typeof $image.attr( 'data-retina' + that.currentImageSize ) !== 'undefined' ) {
2209
+ imageSource = $image.attr( 'data-retina' + that.currentImageSize );
2210
+
2211
+ // If the retina image was not loaded yet, replace the default image source with the one
2212
+ // that corresponds to the current slider size
2213
+ if ( typeof $image.attr( 'data-retina' ) !== 'undefined' && $image.attr( 'data-retina' ) !== imageSource ) {
2214
+ $image.attr( 'data-retina', imageSource );
2215
+ }
2216
+ } else if ( ( that.isRetinaScreen === false || that.isRetinaScreen === true && typeof $image.attr( 'data-retina' ) === 'undefined' ) && typeof $image.attr( 'data-' + that.currentImageSize ) !== 'undefined' ) {
2217
+ imageSource = $image.attr( 'data-' + that.currentImageSize );
2218
+
2219
+ // If the image is set to lazy load, replace the image source with the one
2220
+ // that corresponds to the current slider size
2221
+ if ( typeof $image.attr( 'data-src' ) !== 'undefined' && $image.attr( 'data-src' ) !== imageSource ) {
2222
+ $image.attr( 'data-src', imageSource );
2223
+ }
2224
+ }
2225
+
2226
+ // If a new image was found
2227
+ if ( imageSource !== '' ) {
2228
+
2229
+ // The existence of the 'data-src' attribute indicates that the image
2230
+ // will be lazy loaded, so don't load the new image yet
2231
+ if ( typeof $image.attr( 'data-src' ) === 'undefined' && $image.attr( 'src' ) !== imageSource ) {
2232
+ that._loadConditionalImage( $image, imageSource, function( newImage ) {
2233
+ if ( newImage.hasClass( 'sp-image' ) ) {
2234
+ element.$mainImage = newImage;
2235
+ element.resizeMainImage( true );
2236
+ }
2237
+ });
2238
+ }
2239
+ }
2240
+ });
2241
+ });
2242
+
2243
+ this.previousImageSize = this.currentImageSize;
2244
+ }
2245
+ },
2246
+
2247
+ // Replace the target image with a new image
2248
+ _loadConditionalImage: function( image, source, callback ) {
2249
+
2250
+ // Create a new image element
2251
+ var newImage = $( new Image() );
2252
+
2253
+ // Copy the class(es) and inline style
2254
+ newImage.attr( 'class', image.attr( 'class' ) );
2255
+ newImage.attr( 'style', image.attr( 'style' ) );
2256
+
2257
+ // Copy the data attributes
2258
+ $.each( image.data(), function( name, value ) {
2259
+ newImage.attr( 'data-' + name, value );
2260
+ });
2261
+
2262
+ // Copy the width and height attributes if they exist
2263
+ if ( typeof image.attr( 'width' ) !== 'undefined') {
2264
+ newImage.attr( 'width', image.attr( 'width' ) );
2265
+ }
2266
+
2267
+ if ( typeof image.attr( 'height' ) !== 'undefined') {
2268
+ newImage.attr( 'height', image.attr( 'height' ) );
2269
+ }
2270
+
2271
+ if ( typeof image.attr( 'alt' ) !== 'undefined' ) {
2272
+ newImage.attr( 'alt', image.attr( 'alt' ) );
2273
+ }
2274
+
2275
+ if ( typeof image.attr( 'title' ) !== 'undefined' ) {
2276
+ newImage.attr( 'title', image.attr( 'title' ) );
2277
+ }
2278
+
2279
+ newImage.attr( 'src', source );
2280
+
2281
+ // Add the new image in the same container and remove the older image
2282
+ newImage.insertAfter( image );
2283
+ image.remove();
2284
+ image = null;
2285
+
2286
+ if ( typeof callback === 'function' ) {
2287
+ callback( newImage );
2288
+ }
2289
+ },
2290
+
2291
+ // Destroy the module
2292
+ destroyConditionalImages: function() {
2293
+ this.off( 'update.' + NS );
2294
+ this.off( 'sliderResize.' + NS );
2295
+ },
2296
+
2297
+ conditionalImagesDefaults: {
2298
+
2299
+ // If the slider size is below this size, the small version of the images will be used
2300
+ smallSize: 480,
2301
+
2302
+ // If the slider size is below this size, the small version of the images will be used
2303
+ mediumSize: 768,
2304
+
2305
+ // If the slider size is below this size, the small version of the images will be used
2306
+ largeSize: 1024
2307
+ }
2308
+ };
2309
+
2310
+ $.SliderPro.addModule( 'ConditionalImages', ConditionalImages );
2311
+
2312
+ })( window, jQuery );
2313
+
2314
+ // Retina module for Slider Pro.
2315
+ //
2316
+ // Adds the possibility to load a different image when the slider is
2317
+ // viewed on a retina screen.
2318
+ ;(function( window, $ ) {
2319
+
2320
+ "use strict";
2321
+
2322
+ var NS = 'Retina.' + $.SliderPro.namespace;
2323
+
2324
+ var Retina = {
2325
+
2326
+ initRetina: function() {
2327
+ var that = this;
2328
+
2329
+ // Return if it's not a retina screen
2330
+ if ( this._isRetina() === false ) {
2331
+ return;
2332
+ }
2333
+
2334
+ this.on( 'update.' + NS, $.proxy( this._checkRetinaImages, this ) );
2335
+
2336
+ if ( this.$slider.find( '.sp-thumbnail' ).length !== 0 ) {
2337
+ this.on( 'update.Thumbnails.' + NS, $.proxy( this._checkRetinaThumbnailImages, this ) );
2338
+ }
2339
+ },
2340
+
2341
+ // Checks if the current display supports high PPI
2342
+ _isRetina: function() {
2343
+ if ( window.devicePixelRatio >= 2 ) {
2344
+ return true;
2345
+ }
2346
+
2347
+ if ( window.matchMedia && ( window.matchMedia( "(-webkit-min-device-pixel-ratio: 2),(min-resolution: 2dppx)" ).matches ) ) {
2348
+ return true;
2349
+ }
2350
+
2351
+ return false;
2352
+ },
2353
+
2354
+ // Loop through the slides and replace the images with their retina version
2355
+ _checkRetinaImages: function() {
2356
+ var that = this;
2357
+
2358
+ $.each( this.slides, function( index, element ) {
2359
+ var $slide = element.$slide;
2360
+
2361
+ if ( typeof $slide.attr( 'data-retina-loaded' ) === 'undefined' ) {
2362
+ $slide.attr( 'data-retina-loaded', true );
2363
+
2364
+ $slide.find( 'img[data-retina]' ).each(function() {
2365
+ var $image = $( this );
2366
+
2367
+ if ( typeof $image.attr( 'data-src' ) !== 'undefined' ) {
2368
+ $image.attr( 'data-src', $image.attr( 'data-retina' ) );
2369
+ } else {
2370
+ that._loadRetinaImage( $image, function( newImage ) {
2371
+ if ( newImage.hasClass( 'sp-image' ) ) {
2372
+ element.$mainImage = newImage;
2373
+ element.resizeMainImage( true );
2374
+ }
2375
+ });
2376
+ }
2377
+ });
2378
+ }
2379
+ });
2380
+ },
2381
+
2382
+ // Loop through the thumbnails and replace the images with their retina version
2383
+ _checkRetinaThumbnailImages: function() {
2384
+ var that = this;
2385
+
2386
+ $.each( this.thumbnails, function( index, element ) {
2387
+ var $thumbnail = element.$thumbnailContainer;
2388
+
2389
+ if ( typeof $thumbnail.attr( 'data-retina-loaded' ) === 'undefined' ) {
2390
+ $thumbnail.attr( 'data-retina-loaded', true );
2391
+
2392
+ $thumbnail.find( 'img[data-retina]' ).each(function() {
2393
+ var $image = $( this );
2394
+
2395
+ if ( typeof $image.attr( 'data-src' ) !== 'undefined' ) {
2396
+ $image.attr( 'data-src', $image.attr( 'data-retina' ) );
2397
+ } else {
2398
+ that._loadRetinaImage( $image, function( newImage ) {
2399
+ if ( newImage.hasClass( 'sp-thumbnail' ) ) {
2400
+ element.resizeImage();
2401
+ }
2402
+ });
2403
+ }
2404
+ });
2405
+ }
2406
+ });
2407
+ },
2408
+
2409
+ // Load the retina image
2410
+ _loadRetinaImage: function( image, callback ) {
2411
+ var retinaFound = false,
2412
+ newImagePath = '';
2413
+
2414
+ // Check if there is a retina image specified
2415
+ if ( typeof image.attr( 'data-retina' ) !== 'undefined' ) {
2416
+ retinaFound = true;
2417
+
2418
+ newImagePath = image.attr( 'data-retina' );
2419
+ }
2420
+
2421
+ // Check if there is a lazy loaded, non-retina, image specified
2422
+ if ( typeof image.attr( 'data-src' ) !== 'undefined' ) {
2423
+ if ( retinaFound === false ) {
2424
+ newImagePath = image.attr( 'data-src') ;
2425
+ }
2426
+
2427
+ image.removeAttr('data-src');
2428
+ }
2429
+
2430
+ // Return if there isn't a retina or lazy loaded image
2431
+ if ( newImagePath === '' ) {
2432
+ return;
2433
+ }
2434
+
2435
+ // Create a new image element
2436
+ var newImage = $( new Image() );
2437
+
2438
+ // Copy the class(es) and inline style
2439
+ newImage.attr( 'class', image.attr('class') );
2440
+ newImage.attr( 'style', image.attr('style') );
2441
+
2442
+ // Copy the data attributes
2443
+ $.each( image.data(), function( name, value ) {
2444
+ newImage.attr( 'data-' + name, value );
2445
+ });
2446
+
2447
+ // Copy the width and height attributes if they exist
2448
+ if ( typeof image.attr( 'width' ) !== 'undefined' ) {
2449
+ newImage.attr( 'width', image.attr( 'width' ) );
2450
+ }
2451
+
2452
+ if ( typeof image.attr( 'height' ) !== 'undefined' ) {
2453
+ newImage.attr( 'height', image.attr( 'height' ) );
2454
+ }
2455
+
2456
+ if ( typeof image.attr( 'alt' ) !== 'undefined' ) {
2457
+ newImage.attr( 'alt', image.attr( 'alt' ) );
2458
+ }
2459
+
2460
+ if ( typeof image.attr( 'title' ) !== 'undefined' ) {
2461
+ newImage.attr( 'title', image.attr( 'title' ) );
2462
+ }
2463
+
2464
+ // Add the new image in the same container and remove the older image
2465
+ newImage.insertAfter( image );
2466
+ image.remove();
2467
+ image = null;
2468
+
2469
+ // Assign the source of the image
2470
+ newImage.attr( 'src', newImagePath );
2471
+
2472
+ if ( typeof callback === 'function' ) {
2473
+ callback( newImage );
2474
+ }
2475
+ },
2476
+
2477
+ // Destroy the module
2478
+ destroyRetina: function() {
2479
+ this.off( 'update.' + NS );
2480
+ this.off( 'update.Thumbnails.' + NS );
2481
+ }
2482
+ };
2483
+
2484
+ $.SliderPro.addModule( 'Retina', Retina );
2485
+
2486
+ })( window, jQuery );
2487
+
2488
+ // Lazy Loading module for Slider Pro.
2489
+ //
2490
+ // Adds the possibility to delay the loading of the images until the slides/thumbnails
2491
+ // that contain them become visible. This technique improves the initial loading
2492
+ // performance.
2493
+ ;(function( window, $ ) {
2494
+
2495
+ "use strict";
2496
+
2497
+ var NS = 'LazyLoading.' + $.SliderPro.namespace;
2498
+
2499
+ var LazyLoading = {
2500
+
2501
+ allowLazyLoadingCheck: true,
2502
+
2503
+ initLazyLoading: function() {
2504
+ var that = this;
2505
+
2506
+ // The 'resize' event is fired after every update, so it's possible to use it for checking
2507
+ // if the update made new slides become visible
2508
+ //
2509
+ // Also, resizing the slider might make new slides or thumbnails visible
2510
+ this.on( 'sliderResize.' + NS, $.proxy( this._lazyLoadingOnResize, this ) );
2511
+
2512
+ // Check visible images when a new slide is selected
2513
+ this.on( 'gotoSlide.' + NS, $.proxy( this._checkAndLoadVisibleImages, this ) );
2514
+
2515
+ // Check visible thumbnail images when the thumbnails are updated because new thumbnail
2516
+ // might have been added or the settings might have been changed so that more thumbnail
2517
+ // images become visible
2518
+ //
2519
+ // Also, check visible thumbnail images after the thumbnails have moved because new thumbnails might
2520
+ // have become visible
2521
+ this.on( 'thumbnailsUpdate.' + NS + ' ' + 'thumbnailsMoveComplete.' + NS, $.proxy( this._checkAndLoadVisibleThumbnailImages, this ) );
2522
+ },
2523
+
2524
+ _lazyLoadingOnResize: function() {
2525
+ var that = this;
2526
+
2527
+ if ( this.allowLazyLoadingCheck === false ) {
2528
+ return;
2529
+ }
2530
+
2531
+ this.allowLazyLoadingCheck = false;
2532
+
2533
+ this._checkAndLoadVisibleImages();
2534
+
2535
+ if ( this.$slider.find( '.sp-thumbnail' ).length !== 0 ) {
2536
+ this._checkAndLoadVisibleThumbnailImages();
2537
+ }
2538
+
2539
+ // Use a timer to deffer the loading of images in order to prevent too many
2540
+ // checking attempts
2541
+ setTimeout(function() {
2542
+ that.allowLazyLoadingCheck = true;
2543
+ }, 500 );
2544
+ },
2545
+
2546
+ // Check visible slides and load their images
2547
+ _checkAndLoadVisibleImages: function() {
2548
+ if ( this.$slider.find( '.sp-slide:not([ data-loaded ])' ).length === 0 ) {
2549
+ return;
2550
+ }
2551
+
2552
+ var that = this,
2553
+
2554
+ // Use either the middle position or the index of the selected slide as a reference, depending on
2555
+ // whether the slider is loopable
2556
+ referencePosition = this.settings.loop === true ? this.middleSlidePosition : this.selectedSlideIndex,
2557
+
2558
+ // Calculate how many slides are visible at the sides of the selected slide
2559
+ visibleOnSides = Math.ceil( ( this.visibleSlidesSize - this.slideSize ) / 2 / this.slideSize ),
2560
+
2561
+ // Calculate the indexes of the first and last slide that will be checked
2562
+ from = referencePosition - visibleOnSides - 1 > 0 ? referencePosition - visibleOnSides - 1 : 0,
2563
+ to = referencePosition + visibleOnSides + 1 < this.getTotalSlides() - 1 ? referencePosition + visibleOnSides + 1 : this.getTotalSlides() - 1,
2564
+
2565
+ // Get all the slides that need to be checked
2566
+ slidesToCheck = this.slidesOrder.slice( from, to + 1 );
2567
+
2568
+ // Loop through the selected slides and if the slide is not marked as having
2569
+ // been loaded yet, loop through its images and load them.
2570
+ $.each( slidesToCheck, function( index, element ) {
2571
+ var slide = that.slides[ element ],
2572
+ $slide = slide.$slide;
2573
+
2574
+ if ( typeof $slide.attr( 'data-loaded' ) === 'undefined' ) {
2575
+ $slide.attr( 'data-loaded', true );
2576
+
2577
+ $slide.find( 'img[ data-src ]' ).each(function() {
2578
+ var image = $( this );
2579
+ that._loadImage( image, function( newImage ) {
2580
+ if ( newImage.hasClass( 'sp-image' ) ) {
2581
+ slide.$mainImage = newImage;
2582
+ slide.resizeMainImage( true );
2583
+ }
2584
+ });
2585
+ });
2586
+ }
2587
+ });
2588
+ },
2589
+
2590
+ // Check visible thumbnails and load their images
2591
+ _checkAndLoadVisibleThumbnailImages: function() {
2592
+ if ( this.$slider.find( '.sp-thumbnail-container:not([ data-loaded ])' ).length === 0 ) {
2593
+ return;
2594
+ }
2595
+
2596
+ var that = this,
2597
+ thumbnailSize = this.thumbnailsSize / this.thumbnails.length,
2598
+
2599
+ // Calculate the indexes of the first and last thumbnail that will be checked
2600
+ from = Math.floor( Math.abs( this.thumbnailsPosition / thumbnailSize ) ),
2601
+ to = Math.floor( ( - this.thumbnailsPosition + this.thumbnailsContainerSize ) / thumbnailSize ),
2602
+
2603
+ // Get all the thumbnails that need to be checked
2604
+ thumbnailsToCheck = this.thumbnails.slice( from, to + 1 );
2605
+
2606
+ // Loop through the selected thumbnails and if the thumbnail is not marked as having
2607
+ // been loaded yet, load its image.
2608
+ $.each( thumbnailsToCheck, function( index, element ) {
2609
+ var $thumbnailContainer = element.$thumbnailContainer;
2610
+
2611
+ if ( typeof $thumbnailContainer.attr( 'data-loaded' ) === 'undefined' ) {
2612
+ $thumbnailContainer.attr( 'data-loaded', true );
2613
+
2614
+ $thumbnailContainer.find( 'img[ data-src ]' ).each(function() {
2615
+ var image = $( this );
2616
+
2617
+ that._loadImage( image, function() {
2618
+ element.resizeImage();
2619
+ });
2620
+ });
2621
+ }
2622
+ });
2623
+ },
2624
+
2625
+ // Load an image
2626
+ _loadImage: function( image, callback ) {
2627
+ // Create a new image element
2628
+ var newImage = $( new Image() );
2629
+
2630
+ // Copy the class(es) and inline style
2631
+ newImage.attr( 'class', image.attr( 'class' ) );
2632
+ newImage.attr( 'style', image.attr( 'style' ) );
2633
+
2634
+ // Copy the data attributes
2635
+ $.each( image.data(), function( name, value ) {
2636
+ newImage.attr( 'data-' + name, value );
2637
+ });
2638
+
2639
+ // Copy the width and height attributes if they exist
2640
+ if ( typeof image.attr( 'width' ) !== 'undefined') {
2641
+ newImage.attr( 'width', image.attr( 'width' ) );
2642
+ }
2643
+
2644
+ if ( typeof image.attr( 'height' ) !== 'undefined') {
2645
+ newImage.attr( 'height', image.attr( 'height' ) );
2646
+ }
2647
+
2648
+ if ( typeof image.attr( 'alt' ) !== 'undefined' ) {
2649
+ newImage.attr( 'alt', image.attr( 'alt' ) );
2650
+ }
2651
+
2652
+ if ( typeof image.attr( 'title' ) !== 'undefined' ) {
2653
+ newImage.attr( 'title', image.attr( 'title' ) );
2654
+ }
2655
+
2656
+ // Assign the source of the image
2657
+ newImage.attr( 'src', image.attr( 'data-src' ) );
2658
+ newImage.removeAttr( 'data-src' );
2659
+
2660
+ // Add the new image in the same container and remove the older image
2661
+ newImage.insertAfter( image );
2662
+ image.remove();
2663
+ image = null;
2664
+
2665
+ if ( typeof callback === 'function' ) {
2666
+ callback( newImage );
2667
+ }
2668
+ },
2669
+
2670
+ // Destroy the module
2671
+ destroyLazyLoading: function() {
2672
+ this.off( 'update.' + NS );
2673
+ this.off( 'gotoSlide.' + NS );
2674
+ this.off( 'sliderResize.' + NS );
2675
+ this.off( 'thumbnailsUpdate.' + NS );
2676
+ this.off( 'thumbnailsMoveComplete.' + NS );
2677
+ }
2678
+ };
2679
+
2680
+ $.SliderPro.addModule( 'LazyLoading', LazyLoading );
2681
+
2682
+ })( window, jQuery );
2683
+
2684
+ // Layers module for Slider Pro.
2685
+ //
2686
+ // Adds support for animated and static layers. The layers can contain any content,
2687
+ // from simple text for video elements.
2688
+ ;(function( window, $ ) {
2689
+
2690
+ "use strict";
2691
+
2692
+ var NS = 'Layers.' + $.SliderPro.namespace;
2693
+
2694
+ var Layers = {
2695
+
2696
+ // Reference to the original 'gotoSlide' method
2697
+ layersGotoSlideReference: null,
2698
+
2699
+ // Reference to the timer that will delay the overriding
2700
+ // of the 'gotoSlide' method
2701
+ waitForLayersTimer: null,
2702
+
2703
+ initLayers: function() {
2704
+ this.on( 'update.' + NS, $.proxy( this._layersOnUpdate, this ) );
2705
+ this.on( 'sliderResize.' + NS, $.proxy( this._layersOnResize, this ) );
2706
+ this.on( 'gotoSlide.' + NS, $.proxy( this._layersOnGotoSlide, this ) );
2707
+ },
2708
+
2709
+ // Loop through the slides and initialize all layers
2710
+ _layersOnUpdate: function( event ) {
2711
+ var that = this;
2712
+
2713
+ $.each( this.slides, function( index, element ) {
2714
+ var $slide = element.$slide;
2715
+
2716
+ // Initialize the layers
2717
+ this.$slide.find( '.sp-layer:not([ data-layer-init ])' ).each(function() {
2718
+ var layer = new Layer( $( this ) );
2719
+
2720
+ // Add the 'layers' array to the slide objects (instance of SliderProSlide)
2721
+ if ( typeof element.layers === 'undefined' ) {
2722
+ element.layers = [];
2723
+ }
2724
+
2725
+ element.layers.push( layer );
2726
+
2727
+ if ( $( this ).hasClass( 'sp-static' ) === false ) {
2728
+
2729
+ // Add the 'animatedLayers' array to the slide objects (instance of SliderProSlide)
2730
+ if ( typeof element.animatedLayers === 'undefined' ) {
2731
+ element.animatedLayers = [];
2732
+ }
2733
+
2734
+ element.animatedLayers.push( layer );
2735
+ }
2736
+ });
2737
+ });
2738
+
2739
+ // If the 'waitForLayers' option is enabled, the slider will not move to another slide
2740
+ // until all the layers from the previous slide will be hidden. To achieve this,
2741
+ // replace the current 'gotoSlide' function with another function that will include the
2742
+ // required functionality.
2743
+ //
2744
+ // Since the 'gotoSlide' method might be overridden by other modules as well, delay this
2745
+ // override to make sure it's the last override.
2746
+ if ( this.settings.waitForLayers === true ) {
2747
+ clearTimeout( this.waitForLayersTimer );
2748
+
2749
+ this.waitForLayersTimer = setTimeout(function() {
2750
+ that.layersGotoSlideReference = that.gotoSlide;
2751
+ that.gotoSlide = that._layersGotoSlide;
2752
+ }, 1 );
2753
+ }
2754
+
2755
+ // Show the layers for the initial slide
2756
+ // Delay the call in order to make sure the layers
2757
+ // are scaled properly before displaying them
2758
+ setTimeout(function() {
2759
+ that.showLayers( that.selectedSlideIndex );
2760
+ }, 1);
2761
+ },
2762
+
2763
+ // When the slider resizes, try to scale down the layers proportionally. The automatic scaling
2764
+ // will make use of an option, 'autoScaleReference', by comparing the current width of the slider
2765
+ // with the reference width. So, if the reference width is 1000 pixels and the current width is
2766
+ // 500 pixels, it means that the layers will be scaled down to 50% of their size.
2767
+ _layersOnResize: function() {
2768
+ var that = this,
2769
+ autoScaleReference,
2770
+ useAutoScale = this.settings.autoScaleLayers,
2771
+ scaleRatio;
2772
+
2773
+ if ( this.settings.autoScaleLayers === false ) {
2774
+ return;
2775
+ }
2776
+
2777
+ // If there isn't a reference for how the layers should scale down automatically, use the 'width'
2778
+ // option as a reference, unless the width was set to a percentage. If there isn't a set reference and
2779
+ // the width was set to a percentage, auto scaling will not be used because it's not possible to
2780
+ // calculate how much should the layers scale.
2781
+ if ( this.settings.autoScaleReference === -1 ) {
2782
+ if ( typeof this.settings.width === 'string' && this.settings.width.indexOf( '%' ) !== -1 ) {
2783
+ useAutoScale = false;
2784
+ } else {
2785
+ autoScaleReference = parseInt( this.settings.width, 10 );
2786
+ }
2787
+ } else {
2788
+ autoScaleReference = this.settings.autoScaleReference;
2789
+ }
2790
+
2791
+ if ( useAutoScale === true && this.slideWidth < autoScaleReference ) {
2792
+ scaleRatio = that.slideWidth / autoScaleReference;
2793
+ } else {
2794
+ scaleRatio = 1;
2795
+ }
2796
+
2797
+ $.each( this.slides, function( index, slide ) {
2798
+ if ( typeof slide.layers !== 'undefined' ) {
2799
+ $.each( slide.layers, function( index, layer ) {
2800
+ layer.scale( scaleRatio );
2801
+ });
2802
+ }
2803
+ });
2804
+ },
2805
+
2806
+ // Replace the 'gotoSlide' method with this one, which makes it possible to
2807
+ // change the slide only after the layers from the previous slide are hidden.
2808
+ _layersGotoSlide: function( index ) {
2809
+ var that = this,
2810
+ animatedLayers = this.slides[ this.selectedSlideIndex ].animatedLayers;
2811
+
2812
+ // If the slider is dragged, don't wait for the layer to hide
2813
+ if ( this.$slider.hasClass( 'sp-swiping' ) || typeof animatedLayers === 'undefined' || animatedLayers.length === 0 ) {
2814
+ this.layersGotoSlideReference( index );
2815
+ } else {
2816
+ this.on( 'hideLayersComplete.' + NS, function() {
2817
+ that.off( 'hideLayersComplete.' + NS );
2818
+ that.layersGotoSlideReference( index );
2819
+ });
2820
+
2821
+ this.hideLayers( this.selectedSlideIndex );
2822
+ }
2823
+ },
2824
+
2825
+ // When a new slide is selected, hide the layers from the previous slide
2826
+ // and show the layers from the current slide.
2827
+ _layersOnGotoSlide: function( event ) {
2828
+ if ( this.previousSlideIndex !== this.selectedSlideIndex && this.settings.waitForLayers === false ) {
2829
+ this.hideLayers( this.previousSlideIndex );
2830
+ }
2831
+
2832
+ this.showLayers( this.selectedSlideIndex );
2833
+ },
2834
+
2835
+ // Show the animated layers from the slide at the specified index,
2836
+ // and fire an event when all the layers from the slide become visible.
2837
+ showLayers: function( index ) {
2838
+ var that = this,
2839
+ animatedLayers = this.slides[ index ].animatedLayers,
2840
+ layerCounter = 0;
2841
+
2842
+ if ( typeof animatedLayers === 'undefined' ) {
2843
+ return;
2844
+ }
2845
+
2846
+ $.each( animatedLayers, function( index, element ) {
2847
+
2848
+ // If the layer is already visible, increment the counter directly, else wait
2849
+ // for the layer's showing animation to complete.
2850
+ if ( element.isVisible() === true ) {
2851
+ layerCounter++;
2852
+
2853
+ if ( layerCounter === animatedLayers.length ) {
2854
+ that.trigger({ type: 'showLayersComplete', index: index });
2855
+ if ( $.isFunction( that.settings.showLayersComplete ) ) {
2856
+ that.settings.showLayersComplete.call( that, { type: 'showLayersComplete', index: index });
2857
+ }
2858
+ }
2859
+ } else {
2860
+ element.show(function() {
2861
+ layerCounter++;
2862
+
2863
+ if ( layerCounter === animatedLayers.length ) {
2864
+ that.trigger({ type: 'showLayersComplete', index: index });
2865
+ if ( $.isFunction( that.settings.showLayersComplete ) ) {
2866
+ that.settings.showLayersComplete.call( that, { type: 'showLayersComplete', index: index });
2867
+ }
2868
+ }
2869
+ });
2870
+ }
2871
+ });
2872
+ },
2873
+
2874
+ // Hide the animated layers from the slide at the specified index,
2875
+ // and fire an event when all the layers from the slide become invisible.
2876
+ hideLayers: function( index ) {
2877
+ var that = this,
2878
+ animatedLayers = this.slides[ index ].animatedLayers,
2879
+ layerCounter = 0;
2880
+
2881
+ if ( typeof animatedLayers === 'undefined' ) {
2882
+ return;
2883
+ }
2884
+
2885
+ $.each( animatedLayers, function( index, element ) {
2886
+
2887
+ // If the layer is already invisible, increment the counter directly, else wait
2888
+ // for the layer's hiding animation to complete.
2889
+ if ( element.isVisible() === false ) {
2890
+ layerCounter++;
2891
+
2892
+ if ( layerCounter === animatedLayers.length ) {
2893
+ that.trigger({ type: 'hideLayersComplete', index: index });
2894
+ if ( $.isFunction( that.settings.hideLayersComplete ) ) {
2895
+ that.settings.hideLayersComplete.call( that, { type: 'hideLayersComplete', index: index });
2896
+ }
2897
+ }
2898
+ } else {
2899
+ element.hide(function() {
2900
+ layerCounter++;
2901
+
2902
+ if ( layerCounter === animatedLayers.length ) {
2903
+ that.trigger({ type: 'hideLayersComplete', index: index });
2904
+ if ( $.isFunction( that.settings.hideLayersComplete ) ) {
2905
+ that.settings.hideLayersComplete.call( that, { type: 'hideLayersComplete', index: index });
2906
+ }
2907
+ }
2908
+ });
2909
+ }
2910
+ });
2911
+ },
2912
+
2913
+ // Destroy the module
2914
+ destroyLayers: function() {
2915
+ this.off( 'update.' + NS );
2916
+ this.off( 'resize.' + NS );
2917
+ this.off( 'gotoSlide.' + NS );
2918
+ this.off( 'hideLayersComplete.' + NS );
2919
+ },
2920
+
2921
+ layersDefaults: {
2922
+
2923
+ // Indicates whether the slider will wait for the layers to disappear before
2924
+ // going to a new slide
2925
+ waitForLayers: false,
2926
+
2927
+ // Indicates whether the layers will be scaled automatically
2928
+ autoScaleLayers: true,
2929
+
2930
+ // Sets a reference width which will be compared to the current slider width
2931
+ // in order to determine how much the layers need to scale down. By default,
2932
+ // the reference width will be equal to the slide width. However, if the slide width
2933
+ // is set to a percentage value, then it's necessary to set a specific value for 'autoScaleReference'.
2934
+ autoScaleReference: -1,
2935
+
2936
+ // Called when all animated layers become visible
2937
+ showLayersComplete: function() {},
2938
+
2939
+ // Called when all animated layers become invisible
2940
+ hideLayersComplete: function() {}
2941
+ }
2942
+ };
2943
+
2944
+ // Override the slide's 'destroy' method in order to destroy the
2945
+ // layers that where added to the slide as well.
2946
+ var slideDestroy = window.SliderProSlide.prototype.destroy;
2947
+
2948
+ window.SliderProSlide.prototype.destroy = function() {
2949
+ if ( typeof this.layers !== 'undefined' ) {
2950
+ $.each( this.layers, function( index, element ) {
2951
+ element.destroy();
2952
+ });
2953
+
2954
+ this.layers.length = 0;
2955
+ }
2956
+
2957
+ if ( typeof this.animatedLayers !== 'undefined' ) {
2958
+ this.animatedLayers.length = 0;
2959
+ }
2960
+
2961
+ slideDestroy.apply( this );
2962
+ };
2963
+
2964
+ var Layer = function( layer ) {
2965
+
2966
+ // Reference to the layer jQuery element
2967
+ this.$layer = layer;
2968
+
2969
+ // Indicates whether a layer is currently visible or hidden
2970
+ this.visible = false;
2971
+
2972
+ // Indicates whether the layer was styled
2973
+ this.styled = false;
2974
+
2975
+ // Holds the data attributes added to the layer
2976
+ this.data = null;
2977
+
2978
+ // Indicates the layer's reference point (topLeft, bottomLeft, topRight or bottomRight)
2979
+ this.position = null;
2980
+
2981
+ // Indicates which CSS property (left or right) will be used for positioning the layer
2982
+ this.horizontalProperty = null;
2983
+
2984
+ // Indicates which CSS property (top or bottom) will be used for positioning the layer
2985
+ this.verticalProperty = null;
2986
+
2987
+ // Indicates the value of the horizontal position
2988
+ this.horizontalPosition = null;
2989
+
2990
+ // Indicates the value of the vertical position
2991
+ this.verticalPosition = null;
2992
+
2993
+ // Indicates how much the layers needs to be scaled
2994
+ this.scaleRatio = 1;
2995
+
2996
+ // Indicates the type of supported transition (CSS3 2D, CSS3 3D or JavaScript)
2997
+ this.supportedAnimation = SliderProUtils.getSupportedAnimation();
2998
+
2999
+ // Indicates the required vendor prefix for CSS (i.e., -webkit, -moz, etc.)
3000
+ this.vendorPrefix = SliderProUtils.getVendorPrefix();
3001
+
3002
+ // Indicates the name of the CSS transition's complete event (i.e., transitionend, webkitTransitionEnd, etc.)
3003
+ this.transitionEvent = SliderProUtils.getTransitionEvent();
3004
+
3005
+ // Reference to the timer that will be used to hide the layers automatically after a given time interval
3006
+ this.stayTimer = null;
3007
+
3008
+ this._init();
3009
+ };
3010
+
3011
+ Layer.prototype = {
3012
+
3013
+ // Initialize the layers
3014
+ _init: function() {
3015
+ this.$layer.attr( 'data-layer-init', true );
3016
+
3017
+ if ( this.$layer.hasClass( 'sp-static' ) ) {
3018
+ this._setStyle();
3019
+ } else {
3020
+ this.$layer.css({ 'visibility': 'hidden' });
3021
+ }
3022
+ },
3023
+
3024
+ // Set the size and position of the layer
3025
+ _setStyle: function() {
3026
+ this.styled = true;
3027
+
3028
+ // Get the data attributes specified in HTML
3029
+ this.data = this.$layer.data();
3030
+
3031
+ if ( typeof this.data.width !== 'undefined' ) {
3032
+ this.$layer.css( 'width', this.data.width );
3033
+ }
3034
+
3035
+ if ( typeof this.data.height !== 'undefined' ) {
3036
+ this.$layer.css( 'height', this.data.height );
3037
+ }
3038
+
3039
+ if ( typeof this.data.depth !== 'undefined' ) {
3040
+ this.$layer.css( 'z-index', this.data.depth );
3041
+ }
3042
+
3043
+ this.position = this.data.position ? ( this.data.position ).toLowerCase() : 'topleft';
3044
+
3045
+ if ( this.position.indexOf( 'right' ) !== -1 ) {
3046
+ this.horizontalProperty = 'right';
3047
+ } else if ( this.position.indexOf( 'left' ) !== -1 ) {
3048
+ this.horizontalProperty = 'left';
3049
+ } else {
3050
+ this.horizontalProperty = 'center';
3051
+ }
3052
+
3053
+ if ( this.position.indexOf( 'bottom' ) !== -1 ) {
3054
+ this.verticalProperty = 'bottom';
3055
+ } else if ( this.position.indexOf( 'top' ) !== -1 ) {
3056
+ this.verticalProperty = 'top';
3057
+ } else {
3058
+ this.verticalProperty = 'center';
3059
+ }
3060
+
3061
+ this._setPosition();
3062
+
3063
+ this.scale( this.scaleRatio );
3064
+ },
3065
+
3066
+ // Set the position of the layer
3067
+ _setPosition: function() {
3068
+ var inlineStyle = this.$layer.attr( 'style' );
3069
+
3070
+ this.horizontalPosition = typeof this.data.horizontal !== 'undefined' ? this.data.horizontal : 0;
3071
+ this.verticalPosition = typeof this.data.vertical !== 'undefined' ? this.data.vertical : 0;
3072
+
3073
+ // Set the horizontal position of the layer based on the data set
3074
+ if ( this.horizontalProperty === 'center' ) {
3075
+
3076
+ // prevent content wrapping while setting the width
3077
+ if ( this.$layer.is( 'img' ) === false && ( typeof inlineStyle === 'undefined' || ( typeof inlineStyle !== 'undefined' && inlineStyle.indexOf( 'width' ) === -1 ) ) ) {
3078
+ this.$layer.css( 'white-space', 'nowrap' );
3079
+ this.$layer.css( 'width', this.$layer.outerWidth( true ) );
3080
+ }
3081
+
3082
+ this.$layer.css({ 'marginLeft': 'auto', 'marginRight': 'auto', 'left': this.horizontalPosition, 'right': 0 });
3083
+ } else {
3084
+ this.$layer.css( this.horizontalProperty, this.horizontalPosition );
3085
+ }
3086
+
3087
+ // Set the vertical position of the layer based on the data set
3088
+ if ( this.verticalProperty === 'center' ) {
3089
+
3090
+ // prevent content wrapping while setting the height
3091
+ if ( this.$layer.is( 'img' ) === false && ( typeof inlineStyle === 'undefined' || ( typeof inlineStyle !== 'undefined' && inlineStyle.indexOf( 'height' ) === -1 ) ) ) {
3092
+ this.$layer.css( 'white-space', 'nowrap' );
3093
+ this.$layer.css( 'height', this.$layer.outerHeight( true ) );
3094
+ }
3095
+
3096
+ this.$layer.css({ 'marginTop': 'auto', 'marginBottom': 'auto', 'top': this.verticalPosition, 'bottom': 0 });
3097
+ } else {
3098
+ this.$layer.css( this.verticalProperty, this.verticalPosition );
3099
+ }
3100
+ },
3101
+
3102
+ // Scale the layer
3103
+ scale: function( ratio ) {
3104
+
3105
+ // Return if the layer is set to be unscalable
3106
+ if ( this.$layer.hasClass( 'sp-no-scale' ) ) {
3107
+ return;
3108
+ }
3109
+
3110
+ // Store the ratio (even if the layer is not ready to be scaled yet)
3111
+ this.scaleRatio = ratio;
3112
+
3113
+ // Return if the layer is not styled yet
3114
+ if ( this.styled === false ) {
3115
+ return;
3116
+ }
3117
+
3118
+ var horizontalProperty = this.horizontalProperty === 'center' ? 'left' : this.horizontalProperty,
3119
+ verticalProperty = this.verticalProperty === 'center' ? 'top' : this.verticalProperty,
3120
+ css = {};
3121
+
3122
+ // Apply the scaling
3123
+ css[ this.vendorPrefix + 'transform-origin' ] = this.horizontalProperty + ' ' + this.verticalProperty;
3124
+ css[ this.vendorPrefix + 'transform' ] = 'scale(' + this.scaleRatio + ')';
3125
+
3126
+ // If the position is not set to a percentage value, apply the scaling to the position
3127
+ if ( typeof this.horizontalPosition !== 'string' ) {
3128
+ css[ horizontalProperty ] = this.horizontalPosition * this.scaleRatio;
3129
+ }
3130
+
3131
+ // If the position is not set to a percentage value, apply the scaling to the position
3132
+ if ( typeof this.verticalPosition !== 'string' ) {
3133
+ css[ verticalProperty ] = this.verticalPosition * this.scaleRatio;
3134
+ }
3135
+
3136
+ // If the width or height is set to a percentage value, increase the percentage in order to
3137
+ // maintain the same layer to slide proportions. This is necessary because otherwise the scaling
3138
+ // transform would minimize the layers more than intended.
3139
+ if ( typeof this.data.width === 'string' && this.data.width.indexOf( '%' ) !== -1 ) {
3140
+ css.width = ( parseInt( this.data.width, 10 ) / this.scaleRatio ).toString() + '%';
3141
+ }
3142
+
3143
+ if ( typeof this.data.height === 'string' && this.data.height.indexOf( '%' ) !== -1 ) {
3144
+ css.height = ( parseInt( this.data.height, 10 ) / this.scaleRatio ).toString() + '%';
3145
+ }
3146
+
3147
+ this.$layer.css( css );
3148
+ },
3149
+
3150
+ // Show the layer
3151
+ show: function( callback ) {
3152
+ if ( this.visible === true ) {
3153
+ return;
3154
+ }
3155
+
3156
+ this.visible = true;
3157
+
3158
+ // First, style the layer if it's not already styled
3159
+ if ( this.styled === false ) {
3160
+ this._setStyle();
3161
+ }
3162
+
3163
+ var that = this,
3164
+ offset = typeof this.data.showOffset !== 'undefined' ? this.data.showOffset : 50,
3165
+ duration = typeof this.data.showDuration !== 'undefined' ? this.data.showDuration / 1000 : 0.4,
3166
+ delay = typeof this.data.showDelay !== 'undefined' ? this.data.showDelay : 10,
3167
+ stayDuration = typeof that.data.stayDuration !== 'undefined' ? parseInt( that.data.stayDuration, 10 ) : -1;
3168
+
3169
+ // Animate the layers with CSS3 or with JavaScript
3170
+ if ( this.supportedAnimation === 'javascript' ) {
3171
+ this.$layer
3172
+ .stop()
3173
+ .delay( delay )
3174
+ .css({ 'opacity': 0, 'visibility': 'visible' })
3175
+ .animate( { 'opacity': 1 }, duration * 1000, function() {
3176
+
3177
+ // Hide the layer after a given time interval
3178
+ if ( stayDuration !== -1 ) {
3179
+ that.stayTimer = setTimeout(function() {
3180
+ that.hide();
3181
+ that.stayTimer = null;
3182
+ }, stayDuration );
3183
+ }
3184
+
3185
+ if ( typeof callback !== 'undefined' ) {
3186
+ callback();
3187
+ }
3188
+ });
3189
+ } else {
3190
+ var start = { 'opacity': 0, 'visibility': 'visible' },
3191
+ target = { 'opacity': 1 },
3192
+ transformValues = '';
3193
+
3194
+ start[ this.vendorPrefix + 'transform' ] = 'scale(' + this.scaleRatio + ')';
3195
+ target[ this.vendorPrefix + 'transform' ] = 'scale(' + this.scaleRatio + ')';
3196
+ target[ this.vendorPrefix + 'transition' ] = 'opacity ' + duration + 's';
3197
+
3198
+ if ( typeof this.data.showTransition !== 'undefined' ) {
3199
+ if ( this.data.showTransition === 'left' ) {
3200
+ transformValues = offset + 'px, 0';
3201
+ } else if ( this.data.showTransition === 'right' ) {
3202
+ transformValues = '-' + offset + 'px, 0';
3203
+ } else if ( this.data.showTransition === 'up' ) {
3204
+ transformValues = '0, ' + offset + 'px';
3205
+ } else if ( this.data.showTransition === 'down') {
3206
+ transformValues = '0, -' + offset + 'px';
3207
+ }
3208
+
3209
+ start[ this.vendorPrefix + 'transform' ] += this.supportedAnimation === 'css-3d' ? ' translate3d(' + transformValues + ', 0)' : ' translate(' + transformValues + ')';
3210
+ target[ this.vendorPrefix + 'transform' ] += this.supportedAnimation === 'css-3d' ? ' translate3d(0, 0, 0)' : ' translate(0, 0)';
3211
+ target[ this.vendorPrefix + 'transition' ] += ', ' + this.vendorPrefix + 'transform ' + duration + 's';
3212
+ }
3213
+
3214
+ // Listen when the layer animation is complete
3215
+ this.$layer.on( this.transitionEvent, function( event ) {
3216
+ if ( event.target !== event.currentTarget ) {
3217
+ return;
3218
+ }
3219
+
3220
+ that.$layer
3221
+ .off( that.transitionEvent )
3222
+ .css( that.vendorPrefix + 'transition', '' );
3223
+
3224
+ // Hide the layer after a given time interval
3225
+ if ( stayDuration !== -1 ) {
3226
+ that.stayTimer = setTimeout(function() {
3227
+ that.hide();
3228
+ that.stayTimer = null;
3229
+ }, stayDuration );
3230
+ }
3231
+
3232
+ if ( typeof callback !== 'undefined' ) {
3233
+ callback();
3234
+ }
3235
+ });
3236
+
3237
+ this.$layer.css( start );
3238
+
3239
+ setTimeout( function() {
3240
+ that.$layer.css( target );
3241
+ }, delay );
3242
+ }
3243
+ },
3244
+
3245
+ // Hide the layer
3246
+ hide: function( callback ) {
3247
+ if ( this.visible === false ) {
3248
+ return;
3249
+ }
3250
+
3251
+ var that = this,
3252
+ offset = typeof this.data.hideOffset !== 'undefined' ? this.data.hideOffset : 50,
3253
+ duration = typeof this.data.hideDuration !== 'undefined' ? this.data.hideDuration / 1000 : 0.4,
3254
+ delay = typeof this.data.hideDelay !== 'undefined' ? this.data.hideDelay : 10;
3255
+
3256
+ this.visible = false;
3257
+
3258
+ // If the layer is hidden before it hides automatically, clear the timer
3259
+ if ( this.stayTimer !== null ) {
3260
+ clearTimeout( this.stayTimer );
3261
+ }
3262
+
3263
+ // Animate the layers with CSS3 or with JavaScript
3264
+ if ( this.supportedAnimation === 'javascript' ) {
3265
+ this.$layer
3266
+ .stop()
3267
+ .delay( delay )
3268
+ .animate({ 'opacity': 0 }, duration * 1000, function() {
3269
+ $( this ).css( 'visibility', 'hidden' );
3270
+
3271
+ if ( typeof callback !== 'undefined' ) {
3272
+ callback();
3273
+ }
3274
+ });
3275
+ } else {
3276
+ var transformValues = '',
3277
+ target = { 'opacity': 0 };
3278
+
3279
+ target[ this.vendorPrefix + 'transform' ] = 'scale(' + this.scaleRatio + ')';
3280
+ target[ this.vendorPrefix + 'transition' ] = 'opacity ' + duration + 's';
3281
+
3282
+ if ( typeof this.data.hideTransition !== 'undefined' ) {
3283
+ if ( this.data.hideTransition === 'left' ) {
3284
+ transformValues = '-' + offset + 'px, 0';
3285
+ } else if ( this.data.hideTransition === 'right' ) {
3286
+ transformValues = offset + 'px, 0';
3287
+ } else if ( this.data.hideTransition === 'up' ) {
3288
+ transformValues = '0, -' + offset + 'px';
3289
+ } else if ( this.data.hideTransition === 'down' ) {
3290
+ transformValues = '0, ' + offset + 'px';
3291
+ }
3292
+
3293
+ target[ this.vendorPrefix + 'transform' ] += this.supportedAnimation === 'css-3d' ? ' translate3d(' + transformValues + ', 0)' : ' translate(' + transformValues + ')';
3294
+ target[ this.vendorPrefix + 'transition' ] += ', ' + this.vendorPrefix + 'transform ' + duration + 's';
3295
+ }
3296
+
3297
+ // Listen when the layer animation is complete
3298
+ this.$layer.on( this.transitionEvent, function( event ) {
3299
+ if ( event.target !== event.currentTarget ) {
3300
+ return;
3301
+ }
3302
+
3303
+ that.$layer
3304
+ .off( that.transitionEvent )
3305
+ .css( that.vendorPrefix + 'transition', '' );
3306
+
3307
+ // Hide the layer after transition
3308
+ if ( that.visible === false ) {
3309
+ that.$layer.css( 'visibility', 'hidden' );
3310
+ }
3311
+
3312
+ if ( typeof callback !== 'undefined' ) {
3313
+ callback();
3314
+ }
3315
+ });
3316
+
3317
+ setTimeout( function() {
3318
+ that.$layer.css( target );
3319
+ }, delay );
3320
+ }
3321
+ },
3322
+
3323
+ isVisible: function() {
3324
+ if ( this.visible === false || this.$layer.is( ':hidden' ) ) {
3325
+ return false;
3326
+ }
3327
+
3328
+ return true;
3329
+ },
3330
+
3331
+ // Destroy the layer
3332
+ destroy: function() {
3333
+ this.$layer.removeAttr( 'style' );
3334
+ this.$layer.removeAttr( 'data-layer-init' );
3335
+ }
3336
+ };
3337
+
3338
+ $.SliderPro.addModule( 'Layers', Layers );
3339
+
3340
+ })( window, jQuery );
3341
+
3342
+ // Fade module for Slider Pro.
3343
+ //
3344
+ // Adds the possibility to navigate through slides using a cross-fade effect.
3345
+ ;(function( window, $ ) {
3346
+
3347
+ "use strict";
3348
+
3349
+ var NS = 'Fade.' + $.SliderPro.namespace;
3350
+
3351
+ var Fade = {
3352
+
3353
+ // Reference to the original 'gotoSlide' method
3354
+ fadeGotoSlideReference: null,
3355
+
3356
+ initFade: function() {
3357
+ this.on( 'update.' + NS, $.proxy( this._fadeOnUpdate, this ) );
3358
+ },
3359
+
3360
+ // If fade is enabled, store a reference to the original 'gotoSlide' method
3361
+ // and then assign a new function to 'gotoSlide'.
3362
+ _fadeOnUpdate: function() {
3363
+ if ( this.settings.fade === true ) {
3364
+ this.fadeGotoSlideReference = this.gotoSlide;
3365
+ this.gotoSlide = this._fadeGotoSlide;
3366
+ }
3367
+ },
3368
+
3369
+ // Will replace the original 'gotoSlide' function by adding a cross-fade effect
3370
+ // between the previous and the next slide.
3371
+ _fadeGotoSlide: function( index ) {
3372
+ if ( index === this.selectedSlideIndex ) {
3373
+ return;
3374
+ }
3375
+
3376
+ // If the slides are being swiped/dragged, don't use fade, but call the original method instead.
3377
+ // If not, which means that a new slide was selected through a button, arrows or direct call, then
3378
+ // use fade.
3379
+ if ( this.$slider.hasClass( 'sp-swiping' ) ) {
3380
+ this.fadeGotoSlideReference( index );
3381
+ } else {
3382
+ var that = this,
3383
+ $nextSlide,
3384
+ $previousSlide,
3385
+ newIndex = index;
3386
+
3387
+ // Loop through all the slides and overlap the the previous and next slide,
3388
+ // and hide the other slides.
3389
+ $.each( this.slides, function( index, element ) {
3390
+ var slideIndex = element.getIndex(),
3391
+ $slide = element.$slide;
3392
+
3393
+ if ( slideIndex === newIndex ) {
3394
+ $slide.css({ 'opacity': 0, 'left': 0, 'top': 0, 'z-index': 20 });
3395
+ $nextSlide = $slide;
3396
+ } else if ( slideIndex === that.selectedSlideIndex ) {
3397
+ $slide.css({ 'opacity': 1, 'left': 0, 'top': 0, 'z-index': 10 });
3398
+ $previousSlide = $slide;
3399
+ } else {
3400
+ $slide.css( 'visibility', 'hidden' );
3401
+ }
3402
+ });
3403
+
3404
+ // Set the new indexes for the previous and selected slides
3405
+ this.previousSlideIndex = this.selectedSlideIndex;
3406
+ this.selectedSlideIndex = index;
3407
+
3408
+ // Re-assign the 'sp-selected' class to the currently selected slide
3409
+ this.$slides.find( '.sp-selected' ).removeClass( 'sp-selected' );
3410
+ this.$slides.find( '.sp-slide' ).eq( this.selectedSlideIndex ).addClass( 'sp-selected' );
3411
+
3412
+ // Rearrange the slides if the slider is loopable
3413
+ if ( that.settings.loop === true ) {
3414
+ that._updateSlidesOrder();
3415
+ }
3416
+
3417
+ // Move the slides container so that the cross-fading slides (which now have the top and left
3418
+ // position set to 0) become visible and in the center of the slider.
3419
+ this._moveTo( this.visibleOffset, true );
3420
+
3421
+ // Fade out the previous slide, if indicated, in addition to fading in the next slide
3422
+ if ( this.settings.fadeOutPreviousSlide === true ) {
3423
+ this._fadeSlideTo( $previousSlide, 0 );
3424
+ }
3425
+
3426
+ // Fade in the selected slide
3427
+ this._fadeSlideTo( $nextSlide, 1, function() {
3428
+
3429
+ // After the animation is over, make all the slides visible again
3430
+ $.each( that.slides, function( index, element ) {
3431
+ var $slide = element.$slide;
3432
+ $slide.css({ 'visibility': '', 'opacity': '', 'z-index': '' });
3433
+ });
3434
+
3435
+ // Reset the position of the slides and slides container
3436
+ that._resetSlidesPosition();
3437
+
3438
+ // Fire the 'gotoSlideComplete' event
3439
+ that.trigger({ type: 'gotoSlideComplete', index: index, previousIndex: that.previousSlideIndex });
3440
+ if ( $.isFunction( that.settings.gotoSlideComplete ) ) {
3441
+ that.settings.gotoSlideComplete.call( that, { type: 'gotoSlideComplete', index: index, previousIndex: that.previousSlideIndex } );
3442
+ }
3443
+ });
3444
+
3445
+ if ( this.settings.autoHeight === true ) {
3446
+ this._resizeHeight();
3447
+ }
3448
+
3449
+ // Fire the 'gotoSlide' event
3450
+ this.trigger({ type: 'gotoSlide', index: index, previousIndex: this.previousSlideIndex });
3451
+ if ( $.isFunction( this.settings.gotoSlide ) ) {
3452
+ this.settings.gotoSlide.call( this, { type: 'gotoSlide', index: index, previousIndex: this.previousSlideIndex });
3453
+ }
3454
+ }
3455
+ },
3456
+
3457
+ // Fade the target slide to the specified opacity (0 or 1)
3458
+ _fadeSlideTo: function( target, opacity, callback ) {
3459
+ var that = this;
3460
+
3461
+ // Use CSS transitions if they are supported. If not, use JavaScript animation.
3462
+ if ( this.supportedAnimation === 'css-3d' || this.supportedAnimation === 'css-2d' ) {
3463
+
3464
+ // There needs to be a delay between the moment the opacity is set
3465
+ // and the moment the transitions starts.
3466
+ setTimeout(function(){
3467
+ var css = { 'opacity': opacity };
3468
+ css[ that.vendorPrefix + 'transition' ] = 'opacity ' + that.settings.fadeDuration / 1000 + 's';
3469
+ target.css( css );
3470
+ }, 100 );
3471
+
3472
+ target.on( this.transitionEvent, function( event ) {
3473
+ if ( event.target !== event.currentTarget ) {
3474
+ return;
3475
+ }
3476
+
3477
+ target.off( that.transitionEvent );
3478
+ target.css( that.vendorPrefix + 'transition', '' );
3479
+
3480
+ if ( typeof callback === 'function' ) {
3481
+ callback();
3482
+ }
3483
+ });
3484
+ } else {
3485
+ target.stop().animate({ 'opacity': opacity }, this.settings.fadeDuration, function() {
3486
+ if ( typeof callback === 'function' ) {
3487
+ callback();
3488
+ }
3489
+ });
3490
+ }
3491
+ },
3492
+
3493
+ // Destroy the module
3494
+ destroyFade: function() {
3495
+ this.off( 'update.' + NS );
3496
+
3497
+ if ( this.fadeGotoSlideReference !== null ) {
3498
+ this.gotoSlide = this.fadeGotoSlideReference;
3499
+ }
3500
+ },
3501
+
3502
+ fadeDefaults: {
3503
+
3504
+ // Indicates if fade will be used
3505
+ fade: false,
3506
+
3507
+ // Indicates if the previous slide will be faded out (in addition to the next slide being faded in)
3508
+ fadeOutPreviousSlide: true,
3509
+
3510
+ // Sets the duration of the fade effect
3511
+ fadeDuration: 500
3512
+ }
3513
+ };
3514
+
3515
+ $.SliderPro.addModule( 'Fade', Fade );
3516
+
3517
+ })( window, jQuery );
3518
+
3519
+ // Touch Swipe module for Slider Pro.
3520
+ //
3521
+ // Adds touch-swipe functionality for slides.
3522
+ ;(function( window, $ ) {
3523
+
3524
+ "use strict";
3525
+
3526
+ var NS = 'TouchSwipe.' + $.SliderPro.namespace;
3527
+
3528
+ var TouchSwipe = {
3529
+
3530
+ // The x and y coordinates of the pointer/finger's starting position
3531
+ touchStartPoint: {x: 0, y: 0},
3532
+
3533
+ // The x and y coordinates of the pointer/finger's end position
3534
+ touchEndPoint: {x: 0, y: 0},
3535
+
3536
+ // The distance from the starting to the end position on the x and y axis
3537
+ touchDistance: {x: 0, y: 0},
3538
+
3539
+ // The position of the slides when the touch swipe starts
3540
+ touchStartPosition: 0,
3541
+
3542
+ // Indicates if the slides are being swiped
3543
+ isTouchMoving: false,
3544
+
3545
+ // Stores the names of the events
3546
+ touchSwipeEvents: { startEvent: '', moveEvent: '', endEvent: '' },
3547
+
3548
+ initTouchSwipe: function() {
3549
+ var that = this;
3550
+
3551
+ // check if touch swipe is enabled
3552
+ if ( this.settings.touchSwipe === false ) {
3553
+ return;
3554
+ }
3555
+
3556
+ this.touchSwipeEvents.startEvent = 'touchstart' + '.' + NS + ' mousedown' + '.' + NS;
3557
+ this.touchSwipeEvents.moveEvent = 'touchmove' + '.' + NS + ' mousemove' + '.' + NS;
3558
+ this.touchSwipeEvents.endEvent = 'touchend' + '.' + this.uniqueId + '.' + NS + ' mouseup' + '.' + this.uniqueId + '.' + NS;
3559
+
3560
+ // Listen for touch swipe/mouse move events
3561
+ this.$slidesMask.on( this.touchSwipeEvents.startEvent, $.proxy( this._onTouchStart, this ) );
3562
+ this.$slidesMask.on( 'dragstart.' + NS, function( event ) {
3563
+ event.preventDefault();
3564
+ });
3565
+
3566
+ // Add the grabbing icon
3567
+ this.$slidesMask.addClass( 'sp-grab' );
3568
+ },
3569
+
3570
+ // Called when the slides starts being dragged
3571
+ _onTouchStart: function( event ) {
3572
+
3573
+ // Disable dragging if the element is set to allow selections
3574
+ if ( $( event.target ).closest( '.sp-selectable' ).length >= 1 ) {
3575
+ return;
3576
+ }
3577
+
3578
+ var that = this,
3579
+ eventObject = typeof event.originalEvent.touches !== 'undefined' ? event.originalEvent.touches[0] : event.originalEvent;
3580
+
3581
+ // Prevent default behavior only for mouse events
3582
+ if ( typeof event.originalEvent.touches === 'undefined' ) {
3583
+ event.preventDefault();
3584
+ }
3585
+
3586
+ // Disable click events on links
3587
+ $( event.target ).parents( '.sp-slide' ).find( 'a' ).one( 'click.' + NS, function( event ) {
3588
+ event.preventDefault();
3589
+ });
3590
+
3591
+ // Get the initial position of the mouse pointer and the initial position
3592
+ // of the slides' container
3593
+ this.touchStartPoint.x = eventObject.pageX || eventObject.clientX;
3594
+ this.touchStartPoint.y = eventObject.pageY || eventObject.clientY;
3595
+ this.touchStartPosition = this.slidesPosition;
3596
+
3597
+ // Clear the previous distance values
3598
+ this.touchDistance.x = this.touchDistance.y = 0;
3599
+
3600
+ // If the slides are being grabbed while they're still animating, stop the
3601
+ // current movement
3602
+ if ( this.$slides.hasClass( 'sp-animated' ) ) {
3603
+ this.isTouchMoving = true;
3604
+ this._stopMovement();
3605
+ this.touchStartPosition = this.slidesPosition;
3606
+ }
3607
+
3608
+ // Listen for move and end events
3609
+ this.$slidesMask.on( this.touchSwipeEvents.moveEvent, $.proxy( this._onTouchMove, this ) );
3610
+ $( document ).on( this.touchSwipeEvents.endEvent, $.proxy( this._onTouchEnd, this ) );
3611
+
3612
+ // Swap grabbing icons
3613
+ this.$slidesMask.removeClass( 'sp-grab' ).addClass( 'sp-grabbing' );
3614
+
3615
+ // Add 'sp-swiping' class to indicate that the slides are being swiped
3616
+ this.$slider.addClass( 'sp-swiping' );
3617
+ },
3618
+
3619
+ // Called during the slides' dragging
3620
+ _onTouchMove: function( event ) {
3621
+ var eventObject = typeof event.originalEvent.touches !== 'undefined' ? event.originalEvent.touches[0] : event.originalEvent;
3622
+
3623
+ // Indicate that the move event is being fired
3624
+ this.isTouchMoving = true;
3625
+
3626
+ // Get the current position of the mouse pointer
3627
+ this.touchEndPoint.x = eventObject.pageX || eventObject.clientX;
3628
+ this.touchEndPoint.y = eventObject.pageY || eventObject.clientY;
3629
+
3630
+ // Calculate the distance of the movement on both axis
3631
+ this.touchDistance.x = this.touchEndPoint.x - this.touchStartPoint.x;
3632
+ this.touchDistance.y = this.touchEndPoint.y - this.touchStartPoint.y;
3633
+
3634
+ // Calculate the distance of the swipe that takes place in the same direction as the orientation of the slides
3635
+ // and calculate the distance from the opposite direction.
3636
+ //
3637
+ // For a swipe to be valid there should more distance in the same direction as the orientation of the slides.
3638
+ var distance = this.settings.orientation === 'horizontal' ? this.touchDistance.x : this.touchDistance.y,
3639
+ oppositeDistance = this.settings.orientation === 'horizontal' ? this.touchDistance.y : this.touchDistance.x;
3640
+
3641
+ // If the movement is in the same direction as the orientation of the slides, the swipe is valid
3642
+ if ( Math.abs( distance ) > Math.abs( oppositeDistance ) ) {
3643
+ event.preventDefault();
3644
+ } else {
3645
+ return;
3646
+ }
3647
+
3648
+ if ( this.settings.loop === false ) {
3649
+ // Make the slides move slower if they're dragged outside its bounds
3650
+ if ( ( this.slidesPosition > this.touchStartPosition && this.selectedSlideIndex === 0 ) ||
3651
+ ( this.slidesPosition < this.touchStartPosition && this.selectedSlideIndex === this.getTotalSlides() - 1 )
3652
+ ) {
3653
+ distance = distance * 0.2;
3654
+ }
3655
+ }
3656
+
3657
+ this._moveTo( this.touchStartPosition + distance, true );
3658
+ },
3659
+
3660
+ // Called when the slides are released
3661
+ _onTouchEnd: function( event ) {
3662
+ var that = this,
3663
+ touchDistance = this.settings.orientation === 'horizontal' ? this.touchDistance.x : this.touchDistance.y;
3664
+
3665
+ // Remove the move and end listeners
3666
+ this.$slidesMask.off( this.touchSwipeEvents.moveEvent );
3667
+ $( document ).off( this.touchSwipeEvents.endEvent );
3668
+
3669
+ // Swap grabbing icons
3670
+ this.$slidesMask.removeClass( 'sp-grabbing' ).addClass( 'sp-grab' );
3671
+
3672
+ // Check if there is intention for a tap
3673
+ if ( this.isTouchMoving === false || this.isTouchMoving === true && Math.abs( this.touchDistance.x ) < 10 && Math.abs( this.touchDistance.y ) < 10 ) {
3674
+ // Re-enable click events on links
3675
+ $( event.target ).parents( '.sp-slide' ).find( 'a' ).off( 'click.' + NS );
3676
+ this.$slider.removeClass( 'sp-swiping' );
3677
+ }
3678
+
3679
+ // Remove the 'sp-swiping' class but with a delay
3680
+ // because there might be other event listeners that check
3681
+ // the existence of this class, and this class should still be
3682
+ // applied for those listeners, since there was a swipe event
3683
+ setTimeout(function() {
3684
+ that.$slider.removeClass( 'sp-swiping' );
3685
+ }, 1 );
3686
+
3687
+ // Return if the slides didn't move
3688
+ if ( this.isTouchMoving === false ) {
3689
+ return;
3690
+ }
3691
+
3692
+ this.isTouchMoving = false;
3693
+
3694
+ $( event.target ).parents( '.sp-slide' ).one( 'click', function( event ) {
3695
+ event.preventDefault();
3696
+ });
3697
+
3698
+ // Calculate the old position of the slides in order to return to it if the swipe
3699
+ // is below the threshold
3700
+ var oldSlidesPosition = - parseInt( this.$slides.find( '.sp-slide' ).eq( this.selectedSlideIndex ).css( this.positionProperty ), 10 ) + this.visibleOffset;
3701
+
3702
+ if ( Math.abs( touchDistance ) < this.settings.touchSwipeThreshold ) {
3703
+ this._moveTo( oldSlidesPosition );
3704
+ } else {
3705
+
3706
+ // Calculate by how many slides the slides container has moved
3707
+ var slideArrayDistance = touchDistance / ( this.slideSize + this.settings.slideDistance );
3708
+
3709
+ // Floor the obtained value and add or subtract 1, depending on the direction of the swipe
3710
+ slideArrayDistance = parseInt( slideArrayDistance, 10 ) + ( slideArrayDistance > 0 ? 1 : - 1 );
3711
+
3712
+ // Get the index of the currently selected slide and subtract the position index in order to obtain
3713
+ // the new index of the selected slide.
3714
+ var nextSlideIndex = this.slidesOrder[ $.inArray( this.selectedSlideIndex, this.slidesOrder ) - slideArrayDistance ];
3715
+
3716
+ if ( this.settings.loop === true ) {
3717
+ this.gotoSlide( nextSlideIndex );
3718
+ } else {
3719
+ if ( typeof nextSlideIndex !== 'undefined' ) {
3720
+ this.gotoSlide( nextSlideIndex );
3721
+ } else {
3722
+ this._moveTo( oldSlidesPosition );
3723
+ }
3724
+ }
3725
+ }
3726
+ },
3727
+
3728
+ // Destroy the module
3729
+ destroyTouchSwipe: function() {
3730
+ this.$slidesMask.off( this.touchSwipeEvents.startEvent );
3731
+ this.$slidesMask.off( this.touchSwipeEvents.moveEvent );
3732
+ this.$slidesMask.off( 'dragstart.' + NS );
3733
+ $( document ).off( this.touchSwipeEvents.endEvent );
3734
+ this.$slidesMask.removeClass( 'sp-grab' );
3735
+ },
3736
+
3737
+ touchSwipeDefaults: {
3738
+
3739
+ // Indicates whether the touch swipe will be enabled
3740
+ touchSwipe: true,
3741
+
3742
+ // Sets the minimum amount that the slides should move
3743
+ touchSwipeThreshold: 50
3744
+ }
3745
+ };
3746
+
3747
+ $.SliderPro.addModule( 'TouchSwipe', TouchSwipe );
3748
+
3749
+ })( window, jQuery );
3750
+
3751
+ // Caption module for Slider Pro.
3752
+ //
3753
+ // Adds a corresponding caption for each slide. The caption
3754
+ // will appear and disappear with the slide.
3755
+ ;(function( window, $ ) {
3756
+
3757
+ "use strict";
3758
+
3759
+ var NS = 'Caption.' + $.SliderPro.namespace;
3760
+
3761
+ var Caption = {
3762
+
3763
+ // Reference to the container element that will hold the caption
3764
+ $captionContainer: null,
3765
+
3766
+ // The caption content/text
3767
+ captionContent: '',
3768
+
3769
+ initCaption: function() {
3770
+ this.on( 'update.' + NS, $.proxy( this._captionOnUpdate, this ) );
3771
+ this.on( 'gotoSlide.' + NS, $.proxy( this._updateCaptionContent, this ) );
3772
+ },
3773
+
3774
+ // Create the caption container and hide the captions inside the slides
3775
+ _captionOnUpdate: function() {
3776
+ this.$captionContainer = this.$slider.find( '.sp-caption-container' );
3777
+
3778
+ if ( this.$slider.find( '.sp-caption' ).length && this.$captionContainer.length === 0 ) {
3779
+ this.$captionContainer = $( '<div class="sp-caption-container"></div>' ).appendTo( this.$slider );
3780
+
3781
+ // Show the caption for the selected slide
3782
+ this._updateCaptionContent();
3783
+ }
3784
+
3785
+ // Hide the captions inside the slides
3786
+ this.$slides.find( '.sp-caption' ).each(function() {
3787
+ $( this ).css( 'display', 'none' );
3788
+ });
3789
+ },
3790
+
3791
+ // Show the caption content for the selected slide
3792
+ _updateCaptionContent: function() {
3793
+ var that = this,
3794
+ newCaptionField = this.$slider.find( '.sp-slide' ).eq( this.selectedSlideIndex ).find( '.sp-caption' ),
3795
+ newCaptionContent = newCaptionField.length !== 0 ? newCaptionField.html() : '';
3796
+
3797
+ // Either use a fade effect for swapping the captions or use an instant change
3798
+ if ( this.settings.fadeCaption === true ) {
3799
+
3800
+ // If the previous slide had a caption, fade out that caption first and when the animation is over
3801
+ // fade in the current caption.
3802
+ // If the previous slide didn't have a caption, fade in the current caption directly.
3803
+ if ( this.captionContent !== '' ) {
3804
+
3805
+ // If the caption container has 0 opacity when the fade out transition starts, set it
3806
+ // to 1 because the transition wouldn't work if the initial and final values are the same,
3807
+ // and the callback functions wouldn't fire in this case.
3808
+ if ( parseFloat( this.$captionContainer.css( 'opacity' ), 10 ) === 0 ) {
3809
+ this.$captionContainer.css( this.vendorPrefix + 'transition', '' );
3810
+ this.$captionContainer.css( 'opacity', 1 );
3811
+ }
3812
+
3813
+ this._fadeCaptionTo( 0, function() {
3814
+ that.captionContent = newCaptionContent;
3815
+
3816
+ if ( newCaptionContent !== '' ) {
3817
+ that.$captionContainer.html( that.captionContent );
3818
+ that._fadeCaptionTo( 1 );
3819
+ } else {
3820
+ that.$captionContainer.empty();
3821
+ }
3822
+ });
3823
+ } else {
3824
+ this.captionContent = newCaptionContent;
3825
+ this.$captionContainer.html( this.captionContent );
3826
+ this.$captionContainer.css( 'opacity', 0 );
3827
+ this._fadeCaptionTo( 1 );
3828
+ }
3829
+ } else {
3830
+ this.captionContent = newCaptionContent;
3831
+ this.$captionContainer.html( this.captionContent );
3832
+ }
3833
+ },
3834
+
3835
+ // Fade the caption container to the specified opacity
3836
+ _fadeCaptionTo: function( opacity, callback ) {
3837
+ var that = this;
3838
+
3839
+ // Use CSS transitions if they are supported. If not, use JavaScript animation.
3840
+ if ( this.supportedAnimation === 'css-3d' || this.supportedAnimation === 'css-2d' ) {
3841
+
3842
+ // There needs to be a delay between the moment the opacity is set
3843
+ // and the moment the transitions starts.
3844
+ setTimeout(function(){
3845
+ var css = { 'opacity': opacity };
3846
+ css[ that.vendorPrefix + 'transition' ] = 'opacity ' + that.settings.captionFadeDuration / 1000 + 's';
3847
+ that.$captionContainer.css( css );
3848
+ }, 1 );
3849
+
3850
+ this.$captionContainer.on( this.transitionEvent, function( event ) {
3851
+ if ( event.target !== event.currentTarget ) {
3852
+ return;
3853
+ }
3854
+
3855
+ that.$captionContainer.off( that.transitionEvent );
3856
+ that.$captionContainer.css( that.vendorPrefix + 'transition', '' );
3857
+
3858
+ if ( typeof callback === 'function' ) {
3859
+ callback();
3860
+ }
3861
+ });
3862
+ } else {
3863
+ this.$captionContainer.stop().animate({ 'opacity': opacity }, this.settings.captionFadeDuration, function() {
3864
+ if ( typeof callback === 'function' ) {
3865
+ callback();
3866
+ }
3867
+ });
3868
+ }
3869
+ },
3870
+
3871
+ // Destroy the module
3872
+ destroyCaption: function() {
3873
+ this.off( 'update.' + NS );
3874
+ this.off( 'gotoSlide.' + NS );
3875
+
3876
+ this.$captionContainer.remove();
3877
+
3878
+ this.$slider.find( '.sp-caption' ).each(function() {
3879
+ $( this ).css( 'display', '' );
3880
+ });
3881
+ },
3882
+
3883
+ captionDefaults: {
3884
+
3885
+ // Indicates whether or not the captions will be faded
3886
+ fadeCaption: true,
3887
+
3888
+ // Sets the duration of the fade animation
3889
+ captionFadeDuration: 500
3890
+ }
3891
+ };
3892
+
3893
+ $.SliderPro.addModule( 'Caption', Caption );
3894
+
3895
+ })( window, jQuery );
3896
+
3897
+ // Deep Linking module for Slider Pro.
3898
+ //
3899
+ // Updates the hash of the URL as the user navigates through the slides.
3900
+ // Also, allows navigating to a specific slide by indicating it in the hash.
3901
+ ;(function( window, $ ) {
3902
+
3903
+ "use strict";
3904
+
3905
+ var NS = 'DeepLinking.' + $.SliderPro.namespace;
3906
+
3907
+ var DeepLinking = {
3908
+
3909
+ initDeepLinking: function() {
3910
+ var that = this;
3911
+
3912
+ // Parse the initial hash
3913
+ this.on( 'init.' + NS, function() {
3914
+ that._gotoHash( window.location.hash );
3915
+ });
3916
+
3917
+ // Update the hash when a new slide is selected
3918
+ this.on( 'gotoSlide.' + NS, function( event ) {
3919
+ if ( that.settings.updateHash === true ) {
3920
+
3921
+ // get the 'id' attribute of the slide
3922
+ var slideId = that.$slider.find( '.sp-slide' ).eq( event.index ).attr( 'id' );
3923
+
3924
+ // if the slide doesn't have an 'id' attribute, use the slide index
3925
+ if ( typeof slideId === 'undefined' ) {
3926
+ slideId = event.index;
3927
+ }
3928
+
3929
+ window.location.hash = that.$slider.attr( 'id' ) + '/' + slideId;
3930
+ }
3931
+ });
3932
+
3933
+ // Check when the hash changes and navigate to the indicated slide
3934
+ $( window ).on( 'hashchange.' + this.uniqueId + '.' + NS, function() {
3935
+ that._gotoHash( window.location.hash );
3936
+ });
3937
+ },
3938
+
3939
+ // Parse the hash and return the slider id and the slide id
3940
+ _parseHash: function( hash ) {
3941
+ if ( hash !== '' ) {
3942
+ // Eliminate the # symbol
3943
+ hash = hash.substring(1);
3944
+
3945
+ // Get the specified slider id and slide id
3946
+ var values = hash.split( '/' ),
3947
+ slideId = values.pop(),
3948
+ sliderId = hash.slice( 0, - slideId.toString().length - 1 );
3949
+
3950
+ if ( this.$slider.attr( 'id' ) === sliderId ) {
3951
+ return { 'sliderID': sliderId, 'slideId': slideId };
3952
+ }
3953
+ }
3954
+
3955
+ return false;
3956
+ },
3957
+
3958
+ // Navigate to the appropriate slide, based on the specified hash
3959
+ _gotoHash: function( hash ) {
3960
+ var result = this._parseHash( hash );
3961
+
3962
+ if ( result === false ) {
3963
+ return;
3964
+ }
3965
+
3966
+ var slideId = result.slideId,
3967
+ slideIdNumber = parseInt( slideId, 10 );
3968
+
3969
+ // check if the specified slide id is a number or string
3970
+ if ( isNaN( slideIdNumber ) ) {
3971
+ // get the index of the slide based on the specified id
3972
+ var slideIndex = this.$slider.find( '.sp-slide#' + slideId ).index();
3973
+
3974
+ if ( slideIndex !== -1 && slideIndex !== this.selectedSlideIndex ) {
3975
+ this.gotoSlide( slideIndex );
3976
+ }
3977
+ } else if ( slideIdNumber !== this.selectedSlideIndex ) {
3978
+ this.gotoSlide( slideIdNumber );
3979
+ }
3980
+ },
3981
+
3982
+ // Destroy the module
3983
+ destroyDeepLinking: function() {
3984
+ this.off( 'init.' + NS );
3985
+ this.off( 'gotoSlide.' + NS );
3986
+ $( window ).off( 'hashchange.' + this.uniqueId + '.' + NS );
3987
+ },
3988
+
3989
+ deepLinkingDefaults: {
3990
+
3991
+ // Indicates whether the hash will be updated when a new slide is selected
3992
+ updateHash: false
3993
+ }
3994
+ };
3995
+
3996
+ $.SliderPro.addModule( 'DeepLinking', DeepLinking );
3997
+
3998
+ })( window, jQuery );
3999
+
4000
+ // Autoplay module for Slider Pro.
4001
+ //
4002
+ // Adds automatic navigation through the slides by calling the
4003
+ // 'nextSlide' or 'previousSlide' methods at certain time intervals.
4004
+ ;(function( window, $ ) {
4005
+
4006
+ "use strict";
4007
+
4008
+ var NS = 'Autoplay.' + $.SliderPro.namespace;
4009
+
4010
+ var Autoplay = {
4011
+
4012
+ autoplayTimer: null,
4013
+
4014
+ isTimerRunning: false,
4015
+
4016
+ isTimerPaused: false,
4017
+
4018
+ initAutoplay: function() {
4019
+ this.on( 'update.' + NS, $.proxy( this._autoplayOnUpdate, this ) );
4020
+ },
4021
+
4022
+ // Start the autoplay if it's enabled, or stop it if it's disabled but running
4023
+ _autoplayOnUpdate: function( event ) {
4024
+ if ( this.settings.autoplay === true ) {
4025
+ this.on( 'gotoSlide.' + NS, $.proxy( this._autoplayOnGotoSlide, this ) );
4026
+ this.on( 'mouseenter.' + NS, $.proxy( this._autoplayOnMouseEnter, this ) );
4027
+ this.on( 'mouseleave.' + NS, $.proxy( this._autoplayOnMouseLeave, this ) );
4028
+
4029
+ this.startAutoplay();
4030
+ } else {
4031
+ this.off( 'gotoSlide.' + NS );
4032
+ this.off( 'mouseenter.' + NS );
4033
+ this.off( 'mouseleave.' + NS );
4034
+
4035
+ this.stopAutoplay();
4036
+ }
4037
+ },
4038
+
4039
+ // Restart the autoplay timer when a new slide is selected
4040
+ _autoplayOnGotoSlide: function( event ) {
4041
+ // stop previous timers before starting a new one
4042
+ if ( this.isTimerRunning === true ) {
4043
+ this.stopAutoplay();
4044
+ }
4045
+
4046
+ if ( this.isTimerPaused === false ) {
4047
+ this.startAutoplay();
4048
+ }
4049
+ },
4050
+
4051
+ // Pause the autoplay when the slider is hovered
4052
+ _autoplayOnMouseEnter: function( event ) {
4053
+ if ( this.isTimerRunning && ( this.settings.autoplayOnHover === 'pause' || this.settings.autoplayOnHover === 'stop' ) ) {
4054
+ this.stopAutoplay();
4055
+ this.isTimerPaused = true;
4056
+ }
4057
+ },
4058
+
4059
+ // Start the autoplay when the mouse moves away from the slider
4060
+ _autoplayOnMouseLeave: function( event ) {
4061
+ if ( this.settings.autoplay === true && this.isTimerRunning === false && this.settings.autoplayOnHover !== 'stop' ) {
4062
+ this.startAutoplay();
4063
+ this.isTimerPaused = false;
4064
+ }
4065
+ },
4066
+
4067
+ // Starts the autoplay
4068
+ startAutoplay: function() {
4069
+ var that = this;
4070
+
4071
+ this.isTimerRunning = true;
4072
+
4073
+ this.autoplayTimer = setTimeout(function() {
4074
+ if ( that.settings.autoplayDirection === 'normal' ) {
4075
+ that.nextSlide();
4076
+ } else if ( that.settings.autoplayDirection === 'backwards' ) {
4077
+ that.previousSlide();
4078
+ }
4079
+ }, this.settings.autoplayDelay );
4080
+ },
4081
+
4082
+ // Stops the autoplay
4083
+ stopAutoplay: function() {
4084
+ this.isTimerRunning = false;
4085
+ this.isTimerPaused = false;
4086
+
4087
+ clearTimeout( this.autoplayTimer );
4088
+ },
4089
+
4090
+ // Destroy the module
4091
+ destroyAutoplay: function() {
4092
+ clearTimeout( this.autoplayTimer );
4093
+
4094
+ this.off( 'update.' + NS );
4095
+ this.off( 'gotoSlide.' + NS );
4096
+ this.off( 'mouseenter.' + NS );
4097
+ this.off( 'mouseleave.' + NS );
4098
+ },
4099
+
4100
+ autoplayDefaults: {
4101
+ // Indicates whether or not autoplay will be enabled
4102
+ autoplay: true,
4103
+
4104
+ // Sets the delay/interval at which the autoplay will run
4105
+ autoplayDelay: 5000,
4106
+
4107
+ // Indicates whether autoplay will navigate to the next slide or previous slide
4108
+ autoplayDirection: 'normal',
4109
+
4110
+ // Indicates if the autoplay will be paused or stopped when the slider is hovered.
4111
+ // Possible values are 'pause', 'stop' or 'none'.
4112
+ autoplayOnHover: 'pause'
4113
+ }
4114
+ };
4115
+
4116
+ $.SliderPro.addModule( 'Autoplay', Autoplay );
4117
+
4118
+ })(window, jQuery);
4119
+
4120
+ // Keyboard module for Slider Pro.
4121
+ //
4122
+ // Adds the possibility to navigate through slides using the keyboard arrow keys, or
4123
+ // open the link attached to the main slide image by using the Enter key.
4124
+ ;(function( window, $ ) {
4125
+
4126
+ "use strict";
4127
+
4128
+ var NS = 'Keyboard.' + $.SliderPro.namespace;
4129
+
4130
+ var Keyboard = {
4131
+
4132
+ initKeyboard: function() {
4133
+ var that = this,
4134
+ hasFocus = false;
4135
+
4136
+ if ( this.settings.keyboard === false ) {
4137
+ return;
4138
+ }
4139
+
4140
+ // Detect when the slide is in focus and when it's not, and, optionally, make it
4141
+ // responsive to keyboard input only when it's in focus
4142
+ this.$slider.on( 'focus.' + NS, function() {
4143
+ hasFocus = true;
4144
+ });
4145
+
4146
+ this.$slider.on( 'blur.' + NS, function() {
4147
+ hasFocus = false;
4148
+ });
4149
+
4150
+ $( document ).on( 'keydown.' + this.uniqueId + '.' + NS, function( event ) {
4151
+ if ( that.settings.keyboardOnlyOnFocus === true && hasFocus === false ) {
4152
+ return;
4153
+ }
4154
+
4155
+ // If the left arrow key is pressed, go to the previous slide.
4156
+ // If the right arrow key is pressed, go to the next slide.
4157
+ // If the Enter key is pressed, open the link attached to the main slide image.
4158
+ if ( event.which === 37 ) {
4159
+ that.previousSlide();
4160
+ } else if ( event.which === 39 ) {
4161
+ that.nextSlide();
4162
+ } else if ( event.which === 13 ) {
4163
+ that.$slider.find( '.sp-slide' ).eq( that.selectedSlideIndex ).find( '.sp-image-container a' )[0].click();
4164
+ }
4165
+ });
4166
+ },
4167
+
4168
+ // Destroy the module
4169
+ destroyKeyboard: function() {
4170
+ this.$slider.off( 'focus.' + NS );
4171
+ this.$slider.off( 'blur.' + NS );
4172
+ $( document ).off( 'keydown.' + this.uniqueId + '.' + NS );
4173
+ },
4174
+
4175
+ keyboardDefaults: {
4176
+
4177
+ // Indicates whether keyboard navigation will be enabled
4178
+ keyboard: true,
4179
+
4180
+ // Indicates whether the slider will respond to keyboard input only when
4181
+ // the slider is in focus.
4182
+ keyboardOnlyOnFocus: false
4183
+ }
4184
+ };
4185
+
4186
+ $.SliderPro.addModule( 'Keyboard', Keyboard );
4187
+
4188
+ })( window, jQuery );
4189
+
4190
+ // Full Screen module for Slider Pro.
4191
+ //
4192
+ // Adds the possibility to open the slider full-screen, using the HMTL5 FullScreen API.
4193
+ ;(function( window, $ ) {
4194
+
4195
+ "use strict";
4196
+
4197
+ var NS = 'FullScreen.' + $.SliderPro.namespace;
4198
+
4199
+ var FullScreen = {
4200
+
4201
+ // Indicates whether the slider is currently in full-screen mode
4202
+ isFullScreen: false,
4203
+
4204
+ // Reference to the full-screen button
4205
+ $fullScreenButton: null,
4206
+
4207
+ // Reference to a set of settings that influence the slider's size
4208
+ // before it goes full-screen
4209
+ sizeBeforeFullScreen: {},
4210
+
4211
+ initFullScreen: function() {
4212
+ if ( ! ( document.fullscreenEnabled ||
4213
+ document.webkitFullscreenEnabled ||
4214
+ document.mozFullScreenEnabled ||
4215
+ document.msFullscreenEnabled ) ) {
4216
+ return;
4217
+ }
4218
+
4219
+ this.on( 'update.' + NS, $.proxy( this._fullScreenOnUpdate, this ) );
4220
+ },
4221
+
4222
+ // Create or remove the full-screen button depending on the value of the 'fullScreen' option
4223
+ _fullScreenOnUpdate: function() {
4224
+ if ( this.settings.fullScreen === true && this.$fullScreenButton === null ) {
4225
+ this._addFullScreen();
4226
+ } else if ( this.settings.fullScreen === false && this.$fullScreenButton !== null ) {
4227
+ this._removeFullScreen();
4228
+ }
4229
+
4230
+ if ( this.settings.fullScreen === true ) {
4231
+ if ( this.settings.fadeFullScreen === true ) {
4232
+ this.$fullScreenButton.addClass( 'sp-fade-full-screen' );
4233
+ } else if ( this.settings.fadeFullScreen === false ) {
4234
+ this.$fullScreenButton.removeClass( 'sp-fade-full-screen' );
4235
+ }
4236
+ }
4237
+ },
4238
+
4239
+ // Create the full-screen button
4240
+ _addFullScreen: function() {
4241
+ this.$fullScreenButton = $('<div class="sp-full-screen-button"></div>').appendTo( this.$slider );
4242
+ this.$fullScreenButton.on( 'click.' + NS, $.proxy( this._onFullScreenButtonClick, this ) );
4243
+
4244
+ document.addEventListener( 'fullscreenchange', $.proxy( this._onFullScreenChange, this ) );
4245
+ document.addEventListener( 'mozfullscreenchange', $.proxy( this._onFullScreenChange, this ) );
4246
+ document.addEventListener( 'webkitfullscreenchange', $.proxy( this._onFullScreenChange, this ) );
4247
+ document.addEventListener( 'MSFullscreenChange', $.proxy( this._onFullScreenChange, this ) );
4248
+ },
4249
+
4250
+ // Remove the full-screen button
4251
+ _removeFullScreen: function() {
4252
+ if ( this.$fullScreenButton !== null ) {
4253
+ this.$fullScreenButton.off( 'click.' + NS );
4254
+ this.$fullScreenButton.remove();
4255
+ this.$fullScreenButton = null;
4256
+ document.removeEventListener( 'fullscreenchange', this._onFullScreenChange );
4257
+ document.removeEventListener( 'mozfullscreenchange', this._onFullScreenChange );
4258
+ document.removeEventListener( 'webkitfullscreenchange', this._onFullScreenChange );
4259
+ document.removeEventListener( 'MSFullscreenChange', this._onFullScreenChange );
4260
+ }
4261
+ },
4262
+
4263
+ // When the full-screen button is clicked, put the slider into full-screen mode, and
4264
+ // take it out of the full-screen mode when it's clicked again.
4265
+ _onFullScreenButtonClick: function() {
4266
+ if ( this.isFullScreen === false ) {
4267
+ if ( this.instance.requestFullScreen ) {
4268
+ this.instance.requestFullScreen();
4269
+ } else if ( this.instance.mozRequestFullScreen ) {
4270
+ this.instance.mozRequestFullScreen();
4271
+ } else if ( this.instance.webkitRequestFullScreen ) {
4272
+ this.instance.webkitRequestFullScreen();
4273
+ } else if ( this.instance.msRequestFullscreen ) {
4274
+ this.instance.msRequestFullscreen();
4275
+ }
4276
+ } else {
4277
+ if ( document.exitFullScreen ) {
4278
+ document.exitFullScreen();
4279
+ } else if ( document.mozCancelFullScreen ) {
4280
+ document.mozCancelFullScreen();
4281
+ } else if ( document.webkitCancelFullScreen ) {
4282
+ document.webkitCancelFullScreen();
4283
+ } else if ( document.msExitFullscreen ) {
4284
+ document.msExitFullscreen();
4285
+ }
4286
+ }
4287
+ },
4288
+
4289
+ // This will be called whenever the full-screen mode changes.
4290
+ // If the slider is in full-screen mode, set it to 'full window', and if it's
4291
+ // not in full-screen mode anymore, set it back to the original size.
4292
+ _onFullScreenChange: function() {
4293
+ this.isFullScreen = document.fullscreenElement || document.webkitFullscreenElement || document.mozFullScreenElement || document.msFullscreenElement ? true : false;
4294
+
4295
+ if ( this.isFullScreen === true ) {
4296
+ this.sizeBeforeFullScreen = { forceSize: this.settings.forceSize, autoHeight: this.settings.autoHeight };
4297
+ this.$slider.addClass( 'sp-full-screen' );
4298
+ this.settings.forceSize = 'fullWindow';
4299
+ this.settings.autoHeight = false;
4300
+ } else {
4301
+ this.$slider.css( 'margin', '' );
4302
+ this.$slider.removeClass( 'sp-full-screen' );
4303
+ this.settings.forceSize = this.sizeBeforeFullScreen.forceSize;
4304
+ this.settings.autoHeight = this.sizeBeforeFullScreen.autoHeight;
4305
+ }
4306
+
4307
+ this.resize();
4308
+ },
4309
+
4310
+ // Destroy the module
4311
+ destroyFullScreen: function() {
4312
+ this.off( 'update.' + NS );
4313
+ this._removeFullScreen();
4314
+ },
4315
+
4316
+ fullScreenDefaults: {
4317
+
4318
+ // Indicates whether the full-screen button is enabled
4319
+ fullScreen: false,
4320
+
4321
+ // Indicates whether the button will fade in only on hover
4322
+ fadeFullScreen: true
4323
+ }
4324
+ };
4325
+
4326
+ $.SliderPro.addModule( 'FullScreen', FullScreen );
4327
+
4328
+ })( window, jQuery );
4329
+
4330
+ // Buttons module for Slider Pro.
4331
+ //
4332
+ // Adds navigation buttons at the bottom of the slider.
4333
+ ;(function( window, $ ) {
4334
+
4335
+ "use strict";
4336
+
4337
+ var NS = 'Buttons.' + $.SliderPro.namespace;
4338
+
4339
+ var Buttons = {
4340
+
4341
+ // Reference to the buttons container
4342
+ $buttons: null,
4343
+
4344
+ initButtons: function() {
4345
+ this.on( 'update.' + NS, $.proxy( this._buttonsOnUpdate, this ) );
4346
+ },
4347
+
4348
+ _buttonsOnUpdate: function() {
4349
+ this.$buttons = this.$slider.find('.sp-buttons');
4350
+
4351
+ // If there is more that one slide but the buttons weren't created yet, create the buttons.
4352
+ // If the buttons were created but their number differs from the total number of slides, re-create the buttons.
4353
+ // If the buttons were created but there are less than one slide, remove the buttons.s
4354
+ if ( this.settings.buttons === true && this.getTotalSlides() > 1 && this.$buttons.length === 0 ) {
4355
+ this._createButtons();
4356
+ } else if ( this.settings.buttons === true && this.getTotalSlides() !== this.$buttons.find( '.sp-button' ).length && this.$buttons.length !== 0 ) {
4357
+ this._adjustButtons();
4358
+ } else if ( this.settings.buttons === false || ( this.getTotalSlides() <= 1 && this.$buttons.length !== 0 ) ) {
4359
+ this._removeButtons();
4360
+ }
4361
+ },
4362
+
4363
+ // Create the buttons
4364
+ _createButtons: function() {
4365
+ var that = this;
4366
+
4367
+ // Create the buttons' container
4368
+ this.$buttons = $( '<div class="sp-buttons"></div>' ).appendTo( this.$slider );
4369
+
4370
+ // Create the buttons
4371
+ for ( var i = 0; i < this.getTotalSlides(); i++ ) {
4372
+ $( '<div class="sp-button"></div>' ).appendTo( this.$buttons );
4373
+ }
4374
+
4375
+ // Listen for button clicks
4376
+ this.$buttons.on( 'click.' + NS, '.sp-button', function() {
4377
+ that.gotoSlide( $( this ).index() );
4378
+ });
4379
+
4380
+ // Set the initially selected button
4381
+ this.$buttons.find( '.sp-button' ).eq( this.selectedSlideIndex ).addClass( 'sp-selected-button' );
4382
+
4383
+ // Select the corresponding button when the slide changes
4384
+ this.on( 'gotoSlide.' + NS, function( event ) {
4385
+ that.$buttons.find( '.sp-selected-button' ).removeClass( 'sp-selected-button' );
4386
+ that.$buttons.find( '.sp-button' ).eq( event.index ).addClass( 'sp-selected-button' );
4387
+ });
4388
+
4389
+ // Indicate that the slider has buttons
4390
+ this.$slider.addClass( 'sp-has-buttons' );
4391
+ },
4392
+
4393
+ // Re-create the buttons. This is calles when the number of slides changes.
4394
+ _adjustButtons: function() {
4395
+ this.$buttons.empty();
4396
+
4397
+ // Create the buttons
4398
+ for ( var i = 0; i < this.getTotalSlides(); i++ ) {
4399
+ $( '<div class="sp-button"></div>' ).appendTo( this.$buttons );
4400
+ }
4401
+
4402
+ // Change the selected the buttons
4403
+ this.$buttons.find( '.sp-selected-button' ).removeClass( 'sp-selected-button' );
4404
+ this.$buttons.find( '.sp-button' ).eq( this.selectedSlideIndex ).addClass( 'sp-selected-button' );
4405
+ },
4406
+
4407
+ // Remove the buttons
4408
+ _removeButtons: function() {
4409
+ this.$buttons.off( 'click.' + NS, '.sp-button' );
4410
+ this.off( 'gotoSlide.' + NS );
4411
+ this.$buttons.remove();
4412
+ this.$slider.removeClass( 'sp-has-buttons' );
4413
+ },
4414
+
4415
+ destroyButtons: function() {
4416
+ this._removeButtons();
4417
+ this.off( 'update.' + NS );
4418
+ },
4419
+
4420
+ buttonsDefaults: {
4421
+
4422
+ // Indicates whether the buttons will be created
4423
+ buttons: true
4424
+ }
4425
+ };
4426
+
4427
+ $.SliderPro.addModule( 'Buttons', Buttons );
4428
+
4429
+ })( window, jQuery );
4430
+
4431
+ // Arrows module for Slider Pro.
4432
+ //
4433
+ // Adds arrows for navigating to the next or previous slide.
4434
+ ;(function( window, $ ) {
4435
+
4436
+ "use strict";
4437
+
4438
+ var NS = 'Arrows.' + $.SliderPro.namespace;
4439
+
4440
+ var Arrows = {
4441
+
4442
+ // Reference to the arrows container
4443
+ $arrows: null,
4444
+
4445
+ // Reference to the previous arrow
4446
+ $previousArrow: null,
4447
+
4448
+ // Reference to the next arrow
4449
+ $nextArrow: null,
4450
+
4451
+ initArrows: function() {
4452
+ this.on( 'update.' + NS, $.proxy( this._arrowsOnUpdate, this ) );
4453
+ this.on( 'gotoSlide.' + NS, $.proxy( this._checkArrowsVisibility, this ) );
4454
+ },
4455
+
4456
+ _arrowsOnUpdate: function() {
4457
+ var that = this;
4458
+
4459
+ // Create the arrows if the 'arrows' option is set to true
4460
+ if ( this.settings.arrows === true && this.$arrows === null ) {
4461
+ this.$arrows = $( '<div class="sp-arrows"></div>' ).appendTo( this.$slidesContainer );
4462
+
4463
+ this.$previousArrow = $( '<div class="sp-arrow sp-previous-arrow"></div>' ).appendTo( this.$arrows );
4464
+ this.$nextArrow = $( '<div class="sp-arrow sp-next-arrow"></div>' ).appendTo( this.$arrows );
4465
+
4466
+ this.$previousArrow.on( 'click.' + NS, function() {
4467
+ that.previousSlide();
4468
+ });
4469
+
4470
+ this.$nextArrow.on( 'click.' + NS, function() {
4471
+ that.nextSlide();
4472
+ });
4473
+
4474
+ this._checkArrowsVisibility();
4475
+ } else if ( this.settings.arrows === false && this.$arrows !== null ) {
4476
+ this._removeArrows();
4477
+ }
4478
+
4479
+ if ( this.settings.arrows === true ) {
4480
+ if ( this.settings.fadeArrows === true ) {
4481
+ this.$arrows.addClass( 'sp-fade-arrows' );
4482
+ } else if ( this.settings.fadeArrows === false ) {
4483
+ this.$arrows.removeClass( 'sp-fade-arrows' );
4484
+ }
4485
+ }
4486
+ },
4487
+
4488
+ // Show or hide the arrows depending on the position of the selected slide
4489
+ _checkArrowsVisibility: function() {
4490
+ if ( this.settings.arrows === false || this.settings.loop === true ) {
4491
+ return;
4492
+ }
4493
+
4494
+ if ( this.selectedSlideIndex === 0 ) {
4495
+ this.$previousArrow.css( 'display', 'none' );
4496
+ } else {
4497
+ this.$previousArrow.css( 'display', 'block' );
4498
+ }
4499
+
4500
+ if ( this.selectedSlideIndex === this.getTotalSlides() - 1 ) {
4501
+ this.$nextArrow.css( 'display', 'none' );
4502
+ } else {
4503
+ this.$nextArrow.css( 'display', 'block' );
4504
+ }
4505
+ },
4506
+
4507
+ _removeArrows: function() {
4508
+ if ( this.$arrows !== null ) {
4509
+ this.$previousArrow.off( 'click.' + NS );
4510
+ this.$nextArrow.off( 'click.' + NS );
4511
+ this.$arrows.remove();
4512
+ this.$arrows = null;
4513
+ }
4514
+ },
4515
+
4516
+ destroyArrows: function() {
4517
+ this._removeArrows();
4518
+ this.off( 'update.' + NS );
4519
+ this.off( 'gotoSlide.' + NS );
4520
+ },
4521
+
4522
+ arrowsDefaults: {
4523
+
4524
+ // Indicates whether the arrow buttons will be created
4525
+ arrows: false,
4526
+
4527
+ // Indicates whether the arrows will fade in only on hover
4528
+ fadeArrows: true
4529
+ }
4530
+ };
4531
+
4532
+ $.SliderPro.addModule( 'Arrows', Arrows );
4533
+
4534
+ })( window, jQuery );
4535
+
4536
+ // Thumbnail Touch Swipe module for Slider Pro.
4537
+ //
4538
+ // Adds touch-swipe functionality for thumbnails.
4539
+ ;(function( window, $ ) {
4540
+
4541
+ "use strict";
4542
+
4543
+ var NS = 'ThumbnailTouchSwipe.' + $.SliderPro.namespace;
4544
+
4545
+ var ThumbnailTouchSwipe = {
4546
+
4547
+ // The x and y coordinates of the pointer/finger's starting position
4548
+ thumbnailTouchStartPoint: { x: 0, y: 0 },
4549
+
4550
+ // The x and y coordinates of the pointer/finger's end position
4551
+ thumbnailTouchEndPoint: { x: 0, y: 0 },
4552
+
4553
+ // The distance from the starting to the end position on the x and y axis
4554
+ thumbnailTouchDistance: { x: 0, y: 0 },
4555
+
4556
+ // The position of the thumbnail scroller when the touch swipe starts
4557
+ thumbnailTouchStartPosition: 0,
4558
+
4559
+ // Indicates if the thumbnail scroller is being swiped
4560
+ isThumbnailTouchMoving: false,
4561
+
4562
+ // Indicates if the touch swipe was initialized
4563
+ isThumbnailTouchSwipe: false,
4564
+
4565
+ // Stores the names of the events
4566
+ thumbnailTouchSwipeEvents: { startEvent: '', moveEvent: '', endEvent: '' },
4567
+
4568
+ initThumbnailTouchSwipe: function() {
4569
+ this.on( 'update.' + NS, $.proxy( this._thumbnailTouchSwipeOnUpdate, this ) );
4570
+ },
4571
+
4572
+ _thumbnailTouchSwipeOnUpdate: function() {
4573
+
4574
+ // Return if there are no thumbnails
4575
+ if ( this.isThumbnailScroller === false ) {
4576
+ return;
4577
+ }
4578
+
4579
+ // Initialize the touch swipe functionality if it wasn't initialized yet
4580
+ if ( this.settings.thumbnailTouchSwipe === true && this.isThumbnailTouchSwipe === false ) {
4581
+ this.isThumbnailTouchSwipe = true;
4582
+
4583
+ this.thumbnailTouchSwipeEvents.startEvent = 'touchstart' + '.' + NS + ' mousedown' + '.' + NS;
4584
+ this.thumbnailTouchSwipeEvents.moveEvent = 'touchmove' + '.' + NS + ' mousemove' + '.' + NS;
4585
+ this.thumbnailTouchSwipeEvents.endEvent = 'touchend' + '.' + this.uniqueId + '.' + NS + ' mouseup' + '.' + this.uniqueId + '.' + NS;
4586
+
4587
+ // Listen for touch swipe/mouse move events
4588
+ this.$thumbnails.on( this.thumbnailTouchSwipeEvents.startEvent, $.proxy( this._onThumbnailTouchStart, this ) );
4589
+ this.$thumbnails.on( 'dragstart.' + NS, function( event ) {
4590
+ event.preventDefault();
4591
+ });
4592
+
4593
+ // Add the grabbing icon
4594
+ this.$thumbnails.addClass( 'sp-grab' );
4595
+ }
4596
+
4597
+ // Remove the default thumbnailClick
4598
+ $.each( this.thumbnails, function( index, thumbnail ) {
4599
+ thumbnail.off( 'thumbnailClick' );
4600
+ });
4601
+ },
4602
+
4603
+ // Called when the thumbnail scroller starts being dragged
4604
+ _onThumbnailTouchStart: function( event ) {
4605
+ // Disable dragging if the element is set to allow selections
4606
+ if ( $( event.target ).closest( '.sp-selectable' ).length >= 1 ) {
4607
+ return;
4608
+ }
4609
+
4610
+ var that = this,
4611
+ eventObject = typeof event.originalEvent.touches !== 'undefined' ? event.originalEvent.touches[0] : event.originalEvent;
4612
+
4613
+ // Prevent default behavior for mouse events
4614
+ if ( typeof event.originalEvent.touches === 'undefined' ) {
4615
+ event.preventDefault();
4616
+ }
4617
+
4618
+ // Disable click events on links
4619
+ $( event.target ).parents( '.sp-thumbnail-container' ).find( 'a' ).one( 'click.' + NS, function( event ) {
4620
+ event.preventDefault();
4621
+ });
4622
+
4623
+ // Get the initial position of the mouse pointer and the initial position
4624
+ // of the thumbnail scroller
4625
+ this.thumbnailTouchStartPoint.x = eventObject.pageX || eventObject.clientX;
4626
+ this.thumbnailTouchStartPoint.y = eventObject.pageY || eventObject.clientY;
4627
+ this.thumbnailTouchStartPosition = this.thumbnailsPosition;
4628
+
4629
+ // Clear the previous distance values
4630
+ this.thumbnailTouchDistance.x = this.thumbnailTouchDistance.y = 0;
4631
+
4632
+ // If the thumbnail scroller is being grabbed while it's still animating, stop the
4633
+ // current movement
4634
+ if ( this.$thumbnails.hasClass( 'sp-animated' ) ) {
4635
+ this.isThumbnailTouchMoving = true;
4636
+ this._stopThumbnailsMovement();
4637
+ this.thumbnailTouchStartPosition = this.thumbnailsPosition;
4638
+ }
4639
+
4640
+ // Listen for move and end events
4641
+ this.$thumbnails.on( this.thumbnailTouchSwipeEvents.moveEvent, $.proxy( this._onThumbnailTouchMove, this ) );
4642
+ $( document ).on( this.thumbnailTouchSwipeEvents.endEvent, $.proxy( this._onThumbnailTouchEnd, this ) );
4643
+
4644
+ // Swap grabbing icons
4645
+ this.$thumbnails.removeClass( 'sp-grab' ).addClass( 'sp-grabbing' );
4646
+
4647
+ // Add 'sp-swiping' class to indicate that the thumbnail scroller is being swiped
4648
+ this.$thumbnailsContainer.addClass( 'sp-swiping' );
4649
+ },
4650
+
4651
+ // Called during the thumbnail scroller's dragging
4652
+ _onThumbnailTouchMove: function( event ) {
4653
+ var eventObject = typeof event.originalEvent.touches !== 'undefined' ? event.originalEvent.touches[0] : event.originalEvent;
4654
+
4655
+ // Indicate that the move event is being fired
4656
+ this.isThumbnailTouchMoving = true;
4657
+
4658
+ // Get the current position of the mouse pointer
4659
+ this.thumbnailTouchEndPoint.x = eventObject.pageX || eventObject.clientX;
4660
+ this.thumbnailTouchEndPoint.y = eventObject.pageY || eventObject.clientY;
4661
+
4662
+ // Calculate the distance of the movement on both axis
4663
+ this.thumbnailTouchDistance.x = this.thumbnailTouchEndPoint.x - this.thumbnailTouchStartPoint.x;
4664
+ this.thumbnailTouchDistance.y = this.thumbnailTouchEndPoint.y - this.thumbnailTouchStartPoint.y;
4665
+
4666
+ // Calculate the distance of the swipe that takes place in the same direction as the orientation of the thumbnails
4667
+ // and calculate the distance from the opposite direction.
4668
+ //
4669
+ // For a swipe to be valid there should more distance in the same direction as the orientation of the thumbnails.
4670
+ var distance = this.thumbnailsOrientation === 'horizontal' ? this.thumbnailTouchDistance.x : this.thumbnailTouchDistance.y,
4671
+ oppositeDistance = this.thumbnailsOrientation === 'horizontal' ? this.thumbnailTouchDistance.y : this.thumbnailTouchDistance.x;
4672
+
4673
+ // If the movement is in the same direction as the orientation of the thumbnails, the swipe is valid
4674
+ if ( Math.abs( distance ) > Math.abs( oppositeDistance ) ) {
4675
+ event.preventDefault();
4676
+ } else {
4677
+ return;
4678
+ }
4679
+
4680
+ // Make the thumbnail scroller move slower if it's dragged outside its bounds
4681
+ if ( this.thumbnailsPosition >= 0 ) {
4682
+ var infOffset = - this.thumbnailTouchStartPosition;
4683
+ distance = infOffset + ( distance - infOffset ) * 0.2;
4684
+ } else if ( this.thumbnailsPosition <= - this.thumbnailsSize + this.thumbnailsContainerSize ) {
4685
+ var supOffset = this.thumbnailsSize - this.thumbnailsContainerSize + this.thumbnailTouchStartPosition;
4686
+ distance = - supOffset + ( distance + supOffset ) * 0.2;
4687
+ }
4688
+
4689
+ this._moveThumbnailsTo( this.thumbnailTouchStartPosition + distance, true );
4690
+ },
4691
+
4692
+ // Called when the thumbnail scroller is released
4693
+ _onThumbnailTouchEnd: function( event ) {
4694
+ var that = this,
4695
+ thumbnailTouchDistance = this.thumbnailsOrientation === 'horizontal' ? this.thumbnailTouchDistance.x : this.thumbnailTouchDistance.y;
4696
+
4697
+ // Remove the move and end listeners
4698
+ this.$thumbnails.off( this.thumbnailTouchSwipeEvents.moveEvent );
4699
+ $( document ).off( this.thumbnailTouchSwipeEvents.endEvent );
4700
+
4701
+ // Swap grabbing icons
4702
+ this.$thumbnails.removeClass( 'sp-grabbing' ).addClass( 'sp-grab' );
4703
+
4704
+ // Check if there is intention for a tap/click
4705
+ if ( this.isThumbnailTouchMoving === false ||
4706
+ this.isThumbnailTouchMoving === true &&
4707
+ Math.abs( this.thumbnailTouchDistance.x ) < 10 &&
4708
+ Math.abs( this.thumbnailTouchDistance.y ) < 10
4709
+ ) {
4710
+ var targetThumbnail = $( event.target ).hasClass( 'sp-thumbnail-container' ) ? $( event.target ) : $( event.target ).parents( '.sp-thumbnail-container' ),
4711
+ index = targetThumbnail.index();
4712
+
4713
+ // If a link is cliked, navigate to that link, else navigate to the slide that corresponds to the thumbnail
4714
+ if ( $( event.target ).parents( 'a' ).length !== 0 ) {
4715
+ $( event.target ).parents( 'a' ).off( 'click.' + NS );
4716
+ this.$thumbnailsContainer.removeClass( 'sp-swiping' );
4717
+ } else if ( index !== this.selectedThumbnailIndex && index !== -1 ) {
4718
+ this.gotoSlide( index );
4719
+ }
4720
+
4721
+ return;
4722
+ }
4723
+
4724
+ this.isThumbnailTouchMoving = false;
4725
+
4726
+ $( event.target ).parents( '.sp-thumbnail' ).one( 'click', function( event ) {
4727
+ event.preventDefault();
4728
+ });
4729
+
4730
+ // Remove the 'sp-swiping' class but with a delay
4731
+ // because there might be other event listeners that check
4732
+ // the existence of this class, and this class should still be
4733
+ // applied for those listeners, since there was a swipe event
4734
+ setTimeout(function() {
4735
+ that.$thumbnailsContainer.removeClass( 'sp-swiping' );
4736
+ }, 1 );
4737
+
4738
+ // Keep the thumbnail scroller inside the bounds
4739
+ if ( this.thumbnailsPosition > 0 ) {
4740
+ this._moveThumbnailsTo( 0 );
4741
+ } else if ( this.thumbnailsPosition < this.thumbnailsContainerSize - this.thumbnailsSize ) {
4742
+ this._moveThumbnailsTo( this.thumbnailsContainerSize - this.thumbnailsSize );
4743
+ }
4744
+
4745
+ // Fire the 'thumbnailsMoveComplete' event
4746
+ this.trigger({ type: 'thumbnailsMoveComplete' });
4747
+ if ( $.isFunction( this.settings.thumbnailsMoveComplete ) ) {
4748
+ this.settings.thumbnailsMoveComplete.call( this, { type: 'thumbnailsMoveComplete' });
4749
+ }
4750
+ },
4751
+
4752
+ // Destroy the module
4753
+ destroyThumbnailTouchSwipe: function() {
4754
+ this.off( 'update.' + NS );
4755
+
4756
+ if ( this.isThumbnailScroller === false ) {
4757
+ return;
4758
+ }
4759
+
4760
+ this.$thumbnails.off( this.thumbnailTouchSwipeEvents.startEvent );
4761
+ this.$thumbnails.off( this.thumbnailTouchSwipeEvents.moveEvent );
4762
+ this.$thumbnails.off( 'dragstart.' + NS );
4763
+ $( document ).off( this.thumbnailTouchSwipeEvents.endEvent );
4764
+ this.$thumbnails.removeClass( 'sp-grab' );
4765
+ },
4766
+
4767
+ thumbnailTouchSwipeDefaults: {
4768
+
4769
+ // Indicates whether the touch swipe will be enabled for thumbnails
4770
+ thumbnailTouchSwipe: true
4771
+ }
4772
+ };
4773
+
4774
+ $.SliderPro.addModule( 'ThumbnailTouchSwipe', ThumbnailTouchSwipe );
4775
+
4776
+ })( window, jQuery );
4777
+
4778
+ // Thumbnail Arrows module for Slider Pro.
4779
+ //
4780
+ // Adds thumbnail arrows for moving the thumbnail scroller.
4781
+ ;(function( window, $ ) {
4782
+
4783
+ "use strict";
4784
+
4785
+ var NS = 'ThumbnailArrows.' + $.SliderPro.namespace;
4786
+
4787
+ var ThumbnailArrows = {
4788
+
4789
+ // Reference to the arrows container
4790
+ $thumbnailArrows: null,
4791
+
4792
+ // Reference to the 'previous' thumbnail arrow
4793
+ $previousThumbnailArrow: null,
4794
+
4795
+ // Reference to the 'next' thumbnail arrow
4796
+ $nextThumbnailArrow: null,
4797
+
4798
+ initThumbnailArrows: function() {
4799
+ var that = this;
4800
+
4801
+ this.on( 'update.' + NS, $.proxy( this._thumbnailArrowsOnUpdate, this ) );
4802
+
4803
+ // Check if the arrows need to be visible or invisible when the thumbnail scroller
4804
+ // resizes and when the thumbnail scroller moves.
4805
+ this.on( 'sliderResize.' + NS + ' ' + 'thumbnailsMoveComplete.' + NS, function() {
4806
+ if ( that.isThumbnailScroller === true && that.settings.thumbnailArrows === true ) {
4807
+ that._checkThumbnailArrowsVisibility();
4808
+ }
4809
+ });
4810
+ },
4811
+
4812
+ // Called when the slider is updated
4813
+ _thumbnailArrowsOnUpdate: function() {
4814
+ var that = this;
4815
+
4816
+ if ( this.isThumbnailScroller === false ) {
4817
+ return;
4818
+ }
4819
+
4820
+ // Create or remove the thumbnail scroller arrows
4821
+ if ( this.settings.thumbnailArrows === true && this.$thumbnailArrows === null ) {
4822
+ this.$thumbnailArrows = $( '<div class="sp-thumbnail-arrows"></div>' ).appendTo( this.$thumbnailsContainer );
4823
+
4824
+ this.$previousThumbnailArrow = $( '<div class="sp-thumbnail-arrow sp-previous-thumbnail-arrow"></div>' ).appendTo( this.$thumbnailArrows );
4825
+ this.$nextThumbnailArrow = $( '<div class="sp-thumbnail-arrow sp-next-thumbnail-arrow"></div>' ).appendTo( this.$thumbnailArrows );
4826
+
4827
+ this.$previousThumbnailArrow.on( 'click.' + NS, function() {
4828
+ var previousPosition = Math.min( 0, that.thumbnailsPosition + that.thumbnailsContainerSize );
4829
+ that._moveThumbnailsTo( previousPosition );
4830
+ });
4831
+
4832
+ this.$nextThumbnailArrow.on( 'click.' + NS, function() {
4833
+ var nextPosition = Math.max( that.thumbnailsContainerSize - that.thumbnailsSize, that.thumbnailsPosition - that.thumbnailsContainerSize );
4834
+ that._moveThumbnailsTo( nextPosition );
4835
+ });
4836
+ } else if ( this.settings.thumbnailArrows === false && this.$thumbnailArrows !== null ) {
4837
+ this._removeThumbnailArrows();
4838
+ }
4839
+
4840
+ // Add fading functionality and check if the arrows need to be visible or not
4841
+ if ( this.settings.thumbnailArrows === true ) {
4842
+ if ( this.settings.fadeThumbnailArrows === true ) {
4843
+ this.$thumbnailArrows.addClass( 'sp-fade-thumbnail-arrows' );
4844
+ } else if ( this.settings.fadeThumbnailArrows === false ) {
4845
+ this.$thumbnailArrows.removeClass( 'sp-fade-thumbnail-arrows' );
4846
+ }
4847
+
4848
+ this._checkThumbnailArrowsVisibility();
4849
+ }
4850
+ },
4851
+
4852
+ // Checks if the 'next' or 'previous' arrows need to be visible or hidden,
4853
+ // based on the position of the thumbnail scroller
4854
+ _checkThumbnailArrowsVisibility: function() {
4855
+ if ( this.thumbnailsPosition === 0 ) {
4856
+ this.$previousThumbnailArrow.css( 'display', 'none' );
4857
+ } else {
4858
+ this.$previousThumbnailArrow.css( 'display', 'block' );
4859
+ }
4860
+
4861
+ if ( this.thumbnailsPosition === this.thumbnailsContainerSize - this.thumbnailsSize ) {
4862
+ this.$nextThumbnailArrow.css( 'display', 'none' );
4863
+ } else {
4864
+ this.$nextThumbnailArrow.css( 'display', 'block' );
4865
+ }
4866
+ },
4867
+
4868
+ // Remove the thumbnail arrows
4869
+ _removeThumbnailArrows: function() {
4870
+ if ( this.$thumbnailArrows !== null ) {
4871
+ this.$previousThumbnailArrow.off( 'click.' + NS );
4872
+ this.$nextThumbnailArrow.off( 'click.' + NS );
4873
+ this.$thumbnailArrows.remove();
4874
+ this.$thumbnailArrows = null;
4875
+ }
4876
+ },
4877
+
4878
+ // Destroy the module
4879
+ destroyThumbnailArrows: function() {
4880
+ this._removeThumbnailArrows();
4881
+ this.off( 'update.' + NS );
4882
+ this.off( 'sliderResize.' + NS );
4883
+ this.off( 'thumbnailsMoveComplete.' + NS );
4884
+ },
4885
+
4886
+ thumbnailArrowsDefaults: {
4887
+
4888
+ // Indicates whether the thumbnail arrows will be enabled
4889
+ thumbnailArrows: false,
4890
+
4891
+ // Indicates whether the thumbnail arrows will be faded
4892
+ fadeThumbnailArrows: true
4893
+ }
4894
+ };
4895
+
4896
+ $.SliderPro.addModule( 'ThumbnailArrows', ThumbnailArrows );
4897
+
4898
+ })( window, jQuery );
4899
+
4900
+ // Video module for Slider Pro
4901
+ //
4902
+ // Adds automatic control for several video players and providers
4903
+ ;(function( window, $ ) {
4904
+
4905
+ "use strict";
4906
+
4907
+ var NS = 'Video.' + $.SliderPro.namespace;
4908
+
4909
+ var Video = {
4910
+
4911
+ initVideo: function() {
4912
+ this.on( 'update.' + NS, $.proxy( this._videoOnUpdate, this ) );
4913
+ this.on( 'gotoSlideComplete.' + NS, $.proxy( this._videoOnGotoSlideComplete, this ) );
4914
+ },
4915
+
4916
+ _videoOnUpdate: function() {
4917
+ var that = this;
4918
+
4919
+ // Find all the inline videos and initialize them
4920
+ this.$slider.find( '.sp-video' ).not( 'a, [data-video-init]' ).each(function() {
4921
+ var video = $( this );
4922
+ that._initVideo( video );
4923
+ });
4924
+
4925
+ // Find all the lazy-loaded videos and preinitialize them. They will be initialized
4926
+ // only when their play button is clicked.
4927
+ this.$slider.find( 'a.sp-video' ).not( '[data-video-preinit]' ).each(function() {
4928
+ var video = $( this );
4929
+ that._preinitVideo( video );
4930
+ });
4931
+ },
4932
+
4933
+ // Initialize the target video
4934
+ _initVideo: function( video ) {
4935
+ var that = this;
4936
+
4937
+ video.attr( 'data-video-init', true )
4938
+ .videoController();
4939
+
4940
+ // When the video starts playing, pause the autoplay if it's running
4941
+ video.on( 'videoPlay.' + NS, function() {
4942
+ if ( that.settings.playVideoAction === 'stopAutoplay' && typeof that.stopAutoplay !== 'undefined' ) {
4943
+ that.stopAutoplay();
4944
+ that.settings.autoplay = false;
4945
+ }
4946
+
4947
+ // Fire the 'videoPlay' event
4948
+ var eventObject = { type: 'videoPlay', video: video };
4949
+ that.trigger( eventObject );
4950
+ if ( $.isFunction( that.settings.videoPlay ) ) {
4951
+ that.settings.videoPlay.call( that, eventObject );
4952
+ }
4953
+ });
4954
+
4955
+ // When the video is paused, restart the autoplay
4956
+ video.on( 'videoPause.' + NS, function() {
4957
+ if ( that.settings.pauseVideoAction === 'startAutoplay' && typeof that.startAutoplay !== 'undefined' ) {
4958
+ that.startAutoplay();
4959
+ that.settings.autoplay = true;
4960
+ }
4961
+
4962
+ // Fire the 'videoPause' event
4963
+ var eventObject = { type: 'videoPause', video: video };
4964
+ that.trigger( eventObject );
4965
+ if ( $.isFunction( that.settings.videoPause ) ) {
4966
+ that.settings.videoPause.call( that, eventObject );
4967
+ }
4968
+ });
4969
+
4970
+ // When the video ends, restart the autoplay (which was paused during the playback), or
4971
+ // go to the next slide, or replay the video
4972
+ video.on( 'videoEnded.' + NS, function() {
4973
+ if ( that.settings.endVideoAction === 'startAutoplay' && typeof that.startAutoplay !== 'undefined' ) {
4974
+ that.startAutoplay();
4975
+ that.settings.autoplay = true;
4976
+ } else if ( that.settings.endVideoAction === 'nextSlide' ) {
4977
+ that.nextSlide();
4978
+ } else if ( that.settings.endVideoAction === 'replayVideo' ) {
4979
+ video.videoController( 'replay' );
4980
+ }
4981
+
4982
+ // Fire the 'videoEnd' event
4983
+ var eventObject = { type: 'videoEnd', video: video };
4984
+ that.trigger( eventObject );
4985
+ if ( $.isFunction(that.settings.videoEnd ) ) {
4986
+ that.settings.videoEnd.call( that, eventObject );
4987
+ }
4988
+ });
4989
+ },
4990
+
4991
+ // Pre-initialize the video. This is for lazy loaded videos.
4992
+ _preinitVideo: function( video ) {
4993
+ var that = this;
4994
+
4995
+ video.attr( 'data-video-preinit', true );
4996
+
4997
+ // When the video poster is clicked, remove the poster and create
4998
+ // the inline video
4999
+ video.on( 'click.' + NS, function( event ) {
5000
+
5001
+ // If the video is being dragged, don't start the video
5002
+ if ( that.$slider.hasClass( 'sp-swiping' ) ) {
5003
+ return;
5004
+ }
5005
+
5006
+ event.preventDefault();
5007
+
5008
+ var href = video.attr( 'href' ),
5009
+ iframe,
5010
+ provider,
5011
+ regExp,
5012
+ match,
5013
+ id,
5014
+ src,
5015
+ videoAttributes,
5016
+ videoWidth = video.children( 'img' ).attr( 'width' ),
5017
+ videoHeight = video.children( 'img' ).attr( 'height');
5018
+
5019
+ // Check if it's a youtube or vimeo video
5020
+ if ( href.indexOf( 'youtube' ) !== -1 || href.indexOf( 'youtu.be' ) !== -1 ) {
5021
+ provider = 'youtube';
5022
+ } else if ( href.indexOf( 'vimeo' ) !== -1 ) {
5023
+ provider = 'vimeo';
5024
+ }
5025
+
5026
+ // Get the id of the video
5027
+ regExp = provider === 'youtube' ? /^.*(youtu.be\/|v\/|u\/\w\/|embed\/|watch\?v=|\&v=)([^#\&\?]*).*/ : /http:\/\/(www\.)?vimeo.com\/(\d+)/;
5028
+ match = href.match( regExp );
5029
+ id = match[2];
5030
+
5031
+ // Get the source of the iframe that will be created
5032
+ src = provider === 'youtube' ? 'http://www.youtube.com/embed/' + id + '?enablejsapi=1&wmode=opaque' : 'http://player.vimeo.com/video/'+ id +'?api=1';
5033
+
5034
+ // Get the attributes passed to the video link and then pass them to the iframe's src
5035
+ videoAttributes = href.split( '?' )[ 1 ];
5036
+
5037
+ if ( typeof videoAttributes !== 'undefined' ) {
5038
+ videoAttributes = videoAttributes.split( '&' );
5039
+
5040
+ $.each( videoAttributes, function( index, value ) {
5041
+ if ( value.indexOf( id ) === -1 ) {
5042
+ src += '&' + value;
5043
+ }
5044
+ });
5045
+ }
5046
+
5047
+ // Create the iframe
5048
+ iframe = $( '<iframe></iframe>' )
5049
+ .attr({
5050
+ 'src': src,
5051
+ 'width': videoWidth,
5052
+ 'height': videoHeight,
5053
+ 'class': video.attr( 'class' ),
5054
+ 'frameborder': 0,
5055
+ 'allowfullscreen': 'allowfullscreen'
5056
+ }).insertBefore( video );
5057
+
5058
+ // Initialize the video and play it
5059
+ that._initVideo( iframe );
5060
+ iframe.videoController( 'play' );
5061
+
5062
+ // Hide the video poster
5063
+ video.css( 'display', 'none' );
5064
+ });
5065
+ },
5066
+
5067
+ // Called when a new slide is selected
5068
+ _videoOnGotoSlideComplete: function( event ) {
5069
+
5070
+ // Get the video from the previous slide
5071
+ var previousVideo = this.$slides.find( '.sp-slide' ).eq( event.previousIndex ).find( '.sp-video[data-video-init]' );
5072
+
5073
+ // Handle the video from the previous slide by stopping it, or pausing it,
5074
+ // or remove it, depending on the value of the 'leaveVideoAction' option.
5075
+ if ( event.previousIndex !== -1 && previousVideo.length !== 0 ) {
5076
+ if ( this.settings.leaveVideoAction === 'stopVideo' ) {
5077
+ previousVideo.videoController( 'stop' );
5078
+ } else if ( this.settings.leaveVideoAction === 'pauseVideo' ) {
5079
+ previousVideo.videoController( 'pause' );
5080
+ } else if ( this.settings.leaveVideoAction === 'removeVideo' ) {
5081
+ // If the video was lazy-loaded, remove it and show the poster again. If the video
5082
+ // was not lazy-loaded, but inline, stop the video.
5083
+ if ( previousVideo.siblings( 'a.sp-video' ).length !== 0 ) {
5084
+ previousVideo.siblings( 'a.sp-video' ).css( 'display', '' );
5085
+ previousVideo.videoController( 'destroy' );
5086
+ previousVideo.remove();
5087
+ } else {
5088
+ previousVideo.videoController( 'stop' );
5089
+ }
5090
+ }
5091
+ }
5092
+
5093
+ // Handle the video from the selected slide
5094
+ if ( this.settings.reachVideoAction === 'playVideo' ) {
5095
+ var loadedVideo = this.$slides.find( '.sp-slide' ).eq( event.index ).find( '.sp-video[data-video-init]' ),
5096
+ unloadedVideo = this.$slides.find( '.sp-slide' ).eq( event.index ).find( '.sp-video[data-video-preinit]' );
5097
+
5098
+ // If the video was already initialized, play it. If it's not initialized (because
5099
+ // it's lazy loaded) initialize it and play it.
5100
+ if ( loadedVideo.length !== 0 ) {
5101
+ loadedVideo.videoController( 'play' );
5102
+ } else if ( unloadedVideo.length !== 0 ) {
5103
+ unloadedVideo.trigger( 'click.' + NS );
5104
+ }
5105
+ }
5106
+ },
5107
+
5108
+ // Destroy the module
5109
+ destroyVideo: function() {
5110
+ this.$slider.find( '.sp-video[ data-video-preinit ]' ).each(function() {
5111
+ var video = $( this );
5112
+ video.removeAttr( 'data-video-preinit' );
5113
+ video.off( 'click.' + NS );
5114
+ });
5115
+
5116
+ // Loop through the all the videos and destroy them
5117
+ this.$slider.find( '.sp-video[ data-video-init ]' ).each(function() {
5118
+ var video = $( this );
5119
+ video.removeAttr( 'data-video-init' );
5120
+ video.off( 'Video' );
5121
+ video.videoController( 'destroy' );
5122
+ });
5123
+
5124
+ this.off( 'update.' + NS );
5125
+ this.off( 'gotoSlideComplete.' + NS );
5126
+ },
5127
+
5128
+ videoDefaults: {
5129
+
5130
+ // Sets the action that the video will perform when its slide container is selected
5131
+ // ( 'playVideo' and 'none' )
5132
+ reachVideoAction: 'none',
5133
+
5134
+ // Sets the action that the video will perform when another slide is selected
5135
+ // ( 'stopVideo', 'pauseVideo', 'removeVideo' and 'none' )
5136
+ leaveVideoAction: 'pauseVideo',
5137
+
5138
+ // Sets the action that the slider will perform when the video starts playing
5139
+ // ( 'stopAutoplay' and 'none' )
5140
+ playVideoAction: 'stopAutoplay',
5141
+
5142
+ // Sets the action that the slider will perform when the video is paused
5143
+ // ( 'startAutoplay' and 'none' )
5144
+ pauseVideoAction: 'none',
5145
+
5146
+ // Sets the action that the slider will perform when the video ends
5147
+ // ( 'startAutoplay', 'nextSlide', 'replayVideo' and 'none' )
5148
+ endVideoAction: 'none',
5149
+
5150
+ // Called when the video starts playing
5151
+ videoPlay: function() {},
5152
+
5153
+ // Called when the video is paused
5154
+ videoPause: function() {},
5155
+
5156
+ // Called when the video ends
5157
+ videoEnd: function() {}
5158
+ }
5159
+ };
5160
+
5161
+ $.SliderPro.addModule( 'Video', Video );
5162
+
5163
+ })( window, jQuery );
5164
+
5165
+ // Video Controller jQuery plugin
5166
+ // Creates a universal controller for multiple video types and providers
5167
+ ;(function( $ ) {
5168
+
5169
+ "use strict";
5170
+
5171
+ // Check if an iOS device is used.
5172
+ // This information is important because a video can not be
5173
+ // controlled programmatically unless the user has started the video manually.
5174
+ var isIOS = window.navigator.userAgent.match( /(iPad|iPhone|iPod)/g ) ? true : false;
5175
+
5176
+ var VideoController = function( instance, options ) {
5177
+ this.$video = $( instance );
5178
+ this.options = options;
5179
+ this.settings = {};
5180
+ this.player = null;
5181
+
5182
+ this._init();
5183
+ };
5184
+
5185
+ VideoController.prototype = {
5186
+
5187
+ _init: function() {
5188
+ this.settings = $.extend( {}, this.defaults, this.options );
5189
+
5190
+ var that = this,
5191
+ players = $.VideoController.players,
5192
+ videoID = this.$video.attr( 'id' );
5193
+
5194
+ // Loop through the available video players
5195
+ // and check if the targeted video element is supported by one of the players.
5196
+ // If a compatible type is found, store the video type.
5197
+ for ( var name in players ) {
5198
+ if ( typeof players[ name ] !== 'undefined' && players[ name ].isType( this.$video ) ) {
5199
+ this.player = new players[ name ]( this.$video );
5200
+ break;
5201
+ }
5202
+ }
5203
+
5204
+ // Return if the player could not be instantiated
5205
+ if ( this.player === null ) {
5206
+ return;
5207
+ }
5208
+
5209
+ // Add event listeners
5210
+ var events = [ 'ready', 'start', 'play', 'pause', 'ended' ];
5211
+
5212
+ $.each( events, function( index, element ) {
5213
+ var event = 'video' + element.charAt( 0 ).toUpperCase() + element.slice( 1 );
5214
+
5215
+ that.player.on( element, function() {
5216
+ that.trigger({ type: event, video: videoID });
5217
+ if ( $.isFunction( that.settings[ event ] ) ) {
5218
+ that.settings[ event ].call( that, { type: event, video: videoID } );
5219
+ }
5220
+ });
5221
+ });
5222
+ },
5223
+
5224
+ play: function() {
5225
+ if ( isIOS === true && this.player.isStarted() === false || this.player.getState() === 'playing' ) {
5226
+ return;
5227
+ }
5228
+
5229
+ this.player.play();
5230
+ },
5231
+
5232
+ stop: function() {
5233
+ if ( isIOS === true && this.player.isStarted() === false || this.player.getState() === 'stopped' ) {
5234
+ return;
5235
+ }
5236
+
5237
+ this.player.stop();
5238
+ },
5239
+
5240
+ pause: function() {
5241
+ if ( isIOS === true && this.player.isStarted() === false || this.player.getState() === 'paused' ) {
5242
+ return;
5243
+ }
5244
+
5245
+ this.player.pause();
5246
+ },
5247
+
5248
+ replay: function() {
5249
+ if ( isIOS === true && this.player.isStarted() === false ) {
5250
+ return;
5251
+ }
5252
+
5253
+ this.player.replay();
5254
+ },
5255
+
5256
+ on: function( type, callback ) {
5257
+ return this.$video.on( type, callback );
5258
+ },
5259
+
5260
+ off: function( type ) {
5261
+ return this.$video.off( type );
5262
+ },
5263
+
5264
+ trigger: function( data ) {
5265
+ return this.$video.triggerHandler( data );
5266
+ },
5267
+
5268
+ destroy: function() {
5269
+ if ( this.player.isStarted() === true ) {
5270
+ this.stop();
5271
+ }
5272
+
5273
+ this.player.off( 'ready' );
5274
+ this.player.off( 'start' );
5275
+ this.player.off( 'play' );
5276
+ this.player.off( 'pause' );
5277
+ this.player.off( 'ended' );
5278
+
5279
+ this.$video.removeData( 'videoController' );
5280
+ },
5281
+
5282
+ defaults: {
5283
+ videoReady: function() {},
5284
+ videoStart: function() {},
5285
+ videoPlay: function() {},
5286
+ videoPause: function() {},
5287
+ videoEnded: function() {}
5288
+ }
5289
+ };
5290
+
5291
+ $.VideoController = {
5292
+ players: {},
5293
+
5294
+ addPlayer: function( name, player ) {
5295
+ this.players[ name ] = player;
5296
+ }
5297
+ };
5298
+
5299
+ $.fn.videoController = function( options ) {
5300
+ var args = Array.prototype.slice.call( arguments, 1 );
5301
+
5302
+ return this.each(function() {
5303
+ // Instantiate the video controller or call a function on the current instance
5304
+ if ( typeof $( this ).data( 'videoController' ) === 'undefined' ) {
5305
+ var newInstance = new VideoController( this, options );
5306
+
5307
+ // Store a reference to the instance created
5308
+ $( this ).data( 'videoController', newInstance );
5309
+ } else if ( typeof options !== 'undefined' ) {
5310
+ var currentInstance = $( this ).data( 'videoController' );
5311
+
5312
+ // Check the type of argument passed
5313
+ if ( typeof currentInstance[ options ] === 'function' ) {
5314
+ currentInstance[ options ].apply( currentInstance, args );
5315
+ } else {
5316
+ $.error( options + ' does not exist in videoController.' );
5317
+ }
5318
+ }
5319
+ });
5320
+ };
5321
+
5322
+ // Base object for the video players
5323
+ var Video = function( video ) {
5324
+ this.$video = video;
5325
+ this.player = null;
5326
+ this.ready = false;
5327
+ this.started = false;
5328
+ this.state = '';
5329
+ this.events = $({});
5330
+
5331
+ this._init();
5332
+ };
5333
+
5334
+ Video.prototype = {
5335
+ _init: function() {},
5336
+
5337
+ play: function() {},
5338
+
5339
+ pause: function() {},
5340
+
5341
+ stop: function() {},
5342
+
5343
+ replay: function() {},
5344
+
5345
+ isType: function() {},
5346
+
5347
+ isReady: function() {
5348
+ return this.ready;
5349
+ },
5350
+
5351
+ isStarted: function() {
5352
+ return this.started;
5353
+ },
5354
+
5355
+ getState: function() {
5356
+ return this.state;
5357
+ },
5358
+
5359
+ on: function( type, callback ) {
5360
+ return this.events.on( type, callback );
5361
+ },
5362
+
5363
+ off: function( type ) {
5364
+ return this.events.off( type );
5365
+ },
5366
+
5367
+ trigger: function( data ) {
5368
+ return this.events.triggerHandler( data );
5369
+ }
5370
+ };
5371
+
5372
+ // YouTube video
5373
+ var YoutubeVideoHelper = {
5374
+ youtubeAPIAdded: false,
5375
+ youtubeVideos: []
5376
+ };
5377
+
5378
+ var YoutubeVideo = function( video ) {
5379
+ this.init = false;
5380
+ var youtubeAPILoaded = window.YT && window.YT.Player;
5381
+
5382
+ if ( typeof youtubeAPILoaded !== 'undefined' ) {
5383
+ Video.call( this, video );
5384
+ } else {
5385
+ YoutubeVideoHelper.youtubeVideos.push({ 'video': video, 'scope': this });
5386
+
5387
+ if ( YoutubeVideoHelper.youtubeAPIAdded === false ) {
5388
+ YoutubeVideoHelper.youtubeAPIAdded = true;
5389
+
5390
+ var tag = document.createElement( 'script' );
5391
+ tag.src = "http://www.youtube.com/player_api";
5392
+ var firstScriptTag = document.getElementsByTagName( 'script' )[0];
5393
+ firstScriptTag.parentNode.insertBefore( tag, firstScriptTag );
5394
+
5395
+ window.onYouTubePlayerAPIReady = function() {
5396
+ $.each( YoutubeVideoHelper.youtubeVideos, function( index, element ) {
5397
+ Video.call( element.scope, element.video );
5398
+ });
5399
+ };
5400
+ }
5401
+ }
5402
+ };
5403
+
5404
+ YoutubeVideo.prototype = new Video();
5405
+ YoutubeVideo.prototype.constructor = YoutubeVideo;
5406
+ $.VideoController.addPlayer( 'YoutubeVideo', YoutubeVideo );
5407
+
5408
+ YoutubeVideo.isType = function( video ) {
5409
+ if ( video.is( 'iframe' ) ) {
5410
+ var src = video.attr( 'src' );
5411
+
5412
+ if ( src.indexOf( 'youtube.com' ) !== -1 || src.indexOf( 'youtu.be' ) !== -1 ) {
5413
+ return true;
5414
+ }
5415
+ }
5416
+
5417
+ return false;
5418
+ };
5419
+
5420
+ YoutubeVideo.prototype._init = function() {
5421
+ this.init = true;
5422
+ this._setup();
5423
+ };
5424
+
5425
+ YoutubeVideo.prototype._setup = function() {
5426
+ var that = this;
5427
+
5428
+ // Get a reference to the player
5429
+ this.player = new YT.Player( this.$video[0], {
5430
+ events: {
5431
+ 'onReady': function() {
5432
+ that.trigger({ type: 'ready' });
5433
+ that.ready = true;
5434
+ },
5435
+
5436
+ 'onStateChange': function( event ) {
5437
+ switch ( event.data ) {
5438
+ case YT.PlayerState.PLAYING:
5439
+ if (that.started === false) {
5440
+ that.started = true;
5441
+ that.trigger({ type: 'start' });
5442
+ }
5443
+
5444
+ that.state = 'playing';
5445
+ that.trigger({ type: 'play' });
5446
+ break;
5447
+
5448
+ case YT.PlayerState.PAUSED:
5449
+ that.state = 'paused';
5450
+ that.trigger({ type: 'pause' });
5451
+ break;
5452
+
5453
+ case YT.PlayerState.ENDED:
5454
+ that.state = 'ended';
5455
+ that.trigger({ type: 'ended' });
5456
+ break;
5457
+ }
5458
+ }
5459
+ }
5460
+ });
5461
+ };
5462
+
5463
+ YoutubeVideo.prototype.play = function() {
5464
+ var that = this;
5465
+
5466
+ if ( this.ready === true ) {
5467
+ this.player.playVideo();
5468
+ } else {
5469
+ var timer = setInterval(function() {
5470
+ if ( that.ready === true ) {
5471
+ clearInterval( timer );
5472
+ that.player.playVideo();
5473
+ }
5474
+ }, 100 );
5475
+ }
5476
+ };
5477
+
5478
+ YoutubeVideo.prototype.pause = function() {
5479
+ // On iOS, simply pausing the video can make other videos unresponsive
5480
+ // so we stop the video instead.
5481
+ if ( isIOS === true ) {
5482
+ this.stop();
5483
+ } else {
5484
+ this.player.pauseVideo();
5485
+ }
5486
+ };
5487
+
5488
+ YoutubeVideo.prototype.stop = function() {
5489
+ this.player.seekTo( 1 );
5490
+ this.player.stopVideo();
5491
+ this.state = 'stopped';
5492
+ };
5493
+
5494
+ YoutubeVideo.prototype.replay = function() {
5495
+ this.player.seekTo( 1 );
5496
+ this.player.playVideo();
5497
+ };
5498
+
5499
+ YoutubeVideo.prototype.on = function( type, callback ) {
5500
+ var that = this;
5501
+
5502
+ if ( this.init === true ) {
5503
+ Video.prototype.on.call( this, type, callback );
5504
+ } else {
5505
+ var timer = setInterval(function() {
5506
+ if ( that.init === true ) {
5507
+ clearInterval( timer );
5508
+ Video.prototype.on.call( that, type, callback );
5509
+ }
5510
+ }, 100 );
5511
+ }
5512
+ };
5513
+
5514
+ // Vimeo video
5515
+ var VimeoVideoHelper = {
5516
+ vimeoAPIAdded: false,
5517
+ vimeoVideos: []
5518
+ };
5519
+
5520
+ var VimeoVideo = function( video ) {
5521
+ this.init = false;
5522
+
5523
+ if ( typeof window.Froogaloop !== 'undefined' ) {
5524
+ Video.call( this, video );
5525
+ } else {
5526
+ VimeoVideoHelper.vimeoVideos.push({ 'video': video, 'scope': this });
5527
+
5528
+ if ( VimeoVideoHelper.vimeoAPIAdded === false ) {
5529
+ VimeoVideoHelper.vimeoAPIAdded = true;
5530
+
5531
+ var tag = document.createElement('script');
5532
+ tag.src = "http://a.vimeocdn.com/js/froogaloop2.min.js";
5533
+ var firstScriptTag = document.getElementsByTagName( 'script' )[0];
5534
+ firstScriptTag.parentNode.insertBefore( tag, firstScriptTag );
5535
+
5536
+ var checkVimeoAPITimer = setInterval(function() {
5537
+ if ( typeof window.Froogaloop !== 'undefined' ) {
5538
+ clearInterval( checkVimeoAPITimer );
5539
+
5540
+ $.each( VimeoVideoHelper.vimeoVideos, function( index, element ) {
5541
+ Video.call( element.scope, element.video );
5542
+ });
5543
+ }
5544
+ }, 100 );
5545
+ }
5546
+ }
5547
+ };
5548
+
5549
+ VimeoVideo.prototype = new Video();
5550
+ VimeoVideo.prototype.constructor = VimeoVideo;
5551
+ $.VideoController.addPlayer( 'VimeoVideo', VimeoVideo );
5552
+
5553
+ VimeoVideo.isType = function( video ) {
5554
+ if ( video.is( 'iframe' ) ) {
5555
+ var src = video.attr('src');
5556
+
5557
+ if ( src.indexOf( 'vimeo.com' ) !== -1 ) {
5558
+ return true;
5559
+ }
5560
+ }
5561
+
5562
+ return false;
5563
+ };
5564
+
5565
+ VimeoVideo.prototype._init = function() {
5566
+ this.init = true;
5567
+ this._setup();
5568
+ };
5569
+
5570
+ VimeoVideo.prototype._setup = function() {
5571
+ var that = this;
5572
+
5573
+ // Get a reference to the player
5574
+ this.player = $f( this.$video[0] );
5575
+
5576
+ this.player.addEvent( 'ready', function() {
5577
+ that.ready = true;
5578
+ that.trigger({ type: 'ready' });
5579
+
5580
+ that.player.addEvent( 'play', function() {
5581
+ if ( that.started === false ) {
5582
+ that.started = true;
5583
+ that.trigger({ type: 'start' });
5584
+ }
5585
+
5586
+ that.state = 'playing';
5587
+ that.trigger({ type: 'play' });
5588
+ });
5589
+
5590
+ that.player.addEvent( 'pause', function() {
5591
+ that.state = 'paused';
5592
+ that.trigger({ type: 'pause' });
5593
+ });
5594
+
5595
+ that.player.addEvent( 'finish', function() {
5596
+ that.state = 'ended';
5597
+ that.trigger({ type: 'ended' });
5598
+ });
5599
+ });
5600
+ };
5601
+
5602
+ VimeoVideo.prototype.play = function() {
5603
+ var that = this;
5604
+
5605
+ if ( this.ready === true ) {
5606
+ this.player.api( 'play' );
5607
+ } else {
5608
+ var timer = setInterval(function() {
5609
+ if ( that.ready === true ) {
5610
+ clearInterval( timer );
5611
+ that.player.api( 'play' );
5612
+ }
5613
+ }, 100 );
5614
+ }
5615
+ };
5616
+
5617
+ VimeoVideo.prototype.pause = function() {
5618
+ this.player.api( 'pause' );
5619
+ };
5620
+
5621
+ VimeoVideo.prototype.stop = function() {
5622
+ this.player.api( 'seekTo', 0 );
5623
+ this.player.api( 'pause' );
5624
+ this.state = 'stopped';
5625
+ };
5626
+
5627
+ VimeoVideo.prototype.replay = function() {
5628
+ this.player.api( 'seekTo', 0 );
5629
+ this.player.api( 'play' );
5630
+ };
5631
+
5632
+ VimeoVideo.prototype.on = function( type, callback ) {
5633
+ var that = this;
5634
+
5635
+ if ( this.init === true ) {
5636
+ Video.prototype.on.call( this, type, callback );
5637
+ } else {
5638
+ var timer = setInterval(function() {
5639
+ if ( that.init === true ) {
5640
+ clearInterval( timer );
5641
+ Video.prototype.on.call( that, type, callback );
5642
+ }
5643
+ }, 100 );
5644
+ }
5645
+ };
5646
+
5647
+ // HTML5 video
5648
+ var HTML5Video = function( video ) {
5649
+ Video.call( this, video );
5650
+ };
5651
+
5652
+ HTML5Video.prototype = new Video();
5653
+ HTML5Video.prototype.constructor = HTML5Video;
5654
+ $.VideoController.addPlayer( 'HTML5Video', HTML5Video );
5655
+
5656
+ HTML5Video.isType = function( video ) {
5657
+ if ( video.is( 'video' ) && video.hasClass( 'video-js' ) === false && video.hasClass( 'sublime' ) === false ) {
5658
+ return true;
5659
+ }
5660
+
5661
+ return false;
5662
+ };
5663
+
5664
+ HTML5Video.prototype._init = function() {
5665
+ var that = this;
5666
+
5667
+ // Get a reference to the player
5668
+ this.player = this.$video[0];
5669
+ this.ready = true;
5670
+
5671
+ this.player.addEventListener( 'play', function() {
5672
+ if ( that.started === false ) {
5673
+ that.started = true;
5674
+ that.trigger({ type: 'start' });
5675
+ }
5676
+
5677
+ that.state = 'playing';
5678
+ that.trigger({ type: 'play' });
5679
+ });
5680
+
5681
+ this.player.addEventListener( 'pause', function() {
5682
+ that.state = 'paused';
5683
+ that.trigger({ type: 'pause' });
5684
+ });
5685
+
5686
+ this.player.addEventListener( 'ended', function() {
5687
+ that.state = 'ended';
5688
+ that.trigger({ type: 'ended' });
5689
+ });
5690
+ };
5691
+
5692
+ HTML5Video.prototype.play = function() {
5693
+ this.player.play();
5694
+ };
5695
+
5696
+ HTML5Video.prototype.pause = function() {
5697
+ this.player.pause();
5698
+ };
5699
+
5700
+ HTML5Video.prototype.stop = function() {
5701
+ this.player.currentTime = 0;
5702
+ this.player.pause();
5703
+ this.state = 'stopped';
5704
+ };
5705
+
5706
+ HTML5Video.prototype.replay = function() {
5707
+ this.player.currentTime = 0;
5708
+ this.player.play();
5709
+ };
5710
+
5711
+ // VideoJS video
5712
+ var VideoJSVideo = function( video ) {
5713
+ Video.call( this, video );
5714
+ };
5715
+
5716
+ VideoJSVideo.prototype = new Video();
5717
+ VideoJSVideo.prototype.constructor = VideoJSVideo;
5718
+ $.VideoController.addPlayer( 'VideoJSVideo', VideoJSVideo );
5719
+
5720
+ VideoJSVideo.isType = function( video ) {
5721
+ if ( ( typeof video.attr( 'data-videojs-id' ) !== 'undefined' || video.hasClass( 'video-js' ) ) && typeof videojs !== 'undefined' ) {
5722
+ return true;
5723
+ }
5724
+
5725
+ return false;
5726
+ };
5727
+
5728
+ VideoJSVideo.prototype._init = function() {
5729
+ var that = this,
5730
+ videoID = this.$video.hasClass( 'video-js' ) ? this.$video.attr( 'id' ) : this.$video.attr( 'data-videojs-id' );
5731
+
5732
+ this.player = videojs( videoID );
5733
+
5734
+ this.player.ready(function() {
5735
+ that.ready = true;
5736
+ that.trigger({ type: 'ready' });
5737
+
5738
+ that.player.on( 'play', function() {
5739
+ if ( that.started === false ) {
5740
+ that.started = true;
5741
+ that.trigger({ type: 'start' });
5742
+ }
5743
+
5744
+ that.state = 'playing';
5745
+ that.trigger({ type: 'play' });
5746
+ });
5747
+
5748
+ that.player.on( 'pause', function() {
5749
+ that.state = 'paused';
5750
+ that.trigger({ type: 'pause' });
5751
+ });
5752
+
5753
+ that.player.on( 'ended', function() {
5754
+ that.state = 'ended';
5755
+ that.trigger({ type: 'ended' });
5756
+ });
5757
+ });
5758
+ };
5759
+
5760
+ VideoJSVideo.prototype.play = function() {
5761
+ this.player.play();
5762
+ };
5763
+
5764
+ VideoJSVideo.prototype.pause = function() {
5765
+ this.player.pause();
5766
+ };
5767
+
5768
+ VideoJSVideo.prototype.stop = function() {
5769
+ this.player.currentTime( 0 );
5770
+ this.player.pause();
5771
+ this.state = 'stopped';
5772
+ };
5773
+
5774
+ VideoJSVideo.prototype.replay = function() {
5775
+ this.player.currentTime( 0 );
5776
+ this.player.play();
5777
+ };
5778
+
5779
+ // Sublime video
5780
+ var SublimeVideo = function( video ) {
5781
+ Video.call( this, video );
5782
+ };
5783
+
5784
+ SublimeVideo.prototype = new Video();
5785
+ SublimeVideo.prototype.constructor = SublimeVideo;
5786
+ $.VideoController.addPlayer( 'SublimeVideo', SublimeVideo );
5787
+
5788
+ SublimeVideo.isType = function( video ) {
5789
+ if ( video.hasClass( 'sublime' ) && typeof sublime !== 'undefined' ) {
5790
+ return true;
5791
+ }
5792
+
5793
+ return false;
5794
+ };
5795
+
5796
+ SublimeVideo.prototype._init = function() {
5797
+ var that = this;
5798
+
5799
+ sublime.ready(function() {
5800
+ // Get a reference to the player
5801
+ that.player = sublime.player( that.$video.attr( 'id' ) );
5802
+
5803
+ that.ready = true;
5804
+ that.trigger({ type: 'ready' });
5805
+
5806
+ that.player.on( 'play', function() {
5807
+ if ( that.started === false ) {
5808
+ that.started = true;
5809
+ that.trigger({ type: 'start' });
5810
+ }
5811
+
5812
+ that.state = 'playing';
5813
+ that.trigger({ type: 'play' });
5814
+ });
5815
+
5816
+ that.player.on( 'pause', function() {
5817
+ that.state = 'paused';
5818
+ that.trigger({ type: 'pause' });
5819
+ });
5820
+
5821
+ that.player.on( 'stop', function() {
5822
+ that.state = 'stopped';
5823
+ that.trigger({ type: 'stop' });
5824
+ });
5825
+
5826
+ that.player.on( 'end', function() {
5827
+ that.state = 'ended';
5828
+ that.trigger({ type: 'ended' });
5829
+ });
5830
+ });
5831
+ };
5832
+
5833
+ SublimeVideo.prototype.play = function() {
5834
+ this.player.play();
5835
+ };
5836
+
5837
+ SublimeVideo.prototype.pause = function() {
5838
+ this.player.pause();
5839
+ };
5840
+
5841
+ SublimeVideo.prototype.stop = function() {
5842
+ this.player.stop();
5843
+ };
5844
+
5845
+ SublimeVideo.prototype.replay = function() {
5846
+ this.player.stop();
5847
+ this.player.play();
5848
+ };
5849
+
5850
+ // JWPlayer video
5851
+ var JWPlayerVideo = function( video ) {
5852
+ Video.call( this, video );
5853
+ };
5854
+
5855
+ JWPlayerVideo.prototype = new Video();
5856
+ JWPlayerVideo.prototype.constructor = JWPlayerVideo;
5857
+ $.VideoController.addPlayer( 'JWPlayerVideo', JWPlayerVideo );
5858
+
5859
+ JWPlayerVideo.isType = function( video ) {
5860
+ if ( ( typeof video.attr( 'data-jwplayer-id' ) !== 'undefined' || video.hasClass( 'jwplayer' ) || video.find( "object[data*='jwplayer']" ).length !== 0 ) &&
5861
+ typeof jwplayer !== 'undefined') {
5862
+ return true;
5863
+ }
5864
+
5865
+ return false;
5866
+ };
5867
+
5868
+ JWPlayerVideo.prototype._init = function() {
5869
+ var that = this,
5870
+ videoID;
5871
+
5872
+ if ( this.$video.hasClass( 'jwplayer' ) ) {
5873
+ videoID = this.$video.attr( 'id' );
5874
+ } else if ( typeof this.$video.attr( 'data-jwplayer-id' ) !== 'undefined' ) {
5875
+ videoID = this.$video.attr( 'data-jwplayer-id');
5876
+ } else if ( this.$video.find( "object[data*='jwplayer']" ).length !== 0 ) {
5877
+ videoID = this.$video.find( 'object' ).attr( 'id' );
5878
+ }
5879
+
5880
+ // Get a reference to the player
5881
+ this.player = jwplayer( videoID );
5882
+
5883
+ this.player.onReady(function() {
5884
+ that.ready = true;
5885
+ that.trigger({ type: 'ready' });
5886
+
5887
+ that.player.onPlay(function() {
5888
+ if ( that.started === false ) {
5889
+ that.started = true;
5890
+ that.trigger({ type: 'start' });
5891
+ }
5892
+
5893
+ that.state = 'playing';
5894
+ that.trigger({ type: 'play' });
5895
+ });
5896
+
5897
+ that.player.onPause(function() {
5898
+ that.state = 'paused';
5899
+ that.trigger({ type: 'pause' });
5900
+ });
5901
+
5902
+ that.player.onComplete(function() {
5903
+ that.state = 'ended';
5904
+ that.trigger({ type: 'ended' });
5905
+ });
5906
+ });
5907
+ };
5908
+
5909
+ JWPlayerVideo.prototype.play = function() {
5910
+ this.player.play( true );
5911
+ };
5912
+
5913
+ JWPlayerVideo.prototype.pause = function() {
5914
+ this.player.pause( true );
5915
+ };
5916
+
5917
+ JWPlayerVideo.prototype.stop = function() {
5918
+ this.player.stop();
5919
+ this.state = 'stopped';
5920
+ };
5921
+
5922
+ JWPlayerVideo.prototype.replay = function() {
5923
+ this.player.seek( 0 );
5924
+ this.player.play( true );
5925
+ };
5926
+
5927
+ })( jQuery );
languages/W_R_I_S-en_EN.mo ADDED
Binary file
languages/W_R_I_S-en_EN.po ADDED
@@ -0,0 +1,428 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ msgid ""
2
+ msgstr ""
3
+ "Project-Id-Version: Flicker Album Gallery\n"
4
+ "POT-Creation-Date: 2015-11-25 12:53+0530\n"
5
+ "PO-Revision-Date: 2015-11-25 12:53+0530\n"
6
+ "Last-Translator: Weblizar <lizarweb@gmail.com>\n"
7
+ "Language-Team: \n"
8
+ "Language: en\n"
9
+ "MIME-Version: 1.0\n"
10
+ "Content-Type: text/plain; charset=UTF-8\n"
11
+ "Content-Transfer-Encoding: 8bit\n"
12
+ "X-Generator: Poedit 1.8.6\n"
13
+ "X-Poedit-Basepath: .\n"
14
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
15
+ "X-Poedit-KeywordsList: _e;__\n"
16
+ "X-Poedit-SourceCharset: UTF-8\n"
17
+ "X-Poedit-SearchPath-0: .\n"
18
+
19
+ #: tooltip.php:33 ultimate-responsive-image-slider-settings-meta-box.php:127
20
+ msgid "Sliding Arrow"
21
+ msgstr ""
22
+
23
+ #: tooltip.php:38 ultimate-responsive-image-slider-settings-meta-box.php:140
24
+ msgid "Show Thumbnail"
25
+ msgstr ""
26
+
27
+ #: tooltip.php:43 ultimate-responsive-image-slider-settings-meta-box.php:190
28
+ msgid "Show Navigation Bullets"
29
+ msgstr ""
30
+
31
+ #: tooltip.php:48 ultimate-responsive-image-slider-settings-meta-box.php:203
32
+ msgid "Slider Width"
33
+ msgstr ""
34
+
35
+ #: tooltip.php:53 ultimate-responsive-image-slider-settings-meta-box.php:219
36
+ msgid "Slider Height"
37
+ msgstr ""
38
+
39
+ #: tooltip.php:58 ultimate-responsive-image-slider-settings-meta-box.php:115
40
+ msgid "Slide Distance"
41
+ msgstr ""
42
+
43
+ #: tooltip.php:63 ultimate-responsive-image-slider-settings-meta-box.php:263
44
+ msgid "Slide Title Color"
45
+ msgstr ""
46
+
47
+ #: tooltip.php:68 ultimate-responsive-image-slider-settings-meta-box.php:278
48
+ msgid "Slide Title Background Color"
49
+ msgstr ""
50
+
51
+ #: tooltip.php:73 ultimate-responsive-image-slider-settings-meta-box.php:293
52
+ msgid "Slide Description Color"
53
+ msgstr ""
54
+
55
+ #: tooltip.php:78 ultimate-responsive-image-slider-settings-meta-box.php:308
56
+ msgid "Slide Description Background Color"
57
+ msgstr ""
58
+
59
+ #: tooltip.php:83 ultimate-responsive-image-slider-settings-meta-box.php:323
60
+ msgid "Navigation Color"
61
+ msgstr ""
62
+
63
+ #: ultimate-responsive-image-slider-settings-meta-box.php:51
64
+ msgid "Configure Settings For Slider Shortcode"
65
+ msgstr ""
66
+
67
+ #: ultimate-responsive-image-slider-settings-meta-box.php:55
68
+ msgid "Display Slider Title"
69
+ msgstr ""
70
+
71
+ #: ultimate-responsive-image-slider-settings-meta-box.php:61
72
+ msgid "Select Yes/No option to show/hide slide title above slider"
73
+ msgstr ""
74
+
75
+ #: ultimate-responsive-image-slider-settings-meta-box.php:67
76
+ msgid "Auto Play Slide Show"
77
+ msgstr ""
78
+
79
+ #: ultimate-responsive-image-slider-settings-meta-box.php:70
80
+ msgid "Yes"
81
+ msgstr ""
82
+
83
+ #: ultimate-responsive-image-slider-settings-meta-box.php:71
84
+ msgid "Yes with Stop on Mouse Hover"
85
+ msgstr ""
86
+
87
+ #: ultimate-responsive-image-slider-settings-meta-box.php:72
88
+ msgid "No"
89
+ msgstr ""
90
+
91
+ #: ultimate-responsive-image-slider-settings-meta-box.php:74
92
+ msgid "Select Yes/No option to auto slide enable or disable into slider"
93
+ msgstr ""
94
+
95
+ #: ultimate-responsive-image-slider-settings-meta-box.php:79
96
+ msgid "Slide Transition"
97
+ msgstr ""
98
+
99
+ #: ultimate-responsive-image-slider-settings-meta-box.php:85
100
+ msgid "Select a transition effect you want to apply on slides"
101
+ msgstr ""
102
+
103
+ #: ultimate-responsive-image-slider-settings-meta-box.php:91
104
+ msgid "Slide Transition Speed"
105
+ msgstr ""
106
+
107
+ #: ultimate-responsive-image-slider-settings-meta-box.php:96
108
+ msgid "Set your desired transition speed of slides. Default width is 5000px"
109
+ msgstr ""
110
+
111
+ #: ultimate-responsive-image-slider-settings-meta-box.php:102
112
+ msgid "Slide Order"
113
+ msgstr ""
114
+
115
+ #: ultimate-responsive-image-slider-settings-meta-box.php:105
116
+ msgid "Ascending"
117
+ msgstr ""
118
+
119
+ #: ultimate-responsive-image-slider-settings-meta-box.php:106
120
+ msgid "Descending"
121
+ msgstr ""
122
+
123
+ #: ultimate-responsive-image-slider-settings-meta-box.php:107
124
+ msgid "Random"
125
+ msgstr ""
126
+
127
+ #: ultimate-responsive-image-slider-settings-meta-box.php:109
128
+ msgid "Select a slide order you want to apply on slides"
129
+ msgstr ""
130
+
131
+ #: ultimate-responsive-image-slider-settings-meta-box.php:120
132
+ msgid "Set a gap between all slides. Range 0 to 25"
133
+ msgstr ""
134
+
135
+ #: ultimate-responsive-image-slider-settings-meta-box.php:121
136
+ #: ultimate-responsive-image-slider-settings-meta-box.php:134
137
+ #: ultimate-responsive-image-slider-settings-meta-box.php:147
138
+ #: ultimate-responsive-image-slider-settings-meta-box.php:197
139
+ #: ultimate-responsive-image-slider-settings-meta-box.php:213
140
+ #: ultimate-responsive-image-slider-settings-meta-box.php:228
141
+ #: ultimate-responsive-image-slider-settings-meta-box.php:272
142
+ #: ultimate-responsive-image-slider-settings-meta-box.php:287
143
+ #: ultimate-responsive-image-slider-settings-meta-box.php:302
144
+ #: ultimate-responsive-image-slider-settings-meta-box.php:317
145
+ #: ultimate-responsive-image-slider-settings-meta-box.php:332
146
+ msgid "Preview"
147
+ msgstr ""
148
+
149
+ #: ultimate-responsive-image-slider-settings-meta-box.php:133
150
+ msgid "Select Yes/No option to show or hide arrows on mouse hover on slide"
151
+ msgstr ""
152
+
153
+ #: ultimate-responsive-image-slider-settings-meta-box.php:146
154
+ msgid ""
155
+ "Select Yes/No option to show or hide thumbnail based navigation under slides"
156
+ msgstr ""
157
+
158
+ #: ultimate-responsive-image-slider-settings-meta-box.php:153
159
+ msgid "Thumbnail Position"
160
+ msgstr ""
161
+
162
+ #: ultimate-responsive-image-slider-settings-meta-box.php:156
163
+ msgid "Top"
164
+ msgstr ""
165
+
166
+ #: ultimate-responsive-image-slider-settings-meta-box.php:157
167
+ msgid "Bottom"
168
+ msgstr ""
169
+
170
+ #: ultimate-responsive-image-slider-settings-meta-box.php:159
171
+ msgid "Select a thumbnail position to show above or below the slider"
172
+ msgstr ""
173
+
174
+ #: ultimate-responsive-image-slider-settings-meta-box.php:165
175
+ msgid "Thumbnail Style"
176
+ msgstr ""
177
+
178
+ #: ultimate-responsive-image-slider-settings-meta-box.php:168
179
+ msgid "Border"
180
+ msgstr ""
181
+
182
+ #: ultimate-responsive-image-slider-settings-meta-box.php:169
183
+ msgid "Pointer"
184
+ msgstr ""
185
+
186
+ #: ultimate-responsive-image-slider-settings-meta-box.php:171
187
+ msgid "Select a thumbnail style to apply on thumbnails"
188
+ msgstr ""
189
+
190
+ #: ultimate-responsive-image-slider-settings-meta-box.php:177
191
+ msgid "Thumbnail Resize"
192
+ msgstr ""
193
+
194
+ #: ultimate-responsive-image-slider-settings-meta-box.php:181
195
+ msgid "Width"
196
+ msgstr ""
197
+
198
+ #: ultimate-responsive-image-slider-settings-meta-box.php:182
199
+ msgid "Height"
200
+ msgstr ""
201
+
202
+ #: ultimate-responsive-image-slider-settings-meta-box.php:184
203
+ msgid "Set custom thumbnail height & width according to you"
204
+ msgstr ""
205
+
206
+ #: ultimate-responsive-image-slider-settings-meta-box.php:196
207
+ msgid ""
208
+ "Select Yes/No option to show or hide slider navigation buttons under image "
209
+ "slider"
210
+ msgstr ""
211
+
212
+ #: ultimate-responsive-image-slider-settings-meta-box.php:207
213
+ msgid "100% Width"
214
+ msgstr ""
215
+
216
+ #: ultimate-responsive-image-slider-settings-meta-box.php:208
217
+ msgid "Full Width"
218
+ msgstr ""
219
+
220
+ #: ultimate-responsive-image-slider-settings-meta-box.php:209
221
+ #: ultimate-responsive-image-slider-settings-meta-box.php:224
222
+ msgid "Custom"
223
+ msgstr ""
224
+
225
+ #: ultimate-responsive-image-slider-settings-meta-box.php:212
226
+ msgid "Enter your desired width for slider. Default width is 1000px"
227
+ msgstr ""
228
+
229
+ #: ultimate-responsive-image-slider-settings-meta-box.php:223
230
+ msgid "Auto Height"
231
+ msgstr ""
232
+
233
+ #: ultimate-responsive-image-slider-settings-meta-box.php:227
234
+ msgid "Enter your desired height for slider. Default height is 500px"
235
+ msgstr ""
236
+
237
+ #: ultimate-responsive-image-slider-settings-meta-box.php:234
238
+ msgid "Font Style"
239
+ msgstr ""
240
+
241
+ #: ultimate-responsive-image-slider-settings-meta-box.php:258
242
+ msgid "Choose a caption font style."
243
+ msgstr ""
244
+
245
+ #: ultimate-responsive-image-slider-settings-meta-box.php:266
246
+ #: ultimate-responsive-image-slider-settings-meta-box.php:281
247
+ #: ultimate-responsive-image-slider-settings-meta-box.php:296
248
+ #: ultimate-responsive-image-slider-settings-meta-box.php:311
249
+ #: ultimate-responsive-image-slider-settings-meta-box.php:326
250
+ msgid "Red"
251
+ msgstr ""
252
+
253
+ #: ultimate-responsive-image-slider-settings-meta-box.php:267
254
+ #: ultimate-responsive-image-slider-settings-meta-box.php:282
255
+ #: ultimate-responsive-image-slider-settings-meta-box.php:297
256
+ #: ultimate-responsive-image-slider-settings-meta-box.php:312
257
+ #: ultimate-responsive-image-slider-settings-meta-box.php:327
258
+ msgid "Blue"
259
+ msgstr ""
260
+
261
+ #: ultimate-responsive-image-slider-settings-meta-box.php:268
262
+ #: ultimate-responsive-image-slider-settings-meta-box.php:283
263
+ #: ultimate-responsive-image-slider-settings-meta-box.php:298
264
+ #: ultimate-responsive-image-slider-settings-meta-box.php:313
265
+ #: ultimate-responsive-image-slider-settings-meta-box.php:328
266
+ msgid "Black"
267
+ msgstr ""
268
+
269
+ #: ultimate-responsive-image-slider-settings-meta-box.php:269
270
+ #: ultimate-responsive-image-slider-settings-meta-box.php:284
271
+ #: ultimate-responsive-image-slider-settings-meta-box.php:299
272
+ #: ultimate-responsive-image-slider-settings-meta-box.php:314
273
+ #: ultimate-responsive-image-slider-settings-meta-box.php:329
274
+ msgid "White"
275
+ msgstr ""
276
+
277
+ #: ultimate-responsive-image-slider-settings-meta-box.php:271
278
+ msgid "Select a color to set slide title color"
279
+ msgstr ""
280
+
281
+ #: ultimate-responsive-image-slider-settings-meta-box.php:286
282
+ msgid "Select a color to set slide title background color"
283
+ msgstr ""
284
+
285
+ #: ultimate-responsive-image-slider-settings-meta-box.php:301
286
+ msgid "Select a color to set slide description color"
287
+ msgstr ""
288
+
289
+ #: ultimate-responsive-image-slider-settings-meta-box.php:316
290
+ msgid "Select a color to set slide description background color"
291
+ msgstr ""
292
+
293
+ #: ultimate-responsive-image-slider-settings-meta-box.php:331
294
+ msgid ""
295
+ "Select a color to set navigation bullets color, pointer color, border color, "
296
+ "navigation arrow color"
297
+ msgstr ""
298
+
299
+ #: ultimate-responsive-image-slider-settings-meta-box.php:338
300
+ msgid "Full Screen Slide Show"
301
+ msgstr ""
302
+
303
+ #: ultimate-responsive-image-slider-settings-meta-box.php:344
304
+ msgid "Select Yes/No option for full screen slide show"
305
+ msgstr ""
306
+
307
+ #: ultimate-responsive-image-slider-settings-meta-box.php:350
308
+ msgid "Custom CSS"
309
+ msgstr ""
310
+
311
+ #: ultimate-responsive-image-slider-settings-meta-box.php:355
312
+ msgid ""
313
+ "Enter any custom css you want to apply on this slider into textarea filed"
314
+ msgstr ""
315
+
316
+ #: ultimate-responsive-image-slider-settings-meta-box.php:356
317
+ msgid "Note"
318
+ msgstr ""
319
+
320
+ #: ultimate-responsive-image-slider-settings-meta-box.php:356
321
+ msgid "Please Do Not Use"
322
+ msgstr ""
323
+
324
+ #: ultimate-responsive-image-slider-settings-meta-box.php:356
325
+ msgid "Tag With Custom CSS"
326
+ msgstr ""
327
+
328
+ #: ultimate-responsive-image-slider.php:187
329
+ #: ultimate-responsive-image-slider.php:188
330
+ msgid "Add New Image Slider"
331
+ msgstr ""
332
+
333
+ #: ultimate-responsive-image-slider.php:189
334
+ msgid "Edit Image Slider"
335
+ msgstr ""
336
+
337
+ #: ultimate-responsive-image-slider.php:190
338
+ msgid "New Image Slider"
339
+ msgstr ""
340
+
341
+ #: ultimate-responsive-image-slider.php:191
342
+ msgid "View Image Slider"
343
+ msgstr ""
344
+
345
+ #: ultimate-responsive-image-slider.php:192
346
+ msgid "Search Image Slider"
347
+ msgstr ""
348
+
349
+ #: ultimate-responsive-image-slider.php:193
350
+ msgid "No Image Slider found"
351
+ msgstr ""
352
+
353
+ #: ultimate-responsive-image-slider.php:194
354
+ msgid "No Image Slider Found in Trash"
355
+ msgstr ""
356
+
357
+ #: ultimate-responsive-image-slider.php:195
358
+ msgid "Parent Image Slider:"
359
+ msgstr ""
360
+
361
+ #: ultimate-responsive-image-slider.php:196
362
+ msgid "All Image Sliders"
363
+ msgstr ""
364
+
365
+ #: ultimate-responsive-image-slider.php:227
366
+ msgid "UR Image Slider Title"
367
+ msgstr ""
368
+
369
+ #: ultimate-responsive-image-slider.php:228
370
+ msgid "UR Image Slider Shortcode"
371
+ msgstr ""
372
+
373
+ #: ultimate-responsive-image-slider.php:229
374
+ msgid "Date"
375
+ msgstr ""
376
+
377
+ #: ultimate-responsive-image-slider.php:246
378
+ msgid "Add Images"
379
+ msgstr ""
380
+
381
+ #: ultimate-responsive-image-slider.php:247
382
+ msgid "Apply Setting On Ultimate Responsive Image Slider"
383
+ msgstr ""
384
+
385
+ #: ultimate-responsive-image-slider.php:248
386
+ msgid "Copy Image Slider Shortcode"
387
+ msgstr ""
388
+
389
+ #: ultimate-responsive-image-slider.php:348
390
+ #: ultimate-responsive-image-slider.php:409
391
+ msgid "Slide Title"
392
+ msgstr ""
393
+
394
+ #: ultimate-responsive-image-slider.php:349
395
+ msgid "Enter Slide Title"
396
+ msgstr ""
397
+
398
+ #: ultimate-responsive-image-slider.php:352
399
+ msgid "Slide Descriptions"
400
+ msgstr ""
401
+
402
+ #: ultimate-responsive-image-slider.php:353
403
+ msgid "Enter Slide Description"
404
+ msgstr ""
405
+
406
+ #: ultimate-responsive-image-slider.php:371
407
+ msgid "Add New Images"
408
+ msgstr ""
409
+
410
+ #: ultimate-responsive-image-slider.php:375
411
+ msgid "Remove All Slides"
412
+ msgstr ""
413
+
414
+ #: ultimate-responsive-image-slider.php:388
415
+ msgid "Use below shortcode in any Page/Post to publish your slider"
416
+ msgstr ""
417
+
418
+ #: ultimate-responsive-image-slider.php:410
419
+ msgid "Enter Slide Title Here"
420
+ msgstr ""
421
+
422
+ #: ultimate-responsive-image-slider.php:413
423
+ msgid "Slide Description"
424
+ msgstr ""
425
+
426
+ #: ultimate-responsive-image-slider.php:414
427
+ msgid "Enter Slide Description Here"
428
+ msgstr ""
languages/W_R_I_S-hi_IN.mo ADDED
Binary file
languages/W_R_I_S-hi_IN.po ADDED
@@ -0,0 +1,427 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ msgid ""
2
+ msgstr ""
3
+ "Project-Id-Version: Flicker Album Gallery\n"
4
+ "POT-Creation-Date: 2015-11-25 12:53+0530\n"
5
+ "PO-Revision-Date: 2015-11-25 12:53+0530\n"
6
+ "Last-Translator: Weblizar <lizarweb@gmail.com>\n"
7
+ "Language-Team: \n"
8
+ "Language: en\n"
9
+ "MIME-Version: 1.0\n"
10
+ "Content-Type: text/plain; charset=UTF-8\n"
11
+ "Content-Transfer-Encoding: 8bit\n"
12
+ "X-Generator: Poedit 1.8.6\n"
13
+ "X-Poedit-Basepath: .\n"
14
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
15
+ "X-Poedit-KeywordsList: _e;__\n"
16
+ "X-Poedit-SourceCharset: UTF-8\n"
17
+ "X-Poedit-SearchPath-0: .\n"
18
+
19
+ #: tooltip.php:33 ultimate-responsive-image-slider-settings-meta-box.php:127
20
+ msgid "Sliding Arrow"
21
+ msgstr "तीर फिसलने"
22
+
23
+ #: tooltip.php:38 ultimate-responsive-image-slider-settings-meta-box.php:140
24
+ msgid "Show Thumbnail"
25
+ msgstr "थंबनेल दिखाएँ"
26
+
27
+ #: tooltip.php:43 ultimate-responsive-image-slider-settings-meta-box.php:190
28
+ msgid "Show Navigation Bullets"
29
+ msgstr "नेविगेशन बुलेट दिखाएँ"
30
+
31
+ #: tooltip.php:48 ultimate-responsive-image-slider-settings-meta-box.php:203
32
+ msgid "Slider Width"
33
+ msgstr "स्लाइडर चौड़ाई"
34
+
35
+ #: tooltip.php:53 ultimate-responsive-image-slider-settings-meta-box.php:219
36
+ msgid "Slider Height"
37
+ msgstr "स्लाइडर ऊंचाई"
38
+
39
+ #: tooltip.php:58 ultimate-responsive-image-slider-settings-meta-box.php:115
40
+ msgid "Slide Distance"
41
+ msgstr "स्लाइड दूरी"
42
+
43
+ #: tooltip.php:63 ultimate-responsive-image-slider-settings-meta-box.php:263
44
+ msgid "Slide Title Color"
45
+ msgstr "स्लाइड शीर्षक रंग"
46
+
47
+ #: tooltip.php:68 ultimate-responsive-image-slider-settings-meta-box.php:278
48
+ msgid "Slide Title Background Color"
49
+ msgstr "स्लाइड शीर्षक पृष्ठभूमि रंग"
50
+
51
+ #: tooltip.php:73 ultimate-responsive-image-slider-settings-meta-box.php:293
52
+ msgid "Slide Description Color"
53
+ msgstr "स्लाइड विवरण रंग"
54
+
55
+ #: tooltip.php:78 ultimate-responsive-image-slider-settings-meta-box.php:308
56
+ msgid "Slide Description Background Color"
57
+ msgstr "स्लाइड विवरण पृष्ठभूमि का रंग"
58
+
59
+ #: tooltip.php:83 ultimate-responsive-image-slider-settings-meta-box.php:323
60
+ msgid "Navigation Color"
61
+ msgstr "नेविगेशन रंग"
62
+
63
+ #: ultimate-responsive-image-slider-settings-meta-box.php:51
64
+ msgid "Configure Settings For Slider Shortcode"
65
+ msgstr "स्लाइडर शोर्ट लिए सेटिंग्स कॉन्फ़िगर"
66
+
67
+ #: ultimate-responsive-image-slider-settings-meta-box.php:55
68
+ msgid "Display Slider Title"
69
+ msgstr "स्लाइडर शीर्षक प्रदर्शन"
70
+
71
+ #: ultimate-responsive-image-slider-settings-meta-box.php:61
72
+ msgid "Select Yes/No option to show/hide slide title above slider"
73
+ msgstr "शीर्षक को दिखाने के लिए हां / नहीं विकल्प का करे"
74
+
75
+ #: ultimate-responsive-image-slider-settings-meta-box.php:67
76
+ msgid "Auto Play Slide Show"
77
+ msgstr "ऑटो प्ले स्लाइड शो"
78
+
79
+ #: ultimate-responsive-image-slider-settings-meta-box.php:70
80
+ msgid "Yes"
81
+ msgstr "हाँ"
82
+
83
+ #: ultimate-responsive-image-slider-settings-meta-box.php:71
84
+ msgid "Yes with Stop on Mouse Hover"
85
+ msgstr "हाँ mouseover पर रोक के साथ"
86
+
87
+ #: ultimate-responsive-image-slider-settings-meta-box.php:72
88
+ msgid "No"
89
+ msgstr "नहीं"
90
+
91
+ #: ultimate-responsive-image-slider-settings-meta-box.php:74
92
+ msgid "Select Yes/No option to auto slide enable or disable into slider"
93
+ msgstr "ऑटो स्लाइड करने के लिए हां / नहीं विकल्प का चयन करें"
94
+
95
+ #: ultimate-responsive-image-slider-settings-meta-box.php:79
96
+ msgid "Slide Transition"
97
+ msgstr "स्लाइड हस्तांतरण"
98
+
99
+ #: ultimate-responsive-image-slider-settings-meta-box.php:85
100
+ msgid "Select a transition effect you want to apply on slides"
101
+ msgstr "आप स्लाइड पर लागू करने के लिए एक हस्तांतरण प्रभाव का चयन करें"
102
+
103
+ #: ultimate-responsive-image-slider-settings-meta-box.php:91
104
+ msgid "Slide Transition Speed"
105
+ msgstr "संक्रमण गति स्लाइड"
106
+
107
+ #: ultimate-responsive-image-slider-settings-meta-box.php:96
108
+ msgid "Set your desired transition speed of slides. Default width is 5000px"
109
+ msgstr "स्लाइड्स के अपने वांछित संक्रमण गति सेट करें। डिफ़ॉल्ट चौड़ाई 5000px है"
110
+
111
+ #: ultimate-responsive-image-slider-settings-meta-box.php:102
112
+ msgid "Slide Order"
113
+ msgstr "स्लाइड आदेश"
114
+
115
+ #: ultimate-responsive-image-slider-settings-meta-box.php:105
116
+ msgid "Ascending"
117
+ msgstr "आरोही"
118
+
119
+ #: ultimate-responsive-image-slider-settings-meta-box.php:106
120
+ msgid "Descending"
121
+ msgstr "अवरोही"
122
+
123
+ #: ultimate-responsive-image-slider-settings-meta-box.php:107
124
+ msgid "Random"
125
+ msgstr "क्रमरहित"
126
+
127
+ #: ultimate-responsive-image-slider-settings-meta-box.php:109
128
+ msgid "Select a slide order you want to apply on slides"
129
+ msgstr "आप स्लाइड परलागू करने के लिए एक स्लाइड आदेश का चयन करें"
130
+
131
+ #: ultimate-responsive-image-slider-settings-meta-box.php:120
132
+ msgid "Set a gap between all slides. Range 0 to 25"
133
+ msgstr "सभी स्लाइड्स के बीच एक खाई सेट करें। रेंज 0-25"
134
+
135
+ #: ultimate-responsive-image-slider-settings-meta-box.php:121
136
+ #: ultimate-responsive-image-slider-settings-meta-box.php:134
137
+ #: ultimate-responsive-image-slider-settings-meta-box.php:147
138
+ #: ultimate-responsive-image-slider-settings-meta-box.php:197
139
+ #: ultimate-responsive-image-slider-settings-meta-box.php:213
140
+ #: ultimate-responsive-image-slider-settings-meta-box.php:228
141
+ #: ultimate-responsive-image-slider-settings-meta-box.php:272
142
+ #: ultimate-responsive-image-slider-settings-meta-box.php:287
143
+ #: ultimate-responsive-image-slider-settings-meta-box.php:302
144
+ #: ultimate-responsive-image-slider-settings-meta-box.php:317
145
+ #: ultimate-responsive-image-slider-settings-meta-box.php:332
146
+ msgid "Preview"
147
+ msgstr "पूर्व दर्शन"
148
+
149
+ #: ultimate-responsive-image-slider-settings-meta-box.php:133
150
+ msgid "Select Yes/No option to show or hide arrows on mouse hover on slide"
151
+ msgstr "स्लाइड पर माउस मंडराना पर तीर दिखाने या छिपाने के लिए हां / नहीं विकल्प का चयन करें"
152
+
153
+ #: ultimate-responsive-image-slider-settings-meta-box.php:146
154
+ msgid "Select Yes/No option to show or hide thumbnail based navigation under slides"
155
+ msgstr "थम्बनेल आधारित नेविगेशन दिखाने के लिए हां । नहीं विकल्प का चयन करें"
156
+
157
+ #: ultimate-responsive-image-slider-settings-meta-box.php:153
158
+ msgid "Thumbnail Position"
159
+ msgstr "थंबनेल स्थिति"
160
+
161
+ #: ultimate-responsive-image-slider-settings-meta-box.php:156
162
+ msgid "Top"
163
+ msgstr "ऊपर"
164
+
165
+ #: ultimate-responsive-image-slider-settings-meta-box.php:157
166
+ msgid "Bottom"
167
+ msgstr ""
168
+ "नीचे\n"
169
+ "\t"
170
+
171
+ #: ultimate-responsive-image-slider-settings-meta-box.php:159
172
+ msgid "Select a thumbnail position to show above or below the slider"
173
+ msgstr "स्लाइडर ऊपर या नीचे दिखाने के लिए एक थंबनेल स्थिति का चयन करें"
174
+
175
+ #: ultimate-responsive-image-slider-settings-meta-box.php:165
176
+ msgid "Thumbnail Style"
177
+ msgstr "थंबनेल शैली"
178
+
179
+ #: ultimate-responsive-image-slider-settings-meta-box.php:168
180
+ msgid "Border"
181
+ msgstr "सीमा"
182
+
183
+ #: ultimate-responsive-image-slider-settings-meta-box.php:169
184
+ msgid "Pointer"
185
+ msgstr "सूचक"
186
+
187
+ #: ultimate-responsive-image-slider-settings-meta-box.php:171
188
+ msgid "Select a thumbnail style to apply on thumbnails"
189
+ msgstr "थंबनेल पर लागू करने के लिए एक थंबनेल शैली का चयन करें"
190
+
191
+ #: ultimate-responsive-image-slider-settings-meta-box.php:177
192
+ msgid "Thumbnail Resize"
193
+ msgstr "थंबनेल आकार"
194
+
195
+ #: ultimate-responsive-image-slider-settings-meta-box.php:181
196
+ msgid "Width"
197
+ msgstr "चौड़ाई"
198
+
199
+ #: ultimate-responsive-image-slider-settings-meta-box.php:182
200
+ msgid "Height"
201
+ msgstr "ऊंचाई"
202
+
203
+ #: ultimate-responsive-image-slider-settings-meta-box.php:184
204
+ msgid "Set custom thumbnail height & width according to you"
205
+ msgstr "आप के अनुसार कस्टम थंबनेल लम्बाई और चौड़ाई सेट करें"
206
+
207
+ #: ultimate-responsive-image-slider-settings-meta-box.php:196
208
+ msgid "Select Yes/No option to show or hide slider navigation buttons under image slider"
209
+ msgstr "छवि स्लाइडर के तहत स्लाइडर नेविगेशन बटन दिखाने या छिपाने के लिए हां / नहीं विकल्प का चयन करें"
210
+
211
+ #: ultimate-responsive-image-slider-settings-meta-box.php:207
212
+ msgid "100% Width"
213
+ msgstr "100% चौड़ाई"
214
+
215
+ #: ultimate-responsive-image-slider-settings-meta-box.php:208
216
+ msgid "Full Width"
217
+ msgstr "पूरी चौड़ाई"
218
+
219
+ #: ultimate-responsive-image-slider-settings-meta-box.php:209
220
+ #: ultimate-responsive-image-slider-settings-meta-box.php:224
221
+ msgid "Custom"
222
+ msgstr "बनाइए"
223
+
224
+ #: ultimate-responsive-image-slider-settings-meta-box.php:212
225
+ msgid "Enter your desired width for slider. Default width is 1000px"
226
+ msgstr "स्लाइडर के लिए अपने इच्छित चौड़ाई दर्ज करें। डिफ़ॉल्ट चौड़ाई 1000px है"
227
+
228
+ #: ultimate-responsive-image-slider-settings-meta-box.php:223
229
+ msgid "Auto Height"
230
+ msgstr "ऑटो ऊँचाई"
231
+
232
+ #: ultimate-responsive-image-slider-settings-meta-box.php:227
233
+ msgid "Enter your desired height for slider. Default height is 500px"
234
+ msgstr "स्लाइडर के लिए अपने वांछित ऊंचाई दर्ज करें। तयशुदा ऊंचाई 500px है"
235
+
236
+ #: ultimate-responsive-image-slider-settings-meta-box.php:234
237
+ msgid "Font Style"
238
+ msgstr "फ़ॉन्ट शैली"
239
+
240
+ #: ultimate-responsive-image-slider-settings-meta-box.php:258
241
+ msgid "Choose a caption font style."
242
+ msgstr "एक शीर्षक फ़ॉन्ट शैली चुनें।"
243
+
244
+ #: ultimate-responsive-image-slider-settings-meta-box.php:266
245
+ #: ultimate-responsive-image-slider-settings-meta-box.php:281
246
+ #: ultimate-responsive-image-slider-settings-meta-box.php:296
247
+ #: ultimate-responsive-image-slider-settings-meta-box.php:311
248
+ #: ultimate-responsive-image-slider-settings-meta-box.php:326
249
+ msgid "Red"
250
+ msgstr "लाल"
251
+
252
+ #: ultimate-responsive-image-slider-settings-meta-box.php:267
253
+ #: ultimate-responsive-image-slider-settings-meta-box.php:282
254
+ #: ultimate-responsive-image-slider-settings-meta-box.php:297
255
+ #: ultimate-responsive-image-slider-settings-meta-box.php:312
256
+ #: ultimate-responsive-image-slider-settings-meta-box.php:327
257
+ msgid "Blue"
258
+ msgstr "नीला"
259
+
260
+ #: ultimate-responsive-image-slider-settings-meta-box.php:268
261
+ #: ultimate-responsive-image-slider-settings-meta-box.php:283
262
+ #: ultimate-responsive-image-slider-settings-meta-box.php:298
263
+ #: ultimate-responsive-image-slider-settings-meta-box.php:313
264
+ #: ultimate-responsive-image-slider-settings-meta-box.php:328
265
+ msgid "Black"
266
+ msgstr "काला"
267
+
268
+ #: ultimate-responsive-image-slider-settings-meta-box.php:269
269
+ #: ultimate-responsive-image-slider-settings-meta-box.php:284
270
+ #: ultimate-responsive-image-slider-settings-meta-box.php:299
271
+ #: ultimate-responsive-image-slider-settings-meta-box.php:314
272
+ #: ultimate-responsive-image-slider-settings-meta-box.php:329
273
+ msgid "White"
274
+ msgstr "सफेद"
275
+
276
+ #: ultimate-responsive-image-slider-settings-meta-box.php:271
277
+ msgid "Select a color to set slide title color"
278
+ msgstr "स्लाइड शीर्षक रंग निर्धारित करने के लिए एक रंग का चयन करें"
279
+
280
+ #: ultimate-responsive-image-slider-settings-meta-box.php:286
281
+ msgid "Select a color to set slide title background color"
282
+ msgstr "स्लाइड शीर्षक पृष्ठभूमि का रंग निर्धारित करने के लिए एक रंग का चयन करें"
283
+
284
+ #: ultimate-responsive-image-slider-settings-meta-box.php:301
285
+ msgid "Select a color to set slide description color"
286
+ msgstr "स्लाइड के वर्णन का रंग निर्धारित करने के लिए एक रंग का चयन करें"
287
+
288
+ #: ultimate-responsive-image-slider-settings-meta-box.php:316
289
+ msgid "Select a color to set slide description background color"
290
+ msgstr "स्लाइड विवरण पृष्ठभूमि रंग सेट करने के लिए एक रंग का चयन करें"
291
+
292
+ #: ultimate-responsive-image-slider-settings-meta-box.php:331
293
+ msgid ""
294
+ "Select a color to set navigation bullets color, pointer color, border color, navigation "
295
+ "arrow color"
296
+ msgstr "नेविगेशन गोलियों रंग, सूचक रंग, सीमा रंग, नेविगेशन तीर रंग निर्धारित करने के लिए एक रंग का चयन करें"
297
+
298
+ #: ultimate-responsive-image-slider-settings-meta-box.php:338
299
+ msgid "Full Screen Slide Show"
300
+ msgstr "पूर्ण स्क्रीन स्लाइड शो"
301
+
302
+ #: ultimate-responsive-image-slider-settings-meta-box.php:344
303
+ msgid "Select Yes/No option for full screen slide show"
304
+ msgstr "पूर्ण स्क्रीन स्लाइड शो के लिए हां / नहीं विकल्प का चयन करें"
305
+
306
+ #: ultimate-responsive-image-slider-settings-meta-box.php:350
307
+ msgid "Custom CSS"
308
+ msgstr "कस्टम सीएसएस"
309
+
310
+ #: ultimate-responsive-image-slider-settings-meta-box.php:355
311
+ msgid "Enter any custom css you want to apply on this slider into textarea filed"
312
+ msgstr "कोई भी कस्टम सीएसएस दर्ज करें जो इस स्लाइडर पर लागू करना चाहते हैं"
313
+
314
+ #: ultimate-responsive-image-slider-settings-meta-box.php:356
315
+ msgid "Note"
316
+ msgstr "नोट"
317
+
318
+ #: ultimate-responsive-image-slider-settings-meta-box.php:356
319
+ msgid "Please Do Not Use"
320
+ msgstr "उपयोग न करें"
321
+
322
+ #: ultimate-responsive-image-slider-settings-meta-box.php:356
323
+ msgid "Tag With Custom CSS"
324
+ msgstr "कस्टम सीएसएस के साथ टैग"
325
+
326
+ #: ultimate-responsive-image-slider.php:187 ultimate-responsive-image-slider.php:188
327
+ msgid "Add New Image Slider"
328
+ msgstr "नई छवि स्लाइडर जोड़ें"
329
+
330
+ #: ultimate-responsive-image-slider.php:189
331
+ msgid "Edit Image Slider"
332
+ msgstr "संपादित छवि स्लाइडर"
333
+
334
+ #: ultimate-responsive-image-slider.php:190
335
+ msgid "New Image Slider"
336
+ msgstr "नई छवि स्लाइडर"
337
+
338
+ #: ultimate-responsive-image-slider.php:191
339
+ msgid "View Image Slider"
340
+ msgstr "छवि स्लाइडर देखें"
341
+
342
+ #: ultimate-responsive-image-slider.php:192
343
+ msgid "Search Image Slider"
344
+ msgstr "छवि स्लाइडर खोजें"
345
+
346
+ #: ultimate-responsive-image-slider.php:193
347
+ msgid "No Image Slider found"
348
+ msgstr "छवि स्लाइडर नहीं मिला"
349
+
350
+ #: ultimate-responsive-image-slider.php:194
351
+ msgid "No Image Slider Found in Trash"
352
+ msgstr "कचरा पेटी में कोई छवि स्लाइडर नहीं मिला"
353
+
354
+ #: ultimate-responsive-image-slider.php:195
355
+ msgid "Parent Image Slider:"
356
+ msgstr "जनक छवि स्लाइडर:"
357
+
358
+ #: ultimate-responsive-image-slider.php:196
359
+ msgid "All Image Sliders"
360
+ msgstr "सभी छवि स्लाइडर"
361
+
362
+ #: ultimate-responsive-image-slider.php:227
363
+ msgid "UR Image Slider Title"
364
+ msgstr "यू.आर. छवि स्लाइडर शीर्षक"
365
+
366
+ #: ultimate-responsive-image-slider.php:228
367
+ msgid "UR Image Slider Shortcode"
368
+ msgstr "यू.आर. छवि स्लाइडर शोर्ट"
369
+
370
+ #: ultimate-responsive-image-slider.php:229
371
+ msgid "Date"
372
+ msgstr "तारीख"
373
+
374
+ #: ultimate-responsive-image-slider.php:246
375
+ msgid "Add Images"
376
+ msgstr "छवियां जोड़ें"
377
+
378
+ #: ultimate-responsive-image-slider.php:247
379
+ msgid "Apply Setting On Ultimate Responsive Image Slider"
380
+ msgstr "छवि स्लाइडर पर अंतिम उत्तरदायी सेटिंग लागू करें"
381
+
382
+ #: ultimate-responsive-image-slider.php:248
383
+ msgid "Copy Image Slider Shortcode"
384
+ msgstr "कॉपी छवि स्लाइडर शोर्ट करें"
385
+
386
+ #: ultimate-responsive-image-slider.php:348 ultimate-responsive-image-slider.php:409
387
+ msgid "Slide Title"
388
+ msgstr "शीर्षक स्लाइड"
389
+
390
+ #: ultimate-responsive-image-slider.php:349
391
+ msgid "Enter Slide Title"
392
+ msgstr "शीर्षक स्लाइड दर्ज करें"
393
+
394
+ #: ultimate-responsive-image-slider.php:352
395
+ msgid "Slide Descriptions"
396
+ msgstr "स्लाइड विवरण"
397
+
398
+ #: ultimate-responsive-image-slider.php:353
399
+ msgid "Enter Slide Description"
400
+ msgstr "स्लाइड विवरण दर्ज करें"
401
+
402
+ #: ultimate-responsive-image-slider.php:371
403
+ msgid "Add New Images"
404
+ msgstr "नई छवियाँ जोड़ें"
405
+
406
+ #: ultimate-responsive-image-slider.php:375
407
+ msgid "Remove All Slides"
408
+ msgstr "सभी स्लाइड्स मिटायें"
409
+
410
+ #: ultimate-responsive-image-slider.php:388
411
+ msgid "Use below shortcode in any Page/Post to publish your slider"
412
+ msgstr "किसी भी पोस्ट पेज में अपने स्लाइडर प्रकाशित करने के लिए नीचे कोडशोर्ट का प्रयोग करें । "
413
+
414
+ #: ultimate-responsive-image-slider.php:410
415
+ msgid "Enter Slide Title Here"
416
+ msgstr "यहाँ स्लाइड शीर्षक दर्ज करें"
417
+
418
+ #: ultimate-responsive-image-slider.php:413
419
+ msgid "Slide Description"
420
+ msgstr "स्लाइड विवरण"
421
+
422
+ #: ultimate-responsive-image-slider.php:414
423
+ msgid "Enter Slide Description Here"
424
+ msgstr "यहाँ स्लाइड विवरण दर्ज करें"
425
+
426
+ #~ msgid "Help and Support"
427
+ #~ msgstr "मदद और समर्थन"
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: http://www.weblizar.com/
4
  Tags: best slider plugin, carousel, carousel slider, coin slider, content slider, content slideshow, featured-content-slider, flex slider, free video slider, Horizontal slider, HTML5 slider, image, Image Rotator, image slider, image slideshow, images, javascript slider, javascript slideshow, jquery slider, jquery slideshow, media, nivo slider, nivoslider, page, photo slider, picture slider, plugin, Post, posts, posts slider, recent post slider, responsive, responsive slider, responsive slideshow, seo, slide, slide show, slider, slider plugin, slider shortcode, slides, slideshow, slideshow manager, slideshow plugin, vertical slider, vertical slides, wordpress seo, wordpress slider, wordpress slideshow, wp, wp slider, thumbnail slider, responsive image slider, slider plugin, mobile slider, tab slider, touch slider, text slider, link slider, media slider, 3d slider , awesome slider, wordpress slider plugin, meta slider, free slider, free plugin, gpl slider, Responsive Touch Slider, easy slider , simple slider, image slideshow, lightbox, popbox, gallery, image gallery, slider gallery, photo gallery, thumbnail, portfolio, portfolio gallery, slider portfolio, css slider, jquery plugin, jquery slider plugin, jquery slideshow plugin, animation, animation slider, navigation slider, bullet slider, html5, css3 slider, css3 slideshow, responsive images, responsive, post slider, page slider, wordpress photos slider , wordpress photos slideshow, responsive 3d slider, slideshow
5
  Requires at least: 3.5
6
  Tested up to: 4.4
7
- Stable tag: 2.7
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -32,6 +32,13 @@ Using **[URIS id=123]** shortcode, you can publish image slider in any Page or P
32
  > * Enable/Disable Slide Description
33
  > * Enable/Disable Navigation Bullets
34
  > * Enable/Disable Slide Thumbnails
 
 
 
 
 
 
 
35
  > * All Major & Latest Browser Compatible (IE, Chrome, Firefox)
36
  > * All Major Device Support
37
  > * Multilingual Translation Ready
@@ -70,6 +77,13 @@ A Perfect Responsive Image Slider plugin for WordPress. Contain 5 types of slide
70
  > * Shortcode Button on post or page
71
  > * Unique settings for each gallery
72
  > * Auto Play Pause
 
 
 
 
 
 
 
73
  > * All Browser Compatible
74
  >
75
 
@@ -125,47 +139,43 @@ If you have any question contact us at here: [Plugin Support Forum ](http://word
125
 
126
  For more information, see Weblizar(http://wwww.weblizar.com/).
127
 
 
 
 
 
 
 
 
128
 
129
  = Version 2.7 11-09-2015 =
130
-
131
  * Compatible with wordpress 4.4 beta version
132
 
133
  = Version 2.6 29-10-2015 =
134
-
135
- * small changes in code.
136
 
137
  = Version 2.4 26-10-2015 =
138
-
139
  * Resolved long description in safari.
140
 
141
-
142
  = Version 2.3 19-10-2015 =
143
-
144
  * Small bug fixed
145
 
146
  = Version 2.2 12-10-2015 =
147
-
148
  * Small design bug fixed
149
 
150
  = Version 2.1 28-09-2015 =
151
-
152
  * Add Alt tag in slide images
153
 
154
  = Version 2.0 21-09-2015 =
155
-
156
  * Compatible with wordpress 4.3.1
157
  * Small bug resolved.
158
 
159
  = Version 1.9 02-09-2015 =
160
-
161
  * New : Add Import/Export Settings
162
 
163
  = Version 1.8 01-09-2015 =
164
-
165
  * Small Update in admin bootstrap css
166
 
167
  = Version 1.7 11-08-2015 =
168
-
169
  * New Feature: Slide Translation Speed Setting
170
  * New Feature: Slide Translation Effect Setting
171
  * New Feature: Custom CSS Setting
@@ -174,40 +184,31 @@ For more information, see Weblizar(http://wwww.weblizar.com/).
174
  * Compatible with wordPress 4.3 version
175
 
176
  = Version 1.6 10-07-2015 =
177
-
178
  * Resolved font of image titles is shrink problem for responsive views (safari).
179
 
180
  = Version 1.5 07-07-2015 =
181
-
182
  * Fixed small bug
183
 
184
  = Version 1.4 08-06-2015 =
185
-
186
  * Compatible with WordPress 4.2.2 version
187
  * Small changes in code
188
 
189
  = Version 1.3 21-04-2015 =
190
-
191
  * Compatible with WordPress 4.2 version
192
 
193
  = Version 1.2 31-03-2015 =
194
-
195
  * Resolved capitalization issue of title
196
  * New Added hide/display slider title field setting
197
  * Change design style of slider title
198
  * Add Margin at bottom of slider
199
 
200
  = Version 1.1 19-03-2015 =
201
-
202
  * Resolve Slide Title and Description layout problem for small container
203
- * Resolve Admin pane conflict with another plugins
204
-
205
 
206
  = Version 1.0 04-03-2015 =
207
-
208
  * This is first and basic version of slider plugin.
209
 
210
-
211
  = Docs & Support =
212
 
213
  If any support required then post your query in WordPress [Plugin Support Forum ](http://wordpress.org/support/plugin/ultimate-responsive-image-slider)
4
  Tags: best slider plugin, carousel, carousel slider, coin slider, content slider, content slideshow, featured-content-slider, flex slider, free video slider, Horizontal slider, HTML5 slider, image, Image Rotator, image slider, image slideshow, images, javascript slider, javascript slideshow, jquery slider, jquery slideshow, media, nivo slider, nivoslider, page, photo slider, picture slider, plugin, Post, posts, posts slider, recent post slider, responsive, responsive slider, responsive slideshow, seo, slide, slide show, slider, slider plugin, slider shortcode, slides, slideshow, slideshow manager, slideshow plugin, vertical slider, vertical slides, wordpress seo, wordpress slider, wordpress slideshow, wp, wp slider, thumbnail slider, responsive image slider, slider plugin, mobile slider, tab slider, touch slider, text slider, link slider, media slider, 3d slider , awesome slider, wordpress slider plugin, meta slider, free slider, free plugin, gpl slider, Responsive Touch Slider, easy slider , simple slider, image slideshow, lightbox, popbox, gallery, image gallery, slider gallery, photo gallery, thumbnail, portfolio, portfolio gallery, slider portfolio, css slider, jquery plugin, jquery slider plugin, jquery slideshow plugin, animation, animation slider, navigation slider, bullet slider, html5, css3 slider, css3 slideshow, responsive images, responsive, post slider, page slider, wordpress photos slider , wordpress photos slideshow, responsive 3d slider, slideshow
5
  Requires at least: 3.5
6
  Tested up to: 4.4
7
+ Stable tag: 2.8
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
32
  > * Enable/Disable Slide Description
33
  > * Enable/Disable Navigation Bullets
34
  > * Enable/Disable Slide Thumbnails
35
+ > * Customize Thumbnail Position (New)
36
+ > * Customize Thumbnail Width And Height (New)
37
+ > * Auto Height Option (New)
38
+ > * Label And Description Colour Settings (New)
39
+ > * Added Font Style (New)
40
+ > * Customize Slider Distance (New)
41
+ > * Slider Order - Ascending , Descending and random (New)
42
  > * All Major & Latest Browser Compatible (IE, Chrome, Firefox)
43
  > * All Major Device Support
44
  > * Multilingual Translation Ready
77
  > * Shortcode Button on post or page
78
  > * Unique settings for each gallery
79
  > * Auto Play Pause
80
+ > * Customize Thumbnail Position
81
+ > * Slider Orientation - horizontal and vertical (New)
82
+ > * Slider Order - Ascending , Descending and random (New)
83
+ > * 500+ Google Font Style (New)
84
+ > * Customize Thumbnail Position (New)
85
+ > * Customize Thumbnail Width And Height (New)
86
+ > * Auto Height Option (New)
87
  > * All Browser Compatible
88
  >
89
 
139
 
140
  For more information, see Weblizar(http://wwww.weblizar.com/).
141
 
142
+ = Version 2.8 18-11-2015 =
143
+ * Slider Jquery version updated
144
+ * Slider CSS version updated
145
+ * New Setting Added - slide order, slider thumbnail resize, thumbnails position, thumbnails, Slider width option, slider height option, auto height, slide distance
146
+ * New Added Font Colour Scheme
147
+ * New Added Font Styles
148
+ * Compatible with Wordpress 4.4 version
149
 
150
  = Version 2.7 11-09-2015 =
 
151
  * Compatible with wordpress 4.4 beta version
152
 
153
  = Version 2.6 29-10-2015 =
154
+ * small changes in code
 
155
 
156
  = Version 2.4 26-10-2015 =
 
157
  * Resolved long description in safari.
158
 
 
159
  = Version 2.3 19-10-2015 =
 
160
  * Small bug fixed
161
 
162
  = Version 2.2 12-10-2015 =
 
163
  * Small design bug fixed
164
 
165
  = Version 2.1 28-09-2015 =
 
166
  * Add Alt tag in slide images
167
 
168
  = Version 2.0 21-09-2015 =
 
169
  * Compatible with wordpress 4.3.1
170
  * Small bug resolved.
171
 
172
  = Version 1.9 02-09-2015 =
 
173
  * New : Add Import/Export Settings
174
 
175
  = Version 1.8 01-09-2015 =
 
176
  * Small Update in admin bootstrap css
177
 
178
  = Version 1.7 11-08-2015 =
 
179
  * New Feature: Slide Translation Speed Setting
180
  * New Feature: Slide Translation Effect Setting
181
  * New Feature: Custom CSS Setting
184
  * Compatible with wordPress 4.3 version
185
 
186
  = Version 1.6 10-07-2015 =
 
187
  * Resolved font of image titles is shrink problem for responsive views (safari).
188
 
189
  = Version 1.5 07-07-2015 =
 
190
  * Fixed small bug
191
 
192
  = Version 1.4 08-06-2015 =
 
193
  * Compatible with WordPress 4.2.2 version
194
  * Small changes in code
195
 
196
  = Version 1.3 21-04-2015 =
 
197
  * Compatible with WordPress 4.2 version
198
 
199
  = Version 1.2 31-03-2015 =
 
200
  * Resolved capitalization issue of title
201
  * New Added hide/display slider title field setting
202
  * Change design style of slider title
203
  * Add Margin at bottom of slider
204
 
205
  = Version 1.1 19-03-2015 =
 
206
  * Resolve Slide Title and Description layout problem for small container
207
+ * Resolve Admin panel conflict with another plugins
 
208
 
209
  = Version 1.0 04-03-2015 =
 
210
  * This is first and basic version of slider plugin.
211
 
 
212
  = Docs & Support =
213
 
214
  If any support required then post your query in WordPress [Plugin Support Forum ](http://wordpress.org/support/plugin/ultimate-responsive-image-slider)
tooltip.php CHANGED
@@ -12,6 +12,11 @@ jQuery(document).ready( function(){
12
  jQuery('#p4').darkTooltip();
13
  jQuery('#p5').darkTooltip();
14
  jQuery('#p6').darkTooltip();
 
 
 
 
 
15
 
16
  //With some options
17
  jQuery('#light').darkTooltip({
@@ -25,26 +30,56 @@ jQuery(document).ready( function(){
25
  <?php $PreviewImg = WRIS_PLUGIN_URL.'img/'; ?>
26
 
27
  <div style="display:none;" id="s1">
28
- <h4>Sliding Arrow</h4>
29
  <img src="<?php echo $PreviewImg."sliding-arrow.jpg"; ?>" class="sprev">
30
  </div>
31
 
32
  <div style="display:none;" id="s2">
33
- <h4>Show Thumbnail</h4>
34
  <img src="<?php echo $PreviewImg."show-thumbnail.jpg"; ?>" class="sprev">
35
  </div>
36
 
37
  <div style="display:none;" id="s3">
38
- <h4>Show Navigation Bullets</h4>
39
  <img src="<?php echo $PreviewImg."show-navigation-bullets.jpg"; ?>" class="sprev">
40
  </div>
41
 
42
  <div style="display:none;" id="s4">
43
- <h4>Slider Width</h4>
44
  <img src="<?php echo $PreviewImg."slider-width.jpg"; ?>" class="sprev">
45
  </div>
46
 
47
  <div style="display:none;" id="s5">
48
- <h4>Slider Height</h4>
49
  <img src="<?php echo $PreviewImg."slider-height.jpg"; ?>" class="sprev">
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
50
  </div>
12
  jQuery('#p4').darkTooltip();
13
  jQuery('#p5').darkTooltip();
14
  jQuery('#p6').darkTooltip();
15
+ jQuery('#p7').darkTooltip();
16
+ jQuery('#p8').darkTooltip();
17
+ jQuery('#p9').darkTooltip();
18
+ jQuery('#p10').darkTooltip();
19
+ jQuery('#p11').darkTooltip();
20
 
21
  //With some options
22
  jQuery('#light').darkTooltip({
30
  <?php $PreviewImg = WRIS_PLUGIN_URL.'img/'; ?>
31
 
32
  <div style="display:none;" id="s1">
33
+ <h4><?php _e('Sliding Arrow', WRIS_TEXT_DOMAIN); ?></h4>
34
  <img src="<?php echo $PreviewImg."sliding-arrow.jpg"; ?>" class="sprev">
35
  </div>
36
 
37
  <div style="display:none;" id="s2">
38
+ <h4><?php _e('Show Thumbnail', WRIS_TEXT_DOMAIN); ?></h4>
39
  <img src="<?php echo $PreviewImg."show-thumbnail.jpg"; ?>" class="sprev">
40
  </div>
41
 
42
  <div style="display:none;" id="s3">
43
+ <h4><?php _e('Show Navigation Bullets', WRIS_TEXT_DOMAIN); ?></h4>
44
  <img src="<?php echo $PreviewImg."show-navigation-bullets.jpg"; ?>" class="sprev">
45
  </div>
46
 
47
  <div style="display:none;" id="s4">
48
+ <h4><?php _e('Slider Width', WRIS_TEXT_DOMAIN); ?></h4>
49
  <img src="<?php echo $PreviewImg."slider-width.jpg"; ?>" class="sprev">
50
  </div>
51
 
52
  <div style="display:none;" id="s5">
53
+ <h4><?php _e('Slider Height', WRIS_TEXT_DOMAIN); ?></h4>
54
  <img src="<?php echo $PreviewImg."slider-height.jpg"; ?>" class="sprev">
55
+ </div>
56
+
57
+ <div style="display:none;" id="s6">
58
+ <h4><?php _e('Slide Distance', WRIS_TEXT_DOMAIN); ?></h4>
59
+ <img src="<?php echo $PreviewImg."slide-distance.jpg"; ?>" class="sprev">
60
+ </div>
61
+
62
+ <div style="display:none;" id="s7">
63
+ <h4><?php _e('Slide Title Color', WRIS_TEXT_DOMAIN); ?></h4>
64
+ <img src="<?php echo $PreviewImg."title-color.jpg"; ?>" class="sprev">
65
+ </div>
66
+
67
+ <div style="display:none;" id="s8">
68
+ <h4><?php _e('Slide Title Background Color', WRIS_TEXT_DOMAIN); ?></h4>
69
+ <img src="<?php echo $PreviewImg."title-bg-color.jpg"; ?>" class="sprev">
70
+ </div>
71
+
72
+ <div style="display:none;" id="s9">
73
+ <h4><?php _e('Slide Description Color', WRIS_TEXT_DOMAIN); ?></h4>
74
+ <img src="<?php echo $PreviewImg."desc-color.jpg"; ?>" class="sprev">
75
+ </div>
76
+
77
+ <div style="display:none;" id="s10">
78
+ <h4><?php _e('Slide Description Background Color', WRIS_TEXT_DOMAIN); ?></h4>
79
+ <img src="<?php echo $PreviewImg."desc-bg-color.jpg"; ?>" class="sprev">
80
+ </div>
81
+
82
+ <div style="display:none;" id="s11">
83
+ <h4><?php _e('Navigation Color', WRIS_TEXT_DOMAIN); ?></h4>
84
+ <img src="<?php echo $PreviewImg."navigation-color.jpg"; ?>" class="sprev">
85
  </div>
tooltip/jquery.darktooltip.min.js CHANGED
@@ -1 +1 @@
1
- (function(b){function a(d,c){this.bearer=d;this.options=c;this.hideEvent;this.mouseOverMode=(this.options.trigger=="hover"||this.options.trigger=="mouseover"||this.options.trigger=="onmouseover")}a.prototype={show:function(){var c=this;this.tooltip.css("display","block");if(c.mouseOverMode){this.tooltip.mouseover(function(){clearTimeout(c.hideEvent)});this.tooltip.mouseout(function(){clearTimeout(c.hideEvent);c.hide()})}},hide:function(){var c=this;this.hideEvent=setTimeout(function(){c.tooltip.hide()},100)},toggle:function(){if(this.tooltip.is(":visible")){this.hide()}else{this.show()}},addAnimation:function(){switch(this.options.animation){case"none":break;case"fadeIn":this.tooltip.addClass("animated");this.tooltip.addClass("fadeIn");break;case"flipIn":this.tooltip.addClass("animated");this.tooltip.addClass("flipIn");break}},setContent:function(){b(this.bearer).css("cursor","pointer");if(this.options.content){this.content=this.options.content}else{if(this.bearer.attr("data-tooltip")){this.content=this.bearer.attr("data-tooltip")}else{return}}if(this.content.charAt(0)=="#"){b(this.content).hide();this.content=b(this.content).html();this.contentType="html"}else{this.contentType="text"}this.tooltip=b("<ins class = 'dark-tooltip "+this.options.theme+" "+this.options.size+" "+this.options.gravity+"'><div>"+this.content+"</div><div class = 'tip'></div></ins>");this.tip=this.tooltip.find(".tip");b("body").append(this.tooltip);if(this.contentType=="html"){this.tooltip.css("max-width","none")}this.tooltip.css("opacity",this.options.opacity);this.addAnimation();if(this.options.confirm){this.addConfirm()}},setPositions:function(){var d=this.bearer.offset().left;var c=this.bearer.offset().top;switch(this.options.gravity){case"south":d+=this.bearer.outerWidth()/2-this.tooltip.outerWidth()/2;c+=-this.tooltip.outerHeight()-this.tip.outerHeight()/2;break;case"west":d+=this.bearer.outerWidth()+this.tip.outerWidth()/2;c+=this.bearer.outerHeight()/2-(this.tooltip.outerHeight()/2);break;case"north":d+=this.bearer.outerWidth()/2-(this.tooltip.outerWidth()/2);c+=this.bearer.outerHeight()+this.tip.outerHeight()/2;break;case"east":d+=-this.tooltip.outerWidth()-this.tip.outerWidth()/2;c+=this.bearer.outerHeight()/2-this.tooltip.outerHeight()/2;break}this.tooltip.css("left",d);this.tooltip.css("top",c)},setEvents:function(){var c=this;if(c.mouseOverMode){this.bearer.mouseover(function(){c.setPositions();c.show()}).mouseout(function(){c.hide()})}else{if(this.options.trigger=="click"||this.options.trigger=="onclik"){this.tooltip.click(function(d){d.stopPropagation()});this.bearer.click(function(d){d.preventDefault();c.setPositions();c.toggle();d.stopPropagation()});b("html").click(function(){c.hide()})}}},activate:function(){this.setContent();if(this.content){this.setEvents()}},addConfirm:function(){this.tooltip.append("<ul class = 'confirm'><li class = 'darktooltip-yes'>"+this.options.yes+"</li><li class = 'darktooltip-no'>"+this.options.no+"</li></ul>");this.setConfirmEvents()},setConfirmEvents:function(){var c=this;this.tooltip.find("li.darktooltip-yes").click(function(d){c.onYes();d.stopPropagation()});this.tooltip.find("li.darktooltip-no").click(function(d){c.onNo();d.stopPropagation()})},finalMessage:function(){if(this.options.finalMessage){var c=this;c.tooltip.find("div:first").html(this.options.finalMessage);c.tooltip.find("ul").remove();c.setPositions();setTimeout(function(){c.hide();c.setContent()},c.options.finalMessageDuration)}else{this.hide()}},onYes:function(){this.options.onYes(this.bearer);this.finalMessage()},onNo:function(){this.options.onNo(this.bearer);this.hide()}};b.fn.darkTooltip=function(c){this.each(function(){c=b.extend({},b.fn.darkTooltip.defaults,c);var d=new a(b(this),c);d.activate()})};b.fn.darkTooltip.defaults={opacity:0.9,content:"",size:"medium",gravity:"south",theme:"dark",trigger:"hover",animation:"none",confirm:false,yes:"Yes",no:"No",finalMessage:"",finalMessageDuration:1000,onYes:function(){},onNo:function(){}}})(jQuery);
1
+ (function(b){function a(d,c){this.bearer=d;this.options=c;this.hideEvent;this.mouseOverMode=(this.options.trigger=="hover"||this.options.trigger=="mouseover"||this.options.trigger=="onmouseover")}a.prototype={show:function(){var c=this;this.tooltip.css("display","block");if(c.mouseOverMode){this.tooltip.mouseover(function(){clearTimeout(c.hideEvent)});this.tooltip.mouseout(function(){clearTimeout(c.hideEvent);c.hide()})}},hide:function(){var c=this;this.hideEvent=setTimeout(function(){c.tooltip.hide()},100)},toggle:function(){if(this.tooltip.is(":visible")){this.hide()}else{this.show()}},addAnimation:function(){switch(this.options.animation){case"none":break;case"fadeIn":this.tooltip.addClass("animated");this.tooltip.addClass("fadeIn");break;case"flipIn":this.tooltip.addClass("animated");this.tooltip.addClass("flipIn");break}},setContent:function(){b(this.bearer).css("cursor","pointer");if(this.options.content){this.content=this.options.content}else{if(this.bearer.attr("data-tooltip")){this.content=this.bearer.attr("data-tooltip")}else{return}}if(this.content.charAt(0)=="#"){b(this.content).hide();this.content=b(this.content).html();this.contentType="html"}else{this.contentType="text"}this.tooltip=b("<ins class = 'dark-tooltip "+this.options.theme+" "+this.options.size+" "+this.options.gravity+"'><div>"+this.content+"</div><div class = 'tip'></div></ins>");this.tip=this.tooltip.find(".tip");b("body").append(this.tooltip);if(this.contentType=="html"){this.tooltip.css("max-width","none")}this.tooltip.css("opacity",this.options.opacity);this.addAnimation();if(this.options.confirm){this.addConfirm()}},setPositions:function(){var d=this.bearer.offset().left;var c=this.bearer.offset().top;switch(this.options.gravity){case"south":d+=this.bearer.outerWidth()/2-this.tooltip.outerWidth()/2;c+=-this.tooltip.outerHeight()-this.tip.outerHeight()/2;break;case"west":d+=this.bearer.outerWidth()+this.tip.outerWidth()/2;c+=this.bearer.outerHeight()/2-(this.tooltip.outerHeight()/2);break;case"north":d+=this.bearer.outerWidth()/2-(this.tooltip.outerWidth()/2);c+=this.bearer.outerHeight()+this.tip.outerHeight()/2;break;case"east":d+=-this.tooltip.outerWidth()-this.tip.outerWidth()/2;c+=this.bearer.outerHeight()/2-this.tooltip.outerHeight()/2;break}this.tooltip.css("left",d);this.tooltip.css("top",c)},setEvents:function(){var c=this;if(c.mouseOverMode){this.bearer.mouseover(function(){c.setPositions();c.show()}).mouseout(function(){c.hide()})}else{if(this.options.trigger=="click"||this.options.trigger=="onclik"){this.tooltip.click(function(d){d.stopPropagation()});this.bearer.click(function(d){d.preventDefault();c.setPositions();c.toggle();d.stopPropagation()});b("html").click(function(){c.hide()})}}},activate:function(){this.setContent();if(this.content){this.setEvents()}},addConfirm:function(){this.tooltip.append("<ul class = 'confirm'><li class = 'darktooltip-yes'>"+this.options.yes+"</li><li class = 'darktooltip-no'>"+this.options.no+"</li></ul>");this.setConfirmEvents()},setConfirmEvents:function(){var c=this;this.tooltip.find("li.darktooltip-yes").click(function(d){c.onYes();d.stopPropagation()});this.tooltip.find("li.darktooltip-no").click(function(d){c.onNo();d.stopPropagation()})},finalMessage:function(){if(this.options.finalMessage){var c=this;c.tooltip.find("div:first").html(this.options.finalMessage);c.tooltip.find("ul").remove();c.setPositions();setTimeout(function(){c.hide();c.setContent()},c.options.finalMessageDuration)}else{this.hide()}},onYes:function(){this.options.onYes(this.bearer);this.finalMessage()},onNo:function(){this.options.onNo(this.bearer);this.hide()}};b.fn.darkTooltip=function(c){this.each(function(){c=b.extend({},b.fn.darkTooltip.defaults,c);var d=new a(b(this),c);d.activate()})};b.fn.darkTooltip.defaults={opacity:1,content:"",size:"medium",gravity:"south",theme:"dark",trigger:"hover",animation:"none",confirm:false,yes:"Yes",no:"No",finalMessage:"",finalMessageDuration:1000,onYes:function(){},onNo:function(){}}})(jQuery);
ultimate-responsive-image-slider-settings-meta-box.php CHANGED
@@ -6,16 +6,140 @@ $PostId = $post->ID;
6
  $WRIS_Gallery_Settings_Key = "WRIS_Gallery_Settings_".$PostId;
7
  $WRIS_Gallery_Settings = unserialize(get_post_meta( $PostId, $WRIS_Gallery_Settings_Key, true));
8
  if($WRIS_Gallery_Settings['WRIS_L3_Slider_Width'] && $WRIS_Gallery_Settings['WRIS_L3_Slider_Height']) {
9
- $WRIS_L3_Slide_Title = $WRIS_Gallery_Settings['WRIS_L3_Slide_Title'];
10
- $WRIS_L3_Auto_Slideshow = $WRIS_Gallery_Settings['WRIS_L3_Auto_Slideshow'];
11
- $WRIS_L3_Transition = $WRIS_Gallery_Settings['WRIS_L3_Transition'];
12
- $WRIS_L3_Transition_Speed = $WRIS_Gallery_Settings['WRIS_L3_Transition_Speed'];
13
- $WRIS_L3_Sliding_Arrow = $WRIS_Gallery_Settings['WRIS_L3_Sliding_Arrow'];
14
- $WRIS_L3_Slider_Navigation = $WRIS_Gallery_Settings['WRIS_L3_Slider_Navigation'];
15
- $WRIS_L3_Navigation_Button = $WRIS_Gallery_Settings['WRIS_L3_Navigation_Button'];
16
- $WRIS_L3_Slider_Width = $WRIS_Gallery_Settings['WRIS_L3_Slider_Width'];
17
- $WRIS_L3_Slider_Height = $WRIS_Gallery_Settings['WRIS_L3_Slider_Height'];
18
- $WRIS_L3_Custom_CSS = $WRIS_Gallery_Settings['WRIS_L3_Custom_CSS'];
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
19
  }
20
  ?>
21
  <style>
@@ -33,129 +157,349 @@ if($WRIS_Gallery_Settings['WRIS_L3_Slider_Width'] && $WRIS_Gallery_Settings['WRI
33
  <table class="form-table">
34
  <tbody>
35
  <tr id="L3">
36
- <th scope="row" colspan="2"><h2>Configure Settings For Slider Shortcode: <?php echo "[URIS id=$PostId]"; ?></h2><hr></th>
37
  </tr>
38
 
39
  <tr id="L3">
40
- <th scope="row"><label>Display Slider Title</label></th>
41
  <td>
42
  <?php if(!isset($WRIS_L3_Slide_Title)) $WRIS_L3_Slide_Title = 1; ?>
43
- <input type="radio" name="wl-l3-slide-title" id="wl-l3-slide-title" value="1" <?php if($WRIS_L3_Slide_Title == 1 ) { echo "checked"; } ?>> <i class="fa fa-check fa-2x"></i>
44
  <input type="radio" name="wl-l3-slide-title" id="wl-l3-slide-title" value="0" <?php if($WRIS_L3_Slide_Title == 0 ) { echo "checked"; } ?>> <i class="fa fa-times fa-2x"></i>
45
  <p class="description">
46
- Select Yes/No option to show/hide slide title above slider.
47
  </p>
48
  </td>
49
  </tr>
50
 
51
  <tr id="L3">
52
- <th scope="row"><label>Auto Play Slide Show</label></th>
53
  <td>
54
  <?php if(!isset($WRIS_L3_Auto_Slideshow)) $WRIS_L3_Auto_Slideshow = 1; ?>
55
- <input type="radio" name="wl-l3-auto-slide" id="wl-l3-auto-slide" value="1" <?php if($WRIS_L3_Auto_Slideshow == 1 ) { echo "checked"; } ?>> <i class="fa fa-check fa-2x"></i>
56
- <input type="radio" name="wl-l3-auto-slide" id="wl-l3-auto-slide" value="0" <?php if($WRIS_L3_Auto_Slideshow == 0 ) { echo "checked"; } ?>> <i class="fa fa-times fa-2x"></i>
 
57
  <p class="description">
58
- Select Yes/No option to auto slide enable or disable into slider.
59
  </p>
60
  </td>
61
  </tr>
62
  <tr id="L3">
63
- <th scope="row"><label>Slide Transition</label></th>
64
  <td>
65
  <?php if(!isset($WRIS_L3_Transition)) $WRIS_L3_Transition = 1; ?>
66
- <input type="radio" name="wl-l3-transition" id="wl-l3-transition" value="1" <?php if($WRIS_L3_Transition == 1 ) { echo "checked"; } ?>> Fade
67
  <input type="radio" name="wl-l3-transition" id="wl-l3-transition" value="0" <?php if($WRIS_L3_Transition == 0 ) { echo "checked"; } ?>> Slide
68
  <p class="description">
69
- Select a transition effect you want to apply on slides.
70
  </p>
71
  </td>
72
  </tr>
73
 
74
  <tr id="L3">
75
- <th scope="row"><label>Slide Transition Speed</label></th>
76
  <td>
77
  <?php if(!isset($WRIS_L3_Transition_Speed)) $WRIS_L3_Transition_Speed = 5000; ?>
78
  <input type="text" name="wl-l3-transition-speed" id="wl-l3-transition-speed" value="<?php echo $WRIS_L3_Transition_Speed; ?>">
79
  <p class="description">
80
- Set your desired transition speed of slides. Default width is 5000px.
81
  </p>
82
  </td>
83
  </tr>
84
 
85
  <tr id="L3">
86
- <th scope="row"><label>Sliding Arrow</label></th>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
87
  <td>
88
  <?php if(!isset($WRIS_L3_Sliding_Arrow)) $WRIS_L3_Sliding_Arrow = 1; ?>
89
- <input type="radio" name="wl-l3-sliding-arrow" id="wl-l3-sliding-arrow" value="1" <?php if($WRIS_L3_Sliding_Arrow == 1 ) { echo "checked"; } ?>> <i class="fa fa-check fa-2x"></i>
90
  <input type="radio" name="wl-l3-sliding-arrow" id="wl-l3-sliding-arrow" value="0" <?php if($WRIS_L3_Sliding_Arrow == 0 ) { echo "checked"; } ?>> <i class="fa fa-times fa-2x"></i>
91
  <p class="description">
92
- Select Yes/No option to show or hide arrows on mouse hover on slide.
93
- <a href="#" id="p1" data-tooltip="#s1">Preview</a>
94
  </p>
95
  </td>
96
  </tr>
97
 
98
  <tr id="L3">
99
- <th scope="row"><label>Show Thumbnail</label></th>
100
  <td>
101
  <?php if(!isset($WRIS_L3_Slider_Navigation)) $WRIS_L3_Slider_Navigation = 1; ?>
102
- <input type="radio" name="wl-l3-navigation" id="wl-l3-navigation" value="1" <?php if($WRIS_L3_Slider_Navigation == 1 ) { echo "checked"; } ?>> <i class="fa fa-check fa-2x"></i>
103
  <input type="radio" name="wl-l3-navigation" id="wl-l3-navigation" value="0" <?php if($WRIS_L3_Slider_Navigation == 0 ) { echo "checked"; } ?>> <i class="fa fa-times fa-2x"></i>
104
  <p class="description">
105
- Select Yes/No option to show or hide thumbnail based navigation under slides.
106
- <a href="#" id="p2" data-tooltip="#s2">Preview</a>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
107
  </p>
108
  </td>
109
  </tr>
110
 
111
  <tr id="L3">
112
- <th scope="row"><label>Show Navigation Bullets</label></th>
113
  <td>
114
  <?php if(!isset($WRIS_L3_Navigation_Button)) $WRIS_L3_Navigation_Button = 1; ?>
115
- <input type="radio" name="wl-l3-navigation-button" id="wl-l3-navigation-button" value="1" <?php if($WRIS_L3_Navigation_Button == 1 ) { echo "checked"; } ?>> <i class="fa fa-check fa-2x"></i>
116
  <input type="radio" name="wl-l3-navigation-button" id="wl-l3-navigation-button" value="0" <?php if($WRIS_L3_Navigation_Button == 0 ) { echo "checked"; } ?>> <i class="fa fa-times fa-2x"></i>
117
  <p class="description">
118
- Select Yes/No option to show or hide slider navigation buttons under image slider.
119
- <a href="#" id="p3" data-tooltip="#s3">Preview</a>
120
  </p>
121
  </td>
122
  </tr>
123
 
124
  <tr id="L3">
125
- <th scope="row"><label>Slider Width</label></th>
126
  <td>
127
  <?php if(!isset($WRIS_L3_Slider_Width)) $WRIS_L3_Slider_Width = 1000; ?>
 
 
 
 
128
  <input type="text" name="wl-l3-slider-width" id="wl-l3-slider-width" value="<?php echo $WRIS_L3_Slider_Width; ?>">
129
  <p class="description">
130
- Enter your desired width for slider. Default width is 1000px.
131
- <a href="#" id="p4" data-tooltip="#s4">Preview</a>
132
  </p>
133
  </td>
134
  </tr>
135
 
136
  <tr id="L3">
137
- <th scope="row"><label>Slider Height</label></th>
138
  <td>
139
  <?php if(!isset($WRIS_L3_Slider_Height)) $WRIS_L3_Slider_Height = 500; ?>
 
 
 
140
  <input type="text" name="wl-l3-slider-height" id="wl-l3-slider-height" value="<?php echo $WRIS_L3_Slider_Height; ?>">
141
  <p class="description">
142
- Enter your desired height for slider. Default height is 500px.
143
- <a href="#" id="p5" data-tooltip="#s5">Preview</a>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
144
  </p>
145
  </td>
146
  </tr>
147
 
148
  <tr id="L3">
149
- <th scope="row"><label>Custom CSS</label></th>
150
  <td>
151
  <?php if(!isset($WRIS_L3_Custom_CSS)) $WRIS_L3_Custom_CSS = ""; ?>
152
  <textarea name="wl-l3-custom-css" id="wl-l3-custom-css" rows="5" cols="75"><?php echo $WRIS_L3_Custom_CSS; ?></textarea>
153
  <p class="description">
154
- Enter any custom css you want to apply on this slider into textarea filed.<br>
155
- <strong>Note:</strong> Please Do Not Use <strong>&lt;style&gt;...&lt;/style&gt;</strong> Tag With Custom CSS.
156
  </p>
157
  </td>
158
  </tr>
159
-
160
  </tbody>
161
  </table>
6
  $WRIS_Gallery_Settings_Key = "WRIS_Gallery_Settings_".$PostId;
7
  $WRIS_Gallery_Settings = unserialize(get_post_meta( $PostId, $WRIS_Gallery_Settings_Key, true));
8
  if($WRIS_Gallery_Settings['WRIS_L3_Slider_Width'] && $WRIS_Gallery_Settings['WRIS_L3_Slider_Height']) {
9
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Slide_Title']))
10
+ $WRIS_L3_Slide_Title = $WRIS_Gallery_Settings['WRIS_L3_Slide_Title'];
11
+ else
12
+ $WRIS_L3_Slide_Title = 1;
13
+
14
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Auto_Slideshow']))
15
+ $WRIS_L3_Auto_Slideshow = $WRIS_Gallery_Settings['WRIS_L3_Auto_Slideshow'];
16
+ else
17
+ $WRIS_L3_Auto_Slideshow = 1;
18
+
19
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Transition']))
20
+ $WRIS_L3_Transition = $WRIS_Gallery_Settings['WRIS_L3_Transition'];
21
+ else
22
+ $WRIS_L3_Transition = 1;
23
+
24
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Transition_Speed']))
25
+ $WRIS_L3_Transition_Speed = $WRIS_Gallery_Settings['WRIS_L3_Transition_Speed'];
26
+ else
27
+ $WRIS_L3_Transition_Speed = 5000;
28
+
29
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Slide_Order']))
30
+ $WRIS_L3_Slide_Order = $WRIS_Gallery_Settings['WRIS_L3_Slide_Order'];
31
+ else
32
+ $WRIS_L3_Slide_Order = "ASC";
33
+
34
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Slide_Distance']))
35
+ $WRIS_L3_Slide_Distance = $WRIS_Gallery_Settings['WRIS_L3_Slide_Distance'];
36
+ else
37
+ $WRIS_L3_Slide_Distance = 5;
38
+
39
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Sliding_Arrow']))
40
+ $WRIS_L3_Sliding_Arrow = $WRIS_Gallery_Settings['WRIS_L3_Sliding_Arrow'];
41
+ else
42
+ $WRIS_L3_Sliding_Arrow = 1;
43
+
44
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Slider_Navigation']))
45
+ $WRIS_L3_Slider_Navigation = $WRIS_Gallery_Settings['WRIS_L3_Slider_Navigation'];
46
+ else
47
+ $WRIS_L3_Slider_Navigation = 1;
48
+
49
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Navigation_Position']))
50
+ $WRIS_L3_Navigation_Position = $WRIS_Gallery_Settings['WRIS_L3_Navigation_Position'];
51
+ else
52
+ $WRIS_L3_Navigation_Position = "bottom";
53
+
54
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Thumbnail_Style']))
55
+ $WRIS_L3_Thumbnail_Style = $WRIS_Gallery_Settings['WRIS_L3_Thumbnail_Style'];
56
+ else
57
+ $WRIS_L3_Thumbnail_Style = "border";
58
+
59
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Thumbnail_Width']))
60
+ $WRIS_L3_Thumbnail_Width = $WRIS_Gallery_Settings['WRIS_L3_Thumbnail_Width'];
61
+ else
62
+ $WRIS_L3_Thumbnail_Width = 120;
63
+
64
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Thumbnail_Height']))
65
+ $WRIS_L3_Thumbnail_Height = $WRIS_Gallery_Settings['WRIS_L3_Thumbnail_Height'];
66
+ else
67
+ $WRIS_L3_Thumbnail_Height = 100;
68
+
69
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Navigation_Button']))
70
+ $WRIS_L3_Navigation_Button = $WRIS_Gallery_Settings['WRIS_L3_Navigation_Button'];
71
+ else
72
+ $WRIS_L3_Navigation_Button = 1;
73
+
74
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Width']))
75
+ $WRIS_L3_Width = $WRIS_Gallery_Settings['WRIS_L3_Width'];
76
+ else
77
+ $WRIS_L3_Width = "custom";
78
+
79
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Slider_Width']))
80
+ $WRIS_L3_Slider_Width = $WRIS_Gallery_Settings['WRIS_L3_Slider_Width'];
81
+ else
82
+ $WRIS_L3_Slider_Width = 1000;
83
+
84
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Height']))
85
+ $WRIS_L3_Height = $WRIS_Gallery_Settings['WRIS_L3_Height'];
86
+ else
87
+ $WRIS_L3_Height = "custom";
88
+
89
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Slider_Height']))
90
+ $WRIS_L3_Slider_Height = $WRIS_Gallery_Settings['WRIS_L3_Slider_Height'];
91
+ else
92
+ $WRIS_L3_Slider_Height = 500;
93
+
94
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Font_Style']))
95
+ $WRIS_L3_Font_Style = $WRIS_Gallery_Settings['WRIS_L3_Font_Style'];
96
+ else
97
+ $WRIS_L3_Font_Style = "Arial";
98
+
99
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Title_Color']))
100
+ $WRIS_L3_Title_Color = $WRIS_Gallery_Settings['WRIS_L3_Title_Color'];
101
+ else
102
+ $WRIS_L3_Title_Color = "#00000";
103
+
104
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Title_BgColor']))
105
+ $WRIS_L3_Title_BgColor = $WRIS_Gallery_Settings['WRIS_L3_Title_BgColor'];
106
+ else
107
+ $WRIS_L3_Title_BgColor = "#FFFFFF";
108
+
109
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Desc_Color']))
110
+ $WRIS_L3_Desc_Color = $WRIS_Gallery_Settings['WRIS_L3_Desc_Color'];
111
+ else
112
+ $WRIS_L3_Desc_Color = "#FFFFFF";
113
+
114
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Desc_BgColor']))
115
+ $WRIS_L3_Desc_BgColor = $WRIS_Gallery_Settings['WRIS_L3_Desc_BgColor'];
116
+ else
117
+ $WRIS_L3_Desc_BgColor = "#00000";
118
+
119
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Navigation_Color']))
120
+ $WRIS_L3_Navigation_Color = $WRIS_Gallery_Settings['WRIS_L3_Navigation_Color'];
121
+ else
122
+ $WRIS_L3_Navigation_Color = "#FFFFFF";
123
+
124
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Fullscreeen']))
125
+ $WRIS_L3_Fullscreeen = $WRIS_Gallery_Settings['WRIS_L3_Fullscreeen'];
126
+ else
127
+ $WRIS_L3_Fullscreeen = 1;
128
+
129
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Custom_CSS']))
130
+ $WRIS_L3_Custom_CSS = $WRIS_Gallery_Settings['WRIS_L3_Custom_CSS'];
131
+ else
132
+ $WRIS_L3_Custom_CSS = "";
133
+
134
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Navigation_Bullets_Color']))
135
+ $WRIS_L3_Navigation_Bullets_Color = $WRIS_Gallery_Settings['WRIS_L3_Navigation_Bullets_Color'];
136
+ else
137
+ $WRIS_L3_Navigation_Bullets_Color = "#000000";
138
+
139
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Navigation_Pointer_Color']))
140
+ $WRIS_L3_Navigation_Pointer_Color = $WRIS_Gallery_Settings['WRIS_L3_Navigation_Pointer_Color'];
141
+ else
142
+ $WRIS_L3_Navigation_Pointer_Color = "#000000";
143
  }
144
  ?>
145
  <style>
157
  <table class="form-table">
158
  <tbody>
159
  <tr id="L3">
160
+ <th scope="row" colspan="2"><h2><?php _e('Configure Settings For Slider Shortcode', WRIS_TEXT_DOMAIN); ?>: <?php echo "[URIS id=$PostId]"; ?></h2><hr></th>
161
  </tr>
162
 
163
  <tr id="L3">
164
+ <th scope="row"><label><?php _e('Display Slider Title', WRIS_TEXT_DOMAIN); ?></label></th>
165
  <td>
166
  <?php if(!isset($WRIS_L3_Slide_Title)) $WRIS_L3_Slide_Title = 1; ?>
167
+ <input type="radio" name="wl-l3-slide-title" id="wl-l3-slide-title" value="1" <?php if($WRIS_L3_Slide_Title == 1 ) { echo "checked"; } ?>> <i class="fa fa-check fa-2x"></i> &nbsp;&nbsp;
168
  <input type="radio" name="wl-l3-slide-title" id="wl-l3-slide-title" value="0" <?php if($WRIS_L3_Slide_Title == 0 ) { echo "checked"; } ?>> <i class="fa fa-times fa-2x"></i>
169
  <p class="description">
170
+ <?php _e('Select Yes/No option to show/hide slide title above slider', WRIS_TEXT_DOMAIN); ?>.
171
  </p>
172
  </td>
173
  </tr>
174
 
175
  <tr id="L3">
176
+ <th scope="row"><label><?php _e('Auto Play Slide Show', WRIS_TEXT_DOMAIN); ?></label></th>
177
  <td>
178
  <?php if(!isset($WRIS_L3_Auto_Slideshow)) $WRIS_L3_Auto_Slideshow = 1; ?>
179
+ <input type="radio" name="wl-l3-auto-slide" id="wl-l3-auto-slide" value="1" <?php if($WRIS_L3_Auto_Slideshow == 1 ) { echo "checked"; } ?>> <?php _e('Yes', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
180
+ <input type="radio" name="wl-l3-auto-slide" id="wl-l3-auto-slide" value="2" <?php if($WRIS_L3_Auto_Slideshow == 2 ) { echo "checked"; } ?>> <?php _e('Yes with Stop on Mouse Hover', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
181
+ <input type="radio" name="wl-l3-auto-slide" id="wl-l3-auto-slide" value="3" <?php if($WRIS_L3_Auto_Slideshow == 3 ) { echo "checked"; } ?>> <?php _e('No', WRIS_TEXT_DOMAIN); ?>
182
  <p class="description">
183
+ <?php _e('Select Yes/No option to auto slide enable or disable into slider', WRIS_TEXT_DOMAIN); ?>.
184
  </p>
185
  </td>
186
  </tr>
187
  <tr id="L3">
188
+ <th scope="row"><label><?php _e('Slide Transition', WRIS_TEXT_DOMAIN); ?></label></th>
189
  <td>
190
  <?php if(!isset($WRIS_L3_Transition)) $WRIS_L3_Transition = 1; ?>
191
+ <input type="radio" name="wl-l3-transition" id="wl-l3-transition" value="1" <?php if($WRIS_L3_Transition == 1 ) { echo "checked"; } ?>> Fade &nbsp;&nbsp;
192
  <input type="radio" name="wl-l3-transition" id="wl-l3-transition" value="0" <?php if($WRIS_L3_Transition == 0 ) { echo "checked"; } ?>> Slide
193
  <p class="description">
194
+ <?php _e('Select a transition effect you want to apply on slides', WRIS_TEXT_DOMAIN); ?>.
195
  </p>
196
  </td>
197
  </tr>
198
 
199
  <tr id="L3">
200
+ <th scope="row"><label><?php _e('Autoplay Transition Speed', WRIS_TEXT_DOMAIN); ?></label></th>
201
  <td>
202
  <?php if(!isset($WRIS_L3_Transition_Speed)) $WRIS_L3_Transition_Speed = 5000; ?>
203
  <input type="text" name="wl-l3-transition-speed" id="wl-l3-transition-speed" value="<?php echo $WRIS_L3_Transition_Speed; ?>">
204
  <p class="description">
205
+ <?php _e('Set your desired transition speed of slides. Default width is 5000px', WRIS_TEXT_DOMAIN); ?>.
206
  </p>
207
  </td>
208
  </tr>
209
 
210
  <tr id="L3">
211
+ <th scope="row"><label><?php _e('Slide Order', WRIS_TEXT_DOMAIN); ?></label></th>
212
+ <td>
213
+ <?php if(!isset($WRIS_L3_Slide_Order)) $WRIS_L3_Slide_Order = "ASC"; ?>
214
+ <input type="radio" name="wl-l3-slide-order" id="wl-l3-slide-order" value="ASC" <?php if($WRIS_L3_Slide_Order == "ASC" ) { echo "checked"; } ?>> <?php _e('Ascending', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
215
+ <input type="radio" name="wl-l3-slide-order" id="wl-l3-slide-order" value="DESC" <?php if($WRIS_L3_Slide_Order == "DESC" ) { echo "checked"; } ?>> <?php _e('Descending', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
216
+ <input type="radio" name="wl-l3-slide-order" id="wl-l3-slide-order" value="shuffle" <?php if($WRIS_L3_Slide_Order == "shuffle" ) { echo "checked"; } ?>> <?php _e('Random', WRIS_TEXT_DOMAIN); ?>
217
+ <p class="description">
218
+ <?php _e('Select a slide order you want to apply on slides', WRIS_TEXT_DOMAIN); ?>.
219
+ </p>
220
+ </td>
221
+ </tr>
222
+
223
+ <tr id="L3">
224
+ <th scope="row"><label><?php _e('Slide Distance', WRIS_TEXT_DOMAIN); ?></label></th>
225
+ <td>
226
+ <?php if(!isset($WRIS_L3_Slide_Distance)) $WRIS_L3_Slide_Distance = 5; ?>
227
+ <select name="wl-l3-slide-distance" id="wl-l3-slide-distance">
228
+ <option value="0" <?php if($WRIS_L3_Slide_Distance == 0) echo "selected=selected";?>>0</option>
229
+ <option value="5" <?php if($WRIS_L3_Slide_Distance == 5) echo "selected=selected";?>>5</option>
230
+ <option value="10" <?php if($WRIS_L3_Slide_Distance == 10) echo "selected=selected";?>>10</option>
231
+ <option value="15" <?php if($WRIS_L3_Slide_Distance == 15) echo "selected=selected";?>>15</option>
232
+ <option value="20" <?php if($WRIS_L3_Slide_Distance == 20) echo "selected=selected";?>>20</option>
233
+ <option value="25" <?php if($WRIS_L3_Slide_Distance == 25) echo "selected=selected";?>>25</option>
234
+ </select>
235
+ <p class="description">
236
+ <?php _e('Set a gap between all slides. Range 0 to 25', WRIS_TEXT_DOMAIN); ?>&nbsp;
237
+ <a href="#" id="p6" data-tooltip="#s6"><?php _e('Preview', WRIS_TEXT_DOMAIN); ?></a>
238
+ </p>
239
+ </td>
240
+ </tr>
241
+
242
+ <tr id="L3">
243
+ <th scope="row"><label><?php _e('Sliding Arrow', WRIS_TEXT_DOMAIN); ?></label></th>
244
  <td>
245
  <?php if(!isset($WRIS_L3_Sliding_Arrow)) $WRIS_L3_Sliding_Arrow = 1; ?>
246
+ <input type="radio" name="wl-l3-sliding-arrow" id="wl-l3-sliding-arrow" value="1" <?php if($WRIS_L3_Sliding_Arrow == 1 ) { echo "checked"; } ?>> <i class="fa fa-check fa-2x"></i> &nbsp;&nbsp;
247
  <input type="radio" name="wl-l3-sliding-arrow" id="wl-l3-sliding-arrow" value="0" <?php if($WRIS_L3_Sliding_Arrow == 0 ) { echo "checked"; } ?>> <i class="fa fa-times fa-2x"></i>
248
  <p class="description">
249
+ <?php _e('Select Yes/No option to show or hide arrows on mouse hover on slide', WRIS_TEXT_DOMAIN); ?>.
250
+ <a href="#" id="p1" data-tooltip="#s1"><?php _e('Preview', WRIS_TEXT_DOMAIN); ?></a>
251
  </p>
252
  </td>
253
  </tr>
254
 
255
  <tr id="L3">
256
+ <th scope="row"><label><?php _e('Show Thumbnail', WRIS_TEXT_DOMAIN); ?></label></th>
257
  <td>
258
  <?php if(!isset($WRIS_L3_Slider_Navigation)) $WRIS_L3_Slider_Navigation = 1; ?>
259
+ <input type="radio" name="wl-l3-navigation" id="wl-l3-navigation" value="1" <?php if($WRIS_L3_Slider_Navigation == 1 ) { echo "checked"; } ?>> <i class="fa fa-check fa-2x"></i> &nbsp;&nbsp;
260
  <input type="radio" name="wl-l3-navigation" id="wl-l3-navigation" value="0" <?php if($WRIS_L3_Slider_Navigation == 0 ) { echo "checked"; } ?>> <i class="fa fa-times fa-2x"></i>
261
  <p class="description">
262
+ <?php _e('Select Yes/No option to show or hide thumbnail based navigation under slides', WRIS_TEXT_DOMAIN); ?>.
263
+ <a href="#" id="p2" data-tooltip="#s2"><?php _e('Preview', WRIS_TEXT_DOMAIN); ?></a>
264
+ </p>
265
+ </td>
266
+ </tr>
267
+
268
+ <tr id="L3">
269
+ <th scope="row"><label><?php _e('Thumbnail Position', WRIS_TEXT_DOMAIN); ?></label></th>
270
+ <td>
271
+ <?php if(!isset($WRIS_L3_Navigation_Position)) $WRIS_L3_Navigation_Position = "bottom"; ?>
272
+ <input type="radio" name="wl-l3-navigation-position" id="wl-l3-navigation-position" value="top" <?php if($WRIS_L3_Navigation_Position == "top" ) { echo "checked"; } ?>> <?php _e('Top', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
273
+ <input type="radio" name="wl-l3-navigation-position" id="wl-l3-navigation-position" value="bottom" <?php if($WRIS_L3_Navigation_Position == "bottom" ) { echo "checked"; } ?>> <?php _e('Bottom', WRIS_TEXT_DOMAIN); ?>
274
+ <p class="description">
275
+ <?php _e('Select a thumbnail position to show above or below the slider', WRIS_TEXT_DOMAIN); ?>.
276
+ </p>
277
+ </td>
278
+ </tr>
279
+
280
+ <tr id="L3">
281
+ <th scope="row"><label><?php _e('Thumbnail Style', WRIS_TEXT_DOMAIN); ?></label></th>
282
+ <td>
283
+ <?php if(!isset($WRIS_L3_Thumbnail_Style)) $WRIS_L3_Thumbnail_Style = "border"; ?>
284
+ <input type="radio" name="wl-l3-thumbnail-style" id="wl-l3-thumbnail-style" value="border" <?php if($WRIS_L3_Thumbnail_Style == "border" ) { echo "checked"; } ?>> <?php _e('Border', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
285
+ <input type="radio" name="wl-l3-thumbnail-style" id="wl-l3-thumbnail-style" value="pointer" <?php if($WRIS_L3_Thumbnail_Style == "pointer" ) { echo "checked"; } ?>> <?php _e('Pointer', WRIS_TEXT_DOMAIN); ?>
286
+ <p class="description">
287
+ <?php _e('Select a thumbnail style to apply on thumbnails', WRIS_TEXT_DOMAIN); ?>.
288
+ </p>
289
+ </td>
290
+ </tr>
291
+
292
+ <tr id="L3">
293
+ <th scope="row"><label><?php _e('Thumbnail Resize', WRIS_TEXT_DOMAIN); ?></label></th>
294
+ <td>
295
+ <?php if(!isset($WRIS_L3_Thumbnail_Width)) $WRIS_L3_Thumbnail_Width = "100"; ?>
296
+ <?php if(!isset($WRIS_L3_Thumbnail_Height)) $WRIS_L3_Thumbnail_Height = "120"; ?>
297
+ <?php _e('Width', WRIS_TEXT_DOMAIN); ?> <input type="text" name="wl-l3-navigation-width" id="wl-l3-navigation-width" value="<?php echo $WRIS_L3_Thumbnail_Width; ?>"> &nbsp;&nbsp;
298
+ <?php _e('Height', WRIS_TEXT_DOMAIN); ?> <input type="text" name="wl-l3-navigation-height" id="wl-l3-navigation-height" value="<?php echo $WRIS_L3_Thumbnail_Height; ?>">
299
+ <p class="description">
300
+ <?php _e('Set custom thumbnail height & width according to you', WRIS_TEXT_DOMAIN); ?>.
301
  </p>
302
  </td>
303
  </tr>
304
 
305
  <tr id="L3">
306
+ <th scope="row"><label><?php _e('Show Navigation Bullets', WRIS_TEXT_DOMAIN); ?></label></th>
307
  <td>
308
  <?php if(!isset($WRIS_L3_Navigation_Button)) $WRIS_L3_Navigation_Button = 1; ?>
309
+ <input type="radio" name="wl-l3-navigation-button" id="wl-l3-navigation-button" value="1" <?php if($WRIS_L3_Navigation_Button == 1 ) { echo "checked"; } ?>> <i class="fa fa-check fa-2x"></i> &nbsp;&nbsp;
310
  <input type="radio" name="wl-l3-navigation-button" id="wl-l3-navigation-button" value="0" <?php if($WRIS_L3_Navigation_Button == 0 ) { echo "checked"; } ?>> <i class="fa fa-times fa-2x"></i>
311
  <p class="description">
312
+ <?php _e('Select Yes/No option to show or hide slider navigation buttons under image slider', WRIS_TEXT_DOMAIN); ?>.
313
+ <a href="#" id="p3" data-tooltip="#s3"><?php _e('Preview', WRIS_TEXT_DOMAIN); ?></a>
314
  </p>
315
  </td>
316
  </tr>
317
 
318
  <tr id="L3">
319
+ <th scope="row"><label><?php _e('Slider Width', WRIS_TEXT_DOMAIN); ?></label></th>
320
  <td>
321
  <?php if(!isset($WRIS_L3_Slider_Width)) $WRIS_L3_Slider_Width = 1000; ?>
322
+ <?php if(!isset($WRIS_L3_Width)) $WRIS_L3_Width = "custom"; ?>
323
+ <input type="radio" name="wl-l3-width" id="wl-l3-width" value="100%" <?php if($WRIS_L3_Width == "100%" ) { echo "checked"; } ?>> <?php _e('100% Width', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
324
+ <input type="radio" name="wl-l3-width" id="wl-l3-width" value="fullWidth" <?php if($WRIS_L3_Width == "fullWidth" ) { echo "checked"; } ?>> <?php _e('Full Width', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
325
+ <input type="radio" name="wl-l3-width" id="wl-l3-width" value="custom" <?php if($WRIS_L3_Width == "custom" ) { echo "checked"; } ?>> <?php _e('Custom', WRIS_TEXT_DOMAIN); ?>
326
  <input type="text" name="wl-l3-slider-width" id="wl-l3-slider-width" value="<?php echo $WRIS_L3_Slider_Width; ?>">
327
  <p class="description">
328
+ <?php _e('Enter your desired width for slider. Default width is 1000px', WRIS_TEXT_DOMAIN); ?>.
329
+ <a href="#" id="p4" data-tooltip="#s4"><?php _e('Preview', WRIS_TEXT_DOMAIN); ?></a>
330
  </p>
331
  </td>
332
  </tr>
333
 
334
  <tr id="L3">
335
+ <th scope="row"><label><?php _e('Slider Height', WRIS_TEXT_DOMAIN); ?></label></th>
336
  <td>
337
  <?php if(!isset($WRIS_L3_Slider_Height)) $WRIS_L3_Slider_Height = 500; ?>
338
+ <?php if(!isset($WRIS_L3_Height)) $WRIS_L3_Height = "custom"; ?>
339
+ <input type="radio" name="wl-l3-height" id="wl-l3-height" value="auto" <?php if($WRIS_L3_Height == "auto" ) { echo "checked"; } ?>> <?php _e('Auto Height', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
340
+ <input type="radio" name="wl-l3-height" id="wl-l3-height" value="custom" <?php if($WRIS_L3_Height == "custom" ) { echo "checked"; } ?>> <?php _e('Custom', WRIS_TEXT_DOMAIN); ?>
341
  <input type="text" name="wl-l3-slider-height" id="wl-l3-slider-height" value="<?php echo $WRIS_L3_Slider_Height; ?>">
342
  <p class="description">
343
+ <?php _e('Enter your desired height for slider. Default height is 500px', WRIS_TEXT_DOMAIN); ?>.
344
+ <a href="#" id="p5" data-tooltip="#s5"><?php _e('Preview', WRIS_TEXT_DOMAIN); ?></a>
345
+ </p>
346
+ </td>
347
+ </tr>
348
+
349
+ <tr>
350
+ <th scope="row"><label><?php _e("Font Style", WRIS_TEXT_DOMAIN); ?></label></th>
351
+ <td>
352
+ <?php if(!isset($WRIS_L3_Font_Style)) $WRIS_L3_Font_Style = "Arial";?>
353
+ <select name="wl-l3-font-style" id="wl-l3-font-style" class="standard-dropdown" >
354
+ <optgroup label="Default Fonts">
355
+ <option value="Arial" <?php if($WRIS_L3_Font_Style == 'Arial' ) { echo "selected"; } ?>>Arial</option>
356
+ <option value="Arial Black" <?php if($WRIS_L3_Font_Style == 'Arial Black' ) { echo "selected"; } ?>>Arial Black</option>
357
+ <option value="Courier New" <?php if($WRIS_L3_Font_Style == 'Courier New' ) { echo "selected"; } ?>>Courier New</option>
358
+ <option value="Georgia" <?php if($WRIS_L3_Font_Style == 'Georgia' ) { echo "selected"; } ?>>Georgia</option>
359
+ <option value="Grande" <?php if($WRIS_L3_Font_Style == 'Grande' ) { echo "selected"; } ?>>Grande</option>
360
+ <option value="Helvetica" <?php if($WRIS_L3_Font_Style == 'Helvetica' ) { echo "selected"; } ?>>Helvetica Neue</option>
361
+ <option value="Impact" <?php if($WRIS_L3_Font_Style == 'Impact' ) { echo "selected"; } ?>>Impact</option>
362
+ <option value="Lucida" <?php if($WRIS_L3_Font_Style == 'Lucida' ) { echo "selected"; } ?>>Lucida</option>
363
+ <option value="Lucida Grande" <?php if($WRIS_L3_Font_Style == 'Lucida Grande' ) { echo "selected"; } ?>>Lucida Grande</option>
364
+ <option value="_OpenSansBold" <?php if($WRIS_L3_Font_Style == '_OpenSansBold' ) { echo "selected"; } ?>>OpenSansBold</option>
365
+ <option value="Palatino Linotype" <?php if($WRIS_L3_Font_Style == 'Palatino Linotype' ) { echo "selected"; } ?>>Palatino</option>
366
+ <option value="Sans" <?php if($WRIS_L3_Font_Style == 'Sans' ) { echo "selected"; } ?>>Sans</option>
367
+ <option value="sans-serif" <?php if($WRIS_L3_Font_Style == 'sans-serif' ) { echo "selected"; } ?>>Sans-Serif</option>
368
+ <option value="Tahoma" <?php if($WRIS_L3_Font_Style == 'Tahoma' ) { echo "selected"; } ?>>Tahoma</option>
369
+ <option value="Times New Roman" <?php if($WRIS_L3_Font_Style == 'Times New Roman' ) { echo "selected"; } ?>>Times New Roman</option>
370
+ <option value="Trebuchet" <?php if($WRIS_L3_Font_Style == 'Trebuchet' ) { echo "selected"; } ?>>Trebuchet</option>
371
+ <option value="Verdana" <?php if($WRIS_L3_Font_Style == 'Verdana' ) { echo "selected"; } ?>>Verdana</option>
372
+ </optgroup>
373
+ </select>
374
+ <p class="description"><?php _e("Choose a caption font style.", WRIS_TEXT_DOMAIN); ?> (Upgrade to pro for get 500+ Google fonts in plugin, check <a href="https://weblizar.com/plugins/ultimate-responsive-image-slider-pro/" target="_new">demo</a> )</p>
375
+ </td>
376
+ </tr>
377
+
378
+ <tr id="L3">
379
+ <th scope="row"><label><?php _e('Slide Title Color', WRIS_TEXT_DOMAIN); ?></label></th>
380
+ <td>
381
+ <?php if(!isset($WRIS_L3_Title_Color)) $WRIS_L3_Title_Color = "#000000"; ?>
382
+ <input type="radio" name="wl-l3-title-color" id="wl-l3-title-color" value="#F8504B" <?php if($WRIS_L3_Title_Color == "#F8504B" ) { echo "checked"; } ?>> <?php _e('Red', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
383
+ <input type="radio" name="wl-l3-title-color" id="wl-l3-title-color" value="#31a3dd" <?php if($WRIS_L3_Title_Color == "#31a3dd" ) { echo "checked"; } ?>> <?php _e('Blue', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
384
+ <input type="radio" name="wl-l3-title-color" id="wl-l3-title-color" value="#000000" <?php if($WRIS_L3_Title_Color == "#000000" ) { echo "checked"; } ?>> <?php _e('Black', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
385
+ <input type="radio" name="wl-l3-title-color" id="wl-l3-title-color" value="#FFFFFF" <?php if($WRIS_L3_Title_Color == "#FFFFFF" ) { echo "checked"; } ?>> <?php _e('White', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
386
+ <p class="description">
387
+ <?php _e('Select a color to set slide title color', WRIS_TEXT_DOMAIN); ?>.
388
+ <a href="#" id="p7" data-tooltip="#s7"><?php _e('Preview', WRIS_TEXT_DOMAIN); ?></a>
389
+ </p>
390
+ </td>
391
+ </tr>
392
+
393
+ <tr id="L3">
394
+ <th scope="row"><label><?php _e('Slide Title Background Color', WRIS_TEXT_DOMAIN); ?></label></th>
395
+ <td>
396
+ <?php if(!isset($WRIS_L3_Title_BgColor)) $WRIS_L3_Title_BgColor = "#FFFFFF"; ?>
397
+ <input type="radio" name="wl-l3-title-bgcolor" id="wl-l3-title-bgcolor" value="#F8504B" <?php if($WRIS_L3_Title_BgColor == "#F8504B" ) { echo "checked"; } ?>> <?php _e('Red', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
398
+ <input type="radio" name="wl-l3-title-bgcolor" id="wl-l3-title-bgcolor" value="#31a3dd" <?php if($WRIS_L3_Title_BgColor == "#31a3dd" ) { echo "checked"; } ?>> <?php _e('Blue', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
399
+ <input type="radio" name="wl-l3-title-bgcolor" id="wl-l3-title-bgcolor" value="#000000" <?php if($WRIS_L3_Title_BgColor == "#000000" ) { echo "checked"; } ?>> <?php _e('Black', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
400
+ <input type="radio" name="wl-l3-title-bgcolor" id="wl-l3-title-bgcolor" value="#FFFFFF" <?php if($WRIS_L3_Title_BgColor == "#FFFFFF" ) { echo "checked"; } ?>> <?php _e('White', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
401
+ <p class="description">
402
+ <?php _e('Select a color to set slide title background color', WRIS_TEXT_DOMAIN); ?>.
403
+ <a href="#" id="p8" data-tooltip="#s8"><?php _e('Preview', WRIS_TEXT_DOMAIN); ?></a>
404
+ </p>
405
+ </td>
406
+ </tr>
407
+
408
+ <tr id="L3">
409
+ <th scope="row"><label><?php _e('Slide Description Color', WRIS_TEXT_DOMAIN); ?></label></th>
410
+ <td>
411
+ <?php if(!isset($WRIS_L3_Desc_Color)) $WRIS_L3_Desc_Color = "#FFFFFF"; ?>
412
+ <input type="radio" name="wl-l3-desc-color" id="wl-l3-desc-color" value="#F8504B" <?php if($WRIS_L3_Desc_Color == "#F8504B" ) { echo "checked"; } ?>> <?php _e('Red', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
413
+ <input type="radio" name="wl-l3-desc-color" id="wl-l3-desc-color" value="#31a3dd" <?php if($WRIS_L3_Desc_Color == "#31a3dd" ) { echo "checked"; } ?>> <?php _e('Blue', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
414
+ <input type="radio" name="wl-l3-desc-color" id="wl-l3-desc-color" value="#000000" <?php if($WRIS_L3_Desc_Color == "#000000" ) { echo "checked"; } ?>> <?php _e('Black', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
415
+ <input type="radio" name="wl-l3-desc-color" id="wl-l3-desc-color" value="#FFFFFF" <?php if($WRIS_L3_Desc_Color == "#FFFFFF" ) { echo "checked"; } ?>> <?php _e('White', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
416
+ <p class="description">
417
+ <?php _e('Select a color to set slide description color', WRIS_TEXT_DOMAIN); ?>.
418
+ <a href="#" id="p9" data-tooltip="#s9"><?php _e('Preview', WRIS_TEXT_DOMAIN); ?></a>
419
+ </p>
420
+ </td>
421
+ </tr>
422
+
423
+ <tr id="L3">
424
+ <th scope="row"><label><?php _e('Slide Description Background Color', WRIS_TEXT_DOMAIN); ?></label></th>
425
+ <td>
426
+ <?php if(!isset($WRIS_L3_Desc_BgColor)) $WRIS_L3_Desc_BgColor = "#000000"; ?>
427
+ <input type="radio" name="wl-l3-desc-bgcolor" id="wl-l3-desc-bgcolor" value="#F8504B" <?php if($WRIS_L3_Desc_BgColor == "#F8504B" ) { echo "checked"; } ?>> <?php _e('Red', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
428
+ <input type="radio" name="wl-l3-desc-bgcolor" id="wl-l3-desc-bgcolor" value="#31a3dd" <?php if($WRIS_L3_Desc_BgColor == "#31a3dd" ) { echo "checked"; } ?>> <?php _e('Blue', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
429
+ <input type="radio" name="wl-l3-desc-bgcolor" id="wl-l3-desc-bgcolor" value="#000000" <?php if($WRIS_L3_Desc_BgColor == "#000000" ) { echo "checked"; } ?>> <?php _e('Black', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
430
+ <input type="radio" name="wl-l3-desc-bgcolor" id="wl-l3-desc-bgcolor" value="#FFFFFF" <?php if($WRIS_L3_Desc_BgColor == "#FFFFFF" ) { echo "checked"; } ?>> <?php _e('White', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
431
+ <p class="description">
432
+ <?php _e('Select a color to set slide description background color', WRIS_TEXT_DOMAIN); ?>.
433
+ <a href="#" id="p10" data-tooltip="#s10"><?php _e('Preview', WRIS_TEXT_DOMAIN); ?></a>
434
+ </p>
435
+ </td>
436
+ </tr>
437
+
438
+ <tr id="L3">
439
+ <th scope="row"><label><?php _e('Navigation Color', WRIS_TEXT_DOMAIN); ?></label></th>
440
+ <td>
441
+ <?php if(!isset($WRIS_L3_Navigation_Color)) $WRIS_L3_Navigation_Color = "#FFFFFF"; ?>
442
+ <input type="radio" name="wl-l3-navigation-color" id="wl-l3-navigation-color" value="#F8504B" <?php if($WRIS_L3_Navigation_Color == "#F8504B" ) { echo "checked"; } ?>> <?php _e('Red', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
443
+ <input type="radio" name="wl-l3-navigation-color" id="wl-l3-navigation-color" value="#31a3dd" <?php if($WRIS_L3_Navigation_Color == "#31a3dd" ) { echo "checked"; } ?>> <?php _e('Blue', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
444
+ <input type="radio" name="wl-l3-navigation-color" id="wl-l3-navigation-color" value="#000000" <?php if($WRIS_L3_Navigation_Color == "#000000" ) { echo "checked"; } ?>> <?php _e('Black', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
445
+ <input type="radio" name="wl-l3-navigation-color" id="wl-l3-navigation-color" value="#FFFFFF" <?php if($WRIS_L3_Navigation_Color == "#FFFFFF" ) { echo "checked"; } ?>> <?php _e('White', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
446
+ <p class="description">
447
+ <?php _e('Select a color to set navigation arrow and fullscreen icon color', WRIS_TEXT_DOMAIN); ?>.
448
+ <a href="#" id="p11" data-tooltip="#s11"><?php _e('Preview', WRIS_TEXT_DOMAIN); ?></a>
449
+ </p>
450
+ </td>
451
+ </tr>
452
+
453
+ <tr id="L3">
454
+ <th scope="row"><label><?php _e('Navigation Bullets Color', WRIS_TEXT_DOMAIN); ?></label></th>
455
+ <td>
456
+ <?php if(!isset($WRIS_L3_Navigation_Bullets_Color)) $WRIS_L3_Navigation_Bullets_Color = "#000000"; ?>
457
+ <input type="radio" name="wl-l3-navigation-bullets-color" id="wl-l3-navigation-bullets-color" value="#F8504B" <?php if($WRIS_L3_Navigation_Bullets_Color == "#F8504B" ) { echo "checked"; } ?>> <?php _e('Red', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
458
+ <input type="radio" name="wl-l3-navigation-bullets-color" id="wl-l3-navigation-bullets-color" value="#31a3dd" <?php if($WRIS_L3_Navigation_Bullets_Color == "#31a3dd" ) { echo "checked"; } ?>> <?php _e('Blue', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
459
+ <input type="radio" name="wl-l3-navigation-bullets-color" id="wl-l3-navigation-bullets-color" value="#000000" <?php if($WRIS_L3_Navigation_Bullets_Color == "#000000" ) { echo "checked"; } ?>> <?php _e('Black', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
460
+ <input type="radio" name="wl-l3-navigation-bullets-color" id="wl-l3-navigation-bullets-color" value="#FFFFFF" <?php if($WRIS_L3_Navigation_Bullets_Color == "#FFFFFF" ) { echo "checked"; } ?>> <?php _e('White', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
461
+ <p class="description">
462
+ <?php _e('Select a color to set navigation bullets color', WRIS_TEXT_DOMAIN); ?>.
463
+ </p>
464
+ </td>
465
+ </tr>
466
+
467
+ <tr id="L3">
468
+ <th scope="row"><label><?php _e('Navigation Pointer Color', WRIS_TEXT_DOMAIN); ?></label></th>
469
+ <td>
470
+ <?php if(!isset($WRIS_L3_Navigation_Pointer_Color)) $WRIS_L3_Navigation_Pointer_Color = "#000000"; ?>
471
+ <input type="radio" name="wl-l3-navigation-pointer-color" id="wl-l3-navigation-pointer-color" value="#F8504B" <?php if($WRIS_L3_Navigation_Pointer_Color == "#F8504B" ) { echo "checked"; } ?>> <?php _e('Red', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
472
+ <input type="radio" name="wl-l3-navigation-pointer-color" id="wl-l3-navigation-pointer-color" value="#31a3dd" <?php if($WRIS_L3_Navigation_Pointer_Color == "#31a3dd" ) { echo "checked"; } ?>> <?php _e('Blue', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
473
+ <input type="radio" name="wl-l3-navigation-pointer-color" id="wl-l3-navigation-pointer-color" value="#000000" <?php if($WRIS_L3_Navigation_Pointer_Color == "#000000" ) { echo "checked"; } ?>> <?php _e('Black', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
474
+ <input type="radio" name="wl-l3-navigation-pointer-color" id="wl-l3-navigation-pointer-color" value="#FFFFFF" <?php if($WRIS_L3_Navigation_Pointer_Color == "#FFFFFF" ) { echo "checked"; } ?>> <?php _e('White', WRIS_TEXT_DOMAIN); ?> &nbsp;&nbsp;
475
+ <p class="description">
476
+ <?php _e('Select a color to set navigation pointer color', WRIS_TEXT_DOMAIN); ?>.
477
+ </p>
478
+ </td>
479
+ </tr>
480
+
481
+ <tr id="L3">
482
+ <th scope="row"><label><?php _e('Full Screen Slide Show', WRIS_TEXT_DOMAIN); ?></label></th>
483
+ <td>
484
+ <?php if(!isset($WRIS_L3_Fullscreeen)) $WRIS_L3_Fullscreeen = 1; ?>
485
+ <input type="radio" name="wl-l3-fullscreen" id="wl-l3-fullscreen" value="1" <?php if($WRIS_L3_Fullscreeen == 1 ) { echo "checked"; } ?>> <i class="fa fa-check fa-2x"></i> &nbsp;&nbsp;
486
+ <input type="radio" name="wl-l3-fullscreen" id="wl-l3-fullscreen" value="0" <?php if($WRIS_L3_Fullscreeen == 0 ) { echo "checked"; } ?>> <i class="fa fa-times fa-2x"></i>
487
+ <p class="description">
488
+ <?php _e('Select Yes/No option for full screen slide show', WRIS_TEXT_DOMAIN); ?>.
489
  </p>
490
  </td>
491
  </tr>
492
 
493
  <tr id="L3">
494
+ <th scope="row"><label><?php _e('Custom CSS', WRIS_TEXT_DOMAIN); ?></label></th>
495
  <td>
496
  <?php if(!isset($WRIS_L3_Custom_CSS)) $WRIS_L3_Custom_CSS = ""; ?>
497
  <textarea name="wl-l3-custom-css" id="wl-l3-custom-css" rows="5" cols="75"><?php echo $WRIS_L3_Custom_CSS; ?></textarea>
498
  <p class="description">
499
+ <?php _e('Enter any custom css you want to apply on this slider into textarea filed', WRIS_TEXT_DOMAIN); ?>.<br>
500
+ <?php _e('Note', WRIS_TEXT_DOMAIN); ?><strong>:</strong> <?php _e('Please Do Not Use', WRIS_TEXT_DOMAIN); ?> <strong>&lt;style&gt;...&lt;/style&gt;</strong> <?php _e('Tag With Custom CSS', WRIS_TEXT_DOMAIN); ?>.
501
  </p>
502
  </td>
503
  </tr>
 
504
  </tbody>
505
  </table>
ultimate-responsive-image-slider-short-code.php CHANGED
@@ -15,17 +15,144 @@ function ResponsiveWWRISroShortCode( $Id ) {
15
  $WRIS_Gallery_Settings_Key = "WRIS_Gallery_Settings_".$WRIS_Id;
16
  $WRIS_Gallery_Settings = unserialize(get_post_meta( $WRIS_Id, $WRIS_Gallery_Settings_Key, true));
17
  if($WRIS_Gallery_Settings['WRIS_L3_Slider_Width'] && $WRIS_Gallery_Settings['WRIS_L3_Slider_Height']) {
18
- $WRIS_L3_Slide_Title = $WRIS_Gallery_Settings['WRIS_L3_Slide_Title'];
19
- $WRIS_L3_Auto_Slideshow = $WRIS_Gallery_Settings['WRIS_L3_Auto_Slideshow'];
20
- $WRIS_L3_Transition = $WRIS_Gallery_Settings['WRIS_L3_Transition'];
21
- $WRIS_L3_Transition_Speed = $WRIS_Gallery_Settings['WRIS_L3_Transition_Speed'];
22
- $WRIS_L3_Sliding_Arrow = $WRIS_Gallery_Settings['WRIS_L3_Sliding_Arrow'];
23
- $WRIS_L3_Slider_Navigation = $WRIS_Gallery_Settings['WRIS_L3_Slider_Navigation'];
24
- $WRIS_L3_Navigation_Button = $WRIS_Gallery_Settings['WRIS_L3_Navigation_Button'];
25
- $WRIS_L3_Slider_Width = $WRIS_Gallery_Settings['WRIS_L3_Slider_Width'];
26
- $WRIS_L3_Slider_Height = $WRIS_Gallery_Settings['WRIS_L3_Slider_Height'];
27
- $WRIS_L3_Custom_CSS = $WRIS_Gallery_Settings['WRIS_L3_Custom_CSS'];
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
28
  }
 
 
 
29
  }
30
 
31
  /**
15
  $WRIS_Gallery_Settings_Key = "WRIS_Gallery_Settings_".$WRIS_Id;
16
  $WRIS_Gallery_Settings = unserialize(get_post_meta( $WRIS_Id, $WRIS_Gallery_Settings_Key, true));
17
  if($WRIS_Gallery_Settings['WRIS_L3_Slider_Width'] && $WRIS_Gallery_Settings['WRIS_L3_Slider_Height']) {
18
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Slide_Title']))
19
+ $WRIS_L3_Slide_Title = $WRIS_Gallery_Settings['WRIS_L3_Slide_Title'];
20
+ else
21
+ $WRIS_L3_Slide_Title = 1;
22
+
23
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Auto_Slideshow']))
24
+ $WRIS_L3_Auto_Slideshow = $WRIS_Gallery_Settings['WRIS_L3_Auto_Slideshow'];
25
+ else
26
+ $WRIS_L3_Auto_Slideshow = 1;
27
+
28
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Transition']))
29
+ $WRIS_L3_Transition = $WRIS_Gallery_Settings['WRIS_L3_Transition'];
30
+ else
31
+ $WRIS_L3_Transition = 1;
32
+
33
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Transition_Speed']))
34
+ $WRIS_L3_Transition_Speed = $WRIS_Gallery_Settings['WRIS_L3_Transition_Speed'];
35
+ else
36
+ $WRIS_L3_Transition_Speed = 5000;
37
+
38
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Slide_Order']))
39
+ $WRIS_L3_Slide_Order = $WRIS_Gallery_Settings['WRIS_L3_Slide_Order'];
40
+ else
41
+ $WRIS_L3_Slide_Order = "ASC";
42
+
43
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Slide_Distance']))
44
+ $WRIS_L3_Slide_Distance = $WRIS_Gallery_Settings['WRIS_L3_Slide_Distance'];
45
+ else
46
+ $WRIS_L3_Slide_Distance = 5;
47
+
48
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Sliding_Arrow']))
49
+ $WRIS_L3_Sliding_Arrow = $WRIS_Gallery_Settings['WRIS_L3_Sliding_Arrow'];
50
+ else
51
+ $WRIS_L3_Sliding_Arrow = 1;
52
+
53
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Slider_Navigation']))
54
+ $WRIS_L3_Slider_Navigation = $WRIS_Gallery_Settings['WRIS_L3_Slider_Navigation'];
55
+ else
56
+ $WRIS_L3_Slider_Navigation = 1;
57
+
58
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Navigation_Position']))
59
+ $WRIS_L3_Navigation_Position = $WRIS_Gallery_Settings['WRIS_L3_Navigation_Position'];
60
+ else
61
+ $WRIS_L3_Navigation_Position = "bottom";
62
+
63
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Thumbnail_Style']))
64
+ $WRIS_L3_Thumbnail_Style = $WRIS_Gallery_Settings['WRIS_L3_Thumbnail_Style'];
65
+ else
66
+ $WRIS_L3_Thumbnail_Style = "border";
67
+
68
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Thumbnail_Width']))
69
+ $WRIS_L3_Thumbnail_Width = $WRIS_Gallery_Settings['WRIS_L3_Thumbnail_Width'];
70
+ else
71
+ $WRIS_L3_Thumbnail_Width = 120;
72
+
73
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Thumbnail_Height']))
74
+ $WRIS_L3_Thumbnail_Height = $WRIS_Gallery_Settings['WRIS_L3_Thumbnail_Height'];
75
+ else
76
+ $WRIS_L3_Thumbnail_Height = 100;
77
+
78
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Navigation_Button']))
79
+ $WRIS_L3_Navigation_Button = $WRIS_Gallery_Settings['WRIS_L3_Navigation_Button'];
80
+ else
81
+ $WRIS_L3_Navigation_Button = 1;
82
+
83
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Width']))
84
+ $WRIS_L3_Width = $WRIS_Gallery_Settings['WRIS_L3_Width'];
85
+ else
86
+ $WRIS_L3_Width = "custom";
87
+
88
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Slider_Width']))
89
+ $WRIS_L3_Slider_Width = $WRIS_Gallery_Settings['WRIS_L3_Slider_Width'];
90
+ else
91
+ $WRIS_L3_Slider_Width = 1000;
92
+
93
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Height']))
94
+ $WRIS_L3_Height = $WRIS_Gallery_Settings['WRIS_L3_Height'];
95
+ else
96
+ $WRIS_L3_Height = "custom";
97
+
98
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Slider_Height']))
99
+ $WRIS_L3_Slider_Height = $WRIS_Gallery_Settings['WRIS_L3_Slider_Height'];
100
+ else
101
+ $WRIS_L3_Slider_Height = 500;
102
+
103
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Font_Style']))
104
+ $WRIS_L3_Font_Style = $WRIS_Gallery_Settings['WRIS_L3_Font_Style'];
105
+ else
106
+ $WRIS_L3_Font_Style = "Arial";
107
+
108
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Title_Color']))
109
+ $WRIS_L3_Title_Color = $WRIS_Gallery_Settings['WRIS_L3_Title_Color'];
110
+ else
111
+ $WRIS_L3_Title_Color = "#00000";
112
+
113
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Title_BgColor']))
114
+ $WRIS_L3_Title_BgColor = $WRIS_Gallery_Settings['WRIS_L3_Title_BgColor'];
115
+ else
116
+ $WRIS_L3_Title_BgColor = "#FFFFFF";
117
+
118
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Desc_Color']))
119
+ $WRIS_L3_Desc_Color = $WRIS_Gallery_Settings['WRIS_L3_Desc_Color'];
120
+ else
121
+ $WRIS_L3_Desc_Color = "#FFFFFF";
122
+
123
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Desc_BgColor']))
124
+ $WRIS_L3_Desc_BgColor = $WRIS_Gallery_Settings['WRIS_L3_Desc_BgColor'];
125
+ else
126
+ $WRIS_L3_Desc_BgColor = "#00000";
127
+
128
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Navigation_Color']))
129
+ $WRIS_L3_Navigation_Color = $WRIS_Gallery_Settings['WRIS_L3_Navigation_Color'];
130
+ else
131
+ $WRIS_L3_Navigation_Color = "#FFFFFF";
132
+
133
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Fullscreeen']))
134
+ $WRIS_L3_Fullscreeen = $WRIS_Gallery_Settings['WRIS_L3_Fullscreeen'];
135
+ else
136
+ $WRIS_L3_Fullscreeen = 1;
137
+
138
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Navigation_Bullets_Color']))
139
+ $WRIS_L3_Navigation_Bullets_Color = $WRIS_Gallery_Settings['WRIS_L3_Navigation_Bullets_Color'];
140
+ else
141
+ $WRIS_L3_Navigation_Bullets_Color = "#000000";
142
+
143
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Navigation_Pointer_Color']))
144
+ $WRIS_L3_Navigation_Pointer_Color = $WRIS_Gallery_Settings['WRIS_L3_Navigation_Pointer_Color'];
145
+ else
146
+ $WRIS_L3_Navigation_Pointer_Color = "#000000";
147
+
148
+ if(isset($WRIS_Gallery_Settings['WRIS_L3_Custom_CSS']))
149
+ $WRIS_L3_Custom_CSS = $WRIS_Gallery_Settings['WRIS_L3_Custom_CSS'];
150
+ else
151
+ $WRIS_L3_Custom_CSS = "";
152
  }
153
+ /* echo "<pre>";
154
+ print_r($WRIS_Gallery_Settings);
155
+ echo "<pre>"; */
156
  }
157
 
158
  /**
ultimate-responsive-image-slider.php CHANGED
@@ -1,11 +1,11 @@
1
  <?php
2
  /**
3
  * Plugin Name: Ultimate Responsive Image Slider
4
- * Version: 2.7
5
  * Description: Add unlimited image slides using Ultimate Responsive Image Slider in any Page and Post content to give an attractive mode to represent contents.
6
  * Author: Weblizar
7
- * Author URI: http://weblizar.com/plugins/
8
- * Plugin URI: http://weblizar.com/plugins/
9
  */
10
 
11
 
@@ -27,7 +27,25 @@ function WRIS_DefaultSettingsPro() {
27
  "WRIS_L3_Navigation_Button" => 1,
28
  "WRIS_L3_Slider_Width" => "1000",
29
  "WRIS_L3_Slider_Height" => "500",
30
- "WRIS_L3_Custom_CSS" => ""
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
31
  ));
32
  add_option("WRIS_Settings", $DefaultSettingsProArray);
33
  }
@@ -36,58 +54,54 @@ function WRIS_DefaultSettingsPro() {
36
  add_image_size( 'rpggallery_admin_thumb', 300, 300, true );
37
  add_image_size( 'rpggallery_admin_large', 500,9999 );
38
 
39
- function admin_content_wpse_144936() {
40
-
41
- if(get_post_type()=="ris_gallery"){
42
- ?>
43
- <style>
44
- .wlTBlock{
45
- background: linear-gradient( rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5) ), url('<?php echo WRIS_PLUGIN_URL.'/img/bg2.jpg'; ?>') no-repeat fixed;
46
- background-position: 50% 0 !important;
47
- padding: 27px 0 23px 0;
48
- margin-left: -20px;
49
- font-family: Myriad Pro ;
50
- cursor: pointer;
51
- text-align: center;
52
- }
53
- .wlTBlock .wlTBig{
54
- color: white;
55
- font-size: 30px;
56
- font-weight: bolder;
57
- padding: 0 0 15px 0;
58
- }
59
- .wlTBlock .wlTBig .dashicons{
60
- font-size: 40px;
61
- position: absolute;
62
- margin-left: -45px;
63
- margin-top: -10px;
64
- }
65
- .wlTBlock .WlTSmall{
66
- font-weight: bolder;
67
- color: white;
68
- font-size: 18px;
69
- padding: 0 0 15px 15px;
70
- }
71
 
72
- .wlTBlock a{
73
- text-decoration: none;
74
- }
75
- @media screen and ( max-width: 600px ) {
76
- .wlTBlock{ padding-top: 60px; margin-bottom: -50px; }
77
- .wlTBlock .WlTSmall { display: none; }
78
-
79
- }
80
- </style>
81
- <div class="wlTBlock ">
82
  <a href="https://weblizar.com/plugins/ultimate-responsive-image-slider-pro/" target="_new">
83
  <div class="wlTBig"><span class="dashicons dashicons-cart"></span>Get Pro version</div>
84
  <div class="WlTSmall">with PRO version you get more advanced functionality and even more flexibility in settings </div>
85
  </a>
86
  </div>
87
- <?php
88
-
89
- }
90
-
91
  }
92
  add_action('in_admin_header','admin_content_wpse_144936');
93
 
@@ -127,6 +141,7 @@ class WRIS {
127
  add_image_size('rpg_gallery_thumb', $this->thumbnail_size_w, $this->thumbnail_size_h, true);
128
  add_shortcode('rpggallery', array(&$this, 'shortcode'));
129
  if (is_admin()) {
 
130
  add_action('init', array(&$this, 'ResponsiveImageSlider'), 1);
131
  add_action('add_meta_boxes', array(&$this, 'add_all_ris_meta_boxes'));
132
  add_action('admin_init', array(&$this, 'add_all_ris_meta_boxes'), 1);
@@ -138,6 +153,13 @@ class WRIS {
138
  }
139
  }
140
 
 
 
 
 
 
 
 
141
  //Required JS & CSS
142
  public function ris_admin_print_scripts() {
143
  wp_enqueue_script('media-upload');
@@ -162,19 +184,19 @@ class WRIS {
162
  // Register Custom Post Type
163
  public function ResponsiveImageSlider() {
164
  $labels = array(
165
- 'name' => _x( 'Ultimate Responsive Image Slider', 'ris_gallery' ),
166
- 'singular_name' => _x( 'Ultimate Responsive Image Slider', 'ris_gallery' ),
167
- 'add_new' => _x( 'Add New Image Slider', 'ris_gallery' ),
168
- 'add_new_item' => _x( 'Add New Image Slider', 'ris_gallery' ),
169
- 'edit_item' => _x( 'Edit Image Slider', 'ris_gallery' ),
170
- 'new_item' => _x( 'New Image Slider', 'ris_gallery' ),
171
- 'view_item' => _x( 'View Image Slider', 'ris_gallery' ),
172
- 'search_items' => _x( 'Search Image Slider', 'ris_gallery' ),
173
- 'not_found' => _x( 'No Image Slider found', 'ris_gallery' ),
174
- 'not_found_in_trash' => _x( 'No Image found in Trash', 'ris_gallery' ),
175
- 'parent_item_colon' => _x( 'Parent Image:', 'ris_gallery' ),
176
  'all_items' => __( 'All Image Sliders', WRIS_TEXT_DOMAIN ),
177
- 'menu_name' => _x( 'UR Image Slider', 'ris_gallery' ),
178
  );
179
 
180
  $args = array(
@@ -226,9 +248,9 @@ class WRIS {
226
  add_meta_box( __('Add Images', WRIS_TEXT_DOMAIN), __('Add Images', WRIS_TEXT_DOMAIN), array(&$this, 'ris_generate_add_image_meta_box_function'), 'ris_gallery', 'normal', 'low' );
227
  add_meta_box( __('Apply Setting On Ultimate Responsive Image Slider', WRIS_TEXT_DOMAIN), __('Apply Setting On Ultimate Responsive Image Slider', WRIS_TEXT_DOMAIN), array(&$this, 'ris_settings_meta_box_function'), 'ris_gallery', 'normal', 'low');
228
  add_meta_box ( __('Copy Image Slider Shortcode', WRIS_TEXT_DOMAIN), __('Copy Image Slider Shortcode', WRIS_TEXT_DOMAIN), array(&$this, 'ris_shotcode_meta_box_function'), 'ris_gallery', 'side', 'low');
229
- add_meta_box(__('Show us some love, Rate Us', WRIS_TEXT_DOMAIN) , __('Show us some love, Rate Us', WRIS_TEXT_DOMAIN), array(&$this, 'uris_Rate_us_meta_box_function'), 'ris_gallery', 'side', 'low');
230
- add_meta_box(__('Upgrade To Pro Version', WRIS_TEXT_DOMAIN) , __('Upgrade To Pro Version', WRIS_TEXT_DOMAIN), array(&$this, 'uris_upgrade_to_pro_function'), 'ris_gallery', 'side', 'low');
231
- add_meta_box(__('Pro Features', WRIS_TEXT_DOMAIN) , __('Pro Features', WRIS_TEXT_DOMAIN), array(&$this ,'uris_pro_features'), 'ris_gallery', 'side', 'low');
232
  }
233
 
234
  //Rate Us Meta Box
@@ -325,12 +347,12 @@ class WRIS {
325
  <input type="text" id="rpggallery_admin_thumb[]" name="rpggallery_admin_thumb[]" class="rpg_label_text" value="<?php echo $url1; ?>" readonly="readonly" style="display:none;" />
326
  <input type="text" id="rpggallery_admin_large[]" name="rpggallery_admin_large[]" class="rpg_label_text" value="<?php echo $url3; ?>" readonly="readonly" style="display:none;" />
327
  <p>
328
- <label>Slide Title</label>
329
- <input type="text" id="rpgp_image_label[]" name="rpgp_image_label[]" value="<?php echo $name; ?>" placeholder="Enter Slide Title" class="rpg_label_text">
330
  </p>
331
  <p>
332
- <label>Slide Descriptions</label>
333
- <textarea rows="4" cols="50" id="rpgp_image_desc[]" name="rpgp_image_desc[]" placeholder="Enter Slide Descriptions" class="rpg_label_text"><?php echo $desc; ?></textarea>
334
  </p>
335
  </div>
336
  </li>
@@ -352,7 +374,7 @@ class WRIS {
352
  </p>
353
  </div>
354
  <div style="clear:left;"></div>
355
- <input id="uris_delete_all_button" class="button" type="button" value="Remove All Slides" rel="">
356
  <?php
357
  }
358
 
@@ -386,12 +408,12 @@ class WRIS {
386
  <input type="text" id="rpggallery_admin_thumb[]" name="rpggallery_admin_thumb[]" class="rpg_label_text" value="<?php echo $image1[0]; ?>" readonly="readonly" style="display:none;" />
387
  <input type="text" id="rpggallery_admin_large[]" name="rpggallery_admin_large[]" class="rpg_label_text" value="<?php echo $image3[0]; ?>" readonly="readonly" style="display:none;" />
388
  <p>
389
- <label>Slide Title</label>
390
- <input type="text" id="rpgp_image_label[]" name="rpgp_image_label[]" placeholder="Enter Slide Title Here" class="rpg_label_text">
391
  </p>
392
  <p>
393
- <label>Slide Description</label>
394
- <textarea rows="4" cols="50" id="rpgp_image_desc[]" name="rpgp_image_desc[]" placeholder="Enter Slide Description Here" class="rpg_label_text"></textarea>
395
  </p>
396
  </div>
397
  </li>
@@ -446,8 +468,26 @@ class WRIS {
446
  $WRIS_L3_Navigation_Button = $_POST['wl-l3-navigation-button'];
447
  $WRIS_L3_Slider_Width = $_POST['wl-l3-slider-width'];
448
  $WRIS_L3_Slider_Height = $_POST['wl-l3-slider-height'];
 
 
 
 
 
 
 
449
  $WRIS_L3_Custom_CSS = $_POST['wl-l3-custom-css'];
450
 
 
 
 
 
 
 
 
 
 
 
 
451
  $WRIS_Settings_Array = serialize( array(
452
  'WRIS_L3_Slide_Title' => $WRIS_L3_Slide_Title,
453
  'WRIS_L3_Auto_Slideshow' => $WRIS_L3_Auto_Slideshow,
@@ -458,7 +498,25 @@ class WRIS {
458
  'WRIS_L3_Navigation_Button' => $WRIS_L3_Navigation_Button,
459
  'WRIS_L3_Slider_Width' => $WRIS_L3_Slider_Width,
460
  'WRIS_L3_Slider_Height' => $WRIS_L3_Slider_Height,
 
 
 
 
 
 
 
461
  'WRIS_L3_Custom_CSS' => $WRIS_L3_Custom_CSS,
 
 
 
 
 
 
 
 
 
 
 
462
  ));
463
 
464
  $WRIS_Gallery_Settings = "WRIS_Gallery_Settings_".$PostID;
@@ -481,8 +539,8 @@ function uris_pro_SettingsPage() {
481
  wp_enqueue_style('wl-boot-strap-admin', WRIS_PLUGIN_URL.'css/bootstrap-admin.css');
482
  require_once("get-uris-pro.php");
483
  }
484
- add_submenu_page('edit.php?post_type=ris_gallery', __('Upgrade To Pro', WRIS_TEXT_DOMAIN), __('Upgrade To Pro', WRIS_TEXT_DOMAIN), 'administrator', 'ris_gallery', 'uris_upgrade_pro_function');
485
- add_submenu_page('edit.php?post_type=ris_gallery', __('Help and Support', WRIS_TEXT_DOMAIN), __('Help and Support', WRIS_TEXT_DOMAIN), 'administrator', 'RIS-Help-page', 'RIS_Help_and_Support_page');
486
 
487
  }
488
  function RIS_Help_and_Support_page(){
1
  <?php
2
  /**
3
  * Plugin Name: Ultimate Responsive Image Slider
4
+ * Version: 2.8
5
  * Description: Add unlimited image slides using Ultimate Responsive Image Slider in any Page and Post content to give an attractive mode to represent contents.
6
  * Author: Weblizar
7
+ * Author URI: https://weblizar.com/plugins/ultimate-responsive-image-slider-pro/
8
+ * Plugin URI: https://weblizar.com/plugins/ultimate-responsive-image-slider-pro/
9
  */
10
 
11
 
27
  "WRIS_L3_Navigation_Button" => 1,
28
  "WRIS_L3_Slider_Width" => "1000",
29
  "WRIS_L3_Slider_Height" => "500",
30
+ "WRIS_L3_Font_Style" => "Arial",
31
+ "WRIS_L3_Title_Color" => "#FFFFFF",
32
+ "WRIS_L3_Title_BgColor" => "#000000",
33
+ "WRIS_L3_Desc_Color" => "#FFFFFF",
34
+ "WRIS_L3_Desc_BgColor" => "#000000",
35
+ "WRIS_L3_Navigation_Color" => "#000000",
36
+ "WRIS_L3_Fullscreeen" => 1,
37
+ "WRIS_L3_Custom_CSS" => "",
38
+
39
+ 'WRIS_L3_Slide_Order' => "ASC",
40
+ 'WRIS_L3_Navigation_Position' => "bottom",
41
+ 'WRIS_L3_Slide_Distance' => 5,
42
+ 'WRIS_L3_Thumbnail_Style' => "border",
43
+ 'WRIS_L3_Thumbnail_Width' => 120,
44
+ 'WRIS_L3_Thumbnail_Height' => 100,
45
+ 'WRIS_L3_Width' => "custom",
46
+ 'WRIS_L3_Height' => "custom",
47
+ 'WRIS_L3_Navigation_Bullets_Color' => "#000000",
48
+ 'WRIS_L3_Navigation_Pointer_Color' => "#000000",
49
  ));
50
  add_option("WRIS_Settings", $DefaultSettingsProArray);
51
  }
54
  add_image_size( 'rpggallery_admin_thumb', 300, 300, true );
55
  add_image_size( 'rpggallery_admin_large', 500,9999 );
56
 
57
+ function admin_content_wpse_144936() {
58
+ if(get_post_type()=="ris_gallery") { ?>
59
+ <style>
60
+ .wlTBlock{
61
+ background: linear-gradient( rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5) ), url('<?php echo WRIS_PLUGIN_URL.'/img/bg2.jpg'; ?>') no-repeat fixed;
62
+ background-position: 50% 0 !important;
63
+ padding: 27px 0 23px 0;
64
+ margin-left: -20px;
65
+ font-family: Myriad Pro ;
66
+ cursor: pointer;
67
+ text-align: center;
68
+ }
69
+ .wlTBlock .wlTBig{
70
+ color: white;
71
+ font-size: 30px;
72
+ font-weight: bolder;
73
+ padding: 0 0 15px 0;
74
+ }
75
+ .wlTBlock .wlTBig .dashicons{
76
+ font-size: 40px;
77
+ position: absolute;
78
+ margin-left: -45px;
79
+ margin-top: -10px;
80
+ }
81
+ .wlTBlock .WlTSmall{
82
+ font-weight: bolder;
83
+ color: white;
84
+ font-size: 18px;
85
+ padding: 0 0 15px 15px;
86
+ }
 
 
87
 
88
+ .wlTBlock a{
89
+ text-decoration: none;
90
+ }
91
+ @media screen and ( max-width: 600px ) {
92
+ .wlTBlock{ padding-top: 60px; margin-bottom: -50px; }
93
+ .wlTBlock .WlTSmall { display: none; }
94
+
95
+ }
96
+ </style>
97
+ <div class="wlTBlock ">
98
  <a href="https://weblizar.com/plugins/ultimate-responsive-image-slider-pro/" target="_new">
99
  <div class="wlTBig"><span class="dashicons dashicons-cart"></span>Get Pro version</div>
100
  <div class="WlTSmall">with PRO version you get more advanced functionality and even more flexibility in settings </div>
101
  </a>
102
  </div>
103
+ <?php
104
+ }
 
 
105
  }
106
  add_action('in_admin_header','admin_content_wpse_144936');
107
 
141
  add_image_size('rpg_gallery_thumb', $this->thumbnail_size_w, $this->thumbnail_size_h, true);
142
  add_shortcode('rpggallery', array(&$this, 'shortcode'));
143
  if (is_admin()) {
144
+ add_action('plugins_loaded', array(&$this, 'WRIS_Translate'), 1);
145
  add_action('init', array(&$this, 'ResponsiveImageSlider'), 1);
146
  add_action('add_meta_boxes', array(&$this, 'add_all_ris_meta_boxes'));
147
  add_action('admin_init', array(&$this, 'add_all_ris_meta_boxes'), 1);
153
  }
154
  }
155
 
156
+ /**
157
+ * Translate Plugin
158
+ */
159
+ public function WRIS_Translate() {
160
+ load_plugin_textdomain('W_R_I_S', FALSE, dirname( plugin_basename(__FILE__)).'/languages/' );
161
+ }
162
+
163
  //Required JS & CSS
164
  public function ris_admin_print_scripts() {
165
  wp_enqueue_script('media-upload');
184
  // Register Custom Post Type
185
  public function ResponsiveImageSlider() {
186
  $labels = array(
187
+ 'name' => _x( 'Ultimate Responsive Image Slider', WRIS_TEXT_DOMAIN ),
188
+ 'singular_name' => _x( 'Ultimate Responsive Image Slider', WRIS_TEXT_DOMAIN ),
189
+ 'add_new' => __( 'Add New Image Slider', WRIS_TEXT_DOMAIN ),
190
+ 'add_new_item' => __( 'Add New Image Slider', WRIS_TEXT_DOMAIN ),
191
+ 'edit_item' => __( 'Edit Image Slider', WRIS_TEXT_DOMAIN ),
192
+ 'new_item' => __( 'New Image Slider', WRIS_TEXT_DOMAIN ),
193
+ 'view_item' => __( 'View Image Slider', WRIS_TEXT_DOMAIN ),
194
+ 'search_items' => __( 'Search Image Slider', WRIS_TEXT_DOMAIN ),
195
+ 'not_found' => __( 'No Image Slider found', WRIS_TEXT_DOMAIN ),
196
+ 'not_found_in_trash' => __( 'No Image Slider Found in Trash', WRIS_TEXT_DOMAIN ),
197
+ 'parent_item_colon' => __( 'Parent Image Slider:', WRIS_TEXT_DOMAIN ),
198
  'all_items' => __( 'All Image Sliders', WRIS_TEXT_DOMAIN ),
199
+ 'menu_name' => _x( 'UR Image Slider', WRIS_TEXT_DOMAIN ),
200
  );
201
 
202
  $args = array(
248
  add_meta_box( __('Add Images', WRIS_TEXT_DOMAIN), __('Add Images', WRIS_TEXT_DOMAIN), array(&$this, 'ris_generate_add_image_meta_box_function'), 'ris_gallery', 'normal', 'low' );
249
  add_meta_box( __('Apply Setting On Ultimate Responsive Image Slider', WRIS_TEXT_DOMAIN), __('Apply Setting On Ultimate Responsive Image Slider', WRIS_TEXT_DOMAIN), array(&$this, 'ris_settings_meta_box_function'), 'ris_gallery', 'normal', 'low');
250
  add_meta_box ( __('Copy Image Slider Shortcode', WRIS_TEXT_DOMAIN), __('Copy Image Slider Shortcode', WRIS_TEXT_DOMAIN), array(&$this, 'ris_shotcode_meta_box_function'), 'ris_gallery', 'side', 'low');
251
+ add_meta_box('Show us some love, Rate Us', 'Show us some love, Rate Us', array(&$this, 'uris_Rate_us_meta_box_function'), 'ris_gallery', 'side', 'low');
252
+ add_meta_box('Upgrade To Pro Version', 'Upgrade To Pro Version', array(&$this, 'uris_upgrade_to_pro_function'), 'ris_gallery', 'side', 'low');
253
+ add_meta_box('Pro Features' , 'Pro Features', array(&$this ,'uris_pro_features'), 'ris_gallery', 'side', 'low');
254
  }
255
 
256
  //Rate Us Meta Box
347
  <input type="text" id="rpggallery_admin_thumb[]" name="rpggallery_admin_thumb[]" class="rpg_label_text" value="<?php echo $url1; ?>" readonly="readonly" style="display:none;" />
348
  <input type="text" id="rpggallery_admin_large[]" name="rpggallery_admin_large[]" class="rpg_label_text" value="<?php echo $url3; ?>" readonly="readonly" style="display:none;" />
349
  <p>
350
+ <label><?php _e('Slide Title', WRIS_TEXT_DOMAIN); ?></label>
351
+ <input type="text" id="rpgp_image_label[]" name="rpgp_image_label[]" value="<?php echo $name; ?>" placeholder="<?php _e('Enter Slide Title', WRIS_TEXT_DOMAIN); ?>" class="rpg_label_text">
352
  </p>
353
  <p>
354
+ <label><?php _e('Slide Descriptions', WRIS_TEXT_DOMAIN); ?></label>
355
+ <textarea rows="4" cols="50" id="rpgp_image_desc[]" name="rpgp_image_desc[]" placeholder="<?php _e('Enter Slide Description', WRIS_TEXT_DOMAIN); ?>" class="rpg_label_text"><?php echo $desc; ?></textarea>
356
  </p>
357
  </div>
358
  </li>
374
  </p>
375
  </div>
376
  <div style="clear:left;"></div>
377
+ <input id="uris_delete_all_button" class="button" type="button" value="<?php _e('Remove All Slides', WRIS_TEXT_DOMAIN); ?>">
378
  <?php
379
  }
380
 
408
  <input type="text" id="rpggallery_admin_thumb[]" name="rpggallery_admin_thumb[]" class="rpg_label_text" value="<?php echo $image1[0]; ?>" readonly="readonly" style="display:none;" />
409
  <input type="text" id="rpggallery_admin_large[]" name="rpggallery_admin_large[]" class="rpg_label_text" value="<?php echo $image3[0]; ?>" readonly="readonly" style="display:none;" />
410
  <p>
411
+ <label><?php _e('Slide Title', WRIS_TEXT_DOMAIN); ?></label>
412
+ <input type="text" id="rpgp_image_label[]" name="rpgp_image_label[]" placeholder="<?php _e('Enter Slide Title Here', WRIS_TEXT_DOMAIN); ?>" class="rpg_label_text">
413
  </p>
414
  <p>
415
+ <label><?php _e('Slide Description', WRIS_TEXT_DOMAIN); ?></label>
416
+ <textarea rows="4" cols="50" id="rpgp_image_desc[]" name="rpgp_image_desc[]" placeholder="<?php _e('Enter Slide Description Here', WRIS_TEXT_DOMAIN); ?>" class="rpg_label_text"></textarea>
417
  </p>
418
  </div>
419
  </li>
468
  $WRIS_L3_Navigation_Button = $_POST['wl-l3-navigation-button'];
469
  $WRIS_L3_Slider_Width = $_POST['wl-l3-slider-width'];
470
  $WRIS_L3_Slider_Height = $_POST['wl-l3-slider-height'];
471
+ $WRIS_L3_Font_Style = $_POST['wl-l3-font-style'];
472
+ $WRIS_L3_Title_Color = $_POST['wl-l3-title-color'];
473
+ $WRIS_L3_Title_BgColor = $_POST['wl-l3-title-bgcolor'];
474
+ $WRIS_L3_Desc_Color = $_POST['wl-l3-desc-color'];
475
+ $WRIS_L3_Desc_BgColor = $_POST['wl-l3-desc-bgcolor'];
476
+ $WRIS_L3_Navigation_Color = $_POST['wl-l3-navigation-color'];
477
+ $WRIS_L3_Fullscreeen = $_POST['wl-l3-fullscreen'];
478
  $WRIS_L3_Custom_CSS = $_POST['wl-l3-custom-css'];
479
 
480
+ $WRIS_L3_Slide_Order = $_POST['wl-l3-slide-order'];
481
+ $WRIS_L3_Navigation_Position = $_POST['wl-l3-navigation-position'];
482
+ $WRIS_L3_Slide_Distance = $_POST['wl-l3-slide-distance'];
483
+ $WRIS_L3_Thumbnail_Style = $_POST['wl-l3-thumbnail-style'];
484
+ $WRIS_L3_Thumbnail_Width = $_POST['wl-l3-navigation-width'];
485
+ $WRIS_L3_Thumbnail_Height = $_POST['wl-l3-navigation-height'];
486
+ $WRIS_L3_Width = $_POST['wl-l3-width'];
487
+ $WRIS_L3_Height = $_POST['wl-l3-height'];
488
+ $WRIS_L3_Navigation_Bullets_Color = $_POST['wl-l3-navigation-bullets-color'];
489
+ $WRIS_L3_Navigation_Pointer_Color = $_POST['wl-l3-navigation-pointer-color'];
490
+
491
  $WRIS_Settings_Array = serialize( array(
492
  'WRIS_L3_Slide_Title' => $WRIS_L3_Slide_Title,
493
  'WRIS_L3_Auto_Slideshow' => $WRIS_L3_Auto_Slideshow,
498
  'WRIS_L3_Navigation_Button' => $WRIS_L3_Navigation_Button,
499
  'WRIS_L3_Slider_Width' => $WRIS_L3_Slider_Width,
500
  'WRIS_L3_Slider_Height' => $WRIS_L3_Slider_Height,
501
+ 'WRIS_L3_Font_Style' => $WRIS_L3_Font_Style,
502
+ 'WRIS_L3_Title_Color' => $WRIS_L3_Title_Color,
503
+ 'WRIS_L3_Title_BgColor' => $WRIS_L3_Title_BgColor,
504
+ 'WRIS_L3_Desc_Color' => $WRIS_L3_Desc_Color,
505
+ 'WRIS_L3_Desc_BgColor' => $WRIS_L3_Desc_BgColor,
506
+ 'WRIS_L3_Navigation_Color' => $WRIS_L3_Navigation_Color,
507
+ 'WRIS_L3_Fullscreeen' => $WRIS_L3_Fullscreeen,
508
  'WRIS_L3_Custom_CSS' => $WRIS_L3_Custom_CSS,
509
+
510
+ 'WRIS_L3_Slide_Order' => $WRIS_L3_Slide_Order,
511
+ 'WRIS_L3_Navigation_Position' => $WRIS_L3_Navigation_Position,
512
+ 'WRIS_L3_Slide_Distance' => $WRIS_L3_Slide_Distance,
513
+ 'WRIS_L3_Thumbnail_Style' => $WRIS_L3_Thumbnail_Style,
514
+ 'WRIS_L3_Thumbnail_Width' => $WRIS_L3_Thumbnail_Width,
515
+ 'WRIS_L3_Thumbnail_Height' => $WRIS_L3_Thumbnail_Height,
516
+ 'WRIS_L3_Width' => $WRIS_L3_Width,
517
+ 'WRIS_L3_Height' => $WRIS_L3_Height,
518
+ 'WRIS_L3_Navigation_Bullets_Color' => $WRIS_L3_Navigation_Bullets_Color,
519
+ 'WRIS_L3_Navigation_Pointer_Color' => $WRIS_L3_Navigation_Pointer_Color,
520
  ));
521
 
522
  $WRIS_Gallery_Settings = "WRIS_Gallery_Settings_".$PostID;
539
  wp_enqueue_style('wl-boot-strap-admin', WRIS_PLUGIN_URL.'css/bootstrap-admin.css');
540
  require_once("get-uris-pro.php");
541
  }
542
+ add_submenu_page('edit.php?post_type=ris_gallery', 'Upgrade To Pro', 'Upgrade To Pro', 'administrator', 'ris_gallery', 'uris_upgrade_pro_function');
543
+ add_submenu_page('edit.php?post_type=ris_gallery', 'Help and Support', 'Help and Support', 'administrator', 'RIS-Help-page', 'RIS_Help_and_Support_page');
544
 
545
  }
546
  function RIS_Help_and_Support_page(){
uris-layout.php CHANGED
@@ -3,13 +3,14 @@
3
  * Load All WRIS Custom Post Type
4
  */
5
  $IG_CPT_Name = "ris_gallery";
6
- $AllSlides = array( 'p' => $Id['id'], 'post_type' => $IG_CPT_Name, 'orderby' => 'ASC');
 
7
  $loop = new WP_Query( $AllSlides );
8
 
9
  while ( $loop->have_posts() ) : $loop->the_post();
10
  //get the post id
11
  $post_id = get_the_ID();
12
-
13
  /**
14
  * Get All Slides Details Post Meta
15
  */
@@ -21,39 +22,146 @@ $j = 1;
21
  <script type="text/javascript">
22
  jQuery( document ).ready(function( jQuery ) {
23
  jQuery( '#example3_<?php echo $post_id; ?>' ).sliderPro({
 
 
 
 
24
  width: <?php if($WRIS_L3_Slider_Width != "") echo $WRIS_L3_Slider_Width; else echo "1000"; ?>,
 
 
 
 
 
 
25
  height: <?php if($WRIS_L3_Slider_Height != "") echo $WRIS_L3_Slider_Height; else echo "500"; ?>,
26
- autoplay: <?php if($WRIS_L3_Auto_Slideshow == 1) echo "true"; else echo "false"; ?>,
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
27
  autoplayDelay: <?php if($WRIS_L3_Transition_Speed != "") echo $WRIS_L3_Transition_Speed; else echo "5000"; ?>,
 
 
28
  arrows: <?php if($WRIS_L3_Sliding_Arrow == 1) echo "true"; else echo "false"; ?>,
29
  buttons: <?php if($WRIS_L3_Navigation_Button == 1) echo "true"; else echo "false"; ?>,
30
  smallSize: 500,
31
  mediumSize: 1000,
32
  largeSize: 3000,
33
  fade: <?php if($WRIS_L3_Transition == 1) echo "true"; else echo "false"; ?>,
34
- thumbnailArrows: true,
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
35
  });
36
  });
37
  </script>
 
 
 
 
 
 
 
 
38
  <style>
39
  /* Example 3 */
 
 
 
40
  #example3_<?php echo $post_id; ?> .sp-selected-thumbnail {
41
- border: 4px solid #000;
42
  }
 
43
 
44
- /*
45
- #example3_<?php //echo $post_id; ?> .title-in {
46
- font-weight: bolder;
 
 
47
  opacity: 0.7 !important;
48
- font-size: 1.2em;
49
  }
50
-
51
- #example3_<?php //echo $post_id; ?> .desc-in {
 
 
52
  opacity: 0.7 !important;
53
- text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
54
- font-size: 1em;
55
  }
56
- */
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
57
 
58
  #example3_<?php echo $post_id; ?> .title-in {
59
  color: <?php echo $RISP_Slide_In_Title_Color; ?> !important;
@@ -153,10 +261,10 @@ $j = 1;
153
  <div class="sp-thumbnails">
154
  <?php
155
  foreach($RPGP_AllPhotosDetails as $RPGP_SinglePhotoDetails) {
156
- $ThumbUrl = $RPGP_SinglePhotoDetails['rpggallery_admin_thumb'];
157
- $j++;
158
- ?>
159
- <img class="sp-thumbnail" src="<?php echo $ThumbUrl; ?>"/>
160
  <?php } ?>
161
  </div>
162
  <?php } ?>
3
  * Load All WRIS Custom Post Type
4
  */
5
  $IG_CPT_Name = "ris_gallery";
6
+ echo $WRIS_L3_Slide_Order;
7
+ $AllSlides = array( 'p' => $Id['id'], 'post_type' => $IG_CPT_Name, 'orderby' => $WRIS_L3_Slide_Order);
8
  $loop = new WP_Query( $AllSlides );
9
 
10
  while ( $loop->have_posts() ) : $loop->the_post();
11
  //get the post id
12
  $post_id = get_the_ID();
13
+
14
  /**
15
  * Get All Slides Details Post Meta
16
  */
22
  <script type="text/javascript">
23
  jQuery( document ).ready(function( jQuery ) {
24
  jQuery( '#example3_<?php echo $post_id; ?>' ).sliderPro({
25
+ //width
26
+ <?php if($WRIS_L3_Width == "100%") { ?>
27
+ width: "100%",
28
+ <?php } else if($WRIS_L3_Width == "custom") { ?>
29
  width: <?php if($WRIS_L3_Slider_Width != "") echo $WRIS_L3_Slider_Width; else echo "1000"; ?>,
30
+ <?php } else if($WRIS_L3_Width == "fullWidth") { ?>
31
+ forceSize: 'fullWidth', //'fullWidth', 'fullWindow', 'none'
32
+ <?php } ?>
33
+
34
+ //height
35
+ <?php if($WRIS_L3_Height == "custom") { ?>
36
  height: <?php if($WRIS_L3_Slider_Height != "") echo $WRIS_L3_Slider_Height; else echo "500"; ?>,
37
+ <?php } else { ?>
38
+ autoHeight: true,
39
+ <?php } ?>
40
+
41
+ //autoplay
42
+ <?php if($WRIS_L3_Auto_Slideshow == 1) { ?>
43
+ autoplay: true,
44
+ autoplayOnHover: 'none',
45
+ <?php } ?>
46
+ <?php if($WRIS_L3_Auto_Slideshow == 2) { ?>
47
+ autoplay: true,
48
+ autoplayOnHover: 'pause',
49
+ <?php } ?>
50
+ <?php if($WRIS_L3_Auto_Slideshow == 3) { ?>
51
+ autoplay: false,
52
+ <?php } ?>
53
  autoplayDelay: <?php if($WRIS_L3_Transition_Speed != "") echo $WRIS_L3_Transition_Speed; else echo "5000"; ?>,
54
+
55
+
56
  arrows: <?php if($WRIS_L3_Sliding_Arrow == 1) echo "true"; else echo "false"; ?>,
57
  buttons: <?php if($WRIS_L3_Navigation_Button == 1) echo "true"; else echo "false"; ?>,
58
  smallSize: 500,
59
  mediumSize: 1000,
60
  largeSize: 3000,
61
  fade: <?php if($WRIS_L3_Transition == 1) echo "true"; else echo "false"; ?>,
62
+
63
+ //thumbnail
64
+ thumbnailArrows: true,
65
+ thumbnailWidth: <?php if($WRIS_L3_Thumbnail_Width != "") echo $WRIS_L3_Thumbnail_Width; else echo "120"; ?>,
66
+ thumbnailHeight: <?php if($WRIS_L3_Thumbnail_Height != "") echo $WRIS_L3_Thumbnail_Height; else echo "100"; ?>,
67
+ <?php if($WRIS_L3_Navigation_Position == "top") { ?>
68
+ thumbnailsPosition: 'top',
69
+ <?php } ?>
70
+ <?php if($WRIS_L3_Navigation_Position == "bottom") { ?>
71
+ thumbnailsPosition: 'bottom',
72
+ <?php } ?>
73
+ <?php if($WRIS_L3_Thumbnail_Style == "pointer") { ?>
74
+ thumbnailPointer: true,
75
+ <?php } ?>
76
+ centerImage: true,
77
+ allowScaleUp: true,
78
+ <?php if($WRIS_L3_Slide_Order == "shuffle") { ?>
79
+ shuffle: true,
80
+ <?php } ?>
81
+ startSlide: 0,
82
+ loop: true,
83
+ slideDistance: <?php if($WRIS_L3_Slide_Distance) echo $WRIS_L3_Slide_Distance; else echo "5"; ?>,
84
+ autoplayDirection: 'normal',
85
+ touchSwipe: true,
86
+ fullScreen: <?php if($WRIS_L3_Fullscreeen == 1) echo "true"; else echo "false"; ?>,
87
  });
88
  });
89
  </script>
90
+ <script src="http://ajax.googleapis.com/ajax/libs/webfont/1/webfont.js"></script>
91
+ <script type="text/javascript">
92
+ WebFont.load({
93
+ google: {
94
+ families: ['<?php echo $RISP_Font_Style; ?>'] // saved value
95
+ }
96
+ });
97
+ </script>
98
  <style>
99
  /* Example 3 */
100
+
101
+ /* border */
102
+ <?php if($WRIS_L3_Thumbnail_Style == "border") { ?>
103
  #example3_<?php echo $post_id; ?> .sp-selected-thumbnail {
104
+ border: 4px solid <?php echo $WRIS_L3_Navigation_Pointer_Color; ?>;
105
  }
106
+ <?php } ?>
107
 
108
+ /* font + color */
109
+ .title-in {
110
+ font-family: <?php echo $WRIS_L3_Font_Style; ?> !important;
111
+ color: <?php echo $WRIS_L3_Title_Color; ?> !important;
112
+ background-color: <?php echo $WRIS_L3_Title_BgColor; ?> !important;
113
  opacity: 0.7 !important;
 
114
  }
115
+ .desc-in {
116
+ font-family: <?php echo $WRIS_L3_Font_Style; ?> !important;
117
+ color: <?php echo $WRIS_L3_Desc_Color; ?> !important;
118
+ background-color: <?php echo $WRIS_L3_Desc_BgColor; ?> !important;
119
  opacity: 0.7 !important;
 
 
120
  }
121
+
122
+ /* bullets color */
123
+ .sp-button {
124
+ border: 2px solid <?php echo $WRIS_L3_Navigation_Bullets_Color; ?> !important;
125
+ }
126
+ .sp-selected-button {
127
+ background-color: <?php echo $WRIS_L3_Navigation_Bullets_Color; ?> !important;
128
+ }
129
+
130
+ /* pointer color - bottom */
131
+ <?php if( $WRIS_L3_Navigation_Position == "bottom") { ?>
132
+ .sp-selected-thumbnail::before {
133
+ border-bottom: 5px solid <?php echo $WRIS_L3_Navigation_Pointer_Color; ?> !important;
134
+ }
135
+ .sp-selected-thumbnail::after {
136
+ border-bottom: 13px solid <?php echo $WRIS_L3_Navigation_Pointer_Color; ?> !important;
137
+ }
138
+ <?php } ?>
139
+
140
+ /* pointer color - top */
141
+ <?php if( $WRIS_L3_Navigation_Position == "top") { ?>
142
+
143
+ .sp-top-thumbnails.sp-has-pointer .sp-selected-thumbnail::before {
144
+ border-bottom: 5px solid <?php echo $WRIS_L3_Navigation_Pointer_Color; ?>;
145
+ }
146
+ .sp-top-thumbnails.sp-has-pointer .sp-selected-thumbnail::after {
147
+ border-top: 13px solid <?php echo $WRIS_L3_Navigation_Pointer_Color; ?> !important;
148
+ }
149
+ <?php } ?>
150
+
151
+
152
+ /* full screen icon */
153
+ .sp-full-screen-button::before {
154
+ color: <?php echo $WRIS_L3_Navigation_Color; ?> !important;
155
+ }
156
+
157
+ /* hover navigation icon color */
158
+ .sp-next-arrow::after, .sp-next-arrow::before {
159
+ background-color: <?php echo $WRIS_L3_Navigation_Color; ?> !important;
160
+ }
161
+ .sp-previous-arrow::after, .sp-previous-arrow::before {
162
+ background-color: <?php echo $WRIS_L3_Navigation_Color; ?> !important;
163
+ }
164
+
165
 
166
  #example3_<?php echo $post_id; ?> .title-in {
167
  color: <?php echo $RISP_Slide_In_Title_Color; ?> !important;
261
  <div class="sp-thumbnails">
262
  <?php
263
  foreach($RPGP_AllPhotosDetails as $RPGP_SinglePhotoDetails) {
264
+ $ThumbUrl = $RPGP_SinglePhotoDetails['rpggallery_admin_thumb'];
265
+ $j++;
266
+ ?>
267
+ <img class="sp-thumbnail" src="<?php echo $ThumbUrl; ?>"/>
268
  <?php } ?>
269
  </div>
270
  <?php } ?>