Addons for WPBakery Page Builder - Version 1.9.1

Version Description

  • Rolled back Update done to WayPoints script since WPBakery Page Builder is yet to upgrade to new version. Some reports have come in which suggests that the change broke some pages with certain WPBakery page builder elements.
Download this release

Release Info

Developer livemesh
Plugin Icon 128x128 Addons for WPBakery Page Builder
Version 1.9.1
Comparing to
See all releases

Code changes from version 1.8.2 to 1.9.1

Files changed (38) hide show
  1. admin/admin-init.php +6 -6
  2. admin/assets/css/lvca-admin.css +29 -20
  3. admin/assets/css/lvca-admin.css.map +1 -1
  4. admin/assets/css/lvca-admin.scss +30 -20
  5. admin/assets/images/logo-dark.png +0 -0
  6. admin/assets/images/logo-light.png +0 -0
  7. admin/notices/templates/rate.php +1 -1
  8. admin/views/admin-banner1.php +1 -1
  9. admin/views/admin-banner2.php +1 -1
  10. admin/views/admin-banner3.php +1 -1
  11. admin/views/documentation.php +83 -71
  12. admin/views/premium-upgrade.php +35 -35
  13. admin/views/settings.php +16 -16
  14. assets/js/isotope.pkgd.js +2960 -2960
  15. assets/js/isotope.pkgd.min.js +1 -1
  16. assets/js/jquery.waypoints.js +467 -467
  17. includes/addons/accordion/class-lvca-accordion.php +4 -4
  18. includes/addons/carousel/class-lvca-carousel.php +6 -6
  19. includes/addons/clients/class-lvca-clients.php +4 -4
  20. includes/addons/heading/class-lvca-heading.php +3 -3
  21. includes/addons/odometers/class-lvca-odometers.php +4 -4
  22. includes/addons/odometers/js/odometer.min.js +1 -1
  23. includes/addons/piecharts/class-lvca-piecharts.php +4 -4
  24. includes/addons/piecharts/js/piechart.min.js +1 -1
  25. includes/addons/portfolio/class-lvca-portfolio.php +11 -11
  26. includes/addons/posts-carousel/class-lvca-posts-carousel.php +3 -3
  27. includes/addons/pricing-table/class-lvca-pricing-table.php +4 -4
  28. includes/addons/services/class-lvca-services.php +4 -4
  29. includes/addons/spacer/class-lvca-spacer.php +3 -3
  30. includes/addons/stats-bar/class-lvca-stats-bar.php +4 -4
  31. includes/addons/stats-bar/js/stats-bar.min.js +1 -1
  32. includes/addons/tabs/class-lvca-tabs.php +4 -4
  33. includes/addons/team/class-lvca-team.php +5 -5
  34. includes/addons/testimonials-slider/class-lvca-testimonials-slider.php +5 -5
  35. includes/addons/testimonials/class-lvca-testimonials.php +5 -5
  36. includes/interfaces.php +1 -1
  37. livemesh-vc-addons.php +11 -11
  38. readme.txt +59 -49
admin/admin-init.php CHANGED
@@ -54,7 +54,7 @@ class LVCA_Admin {
54
 
55
  public function remove_admin_notices($screen) {
56
 
57
- // If this screen is Livemesh VC Addons plugin options page, remove annoying admin notices
58
  if (strpos($screen->id, $this->plugin_slug) !== false) {
59
  add_action('admin_notices', array(&$this, 'remove_notices_start'));
60
  add_action('admin_notices', array(&$this, 'remove_notices_end'), 999);
@@ -79,8 +79,8 @@ class LVCA_Admin {
79
  public function add_plugin_admin_menu() {
80
 
81
  add_menu_page(
82
- 'Visual Composer Addons',
83
- __('VC Addons', 'livemesh-vc-addons'),
84
  'manage_options',
85
  $this->plugin_slug,
86
  array($this, 'display_settings_page'),
@@ -90,7 +90,7 @@ class LVCA_Admin {
90
  // add plugin settings submenu page
91
  add_submenu_page(
92
  $this->plugin_slug,
93
- 'VC Addons Settings',
94
  __('Settings', 'livemesh-vc-addons'),
95
  'manage_options',
96
  $this->plugin_slug,
@@ -100,7 +100,7 @@ class LVCA_Admin {
100
  // add import/export submenu page
101
  add_submenu_page(
102
  $this->plugin_slug,
103
- 'VC Addons Documentation',
104
  __('Documentation', 'livemesh-vc-addons'),
105
  'manage_options',
106
  $this->plugin_slug . '_documentation',
@@ -159,7 +159,7 @@ class LVCA_Admin {
159
  // get current admin screen
160
  $screen = get_current_screen();
161
 
162
- // If screen is a part of Livemesh Visual Composer Addons plugin options page
163
  if (strpos($screen->id, $this->plugin_slug) !== false) {
164
 
165
  wp_enqueue_script('jquery-ui-datepicker');
54
 
55
  public function remove_admin_notices($screen) {
56
 
57
+ // If this screen is Livemesh Addons plugin options page, remove annoying admin notices
58
  if (strpos($screen->id, $this->plugin_slug) !== false) {
59
  add_action('admin_notices', array(&$this, 'remove_notices_start'));
60
  add_action('admin_notices', array(&$this, 'remove_notices_end'), 999);
79
  public function add_plugin_admin_menu() {
80
 
81
  add_menu_page(
82
+ 'WPBakery Page Builder Addons',
83
+ __('WPBakery Addons', 'livemesh-vc-addons'),
84
  'manage_options',
85
  $this->plugin_slug,
86
  array($this, 'display_settings_page'),
90
  // add plugin settings submenu page
91
  add_submenu_page(
92
  $this->plugin_slug,
93
+ 'WPBakery Page Builder Addons Settings',
94
  __('Settings', 'livemesh-vc-addons'),
95
  'manage_options',
96
  $this->plugin_slug,
100
  // add import/export submenu page
101
  add_submenu_page(
102
  $this->plugin_slug,
103
+ 'WPBakery Page Builder Addons Documentation',
104
  __('Documentation', 'livemesh-vc-addons'),
105
  'manage_options',
106
  $this->plugin_slug . '_documentation',
159
  // get current admin screen
160
  $screen = get_current_screen();
161
 
162
+ // If screen is a part of Livemesh WPBakery Page Builder Addons plugin options page
163
  if (strpos($screen->id, $this->plugin_slug) !== false) {
164
 
165
  wp_enqueue_script('jquery-ui-datepicker');
admin/assets/css/lvca-admin.css CHANGED
@@ -1,4 +1,10 @@
1
- /* =============== Visual Composer Elements ==================== */
 
 
 
 
 
 
2
  [class*=vc_element-icon][class*=icon-lvca-] {
3
  background-position: 0 0 !important;
4
  background-size: contain; }
@@ -7,31 +13,31 @@ input[type=number].wpb_vc_param_value.lvca_number {
7
  max-width: 100px;
8
  margin-right: 10px; }
9
 
10
- .icon-lvca-services.vc_element-icon {
11
  background-image: url(../images/admin/services.png); }
12
 
13
  .icon-lvca-service.vc_element-icon {
14
  background-image: url(../images/admin/service-add.png); }
15
 
16
- .icon-lvca-statsbars.vc_element-icon {
17
  background-image: url(../images/admin/stats-bar.png); }
18
 
19
  .icon-lvca-statsbar.vc_element-icon {
20
  background-image: url(../images/admin/stats-bar.png); }
21
 
22
- .icon-lvca-piecharts.vc_element-icon {
23
  background-image: url(../images/admin/piecharts.png); }
24
 
25
  .icon-lvca-piechart.vc_element-icon {
26
  background-image: url(../images/admin/piechart-add.png); }
27
 
28
- .icon-lvca-odometers.vc_element-icon {
29
  background-image: url(../images/admin/odometers.png); }
30
 
31
  .icon-lvca-odometer.vc_element-icon {
32
  background-image: url(../images/admin/odometer-add.png); }
33
 
34
- .icon-lvca-clients.vc_element-icon {
35
  background-image: url(../images/admin/clients.png); }
36
 
37
  .icon-lvca-client.vc_element-icon {
@@ -40,25 +46,25 @@ input[type=number].wpb_vc_param_value.lvca_number {
40
  .icon-lvca-heading.vc_element-icon {
41
  background-image: url(../images/admin/heading.png); }
42
 
43
- .icon-lvca-team.vc_element-icon {
44
  background-image: url(../images/admin/team.png); }
45
 
46
  .icon-lvca-team-member.vc_element-icon {
47
  background-image: url(../images/admin/team-member-add.png); }
48
 
49
- .icon-lvca-testimonials.vc_element-icon {
50
  background-image: url(../images/admin/testimonials.png); }
51
 
52
  .icon-lvca-testimonial.vc_element-icon {
53
  background-image: url(../images/admin/testimonial-add.png); }
54
 
55
- .icon-lvca-testimonials-slider.vc_element-icon {
56
  background-image: url(../images/admin/testimonials-slider.png); }
57
 
58
  .icon-lvca-testimonials-slide.vc_element-icon {
59
  background-image: url(../images/admin/testimonials-slider-add.png); }
60
 
61
- .icon-lvca-carousel.vc_element-icon {
62
  background-image: url(../images/admin/generic-carousel.png); }
63
 
64
  .icon-lvca-carousel-item.vc_element-icon {
@@ -70,7 +76,10 @@ input[type=number].wpb_vc_param_value.lvca_number {
70
  .icon-lvca-portfolio.vc_element-icon {
71
  background-image: url(../images/admin/grid-alt.png); }
72
 
73
- .icon-lvca-pricing-table.vc_element-icon {
 
 
 
74
  background-image: url(../images/admin/pricing-table.png); }
75
 
76
  .icon-lvca-pricing.vc_element-icon {
@@ -79,13 +88,13 @@ input[type=number].wpb_vc_param_value.lvca_number {
79
  .icon-lvca-spacer.vc_element-icon {
80
  background-image: url(../images/admin/spacer.png); }
81
 
82
- .icon-lvca-accordion.vc_element-icon {
83
  background-image: url(../images/admin/accordion.png); }
84
 
85
  .icon-lvca-panel.vc_element-icon {
86
  background-image: url(../images/admin/accordion-add.png); }
87
 
88
- .icon-lvca-tabs.vc_element-icon {
89
  background-image: url(../images/admin/tabs.png); }
90
 
91
  .icon-lvca-tab.vc_element-icon {
@@ -94,13 +103,13 @@ input[type=number].wpb_vc_param_value.lvca_number {
94
  .icon-lvca-countdown.vc_element-icon {
95
  background-image: url(../images/admin/countdown.png); }
96
 
97
- .icon-lvca-features.vc_element-icon {
98
  background-image: url(../images/admin/features.png); }
99
 
100
  .icon-lvca-feature-add.vc_element-icon {
101
  background-image: url(../images/admin/feature-add.png); }
102
 
103
- .icon-lvca-faq.vc_element-icon {
104
  background-image: url(../images/admin/faq.png); }
105
 
106
  .icon-lvca-faq-add.vc_element-icon {
@@ -109,28 +118,28 @@ input[type=number].wpb_vc_param_value.lvca_number {
109
  .icon-lvca-button.vc_element-icon {
110
  background-image: url(../images/admin/button.png); }
111
 
112
- .icon-lvca-gallery.vc_element-icon {
113
  background-image: url(../images/admin/gallery.png); }
114
 
115
  .icon-lvca-gallery-add.vc_element-icon {
116
  background-image: url(../images/admin/gallery-add.png); }
117
 
118
- .icon-lvca-gallery-carousel.vc_element-icon {
119
  background-image: url(../images/admin/carousel.png); }
120
 
121
- .icon-lvca-image-slider.vc_element-icon {
122
  background-image: url(../images/admin/sliders2.png); }
123
 
124
  .icon-lvca-image-slider-add.vc_element-icon {
125
  background-image: url(../images/admin/slider-add2.png); }
126
 
127
- .icon-lvca-slider.vc_element-icon {
128
  background-image: url(../images/admin/sliders.png); }
129
 
130
  .icon-lvca-slider-add.vc_element-icon {
131
  background-image: url(../images/admin/slider-add.png); }
132
 
133
- .icon-lvca-icons.vc_element-icon {
134
  background-image: url(../images/admin/icons.png); }
135
 
136
  .icon-lvca-icon-add.vc_element-icon {
1
+ .wrap.lvca-license-wrap form.lvca-license-box {
2
+ max-width: 700px;
3
+ background: white;
4
+ margin: 20px 0;
5
+ padding: 20px 30px; }
6
+
7
+ /* =============== WPBakery Page Builder Elements ==================== */
8
  [class*=vc_element-icon][class*=icon-lvca-] {
9
  background-position: 0 0 !important;
10
  background-size: contain; }
13
  max-width: 100px;
14
  margin-right: 10px; }
15
 
16
+ .icon-lvca-services.vc_element-icon[data-is-container=true] {
17
  background-image: url(../images/admin/services.png); }
18
 
19
  .icon-lvca-service.vc_element-icon {
20
  background-image: url(../images/admin/service-add.png); }
21
 
22
+ .icon-lvca-statsbars.vc_element-icon[data-is-container=true] {
23
  background-image: url(../images/admin/stats-bar.png); }
24
 
25
  .icon-lvca-statsbar.vc_element-icon {
26
  background-image: url(../images/admin/stats-bar.png); }
27
 
28
+ .icon-lvca-piecharts.vc_element-icon[data-is-container=true] {
29
  background-image: url(../images/admin/piecharts.png); }
30
 
31
  .icon-lvca-piechart.vc_element-icon {
32
  background-image: url(../images/admin/piechart-add.png); }
33
 
34
+ .icon-lvca-odometers.vc_element-icon[data-is-container=true] {
35
  background-image: url(../images/admin/odometers.png); }
36
 
37
  .icon-lvca-odometer.vc_element-icon {
38
  background-image: url(../images/admin/odometer-add.png); }
39
 
40
+ .icon-lvca-clients.vc_element-icon[data-is-container=true] {
41
  background-image: url(../images/admin/clients.png); }
42
 
43
  .icon-lvca-client.vc_element-icon {
46
  .icon-lvca-heading.vc_element-icon {
47
  background-image: url(../images/admin/heading.png); }
48
 
49
+ .icon-lvca-team.vc_element-icon[data-is-container=true] {
50
  background-image: url(../images/admin/team.png); }
51
 
52
  .icon-lvca-team-member.vc_element-icon {
53
  background-image: url(../images/admin/team-member-add.png); }
54
 
55
+ .icon-lvca-testimonials.vc_element-icon[data-is-container=true] {
56
  background-image: url(../images/admin/testimonials.png); }
57
 
58
  .icon-lvca-testimonial.vc_element-icon {
59
  background-image: url(../images/admin/testimonial-add.png); }
60
 
61
+ .icon-lvca-testimonials-slider.vc_element-icon[data-is-container=true] {
62
  background-image: url(../images/admin/testimonials-slider.png); }
63
 
64
  .icon-lvca-testimonials-slide.vc_element-icon {
65
  background-image: url(../images/admin/testimonials-slider-add.png); }
66
 
67
+ .icon-lvca-carousel.vc_element-icon[data-is-container=true] {
68
  background-image: url(../images/admin/generic-carousel.png); }
69
 
70
  .icon-lvca-carousel-item.vc_element-icon {
76
  .icon-lvca-portfolio.vc_element-icon {
77
  background-image: url(../images/admin/grid-alt.png); }
78
 
79
+ .icon-lvca-posts-block.vc_element-icon {
80
+ background-image: url(../images/admin/grid.png); }
81
+
82
+ .icon-lvca-pricing-table.vc_element-icon[data-is-container=true] {
83
  background-image: url(../images/admin/pricing-table.png); }
84
 
85
  .icon-lvca-pricing.vc_element-icon {
88
  .icon-lvca-spacer.vc_element-icon {
89
  background-image: url(../images/admin/spacer.png); }
90
 
91
+ .icon-lvca-accordion.vc_element-icon[data-is-container=true] {
92
  background-image: url(../images/admin/accordion.png); }
93
 
94
  .icon-lvca-panel.vc_element-icon {
95
  background-image: url(../images/admin/accordion-add.png); }
96
 
97
+ .icon-lvca-tabs.vc_element-icon[data-is-container=true] {
98
  background-image: url(../images/admin/tabs.png); }
99
 
100
  .icon-lvca-tab.vc_element-icon {
103
  .icon-lvca-countdown.vc_element-icon {
104
  background-image: url(../images/admin/countdown.png); }
105
 
106
+ .icon-lvca-features.vc_element-icon[data-is-container=true] {
107
  background-image: url(../images/admin/features.png); }
108
 
109
  .icon-lvca-feature-add.vc_element-icon {
110
  background-image: url(../images/admin/feature-add.png); }
111
 
112
+ .icon-lvca-faq.vc_element-icon[data-is-container=true] {
113
  background-image: url(../images/admin/faq.png); }
114
 
115
  .icon-lvca-faq-add.vc_element-icon {
118
  .icon-lvca-button.vc_element-icon {
119
  background-image: url(../images/admin/button.png); }
120
 
121
+ .icon-lvca-gallery.vc_element-icon[data-is-container=true] {
122
  background-image: url(../images/admin/gallery.png); }
123
 
124
  .icon-lvca-gallery-add.vc_element-icon {
125
  background-image: url(../images/admin/gallery-add.png); }
126
 
127
+ .icon-lvca-gallery-carousel.vc_element-icon[data-is-container=true] {
128
  background-image: url(../images/admin/carousel.png); }
129
 
130
+ .icon-lvca-image-slider.vc_element-icon[data-is-container=true] {
131
  background-image: url(../images/admin/sliders2.png); }
132
 
133
  .icon-lvca-image-slider-add.vc_element-icon {
134
  background-image: url(../images/admin/slider-add2.png); }
135
 
136
+ .icon-lvca-slider.vc_element-icon[data-is-container=true] {
137
  background-image: url(../images/admin/sliders.png); }
138
 
139
  .icon-lvca-slider-add.vc_element-icon {
140
  background-image: url(../images/admin/slider-add.png); }
141
 
142
+ .icon-lvca-icons.vc_element-icon[data-is-container=true] {
143
  background-image: url(../images/admin/icons.png); }
144
 
145
  .icon-lvca-icon-add.vc_element-icon {
admin/assets/css/lvca-admin.css.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["lvca-admin.scss"],"names":[],"mappings":"AAEA,mEAAmE;AAGnE;EACE,oCAAmC;EACnC,yBAAwB,EAAA;;AAG1B;EACE,iBAAgB;EAChB,mBAAkB,EAAA;;AAGpB;EACE,oDAAmD,EAAA;;AAGrD;EACE,uDAAsD,EAAA;;AAGxD;EACE,qDAAoD,EAAA;;AAGtD;EACE,qDAAoD,EAAA;;AAGtD;EACE,qDAAoD,EAAA;;AAGtD;EACE,wDAAuD,EAAA;;AAGzD;EACE,qDAAoD,EAAA;;AAGtD;EACE,wDAAuD,EAAA;;AAGzD;EACE,mDAAkD,EAAA;;AAGpD;EACE,sDAAqD,EAAA;;AAGvD;EACE,mDAAkD,EAAA;;AAGpD;EACE,gDAA+C,EAAA;;AAGjD;EACE,2DAA0D,EAAA;;AAG5D;EACE,wDAAuD,EAAA;;AAGzD;EACE,2DAA0D,EAAA;;AAG5D;EACE,+DAA8D,EAAA;;AAGhE;EACE,mEAAkE,EAAA;;AAGpE;EACE,4DAA2D,EAAA;;AAG7D;EACE,wDAAuD,EAAA;;AAGzD;EACE,0DAAyD,EAAA;;AAG3D;EACE,oDAAmD,EAAA;;AAGrD;EACE,yDAAwD,EAAA;;AAG1D;EACE,wDAAuD,EAAA;;AAGzD;EACE,kDAAiD,EAAA;;AAGnD;EACE,qDAAoD,EAAA;;AAGtD;EACE,yDAAwD,EAAA;;AAG1D;EACE,gDAA+C,EAAA;;AAGjD;EACE,mDAAkD,EAAA;;AAGpD;EACE,qDAAoD,EAAA;;AAGtD;EACE,oDAAmD,EAAA;;AAGrD;EACE,uDAAsD,EAAA;;AAGxD;EACE,+CAA8C,EAAA;;AAGhD;EACE,mDAAkD,EAAA;;AAGpD;EACE,kDAAiD,EAAA;;AAGnD;EACE,mDAAkD,EAAA;;AAGpD;EACE,uDAAsD,EAAA;;AAGxD;EACE,oDAAmD,EAAA;;AAGrD;EACE,oDAAmD,EAAA;;AAGrD;EACE,uDAAsD,EAAA;;AAGxD;EACE,mDAAkD,EAAA;;AAGpD;EACE,sDAAqD,EAAA;;AAGvD;EACE,iDAAgD,EAAA;;AAGlD;EACE,oDAAmD,EAAA","file":"lvca-admin.css"}
1
+ {"version":3,"sources":["lvca-admin.scss"],"names":[],"mappings":"AACA;EACE,iBAAgB;EAChB,kBAAiB;EACjB,eAAc;EACd,mBAAkB,EAAA;;AAGpB,yEAAyE;AAGzE;EACE,oCAAmC;EACnC,yBAAwB,EAAA;;AAG1B;EACE,iBAAgB;EAChB,mBAAkB,EAAA;;AAGpB;EACE,oDAAmD,EAAA;;AAGrD;EACE,uDAAsD,EAAA;;AAGxD;EACE,qDAAoD,EAAA;;AAGtD;EACE,qDAAoD,EAAA;;AAGtD;EACE,qDAAoD,EAAA;;AAGtD;EACE,wDAAuD,EAAA;;AAGzD;EACE,qDAAoD,EAAA;;AAGtD;EACE,wDAAuD,EAAA;;AAGzD;EACE,mDAAkD,EAAA;;AAGpD;EACE,sDAAqD,EAAA;;AAGvD;EACE,mDAAkD,EAAA;;AAGpD;EACE,gDAA+C,EAAA;;AAGjD;EACE,2DAA0D,EAAA;;AAG5D;EACE,wDAAuD,EAAA;;AAGzD;EACE,2DAA0D,EAAA;;AAG5D;EACE,+DAA8D,EAAA;;AAGhE;EACE,mEAAkE,EAAA;;AAGpE;EACE,4DAA2D,EAAA;;AAG7D;EACE,wDAAuD,EAAA;;AAGzD;EACE,0DAAyD,EAAA;;AAG3D;EACE,oDAAmD,EAAA;;AAGrD;EACE,gDAA+C,EAAA;;AAGjD;EACE,yDAAwD,EAAA;;AAG1D;EACE,wDAAuD,EAAA;;AAGzD;EACE,kDAAiD,EAAA;;AAGnD;EACE,qDAAoD,EAAA;;AAGtD;EACE,yDAAwD,EAAA;;AAG1D;EACE,gDAA+C,EAAA;;AAGjD;EACE,mDAAkD,EAAA;;AAGpD;EACE,qDAAoD,EAAA;;AAGtD;EACE,oDAAmD,EAAA;;AAGrD;EACE,uDAAsD,EAAA;;AAGxD;EACE,+CAA8C,EAAA;;AAGhD;EACE,mDAAkD,EAAA;;AAGpD;EACE,kDAAiD,EAAA;;AAGnD;EACE,mDAAkD,EAAA;;AAGpD;EACE,uDAAsD,EAAA;;AAGxD;EACE,oDAAmD,EAAA;;AAGrD;EACE,oDAAmD,EAAA;;AAGrD;EACE,uDAAsD,EAAA;;AAGxD;EACE,mDAAkD,EAAA;;AAGpD;EACE,sDAAqD,EAAA;;AAGvD;EACE,iDAAgD,EAAA;;AAGlD;EACE,oDAAmD,EAAA","file":"lvca-admin.css"}
admin/assets/css/lvca-admin.scss CHANGED
@@ -1,6 +1,12 @@
1
 
 
 
 
 
 
 
2
 
3
- /* =============== Visual Composer Elements ==================== */
4
 
5
 
6
  [class*=vc_element-icon][class*=icon-lvca-] {
@@ -13,7 +19,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
13
  margin-right: 10px;
14
  }
15
 
16
- .icon-lvca-services.vc_element-icon {
17
  background-image: url(../images/admin/services.png);
18
  }
19
 
@@ -21,7 +27,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
21
  background-image: url(../images/admin/service-add.png);
22
  }
23
 
24
- .icon-lvca-statsbars.vc_element-icon {
25
  background-image: url(../images/admin/stats-bar.png);
26
  }
27
 
@@ -29,7 +35,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
29
  background-image: url(../images/admin/stats-bar.png);
30
  }
31
 
32
- .icon-lvca-piecharts.vc_element-icon {
33
  background-image: url(../images/admin/piecharts.png);
34
  }
35
 
@@ -37,7 +43,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
37
  background-image: url(../images/admin/piechart-add.png);
38
  }
39
 
40
- .icon-lvca-odometers.vc_element-icon {
41
  background-image: url(../images/admin/odometers.png);
42
  }
43
 
@@ -45,7 +51,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
45
  background-image: url(../images/admin/odometer-add.png);
46
  }
47
 
48
- .icon-lvca-clients.vc_element-icon {
49
  background-image: url(../images/admin/clients.png);
50
  }
51
 
@@ -57,7 +63,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
57
  background-image: url(../images/admin/heading.png);
58
  }
59
 
60
- .icon-lvca-team.vc_element-icon {
61
  background-image: url(../images/admin/team.png);
62
  }
63
 
@@ -65,7 +71,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
65
  background-image: url(../images/admin/team-member-add.png);
66
  }
67
 
68
- .icon-lvca-testimonials.vc_element-icon {
69
  background-image: url(../images/admin/testimonials.png);
70
  }
71
 
@@ -73,7 +79,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
73
  background-image: url(../images/admin/testimonial-add.png);
74
  }
75
 
76
- .icon-lvca-testimonials-slider.vc_element-icon {
77
  background-image: url(../images/admin/testimonials-slider.png);
78
  }
79
 
@@ -81,7 +87,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
81
  background-image: url(../images/admin/testimonials-slider-add.png);
82
  }
83
 
84
- .icon-lvca-carousel.vc_element-icon {
85
  background-image: url(../images/admin/generic-carousel.png);
86
  }
87
 
@@ -97,7 +103,11 @@ input[type=number].wpb_vc_param_value.lvca_number {
97
  background-image: url(../images/admin/grid-alt.png);
98
  }
99
 
100
- .icon-lvca-pricing-table.vc_element-icon {
 
 
 
 
101
  background-image: url(../images/admin/pricing-table.png);
102
  }
103
 
@@ -109,7 +119,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
109
  background-image: url(../images/admin/spacer.png);
110
  }
111
 
112
- .icon-lvca-accordion.vc_element-icon {
113
  background-image: url(../images/admin/accordion.png);
114
  }
115
 
@@ -117,7 +127,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
117
  background-image: url(../images/admin/accordion-add.png);
118
  }
119
 
120
- .icon-lvca-tabs.vc_element-icon {
121
  background-image: url(../images/admin/tabs.png);
122
  }
123
 
@@ -129,7 +139,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
129
  background-image: url(../images/admin/countdown.png);
130
  }
131
 
132
- .icon-lvca-features.vc_element-icon {
133
  background-image: url(../images/admin/features.png);
134
  }
135
 
@@ -137,7 +147,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
137
  background-image: url(../images/admin/feature-add.png);
138
  }
139
 
140
- .icon-lvca-faq.vc_element-icon {
141
  background-image: url(../images/admin/faq.png);
142
  }
143
 
@@ -149,7 +159,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
149
  background-image: url(../images/admin/button.png);
150
  }
151
 
152
- .icon-lvca-gallery.vc_element-icon {
153
  background-image: url(../images/admin/gallery.png);
154
  }
155
 
@@ -157,11 +167,11 @@ input[type=number].wpb_vc_param_value.lvca_number {
157
  background-image: url(../images/admin/gallery-add.png);
158
  }
159
 
160
- .icon-lvca-gallery-carousel.vc_element-icon {
161
  background-image: url(../images/admin/carousel.png);
162
  }
163
 
164
- .icon-lvca-image-slider.vc_element-icon {
165
  background-image: url(../images/admin/sliders2.png);
166
  }
167
 
@@ -169,7 +179,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
169
  background-image: url(../images/admin/slider-add2.png);
170
  }
171
 
172
- .icon-lvca-slider.vc_element-icon {
173
  background-image: url(../images/admin/sliders.png);
174
  }
175
 
@@ -177,7 +187,7 @@ input[type=number].wpb_vc_param_value.lvca_number {
177
  background-image: url(../images/admin/slider-add.png);
178
  }
179
 
180
- .icon-lvca-icons.vc_element-icon {
181
  background-image: url(../images/admin/icons.png);
182
  }
183
 
1
 
2
+ .wrap.lvca-license-wrap form.lvca-license-box {
3
+ max-width: 700px;
4
+ background: white;
5
+ margin: 20px 0;
6
+ padding: 20px 30px;
7
+ }
8
 
9
+ /* =============== WPBakery Page Builder Elements ==================== */
10
 
11
 
12
  [class*=vc_element-icon][class*=icon-lvca-] {
19
  margin-right: 10px;
20
  }
21
 
22
+ .icon-lvca-services.vc_element-icon[data-is-container=true] {
23
  background-image: url(../images/admin/services.png);
24
  }
25
 
27
  background-image: url(../images/admin/service-add.png);
28
  }
29
 
30
+ .icon-lvca-statsbars.vc_element-icon[data-is-container=true] {
31
  background-image: url(../images/admin/stats-bar.png);
32
  }
33
 
35
  background-image: url(../images/admin/stats-bar.png);
36
  }
37
 
38
+ .icon-lvca-piecharts.vc_element-icon[data-is-container=true] {
39
  background-image: url(../images/admin/piecharts.png);
40
  }
41
 
43
  background-image: url(../images/admin/piechart-add.png);
44
  }
45
 
46
+ .icon-lvca-odometers.vc_element-icon[data-is-container=true] {
47
  background-image: url(../images/admin/odometers.png);
48
  }
49
 
51
  background-image: url(../images/admin/odometer-add.png);
52
  }
53
 
54
+ .icon-lvca-clients.vc_element-icon[data-is-container=true] {
55
  background-image: url(../images/admin/clients.png);
56
  }
57
 
63
  background-image: url(../images/admin/heading.png);
64
  }
65
 
66
+ .icon-lvca-team.vc_element-icon[data-is-container=true] {
67
  background-image: url(../images/admin/team.png);
68
  }
69
 
71
  background-image: url(../images/admin/team-member-add.png);
72
  }
73
 
74
+ .icon-lvca-testimonials.vc_element-icon[data-is-container=true] {
75
  background-image: url(../images/admin/testimonials.png);
76
  }
77
 
79
  background-image: url(../images/admin/testimonial-add.png);
80
  }
81
 
82
+ .icon-lvca-testimonials-slider.vc_element-icon[data-is-container=true] {
83
  background-image: url(../images/admin/testimonials-slider.png);
84
  }
85
 
87
  background-image: url(../images/admin/testimonials-slider-add.png);
88
  }
89
 
90
+ .icon-lvca-carousel.vc_element-icon[data-is-container=true] {
91
  background-image: url(../images/admin/generic-carousel.png);
92
  }
93
 
103
  background-image: url(../images/admin/grid-alt.png);
104
  }
105
 
106
+ .icon-lvca-posts-block.vc_element-icon {
107
+ background-image: url(../images/admin/grid.png);
108
+ }
109
+
110
+ .icon-lvca-pricing-table.vc_element-icon[data-is-container=true] {
111
  background-image: url(../images/admin/pricing-table.png);
112
  }
113
 
119
  background-image: url(../images/admin/spacer.png);
120
  }
121
 
122
+ .icon-lvca-accordion.vc_element-icon[data-is-container=true] {
123
  background-image: url(../images/admin/accordion.png);
124
  }
125
 
127
  background-image: url(../images/admin/accordion-add.png);
128
  }
129
 
130
+ .icon-lvca-tabs.vc_element-icon[data-is-container=true] {
131
  background-image: url(../images/admin/tabs.png);
132
  }
133
 
139
  background-image: url(../images/admin/countdown.png);
140
  }
141
 
142
+ .icon-lvca-features.vc_element-icon[data-is-container=true] {
143
  background-image: url(../images/admin/features.png);
144
  }
145
 
147
  background-image: url(../images/admin/feature-add.png);
148
  }
149
 
150
+ .icon-lvca-faq.vc_element-icon[data-is-container=true] {
151
  background-image: url(../images/admin/faq.png);
152
  }
153
 
159
  background-image: url(../images/admin/button.png);
160
  }
161
 
162
+ .icon-lvca-gallery.vc_element-icon[data-is-container=true] {
163
  background-image: url(../images/admin/gallery.png);
164
  }
165
 
167
  background-image: url(../images/admin/gallery-add.png);
168
  }
169
 
170
+ .icon-lvca-gallery-carousel.vc_element-icon[data-is-container=true] {
171
  background-image: url(../images/admin/carousel.png);
172
  }
173
 
174
+ .icon-lvca-image-slider.vc_element-icon[data-is-container=true] {
175
  background-image: url(../images/admin/sliders2.png);
176
  }
177
 
179
  background-image: url(../images/admin/slider-add2.png);
180
  }
181
 
182
+ .icon-lvca-slider.vc_element-icon[data-is-container=true] {
183
  background-image: url(../images/admin/sliders.png);
184
  }
185
 
187
  background-image: url(../images/admin/slider-add.png);
188
  }
189
 
190
+ .icon-lvca-icons.vc_element-icon[data-is-container=true] {
191
  background-image: url(../images/admin/icons.png);
192
  }
193
 
admin/assets/images/logo-dark.png CHANGED
Binary file
admin/assets/images/logo-light.png CHANGED
Binary file
admin/notices/templates/rate.php CHANGED
@@ -4,7 +4,7 @@
4
 
5
  <div class="lvca-notice-rate-content">
6
 
7
- <p><?php _e( 'Hello!', 'livemesh-vc-addons' ); ?> <?php _e( 'I see that you have the plugin <strong>Addons for Visual Composer by Livemesh</strong> installed for some time now.', 'livemesh-vc-addons' ); ?></p>
8
  <p><?php _e( 'If you like this plugin, please write a few words about it at wordpress.org or social media. Your opinion will help others discover our plugin.', 'livemesh-vc-addons' ); ?></p>
9
  <p><?php _e( 'Thank you!', 'livemesh-vc-addons' ); ?></p>
10
 
4
 
5
  <div class="lvca-notice-rate-content">
6
 
7
+ <p><?php _e( 'Hello!', 'livemesh-vc-addons' ); ?> <?php _e( 'I see that you have the plugin <strong>Addons for WPBakery Page Builder by Livemesh</strong> installed for some time now.', 'livemesh-vc-addons' ); ?></p>
8
  <p><?php _e( 'If you like this plugin, please write a few words about it at wordpress.org or social media. Your opinion will help others discover our plugin.', 'livemesh-vc-addons' ); ?></p>
9
  <p><?php _e( 'Thank you!', 'livemesh-vc-addons' ); ?></p>
10
 
admin/views/admin-banner1.php CHANGED
@@ -10,7 +10,7 @@ if (!defined('ABSPATH')) {
10
  <div id="lvca-banner-wrap">
11
 
12
  <div id="lvca-banner" class="lvca-banner-sticky">
13
- <h2><span><?php echo __('Visual Composer Addons', 'livemesh-vc-addons'); ?></span><?php echo __('Plugin Documentation', 'livemesh-vc-addons') ?></h2>
14
  </div>
15
 
16
  </div>
10
  <div id="lvca-banner-wrap">
11
 
12
  <div id="lvca-banner" class="lvca-banner-sticky">
13
+ <h2><span><?php echo __('WPBakery Builder Addons', 'livemesh-vc-addons'); ?></span><?php echo __('Plugin Documentation', 'livemesh-vc-addons') ?></h2>
14
  </div>
15
 
16
  </div>
admin/views/admin-banner2.php CHANGED
@@ -10,7 +10,7 @@ if (!defined('ABSPATH')) {
10
  <div id="lvca-banner-wrap">
11
 
12
  <div id="lvca-banner" class="lvca-banner-sticky">
13
- <h2><span><?php echo __('Visual Composer Addons', 'livemesh-vc-addons'); ?></span><?php echo __('Plugin Settings', 'livemesh-vc-addons') ?></h2>
14
  <div id="lvca-buttons-wrap">
15
  <a class="lvca-button" data-action="lvca_save_settings" id="lvca_settings_save"><i
16
  class="dashicons dashicons-yes"></i><?php echo __('Save Settings', 'livemesh-vc-addons') ?></a>
10
  <div id="lvca-banner-wrap">
11
 
12
  <div id="lvca-banner" class="lvca-banner-sticky">
13
+ <h2><span><?php echo __('WPBakery Builder Addons', 'livemesh-vc-addons'); ?></span><?php echo __('Plugin Settings', 'livemesh-vc-addons') ?></h2>
14
  <div id="lvca-buttons-wrap">
15
  <a class="lvca-button" data-action="lvca_save_settings" id="lvca_settings_save"><i
16
  class="dashicons dashicons-yes"></i><?php echo __('Save Settings', 'livemesh-vc-addons') ?></a>
admin/views/admin-banner3.php CHANGED
@@ -10,7 +10,7 @@ if (!defined('ABSPATH')) {
10
  <div id="lvca-banner-wrap">
11
 
12
  <div id="lvca-banner" class="lvca-banner-sticky">
13
- <h2><span><?php echo __('Addons for Visual Composer', 'livemesh-vc-addons'); ?></span><?php echo __('Premium Upgrade', 'livemesh-vc-addons') ?></h2>
14
  </div>
15
 
16
  </div>
10
  <div id="lvca-banner-wrap">
11
 
12
  <div id="lvca-banner" class="lvca-banner-sticky">
13
+ <h2><span><?php echo __('Addons for WPBakery Page Builder', 'livemesh-vc-addons'); ?></span><?php echo __('Premium Upgrade', 'livemesh-vc-addons') ?></h2>
14
  </div>
15
 
16
  </div>
admin/views/documentation.php CHANGED
@@ -26,7 +26,7 @@ else {
26
 
27
  <div class="intro-wrap">
28
 
29
- <img class="plugin-image" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/plugin-screenshot.jpg" alt="Addons for Visual Composer">
30
 
31
  <div class="intro">
32
  <h3><?php printf(__('Getting started with %1$s v%2$s', 'livemesh-vc-addons'), $plugin['Name'], $plugin['Version']); ?></h3>
@@ -76,7 +76,7 @@ else {
76
  <li><a href="#testimonials-elements">Testimonials Addons</a></li>
77
  <li><a href="#posts-carousel">Posts Carousel</a></li>
78
  <li><a href="#carousel-element">Carousel Addon</a></li>
79
- <li><a href="#grid-element">Livemesh Grid</a></li>
80
  <li><a href="#clients-element">Clients</a></li>
81
  <li><a href="#pricing-table">Pricing Table</a></li>
82
  <li><a href="#tabs-accordions">Tabs and Accordions</a></li>
@@ -91,40 +91,40 @@ else {
91
  </ul>
92
  <h3 id="getting-started">Getting Started<a class="back-to-top" href="#panel"><span
93
  class="dashicons dashicons-arrow-up-alt2"></span> Back to top</a></h3>
94
- <p>Thanks for choosing Addons for Visual Composer plugin. This help file aims to provide you with all the information you need to make the best use of this powerful plugin. The aim of the plugin to make the task of building a website effortless and pleasurable. Towards that end, we have built a number of elements most commonly used across most of the websites of small businesses, corporates, design agencies, freelancers, artists etc.</p>
95
  <p>Do follow the steps below to get started - </p>
96
  <ol>
97
  <li>Install and activate the <strong>required plugin</strong> <a
98
- href="https://codecanyon.net/item/visual-composer-page-builder-for-wordpress/242431?ref=livemesh" rel="nofollow" target="_blank">Visual Composer</a>.
99
- Visual Composer is a premium WordPress page builder plugin available for purchase from <a
100
  href="https://codecanyon.net/item/visual-composer-page-builder-for-wordpress/242431?ref=livemesh" rel="nofollow" target="_blank">CodeCanyon</a>.
101
  With over 1.5m installed sites, VC is certainly the most popular page builder plugin for WordPress.
102
  </li>
103
  <li>Unzip the downloaded addons-for-visual-composer.zip file and upload to the <code>/wp-content/plugins/</code>
104
  directory or upload the plugin zip with the help of Plugins→Installed Plugins→Add New button.<br>
105
  Activate the plugin through the 'Plugins' menu in WordPress. If you are viewing this help page
106
- in WordPress admin under VC Addons→Documentation, you have already activated the plugin.
107
  </li>
108
  <li>Once the plugin is activated, all of the elements part of the plugin are available in Visual
109
- Composer 'Add Element' window, grouped under 'Livemesh VC Addons' tab.
110
 
111
- <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/add-element-window.png" alt="Visual Composer Addons Add Element Window"></p>
112
 
113
 
114
  <p>Once you are done with developing the site, for performance gains, you can selectively deactivate
115
  the unused elements in 'Elements' tab of
116
  <strong> <a href="<?php echo admin_url() . 'admin.php?page=livemesh_vc_addons'; ?>"
117
- target="_blank"><?php echo __('VC Addons→Settings', 'livemesh-vc-addons') ?></a></strong>
118
  page. This will ensure that scripts and files relating to the deactivated elements do not load on your site.</p>
119
  </li>
120
- <li>If you plan to build a portfolio site and plan to use Livemesh Grid element for the same, install
121
  and activate the optional plugin <a
122
  href="https://wordpress.org/plugins/portfolio-post-type/" rel="nofollow" target="_blank">Portfolio
123
  Post Type</a>.
124
- The portfolio examples of Livemesh Grid element is built using custom post type registered by
125
  this plugin.
126
  </li>
127
- <li>Optionally, if you have <a href="https://www.livemeshthemes.com/visual-composer-addons/pricing/" title="Addons for Visual Composer Pro" target="_blank">premium version</a> of the plugin installed, you can import the sample data
128
  that replicates the demo site for you by importing the
129
  file sample-data.xml file located in the plugin directory. The import option is available under
130
  <strong> <a href="<?php echo admin_url() . 'import.php'; ?>"
@@ -140,22 +140,22 @@ else {
140
  <p>Below is a list of required/recommended plugins to install that will help you get the most out of this plugin.
141
  Although some of these plugins are optional, we recommend that you install these popular plugins if
142
  you plan to install the demo data and get most out of this plugin. The demo site and the sample data
143
- provided with the <a href="https://www.livemeshthemes.com/visual-composer-addons/pricing/"
144
- title="Addons for Visual Composer Pro" target="_blank">premium version</a> of
145
  the plugin utilizes all of these plugins including the Portfolio Post type plugin.</p>
146
- <p>These plugins are also listed in the Plugins tab of this help file under VC Addons →
147
  Documentation, and you can install the plugins directly from there.</p>
148
  <ul>
149
- <li><p><strong>Visual Composer</strong> is perhaps the most popular page builder tool for WordPress powering
150
  over 1.5+ million sites. You can build any layout you can imagine with intuitive drag and drop builder
151
  with little or no programming knowledge.</p>
152
- <p>All of the elements part of Addons for Visual Composer plugin were built using the API provided
153
- by the Visual Composer plugin and hence this plugin must be installed and activated on the site prior
154
  to using our plugin.</p>
155
  <p>All of the pages of our demo site for
156
  the plugin have been built using this page builder. You should install and activate this plugin
157
  prior to replicating the plugin demo site by importing the sample data provided.</p>
158
- <p><a href="<?php echo esc_url($visualComposerUrl); ?>" target="_blank">More about Visual Composer →</a></p></li>
159
  <li><strong>Portfolio Post Type</strong> is a free plugin that registers a custom post type for
160
  portfolio items. It also registers separate portfolio taxonomies for tags and categories. The
161
  Portfolio grid instances showcased on our demo site was built using custom post types registered
@@ -167,7 +167,7 @@ else {
167
  <hr>
168
  <h3 id="demo-data">Installing Demo Data<a class="back-to-top" href="#panel"><span
169
  class="dashicons dashicons-arrow-up-alt2"></span> Back to top</a></h3>
170
- <p>If you have <a href="https://www.livemeshthemes.com/visual-composer-addons/pricing/" title="Addons for Visual Composer Pro" target="_blank">premium version</a> of the plugin installed, you can install the demo data to replicate the
171
  plugin demo site to get a head start on building your site. Installing demo data reduces the
172
  learning curve associated with trying out the powerful elements part of this plugin.</p>
173
  <p>The sample data imports the pages, posts and portfolio items part of the demo site. Once you are done with playing around the
@@ -185,35 +185,35 @@ else {
185
  class="dashicons dashicons-arrow-up-alt2"></span> Back to top</a></h3>
186
 
187
  <ul>
188
- <li>If you are new to drag and drop page building functions of <a href="<?php echo esc_url($visualComposerUrl); ?>" target="_blank">Visual Composer</a> and need help, make sure you checkout the <a
189
  href="https://wpbakery.atlassian.net/wiki/display/VC/Visual+Composer+Pagebuilder+for+WordPress"
190
- title="Visual Composer Documentation" target="_blank">documentation of the Visual Composer</a> before
191
  starting to use this plugin. The site has numerous text as well as video tutorials to help you
192
  get a head start on using the plugin.
193
  </li>
194
 
195
- <li>Once the Addons for Visual Composer plugin is activated, you should see a menu item <strong> <a href="<?php echo admin_url() . 'admin.php?page=livemesh_vc_addons'; ?>"
196
- target="_blank"><?php echo __('VC Addons', 'livemesh-vc-addons') ?></a></strong> in WordPress admin with four sections - Settings, Elements, Debugging and Premium Upgrade.
197
- <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/plugin-settings.png" alt="Visual Composer Addons Settings"></p>
198
 
199
  <p>The settings screen <strong> <a href="<?php echo admin_url() . 'admin.php?page=livemesh_vc_addons'; ?>"
200
- target="_blank"><?php echo __('VC Addons→Settings', 'livemesh-vc-addons') ?></a></strong> for the plugin is self-documenting with minimal
201
  options. Make sure you choose the theme color scheme in the 'General' tab to help ensure the plugin takes this as the default color for elements like buttons and links which have default color set.</p>
202
  <p>During the development phase, it is recommended to not have any of the elements deactivated in the 'Elements' tab of the settings screen.</p>
203
 
204
  </li>
205
 
206
- <li>Once the Addons for Visual Composer plugin is activated, all of the elements built by the plugin become available for drag and drop in the Visual Composer. In
207
  the Page edit window, click on the <strong>'Backend Editor'</strong> button below the title field of the page edit window to bring up the page builder controls on
208
  the page edit screen.
209
- <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/page-builder-screen.png" alt="Visual Composer Page Builder Screen"></p>
210
  </li>
211
 
212
- <li>To add a Livemesh VC addon element, just click on the <strong>'Add Element'</strong> button to bring up the 'Add Element'
213
- popup screen of the page builder. The plugin elements are grouped under <strong>'Livemesh VC
214
  Addons'</strong> tab on the top. Clicking on a element listed in the popup adds the
215
  element to the page builder.
216
- <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/add-element-window.png" alt="Visual Composer Page Builder Addons"></p>
217
  </li>
218
 
219
  <li>Hovering over the element added to the page builder, you can view the Edit link. Clicking the
@@ -223,18 +223,18 @@ else {
223
 
224
  <p>Once the data required for configuring a element is entered, you can save the changes by
225
  clicking on the <strong>'Save Changes'</strong> button for the element.</p>
226
- <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/addon-edit-screen.png" alt="Visual Composer Element Edit Window"></p>
227
 
228
  </li>
229
 
230
  <li>Many of the plugin elements part of this plugin are container elements that involve a child element to be added to the it. For eg., Team element needs multiple team member elements
231
  added to it, Testimonials element is made of multiple child testiominial elements, Services element require that you add multiple service elements individually to make up the list of services.
232
 
233
- <p>The container elements are listed under 'Livemesh VC Addons' tab in the 'Add Element' popup screen. Once you add a container element (e.g., Livemesh Testimonials,
234
- Livemesh Servies, Livemesh FAQ, Livemesh Features, Livemesh Team etc.), the element display a big plus(+) icon in the page to help add child elements. Clicking on the plus(+) button
235
  brings up child element editor popup window. Once you configure and save changes to the child element, the element gets added to the page builder window as contained
236
  element part of the parent container element as seen below.</p>
237
- <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/page-builder-screen.png" alt="Visual Composer Addon Edit Window"></p>
238
 
239
  <p>In the page edit screen of the page builder, while the settings for the container element itself can be changed by clicking on the edit icon at the top of the element added,
240
  the child elements can be edited by clicking on the edit option available upon hovering over the child elements in the page edit window.</p>
@@ -243,14 +243,14 @@ else {
243
 
244
  <li>After you hit the <strong>Update</strong> or <strong>Publish</strong> button on the page,the element is then ready for viewing on
245
  the frontend page.
246
- <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/addon-rendered.png" alt="Visual Composer Addon Rendered"></p>
247
 
248
  </li>
249
 
250
  </ul>
251
 
252
 
253
- <p>The below sections provide help on each of the elements built as part of Addons for Visual Composer
254
  plugin.</p>
255
 
256
  <hr>
@@ -281,7 +281,7 @@ else {
281
  <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/services-addon-edit.png" alt="Services Addon Container Element"></p>
282
  <p>The services element is a container element that requires you to input multiple child service elements
283
  that make up the list of services offered by a business or a community.</p>
284
- <p>The element supports about 3 different styles (with 2 additional styles in <a href="https://www.livemeshthemes.com/visual-composer-addons/pricing/" title="Addons for Visual Composer Pro" target="_blank">premium version</a> of the
285
  plugin) and each of these styles can be customized further by choosing the type of icon desired to
286
  represent the service – a font icon or an custom image icon. While the choice of font icons is huge
287
  in number and perhaps sufficient for most common services, the icon images can help present the
@@ -298,7 +298,7 @@ else {
298
  <li><strong>Icon Custom Hover Color</strong> – Specify a custom hover color for the font icon.</li>
299
  </ul>
300
 
301
- <p>The <a href="https://www.livemeshthemes.com/visual-composer-addons/pricing/" title="Addons for Visual Composer Pro" target="_blank">premium version</a> of the plugin allows you specify a custom font size, font color and and hover
302
  color for the font icon along with providing two additional styles of services/features.</p>
303
 
304
 
@@ -316,9 +316,9 @@ else {
316
 
317
  <p>This element provides an easy way to capture the team members of your organization or an agency.</p>
318
  <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/team-members-edit.png" alt="Team Members Addon Container Element"></p>
319
- <p>The Livemesh Team element is a container element that requires you to input multiple child elements for
320
  team members that are part of the team/organization.</p>
321
- <p>Two different styles are provided with more styles planned in the <a href="https://www.livemeshthemes.com/visual-composer-addons/pricing/" title="Addons for Visual Composer Pro" target="_blank">premium version</a> of the plugin. Most
322
  of the styles display the team members in a multi-column grid. The option to specify the number of
323
  columns is provided that helps to control the number of team members displayed per row of the team
324
  members.</p>
@@ -333,7 +333,7 @@ else {
333
  <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/statsbars-piecharts.png" alt="Statistics Addons"></p>
334
 
335
  <p>The plugin features a number of elements that help display statistical information in the form of
336
- odometers, piecharts and stats bars. The <a href="https://www.livemeshthemes.com/visual-composer-addons/pricing/" title="Addons for Visual Composer Pro" target="_blank">premium version</a> of the plugin also includes a countdown
337
  element that displays a countdown timer for planned events such as product launches or website going
338
  live.</p>
339
 
@@ -431,7 +431,7 @@ else {
431
  <li><strong>Post Count</strong> – Set the number of posts you wish you display in the element. If
432
  the element does not support pagination, the number of posts displayed is limited by the number
433
  specified here. This is also the number of posts to display per page when the element supports
434
- pagination as is the case with Livemesh Grid element. Enter "All" to display all posts.
435
  </li>
436
  <li><strong>Order By</strong> – Specify the order of the posts displayed - by post date, title, modified date, author
437
  menu order, comment count etc.
@@ -516,7 +516,7 @@ else {
516
  <h3 id="carousel-element">Carousel<a class="back-to-top" href="#panel"> Back to top</a></h3>
517
  <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/generic-carousel.jpg" alt="Generic Carousel Addon"></p>
518
 
519
- <p>Livemesh Carousel is a generic carousel of custom HTML content of your choice. Possibilities are endless – image
520
  carousels with textual content describing the images, video carousels, event carousels with link to
521
  the events, a carousel of team of volunteers, a collection of books sold on Amazon etc.</p>
522
  <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-carousel-edit.png" alt="Generic Carousel Addon Edit Window"></p>
@@ -534,26 +534,26 @@ else {
534
  for carousel, number of columns or items to display before making the user to scroll for additional
535
  items etc. The carousel settings are explained in the help section above for Posts Carousel.</p>
536
  <hr>
537
- <h3 id="grid-element">Livemesh Grid<a class="back-to-top" href="#panel"> Back to top</a></h3>
538
- <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid.jpg" alt="Livemesh Grid Addon"></p>
539
 
540
  <p>Perhaps the most popular and most important of all elements part of all elements part of this plugin,
541
- Livemesh Grid helps you build a multi-column grid of posts or custom post types. The posts displayed
542
  are filterable by taxonomy terms.</p>
543
 
544
- <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid2.jpg" alt="Livemesh Grid Addon"></p>
545
  <p>Using the Grid element, you can construct a portfolio of your work/services/products. We recommend you
546
  use the popular plugin – <a title="Portfolio Post Type Plugin"
547
  href="https://wordpress.org/plugins/portfolio-post-type/">https://wordpress.org/plugins/portfolio-post-type/</a>
548
  for building a collection of portfolio entries. Once the portfolio entries are in place, make sure
549
  you select Portfolio Post type under Post Type entry in Build Tools window as explained below.</p>
550
 
551
- <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid-pagination.jpg" alt="Livemesh Grid Pagination"></p>
552
- <p>The <a href="https://www.livemeshthemes.com/visual-composer-addons/pricing/" title="Addons for Visual Composer Pro" target="_blank">premium version</a> of the plugin has support for pagination, lazy load with load more button and
553
  lightbox option for images. The additional posts are loaded via AJAX when the user navigates through
554
  the pages populated or when the user hits the Load More button.</p>
555
 
556
- <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid-loadmore.jpg" alt="Livemesh Grid AJAX Load More"></p>
557
 
558
  <p>The element features a Posts Query section to help choose posts or custom posts to display. This
559
  powerful tool has number of fields to control what gets displayed and in what order.</p>
@@ -567,7 +567,7 @@ else {
567
  <li><strong>Post Count</strong> – Set the number of posts you wish you display in the element. If
568
  the element does not support pagination, the number of posts displayed is limited by the number
569
  specified here. This is also the number of posts to display per page when the element supports
570
- pagination as is the case with Livemesh Grid element. Enter "All" to display all posts.
571
  </li>
572
  <li><strong>Order By</strong> – Specify the order of the posts displayed - by post date, title, modified date, author
573
  menu order, comment count etc.
@@ -591,12 +591,12 @@ else {
591
  use this field to specify the chosen authors here by specifying their names.
592
  </li>
593
  </ol>
594
- <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid-edit1.png" alt="Livemesh Grid Edit Window"></p>
595
- <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid-edit2.png" alt="Livemesh Grid Edit Window"></p>
596
 
597
- <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid-edit3.png" alt="Livemesh Grid Edit Window"></p>
598
 
599
- <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid-edit4.png" alt="Livemesh Grid Edit Window"></p>
600
 
601
 
602
  <p>The grid element has numerous other options to control the display of posts or custom post types. Some
@@ -776,8 +776,8 @@ else {
776
  <p>You can choose to display an icon along with the button text. The icon can be a icon font or an
777
  image.</p>
778
  <p>The element options are mostly self-explanatory and you can view a live preview of the buttons <a
779
- title="Visual Composer Button Addon Demo"
780
- href="https://www.livemeshthemes.com/visual-composer-addons/buttons/">here</a>.</p>
781
 
782
 
783
  <hr>
@@ -928,7 +928,7 @@ else {
928
  video tutorial sites, video marketers, small businesses or websites with a major presence on
929
  YouTube/Vimeo. The videos can be played with a single click of the play button on the gallery item
930
  as seen in this <a title="Video Gallery"
931
- href="https://www.livemeshthemes.com/visual-composer-addons/video-gallery/">demo page</a>.
932
  </p>
933
  <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/image-gallery-edit1.png" alt="Image Gallery Addon Edit Window"></p>
934
  <p>The image gallery element is a container element that requires you to add child elements representing gallery items.</p>
@@ -995,7 +995,7 @@ else {
995
  video tutorial sites, video marketers, small businesses or websites with a major presence on
996
  YouTube/Vimeo. The videos can be played with a single click of the play button on the gallery item
997
  as seen in this <a title="Video Gallery"
998
- href="https://www.livemeshthemes.com/visual-composer-addons/video-gallery/">demo page</a>.
999
  </p>
1000
  <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/image-carousel-edit1.png" alt="Image Carousel Addon Edit Window"></p>
1001
 
@@ -1116,14 +1116,14 @@ else {
1116
  <div id="plugins-panel" class="panel-left">
1117
  <h4>Required/Recommended Plugins</h4>
1118
 
1119
- <p>Below is a list of required/recommended plugins to install that will help you get the most out of the plugin. While Visual Composer plugin is required, the rest of the plugins are optional but we recommend you install these plugins if you plan to replicate the plugin demo site by importing the sample data.</p>
1120
 
1121
  <hr/>
1122
 
1123
- <h4><?php _e('Visual Composer', 'livemesh-vc-addons'); ?>
1124
  <?php if (!class_exists('Vc_Manager')) { ?>
1125
  <a class="button button-secondary thickbox onclick" href="<?php echo esc_url($visualComposerUrl); ?>"
1126
- title="<?php esc_attr_e('Install Visual Composer', 'livemesh-vc-addons'); ?>"><span
1127
  class="dashicons dashicons-download"></span> <?php _e('Install Now', 'livemesh-vc-addons'); ?></a>
1128
  <?php }
1129
  else { ?>
@@ -1132,11 +1132,11 @@ else {
1132
  <?php } ?>
1133
  </h4>
1134
 
1135
- <p><strong>Visual Composer</strong> is perhaps the most popular page builder tool for WordPress powering
1136
  over 1.5+ million sites. You can build any layout you can imagine with intuitive drag and drop builder
1137
  with little or no programming knowledge.</p>
1138
- <p>All of the elements part of Addons for Visual Composer plugin were built using the API provided
1139
- by the Visual Composer plugin and hence this plugin must be installed and activated on the site prior
1140
  to using our plugin.</p>
1141
  <p>All of the pages of our demo site for
1142
  the plugin have been built using this page builder. You should install and activate this plugin
@@ -1181,7 +1181,7 @@ else {
1181
  <p>Our tests indicate that the elements work well with most themes that are well coded. You may need some
1182
  minor custom CSS with themes that hijack the styling for heading tags by using !important
1183
  keyword.</p>
1184
- <p>Some themes override default templates provided by Visual Composer. The themes that override VC Row
1185
  template may require you to manually set the attributes required for the dark version (see below).</p>
1186
 
1187
  <p>The demo site is best recreated with a theme that supports a full width page template without
@@ -1192,7 +1192,7 @@ else {
1192
 
1193
  <h3 id="faq-dark-version">How to enable the dark version for any element?</h3>
1194
 
1195
- <p>In Visual Composer page builder, add a row wrapper for the element, edit row and check the option
1196
  ‘Dark Background?’ at the end of General tab of the row or an inner row element.</p>
1197
 
1198
  <p>For themes that override the VC row template with one of their own, you may need to add a custom
@@ -1210,9 +1210,21 @@ else {
1210
 
1211
  <!-- Updates panel -->
1212
  <div id="updates-panel" class="panel-left">
 
 
 
 
 
 
 
 
 
 
 
 
1213
  <h3>1.8.2</h3>
1214
  <ul>
1215
- <li>Fixed – Livemesh Grid columns can break in certain resolutions in FireFox.</li>
1216
  <li>Fixed - The piechart value is not being rounded.</li>
1217
  <li>Fixed - The post grid and posts carousel date format not reflecting the user preference specified in Settings page.</li>
1218
  </ul>
@@ -1235,7 +1247,7 @@ else {
1235
  <li>Fixed – The post image in a grid or posts carousel was not clickable to the link specified</li>
1236
  <li>Fixed – The grid filters would not center when a heading was not specified.</li>
1237
  <li>Fixed – The grid filters will not display multi-line on devices of lower resolutions like mobile devices.</li>
1238
- <li>Fixed – The plugin caused some minor styling changes to occur in Visual Composer backend.</li>
1239
  <li>Updated - Compatibility with WordPress 4.9 version.</li>
1240
  </ul>
1241
  <h4>1.6.1</h4>
@@ -1305,7 +1317,7 @@ else {
1305
  <div class="panel-inner">
1306
 
1307
  <div class="panel-aside banner">
1308
- <a href="https://www.livemeshthemes.com/visual-composer-addons/pricing/" title="Purchase Now"><img class="dashboard-image"
1309
  src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/dashboard/purchase-banner1.jpg"
1310
  alt="Sale Banner"></a>
1311
  </div>
26
 
27
  <div class="intro-wrap">
28
 
29
+ <img class="plugin-image" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/plugin-screenshot.jpg" alt="Addons for WPBakery Page Builder">
30
 
31
  <div class="intro">
32
  <h3><?php printf(__('Getting started with %1$s v%2$s', 'livemesh-vc-addons'), $plugin['Name'], $plugin['Version']); ?></h3>
76
  <li><a href="#testimonials-elements">Testimonials Addons</a></li>
77
  <li><a href="#posts-carousel">Posts Carousel</a></li>
78
  <li><a href="#carousel-element">Carousel Addon</a></li>
79
+ <li><a href="#grid-element">Posts Grid</a></li>
80
  <li><a href="#clients-element">Clients</a></li>
81
  <li><a href="#pricing-table">Pricing Table</a></li>
82
  <li><a href="#tabs-accordions">Tabs and Accordions</a></li>
91
  </ul>
92
  <h3 id="getting-started">Getting Started<a class="back-to-top" href="#panel"><span
93
  class="dashicons dashicons-arrow-up-alt2"></span> Back to top</a></h3>
94
+ <p>Thanks for choosing Addons for WPBakery Page Builder plugin. This help file aims to provide you with all the information you need to make the best use of this powerful plugin. The aim of the plugin to make the task of building a website effortless and pleasurable. Towards that end, we have built a number of elements most commonly used across most of the websites of small businesses, corporates, design agencies, freelancers, artists etc.</p>
95
  <p>Do follow the steps below to get started - </p>
96
  <ol>
97
  <li>Install and activate the <strong>required plugin</strong> <a
98
+ href="https://codecanyon.net/item/visual-composer-page-builder-for-wordpress/242431?ref=livemesh" rel="nofollow" target="_blank">WPBakery Page Builder</a>.
99
+ WPBakery Page Builder is a premium WordPress page builder plugin available for purchase from <a
100
  href="https://codecanyon.net/item/visual-composer-page-builder-for-wordpress/242431?ref=livemesh" rel="nofollow" target="_blank">CodeCanyon</a>.
101
  With over 1.5m installed sites, VC is certainly the most popular page builder plugin for WordPress.
102
  </li>
103
  <li>Unzip the downloaded addons-for-visual-composer.zip file and upload to the <code>/wp-content/plugins/</code>
104
  directory or upload the plugin zip with the help of Plugins→Installed Plugins→Add New button.<br>
105
  Activate the plugin through the 'Plugins' menu in WordPress. If you are viewing this help page
106
+ in WordPress admin under WPBakery Addons→Documentation, you have already activated the plugin.
107
  </li>
108
  <li>Once the plugin is activated, all of the elements part of the plugin are available in Visual
109
+ Composer 'Add Element' window, grouped under 'Livemesh Addons' tab.
110
 
111
+ <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/add-element-window.png" alt="WPBakery Page Builder Addons Add Element Window"></p>
112
 
113
 
114
  <p>Once you are done with developing the site, for performance gains, you can selectively deactivate
115
  the unused elements in 'Elements' tab of
116
  <strong> <a href="<?php echo admin_url() . 'admin.php?page=livemesh_vc_addons'; ?>"
117
+ target="_blank"><?php echo __('WPBakery Addons→Settings', 'livemesh-vc-addons') ?></a></strong>
118
  page. This will ensure that scripts and files relating to the deactivated elements do not load on your site.</p>
119
  </li>
120
+ <li>If you plan to build a portfolio site and plan to use Posts Grid element for the same, install
121
  and activate the optional plugin <a
122
  href="https://wordpress.org/plugins/portfolio-post-type/" rel="nofollow" target="_blank">Portfolio
123
  Post Type</a>.
124
+ The portfolio examples of Posts Grid element is built using custom post type registered by
125
  this plugin.
126
  </li>
127
+ <li>Optionally, if you have <a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/" title="Addons for WPBakery Page Builder Pro" target="_blank">premium version</a> of the plugin installed, you can import the sample data
128
  that replicates the demo site for you by importing the
129
  file sample-data.xml file located in the plugin directory. The import option is available under
130
  <strong> <a href="<?php echo admin_url() . 'import.php'; ?>"
140
  <p>Below is a list of required/recommended plugins to install that will help you get the most out of this plugin.
141
  Although some of these plugins are optional, we recommend that you install these popular plugins if
142
  you plan to install the demo data and get most out of this plugin. The demo site and the sample data
143
+ provided with the <a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/"
144
+ title="Addons for WPBakery Page Builder Pro" target="_blank">premium version</a> of
145
  the plugin utilizes all of these plugins including the Portfolio Post type plugin.</p>
146
+ <p>These plugins are also listed in the Plugins tab of this help file under WPBakery Addons →
147
  Documentation, and you can install the plugins directly from there.</p>
148
  <ul>
149
+ <li><p><strong>WPBakery Page Builder</strong> is perhaps the most popular page builder tool for WordPress powering
150
  over 1.5+ million sites. You can build any layout you can imagine with intuitive drag and drop builder
151
  with little or no programming knowledge.</p>
152
+ <p>All of the elements part of Addons for WPBakery Page Builder plugin were built using the API provided
153
+ by the WPBakery Page Builder plugin and hence this plugin must be installed and activated on the site prior
154
  to using our plugin.</p>
155
  <p>All of the pages of our demo site for
156
  the plugin have been built using this page builder. You should install and activate this plugin
157
  prior to replicating the plugin demo site by importing the sample data provided.</p>
158
+ <p><a href="<?php echo esc_url($visualComposerUrl); ?>" target="_blank">More about WPBakery Page Builder →</a></p></li>
159
  <li><strong>Portfolio Post Type</strong> is a free plugin that registers a custom post type for
160
  portfolio items. It also registers separate portfolio taxonomies for tags and categories. The
161
  Portfolio grid instances showcased on our demo site was built using custom post types registered
167
  <hr>
168
  <h3 id="demo-data">Installing Demo Data<a class="back-to-top" href="#panel"><span
169
  class="dashicons dashicons-arrow-up-alt2"></span> Back to top</a></h3>
170
+ <p>If you have <a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/" title="Addons for WPBakery Page Builder Pro" target="_blank">premium version</a> of the plugin installed, you can install the demo data to replicate the
171
  plugin demo site to get a head start on building your site. Installing demo data reduces the
172
  learning curve associated with trying out the powerful elements part of this plugin.</p>
173
  <p>The sample data imports the pages, posts and portfolio items part of the demo site. Once you are done with playing around the
185
  class="dashicons dashicons-arrow-up-alt2"></span> Back to top</a></h3>
186
 
187
  <ul>
188
+ <li>If you are new to drag and drop page building functions of <a href="<?php echo esc_url($visualComposerUrl); ?>" target="_blank">WPBakery Page Builder</a> and need help, make sure you checkout the <a
189
  href="https://wpbakery.atlassian.net/wiki/display/VC/Visual+Composer+Pagebuilder+for+WordPress"
190
+ title="WPBakery Page Builder Documentation" target="_blank">documentation of the WPBakery Page Builder</a> before
191
  starting to use this plugin. The site has numerous text as well as video tutorials to help you
192
  get a head start on using the plugin.
193
  </li>
194
 
195
+ <li>Once the Addons for WPBakery Page Builder plugin is activated, you should see a menu item <strong> <a href="<?php echo admin_url() . 'admin.php?page=livemesh_vc_addons'; ?>"
196
+ target="_blank"><?php echo __('WPBakery Addons', 'livemesh-vc-addons') ?></a></strong> in WordPress admin with four sections - Settings, Elements, Debugging and Premium Upgrade.
197
+ <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/plugin-settings.png" alt="WPBakery Page Builder Addons Settings"></p>
198
 
199
  <p>The settings screen <strong> <a href="<?php echo admin_url() . 'admin.php?page=livemesh_vc_addons'; ?>"
200
+ target="_blank"><?php echo __('WPBakery Addons→Settings', 'livemesh-vc-addons') ?></a></strong> for the plugin is self-documenting with minimal
201
  options. Make sure you choose the theme color scheme in the 'General' tab to help ensure the plugin takes this as the default color for elements like buttons and links which have default color set.</p>
202
  <p>During the development phase, it is recommended to not have any of the elements deactivated in the 'Elements' tab of the settings screen.</p>
203
 
204
  </li>
205
 
206
+ <li>Once the Addons for WPBakery Page Builder plugin is activated, all of the elements built by the plugin become available for drag and drop in the WPBakery Page Builder. In
207
  the Page edit window, click on the <strong>'Backend Editor'</strong> button below the title field of the page edit window to bring up the page builder controls on
208
  the page edit screen.
209
+ <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/page-builder-screen.png" alt="WPBakery Page Builder Screen"></p>
210
  </li>
211
 
212
+ <li>To add a Livemesh WPBakery Page Builder addon element, just click on the <strong>'Add Element'</strong> button to bring up the 'Add Element'
213
+ popup screen of the page builder. The plugin elements are grouped under <strong>'Livemesh
214
  Addons'</strong> tab on the top. Clicking on a element listed in the popup adds the
215
  element to the page builder.
216
+ <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/add-element-window.png" alt="WPBakery Page Builder Addons"></p>
217
  </li>
218
 
219
  <li>Hovering over the element added to the page builder, you can view the Edit link. Clicking the
223
 
224
  <p>Once the data required for configuring a element is entered, you can save the changes by
225
  clicking on the <strong>'Save Changes'</strong> button for the element.</p>
226
+ <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/addon-edit-screen.png" alt="WPBakery Page Builder Element Edit Window"></p>
227
 
228
  </li>
229
 
230
  <li>Many of the plugin elements part of this plugin are container elements that involve a child element to be added to the it. For eg., Team element needs multiple team member elements
231
  added to it, Testimonials element is made of multiple child testiominial elements, Services element require that you add multiple service elements individually to make up the list of services.
232
 
233
+ <p>The container elements are listed under 'Livemesh Addons' tab in the 'Add Element' popup screen. Once you add a container element (e.g., Livemesh Testimonials,
234
+ Services, FAQ, Features, Team Members etc.), the element display a big plus(+) icon in the page to help add child elements. Clicking on the plus(+) button
235
  brings up child element editor popup window. Once you configure and save changes to the child element, the element gets added to the page builder window as contained
236
  element part of the parent container element as seen below.</p>
237
+ <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/page-builder-screen.png" alt="WPBakery Page Builder Addon Edit Window"></p>
238
 
239
  <p>In the page edit screen of the page builder, while the settings for the container element itself can be changed by clicking on the edit icon at the top of the element added,
240
  the child elements can be edited by clicking on the edit option available upon hovering over the child elements in the page edit window.</p>
243
 
244
  <li>After you hit the <strong>Update</strong> or <strong>Publish</strong> button on the page,the element is then ready for viewing on
245
  the frontend page.
246
+ <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/addon-rendered.png" alt="WPBakery Page Builder Addon Rendered"></p>
247
 
248
  </li>
249
 
250
  </ul>
251
 
252
 
253
+ <p>The below sections provide help on each of the elements built as part of Addons for WPBakery Page Builder
254
  plugin.</p>
255
 
256
  <hr>
281
  <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/services-addon-edit.png" alt="Services Addon Container Element"></p>
282
  <p>The services element is a container element that requires you to input multiple child service elements
283
  that make up the list of services offered by a business or a community.</p>
284
+ <p>The element supports about 3 different styles (with 2 additional styles in <a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/" title="Addons for WPBakery Page Builder Pro" target="_blank">premium version</a> of the
285
  plugin) and each of these styles can be customized further by choosing the type of icon desired to
286
  represent the service – a font icon or an custom image icon. While the choice of font icons is huge
287
  in number and perhaps sufficient for most common services, the icon images can help present the
298
  <li><strong>Icon Custom Hover Color</strong> – Specify a custom hover color for the font icon.</li>
299
  </ul>
300
 
301
+ <p>The <a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/" title="Addons for WPBakery Page Builder Pro" target="_blank">premium version</a> of the plugin allows you specify a custom font size, font color and and hover
302
  color for the font icon along with providing two additional styles of services/features.</p>
303
 
304
 
316
 
317
  <p>This element provides an easy way to capture the team members of your organization or an agency.</p>
318
  <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/team-members-edit.png" alt="Team Members Addon Container Element"></p>
319
+ <p>The Team Members element is a container element that requires you to input multiple child elements for
320
  team members that are part of the team/organization.</p>
321
+ <p>Two different styles are provided with more styles planned in the <a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/" title="Addons for WPBakery Page Builder Pro" target="_blank">premium version</a> of the plugin. Most
322
  of the styles display the team members in a multi-column grid. The option to specify the number of
323
  columns is provided that helps to control the number of team members displayed per row of the team
324
  members.</p>
333
  <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/statsbars-piecharts.png" alt="Statistics Addons"></p>
334
 
335
  <p>The plugin features a number of elements that help display statistical information in the form of
336
+ odometers, piecharts and stats bars. The <a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/" title="Addons for WPBakery Page Builder Pro" target="_blank">premium version</a> of the plugin also includes a countdown
337
  element that displays a countdown timer for planned events such as product launches or website going
338
  live.</p>
339
 
431
  <li><strong>Post Count</strong> – Set the number of posts you wish you display in the element. If
432
  the element does not support pagination, the number of posts displayed is limited by the number
433
  specified here. This is also the number of posts to display per page when the element supports
434
+ pagination as is the case with Posts Grid element. Enter "All" to display all posts.
435
  </li>
436
  <li><strong>Order By</strong> – Specify the order of the posts displayed - by post date, title, modified date, author
437
  menu order, comment count etc.
516
  <h3 id="carousel-element">Carousel<a class="back-to-top" href="#panel"> Back to top</a></h3>
517
  <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/generic-carousel.jpg" alt="Generic Carousel Addon"></p>
518
 
519
+ <p>Carousel is a generic carousel of custom HTML content of your choice. Possibilities are endless – image
520
  carousels with textual content describing the images, video carousels, event carousels with link to
521
  the events, a carousel of team of volunteers, a collection of books sold on Amazon etc.</p>
522
  <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-carousel-edit.png" alt="Generic Carousel Addon Edit Window"></p>
534
  for carousel, number of columns or items to display before making the user to scroll for additional
535
  items etc. The carousel settings are explained in the help section above for Posts Carousel.</p>
536
  <hr>
537
+ <h3 id="grid-element">Posts Grid<a class="back-to-top" href="#panel"> Back to top</a></h3>
538
+ <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid.jpg" alt="Posts Grid Addon"></p>
539
 
540
  <p>Perhaps the most popular and most important of all elements part of all elements part of this plugin,
541
+ Posts Grid helps you build a multi-column grid of posts or custom post types. The posts displayed
542
  are filterable by taxonomy terms.</p>
543
 
544
+ <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid2.jpg" alt="Posts Grid Addon"></p>
545
  <p>Using the Grid element, you can construct a portfolio of your work/services/products. We recommend you
546
  use the popular plugin – <a title="Portfolio Post Type Plugin"
547
  href="https://wordpress.org/plugins/portfolio-post-type/">https://wordpress.org/plugins/portfolio-post-type/</a>
548
  for building a collection of portfolio entries. Once the portfolio entries are in place, make sure
549
  you select Portfolio Post type under Post Type entry in Build Tools window as explained below.</p>
550
 
551
+ <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid-pagination.jpg" alt="Posts Grid Pagination"></p>
552
+ <p>The <a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/" title="Addons for WPBakery Page Builder Pro" target="_blank">premium version</a> of the plugin has support for pagination, lazy load with load more button and
553
  lightbox option for images. The additional posts are loaded via AJAX when the user navigates through
554
  the pages populated or when the user hits the Load More button.</p>
555
 
556
+ <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid-loadmore.jpg" alt="Posts Grid AJAX Load More"></p>
557
 
558
  <p>The element features a Posts Query section to help choose posts or custom posts to display. This
559
  powerful tool has number of fields to control what gets displayed and in what order.</p>
567
  <li><strong>Post Count</strong> – Set the number of posts you wish you display in the element. If
568
  the element does not support pagination, the number of posts displayed is limited by the number
569
  specified here. This is also the number of posts to display per page when the element supports
570
+ pagination as is the case with Posts Grid element. Enter "All" to display all posts.
571
  </li>
572
  <li><strong>Order By</strong> – Specify the order of the posts displayed - by post date, title, modified date, author
573
  menu order, comment count etc.
591
  use this field to specify the chosen authors here by specifying their names.
592
  </li>
593
  </ol>
594
+ <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid-edit1.png" alt="Posts Grid Edit Window"></p>
595
+ <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid-edit2.png" alt="Posts Grid Edit Window"></p>
596
 
597
+ <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid-edit3.png" alt="Posts Grid Edit Window"></p>
598
 
599
+ <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/livemesh-grid-edit4.png" alt="Posts Grid Edit Window"></p>
600
 
601
 
602
  <p>The grid element has numerous other options to control the display of posts or custom post types. Some
776
  <p>You can choose to display an icon along with the button text. The icon can be a icon font or an
777
  image.</p>
778
  <p>The element options are mostly self-explanatory and you can view a live preview of the buttons <a
779
+ title="WPBakery Page Builder Button Addon Demo"
780
+ href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/buttons/">here</a>.</p>
781
 
782
 
783
  <hr>
928
  video tutorial sites, video marketers, small businesses or websites with a major presence on
929
  YouTube/Vimeo. The videos can be played with a single click of the play button on the gallery item
930
  as seen in this <a title="Video Gallery"
931
+ href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/video-gallery/">demo page</a>.
932
  </p>
933
  <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/image-gallery-edit1.png" alt="Image Gallery Addon Edit Window"></p>
934
  <p>The image gallery element is a container element that requires you to add child elements representing gallery items.</p>
995
  video tutorial sites, video marketers, small businesses or websites with a major presence on
996
  YouTube/Vimeo. The videos can be played with a single click of the play button on the gallery item
997
  as seen in this <a title="Video Gallery"
998
+ href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/video-gallery/">demo page</a>.
999
  </p>
1000
  <p><img class="alignnone size-large" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/image-carousel-edit1.png" alt="Image Carousel Addon Edit Window"></p>
1001
 
1116
  <div id="plugins-panel" class="panel-left">
1117
  <h4>Required/Recommended Plugins</h4>
1118
 
1119
+ <p>Below is a list of required/recommended plugins to install that will help you get the most out of the plugin. While WPBakery Page Builder plugin is required, the rest of the plugins are optional but we recommend you install these plugins if you plan to replicate the plugin demo site by importing the sample data.</p>
1120
 
1121
  <hr/>
1122
 
1123
+ <h4><?php _e('WPBakery Page Builder', 'livemesh-vc-addons'); ?>
1124
  <?php if (!class_exists('Vc_Manager')) { ?>
1125
  <a class="button button-secondary thickbox onclick" href="<?php echo esc_url($visualComposerUrl); ?>"
1126
+ title="<?php esc_attr_e('Install WPBakery Page Builder', 'livemesh-vc-addons'); ?>"><span
1127
  class="dashicons dashicons-download"></span> <?php _e('Install Now', 'livemesh-vc-addons'); ?></a>
1128
  <?php }
1129
  else { ?>
1132
  <?php } ?>
1133
  </h4>
1134
 
1135
+ <p><strong>WPBakery Page Builder</strong> is perhaps the most popular page builder tool for WordPress powering
1136
  over 1.5+ million sites. You can build any layout you can imagine with intuitive drag and drop builder
1137
  with little or no programming knowledge.</p>
1138
+ <p>All of the elements part of Addons for WPBakery Page Builder plugin were built using the API provided
1139
+ by the WPBakery Page Builder plugin and hence this plugin must be installed and activated on the site prior
1140
  to using our plugin.</p>
1141
  <p>All of the pages of our demo site for
1142
  the plugin have been built using this page builder. You should install and activate this plugin
1181
  <p>Our tests indicate that the elements work well with most themes that are well coded. You may need some
1182
  minor custom CSS with themes that hijack the styling for heading tags by using !important
1183
  keyword.</p>
1184
+ <p>Some themes override default templates provided by WPBakery Page Builder. The themes that override VC Row
1185
  template may require you to manually set the attributes required for the dark version (see below).</p>
1186
 
1187
  <p>The demo site is best recreated with a theme that supports a full width page template without
1192
 
1193
  <h3 id="faq-dark-version">How to enable the dark version for any element?</h3>
1194
 
1195
+ <p>In WPBakery Page Builder, add a row wrapper for the element, edit row and check the option
1196
  ‘Dark Background?’ at the end of General tab of the row or an inner row element.</p>
1197
 
1198
  <p>For themes that override the VC row template with one of their own, you may need to add a custom
1210
 
1211
  <!-- Updates panel -->
1212
  <div id="updates-panel" class="panel-left">
1213
+ <h3>1.9.1</h3>
1214
+ <ul>
1215
+ <li>Rolled back – Update done to WayPoints script since WPBakery Page Builder is yet to upgrade to new version. Some reports have come in which suggests that the change broke some pages with certain WPBakery page builder elements.</li>
1216
+ </ul>
1217
+ <h3>1.9.0</h3>
1218
+ <ul>
1219
+ <li>Updated – Changed plugin name to Addons for WPBakery Page Builder to help reflect recent renaming of Visual Composer to WPBakery Page Builder.</li>
1220
+ <li>Updated - Changed plugin options menu title from VC Addons to WPBakery Addons in WordPress admin.</li>
1221
+ <li>Updated - Removed annoying Livemesh prefix from all elements. For example, Livemesh Services is now named Services, Livemesh Tabs is now Tabs, Livemesh Grid is now Posts Grid etc.</li>
1222
+ <li>Updated - Moved to latest version of waypoints script.</li>
1223
+ <li>Fixed - The grid won't display filters when specific taxonomy terms are chosen in the build query</li>
1224
+ </ul>
1225
  <h3>1.8.2</h3>
1226
  <ul>
1227
+ <li>Fixed – Posts Grid columns can break in certain resolutions in FireFox.</li>
1228
  <li>Fixed - The piechart value is not being rounded.</li>
1229
  <li>Fixed - The post grid and posts carousel date format not reflecting the user preference specified in Settings page.</li>
1230
  </ul>
1247
  <li>Fixed – The post image in a grid or posts carousel was not clickable to the link specified</li>
1248
  <li>Fixed – The grid filters would not center when a heading was not specified.</li>
1249
  <li>Fixed – The grid filters will not display multi-line on devices of lower resolutions like mobile devices.</li>
1250
+ <li>Fixed – The plugin caused some minor styling changes to occur in WPBakery Page Builder backend.</li>
1251
  <li>Updated - Compatibility with WordPress 4.9 version.</li>
1252
  </ul>
1253
  <h4>1.6.1</h4>
1317
  <div class="panel-inner">
1318
 
1319
  <div class="panel-aside banner">
1320
+ <a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/" title="Purchase Now"><img class="dashboard-image"
1321
  src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/dashboard/purchase-banner1.jpg"
1322
  alt="Sale Banner"></a>
1323
  </div>
admin/views/premium-upgrade.php CHANGED
@@ -21,7 +21,7 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
21
  <div class="plans-wrapper clear">
22
  <div class="plan-intro">
23
  <div class="w100 clear"><img src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/dashboard/logo-light.png" class="mb30">
24
- <p>A huge collection of Premium addons for Visual Composer. Building a beautiful website is as easy as drag and drop.</p></div>
25
  </div>
26
  <div class="plans">
27
  <div class="content-wrapper flex-wrap">
@@ -29,14 +29,14 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
29
  <div class="w100 clear"><h3>Lite</h3>
30
  <p class="mb20 text">All the great features and addons you need to get started on creating a beautiful website.</p>
31
  <h4 class="b c-wh price">FREE</h4>
32
- <div class="action clear"><a href="https://wordpress.org/plugins/addons-for-visual-composer/" class="btn bg-gr center" title="Addons for Visual Composer Download">Download now</a></div>
33
  </div>
34
  </div>
35
  <div class="plan plan2 flex-col">
36
  <div class="w100 clear"><h3>Premium</h3>
37
  <p class="mb20 text">More features and additional addons to build a professional website without switching your WP theme.</p>
38
  <h4 class="b price c-wh">$19</h4>
39
- <div class="action clear"><a href="https://www.livemeshthemes.com/visual-composer-addons/pricing/" class="btn center bg-cy">Purchase Now</a></div>
40
  </div>
41
  </div>
42
  </div>
@@ -52,13 +52,13 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
52
  <li><span class="help dashicons dashicons-editor-help"></span>
53
  <div class="text">Premium quality Addons</div>
54
  <div class="tooltip hide">
55
- <div><p>Exquisitely designed premium quality addons for Visual Composer Page Builder.</div>
56
  </div>
57
  </li>
58
  <li><span class="help dashicons dashicons-editor-help"></span>
59
  <div class="text">Page Builder Elements</div>
60
  <div class="tooltip hide">
61
- <div><p>Large collection of plugin addons with their multiple styles are page builder elements that provide ALL the tools you need to come up with a dream website of yours by just drag, drop and configure. &nbsp;<a target="_blank" href="https://www.livemeshthemes.com/visual-composer-addons/">Live Demo</a></p></div>
62
  </div>
63
  </li>
64
  <li><span class="help dashicons dashicons-editor-help"></span>
@@ -70,13 +70,13 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
70
  <li><span class="help dashicons dashicons-editor-help"></span>
71
  <div class="text">Posts/Portfolio Grid</div>
72
  <div class="tooltip hide">
73
- <div><p>The PRO version comes with advanced grid functions like multiple styles, AJAX filtering, pagination, lazy load via AJAX, lightbox support etc.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/visual-composer-addons/portfolio-grid-pro/">Live Demo</a></p></div>
74
  </div>
75
  </li>
76
  <li><span class="help dashicons dashicons-editor-help"></span>
77
  <div class="text">Post Blocks!</div>
78
  <div class="tooltip hide">
79
- <div><p>Present your blog posts, events, news items or portfolio in a dozen creative ways. Comes with AJAX filtering, pagination and load more features to help visitors navigate your entire collection of blog posts or custom post types and their categories without reloading the page.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/visual-composer-addons/posts-block/">Live Demo</a></p>
80
  </div>
81
  </div>
82
  </li>
@@ -89,13 +89,13 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
89
  <li><span class="help dashicons dashicons-editor-help"></span>
90
  <div class="text">Grids with AJAX Pagination</div>
91
  <div class="tooltip hide">
92
- <div><p>Multiple pages of posts/portfolio/image/video grid loaded inline without page refresh. Showcase your entire work anywhere on the site.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/visual-composer-addons/portfolio-grid-pro/">Live Demo</a></p></div>
93
  </div>
94
  </li>
95
  <li><span class="help dashicons dashicons-editor-help"></span>
96
  <div class="text">Advanced Grid with Lazy Load</div>
97
  <div class="tooltip hide">
98
- <div><p>The grid elements are loaded on demand with each press of a Load More button that displays a count of remaining posts.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/visual-composer-addons/portfolio-grid-pro/">Live Demo</a></p></div>
99
  </div>
100
  </li>
101
  <li><span class="help dashicons dashicons-editor-help"></span>
@@ -115,38 +115,38 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
115
  <li><span class="help dashicons dashicons-editor-help"></span>
116
  <div class="text">Advanced Image Slider</div>
117
  <div class="tooltip hide">
118
- <div><p>Responsive slider with choice of Nivo, Flex, Slick and Ultra Lightweight slider types. Comes with multiple caption styles, thumbnail navigation and detailed customization of slider speed and controls.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/visual-composer-addons/livemesh-sliders/">Live Demo</a></p>
119
  </div>
120
  </div>
121
  </li>
122
  <li><span class="help dashicons dashicons-editor-help"></span>
123
  <div class="text">Image Gallery</div>
124
  <div class="tooltip hide">
125
- <div><p>Create a beautiful yet responsive gallery with support for tagging, linking, filtering, labels, lazy load of images with Load More and pagination.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/visual-composer-addons/image-gallery/">Live Demo</a></p></div>
126
  </div>
127
  </li>
128
  <li><span class="help dashicons dashicons-editor-help"></span>
129
  <div class="text">YouTube/Vimeo Video Gallery</div>
130
  <div class="tooltip hide">
131
- <div><p>Essential tool for video bloggers, video marketers, musicians and other sites with video content. Tags, filters, external linking, labels, pagination and lazy load via AJAX supported.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/visual-composer-addons/video-gallery/">Live Demo</a></p></div>
132
  </div>
133
  </li>
134
  <li><span class="help dashicons dashicons-editor-help"></span>
135
  <div class="text">Advanced Image Carousel</div>
136
  <div class="tooltip hide">
137
- <div><p>Advanced carousel with touch/swipe/drag/paged/click navigation. Extensive customization for responsiveness, animation/slideshow speed, gutter, looping etc.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/visual-composer-addons/gallery-carousel/">Live Demo</a></p></div>
138
  </div>
139
  </li>
140
  <li><span class="help dashicons dashicons-editor-help"></span>
141
  <div class="text">YouTube/Vimeo Video Carousel</div>
142
  <div class="tooltip hide">
143
- <div><p>Perfect for showcasing a select collection of videos with filters, tags, external links, labels, touch/swipe/mouse drag/click navigation, paging and lightbox support.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/visual-composer-addons/gallery-carousel/">Live Demo</a></p></div>
144
  </div>
145
  </li>
146
  <li><span class="help dashicons dashicons-editor-help"></span>
147
  <div class="text">Features List</div>
148
  <div class="tooltip hide">
149
- <div><p>List the product features or services offered in style.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/visual-composer-addons/features/">Live Demo</a></p></div>
150
  </div>
151
  </li>
152
  <li><span class="help dashicons dashicons-editor-help"></span>
@@ -171,7 +171,7 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
171
  <div class="dashicons dashicons-yes"></div>
172
  <span class="m-feature m">Premium quality Addons</span>
173
  <div class="tooltip hide">
174
- <p>Exquisitely designed premium quality addons for Visual Composer Page Builder.</p>
175
  </div>
176
  </li>
177
  <li>
@@ -203,7 +203,7 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
203
  <div class="dashicons dashicons-no-alt"></div>
204
  <span class="m-feature m">Post Blocks!</span>
205
  <div class="tooltip hide">
206
- <p>Present your blog posts, events, news items or portfolio in a dozen creative ways. Comes with AJAX filtering, pagination and load more features to help visitors navigate your entire collection of blog posts or custom post types and their categories without reloading the page.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/visual-composer-addons/posts-block/">Live Demo</a></p>
207
  </div>
208
  </li>
209
  <li>
@@ -298,7 +298,7 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
298
  </div>
299
  </li>
300
  </ul>
301
- <div class="action clear"><a href="https://wordpress.org/plugins/addons-for-visual-composer/" class="btn bg-gr center" title="Addons for Visual Composer Download">Download now</a></div>
302
  </div>
303
  <div class="plan plan2"><h4>PRO</h4>
304
  <ul>
@@ -306,7 +306,7 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
306
  <div class="dashicons dashicons-yes"></div>
307
  <span class="m-feature m">Premium quality Addons</span>
308
  <div class="tooltip hide">
309
- <p>Exquisitely designed premium quality addons for Visual Composer Page Builder..</p>
310
  </div>
311
  </li>
312
  <li>
@@ -433,7 +433,7 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
433
  </div>
434
  </li>
435
  </ul>
436
- <div class="action clear"><a href="https://www.livemeshthemes.com/visual-composer-addons/pricing/" class="btn center bg-cy">Purchase Now</a></div>
437
  </div>
438
  </div>
439
  </div>
@@ -446,7 +446,7 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
446
 
447
  <div class="button-wrap">
448
 
449
- <a href="https://www.livemeshthemes.com/visual-composer-addons/pricing/" title="Purchase Now">
450
 
451
  <img class="button-image" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/dashboard/purchase-button.png" alt="Purchase Button">
452
 
@@ -482,30 +482,30 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
482
 
483
  <h3 id="item-description__features-overview">New Premium Addons</h3>
484
 
485
- <p>Although the free version of the Addons for Visual Composer features a large repertoire of premium quality addons, the premium
486
  version does even more.</p>
487
 
488
  <ul>
489
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/posts-block/" title="Livemesh Post Blocks" target="_blank">Post Blocks</a> - Present your blog posts, events, news items or portfolio
490
  in a dozen creative ways. Comes with AJAX filtering, pagination and load more features to help visitors navigate your entire collection of blog posts or custom post types and their categories without reloading the page.
491
  </li>
492
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/sliders/" title="Image Slider Addon" target="_blank">Image
493
  Slider</a> - Create a responsive slider of images with support
494
  for captions,
495
  multiple slider types like Nivo, Flex, Slick and lightweight sliders, thumbnail
496
  navigation etc.
497
  </li>
498
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/image-gallery/" title="Image Gallery Addon" target="_blank">Image
499
  Gallery</a> - Create a gallery of images with options for masonry
500
  or fit rows, pagination, lazy load, lightbox support etc.
501
  </li>
502
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/video-gallery/" title="Video Gallery Addon" target="_blank">Video
503
  Gallery</a> - Create a beautiful gallery of videos to help
504
  showcase a collection of YouTube/Vimeo videos on your site.
505
  </li>
506
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/gallery-carousel/" title="Image Carousel" target="_blank">Image
507
  Carousel</a> - Build a responsive carousel of images.</li>
508
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/gallery-carousel/" title="Video Carousel" target="_blank">Video
509
  Carousel</a> - Build a responsive carousel of YouTube/Vimeo
510
  videos.
511
  </li>
@@ -513,10 +513,10 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
513
  your site pages
514
  such as those that feature events or under construction/coming soon pages.
515
  </li>
516
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/faq-element/" title="FAQ Addon" target="_blank">FAQ</a> - Create a set of Frequently Asked Questions for display in a
517
  page.
518
  </li>
519
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/features/" title="Features Addon" target="_blank">Features Addon</a> - Showcase product features or services provided by your agency/business.
520
  </li>
521
  </ul>
522
 
@@ -526,10 +526,10 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
526
  updated with additional features for existing addons -</p>
527
 
528
  <ul>
529
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/portfolio-grid-pro/" title="Livemesh Grid" target="_blank">Lazy Load</a> - The portfolio/post grid and image gallery addons
530
  incorporate option to lazy load posts/images with the click of a Load More button.
531
  </li>
532
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/portfolio-grid-pro/" title="Livemesh Grid" target="_blank">Pagination</a> - Create a grid of posts or custom post types with AJAX
533
  based pagination support.
534
  </li>
535
  <li><strong>Lightbox Support</strong> - The premium version comes with support for
@@ -578,7 +578,7 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
578
 
579
  <div class="button-wrap">
580
 
581
- <a class="button-wrap" href="https://www.livemeshthemes.com/visual-composer-addons/pricing/" title="Purchase Now">
582
 
583
  <img class="button-image" style="border:none" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/dashboard/purchase-button.png" alt="Purchase Button">
584
 
@@ -593,7 +593,7 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
593
  <div class="panel-inner">
594
 
595
  <div class="panel-aside banner">
596
- <a href="https://www.livemeshthemes.com/visual-composer-addons/pricing/" title="Purchase Now"><img class="dashboard-image" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/dashboard/purchase-banner2.jpg" alt="Sale Banner"></a>
597
  </div>
598
 
599
  <!-- Knowledge base -->
@@ -602,7 +602,7 @@ $plugin = get_plugin_data(LVCA_PLUGIN_FILE);
602
  <h4>Have questions regarding premium version of the plugin?</h4>
603
  <p>If you have pre-sales questions related to the paid version of this plugin, feel free to get in touch with us via contact form on our website.</p>
604
 
605
- <a class="button button-primary" href="https://www.livemeshthemes.com/visual-composer-addons/contact-us/"
606
  title="<?php esc_attr_e('Contact Us', 'livemesh-vc-addons'); ?>"><?php _e('Write to Us', 'livemesh-vc-addons'); ?></a>
607
 
608
  </div><!-- .panel-aside knowledge base -->
21
  <div class="plans-wrapper clear">
22
  <div class="plan-intro">
23
  <div class="w100 clear"><img src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/dashboard/logo-light.png" class="mb30">
24
+ <p>A huge collection of Premium addons for WPBakery Page Builder. Building a beautiful website is as easy as drag and drop.</p></div>
25
  </div>
26
  <div class="plans">
27
  <div class="content-wrapper flex-wrap">
29
  <div class="w100 clear"><h3>Lite</h3>
30
  <p class="mb20 text">All the great features and addons you need to get started on creating a beautiful website.</p>
31
  <h4 class="b c-wh price">FREE</h4>
32
+ <div class="action clear"><a href="https://wordpress.org/plugins/addons-for-visual-composer/" class="btn bg-gr center" title="Addons for WPBakery Page Builder Download">Download now</a></div>
33
  </div>
34
  </div>
35
  <div class="plan plan2 flex-col">
36
  <div class="w100 clear"><h3>Premium</h3>
37
  <p class="mb20 text">More features and additional addons to build a professional website without switching your WP theme.</p>
38
  <h4 class="b price c-wh">$19</h4>
39
+ <div class="action clear"><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/" class="btn center bg-cy">Purchase Now</a></div>
40
  </div>
41
  </div>
42
  </div>
52
  <li><span class="help dashicons dashicons-editor-help"></span>
53
  <div class="text">Premium quality Addons</div>
54
  <div class="tooltip hide">
55
+ <div><p>Exquisitely designed premium quality addons for WPBakery Page Builder.</div>
56
  </div>
57
  </li>
58
  <li><span class="help dashicons dashicons-editor-help"></span>
59
  <div class="text">Page Builder Elements</div>
60
  <div class="tooltip hide">
61
+ <div><p>Large collection of plugin addons with their multiple styles are page builder elements that provide ALL the tools you need to come up with a dream website of yours by just drag, drop and configure. &nbsp;<a target="_blank" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/">Live Demo</a></p></div>
62
  </div>
63
  </li>
64
  <li><span class="help dashicons dashicons-editor-help"></span>
70
  <li><span class="help dashicons dashicons-editor-help"></span>
71
  <div class="text">Posts/Portfolio Grid</div>
72
  <div class="tooltip hide">
73
+ <div><p>The PRO version comes with advanced grid functions like multiple styles, AJAX filtering, pagination, lazy load via AJAX, lightbox support etc.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/portfolio-grid-pro/">Live Demo</a></p></div>
74
  </div>
75
  </li>
76
  <li><span class="help dashicons dashicons-editor-help"></span>
77
  <div class="text">Post Blocks!</div>
78
  <div class="tooltip hide">
79
+ <div><p>Present your blog posts, events, news items or portfolio in a dozen creative ways. Comes with AJAX filtering, pagination and load more features to help visitors navigate your entire collection of blog posts or custom post types and their categories without reloading the page.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/posts-block/">Live Demo</a></p>
80
  </div>
81
  </div>
82
  </li>
89
  <li><span class="help dashicons dashicons-editor-help"></span>
90
  <div class="text">Grids with AJAX Pagination</div>
91
  <div class="tooltip hide">
92
+ <div><p>Multiple pages of posts/portfolio/image/video grid loaded inline without page refresh. Showcase your entire work anywhere on the site.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/portfolio-grid-pro/">Live Demo</a></p></div>
93
  </div>
94
  </li>
95
  <li><span class="help dashicons dashicons-editor-help"></span>
96
  <div class="text">Advanced Grid with Lazy Load</div>
97
  <div class="tooltip hide">
98
+ <div><p>The grid elements are loaded on demand with each press of a Load More button that displays a count of remaining posts.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/portfolio-grid-pro/">Live Demo</a></p></div>
99
  </div>
100
  </li>
101
  <li><span class="help dashicons dashicons-editor-help"></span>
115
  <li><span class="help dashicons dashicons-editor-help"></span>
116
  <div class="text">Advanced Image Slider</div>
117
  <div class="tooltip hide">
118
+ <div><p>Responsive slider with choice of Nivo, Flex, Slick and Ultra Lightweight slider types. Comes with multiple caption styles, thumbnail navigation and detailed customization of slider speed and controls.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/livemesh-sliders/">Live Demo</a></p>
119
  </div>
120
  </div>
121
  </li>
122
  <li><span class="help dashicons dashicons-editor-help"></span>
123
  <div class="text">Image Gallery</div>
124
  <div class="tooltip hide">
125
+ <div><p>Create a beautiful yet responsive gallery with support for tagging, linking, filtering, labels, lazy load of images with Load More and pagination.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/image-gallery/">Live Demo</a></p></div>
126
  </div>
127
  </li>
128
  <li><span class="help dashicons dashicons-editor-help"></span>
129
  <div class="text">YouTube/Vimeo Video Gallery</div>
130
  <div class="tooltip hide">
131
+ <div><p>Essential tool for video bloggers, video marketers, musicians and other sites with video content. Tags, filters, external linking, labels, pagination and lazy load via AJAX supported.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/video-gallery/">Live Demo</a></p></div>
132
  </div>
133
  </li>
134
  <li><span class="help dashicons dashicons-editor-help"></span>
135
  <div class="text">Advanced Image Carousel</div>
136
  <div class="tooltip hide">
137
+ <div><p>Advanced carousel with touch/swipe/drag/paged/click navigation. Extensive customization for responsiveness, animation/slideshow speed, gutter, looping etc.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/gallery-carousel/">Live Demo</a></p></div>
138
  </div>
139
  </li>
140
  <li><span class="help dashicons dashicons-editor-help"></span>
141
  <div class="text">YouTube/Vimeo Video Carousel</div>
142
  <div class="tooltip hide">
143
+ <div><p>Perfect for showcasing a select collection of videos with filters, tags, external links, labels, touch/swipe/mouse drag/click navigation, paging and lightbox support.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/gallery-carousel/">Live Demo</a></p></div>
144
  </div>
145
  </li>
146
  <li><span class="help dashicons dashicons-editor-help"></span>
147
  <div class="text">Features List</div>
148
  <div class="tooltip hide">
149
+ <div><p>List the product features or services offered in style.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/features/">Live Demo</a></p></div>
150
  </div>
151
  </li>
152
  <li><span class="help dashicons dashicons-editor-help"></span>
171
  <div class="dashicons dashicons-yes"></div>
172
  <span class="m-feature m">Premium quality Addons</span>
173
  <div class="tooltip hide">
174
+ <p>Exquisitely designed premium quality addons for WPBakery Page Builder.</p>
175
  </div>
176
  </li>
177
  <li>
203
  <div class="dashicons dashicons-no-alt"></div>
204
  <span class="m-feature m">Post Blocks!</span>
205
  <div class="tooltip hide">
206
+ <p>Present your blog posts, events, news items or portfolio in a dozen creative ways. Comes with AJAX filtering, pagination and load more features to help visitors navigate your entire collection of blog posts or custom post types and their categories without reloading the page.&nbsp;<a target="_blank" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/posts-block/">Live Demo</a></p>
207
  </div>
208
  </li>
209
  <li>
298
  </div>
299
  </li>
300
  </ul>
301
+ <div class="action clear"><a href="https://wordpress.org/plugins/addons-for-visual-composer/" class="btn bg-gr center" title="Addons for WPBakery Page Builder Download">Download now</a></div>
302
  </div>
303
  <div class="plan plan2"><h4>PRO</h4>
304
  <ul>
306
  <div class="dashicons dashicons-yes"></div>
307
  <span class="m-feature m">Premium quality Addons</span>
308
  <div class="tooltip hide">
309
+ <p>Exquisitely designed premium quality addons for WPBakery Page Builder..</p>
310
  </div>
311
  </li>
312
  <li>
433
  </div>
434
  </li>
435
  </ul>
436
+ <div class="action clear"><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/" class="btn center bg-cy">Purchase Now</a></div>
437
  </div>
438
  </div>
439
  </div>
446
 
447
  <div class="button-wrap">
448
 
449
+ <a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/" title="Purchase Now">
450
 
451
  <img class="button-image" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/dashboard/purchase-button.png" alt="Purchase Button">
452
 
482
 
483
  <h3 id="item-description__features-overview">New Premium Addons</h3>
484
 
485
+ <p>Although the free version of the Addons for WPBakery Page Builder features a large repertoire of premium quality addons, the premium
486
  version does even more.</p>
487
 
488
  <ul>
489
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/posts-block/" title="Post Blocks" target="_blank">Post Blocks</a> - Present your blog posts, events, news items or portfolio
490
  in a dozen creative ways. Comes with AJAX filtering, pagination and load more features to help visitors navigate your entire collection of blog posts or custom post types and their categories without reloading the page.
491
  </li>
492
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/sliders/" title="Image Slider Addon" target="_blank">Image
493
  Slider</a> - Create a responsive slider of images with support
494
  for captions,
495
  multiple slider types like Nivo, Flex, Slick and lightweight sliders, thumbnail
496
  navigation etc.
497
  </li>
498
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/image-gallery/" title="Image Gallery Addon" target="_blank">Image
499
  Gallery</a> - Create a gallery of images with options for masonry
500
  or fit rows, pagination, lazy load, lightbox support etc.
501
  </li>
502
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/video-gallery/" title="Video Gallery Addon" target="_blank">Video
503
  Gallery</a> - Create a beautiful gallery of videos to help
504
  showcase a collection of YouTube/Vimeo videos on your site.
505
  </li>
506
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/gallery-carousel/" title="Image Carousel" target="_blank">Image
507
  Carousel</a> - Build a responsive carousel of images.</li>
508
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/gallery-carousel/" title="Video Carousel" target="_blank">Video
509
  Carousel</a> - Build a responsive carousel of YouTube/Vimeo
510
  videos.
511
  </li>
513
  your site pages
514
  such as those that feature events or under construction/coming soon pages.
515
  </li>
516
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/faq-element/" title="FAQ Addon" target="_blank">FAQ</a> - Create a set of Frequently Asked Questions for display in a
517
  page.
518
  </li>
519
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/features/" title="Features Addon" target="_blank">Features Addon</a> - Showcase product features or services provided by your agency/business.
520
  </li>
521
  </ul>
522
 
526
  updated with additional features for existing addons -</p>
527
 
528
  <ul>
529
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/portfolio-grid-pro/" title="Posts Grid" target="_blank">Lazy Load</a> - The portfolio/post grid and image gallery addons
530
  incorporate option to lazy load posts/images with the click of a Load More button.
531
  </li>
532
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/portfolio-grid-pro/" title="Posts Grid" target="_blank">Pagination</a> - Create a grid of posts or custom post types with AJAX
533
  based pagination support.
534
  </li>
535
  <li><strong>Lightbox Support</strong> - The premium version comes with support for
578
 
579
  <div class="button-wrap">
580
 
581
+ <a class="button-wrap" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/" title="Purchase Now">
582
 
583
  <img class="button-image" style="border:none" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/dashboard/purchase-button.png" alt="Purchase Button">
584
 
593
  <div class="panel-inner">
594
 
595
  <div class="panel-aside banner">
596
+ <a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/" title="Purchase Now"><img class="dashboard-image" src="https://www.livemeshthemes.com/wp-content/uploads/plugin-doc/livemesh-vc-addons/dashboard/purchase-banner2.jpg" alt="Sale Banner"></a>
597
  </div>
598
 
599
  <!-- Knowledge base -->
602
  <h4>Have questions regarding premium version of the plugin?</h4>
603
  <p>If you have pre-sales questions related to the paid version of this plugin, feel free to get in touch with us via contact form on our website.</p>
604
 
605
+ <a class="button button-primary" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/contact-us/"
606
  title="<?php esc_attr_e('Contact Us', 'livemesh-vc-addons'); ?>"><?php _e('Write to Us', 'livemesh-vc-addons'); ?></a>
607
 
608
  </div><!-- .panel-aside knowledge base -->
admin/views/settings.php CHANGED
@@ -134,7 +134,7 @@ $deactivate_element_testimonials_slider = lvca_get_option('lvca_deactivate_eleme
134
 
135
  <div class="lvca-tab-content elements">
136
 
137
- <!---- Auto activate VC Addons -->
138
  <div class="lvca-box-side">
139
 
140
  <h3><?php echo __('Optimize Plugin', 'livemesh-vc-addons') ?></h3>
@@ -461,32 +461,32 @@ $deactivate_element_testimonials_slider = lvca_get_option('lvca_deactivate_eleme
461
 
462
  <label class="lvca-label">New Premium Widgets</label>
463
 
464
- <p>Although the free version of the Addons for Visual Composer features a large repertoire of
465
  premium quality elements with its numerous styles, the premium version does even more.</p>
466
 
467
  <ul>
468
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/posts-block/" title="Post Blocks Addon" target="_blank">Post
469
  Blocks!</a> - Present your blog posts, events, news items or portfolio in a dozen creative ways. Comes with AJAX filtering,
470
  pagination and load more features to help visitors navigate your entire collection of blog posts or custom post types and
471
  their categories without reloading the page.
472
  </li>
473
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/sliders/" title="Image Slider Widget" target="_blank">Image
474
  Slider</a> - Create a responsive slider of images with support
475
  for captions,
476
  multiple slider types like Nivo, Flex, Slick and lightweight sliders, thumbnail
477
  navigation etc.
478
  </li>
479
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/image-gallery/" title="Image Gallery Widget" target="_blank">Image
480
  Gallery</a> - Create a gallery of images with options for masonry
481
  or fit rows, pagination, lazy load, lightbox support etc.
482
  </li>
483
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/video-gallery/" title="Video Gallery Widget" target="_blank">Video
484
  Gallery</a> - Create a beautiful gallery of videos to help
485
  showcase a collection of YouTube/Vimeo videos on your site.
486
  </li>
487
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/gallery-carousel/" title="Image Carousel" target="_blank">Image
488
  Carousel</a> - Build a responsive carousel of images.</li>
489
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/gallery-carousel/" title="Video Carousel" target="_blank">Video
490
  Carousel</a> - Build a responsive carousel of YouTube/Vimeo
491
  videos.
492
  </li>
@@ -494,21 +494,21 @@ $deactivate_element_testimonials_slider = lvca_get_option('lvca_deactivate_eleme
494
  your site pages such as those that feature events or under construction/coming soon
495
  pages.
496
  </li>
497
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/buttons/" title="Buttons Addon" target="_blank">Buttons</a> - Animated buttons with great choice of colors.
498
  </li>
499
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/icon-lists/" title="Icon List" target="_blank">Icon List</a> - - Create a list of icons with description and link - for social media profiles,
500
  for showcasing services or features as well with icons or images.
501
  </li>
502
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/faq-element/" title="FAQ Addon" target="_blank">FAQ</a> - Create a set of Frequently Asked Questions for display in a
503
  page.
504
  </li>
505
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/features/" title="Features Addon" target="_blank">Features Addon</a> for showcasing product features or services provided by an agency/business.
506
  </li>
507
  </ul>
508
 
509
  <div class="lvca-spacer" style="height: 15px"></div>
510
 
511
- <a class="lvca-button purchase" href="https://www.livemeshthemes.com/visual-composer-addons/pricing/"><i class="dashicons dashicons-cart"></i><?php echo __('Purchase Now', 'livemesh-vc-addons'); ?></a>
512
 
513
  <div class="lvca-spacer" style="height: 25px"></div>
514
 
@@ -518,10 +518,10 @@ $deactivate_element_testimonials_slider = lvca_get_option('lvca_deactivate_eleme
518
  updated with additional features for existing elements -</p>
519
 
520
  <ul>
521
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/portfolio-grid-pro/" title="Livemesh Grid" target="_blank">Lazy Load</a> - The portfolio/post grid and image gallery elements
522
  incorporate option to lazy load posts/images with the click of a Load More button.
523
  </li>
524
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/portfolio-grid-pro/" title="Livemesh Grid" target="_blank">Pagination</a> - Create a grid of posts or custom post types with AJAX
525
  based pagination support.
526
  </li>
527
  <li><strong>Lightbox Support</strong> - The premium version comes with support for
@@ -570,7 +570,7 @@ $deactivate_element_testimonials_slider = lvca_get_option('lvca_deactivate_eleme
570
 
571
  <div class="lvca-spacer" style="height: 25px"></div>
572
 
573
- <a class="lvca-button purchase" href="https://www.livemeshthemes.com/visual-composer-addons/pricing/"><i class="dashicons dashicons-cart"></i><?php echo __('Go Premium', 'livemesh-vc-addons'); ?></a>
574
 
575
  </div>
576
 
134
 
135
  <div class="lvca-tab-content elements">
136
 
137
+ <!---- Auto activate WPBakery Addons -->
138
  <div class="lvca-box-side">
139
 
140
  <h3><?php echo __('Optimize Plugin', 'livemesh-vc-addons') ?></h3>
461
 
462
  <label class="lvca-label">New Premium Widgets</label>
463
 
464
+ <p>Although the free version of the Addons for WPBakery Page Builder features a large repertoire of
465
  premium quality elements with its numerous styles, the premium version does even more.</p>
466
 
467
  <ul>
468
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/posts-block/" title="Post Blocks Addon" target="_blank">Post
469
  Blocks!</a> - Present your blog posts, events, news items or portfolio in a dozen creative ways. Comes with AJAX filtering,
470
  pagination and load more features to help visitors navigate your entire collection of blog posts or custom post types and
471
  their categories without reloading the page.
472
  </li>
473
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/sliders/" title="Image Slider Widget" target="_blank">Image
474
  Slider</a> - Create a responsive slider of images with support
475
  for captions,
476
  multiple slider types like Nivo, Flex, Slick and lightweight sliders, thumbnail
477
  navigation etc.
478
  </li>
479
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/image-gallery/" title="Image Gallery Widget" target="_blank">Image
480
  Gallery</a> - Create a gallery of images with options for masonry
481
  or fit rows, pagination, lazy load, lightbox support etc.
482
  </li>
483
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/video-gallery/" title="Video Gallery Widget" target="_blank">Video
484
  Gallery</a> - Create a beautiful gallery of videos to help
485
  showcase a collection of YouTube/Vimeo videos on your site.
486
  </li>
487
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/gallery-carousel/" title="Image Carousel" target="_blank">Image
488
  Carousel</a> - Build a responsive carousel of images.</li>
489
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/gallery-carousel/" title="Video Carousel" target="_blank">Video
490
  Carousel</a> - Build a responsive carousel of YouTube/Vimeo
491
  videos.
492
  </li>
494
  your site pages such as those that feature events or under construction/coming soon
495
  pages.
496
  </li>
497
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/buttons/" title="Buttons Addon" target="_blank">Buttons</a> - Animated buttons with great choice of colors.
498
  </li>
499
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/icon-lists/" title="Icon List" target="_blank">Icon List</a> - - Create a list of icons with description and link - for social media profiles,
500
  for showcasing services or features as well with icons or images.
501
  </li>
502
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/faq-element/" title="FAQ Addon" target="_blank">FAQ</a> - Create a set of Frequently Asked Questions for display in a
503
  page.
504
  </li>
505
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/features/" title="Features Addon" target="_blank">Features Addon</a> for showcasing product features or services provided by an agency/business.
506
  </li>
507
  </ul>
508
 
509
  <div class="lvca-spacer" style="height: 15px"></div>
510
 
511
+ <a class="lvca-button purchase" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/"><i class="dashicons dashicons-cart"></i><?php echo __('Purchase Now', 'livemesh-vc-addons'); ?></a>
512
 
513
  <div class="lvca-spacer" style="height: 25px"></div>
514
 
518
  updated with additional features for existing elements -</p>
519
 
520
  <ul>
521
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/portfolio-grid-pro/" title="Posts Grid" target="_blank">Lazy Load</a> - The portfolio/post grid and image gallery elements
522
  incorporate option to lazy load posts/images with the click of a Load More button.
523
  </li>
524
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/portfolio-grid-pro/" title="Posts Grid" target="_blank">Pagination</a> - Create a grid of posts or custom post types with AJAX
525
  based pagination support.
526
  </li>
527
  <li><strong>Lightbox Support</strong> - The premium version comes with support for
570
 
571
  <div class="lvca-spacer" style="height: 25px"></div>
572
 
573
+ <a class="lvca-button purchase" href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/"><i class="dashicons dashicons-cart"></i><?php echo __('Go Premium', 'livemesh-vc-addons'); ?></a>
574
 
575
  </div>
576
 
assets/js/isotope.pkgd.js CHANGED
@@ -17,138 +17,138 @@
17
  /* jshint browser: true, strict: true, undef: true, unused: true */
18
 
19
  ( function( window, factory ) {
20
- // universal module definition
21
- /*jshint strict: false */ /* globals define, module, require */
22
- if ( typeof define == 'function' && define.amd ) {
23
- // AMD
24
- define( 'jquery-bridget/jquery-bridget',[ 'jquery' ], function( jQuery ) {
25
- return factory( window, jQuery );
26
- });
27
- } else if ( typeof module == 'object' && module.exports ) {
28
- // CommonJS
29
- module.exports = factory(
30
- window,
31
- require('jquery')
32
- );
33
- } else {
34
- // browser global
35
- window.jQueryBridget = factory(
36
- window,
37
- window.jQuery
38
- );
39
- }
40
 
41
  }( window, function factory( window, jQuery ) {
42
- 'use strict';
43
 
44
  // ----- utils ----- //
45
 
46
- var arraySlice = Array.prototype.slice;
47
 
48
  // helper function for logging errors
49
  // $.error breaks jQuery chaining
50
- var console = window.console;
51
- var logError = typeof console == 'undefined' ? function() {} :
52
- function( message ) {
53
- console.error( message );
54
- };
55
 
56
  // ----- jQueryBridget ----- //
57
 
58
- function jQueryBridget( namespace, PluginClass, $ ) {
59
- $ = $ || jQuery || window.jQuery;
60
- if ( !$ ) {
61
- return;
62
- }
63
-
64
- // add option method -> $().plugin('option', {...})
65
- if ( !PluginClass.prototype.option ) {
66
- // option setter
67
- PluginClass.prototype.option = function( opts ) {
68
- // bail out if not an object
69
- if ( !$.isPlainObject( opts ) ){
70
- return;
71
- }
72
- this.options = $.extend( true, this.options, opts );
73
- };
74
- }
75
-
76
- // make jQuery plugin
77
- $.fn[ namespace ] = function( arg0 /*, arg1 */ ) {
78
- if ( typeof arg0 == 'string' ) {
79
- // method call $().plugin( 'methodName', { options } )
80
- // shift arguments by 1
81
- var args = arraySlice.call( arguments, 1 );
82
- return methodCall( this, arg0, args );
83
- }
84
- // just $().plugin({ options })
85
- plainCall( this, arg0 );
86
- return this;
87
- };
88
-
89
- // $().plugin('methodName')
90
- function methodCall( $elems, methodName, args ) {
91
- var returnValue;
92
- var pluginMethodStr = '$().' + namespace + '("' + methodName + '")';
93
-
94
- $elems.each( function( i, elem ) {
95
- // get instance
96
- var instance = $.data( elem, namespace );
97
- if ( !instance ) {
98
- logError( namespace + ' not initialized. Cannot call methods, i.e. ' +
99
- pluginMethodStr );
100
- return;
101
- }
102
-
103
- var method = instance[ methodName ];
104
- if ( !method || methodName.charAt(0) == '_' ) {
105
- logError( pluginMethodStr + ' is not a valid method' );
106
- return;
107
- }
108
-
109
- // apply method, get return value
110
- var value = method.apply( instance, args );
111
- // set return value if value is returned, use only first value
112
- returnValue = returnValue === undefined ? value : returnValue;
113
- });
114
 
115
- return returnValue !== undefined ? returnValue : $elems;
116
- }
117
-
118
- function plainCall( $elems, options ) {
119
- $elems.each( function( i, elem ) {
120
- var instance = $.data( elem, namespace );
121
- if ( instance ) {
122
- // set options & init
123
- instance.option( options );
124
- instance._init();
125
- } else {
126
- // initialize new instance
127
- instance = new PluginClass( elem, options );
128
- $.data( elem, namespace, instance );
129
- }
130
- });
131
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
132
 
133
- updateJQuery( $ );
134
 
135
- }
136
 
137
  // ----- updateJQuery ----- //
138
 
139
  // set $.bridget for v1 backwards compatibility
140
- function updateJQuery( $ ) {
141
- if ( !$ || ( $ && $.bridget ) ) {
142
- return;
143
- }
144
- $.bridget = jQueryBridget;
145
- }
146
 
147
- updateJQuery( jQuery || window.jQuery );
148
 
149
  // ----- ----- //
150
 
151
- return jQueryBridget;
152
 
153
  }));
154
 
@@ -161,104 +161,104 @@ return jQueryBridget;
161
  /* jshint unused: true, undef: true, strict: true */
162
 
163
  ( function( global, factory ) {
164
- // universal module definition
165
- /* jshint strict: false */ /* globals define, module, window */
166
- if ( typeof define == 'function' && define.amd ) {
167
- // AMD - RequireJS
168
- define( 'ev-emitter/ev-emitter',factory );
169
- } else if ( typeof module == 'object' && module.exports ) {
170
- // CommonJS - Browserify, Webpack
171
- module.exports = factory();
172
- } else {
173
- // Browser globals
174
- global.EvEmitter = factory();
175
- }
176
 
177
  }( typeof window != 'undefined' ? window : this, function() {
178
 
179
 
180
 
181
- function EvEmitter() {}
182
-
183
- var proto = EvEmitter.prototype;
184
-
185
- proto.on = function( eventName, listener ) {
186
- if ( !eventName || !listener ) {
187
- return;
188
- }
189
- // set events hash
190
- var events = this._events = this._events || {};
191
- // set listeners array
192
- var listeners = events[ eventName ] = events[ eventName ] || [];
193
- // only add once
194
- if ( listeners.indexOf( listener ) == -1 ) {
195
- listeners.push( listener );
196
- }
197
-
198
- return this;
199
- };
200
-
201
- proto.once = function( eventName, listener ) {
202
- if ( !eventName || !listener ) {
203
- return;
204
- }
205
- // add event
206
- this.on( eventName, listener );
207
- // set once flag
208
- // set onceEvents hash
209
- var onceEvents = this._onceEvents = this._onceEvents || {};
210
- // set onceListeners object
211
- var onceListeners = onceEvents[ eventName ] = onceEvents[ eventName ] || {};
212
- // set flag
213
- onceListeners[ listener ] = true;
214
-
215
- return this;
216
- };
217
-
218
- proto.off = function( eventName, listener ) {
219
- var listeners = this._events && this._events[ eventName ];
220
- if ( !listeners || !listeners.length ) {
221
- return;
222
- }
223
- var index = listeners.indexOf( listener );
224
- if ( index != -1 ) {
225
- listeners.splice( index, 1 );
226
- }
227
-
228
- return this;
229
- };
230
-
231
- proto.emitEvent = function( eventName, args ) {
232
- var listeners = this._events && this._events[ eventName ];
233
- if ( !listeners || !listeners.length ) {
234
- return;
235
- }
236
- var i = 0;
237
- var listener = listeners[i];
238
- args = args || [];
239
- // once stuff
240
- var onceListeners = this._onceEvents && this._onceEvents[ eventName ];
241
-
242
- while ( listener ) {
243
- var isOnce = onceListeners && onceListeners[ listener ];
244
- if ( isOnce ) {
245
- // remove listener
246
- // remove before trigger to prevent recursion
247
- this.off( eventName, listener );
248
- // unset once flag
249
- delete onceListeners[ listener ];
250
- }
251
- // trigger listener
252
- listener.apply( this, args );
253
- // get next listener
254
- i += isOnce ? 0 : 1;
255
- listener = listeners[i];
256
- }
257
 
258
- return this;
259
- };
260
 
261
- return EvEmitter;
262
 
263
  }));
264
 
@@ -272,203 +272,203 @@ return EvEmitter;
272
  /*global define: false, module: false, console: false */
273
 
274
  ( function( window, factory ) {
275
- 'use strict';
276
-
277
- if ( typeof define == 'function' && define.amd ) {
278
- // AMD
279
- define( 'get-size/get-size',[],function() {
280
- return factory();
281
- });
282
- } else if ( typeof module == 'object' && module.exports ) {
283
- // CommonJS
284
- module.exports = factory();
285
- } else {
286
- // browser global
287
- window.getSize = factory();
288
- }
289
 
290
  })( window, function factory() {
291
- 'use strict';
292
 
293
  // -------------------------- helpers -------------------------- //
294
 
295
  // get a number from a string, not a percentage
296
- function getStyleSize( value ) {
297
- var num = parseFloat( value );
298
- // not a percent like '100%', and a number
299
- var isValid = value.indexOf('%') == -1 && !isNaN( num );
300
- return isValid && num;
301
- }
302
 
303
- function noop() {}
304
 
305
- var logError = typeof console == 'undefined' ? noop :
306
- function( message ) {
307
- console.error( message );
308
- };
309
 
310
  // -------------------------- measurements -------------------------- //
311
 
312
- var measurements = [
313
- 'paddingLeft',
314
- 'paddingRight',
315
- 'paddingTop',
316
- 'paddingBottom',
317
- 'marginLeft',
318
- 'marginRight',
319
- 'marginTop',
320
- 'marginBottom',
321
- 'borderLeftWidth',
322
- 'borderRightWidth',
323
- 'borderTopWidth',
324
- 'borderBottomWidth'
325
- ];
326
-
327
- var measurementsLength = measurements.length;
328
-
329
- function getZeroSize() {
330
- var size = {
331
- width: 0,
332
- height: 0,
333
- innerWidth: 0,
334
- innerHeight: 0,
335
- outerWidth: 0,
336
- outerHeight: 0
337
- };
338
- for ( var i=0; i < measurementsLength; i++ ) {
339
- var measurement = measurements[i];
340
- size[ measurement ] = 0;
341
- }
342
- return size;
343
- }
344
 
345
  // -------------------------- getStyle -------------------------- //
346
 
347
- /**
348
- * getStyle, get style of element, check for Firefox bug
349
- * https://bugzilla.mozilla.org/show_bug.cgi?id=548397
350
- */
351
- function getStyle( elem ) {
352
- var style = getComputedStyle( elem );
353
- if ( !style ) {
354
- logError( 'Style returned ' + style +
355
- '. Are you running this code in a hidden iframe on Firefox? ' +
356
- 'See http://bit.ly/getsizebug1' );
357
- }
358
- return style;
359
- }
360
 
361
  // -------------------------- setup -------------------------- //
362
 
363
- var isSetup = false;
364
 
365
- var isBoxSizeOuter;
366
 
367
- /**
368
- * setup
369
- * check isBoxSizerOuter
370
- * do on first getSize() rather than on page load for Firefox bug
371
- */
372
- function setup() {
373
- // setup once
374
- if ( isSetup ) {
375
- return;
376
- }
377
- isSetup = true;
378
-
379
- // -------------------------- box sizing -------------------------- //
380
-
381
- /**
382
- * WebKit measures the outer-width on style.width on border-box elems
383
- * IE & Firefox<29 measures the inner-width
384
- */
385
- var div = document.createElement('div');
386
- div.style.width = '200px';
387
- div.style.padding = '1px 2px 3px 4px';
388
- div.style.borderStyle = 'solid';
389
- div.style.borderWidth = '1px 2px 3px 4px';
390
- div.style.boxSizing = 'border-box';
391
-
392
- var body = document.body || document.documentElement;
393
- body.appendChild( div );
394
- var style = getStyle( div );
395
-
396
- getSize.isBoxSizeOuter = isBoxSizeOuter = getStyleSize( style.width ) == 200;
397
- body.removeChild( div );
398
-
399
- }
400
 
401
- // -------------------------- getSize -------------------------- //
402
 
403
- function getSize( elem ) {
404
- setup();
 
 
 
 
 
 
 
 
405
 
406
- // use querySeletor if elem is string
407
- if ( typeof elem == 'string' ) {
408
- elem = document.querySelector( elem );
409
- }
410
 
411
- // do not proceed on non-objects
412
- if ( !elem || typeof elem != 'object' || !elem.nodeType ) {
413
- return;
414
- }
415
 
416
- var style = getStyle( elem );
 
 
 
 
 
417
 
418
- // if hidden, everything is 0
419
- if ( style.display == 'none' ) {
420
- return getZeroSize();
421
- }
 
 
 
 
 
422
 
423
- var size = {};
424
- size.width = elem.offsetWidth;
425
- size.height = elem.offsetHeight;
426
 
427
- var isBorderBox = size.isBorderBox = style.boxSizing == 'border-box';
 
 
 
428
 
429
- // get all measurements
430
- for ( var i=0; i < measurementsLength; i++ ) {
431
- var measurement = measurements[i];
432
- var value = style[ measurement ];
433
- var num = parseFloat( value );
434
- // any 'auto', 'medium' value will be 0
435
- size[ measurement ] = !isNaN( num ) ? num : 0;
436
- }
437
 
438
- var paddingWidth = size.paddingLeft + size.paddingRight;
439
- var paddingHeight = size.paddingTop + size.paddingBottom;
440
- var marginWidth = size.marginLeft + size.marginRight;
441
- var marginHeight = size.marginTop + size.marginBottom;
442
- var borderWidth = size.borderLeftWidth + size.borderRightWidth;
443
- var borderHeight = size.borderTopWidth + size.borderBottomWidth;
444
 
445
- var isBorderBoxSizeOuter = isBorderBox && isBoxSizeOuter;
 
 
 
 
 
 
 
446
 
447
- // overwrite width and height if we can get it from style
448
- var styleWidth = getStyleSize( style.width );
449
- if ( styleWidth !== false ) {
450
- size.width = styleWidth +
451
- // add padding and border unless it's already including it
452
- ( isBorderBoxSizeOuter ? 0 : paddingWidth + borderWidth );
453
- }
 
 
 
 
 
 
 
 
 
454
 
455
- var styleHeight = getStyleSize( style.height );
456
- if ( styleHeight !== false ) {
457
- size.height = styleHeight +
458
- // add padding and border unless it's already including it
459
- ( isBorderBoxSizeOuter ? 0 : paddingHeight + borderHeight );
460
- }
461
 
462
- size.innerWidth = size.width - ( paddingWidth + borderWidth );
463
- size.innerHeight = size.height - ( paddingHeight + borderHeight );
464
 
465
- size.outerWidth = size.width + marginWidth;
466
- size.outerHeight = size.height + marginHeight;
467
 
468
- return size;
469
- }
470
 
471
- return getSize;
472
 
473
  });
474
 
@@ -481,48 +481,48 @@ return getSize;
481
  /*jshint browser: true, strict: true, undef: true, unused: true */
482
 
483
  ( function( window, factory ) {
484
- /*global define: false, module: false */
485
- 'use strict';
486
- // universal module definition
487
- if ( typeof define == 'function' && define.amd ) {
488
- // AMD
489
- define( 'desandro-matches-selector/matches-selector',factory );
490
- } else if ( typeof module == 'object' && module.exports ) {
491
- // CommonJS
492
- module.exports = factory();
493
- } else {
494
- // browser global
495
- window.matchesSelector = factory();
496
- }
497
 
498
  }( window, function factory() {
499
- 'use strict';
500
 
501
- var matchesMethod = ( function() {
502
- var ElemProto = Element.prototype;
503
- // check for the standard method name first
504
- if ( ElemProto.matches ) {
505
- return 'matches';
506
- }
507
- // check un-prefixed
508
- if ( ElemProto.matchesSelector ) {
509
- return 'matchesSelector';
510
- }
511
- // check vendor prefixes
512
- var prefixes = [ 'webkit', 'moz', 'ms', 'o' ];
513
-
514
- for ( var i=0; i < prefixes.length; i++ ) {
515
- var prefix = prefixes[i];
516
- var method = prefix + 'MatchesSelector';
517
- if ( ElemProto[ method ] ) {
518
- return method;
519
- }
520
- }
521
- })();
522
 
523
- return function matchesSelector( elem, selector ) {
524
- return elem[ matchesMethod ]( selector );
525
- };
526
 
527
  }));
528
 
@@ -534,233 +534,233 @@ return getSize;
534
  /*jshint browser: true, undef: true, unused: true, strict: true */
535
 
536
  ( function( window, factory ) {
537
- // universal module definition
538
- /*jshint strict: false */ /*globals define, module, require */
539
-
540
- if ( typeof define == 'function' && define.amd ) {
541
- // AMD
542
- define( 'fizzy-ui-utils/utils',[
543
- 'desandro-matches-selector/matches-selector'
544
- ], function( matchesSelector ) {
545
- return factory( window, matchesSelector );
546
- });
547
- } else if ( typeof module == 'object' && module.exports ) {
548
- // CommonJS
549
- module.exports = factory(
550
- window,
551
- require('desandro-matches-selector')
552
- );
553
- } else {
554
- // browser global
555
- window.fizzyUIUtils = factory(
556
- window,
557
- window.matchesSelector
558
- );
559
- }
560
 
561
  }( window, function factory( window, matchesSelector ) {
562
 
563
 
564
 
565
- var utils = {};
566
 
567
  // ----- extend ----- //
568
 
569
  // extends objects
570
- utils.extend = function( a, b ) {
571
- for ( var prop in b ) {
572
- a[ prop ] = b[ prop ];
573
- }
574
- return a;
575
- };
576
 
577
  // ----- modulo ----- //
578
 
579
- utils.modulo = function( num, div ) {
580
- return ( ( num % div ) + div ) % div;
581
- };
582
 
583
  // ----- makeArray ----- //
584
 
585
  // turn element or nodeList into an array
586
- utils.makeArray = function( obj ) {
587
- var ary = [];
588
- if ( Array.isArray( obj ) ) {
589
- // use object if already an array
590
- ary = obj;
591
- } else if ( obj && typeof obj.length == 'number' ) {
592
- // convert nodeList to array
593
- for ( var i=0; i < obj.length; i++ ) {
594
- ary.push( obj[i] );
595
- }
596
- } else {
597
- // array of single index
598
- ary.push( obj );
599
- }
600
- return ary;
601
- };
602
 
603
  // ----- removeFrom ----- //
604
 
605
- utils.removeFrom = function( ary, obj ) {
606
- var index = ary.indexOf( obj );
607
- if ( index != -1 ) {
608
- ary.splice( index, 1 );
609
- }
610
- };
611
 
612
  // ----- getParent ----- //
613
 
614
- utils.getParent = function( elem, selector ) {
615
- while ( elem != document.body ) {
616
- elem = elem.parentNode;
617
- if ( matchesSelector( elem, selector ) ) {
618
- return elem;
619
- }
620
- }
621
- };
622
 
623
  // ----- getQueryElement ----- //
624
 
625
  // use element as selector string
626
- utils.getQueryElement = function( elem ) {
627
- if ( typeof elem == 'string' ) {
628
- return document.querySelector( elem );
629
- }
630
- return elem;
631
- };
632
 
633
  // ----- handleEvent ----- //
634
 
635
  // enable .ontype to trigger from .addEventListener( elem, 'type' )
636
- utils.handleEvent = function( event ) {
637
- var method = 'on' + event.type;
638
- if ( this[ method ] ) {
639
- this[ method ]( event );
640
- }
641
- };
642
 
643
  // ----- filterFindElements ----- //
644
 
645
- utils.filterFindElements = function( elems, selector ) {
646
- // make array of elems
647
- elems = utils.makeArray( elems );
648
- var ffElems = [];
649
-
650
- elems.forEach( function( elem ) {
651
- // check that elem is an actual element
652
- if ( !( elem instanceof HTMLElement ) ) {
653
- return;
654
- }
655
- // add elem if no selector
656
- if ( !selector ) {
657
- ffElems.push( elem );
658
- return;
659
- }
660
- // filter & find items if we have a selector
661
- // filter
662
- if ( matchesSelector( elem, selector ) ) {
663
- ffElems.push( elem );
664
- }
665
- // find children
666
- var childElems = elem.querySelectorAll( selector );
667
- // concat childElems to filterFound array
668
- for ( var i=0; i < childElems.length; i++ ) {
669
- ffElems.push( childElems[i] );
670
- }
671
- });
672
-
673
- return ffElems;
674
- };
675
 
676
  // ----- debounceMethod ----- //
677
 
678
- utils.debounceMethod = function( _class, methodName, threshold ) {
679
- // original method
680
- var method = _class.prototype[ methodName ];
681
- var timeoutName = methodName + 'Timeout';
682
-
683
- _class.prototype[ methodName ] = function() {
684
- var timeout = this[ timeoutName ];
685
- if ( timeout ) {
686
- clearTimeout( timeout );
687
- }
688
- var args = arguments;
689
-
690
- var _this = this;
691
- this[ timeoutName ] = setTimeout( function() {
692
- method.apply( _this, args );
693
- delete _this[ timeoutName ];
694
- }, threshold || 100 );
695
- };
696
- };
697
 
698
  // ----- docReady ----- //
699
 
700
- utils.docReady = function( callback ) {
701
- var readyState = document.readyState;
702
- if ( readyState == 'complete' || readyState == 'interactive' ) {
703
- // do async to allow for other scripts to run. metafizzy/flickity#441
704
- setTimeout( callback );
705
- } else {
706
- document.addEventListener( 'DOMContentLoaded', callback );
707
- }
708
- };
709
 
710
  // ----- htmlInit ----- //
711
 
712
  // http://jamesroberts.name/blog/2010/02/22/string-functions-for-javascript-trim-to-camel-case-to-dashed-and-to-underscore/
713
- utils.toDashed = function( str ) {
714
- return str.replace( /(.)([A-Z])/g, function( match, $1, $2 ) {
715
- return $1 + '-' + $2;
716
- }).toLowerCase();
717
- };
718
-
719
- var console = window.console;
720
- /**
721
- * allow user to initialize classes via [data-namespace] or .js-namespace class
722
- * htmlInit( Widget, 'widgetName' )
723
- * options are parsed from data-namespace-options
724
- */
725
- utils.htmlInit = function( WidgetClass, namespace ) {
726
- utils.docReady( function() {
727
- var dashedNamespace = utils.toDashed( namespace );
728
- var dataAttr = 'data-' + dashedNamespace;
729
- var dataAttrElems = document.querySelectorAll( '[' + dataAttr + ']' );
730
- var jsDashElems = document.querySelectorAll( '.js-' + dashedNamespace );
731
- var elems = utils.makeArray( dataAttrElems )
732
- .concat( utils.makeArray( jsDashElems ) );
733
- var dataOptionsAttr = dataAttr + '-options';
734
- var jQuery = window.jQuery;
735
-
736
- elems.forEach( function( elem ) {
737
- var attr = elem.getAttribute( dataAttr ) ||
738
- elem.getAttribute( dataOptionsAttr );
739
- var options;
740
- try {
741
- options = attr && JSON.parse( attr );
742
- } catch ( error ) {
743
- // log error, do not initialize
744
- if ( console ) {
745
- console.error( 'Error parsing ' + dataAttr + ' on ' + elem.className +
746
- ': ' + error );
747
- }
748
- return;
749
- }
750
- // initialize
751
- var instance = new WidgetClass( elem, options );
752
- // make available via $().data('namespace')
753
- if ( jQuery ) {
754
- jQuery.data( elem, namespace, instance );
755
- }
756
- });
757
 
758
- });
759
- };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
760
 
761
  // ----- ----- //
762
 
763
- return utils;
764
 
765
  }));
766
 
@@ -769,552 +769,552 @@ return utils;
769
  */
770
 
771
  ( function( window, factory ) {
772
- // universal module definition
773
- /* jshint strict: false */ /* globals define, module, require */
774
- if ( typeof define == 'function' && define.amd ) {
775
- // AMD - RequireJS
776
- define( 'outlayer/item',[
777
- 'ev-emitter/ev-emitter',
778
- 'get-size/get-size'
779
- ],
780
- factory
781
- );
782
- } else if ( typeof module == 'object' && module.exports ) {
783
- // CommonJS - Browserify, Webpack
784
- module.exports = factory(
785
- require('ev-emitter'),
786
- require('get-size')
787
- );
788
- } else {
789
- // browser global
790
- window.Outlayer = {};
791
- window.Outlayer.Item = factory(
792
- window.EvEmitter,
793
- window.getSize
794
- );
795
- }
796
 
797
  }( window, function factory( EvEmitter, getSize ) {
798
- 'use strict';
799
 
800
  // ----- helpers ----- //
801
 
802
- function isEmptyObj( obj ) {
803
- for ( var prop in obj ) {
804
- return false;
805
- }
806
- prop = null;
807
- return true;
808
- }
809
 
810
  // -------------------------- CSS3 support -------------------------- //
811
 
812
 
813
- var docElemStyle = document.documentElement.style;
814
 
815
- var transitionProperty = typeof docElemStyle.transition == 'string' ?
816
- 'transition' : 'WebkitTransition';
817
- var transformProperty = typeof docElemStyle.transform == 'string' ?
818
- 'transform' : 'WebkitTransform';
819
 
820
- var transitionEndEvent = {
821
- WebkitTransition: 'webkitTransitionEnd',
822
- transition: 'transitionend'
823
- }[ transitionProperty ];
824
 
825
  // cache all vendor properties that could have vendor prefix
826
- var vendorProperties = {
827
- transform: transformProperty,
828
- transition: transitionProperty,
829
- transitionDuration: transitionProperty + 'Duration',
830
- transitionProperty: transitionProperty + 'Property',
831
- transitionDelay: transitionProperty + 'Delay'
832
- };
833
 
834
  // -------------------------- Item -------------------------- //
835
 
836
- function Item( element, layout ) {
837
- if ( !element ) {
838
- return;
839
- }
840
 
841
- this.element = element;
842
- // parent layout class, i.e. Masonry, Isotope, or Packery
843
- this.layout = layout;
844
- this.position = {
845
- x: 0,
846
- y: 0
847
- };
848
 
849
- this._create();
850
- }
851
 
852
  // inherit EvEmitter
853
- var proto = Item.prototype = Object.create( EvEmitter.prototype );
854
- proto.constructor = Item;
855
-
856
- proto._create = function() {
857
- // transition objects
858
- this._transn = {
859
- ingProperties: {},
860
- clean: {},
861
- onEnd: {}
862
- };
863
-
864
- this.css({
865
- position: 'absolute'
866
- });
867
- };
868
 
869
  // trigger specified handler for event type
870
- proto.handleEvent = function( event ) {
871
- var method = 'on' + event.type;
872
- if ( this[ method ] ) {
873
- this[ method ]( event );
874
- }
875
- };
876
 
877
- proto.getSize = function() {
878
- this.size = getSize( this.element );
879
- };
880
 
881
- /**
882
- * apply CSS styles to element
883
- * @param {Object} style
884
- */
885
- proto.css = function( style ) {
886
- var elemStyle = this.element.style;
887
-
888
- for ( var prop in style ) {
889
- // use vendor property if available
890
- var supportedProp = vendorProperties[ prop ] || prop;
891
- elemStyle[ supportedProp ] = style[ prop ];
892
- }
893
- };
894
-
895
- // measure position, and sets it
896
- proto.getPosition = function() {
897
- var style = getComputedStyle( this.element );
898
- var isOriginLeft = this.layout._getOption('originLeft');
899
- var isOriginTop = this.layout._getOption('originTop');
900
- var xValue = style[ isOriginLeft ? 'left' : 'right' ];
901
- var yValue = style[ isOriginTop ? 'top' : 'bottom' ];
902
- // convert percent to pixels
903
- var layoutSize = this.layout.size;
904
- var x = xValue.indexOf('%') != -1 ?
905
- ( parseFloat( xValue ) / 100 ) * layoutSize.width : parseInt( xValue, 10 );
906
- var y = yValue.indexOf('%') != -1 ?
907
- ( parseFloat( yValue ) / 100 ) * layoutSize.height : parseInt( yValue, 10 );
908
-
909
- // clean up 'auto' or other non-integer values
910
- x = isNaN( x ) ? 0 : x;
911
- y = isNaN( y ) ? 0 : y;
912
- // remove padding from measurement
913
- x -= isOriginLeft ? layoutSize.paddingLeft : layoutSize.paddingRight;
914
- y -= isOriginTop ? layoutSize.paddingTop : layoutSize.paddingBottom;
915
-
916
- this.position.x = x;
917
- this.position.y = y;
918
- };
919
 
920
  // set settled position, apply padding
921
- proto.layoutPosition = function() {
922
- var layoutSize = this.layout.size;
923
- var style = {};
924
- var isOriginLeft = this.layout._getOption('originLeft');
925
- var isOriginTop = this.layout._getOption('originTop');
926
-
927
- // x
928
- var xPadding = isOriginLeft ? 'paddingLeft' : 'paddingRight';
929
- var xProperty = isOriginLeft ? 'left' : 'right';
930
- var xResetProperty = isOriginLeft ? 'right' : 'left';
931
-
932
- var x = this.position.x + layoutSize[ xPadding ];
933
- // set in percentage or pixels
934
- style[ xProperty ] = this.getXValue( x );
935
- // reset other property
936
- style[ xResetProperty ] = '';
937
-
938
- // y
939
- var yPadding = isOriginTop ? 'paddingTop' : 'paddingBottom';
940
- var yProperty = isOriginTop ? 'top' : 'bottom';
941
- var yResetProperty = isOriginTop ? 'bottom' : 'top';
942
-
943
- var y = this.position.y + layoutSize[ yPadding ];
944
- // set in percentage or pixels
945
- style[ yProperty ] = this.getYValue( y );
946
- // reset other property
947
- style[ yResetProperty ] = '';
948
-
949
- this.css( style );
950
- this.emitEvent( 'layout', [ this ] );
951
- };
952
-
953
- proto.getXValue = function( x ) {
954
- var isHorizontal = this.layout._getOption('horizontal');
955
- return this.layout.options.percentPosition && !isHorizontal ?
956
- ( ( x / this.layout.size.width ) * 100 ) + '%' : x + 'px';
957
- };
958
-
959
- proto.getYValue = function( y ) {
960
- var isHorizontal = this.layout._getOption('horizontal');
961
- return this.layout.options.percentPosition && isHorizontal ?
962
- ( ( y / this.layout.size.height ) * 100 ) + '%' : y + 'px';
963
- };
964
-
965
- proto._transitionTo = function( x, y ) {
966
- this.getPosition();
967
- // get current x & y from top/left
968
- var curX = this.position.x;
969
- var curY = this.position.y;
970
-
971
- var compareX = parseInt( x, 10 );
972
- var compareY = parseInt( y, 10 );
973
- var didNotMove = compareX === this.position.x && compareY === this.position.y;
974
-
975
- // save end position
976
- this.setPosition( x, y );
977
-
978
- // if did not move and not transitioning, just go to layout
979
- if ( didNotMove && !this.isTransitioning ) {
980
- this.layoutPosition();
981
- return;
982
- }
983
-
984
- var transX = x - curX;
985
- var transY = y - curY;
986
- var transitionStyle = {};
987
- transitionStyle.transform = this.getTranslate( transX, transY );
988
-
989
- this.transition({
990
- to: transitionStyle,
991
- onTransitionEnd: {
992
- transform: this.layoutPosition
993
- },
994
- isCleaning: true
995
- });
996
- };
997
-
998
- proto.getTranslate = function( x, y ) {
999
- // flip cooridinates if origin on right or bottom
1000
- var isOriginLeft = this.layout._getOption('originLeft');
1001
- var isOriginTop = this.layout._getOption('originTop');
1002
- x = isOriginLeft ? x : -x;
1003
- y = isOriginTop ? y : -y;
1004
- return 'translate3d(' + x + 'px, ' + y + 'px, 0)';
1005
- };
1006
 
1007
  // non transition + transform support
1008
- proto.goTo = function( x, y ) {
1009
- this.setPosition( x, y );
1010
- this.layoutPosition();
1011
- };
1012
 
1013
- proto.moveTo = proto._transitionTo;
1014
 
1015
- proto.setPosition = function( x, y ) {
1016
- this.position.x = parseInt( x, 10 );
1017
- this.position.y = parseInt( y, 10 );
1018
- };
1019
 
1020
  // ----- transition ----- //
1021
 
1022
- /**
1023
- * @param {Object} style - CSS
1024
- * @param {Function} onTransitionEnd
1025
- */
1026
 
1027
  // non transition, just trigger callback
1028
- proto._nonTransition = function( args ) {
1029
- this.css( args.to );
1030
- if ( args.isCleaning ) {
1031
- this._removeStyles( args.to );
1032
- }
1033
- for ( var prop in args.onTransitionEnd ) {
1034
- args.onTransitionEnd[ prop ].call( this );
1035
- }
1036
- };
1037
 
1038
- /**
1039
- * proper transition
1040
- * @param {Object} args - arguments
1041
- * @param {Object} to - style to transition to
1042
- * @param {Object} from - style to start transition from
1043
- * @param {Boolean} isCleaning - removes transition styles after transition
1044
- * @param {Function} onTransitionEnd - callback
1045
- */
1046
- proto.transition = function( args ) {
1047
- // redirect to nonTransition if no transition duration
1048
- if ( !parseFloat( this.layout.options.transitionDuration ) ) {
1049
- this._nonTransition( args );
1050
- return;
1051
- }
1052
-
1053
- var _transition = this._transn;
1054
- // keep track of onTransitionEnd callback by css property
1055
- for ( var prop in args.onTransitionEnd ) {
1056
- _transition.onEnd[ prop ] = args.onTransitionEnd[ prop ];
1057
- }
1058
- // keep track of properties that are transitioning
1059
- for ( prop in args.to ) {
1060
- _transition.ingProperties[ prop ] = true;
1061
- // keep track of properties to clean up when transition is done
1062
- if ( args.isCleaning ) {
1063
- _transition.clean[ prop ] = true;
1064
- }
1065
- }
1066
 
1067
- // set from styles
1068
- if ( args.from ) {
1069
- this.css( args.from );
1070
- // force redraw. http://blog.alexmaccaw.com/css-transitions
1071
- var h = this.element.offsetHeight;
1072
- // hack for JSHint to hush about unused var
1073
- h = null;
1074
- }
1075
- // enable transition
1076
- this.enableTransition( args.to );
1077
- // set styles that are transitioning
1078
- this.css( args.to );
1079
 
1080
- this.isTransitioning = true;
1081
 
1082
- };
1083
 
1084
  // dash before all cap letters, including first for
1085
  // WebkitTransform => -webkit-transform
1086
- function toDashedAll( str ) {
1087
- return str.replace( /([A-Z])/g, function( $1 ) {
1088
- return '-' + $1.toLowerCase();
1089
- });
1090
- }
1091
-
1092
- var transitionProps = 'opacity,' + toDashedAll( transformProperty );
1093
-
1094
- proto.enableTransition = function(/* style */) {
1095
- // HACK changing transitionProperty during a transition
1096
- // will cause transition to jump
1097
- if ( this.isTransitioning ) {
1098
- return;
1099
- }
1100
-
1101
- // make `transition: foo, bar, baz` from style object
1102
- // HACK un-comment this when enableTransition can work
1103
- // while a transition is happening
1104
- // var transitionValues = [];
1105
- // for ( var prop in style ) {
1106
- // // dash-ify camelCased properties like WebkitTransition
1107
- // prop = vendorProperties[ prop ] || prop;
1108
- // transitionValues.push( toDashedAll( prop ) );
1109
- // }
1110
- // munge number to millisecond, to match stagger
1111
- var duration = this.layout.options.transitionDuration;
1112
- duration = typeof duration == 'number' ? duration + 'ms' : duration;
1113
- // enable transition styles
1114
- this.css({
1115
- transitionProperty: transitionProps,
1116
- transitionDuration: duration,
1117
- transitionDelay: this.staggerDelay || 0
1118
- });
1119
- // listen for transition end event
1120
- this.element.addEventListener( transitionEndEvent, this, false );
1121
- };
1122
 
1123
  // ----- events ----- //
1124
 
1125
- proto.onwebkitTransitionEnd = function( event ) {
1126
- this.ontransitionend( event );
1127
- };
1128
 
1129
- proto.onotransitionend = function( event ) {
1130
- this.ontransitionend( event );
1131
- };
1132
 
1133
  // properties that I munge to make my life easier
1134
- var dashedVendorProperties = {
1135
- '-webkit-transform': 'transform'
1136
- };
1137
-
1138
- proto.ontransitionend = function( event ) {
1139
- // disregard bubbled events from children
1140
- if ( event.target !== this.element ) {
1141
- return;
1142
- }
1143
- var _transition = this._transn;
1144
- // get property name of transitioned property, convert to prefix-free
1145
- var propertyName = dashedVendorProperties[ event.propertyName ] || event.propertyName;
1146
-
1147
- // remove property that has completed transitioning
1148
- delete _transition.ingProperties[ propertyName ];
1149
- // check if any properties are still transitioning
1150
- if ( isEmptyObj( _transition.ingProperties ) ) {
1151
- // all properties have completed transitioning
1152
- this.disableTransition();
1153
- }
1154
- // clean style
1155
- if ( propertyName in _transition.clean ) {
1156
- // clean up style
1157
- this.element.style[ event.propertyName ] = '';
1158
- delete _transition.clean[ propertyName ];
1159
- }
1160
- // trigger onTransitionEnd callback
1161
- if ( propertyName in _transition.onEnd ) {
1162
- var onTransitionEnd = _transition.onEnd[ propertyName ];
1163
- onTransitionEnd.call( this );
1164
- delete _transition.onEnd[ propertyName ];
1165
- }
1166
-
1167
- this.emitEvent( 'transitionEnd', [ this ] );
1168
- };
1169
-
1170
- proto.disableTransition = function() {
1171
- this.removeTransitionStyles();
1172
- this.element.removeEventListener( transitionEndEvent, this, false );
1173
- this.isTransitioning = false;
1174
- };
1175
 
1176
- /**
1177
- * removes style property from element
1178
- * @param {Object} style
1179
- **/
1180
- proto._removeStyles = function( style ) {
1181
- // clean up transition styles
1182
- var cleanStyle = {};
1183
- for ( var prop in style ) {
1184
- cleanStyle[ prop ] = '';
1185
- }
1186
- this.css( cleanStyle );
1187
- };
1188
-
1189
- var cleanTransitionStyle = {
1190
- transitionProperty: '',
1191
- transitionDuration: '',
1192
- transitionDelay: ''
1193
- };
1194
-
1195
- proto.removeTransitionStyles = function() {
1196
- // remove transition
1197
- this.css( cleanTransitionStyle );
1198
- };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1199
 
1200
  // ----- stagger ----- //
1201
 
1202
- proto.stagger = function( delay ) {
1203
- delay = isNaN( delay ) ? 0 : delay;
1204
- this.staggerDelay = delay + 'ms';
1205
- };
1206
 
1207
  // ----- show/hide/remove ----- //
1208
 
1209
  // remove element from DOM
1210
- proto.removeElem = function() {
1211
- this.element.parentNode.removeChild( this.element );
1212
- // remove display: none
1213
- this.css({ display: '' });
1214
- this.emitEvent( 'remove', [ this ] );
1215
- };
1216
-
1217
- proto.remove = function() {
1218
- // just remove element if no transition support or no transition
1219
- if ( !transitionProperty || !parseFloat( this.layout.options.transitionDuration ) ) {
1220
- this.removeElem();
1221
- return;
1222
- }
1223
-
1224
- // start transition
1225
- this.once( 'transitionEnd', function() {
1226
- this.removeElem();
1227
- });
1228
- this.hide();
1229
- };
1230
-
1231
- proto.reveal = function() {
1232
- delete this.isHidden;
1233
- // remove display: none
1234
- this.css({ display: '' });
1235
-
1236
- var options = this.layout.options;
1237
-
1238
- var onTransitionEnd = {};
1239
- var transitionEndProperty = this.getHideRevealTransitionEndProperty('visibleStyle');
1240
- onTransitionEnd[ transitionEndProperty ] = this.onRevealTransitionEnd;
1241
-
1242
- this.transition({
1243
- from: options.hiddenStyle,
1244
- to: options.visibleStyle,
1245
- isCleaning: true,
1246
- onTransitionEnd: onTransitionEnd
1247
- });
1248
- };
1249
-
1250
- proto.onRevealTransitionEnd = function() {
1251
- // check if still visible
1252
- // during transition, item may have been hidden
1253
- if ( !this.isHidden ) {
1254
- this.emitEvent('reveal');
1255
- }
1256
- };
1257
 
1258
- /**
1259
- * get style property use for hide/reveal transition end
1260
- * @param {String} styleProperty - hiddenStyle/visibleStyle
1261
- * @returns {String}
1262
- */
1263
- proto.getHideRevealTransitionEndProperty = function( styleProperty ) {
1264
- var optionStyle = this.layout.options[ styleProperty ];
1265
- // use opacity
1266
- if ( optionStyle.opacity ) {
1267
- return 'opacity';
1268
- }
1269
- // get first property
1270
- for ( var prop in optionStyle ) {
1271
- return prop;
1272
- }
1273
- };
1274
-
1275
- proto.hide = function() {
1276
- // set flag
1277
- this.isHidden = true;
1278
- // remove display: none
1279
- this.css({ display: '' });
1280
-
1281
- var options = this.layout.options;
1282
-
1283
- var onTransitionEnd = {};
1284
- var transitionEndProperty = this.getHideRevealTransitionEndProperty('hiddenStyle');
1285
- onTransitionEnd[ transitionEndProperty ] = this.onHideTransitionEnd;
1286
-
1287
- this.transition({
1288
- from: options.visibleStyle,
1289
- to: options.hiddenStyle,
1290
- // keep hidden stuff hidden
1291
- isCleaning: true,
1292
- onTransitionEnd: onTransitionEnd
1293
- });
1294
- };
1295
-
1296
- proto.onHideTransitionEnd = function() {
1297
- // check if still hidden
1298
- // during transition, item may have been un-hidden
1299
- if ( this.isHidden ) {
1300
- this.css({ display: 'none' });
1301
- this.emitEvent('hide');
1302
- }
1303
- };
1304
-
1305
- proto.destroy = function() {
1306
- this.css({
1307
- position: '',
1308
- left: '',
1309
- right: '',
1310
- top: '',
1311
- bottom: '',
1312
- transition: '',
1313
- transform: ''
1314
- });
1315
- };
1316
-
1317
- return Item;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1318
 
1319
  }));
1320
 
@@ -1325,1014 +1325,1014 @@ return Item;
1325
  */
1326
 
1327
  ( function( window, factory ) {
1328
- 'use strict';
1329
- // universal module definition
1330
- /* jshint strict: false */ /* globals define, module, require */
1331
- if ( typeof define == 'function' && define.amd ) {
1332
- // AMD - RequireJS
1333
- define( 'outlayer/outlayer',[
1334
- 'ev-emitter/ev-emitter',
1335
- 'get-size/get-size',
1336
- 'fizzy-ui-utils/utils',
1337
- './item'
1338
- ],
1339
- function( EvEmitter, getSize, utils, Item ) {
1340
- return factory( window, EvEmitter, getSize, utils, Item);
1341
- }
1342
- );
1343
- } else if ( typeof module == 'object' && module.exports ) {
1344
- // CommonJS - Browserify, Webpack
1345
- module.exports = factory(
1346
- window,
1347
- require('ev-emitter'),
1348
- require('get-size'),
1349
- require('fizzy-ui-utils'),
1350
- require('./item')
1351
- );
1352
- } else {
1353
- // browser global
1354
- window.Outlayer = factory(
1355
- window,
1356
- window.EvEmitter,
1357
- window.getSize,
1358
- window.fizzyUIUtils,
1359
- window.Outlayer.Item
1360
- );
1361
- }
1362
 
1363
  }( window, function factory( window, EvEmitter, getSize, utils, Item ) {
1364
- 'use strict';
1365
 
1366
  // ----- vars ----- //
1367
 
1368
- var console = window.console;
1369
- var jQuery = window.jQuery;
1370
- var noop = function() {};
1371
 
1372
  // -------------------------- Outlayer -------------------------- //
1373
 
1374
  // globally unique identifiers
1375
- var GUID = 0;
1376
  // internal store of all Outlayer intances
1377
- var instances = {};
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1378
 
 
 
 
1379
 
1380
- /**
1381
- * @param {Element, String} element
1382
- * @param {Object} options
1383
- * @constructor
1384
- */
1385
- function Outlayer( element, options ) {
1386
- var queryElement = utils.getQueryElement( element );
1387
- if ( !queryElement ) {
1388
- if ( console ) {
1389
- console.error( 'Bad element for ' + this.constructor.namespace +
1390
- ': ' + ( queryElement || element ) );
 
1391
  }
1392
- return;
1393
- }
1394
- this.element = queryElement;
1395
- // add jQuery
1396
- if ( jQuery ) {
1397
- this.$element = jQuery( this.element );
1398
- }
1399
-
1400
- // options
1401
- this.options = utils.extend( {}, this.constructor.defaults );
1402
- this.option( options );
1403
-
1404
- // add id for Outlayer.getFromElement
1405
- var id = ++GUID;
1406
- this.element.outlayerGUID = id; // expando
1407
- instances[ id ] = this; // associate via id
1408
-
1409
- // kick it off
1410
- this._create();
1411
-
1412
- var isInitLayout = this._getOption('initLayout');
1413
- if ( isInitLayout ) {
1414
- this.layout();
1415
- }
1416
- }
1417
 
1418
  // settings are for internal use only
1419
- Outlayer.namespace = 'outlayer';
1420
- Outlayer.Item = Item;
1421
 
1422
  // default options
1423
- Outlayer.defaults = {
1424
- containerStyle: {
1425
- position: 'relative'
1426
- },
1427
- initLayout: true,
1428
- originLeft: true,
1429
- originTop: true,
1430
- resize: true,
1431
- resizeContainer: true,
1432
- // item options
1433
- transitionDuration: '0.4s',
1434
- hiddenStyle: {
1435
- opacity: 0,
1436
- transform: 'scale(0.001)'
1437
- },
1438
- visibleStyle: {
1439
- opacity: 1,
1440
- transform: 'scale(1)'
1441
- }
1442
- };
1443
-
1444
- var proto = Outlayer.prototype;
1445
  // inherit EvEmitter
1446
- utils.extend( proto, EvEmitter.prototype );
 
 
 
 
 
 
 
 
1447
 
1448
- /**
1449
- * set options
1450
- * @param {Object} opts
1451
- */
1452
- proto.option = function( opts ) {
1453
- utils.extend( this.options, opts );
1454
- };
 
1455
 
1456
- /**
1457
- * get backwards compatible option value, check old name
1458
- */
1459
- proto._getOption = function( option ) {
1460
- var oldOption = this.constructor.compatOptions[ option ];
1461
- return oldOption && this.options[ oldOption ] !== undefined ?
1462
- this.options[ oldOption ] : this.options[ option ];
1463
- };
1464
-
1465
- Outlayer.compatOptions = {
1466
- // currentName: oldName
1467
- initLayout: 'isInitLayout',
1468
- horizontal: 'isHorizontal',
1469
- layoutInstant: 'isLayoutInstant',
1470
- originLeft: 'isOriginLeft',
1471
- originTop: 'isOriginTop',
1472
- resize: 'isResizeBound',
1473
- resizeContainer: 'isResizingContainer'
1474
- };
1475
-
1476
- proto._create = function() {
1477
- // get items from children
1478
- this.reloadItems();
1479
- // elements that affect layout, but are not laid out
1480
- this.stamps = [];
1481
- this.stamp( this.options.stamp );
1482
- // set container style
1483
- utils.extend( this.element.style, this.options.containerStyle );
1484
-
1485
- // bind resize method
1486
- var canBindResize = this._getOption('resize');
1487
- if ( canBindResize ) {
1488
- this.bindResize();
1489
- }
1490
- };
1491
 
1492
  // goes through all children again and gets bricks in proper order
1493
- proto.reloadItems = function() {
1494
- // collection of item elements
1495
- this.items = this._itemize( this.element.children );
1496
- };
1497
 
1498
 
1499
- /**
1500
- * turn elements into Outlayer.Items to be used in layout
1501
- * @param {Array or NodeList or HTMLElement} elems
1502
- * @returns {Array} items - collection of new Outlayer Items
1503
- */
1504
- proto._itemize = function( elems ) {
1505
 
1506
- var itemElems = this._filterFindItemElements( elems );
1507
- var Item = this.constructor.Item;
1508
 
1509
- // create new Outlayer Items for collection
1510
- var items = [];
1511
- for ( var i=0; i < itemElems.length; i++ ) {
1512
- var elem = itemElems[i];
1513
- var item = new Item( elem, this );
1514
- items.push( item );
1515
- }
1516
 
1517
- return items;
1518
- };
1519
 
1520
- /**
1521
- * get item elements to be used in layout
1522
- * @param {Array or NodeList or HTMLElement} elems
1523
- * @returns {Array} items - item elements
1524
- */
1525
- proto._filterFindItemElements = function( elems ) {
1526
- return utils.filterFindElements( elems, this.options.itemSelector );
1527
- };
1528
 
1529
- /**
1530
- * getter method for getting item elements
1531
- * @returns {Array} elems - collection of item elements
1532
- */
1533
- proto.getItemElements = function() {
1534
- return this.items.map( function( item ) {
1535
- return item.element;
1536
- });
1537
- };
1538
 
1539
  // ----- init & layout ----- //
1540
 
1541
- /**
1542
- * lays out all items
1543
- */
1544
- proto.layout = function() {
1545
- this._resetLayout();
1546
- this._manageStamps();
 
 
 
 
 
 
 
 
 
 
1547
 
1548
- // don't animate first layout
1549
- var layoutInstant = this._getOption('layoutInstant');
1550
- var isInstant = layoutInstant !== undefined ?
1551
- layoutInstant : !this._isLayoutInited;
1552
- this.layoutItems( this.items, isInstant );
1553
 
1554
- // flag for initalized
1555
- this._isLayoutInited = true;
1556
- };
 
 
 
1557
 
1558
- // _init is alias for layout
1559
- proto._init = proto.layout;
1560
 
1561
- /**
1562
- * logic before any new layout
1563
- */
1564
- proto._resetLayout = function() {
1565
- this.getSize();
1566
- };
1567
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1568
 
1569
- proto.getSize = function() {
1570
- this.size = getSize( this.element );
1571
- };
 
 
 
1572
 
1573
- /**
1574
- * get measurement from option, for columnWidth, rowHeight, gutter
1575
- * if option is String -> get element from selector string, & get size of element
1576
- * if option is Element -> get size of element
1577
- * else use option as a number
1578
- *
1579
- * @param {String} measurement
1580
- * @param {String} size - width or height
1581
- * @private
1582
- */
1583
- proto._getMeasurement = function( measurement, size ) {
1584
- var option = this.options[ measurement ];
1585
- var elem;
1586
- if ( !option ) {
1587
- // default to 0
1588
- this[ measurement ] = 0;
1589
- } else {
1590
- // use option as an element
1591
- if ( typeof option == 'string' ) {
1592
- elem = this.element.querySelector( option );
1593
- } else if ( option instanceof HTMLElement ) {
1594
- elem = option;
1595
- }
1596
- // use size of element, if element
1597
- this[ measurement ] = elem ? getSize( elem )[ size ] : option;
1598
- }
1599
- };
1600
 
1601
- /**
1602
- * layout a collection of item elements
1603
- * @api public
1604
- */
1605
- proto.layoutItems = function( items, isInstant ) {
1606
- items = this._getItemsForLayout( items );
1607
 
1608
- this._layoutItems( items, isInstant );
 
 
 
 
 
 
 
 
 
 
1609
 
1610
- this._postLayout();
1611
- };
 
 
 
 
 
 
 
 
 
 
1612
 
1613
- /**
1614
- * get the items to be laid out
1615
- * you may want to skip over some items
1616
- * @param {Array} items
1617
- * @returns {Array} items
1618
- */
1619
- proto._getItemsForLayout = function( items ) {
1620
- return items.filter( function( item ) {
1621
- return !item.isIgnored;
1622
- });
1623
- };
1624
 
1625
- /**
1626
- * layout items
1627
- * @param {Array} items
1628
- * @param {Boolean} isInstant
1629
- */
1630
- proto._layoutItems = function( items, isInstant ) {
1631
- this._emitCompleteOnItems( 'layout', items );
 
1632
 
1633
- if ( !items || !items.length ) {
1634
- // no items, emit event with empty array
1635
- return;
1636
- }
1637
 
1638
- var queue = [];
 
 
 
 
 
 
 
 
 
 
1639
 
1640
- items.forEach( function( item ) {
1641
- // get x/y object from method
1642
- var position = this._getItemLayoutPosition( item );
1643
- // enqueue
1644
- position.item = item;
1645
- position.isInstant = isInstant || item.isLayoutInstant;
1646
- queue.push( position );
1647
- }, this );
 
 
 
 
1648
 
1649
- this._processLayoutQueue( queue );
1650
- };
 
 
 
 
 
 
 
 
1651
 
1652
- /**
1653
- * get item layout position
1654
- * @param {Outlayer.Item} item
1655
- * @returns {Object} x and y position
1656
- */
1657
- proto._getItemLayoutPosition = function( /* item */ ) {
1658
- return {
1659
- x: 0,
1660
- y: 0
1661
- };
1662
- };
 
 
 
 
 
1663
 
1664
- /**
1665
- * iterate over array and position each item
1666
- * Reason being - separating this logic prevents 'layout invalidation'
1667
- * thx @paul_irish
1668
- * @param {Array} queue
1669
- */
1670
- proto._processLayoutQueue = function( queue ) {
1671
- this.updateStagger();
1672
- queue.forEach( function( obj, i ) {
1673
- this._positionItem( obj.item, obj.x, obj.y, obj.isInstant, i );
1674
- }, this );
1675
- };
1676
 
1677
- // set stagger from option in milliseconds number
1678
- proto.updateStagger = function() {
1679
- var stagger = this.options.stagger;
1680
- if ( stagger === null || stagger === undefined ) {
1681
- this.stagger = 0;
1682
- return;
1683
- }
1684
- this.stagger = getMilliseconds( stagger );
1685
- return this.stagger;
1686
- };
 
1687
 
1688
- /**
1689
- * Sets position of item in DOM
1690
- * @param {Outlayer.Item} item
1691
- * @param {Number} x - horizontal position
1692
- * @param {Number} y - vertical position
1693
- * @param {Boolean} isInstant - disables transitions
1694
- */
1695
- proto._positionItem = function( item, x, y, isInstant, i ) {
1696
- if ( isInstant ) {
1697
- // if not transition, just set CSS
1698
- item.goTo( x, y );
1699
- } else {
1700
- item.stagger( i * this.stagger );
1701
- item.moveTo( x, y );
1702
- }
1703
- };
1704
 
1705
- /**
1706
- * Any logic you want to do after each layout,
1707
- * i.e. size the container
1708
- */
1709
- proto._postLayout = function() {
1710
- this.resizeContainer();
1711
- };
1712
-
1713
- proto.resizeContainer = function() {
1714
- var isResizingContainer = this._getOption('resizeContainer');
1715
- if ( !isResizingContainer ) {
1716
- return;
1717
- }
1718
- var size = this._getContainerSize();
1719
- if ( size ) {
1720
- this._setContainerMeasure( size.width, true );
1721
- this._setContainerMeasure( size.height, false );
1722
- }
1723
- };
1724
 
1725
- /**
1726
- * Sets width or height of container if returned
1727
- * @returns {Object} size
1728
- * @param {Number} width
1729
- * @param {Number} height
1730
- */
1731
- proto._getContainerSize = noop;
1732
 
1733
- /**
1734
- * @param {Number} measure - size of width or height
1735
- * @param {Boolean} isWidth
1736
- */
1737
- proto._setContainerMeasure = function( measure, isWidth ) {
1738
- if ( measure === undefined ) {
1739
- return;
1740
- }
1741
-
1742
- var elemSize = this.size;
1743
- // add padding and border width if border box
1744
- if ( elemSize.isBorderBox ) {
1745
- measure += isWidth ? elemSize.paddingLeft + elemSize.paddingRight +
1746
- elemSize.borderLeftWidth + elemSize.borderRightWidth :
1747
- elemSize.paddingBottom + elemSize.paddingTop +
1748
- elemSize.borderTopWidth + elemSize.borderBottomWidth;
1749
- }
1750
-
1751
- measure = Math.max( measure, 0 );
1752
- this.element.style[ isWidth ? 'width' : 'height' ] = measure + 'px';
1753
- };
1754
 
1755
- /**
1756
- * emit eventComplete on a collection of items events
1757
- * @param {String} eventName
1758
- * @param {Array} items - Outlayer.Items
1759
- */
1760
- proto._emitCompleteOnItems = function( eventName, items ) {
1761
- var _this = this;
1762
- function onComplete() {
1763
- _this.dispatchEvent( eventName + 'Complete', null, [ items ] );
1764
- }
1765
-
1766
- var count = items.length;
1767
- if ( !items || !count ) {
1768
- onComplete();
1769
- return;
1770
- }
1771
-
1772
- var doneCount = 0;
1773
- function tick() {
1774
- doneCount++;
1775
- if ( doneCount == count ) {
1776
- onComplete();
1777
- }
1778
- }
1779
 
1780
- // bind callback
1781
- items.forEach( function( item ) {
1782
- item.once( eventName, tick );
1783
- });
1784
- };
 
 
1785
 
1786
- /**
1787
- * emits events via EvEmitter and jQuery events
1788
- * @param {String} type - name of event
1789
- * @param {Event} event - original event
1790
- * @param {Array} args - extra arguments
1791
- */
1792
- proto.dispatchEvent = function( type, event, args ) {
1793
- // add original event to arguments
1794
- var emitArgs = event ? [ event ].concat( args ) : args;
1795
- this.emitEvent( type, emitArgs );
1796
-
1797
- if ( jQuery ) {
1798
- // set this.$element
1799
- this.$element = this.$element || jQuery( this.element );
1800
- if ( event ) {
1801
- // create jQuery event
1802
- var $event = jQuery.Event( event );
1803
- $event.type = type;
1804
- this.$element.trigger( $event, args );
1805
- } else {
1806
- // just trigger with type if no event available
1807
- this.$element.trigger( type, args );
1808
- }
1809
- }
1810
- };
 
 
 
 
 
 
1811
 
1812
  // -------------------------- ignore & stamps -------------------------- //
1813
 
1814
 
1815
- /**
1816
- * keep item in collection, but do not lay it out
1817
- * ignored items do not get skipped in layout
1818
- * @param {Element} elem
1819
- */
1820
- proto.ignore = function( elem ) {
1821
- var item = this.getItem( elem );
1822
- if ( item ) {
1823
- item.isIgnored = true;
1824
- }
1825
- };
1826
 
1827
- /**
1828
- * return item to layout collection
1829
- * @param {Element} elem
1830
- */
1831
- proto.unignore = function( elem ) {
1832
- var item = this.getItem( elem );
1833
- if ( item ) {
1834
- delete item.isIgnored;
1835
- }
1836
- };
1837
 
1838
- /**
1839
- * adds elements to stamps
1840
- * @param {NodeList, Array, Element, or String} elems
1841
- */
1842
- proto.stamp = function( elems ) {
1843
- elems = this._find( elems );
1844
- if ( !elems ) {
1845
- return;
1846
- }
1847
 
1848
- this.stamps = this.stamps.concat( elems );
1849
- // ignore
1850
- elems.forEach( this.ignore, this );
1851
- };
1852
 
1853
- /**
1854
- * removes elements to stamps
1855
- * @param {NodeList, Array, or Element} elems
1856
- */
1857
- proto.unstamp = function( elems ) {
1858
- elems = this._find( elems );
1859
- if ( !elems ){
1860
- return;
1861
- }
1862
-
1863
- elems.forEach( function( elem ) {
1864
- // filter out removed stamp elements
1865
- utils.removeFrom( this.stamps, elem );
1866
- this.unignore( elem );
1867
- }, this );
1868
- };
1869
 
1870
- /**
1871
- * finds child elements
1872
- * @param {NodeList, Array, Element, or String} elems
1873
- * @returns {Array} elems
1874
- */
1875
- proto._find = function( elems ) {
1876
- if ( !elems ) {
1877
- return;
1878
- }
1879
- // if string, use argument as selector string
1880
- if ( typeof elems == 'string' ) {
1881
- elems = this.element.querySelectorAll( elems );
1882
- }
1883
- elems = utils.makeArray( elems );
1884
- return elems;
1885
- };
1886
-
1887
- proto._manageStamps = function() {
1888
- if ( !this.stamps || !this.stamps.length ) {
1889
- return;
1890
- }
1891
-
1892
- this._getBoundingRect();
1893
-
1894
- this.stamps.forEach( this._manageStamp, this );
1895
- };
1896
 
1897
- // update boundingLeft / Top
1898
- proto._getBoundingRect = function() {
1899
- // get bounding rect for container element
1900
- var boundingRect = this.element.getBoundingClientRect();
1901
- var size = this.size;
1902
- this._boundingRect = {
1903
- left: boundingRect.left + size.paddingLeft + size.borderLeftWidth,
1904
- top: boundingRect.top + size.paddingTop + size.borderTopWidth,
1905
- right: boundingRect.right - ( size.paddingRight + size.borderRightWidth ),
1906
- bottom: boundingRect.bottom - ( size.paddingBottom + size.borderBottomWidth )
1907
- };
1908
- };
 
 
 
 
1909
 
1910
- /**
1911
- * @param {Element} stamp
1912
- **/
1913
- proto._manageStamp = noop;
1914
 
1915
- /**
1916
- * get x/y position of element relative to container element
1917
- * @param {Element} elem
1918
- * @returns {Object} offset - has left, top, right, bottom
1919
- */
1920
- proto._getElementOffset = function( elem ) {
1921
- var boundingRect = elem.getBoundingClientRect();
1922
- var thisRect = this._boundingRect;
1923
- var size = getSize( elem );
1924
- var offset = {
1925
- left: boundingRect.left - thisRect.left - size.marginLeft,
1926
- top: boundingRect.top - thisRect.top - size.marginTop,
1927
- right: thisRect.right - boundingRect.right - size.marginRight,
1928
- bottom: thisRect.bottom - boundingRect.bottom - size.marginBottom
1929
- };
1930
- return offset;
1931
- };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1932
 
1933
  // -------------------------- resize -------------------------- //
1934
 
1935
  // enable event handlers for listeners
1936
  // i.e. resize -> onresize
1937
- proto.handleEvent = utils.handleEvent;
1938
-
1939
- /**
1940
- * Bind layout to window resizing
1941
- */
1942
- proto.bindResize = function() {
1943
- window.addEventListener( 'resize', this );
1944
- this.isResizeBound = true;
1945
- };
1946
 
1947
- /**
1948
- * Unbind layout to window resizing
1949
- */
1950
- proto.unbindResize = function() {
1951
- window.removeEventListener( 'resize', this );
1952
- this.isResizeBound = false;
1953
- };
1954
 
1955
- proto.onresize = function() {
1956
- this.resize();
1957
- };
1958
 
1959
- utils.debounceMethod( Outlayer, 'onresize', 100 );
1960
 
1961
- proto.resize = function() {
1962
- // don't trigger if size did not change
1963
- // or if resize was unbound. See #9
1964
- if ( !this.isResizeBound || !this.needsResizeLayout() ) {
1965
- return;
1966
- }
1967
 
1968
- this.layout();
1969
- };
1970
 
1971
- /**
1972
- * check if layout is needed post layout
1973
- * @returns Boolean
1974
- */
1975
- proto.needsResizeLayout = function() {
1976
- var size = getSize( this.element );
1977
- // check that this.size and size are there
1978
- // IE8 triggers resize on body size change, so they might not be
1979
- var hasSizes = this.size && size;
1980
- return hasSizes && size.innerWidth !== this.size.innerWidth;
1981
- };
1982
 
1983
  // -------------------------- methods -------------------------- //
1984
 
1985
- /**
1986
- * add items to Outlayer instance
1987
- * @param {Array or NodeList or Element} elems
1988
- * @returns {Array} items - Outlayer.Items
1989
- **/
1990
- proto.addItems = function( elems ) {
1991
- var items = this._itemize( elems );
1992
- // add items to collection
1993
- if ( items.length ) {
1994
- this.items = this.items.concat( items );
1995
- }
1996
- return items;
1997
- };
1998
-
1999
- /**
2000
- * Layout newly-appended item elements
2001
- * @param {Array or NodeList or Element} elems
2002
- */
2003
- proto.appended = function( elems ) {
2004
- var items = this.addItems( elems );
2005
- if ( !items.length ) {
2006
- return;
2007
- }
2008
- // layout and reveal just the new items
2009
- this.layoutItems( items, true );
2010
- this.reveal( items );
2011
- };
2012
 
2013
- /**
2014
- * Layout prepended elements
2015
- * @param {Array or NodeList or Element} elems
2016
- */
2017
- proto.prepended = function( elems ) {
2018
- var items = this._itemize( elems );
2019
- if ( !items.length ) {
2020
- return;
2021
- }
2022
- // add items to beginning of collection
2023
- var previousItems = this.items.slice(0);
2024
- this.items = items.concat( previousItems );
2025
- // start new layout
2026
- this._resetLayout();
2027
- this._manageStamps();
2028
- // layout new stuff without transition
2029
- this.layoutItems( items, true );
2030
- this.reveal( items );
2031
- // layout previous items
2032
- this.layoutItems( previousItems );
2033
- };
2034
 
2035
- /**
2036
- * reveal a collection of items
2037
- * @param {Array of Outlayer.Items} items
2038
- */
2039
- proto.reveal = function( items ) {
2040
- this._emitCompleteOnItems( 'reveal', items );
2041
- if ( !items || !items.length ) {
2042
- return;
2043
- }
2044
- var stagger = this.updateStagger();
2045
- items.forEach( function( item, i ) {
2046
- item.stagger( i * stagger );
2047
- item.reveal();
2048
- });
2049
- };
 
 
 
 
 
 
2050
 
2051
- /**
2052
- * hide a collection of items
2053
- * @param {Array of Outlayer.Items} items
2054
- */
2055
- proto.hide = function( items ) {
2056
- this._emitCompleteOnItems( 'hide', items );
2057
- if ( !items || !items.length ) {
2058
- return;
2059
- }
2060
- var stagger = this.updateStagger();
2061
- items.forEach( function( item, i ) {
2062
- item.stagger( i * stagger );
2063
- item.hide();
2064
- });
2065
- };
2066
 
2067
- /**
2068
- * reveal item elements
2069
- * @param {Array}, {Element}, {NodeList} items
2070
- */
2071
- proto.revealItemElements = function( elems ) {
2072
- var items = this.getItems( elems );
2073
- this.reveal( items );
2074
- };
 
 
 
 
 
 
 
2075
 
2076
- /**
2077
- * hide item elements
2078
- * @param {Array}, {Element}, {NodeList} items
2079
- */
2080
- proto.hideItemElements = function( elems ) {
2081
- var items = this.getItems( elems );
2082
- this.hide( items );
2083
- };
2084
 
2085
- /**
2086
- * get Outlayer.Item, given an Element
2087
- * @param {Element} elem
2088
- * @param {Function} callback
2089
- * @returns {Outlayer.Item} item
2090
- */
2091
- proto.getItem = function( elem ) {
2092
- // loop through items to get the one that matches
2093
- for ( var i=0; i < this.items.length; i++ ) {
2094
- var item = this.items[i];
2095
- if ( item.element == elem ) {
2096
- // return item
2097
- return item;
2098
- }
2099
- }
2100
- };
2101
 
2102
- /**
2103
- * get collection of Outlayer.Items, given Elements
2104
- * @param {Array} elems
2105
- * @returns {Array} items - Outlayer.Items
2106
- */
2107
- proto.getItems = function( elems ) {
2108
- elems = utils.makeArray( elems );
2109
- var items = [];
2110
- elems.forEach( function( elem ) {
2111
- var item = this.getItem( elem );
2112
- if ( item ) {
2113
- items.push( item );
2114
- }
2115
- }, this );
 
 
2116
 
2117
- return items;
2118
- };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2119
 
2120
- /**
2121
- * remove element(s) from instance and DOM
2122
- * @param {Array or NodeList or Element} elems
2123
- */
2124
- proto.remove = function( elems ) {
2125
- var removeItems = this.getItems( elems );
2126
 
2127
- this._emitCompleteOnItems( 'remove', removeItems );
2128
 
2129
- // bail if no items to remove
2130
- if ( !removeItems || !removeItems.length ) {
2131
- return;
2132
- }
2133
 
2134
- removeItems.forEach( function( item ) {
2135
- item.remove();
2136
- // remove item from collection
2137
- utils.removeFrom( this.items, item );
2138
- }, this );
2139
- };
2140
 
2141
  // ----- destroy ----- //
2142
 
2143
  // remove and disable Outlayer instance
2144
- proto.destroy = function() {
2145
- // clean up dynamic styles
2146
- var style = this.element.style;
2147
- style.height = '';
2148
- style.position = '';
2149
- style.width = '';
2150
- // destroy items
2151
- this.items.forEach( function( item ) {
2152
- item.destroy();
2153
- });
2154
-
2155
- this.unbindResize();
2156
-
2157
- var id = this.element.outlayerGUID;
2158
- delete instances[ id ]; // remove reference to instance by id
2159
- delete this.element.outlayerGUID;
2160
- // remove data for jQuery
2161
- if ( jQuery ) {
2162
- jQuery.removeData( this.element, this.constructor.namespace );
2163
- }
2164
-
2165
- };
2166
 
2167
  // -------------------------- data -------------------------- //
2168
 
2169
- /**
2170
- * get Outlayer instance from element
2171
- * @param {Element} elem
2172
- * @returns {Outlayer}
2173
- */
2174
- Outlayer.data = function( elem ) {
2175
- elem = utils.getQueryElement( elem );
2176
- var id = elem && elem.outlayerGUID;
2177
- return id && instances[ id ];
2178
- };
2179
 
2180
 
2181
  // -------------------------- create Outlayer class -------------------------- //
2182
 
2183
- /**
2184
- * create a layout class
2185
- * @param {String} namespace
2186
- */
2187
- Outlayer.create = function( namespace, options ) {
2188
- // sub-class Outlayer
2189
- var Layout = subclass( Outlayer );
2190
- // apply new options and compatOptions
2191
- Layout.defaults = utils.extend( {}, Outlayer.defaults );
2192
- utils.extend( Layout.defaults, options );
2193
- Layout.compatOptions = utils.extend( {}, Outlayer.compatOptions );
2194
 
2195
- Layout.namespace = namespace;
2196
 
2197
- Layout.data = Outlayer.data;
2198
 
2199
- // sub-class Item
2200
- Layout.Item = subclass( Item );
2201
 
2202
- // -------------------------- declarative -------------------------- //
2203
 
2204
- utils.htmlInit( Layout, namespace );
2205
 
2206
- // -------------------------- jQuery bridge -------------------------- //
2207
 
2208
- // make into jQuery plugin
2209
- if ( jQuery && jQuery.bridget ) {
2210
- jQuery.bridget( namespace, Layout );
2211
- }
2212
 
2213
- return Layout;
2214
- };
2215
 
2216
- function subclass( Parent ) {
2217
- function SubClass() {
2218
- Parent.apply( this, arguments );
2219
- }
2220
 
2221
- SubClass.prototype = Object.create( Parent.prototype );
2222
- SubClass.prototype.constructor = SubClass;
2223
 
2224
- return SubClass;
2225
- }
2226
 
2227
  // ----- helpers ----- //
2228
 
2229
  // how many milliseconds are in each unit
2230
- var msUnits = {
2231
- ms: 1,
2232
- s: 1000
2233
- };
2234
 
2235
  // munge time-like parameter into millisecond number
2236
  // '0.4s' -> 40
2237
- function getMilliseconds( time ) {
2238
- if ( typeof time == 'number' ) {
2239
- return time;
2240
- }
2241
- var matches = time.match( /(^\d*\.?\d*)(\w*)/ );
2242
- var num = matches && matches[1];
2243
- var unit = matches && matches[2];
2244
- if ( !num.length ) {
2245
- return 0;
2246
- }
2247
- num = parseFloat( num );
2248
- var mult = msUnits[ unit ] || 1;
2249
- return num * mult;
2250
- }
2251
 
2252
  // ----- fin ----- //
2253
 
2254
  // back in global
2255
- Outlayer.Item = Item;
2256
 
2257
- return Outlayer;
2258
 
2259
  }));
2260
 
2261
  /**
2262
  * Isotope Item
2263
- **/
2264
 
2265
  ( function( window, factory ) {
2266
- // universal module definition
2267
- /* jshint strict: false */ /*globals define, module, require */
2268
- if ( typeof define == 'function' && define.amd ) {
2269
- // AMD
2270
- define( 'isotope/js/item',[
2271
- 'outlayer/outlayer'
2272
- ],
2273
- factory );
2274
- } else if ( typeof module == 'object' && module.exports ) {
2275
- // CommonJS
2276
- module.exports = factory(
2277
- require('outlayer')
2278
- );
2279
- } else {
2280
- // browser global
2281
- window.Isotope = window.Isotope || {};
2282
- window.Isotope.Item = factory(
2283
- window.Outlayer
2284
- );
2285
- }
2286
 
2287
  }( window, function factory( Outlayer ) {
2288
- 'use strict';
2289
 
2290
  // -------------------------- Item -------------------------- //
2291
 
2292
  // sub-class Outlayer Item
2293
- function Item() {
2294
- Outlayer.Item.apply( this, arguments );
2295
- }
2296
-
2297
- var proto = Item.prototype = Object.create( Outlayer.Item.prototype );
2298
-
2299
- var _create = proto._create;
2300
- proto._create = function() {
2301
- // assign id, used for original-order sorting
2302
- this.id = this.layout.itemGUID++;
2303
- _create.call( this );
2304
- this.sortData = {};
2305
- };
2306
-
2307
- proto.updateSortData = function() {
2308
- if ( this.isIgnored ) {
2309
- return;
2310
- }
2311
- // default sorters
2312
- this.sortData.id = this.id;
2313
- // for backward compatibility
2314
- this.sortData['original-order'] = this.id;
2315
- this.sortData.random = Math.random();
2316
- // go thru getSortData obj and apply the sorters
2317
- var getSortData = this.layout.options.getSortData;
2318
- var sorters = this.layout._sorters;
2319
- for ( var key in getSortData ) {
2320
- var sorter = sorters[ key ];
2321
- this.sortData[ key ] = sorter( this.element, this );
2322
- }
2323
- };
2324
-
2325
- var _destroy = proto.destroy;
2326
- proto.destroy = function() {
2327
- // call super
2328
- _destroy.apply( this, arguments );
2329
- // reset display, #741
2330
- this.css({
2331
- display: ''
2332
- });
2333
- };
2334
-
2335
- return Item;
2336
 
2337
  }));
2338
 
@@ -2341,156 +2341,156 @@ return Item;
2341
  */
2342
 
2343
  ( function( window, factory ) {
2344
- // universal module definition
2345
- /* jshint strict: false */ /*globals define, module, require */
2346
- if ( typeof define == 'function' && define.amd ) {
2347
- // AMD
2348
- define( 'isotope/js/layout-mode',[
2349
- 'get-size/get-size',
2350
- 'outlayer/outlayer'
2351
- ],
2352
- factory );
2353
- } else if ( typeof module == 'object' && module.exports ) {
2354
- // CommonJS
2355
- module.exports = factory(
2356
- require('get-size'),
2357
- require('outlayer')
2358
- );
2359
- } else {
2360
- // browser global
2361
- window.Isotope = window.Isotope || {};
2362
- window.Isotope.LayoutMode = factory(
2363
- window.getSize,
2364
- window.Outlayer
2365
- );
2366
- }
2367
 
2368
  }( window, function factory( getSize, Outlayer ) {
2369
- 'use strict';
2370
-
2371
- // layout mode class
2372
- function LayoutMode( isotope ) {
2373
- this.isotope = isotope;
2374
- // link properties
2375
- if ( isotope ) {
2376
- this.options = isotope.options[ this.namespace ];
2377
- this.element = isotope.element;
2378
- this.items = isotope.filteredItems;
2379
- this.size = isotope.size;
2380
- }
2381
- }
2382
-
2383
- var proto = LayoutMode.prototype;
2384
-
2385
- /**
2386
- * some methods should just defer to default Outlayer method
2387
- * and reference the Isotope instance as `this`
2388
- **/
2389
- var facadeMethods = [
2390
- '_resetLayout',
2391
- '_getItemLayoutPosition',
2392
- '_manageStamp',
2393
- '_getContainerSize',
2394
- '_getElementOffset',
2395
- 'needsResizeLayout',
2396
- '_getOption'
2397
- ];
2398
-
2399
- facadeMethods.forEach( function( methodName ) {
2400
- proto[ methodName ] = function() {
2401
- return Outlayer.prototype[ methodName ].apply( this.isotope, arguments );
2402
- };
2403
- });
2404
-
2405
- // ----- ----- //
2406
-
2407
- // for horizontal layout modes, check vertical size
2408
- proto.needsVerticalResizeLayout = function() {
2409
- // don't trigger if size did not change
2410
- var size = getSize( this.isotope.element );
2411
- // check that this.size and size are there
2412
- // IE8 triggers resize on body size change, so they might not be
2413
- var hasSizes = this.isotope.size && size;
2414
- return hasSizes && size.innerHeight != this.isotope.size.innerHeight;
2415
- };
2416
-
2417
- // ----- measurements ----- //
2418
-
2419
- proto._getMeasurement = function() {
2420
- this.isotope._getMeasurement.apply( this, arguments );
2421
- };
2422
-
2423
- proto.getColumnWidth = function() {
2424
- this.getSegmentSize( 'column', 'Width' );
2425
- };
2426
-
2427
- proto.getRowHeight = function() {
2428
- this.getSegmentSize( 'row', 'Height' );
2429
- };
2430
-
2431
- /**
2432
- * get columnWidth or rowHeight
2433
- * segment: 'column' or 'row'
2434
- * size 'Width' or 'Height'
2435
- **/
2436
- proto.getSegmentSize = function( segment, size ) {
2437
- var segmentName = segment + size;
2438
- var outerSize = 'outer' + size;
2439
- // columnWidth / outerWidth // rowHeight / outerHeight
2440
- this._getMeasurement( segmentName, outerSize );
2441
- // got rowHeight or columnWidth, we can chill
2442
- if ( this[ segmentName ] ) {
2443
- return;
2444
  }
2445
- // fall back to item of first element
2446
- var firstItemSize = this.getFirstItemSize();
2447
- this[ segmentName ] = firstItemSize && firstItemSize[ outerSize ] ||
2448
- // or size of container
2449
- this.isotope.size[ 'inner' + size ];
2450
- };
2451
 
2452
- proto.getFirstItemSize = function() {
2453
- var firstItem = this.isotope.filteredItems[0];
2454
- return firstItem && firstItem.element && getSize( firstItem.element );
2455
- };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2456
 
2457
- // ----- methods that should reference isotope ----- //
 
 
 
 
 
 
 
 
 
 
2458
 
2459
- proto.layout = function() {
2460
- this.isotope.layout.apply( this.isotope, arguments );
2461
- };
2462
 
2463
- proto.getSize = function() {
2464
- this.isotope.getSize();
2465
- this.size = this.isotope.size;
2466
- };
2467
 
2468
- // -------------------------- create -------------------------- //
 
 
2469
 
2470
- LayoutMode.modes = {};
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2471
 
2472
- LayoutMode.create = function( namespace, options ) {
 
 
 
2473
 
2474
- function Mode() {
2475
- LayoutMode.apply( this, arguments );
2476
- }
2477
 
2478
- Mode.prototype = Object.create( proto );
2479
- Mode.prototype.constructor = Mode;
 
2480
 
2481
- // default options
2482
- if ( options ) {
2483
- Mode.options = options;
2484
- }
2485
 
2486
- Mode.prototype.namespace = namespace;
2487
- // register in Isotope
2488
- LayoutMode.modes[ namespace ] = Mode;
2489
 
2490
- return Mode;
2491
- };
2492
 
2493
- return LayoutMode;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2494
 
2495
  }));
2496
 
@@ -2503,28 +2503,28 @@ return Item;
2503
  */
2504
 
2505
  ( function( window, factory ) {
2506
- // universal module definition
2507
- /* jshint strict: false */ /*globals define, module, require */
2508
- if ( typeof define == 'function' && define.amd ) {
2509
- // AMD
2510
- define( 'masonry/masonry',[
2511
- 'outlayer/outlayer',
2512
- 'get-size/get-size'
2513
- ],
2514
- factory );
2515
- } else if ( typeof module == 'object' && module.exports ) {
2516
- // CommonJS
2517
- module.exports = factory(
2518
- require('outlayer'),
2519
- require('get-size')
2520
- );
2521
- } else {
2522
- // browser global
2523
- window.Masonry = factory(
2524
- window.Outlayer,
2525
- window.getSize
2526
- );
2527
- }
2528
 
2529
  }( window, function factory( Outlayer, getSize ) {
2530
 
@@ -2532,171 +2532,171 @@ return Item;
2532
 
2533
  // -------------------------- masonryDefinition -------------------------- //
2534
 
2535
- // create an Outlayer layout class
2536
- var Masonry = Outlayer.create('masonry');
2537
- // isFitWidth -> fitWidth
2538
- Masonry.compatOptions.fitWidth = 'isFitWidth';
2539
-
2540
- Masonry.prototype._resetLayout = function() {
2541
- this.getSize();
2542
- this._getMeasurement( 'columnWidth', 'outerWidth' );
2543
- this._getMeasurement( 'gutter', 'outerWidth' );
2544
- this.measureColumns();
2545
-
2546
- // reset column Y
2547
- this.colYs = [];
2548
- for ( var i=0; i < this.cols; i++ ) {
2549
- this.colYs.push( 0 );
2550
- }
2551
 
2552
- this.maxY = 0;
2553
- };
2554
-
2555
- Masonry.prototype.measureColumns = function() {
2556
- this.getContainerWidth();
2557
- // if columnWidth is 0, default to outerWidth of first item
2558
- if ( !this.columnWidth ) {
2559
- var firstItem = this.items[0];
2560
- var firstItemElem = firstItem && firstItem.element;
2561
- // columnWidth fall back to item of first element
2562
- this.columnWidth = firstItemElem && getSize( firstItemElem ).outerWidth ||
2563
- // if first elem has no width, default to size of container
2564
- this.containerWidth;
2565
- }
2566
 
2567
- var columnWidth = this.columnWidth += this.gutter;
2568
-
2569
- // calculate columns
2570
- var containerWidth = this.containerWidth + this.gutter;
2571
- var cols = containerWidth / columnWidth;
2572
- // fix rounding errors, typically with gutters
2573
- var excess = columnWidth - containerWidth % columnWidth;
2574
- // if overshoot is less than a pixel, round up, otherwise floor it
2575
- var mathMethod = excess && excess < 1 ? 'round' : 'floor';
2576
- cols = Math[ mathMethod ]( cols );
2577
- this.cols = Math.max( cols, 1 );
2578
- };
2579
-
2580
- Masonry.prototype.getContainerWidth = function() {
2581
- // container is parent if fit width
2582
- var isFitWidth = this._getOption('fitWidth');
2583
- var container = isFitWidth ? this.element.parentNode : this.element;
2584
- // check that this.size and size are there
2585
- // IE8 triggers resize on body size change, so they might not be
2586
- var size = getSize( container );
2587
- this.containerWidth = size && size.innerWidth;
2588
- };
2589
-
2590
- Masonry.prototype._getItemLayoutPosition = function( item ) {
2591
- item.getSize();
2592
- // how many columns does this brick span
2593
- var remainder = item.size.outerWidth % this.columnWidth;
2594
- var mathMethod = remainder && remainder < 1 ? 'round' : 'ceil';
2595
- // round if off by 1 pixel, otherwise use ceil
2596
- var colSpan = Math[ mathMethod ]( item.size.outerWidth / this.columnWidth );
2597
- colSpan = Math.min( colSpan, this.cols );
2598
-
2599
- var colGroup = this._getColGroup( colSpan );
2600
- // get the minimum Y value from the columns
2601
- var minimumY = Math.min.apply( Math, colGroup );
2602
- var shortColIndex = colGroup.indexOf( minimumY );
2603
-
2604
- // position the brick
2605
- var position = {
2606
- x: this.columnWidth * shortColIndex,
2607
- y: minimumY
2608
- };
2609
-
2610
- // apply setHeight to necessary columns
2611
- var setHeight = minimumY + item.size.outerHeight;
2612
- var setSpan = this.cols + 1 - colGroup.length;
2613
- for ( var i = 0; i < setSpan; i++ ) {
2614
- this.colYs[ shortColIndex + i ] = setHeight;
2615
- }
2616
 
2617
- return position;
2618
- };
2619
-
2620
- /**
2621
- * @param {Number} colSpan - number of columns the element spans
2622
- * @returns {Array} colGroup
2623
- */
2624
- Masonry.prototype._getColGroup = function( colSpan ) {
2625
- if ( colSpan < 2 ) {
2626
- // if brick spans only one column, use all the column Ys
2627
- return this.colYs;
2628
- }
2629
 
2630
- var colGroup = [];
2631
- // how many different places could this brick fit horizontally
2632
- var groupCount = this.cols + 1 - colSpan;
2633
- // for each group potential horizontal position
2634
- for ( var i = 0; i < groupCount; i++ ) {
2635
- // make an array of colY values for that one group
2636
- var groupColYs = this.colYs.slice( i, i + colSpan );
2637
- // and get the max value of the array
2638
- colGroup[i] = Math.max.apply( Math, groupColYs );
2639
- }
2640
- return colGroup;
2641
- };
2642
-
2643
- Masonry.prototype._manageStamp = function( stamp ) {
2644
- var stampSize = getSize( stamp );
2645
- var offset = this._getElementOffset( stamp );
2646
- // get the columns that this stamp affects
2647
- var isOriginLeft = this._getOption('originLeft');
2648
- var firstX = isOriginLeft ? offset.left : offset.right;
2649
- var lastX = firstX + stampSize.outerWidth;
2650
- var firstCol = Math.floor( firstX / this.columnWidth );
2651
- firstCol = Math.max( 0, firstCol );
2652
- var lastCol = Math.floor( lastX / this.columnWidth );
2653
- // lastCol should not go over if multiple of columnWidth #425
2654
- lastCol -= lastX % this.columnWidth ? 0 : 1;
2655
- lastCol = Math.min( this.cols - 1, lastCol );
2656
- // set colYs to bottom of the stamp
2657
-
2658
- var isOriginTop = this._getOption('originTop');
2659
- var stampMaxY = ( isOriginTop ? offset.top : offset.bottom ) +
2660
- stampSize.outerHeight;
2661
- for ( var i = firstCol; i <= lastCol; i++ ) {
2662
- this.colYs[i] = Math.max( stampMaxY, this.colYs[i] );
2663
- }
2664
- };
 
2665
 
2666
- Masonry.prototype._getContainerSize = function() {
2667
- this.maxY = Math.max.apply( Math, this.colYs );
2668
- var size = {
2669
- height: this.maxY
2670
  };
2671
 
2672
- if ( this._getOption('fitWidth') ) {
2673
- size.width = this._getContainerFitWidth();
2674
- }
 
 
 
 
 
 
2675
 
2676
- return size;
2677
- };
2678
-
2679
- Masonry.prototype._getContainerFitWidth = function() {
2680
- var unusedCols = 0;
2681
- // count unused columns
2682
- var i = this.cols;
2683
- while ( --i ) {
2684
- if ( this.colYs[i] !== 0 ) {
2685
- break;
2686
- }
2687
- unusedCols++;
2688
- }
2689
- // fit container to columns that have been used
2690
- return ( this.cols - unusedCols ) * this.columnWidth - this.gutter;
2691
- };
2692
 
2693
- Masonry.prototype.needsResizeLayout = function() {
2694
- var previousWidth = this.containerWidth;
2695
- this.getContainerWidth();
2696
- return previousWidth != this.containerWidth;
2697
- };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2698
 
2699
- return Masonry;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2700
 
2701
  }));
2702
 
@@ -2707,71 +2707,71 @@ return Item;
2707
  */
2708
 
2709
  ( function( window, factory ) {
2710
- // universal module definition
2711
- /* jshint strict: false */ /*globals define, module, require */
2712
- if ( typeof define == 'function' && define.amd ) {
2713
- // AMD
2714
- define( 'isotope/js/layout-modes/masonry',[
2715
- '../layout-mode',
2716
- 'masonry/masonry'
2717
- ],
2718
- factory );
2719
- } else if ( typeof module == 'object' && module.exports ) {
2720
- // CommonJS
2721
- module.exports = factory(
2722
- require('../layout-mode'),
2723
- require('masonry-layout')
2724
- );
2725
- } else {
2726
- // browser global
2727
- factory(
2728
- window.Isotope.LayoutMode,
2729
- window.Masonry
2730
- );
2731
- }
2732
 
2733
  }( window, function factory( LayoutMode, Masonry ) {
2734
- 'use strict';
2735
 
2736
  // -------------------------- masonryDefinition -------------------------- //
2737
 
2738
- // create an Outlayer layout class
2739
- var MasonryMode = LayoutMode.create('masonry');
2740
 
2741
- var proto = MasonryMode.prototype;
2742
 
2743
- var keepModeMethods = {
2744
- _getElementOffset: true,
2745
- layout: true,
2746
- _getMeasurement: true
2747
- };
2748
 
2749
- // inherit Masonry prototype
2750
- for ( var method in Masonry.prototype ) {
2751
- // do not inherit mode methods
2752
- if ( !keepModeMethods[ method ] ) {
2753
- proto[ method ] = Masonry.prototype[ method ];
2754
- }
2755
- }
2756
-
2757
- var measureColumns = proto.measureColumns;
2758
- proto.measureColumns = function() {
2759
- // set items, used if measuring first item
2760
- this.items = this.isotope.filteredItems;
2761
- measureColumns.call( this );
2762
- };
2763
-
2764
- // point to mode options for fitWidth
2765
- var _getOption = proto._getOption;
2766
- proto._getOption = function( option ) {
2767
- if ( option == 'fitWidth' ) {
2768
- return this.options.isFitWidth !== undefined ?
2769
- this.options.isFitWidth : this.options.fitWidth;
2770
  }
2771
- return _getOption.apply( this.isotope, arguments );
2772
- };
2773
 
2774
- return MasonryMode;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2775
 
2776
  }));
2777
 
@@ -2780,67 +2780,67 @@ return Item;
2780
  */
2781
 
2782
  ( function( window, factory ) {
2783
- // universal module definition
2784
- /* jshint strict: false */ /*globals define, module, require */
2785
- if ( typeof define == 'function' && define.amd ) {
2786
- // AMD
2787
- define( 'isotope/js/layout-modes/fit-rows',[
2788
- '../layout-mode'
2789
- ],
2790
- factory );
2791
- } else if ( typeof exports == 'object' ) {
2792
- // CommonJS
2793
- module.exports = factory(
2794
- require('../layout-mode')
2795
- );
2796
- } else {
2797
- // browser global
2798
- factory(
2799
- window.Isotope.LayoutMode
2800
- );
2801
- }
2802
 
2803
  }( window, function factory( LayoutMode ) {
2804
- 'use strict';
2805
 
2806
- var FitRows = LayoutMode.create('fitRows');
2807
 
2808
- var proto = FitRows.prototype;
2809
 
2810
- proto._resetLayout = function() {
2811
- this.x = 0;
2812
- this.y = 0;
2813
- this.maxY = 0;
2814
- this._getMeasurement( 'gutter', 'outerWidth' );
2815
- };
2816
 
2817
- proto._getItemLayoutPosition = function( item ) {
2818
- item.getSize();
2819
 
2820
- var itemWidth = item.size.outerWidth + this.gutter;
2821
- // if this element cannot fit in the current row
2822
- var containerWidth = this.isotope.size.innerWidth + this.gutter;
2823
- if ( this.x !== 0 && itemWidth + this.x > containerWidth ) {
2824
- this.x = 0;
2825
- this.y = this.maxY;
2826
- }
2827
 
2828
- var position = {
2829
- x: this.x,
2830
- y: this.y
2831
- };
2832
 
2833
- this.maxY = Math.max( this.maxY, this.y + item.size.outerHeight );
2834
- this.x += itemWidth;
2835
 
2836
- return position;
2837
- };
2838
 
2839
- proto._getContainerSize = function() {
2840
- return { height: this.maxY };
2841
- };
2842
 
2843
- return FitRows;
2844
 
2845
  }));
2846
 
@@ -2849,53 +2849,53 @@ return FitRows;
2849
  */
2850
 
2851
  ( function( window, factory ) {
2852
- // universal module definition
2853
- /* jshint strict: false */ /*globals define, module, require */
2854
- if ( typeof define == 'function' && define.amd ) {
2855
- // AMD
2856
- define( 'isotope/js/layout-modes/vertical',[
2857
- '../layout-mode'
2858
- ],
2859
- factory );
2860
- } else if ( typeof module == 'object' && module.exports ) {
2861
- // CommonJS
2862
- module.exports = factory(
2863
- require('../layout-mode')
2864
- );
2865
- } else {
2866
- // browser global
2867
- factory(
2868
- window.Isotope.LayoutMode
2869
- );
2870
- }
2871
 
2872
  }( window, function factory( LayoutMode ) {
2873
- 'use strict';
2874
 
2875
- var Vertical = LayoutMode.create( 'vertical', {
2876
- horizontalAlignment: 0
2877
- });
2878
 
2879
- var proto = Vertical.prototype;
2880
 
2881
- proto._resetLayout = function() {
2882
- this.y = 0;
2883
- };
2884
 
2885
- proto._getItemLayoutPosition = function( item ) {
2886
- item.getSize();
2887
- var x = ( this.isotope.size.innerWidth - item.size.outerWidth ) *
2888
- this.options.horizontalAlignment;
2889
- var y = this.y;
2890
- this.y += item.size.outerHeight;
2891
- return { x: x, y: y };
2892
- };
2893
 
2894
- proto._getContainerSize = function() {
2895
- return { height: this.y };
2896
- };
2897
 
2898
- return Vertical;
2899
 
2900
  }));
2901
 
@@ -2910,606 +2910,606 @@ return Vertical;
2910
  */
2911
 
2912
  ( function( window, factory ) {
2913
- // universal module definition
2914
- /* jshint strict: false */ /*globals define, module, require */
2915
- if ( typeof define == 'function' && define.amd ) {
2916
- // AMD
2917
- define( [
2918
- 'outlayer/outlayer',
2919
- 'get-size/get-size',
2920
- 'desandro-matches-selector/matches-selector',
2921
- 'fizzy-ui-utils/utils',
2922
- 'isotope/js/item',
2923
- 'isotope/js/layout-mode',
2924
- // include default layout modes
2925
- 'isotope/js/layout-modes/masonry',
2926
- 'isotope/js/layout-modes/fit-rows',
2927
- 'isotope/js/layout-modes/vertical'
2928
- ],
2929
- function( Outlayer, getSize, matchesSelector, utils, Item, LayoutMode ) {
2930
- return factory( window, Outlayer, getSize, matchesSelector, utils, Item, LayoutMode );
2931
- });
2932
- } else if ( typeof module == 'object' && module.exports ) {
2933
- // CommonJS
2934
- module.exports = factory(
2935
- window,
2936
- require('outlayer'),
2937
- require('get-size'),
2938
- require('desandro-matches-selector'),
2939
- require('fizzy-ui-utils'),
2940
- require('isotope/js/item'),
2941
- require('isotope/js/layout-mode'),
2942
- // include default layout modes
2943
- require('isotope/js/layout-modes/masonry'),
2944
- require('isotope/js/layout-modes/fit-rows'),
2945
- require('isotope/js/layout-modes/vertical')
2946
- );
2947
- } else {
2948
- // browser global
2949
- window.Isotope = factory(
2950
- window,
2951
- window.Outlayer,
2952
- window.getSize,
2953
- window.matchesSelector,
2954
- window.fizzyUIUtils,
2955
- window.Isotope.Item,
2956
- window.Isotope.LayoutMode
2957
- );
2958
- }
2959
 
2960
  }( window, function factory( window, Outlayer, getSize, matchesSelector, utils,
2961
- Item, LayoutMode ) {
2962
 
2963
 
2964
 
2965
  // -------------------------- vars -------------------------- //
2966
 
2967
- var jQuery = window.jQuery;
2968
 
2969
  // -------------------------- helpers -------------------------- //
2970
 
2971
- var trim = String.prototype.trim ?
2972
- function( str ) {
2973
- return str.trim();
2974
- } :
2975
- function( str ) {
2976
- return str.replace( /^\s+|\s+$/g, '' );
2977
- };
2978
 
2979
  // -------------------------- isotopeDefinition -------------------------- //
2980
 
2981
- // create an Outlayer layout class
2982
- var Isotope = Outlayer.create( 'isotope', {
2983
- layoutMode: 'masonry',
2984
- isJQueryFiltering: true,
2985
- sortAscending: true
2986
- });
2987
-
2988
- Isotope.Item = Item;
2989
- Isotope.LayoutMode = LayoutMode;
2990
-
2991
- var proto = Isotope.prototype;
2992
-
2993
- proto._create = function() {
2994
- this.itemGUID = 0;
2995
- // functions that sort items
2996
- this._sorters = {};
2997
- this._getSorters();
2998
- // call super
2999
- Outlayer.prototype._create.call( this );
3000
-
3001
- // create layout modes
3002
- this.modes = {};
3003
- // start filteredItems with all items
3004
- this.filteredItems = this.items;
3005
- // keep of track of sortBys
3006
- this.sortHistory = [ 'original-order' ];
3007
- // create from registered layout modes
3008
- for ( var name in LayoutMode.modes ) {
3009
- this._initLayoutMode( name );
3010
- }
3011
- };
3012
-
3013
- proto.reloadItems = function() {
3014
- // reset item ID counter
3015
- this.itemGUID = 0;
3016
- // call super
3017
- Outlayer.prototype.reloadItems.call( this );
3018
- };
3019
-
3020
- proto._itemize = function() {
3021
- var items = Outlayer.prototype._itemize.apply( this, arguments );
3022
- // assign ID for original-order
3023
- for ( var i=0; i < items.length; i++ ) {
3024
- var item = items[i];
3025
- item.id = this.itemGUID++;
3026
- }
3027
- this._updateItemsSortData( items );
3028
- return items;
3029
- };
3030
-
3031
-
3032
- // -------------------------- layout -------------------------- //
3033
-
3034
- proto._initLayoutMode = function( name ) {
3035
- var Mode = LayoutMode.modes[ name ];
3036
- // set mode options
3037
- // HACK extend initial options, back-fill in default options
3038
- var initialOpts = this.options[ name ] || {};
3039
- this.options[ name ] = Mode.options ?
3040
- utils.extend( Mode.options, initialOpts ) : initialOpts;
3041
- // init layout mode instance
3042
- this.modes[ name ] = new Mode( this );
3043
- };
3044
-
3045
-
3046
- proto.layout = function() {
3047
- // if first time doing layout, do all magic
3048
- if ( !this._isLayoutInited && this._getOption('initLayout') ) {
3049
- this.arrange();
3050
- return;
3051
- }
3052
- this._layout();
3053
- };
3054
-
3055
- // private method to be used in layout() & magic()
3056
- proto._layout = function() {
3057
- // don't animate first layout
3058
- var isInstant = this._getIsInstant();
3059
- // layout flow
3060
- this._resetLayout();
3061
- this._manageStamps();
3062
- this.layoutItems( this.filteredItems, isInstant );
3063
-
3064
- // flag for initalized
3065
- this._isLayoutInited = true;
3066
- };
3067
-
3068
- // filter + sort + layout
3069
- proto.arrange = function( opts ) {
3070
- // set any options pass
3071
- this.option( opts );
3072
- this._getIsInstant();
3073
- // filter, sort, and layout
3074
-
3075
- // filter
3076
- var filtered = this._filter( this.items );
3077
- this.filteredItems = filtered.matches;
3078
-
3079
- this._bindArrangeComplete();
3080
-
3081
- if ( this._isInstant ) {
3082
- this._noTransition( this._hideReveal, [ filtered ] );
3083
- } else {
3084
- this._hideReveal( filtered );
3085
- }
3086
-
3087
- this._sort();
3088
- this._layout();
3089
- };
3090
- // alias to _init for main plugin method
3091
- proto._init = proto.arrange;
3092
-
3093
- proto._hideReveal = function( filtered ) {
3094
- this.reveal( filtered.needReveal );
3095
- this.hide( filtered.needHide );
3096
- };
3097
-
3098
- // HACK
3099
- // Don't animate/transition first layout
3100
- // Or don't animate/transition other layouts
3101
- proto._getIsInstant = function() {
3102
- var isLayoutInstant = this._getOption('layoutInstant');
3103
- var isInstant = isLayoutInstant !== undefined ? isLayoutInstant :
3104
- !this._isLayoutInited;
3105
- this._isInstant = isInstant;
3106
- return isInstant;
3107
- };
3108
-
3109
- // listen for layoutComplete, hideComplete and revealComplete
3110
- // to trigger arrangeComplete
3111
- proto._bindArrangeComplete = function() {
3112
- // listen for 3 events to trigger arrangeComplete
3113
- var isLayoutComplete, isHideComplete, isRevealComplete;
3114
- var _this = this;
3115
- function arrangeParallelCallback() {
3116
- if ( isLayoutComplete && isHideComplete && isRevealComplete ) {
3117
- _this.dispatchEvent( 'arrangeComplete', null, [ _this.filteredItems ] );
3118
- }
3119
- }
3120
- this.once( 'layoutComplete', function() {
3121
- isLayoutComplete = true;
3122
- arrangeParallelCallback();
3123
- });
3124
- this.once( 'hideComplete', function() {
3125
- isHideComplete = true;
3126
- arrangeParallelCallback();
3127
- });
3128
- this.once( 'revealComplete', function() {
3129
- isRevealComplete = true;
3130
- arrangeParallelCallback();
3131
  });
3132
- };
3133
-
3134
- // -------------------------- filter -------------------------- //
3135
-
3136
- proto._filter = function( items ) {
3137
- var filter = this.options.filter;
3138
- filter = filter || '*';
3139
- var matches = [];
3140
- var hiddenMatched = [];
3141
- var visibleUnmatched = [];
3142
-
3143
- var test = this._getFilterTest( filter );
3144
-
3145
- // test each item
3146
- for ( var i=0; i < items.length; i++ ) {
3147
- var item = items[i];
3148
- if ( item.isIgnored ) {
3149
- continue;
3150
- }
3151
- // add item to either matched or unmatched group
3152
- var isMatched = test( item );
3153
- // item.isFilterMatched = isMatched;
3154
- // add to matches if its a match
3155
- if ( isMatched ) {
3156
- matches.push( item );
3157
- }
3158
- // add to additional group if item needs to be hidden or revealed
3159
- if ( isMatched && item.isHidden ) {
3160
- hiddenMatched.push( item );
3161
- } else if ( !isMatched && !item.isHidden ) {
3162
- visibleUnmatched.push( item );
3163
- }
3164
- }
3165
 
3166
- // return collections of items to be manipulated
3167
- return {
3168
- matches: matches,
3169
- needReveal: hiddenMatched,
3170
- needHide: visibleUnmatched
3171
- };
3172
- };
3173
-
3174
- // get a jQuery, function, or a matchesSelector test given the filter
3175
- proto._getFilterTest = function( filter ) {
3176
- if ( jQuery && this.options.isJQueryFiltering ) {
3177
- // use jQuery
3178
- return function( item ) {
3179
- return jQuery( item.element ).is( filter );
3180
- };
3181
- }
3182
- if ( typeof filter == 'function' ) {
3183
- // use filter as function
3184
- return function( item ) {
3185
- return filter( item.element );
3186
- };
3187
- }
3188
- // default, use filter as selector string
3189
- return function( item ) {
3190
- return matchesSelector( item.element, filter );
3191
- };
3192
- };
3193
-
3194
- // -------------------------- sorting -------------------------- //
3195
-
3196
- /**
3197
- * @params {Array} elems
3198
- * @public
3199
- */
3200
- proto.updateSortData = function( elems ) {
3201
- // get items
3202
- var items;
3203
- if ( elems ) {
3204
- elems = utils.makeArray( elems );
3205
- items = this.getItems( elems );
3206
- } else {
3207
- // update all items if no elems provided
3208
- items = this.items;
3209
- }
3210
 
3211
- this._getSorters();
3212
- this._updateItemsSortData( items );
3213
- };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3214
 
3215
- proto._getSorters = function() {
3216
- var getSortData = this.options.getSortData;
3217
- for ( var key in getSortData ) {
3218
- var sorter = getSortData[ key ];
3219
- this._sorters[ key ] = mungeSorter( sorter );
3220
- }
3221
- };
3222
-
3223
- /**
3224
- * @params {Array} items - of Isotope.Items
3225
- * @private
3226
- */
3227
- proto._updateItemsSortData = function( items ) {
3228
- // do not update if no items
3229
- var len = items && items.length;
3230
-
3231
- for ( var i=0; len && i < len; i++ ) {
3232
- var item = items[i];
3233
- item.updateSortData();
3234
- }
3235
- };
3236
-
3237
- // ----- munge sorter ----- //
3238
-
3239
- // encapsulate this, as we just need mungeSorter
3240
- // other functions in here are just for munging
3241
- var mungeSorter = ( function() {
3242
- // add a magic layer to sorters for convienent shorthands
3243
- // `.foo-bar` will use the text of .foo-bar querySelector
3244
- // `[foo-bar]` will use attribute
3245
- // you can also add parser
3246
- // `.foo-bar parseInt` will parse that as a number
3247
- function mungeSorter( sorter ) {
3248
- // if not a string, return function or whatever it is
3249
- if ( typeof sorter != 'string' ) {
3250
- return sorter;
3251
- }
3252
- // parse the sorter string
3253
- var args = trim( sorter ).split(' ');
3254
- var query = args[0];
3255
- // check if query looks like [an-attribute]
3256
- var attrMatch = query.match( /^\[(.+)\]$/ );
3257
- var attr = attrMatch && attrMatch[1];
3258
- var getValue = getValueGetter( attr, query );
3259
- // use second argument as a parser
3260
- var parser = Isotope.sortDataParsers[ args[1] ];
3261
- // parse the value, if there was a parser
3262
- sorter = parser ? function( elem ) {
3263
- return elem && parser( getValue( elem ) );
3264
- } :
3265
- // otherwise just return value
3266
- function( elem ) {
3267
- return elem && getValue( elem );
3268
- };
3269
-
3270
- return sorter;
3271
- }
3272
 
3273
- // get an attribute getter, or get text of the querySelector
3274
- function getValueGetter( attr, query ) {
3275
- // if query looks like [foo-bar], get attribute
3276
- if ( attr ) {
3277
- return function getAttribute( elem ) {
3278
- return elem.getAttribute( attr );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3279
  };
3280
- }
3281
 
3282
- // otherwise, assume its a querySelector, and get its text
3283
- return function getChildText( elem ) {
3284
- var child = elem.querySelector( query );
3285
- return child && child.textContent;
3286
- };
3287
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
3288
 
3289
- return mungeSorter;
3290
- })();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3291
 
3292
- // parsers used in getSortData shortcut strings
3293
- Isotope.sortDataParsers = {
3294
- 'parseInt': function( val ) {
3295
- return parseInt( val, 10 );
3296
- },
3297
- 'parseFloat': function( val ) {
3298
- return parseFloat( val );
3299
- }
3300
- };
3301
 
3302
- // ----- sort method ----- //
 
 
 
 
 
 
3303
 
3304
- // sort filteredItem order
3305
- proto._sort = function() {
3306
- var sortByOpt = this.options.sortBy;
3307
- if ( !sortByOpt ) {
3308
- return;
3309
- }
3310
- // concat all sortBy and sortHistory
3311
- var sortBys = [].concat.apply( sortByOpt, this.sortHistory );
3312
- // sort magic
3313
- var itemSorter = getItemSorter( sortBys, this.options.sortAscending );
3314
- this.filteredItems.sort( itemSorter );
3315
- // keep track of sortBy History
3316
- if ( sortByOpt != this.sortHistory[0] ) {
3317
- // add to front, oldest goes in last
3318
- this.sortHistory.unshift( sortByOpt );
3319
- }
3320
- };
3321
-
3322
- // returns a function used for sorting
3323
- function getItemSorter( sortBys, sortAsc ) {
3324
- return function sorter( itemA, itemB ) {
3325
- // cycle through all sortKeys
3326
- for ( var i = 0; i < sortBys.length; i++ ) {
3327
- var sortBy = sortBys[i];
3328
- var a = itemA.sortData[ sortBy ];
3329
- var b = itemB.sortData[ sortBy ];
3330
- if ( a > b || a < b ) {
3331
- // if sortAsc is an object, use the value given the sortBy key
3332
- var isAscending = sortAsc[ sortBy ] !== undefined ? sortAsc[ sortBy ] : sortAsc;
3333
- var direction = isAscending ? 1 : -1;
3334
- return ( a > b ? 1 : -1 ) * direction;
3335
- }
3336
- }
3337
- return 0;
3338
- };
3339
- }
3340
-
3341
- // -------------------------- methods -------------------------- //
3342
-
3343
- // get layout mode
3344
- proto._mode = function() {
3345
- var layoutMode = this.options.layoutMode;
3346
- var mode = this.modes[ layoutMode ];
3347
- if ( !mode ) {
3348
- // TODO console.error
3349
- throw new Error( 'No layout mode: ' + layoutMode );
3350
- }
3351
- // HACK sync mode's options
3352
- // any options set after init for layout mode need to be synced
3353
- mode.options = this.options[ layoutMode ];
3354
- return mode;
3355
- };
3356
-
3357
- proto._resetLayout = function() {
3358
- // trigger original reset layout
3359
- Outlayer.prototype._resetLayout.call( this );
3360
- this._mode()._resetLayout();
3361
- };
3362
-
3363
- proto._getItemLayoutPosition = function( item ) {
3364
- return this._mode()._getItemLayoutPosition( item );
3365
- };
3366
-
3367
- proto._manageStamp = function( stamp ) {
3368
- this._mode()._manageStamp( stamp );
3369
- };
3370
-
3371
- proto._getContainerSize = function() {
3372
- return this._mode()._getContainerSize();
3373
- };
3374
-
3375
- proto.needsResizeLayout = function() {
3376
- return this._mode().needsResizeLayout();
3377
- };
3378
-
3379
- // -------------------------- adding & removing -------------------------- //
3380
-
3381
- // HEADS UP overwrites default Outlayer appended
3382
- proto.appended = function( elems ) {
3383
- var items = this.addItems( elems );
3384
- if ( !items.length ) {
3385
- return;
3386
- }
3387
- // filter, layout, reveal new items
3388
- var filteredItems = this._filterRevealAdded( items );
3389
- // add to filteredItems
3390
- this.filteredItems = this.filteredItems.concat( filteredItems );
3391
- };
3392
-
3393
- // HEADS UP overwrites default Outlayer prepended
3394
- proto.prepended = function( elems ) {
3395
- var items = this._itemize( elems );
3396
- if ( !items.length ) {
3397
- return;
3398
- }
3399
- // start new layout
3400
- this._resetLayout();
3401
- this._manageStamps();
3402
- // filter, layout, reveal new items
3403
- var filteredItems = this._filterRevealAdded( items );
3404
- // layout previous items
3405
- this.layoutItems( this.filteredItems );
3406
- // add to items and filteredItems
3407
- this.filteredItems = filteredItems.concat( this.filteredItems );
3408
- this.items = items.concat( this.items );
3409
- };
3410
-
3411
- proto._filterRevealAdded = function( items ) {
3412
- var filtered = this._filter( items );
3413
- this.hide( filtered.needHide );
3414
- // reveal all new items
3415
- this.reveal( filtered.matches );
3416
- // layout new items, no transition
3417
- this.layoutItems( filtered.matches, true );
3418
- return filtered.matches;
3419
- };
3420
-
3421
- /**
3422
- * Filter, sort, and layout newly-appended item elements
3423
- * @param {Array or NodeList or Element} elems
3424
- */
3425
- proto.insert = function( elems ) {
3426
- var items = this.addItems( elems );
3427
- if ( !items.length ) {
3428
- return;
3429
- }
3430
- // append item elements
3431
- var i, item;
3432
- var len = items.length;
3433
- for ( i=0; i < len; i++ ) {
3434
- item = items[i];
3435
- this.element.appendChild( item.element );
3436
- }
3437
- // filter new stuff
3438
- var filteredInsertItems = this._filter( items ).matches;
3439
- // set flag
3440
- for ( i=0; i < len; i++ ) {
3441
- items[i].isLayoutInstant = true;
3442
- }
3443
- this.arrange();
3444
- // reset flag
3445
- for ( i=0; i < len; i++ ) {
3446
- delete items[i].isLayoutInstant;
3447
- }
3448
- this.reveal( filteredInsertItems );
3449
- };
3450
-
3451
- var _remove = proto.remove;
3452
- proto.remove = function( elems ) {
3453
- elems = utils.makeArray( elems );
3454
- var removeItems = this.getItems( elems );
3455
- // do regular thing
3456
- _remove.call( this, elems );
3457
- // bail if no items to remove
3458
- var len = removeItems && removeItems.length;
3459
- // remove elems from filteredItems
3460
- for ( var i=0; len && i < len; i++ ) {
3461
- var item = removeItems[i];
3462
- // remove item from collection
3463
- utils.removeFrom( this.filteredItems, item );
3464
- }
3465
- };
3466
 
3467
- proto.shuffle = function() {
3468
- // update random sortData
3469
- for ( var i=0; i < this.items.length; i++ ) {
3470
- var item = this.items[i];
3471
- item.sortData.random = Math.random();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3472
  }
3473
- this.options.sortBy = 'random';
3474
- this._sort();
3475
- this._layout();
3476
- };
3477
-
3478
- /**
3479
- * trigger fn without transition
3480
- * kind of hacky to have this in the first place
3481
- * @param {Function} fn
3482
- * @param {Array} args
3483
- * @returns ret
3484
- * @private
3485
- */
3486
- proto._noTransition = function( fn, args ) {
3487
- // save transitionDuration before disabling
3488
- var transitionDuration = this.options.transitionDuration;
3489
- // disable transition
3490
- this.options.transitionDuration = 0;
3491
- // do it
3492
- var returnValue = fn.apply( this, args );
3493
- // re-enable transition for reveal
3494
- this.options.transitionDuration = transitionDuration;
3495
- return returnValue;
3496
- };
3497
-
3498
- // ----- helper methods ----- //
3499
-
3500
- /**
3501
- * getter method for getting filtered item elements
3502
- * @returns {Array} elems - collection of item elements
3503
- */
3504
- proto.getFilteredItemElements = function() {
3505
- return this.filteredItems.map( function( item ) {
3506
- return item.element;
3507
- });
3508
- };
3509
 
3510
- // ----- ----- //
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3511
 
3512
- return Isotope;
3513
 
3514
  }));
3515
 
17
  /* jshint browser: true, strict: true, undef: true, unused: true */
18
 
19
  ( function( window, factory ) {
20
+ // universal module definition
21
+ /*jshint strict: false */ /* globals define, module, require */
22
+ if ( typeof define == 'function' && define.amd ) {
23
+ // AMD
24
+ define( 'jquery-bridget/jquery-bridget',[ 'jquery' ], function( jQuery ) {
25
+ return factory( window, jQuery );
26
+ });
27
+ } else if ( typeof module == 'object' && module.exports ) {
28
+ // CommonJS
29
+ module.exports = factory(
30
+ window,
31
+ require('jquery')
32
+ );
33
+ } else {
34
+ // browser global
35
+ window.jQueryBridget = factory(
36
+ window,
37
+ window.jQuery
38
+ );
39
+ }
40
 
41
  }( window, function factory( window, jQuery ) {
42
+ 'use strict';
43
 
44
  // ----- utils ----- //
45
 
46
+ var arraySlice = Array.prototype.slice;
47
 
48
  // helper function for logging errors
49
  // $.error breaks jQuery chaining
50
+ var console = window.console;
51
+ var logError = typeof console == 'undefined' ? function() {} :
52
+ function( message ) {
53
+ console.error( message );
54
+ };
55
 
56
  // ----- jQueryBridget ----- //
57
 
58
+ function jQueryBridget( namespace, PluginClass, $ ) {
59
+ $ = $ || jQuery || window.jQuery;
60
+ if ( !$ ) {
61
+ return;
62
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
63
 
64
+ // add option method -> $().plugin('option', {...})
65
+ if ( !PluginClass.prototype.option ) {
66
+ // option setter
67
+ PluginClass.prototype.option = function( opts ) {
68
+ // bail out if not an object
69
+ if ( !$.isPlainObject( opts ) ){
70
+ return;
71
+ }
72
+ this.options = $.extend( true, this.options, opts );
73
+ };
74
+ }
75
+
76
+ // make jQuery plugin
77
+ $.fn[ namespace ] = function( arg0 /*, arg1 */ ) {
78
+ if ( typeof arg0 == 'string' ) {
79
+ // method call $().plugin( 'methodName', { options } )
80
+ // shift arguments by 1
81
+ var args = arraySlice.call( arguments, 1 );
82
+ return methodCall( this, arg0, args );
83
+ }
84
+ // just $().plugin({ options })
85
+ plainCall( this, arg0 );
86
+ return this;
87
+ };
88
+
89
+ // $().plugin('methodName')
90
+ function methodCall( $elems, methodName, args ) {
91
+ var returnValue;
92
+ var pluginMethodStr = '$().' + namespace + '("' + methodName + '")';
93
+
94
+ $elems.each( function( i, elem ) {
95
+ // get instance
96
+ var instance = $.data( elem, namespace );
97
+ if ( !instance ) {
98
+ logError( namespace + ' not initialized. Cannot call methods, i.e. ' +
99
+ pluginMethodStr );
100
+ return;
101
+ }
102
+
103
+ var method = instance[ methodName ];
104
+ if ( !method || methodName.charAt(0) == '_' ) {
105
+ logError( pluginMethodStr + ' is not a valid method' );
106
+ return;
107
+ }
108
+
109
+ // apply method, get return value
110
+ var value = method.apply( instance, args );
111
+ // set return value if value is returned, use only first value
112
+ returnValue = returnValue === undefined ? value : returnValue;
113
+ });
114
+
115
+ return returnValue !== undefined ? returnValue : $elems;
116
+ }
117
+
118
+ function plainCall( $elems, options ) {
119
+ $elems.each( function( i, elem ) {
120
+ var instance = $.data( elem, namespace );
121
+ if ( instance ) {
122
+ // set options & init
123
+ instance.option( options );
124
+ instance._init();
125
+ } else {
126
+ // initialize new instance
127
+ instance = new PluginClass( elem, options );
128
+ $.data( elem, namespace, instance );
129
+ }
130
+ });
131
+ }
132
 
133
+ updateJQuery( $ );
134
 
135
+ }
136
 
137
  // ----- updateJQuery ----- //
138
 
139
  // set $.bridget for v1 backwards compatibility
140
+ function updateJQuery( $ ) {
141
+ if ( !$ || ( $ && $.bridget ) ) {
142
+ return;
143
+ }
144
+ $.bridget = jQueryBridget;
145
+ }
146
 
147
+ updateJQuery( jQuery || window.jQuery );
148
 
149
  // ----- ----- //
150
 
151
+ return jQueryBridget;
152
 
153
  }));
154
 
161
  /* jshint unused: true, undef: true, strict: true */
162
 
163
  ( function( global, factory ) {
164
+ // universal module definition
165
+ /* jshint strict: false */ /* globals define, module, window */
166
+ if ( typeof define == 'function' && define.amd ) {
167
+ // AMD - RequireJS
168
+ define( 'ev-emitter/ev-emitter',factory );
169
+ } else if ( typeof module == 'object' && module.exports ) {
170
+ // CommonJS - Browserify, Webpack
171
+ module.exports = factory();
172
+ } else {
173
+ // Browser globals
174
+ global.EvEmitter = factory();
175
+ }
176
 
177
  }( typeof window != 'undefined' ? window : this, function() {
178
 
179
 
180
 
181
+ function EvEmitter() {}
182
+
183
+ var proto = EvEmitter.prototype;
184
+
185
+ proto.on = function( eventName, listener ) {
186
+ if ( !eventName || !listener ) {
187
+ return;
188
+ }
189
+ // set events hash
190
+ var events = this._events = this._events || {};
191
+ // set listeners array
192
+ var listeners = events[ eventName ] = events[ eventName ] || [];
193
+ // only add once
194
+ if ( listeners.indexOf( listener ) == -1 ) {
195
+ listeners.push( listener );
196
+ }
197
+
198
+ return this;
199
+ };
200
+
201
+ proto.once = function( eventName, listener ) {
202
+ if ( !eventName || !listener ) {
203
+ return;
204
+ }
205
+ // add event
206
+ this.on( eventName, listener );
207
+ // set once flag
208
+ // set onceEvents hash
209
+ var onceEvents = this._onceEvents = this._onceEvents || {};
210
+ // set onceListeners object
211
+ var onceListeners = onceEvents[ eventName ] = onceEvents[ eventName ] || {};
212
+ // set flag
213
+ onceListeners[ listener ] = true;
214
+
215
+ return this;
216
+ };
217
+
218
+ proto.off = function( eventName, listener ) {
219
+ var listeners = this._events && this._events[ eventName ];
220
+ if ( !listeners || !listeners.length ) {
221
+ return;
222
+ }
223
+ var index = listeners.indexOf( listener );
224
+ if ( index != -1 ) {
225
+ listeners.splice( index, 1 );
226
+ }
227
+
228
+ return this;
229
+ };
230
+
231
+ proto.emitEvent = function( eventName, args ) {
232
+ var listeners = this._events && this._events[ eventName ];
233
+ if ( !listeners || !listeners.length ) {
234
+ return;
235
+ }
236
+ var i = 0;
237
+ var listener = listeners[i];
238
+ args = args || [];
239
+ // once stuff
240
+ var onceListeners = this._onceEvents && this._onceEvents[ eventName ];
241
+
242
+ while ( listener ) {
243
+ var isOnce = onceListeners && onceListeners[ listener ];
244
+ if ( isOnce ) {
245
+ // remove listener
246
+ // remove before trigger to prevent recursion
247
+ this.off( eventName, listener );
248
+ // unset once flag
249
+ delete onceListeners[ listener ];
250
+ }
251
+ // trigger listener
252
+ listener.apply( this, args );
253
+ // get next listener
254
+ i += isOnce ? 0 : 1;
255
+ listener = listeners[i];
256
+ }
257
 
258
+ return this;
259
+ };
260
 
261
+ return EvEmitter;
262
 
263
  }));
264
 
272
  /*global define: false, module: false, console: false */
273
 
274
  ( function( window, factory ) {
275
+ 'use strict';
276
+
277
+ if ( typeof define == 'function' && define.amd ) {
278
+ // AMD
279
+ define( 'get-size/get-size',[],function() {
280
+ return factory();
281
+ });
282
+ } else if ( typeof module == 'object' && module.exports ) {
283
+ // CommonJS
284
+ module.exports = factory();
285
+ } else {
286
+ // browser global
287
+ window.getSize = factory();
288
+ }
289
 
290
  })( window, function factory() {
291
+ 'use strict';
292
 
293
  // -------------------------- helpers -------------------------- //
294
 
295
  // get a number from a string, not a percentage
296
+ function getStyleSize( value ) {
297
+ var num = parseFloat( value );
298
+ // not a percent like '100%', and a number
299
+ var isValid = value.indexOf('%') == -1 && !isNaN( num );
300
+ return isValid && num;
301
+ }
302
 
303
+ function noop() {}
304
 
305
+ var logError = typeof console == 'undefined' ? noop :
306
+ function( message ) {
307
+ console.error( message );
308
+ };
309
 
310
  // -------------------------- measurements -------------------------- //
311
 
312
+ var measurements = [
313
+ 'paddingLeft',
314
+ 'paddingRight',
315
+ 'paddingTop',
316
+ 'paddingBottom',
317
+ 'marginLeft',
318
+ 'marginRight',
319
+ 'marginTop',
320
+ 'marginBottom',
321
+ 'borderLeftWidth',
322
+ 'borderRightWidth',
323
+ 'borderTopWidth',
324
+ 'borderBottomWidth'
325
+ ];
326
+
327
+ var measurementsLength = measurements.length;
328
+
329
+ function getZeroSize() {
330
+ var size = {
331
+ width: 0,
332
+ height: 0,
333
+ innerWidth: 0,
334
+ innerHeight: 0,
335
+ outerWidth: 0,
336
+ outerHeight: 0
337
+ };
338
+ for ( var i=0; i < measurementsLength; i++ ) {
339
+ var measurement = measurements[i];
340
+ size[ measurement ] = 0;
341
+ }
342
+ return size;
343
+ }
344
 
345
  // -------------------------- getStyle -------------------------- //
346
 
347
+ /**
348
+ * getStyle, get style of element, check for Firefox bug
349
+ * https://bugzilla.mozilla.org/show_bug.cgi?id=548397
350
+ */
351
+ function getStyle( elem ) {
352
+ var style = getComputedStyle( elem );
353
+ if ( !style ) {
354
+ logError( 'Style returned ' + style +
355
+ '. Are you running this code in a hidden iframe on Firefox? ' +
356
+ 'See http://bit.ly/getsizebug1' );
357
+ }
358
+ return style;
359
+ }
360
 
361
  // -------------------------- setup -------------------------- //
362
 
363
+ var isSetup = false;
364
 
365
+ var isBoxSizeOuter;
366
 
367
+ /**
368
+ * setup
369
+ * check isBoxSizerOuter
370
+ * do on first getSize() rather than on page load for Firefox bug
371
+ */
372
+ function setup() {
373
+ // setup once
374
+ if ( isSetup ) {
375
+ return;
376
+ }
377
+ isSetup = true;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
378
 
379
+ // -------------------------- box sizing -------------------------- //
380
 
381
+ /**
382
+ * WebKit measures the outer-width on style.width on border-box elems
383
+ * IE & Firefox<29 measures the inner-width
384
+ */
385
+ var div = document.createElement('div');
386
+ div.style.width = '200px';
387
+ div.style.padding = '1px 2px 3px 4px';
388
+ div.style.borderStyle = 'solid';
389
+ div.style.borderWidth = '1px 2px 3px 4px';
390
+ div.style.boxSizing = 'border-box';
391
 
392
+ var body = document.body || document.documentElement;
393
+ body.appendChild( div );
394
+ var style = getStyle( div );
 
395
 
396
+ getSize.isBoxSizeOuter = isBoxSizeOuter = getStyleSize( style.width ) == 200;
397
+ body.removeChild( div );
 
 
398
 
399
+ }
400
+
401
+ // -------------------------- getSize -------------------------- //
402
+
403
+ function getSize( elem ) {
404
+ setup();
405
 
406
+ // use querySeletor if elem is string
407
+ if ( typeof elem == 'string' ) {
408
+ elem = document.querySelector( elem );
409
+ }
410
+
411
+ // do not proceed on non-objects
412
+ if ( !elem || typeof elem != 'object' || !elem.nodeType ) {
413
+ return;
414
+ }
415
 
416
+ var style = getStyle( elem );
 
 
417
 
418
+ // if hidden, everything is 0
419
+ if ( style.display == 'none' ) {
420
+ return getZeroSize();
421
+ }
422
 
423
+ var size = {};
424
+ size.width = elem.offsetWidth;
425
+ size.height = elem.offsetHeight;
 
 
 
 
 
426
 
427
+ var isBorderBox = size.isBorderBox = style.boxSizing == 'border-box';
 
 
 
 
 
428
 
429
+ // get all measurements
430
+ for ( var i=0; i < measurementsLength; i++ ) {
431
+ var measurement = measurements[i];
432
+ var value = style[ measurement ];
433
+ var num = parseFloat( value );
434
+ // any 'auto', 'medium' value will be 0
435
+ size[ measurement ] = !isNaN( num ) ? num : 0;
436
+ }
437
 
438
+ var paddingWidth = size.paddingLeft + size.paddingRight;
439
+ var paddingHeight = size.paddingTop + size.paddingBottom;
440
+ var marginWidth = size.marginLeft + size.marginRight;
441
+ var marginHeight = size.marginTop + size.marginBottom;
442
+ var borderWidth = size.borderLeftWidth + size.borderRightWidth;
443
+ var borderHeight = size.borderTopWidth + size.borderBottomWidth;
444
+
445
+ var isBorderBoxSizeOuter = isBorderBox && isBoxSizeOuter;
446
+
447
+ // overwrite width and height if we can get it from style
448
+ var styleWidth = getStyleSize( style.width );
449
+ if ( styleWidth !== false ) {
450
+ size.width = styleWidth +
451
+ // add padding and border unless it's already including it
452
+ ( isBorderBoxSizeOuter ? 0 : paddingWidth + borderWidth );
453
+ }
454
 
455
+ var styleHeight = getStyleSize( style.height );
456
+ if ( styleHeight !== false ) {
457
+ size.height = styleHeight +
458
+ // add padding and border unless it's already including it
459
+ ( isBorderBoxSizeOuter ? 0 : paddingHeight + borderHeight );
460
+ }
461
 
462
+ size.innerWidth = size.width - ( paddingWidth + borderWidth );
463
+ size.innerHeight = size.height - ( paddingHeight + borderHeight );
464
 
465
+ size.outerWidth = size.width + marginWidth;
466
+ size.outerHeight = size.height + marginHeight;
467
 
468
+ return size;
469
+ }
470
 
471
+ return getSize;
472
 
473
  });
474
 
481
  /*jshint browser: true, strict: true, undef: true, unused: true */
482
 
483
  ( function( window, factory ) {
484
+ /*global define: false, module: false */
485
+ 'use strict';
486
+ // universal module definition
487
+ if ( typeof define == 'function' && define.amd ) {
488
+ // AMD
489
+ define( 'desandro-matches-selector/matches-selector',factory );
490
+ } else if ( typeof module == 'object' && module.exports ) {
491
+ // CommonJS
492
+ module.exports = factory();
493
+ } else {
494
+ // browser global
495
+ window.matchesSelector = factory();
496
+ }
497
 
498
  }( window, function factory() {
499
+ 'use strict';
500
 
501
+ var matchesMethod = ( function() {
502
+ var ElemProto = Element.prototype;
503
+ // check for the standard method name first
504
+ if ( ElemProto.matches ) {
505
+ return 'matches';
506
+ }
507
+ // check un-prefixed
508
+ if ( ElemProto.matchesSelector ) {
509
+ return 'matchesSelector';
510
+ }
511
+ // check vendor prefixes
512
+ var prefixes = [ 'webkit', 'moz', 'ms', 'o' ];
513
+
514
+ for ( var i=0; i < prefixes.length; i++ ) {
515
+ var prefix = prefixes[i];
516
+ var method = prefix + 'MatchesSelector';
517
+ if ( ElemProto[ method ] ) {
518
+ return method;
519
+ }
520
+ }
521
+ })();
522
 
523
+ return function matchesSelector( elem, selector ) {
524
+ return elem[ matchesMethod ]( selector );
525
+ };
526
 
527
  }));
528
 
534
  /*jshint browser: true, undef: true, unused: true, strict: true */
535
 
536
  ( function( window, factory ) {
537
+ // universal module definition
538
+ /*jshint strict: false */ /*globals define, module, require */
539
+
540
+ if ( typeof define == 'function' && define.amd ) {
541
+ // AMD
542
+ define( 'fizzy-ui-utils/utils',[
543
+ 'desandro-matches-selector/matches-selector'
544
+ ], function( matchesSelector ) {
545
+ return factory( window, matchesSelector );
546
+ });
547
+ } else if ( typeof module == 'object' && module.exports ) {
548
+ // CommonJS
549
+ module.exports = factory(
550
+ window,
551
+ require('desandro-matches-selector')
552
+ );
553
+ } else {
554
+ // browser global
555
+ window.fizzyUIUtils = factory(
556
+ window,
557
+ window.matchesSelector
558
+ );
559
+ }
560
 
561
  }( window, function factory( window, matchesSelector ) {
562
 
563
 
564
 
565
+ var utils = {};
566
 
567
  // ----- extend ----- //
568
 
569
  // extends objects
570
+ utils.extend = function( a, b ) {
571
+ for ( var prop in b ) {
572
+ a[ prop ] = b[ prop ];
573
+ }
574
+ return a;
575
+ };
576
 
577
  // ----- modulo ----- //
578
 
579
+ utils.modulo = function( num, div ) {
580
+ return ( ( num % div ) + div ) % div;
581
+ };
582
 
583
  // ----- makeArray ----- //
584
 
585
  // turn element or nodeList into an array
586
+ utils.makeArray = function( obj ) {
587
+ var ary = [];
588
+ if ( Array.isArray( obj ) ) {
589
+ // use object if already an array
590
+ ary = obj;
591
+ } else if ( obj && typeof obj.length == 'number' ) {
592
+ // convert nodeList to array
593
+ for ( var i=0; i < obj.length; i++ ) {
594
+ ary.push( obj[i] );
595
+ }
596
+ } else {
597
+ // array of single index
598
+ ary.push( obj );
599
+ }
600
+ return ary;
601
+ };
602
 
603
  // ----- removeFrom ----- //
604
 
605
+ utils.removeFrom = function( ary, obj ) {
606
+ var index = ary.indexOf( obj );
607
+ if ( index != -1 ) {
608
+ ary.splice( index, 1 );
609
+ }
610
+ };
611
 
612
  // ----- getParent ----- //
613
 
614
+ utils.getParent = function( elem, selector ) {
615
+ while ( elem != document.body ) {
616
+ elem = elem.parentNode;
617
+ if ( matchesSelector( elem, selector ) ) {
618
+ return elem;
619
+ }
620
+ }
621
+ };
622
 
623
  // ----- getQueryElement ----- //
624
 
625
  // use element as selector string
626
+ utils.getQueryElement = function( elem ) {
627
+ if ( typeof elem == 'string' ) {
628
+ return document.querySelector( elem );
629
+ }
630
+ return elem;
631
+ };
632
 
633
  // ----- handleEvent ----- //
634
 
635
  // enable .ontype to trigger from .addEventListener( elem, 'type' )
636
+ utils.handleEvent = function( event ) {
637
+ var method = 'on' + event.type;
638
+ if ( this[ method ] ) {
639
+ this[ method ]( event );
640
+ }
641
+ };
642
 
643
  // ----- filterFindElements ----- //
644
 
645
+ utils.filterFindElements = function( elems, selector ) {
646
+ // make array of elems
647
+ elems = utils.makeArray( elems );
648
+ var ffElems = [];
649
+
650
+ elems.forEach( function( elem ) {
651
+ // check that elem is an actual element
652
+ if ( !( elem instanceof HTMLElement ) ) {
653
+ return;
654
+ }
655
+ // add elem if no selector
656
+ if ( !selector ) {
657
+ ffElems.push( elem );
658
+ return;
659
+ }
660
+ // filter & find items if we have a selector
661
+ // filter
662
+ if ( matchesSelector( elem, selector ) ) {
663
+ ffElems.push( elem );
664
+ }
665
+ // find children
666
+ var childElems = elem.querySelectorAll( selector );
667
+ // concat childElems to filterFound array
668
+ for ( var i=0; i < childElems.length; i++ ) {
669
+ ffElems.push( childElems[i] );
670
+ }
671
+ });
672
+
673
+ return ffElems;
674
+ };
675
 
676
  // ----- debounceMethod ----- //
677
 
678
+ utils.debounceMethod = function( _class, methodName, threshold ) {
679
+ // original method
680
+ var method = _class.prototype[ methodName ];
681
+ var timeoutName = methodName + 'Timeout';
682
+
683
+ _class.prototype[ methodName ] = function() {
684
+ var timeout = this[ timeoutName ];
685
+ if ( timeout ) {
686
+ clearTimeout( timeout );
687
+ }
688
+ var args = arguments;
689
+
690
+ var _this = this;
691
+ this[ timeoutName ] = setTimeout( function() {
692
+ method.apply( _this, args );
693
+ delete _this[ timeoutName ];
694
+ }, threshold || 100 );
695
+ };
696
+ };
697
 
698
  // ----- docReady ----- //
699
 
700
+ utils.docReady = function( callback ) {
701
+ var readyState = document.readyState;
702
+ if ( readyState == 'complete' || readyState == 'interactive' ) {
703
+ // do async to allow for other scripts to run. metafizzy/flickity#441
704
+ setTimeout( callback );
705
+ } else {
706
+ document.addEventListener( 'DOMContentLoaded', callback );
707
+ }
708
+ };
709
 
710
  // ----- htmlInit ----- //
711
 
712
  // http://jamesroberts.name/blog/2010/02/22/string-functions-for-javascript-trim-to-camel-case-to-dashed-and-to-underscore/
713
+ utils.toDashed = function( str ) {
714
+ return str.replace( /(.)([A-Z])/g, function( match, $1, $2 ) {
715
+ return $1 + '-' + $2;
716
+ }).toLowerCase();
717
+ };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
718
 
719
+ var console = window.console;
720
+ /**
721
+ * allow user to initialize classes via [data-namespace] or .js-namespace class
722
+ * htmlInit( Widget, 'widgetName' )
723
+ * options are parsed from data-namespace-options
724
+ */
725
+ utils.htmlInit = function( WidgetClass, namespace ) {
726
+ utils.docReady( function() {
727
+ var dashedNamespace = utils.toDashed( namespace );
728
+ var dataAttr = 'data-' + dashedNamespace;
729
+ var dataAttrElems = document.querySelectorAll( '[' + dataAttr + ']' );
730
+ var jsDashElems = document.querySelectorAll( '.js-' + dashedNamespace );
731
+ var elems = utils.makeArray( dataAttrElems )
732
+ .concat( utils.makeArray( jsDashElems ) );
733
+ var dataOptionsAttr = dataAttr + '-options';
734
+ var jQuery = window.jQuery;
735
+
736
+ elems.forEach( function( elem ) {
737
+ var attr = elem.getAttribute( dataAttr ) ||
738
+ elem.getAttribute( dataOptionsAttr );
739
+ var options;
740
+ try {
741
+ options = attr && JSON.parse( attr );
742
+ } catch ( error ) {
743
+ // log error, do not initialize
744
+ if ( console ) {
745
+ console.error( 'Error parsing ' + dataAttr + ' on ' + elem.className +
746
+ ': ' + error );
747
+ }
748
+ return;
749
+ }
750
+ // initialize
751
+ var instance = new WidgetClass( elem, options );
752
+ // make available via $().data('namespace')
753
+ if ( jQuery ) {
754
+ jQuery.data( elem, namespace, instance );
755
+ }
756
+ });
757
+
758
+ });
759
+ };
760
 
761
  // ----- ----- //
762
 
763
+ return utils;
764
 
765
  }));
766
 
769
  */
770
 
771
  ( function( window, factory ) {
772
+ // universal module definition
773
+ /* jshint strict: false */ /* globals define, module, require */
774
+ if ( typeof define == 'function' && define.amd ) {
775
+ // AMD - RequireJS
776
+ define( 'outlayer/item',[
777
+ 'ev-emitter/ev-emitter',
778
+ 'get-size/get-size'
779
+ ],
780
+ factory
781
+ );
782
+ } else if ( typeof module == 'object' && module.exports ) {
783
+ // CommonJS - Browserify, Webpack
784
+ module.exports = factory(
785
+ require('ev-emitter'),
786
+ require('get-size')
787
+ );
788
+ } else {
789
+ // browser global
790
+ window.Outlayer = {};
791
+ window.Outlayer.Item = factory(
792
+ window.EvEmitter,
793
+ window.getSize
794
+ );
795
+ }
796
 
797
  }( window, function factory( EvEmitter, getSize ) {
798
+ 'use strict';
799
 
800
  // ----- helpers ----- //
801
 
802
+ function isEmptyObj( obj ) {
803
+ for ( var prop in obj ) {
804
+ return false;
805
+ }
806
+ prop = null;
807
+ return true;
808
+ }
809
 
810
  // -------------------------- CSS3 support -------------------------- //
811
 
812
 
813
+ var docElemStyle = document.documentElement.style;
814
 
815
+ var transitionProperty = typeof docElemStyle.transition == 'string' ?
816
+ 'transition' : 'WebkitTransition';
817
+ var transformProperty = typeof docElemStyle.transform == 'string' ?
818
+ 'transform' : 'WebkitTransform';
819
 
820
+ var transitionEndEvent = {
821
+ WebkitTransition: 'webkitTransitionEnd',
822
+ transition: 'transitionend'
823
+ }[ transitionProperty ];
824
 
825
  // cache all vendor properties that could have vendor prefix
826
+ var vendorProperties = {
827
+ transform: transformProperty,
828
+ transition: transitionProperty,
829
+ transitionDuration: transitionProperty + 'Duration',
830
+ transitionProperty: transitionProperty + 'Property',
831
+ transitionDelay: transitionProperty + 'Delay'
832
+ };
833
 
834
  // -------------------------- Item -------------------------- //
835
 
836
+ function Item( element, layout ) {
837
+ if ( !element ) {
838
+ return;
839
+ }
840
 
841
+ this.element = element;
842
+ // parent layout class, i.e. Masonry, Isotope, or Packery
843
+ this.layout = layout;
844
+ this.position = {
845
+ x: 0,
846
+ y: 0
847
+ };
848
 
849
+ this._create();
850
+ }
851
 
852
  // inherit EvEmitter
853
+ var proto = Item.prototype = Object.create( EvEmitter.prototype );
854
+ proto.constructor = Item;
855
+
856
+ proto._create = function() {
857
+ // transition objects
858
+ this._transn = {
859
+ ingProperties: {},
860
+ clean: {},
861
+ onEnd: {}
862
+ };
863
+
864
+ this.css({
865
+ position: 'absolute'
866
+ });
867
+ };
868
 
869
  // trigger specified handler for event type
870
+ proto.handleEvent = function( event ) {
871
+ var method = 'on' + event.type;
872
+ if ( this[ method ] ) {
873
+ this[ method ]( event );
874
+ }
875
+ };
876
 
877
+ proto.getSize = function() {
878
+ this.size = getSize( this.element );
879
+ };
880
 
881
+ /**
882
+ * apply CSS styles to element
883
+ * @param {Object} style
884
+ */
885
+ proto.css = function( style ) {
886
+ var elemStyle = this.element.style;
887
+
888
+ for ( var prop in style ) {
889
+ // use vendor property if available
890
+ var supportedProp = vendorProperties[ prop ] || prop;
891
+ elemStyle[ supportedProp ] = style[ prop ];
892
+ }
893
+ };
894
+
895
+ // measure position, and sets it
896
+ proto.getPosition = function() {
897
+ var style = getComputedStyle( this.element );
898
+ var isOriginLeft = this.layout._getOption('originLeft');
899
+ var isOriginTop = this.layout._getOption('originTop');
900
+ var xValue = style[ isOriginLeft ? 'left' : 'right' ];
901
+ var yValue = style[ isOriginTop ? 'top' : 'bottom' ];
902
+ // convert percent to pixels
903
+ var layoutSize = this.layout.size;
904
+ var x = xValue.indexOf('%') != -1 ?
905
+ ( parseFloat( xValue ) / 100 ) * layoutSize.width : parseInt( xValue, 10 );
906
+ var y = yValue.indexOf('%') != -1 ?
907
+ ( parseFloat( yValue ) / 100 ) * layoutSize.height : parseInt( yValue, 10 );
908
+
909
+ // clean up 'auto' or other non-integer values
910
+ x = isNaN( x ) ? 0 : x;
911
+ y = isNaN( y ) ? 0 : y;
912
+ // remove padding from measurement
913
+ x -= isOriginLeft ? layoutSize.paddingLeft : layoutSize.paddingRight;
914
+ y -= isOriginTop ? layoutSize.paddingTop : layoutSize.paddingBottom;
915
+
916
+ this.position.x = x;
917
+ this.position.y = y;
918
+ };
919
 
920
  // set settled position, apply padding
921
+ proto.layoutPosition = function() {
922
+ var layoutSize = this.layout.size;
923
+ var style = {};
924
+ var isOriginLeft = this.layout._getOption('originLeft');
925
+ var isOriginTop = this.layout._getOption('originTop');
926
+
927
+ // x
928
+ var xPadding = isOriginLeft ? 'paddingLeft' : 'paddingRight';
929
+ var xProperty = isOriginLeft ? 'left' : 'right';
930
+ var xResetProperty = isOriginLeft ? 'right' : 'left';
931
+
932
+ var x = this.position.x + layoutSize[ xPadding ];
933
+ // set in percentage or pixels
934
+ style[ xProperty ] = this.getXValue( x );
935
+ // reset other property
936
+ style[ xResetProperty ] = '';
937
+
938
+ // y
939
+ var yPadding = isOriginTop ? 'paddingTop' : 'paddingBottom';
940
+ var yProperty = isOriginTop ? 'top' : 'bottom';
941
+ var yResetProperty = isOriginTop ? 'bottom' : 'top';
942
+
943
+ var y = this.position.y + layoutSize[ yPadding ];
944
+ // set in percentage or pixels
945
+ style[ yProperty ] = this.getYValue( y );
946
+ // reset other property
947
+ style[ yResetProperty ] = '';
948
+
949
+ this.css( style );
950
+ this.emitEvent( 'layout', [ this ] );
951
+ };
952
+
953
+ proto.getXValue = function( x ) {
954
+ var isHorizontal = this.layout._getOption('horizontal');
955
+ return this.layout.options.percentPosition && !isHorizontal ?
956
+ ( ( x / this.layout.size.width ) * 100 ) + '%' : x + 'px';
957
+ };
958
+
959
+ proto.getYValue = function( y ) {
960
+ var isHorizontal = this.layout._getOption('horizontal');
961
+ return this.layout.options.percentPosition && isHorizontal ?
962
+ ( ( y / this.layout.size.height ) * 100 ) + '%' : y + 'px';
963
+ };
964
+
965
+ proto._transitionTo = function( x, y ) {
966
+ this.getPosition();
967
+ // get current x & y from top/left
968
+ var curX = this.position.x;
969
+ var curY = this.position.y;
970
+
971
+ var compareX = parseInt( x, 10 );
972
+ var compareY = parseInt( y, 10 );
973
+ var didNotMove = compareX === this.position.x && compareY === this.position.y;
974
+
975
+ // save end position
976
+ this.setPosition( x, y );
977
+
978
+ // if did not move and not transitioning, just go to layout
979
+ if ( didNotMove && !this.isTransitioning ) {
980
+ this.layoutPosition();
981
+ return;
982
+ }
983
+
984
+ var transX = x - curX;
985
+ var transY = y - curY;
986
+ var transitionStyle = {};
987
+ transitionStyle.transform = this.getTranslate( transX, transY );
988
+
989
+ this.transition({
990
+ to: transitionStyle,
991
+ onTransitionEnd: {
992
+ transform: this.layoutPosition
993
+ },
994
+ isCleaning: true
995
+ });
996
+ };
997
+
998
+ proto.getTranslate = function( x, y ) {
999
+ // flip cooridinates if origin on right or bottom
1000
+ var isOriginLeft = this.layout._getOption('originLeft');
1001
+ var isOriginTop = this.layout._getOption('originTop');
1002
+ x = isOriginLeft ? x : -x;
1003
+ y = isOriginTop ? y : -y;
1004
+ return 'translate3d(' + x + 'px, ' + y + 'px, 0)';
1005
+ };
1006
 
1007
  // non transition + transform support
1008
+ proto.goTo = function( x, y ) {
1009
+ this.setPosition( x, y );
1010
+ this.layoutPosition();
1011
+ };
1012
 
1013
+ proto.moveTo = proto._transitionTo;
1014
 
1015
+ proto.setPosition = function( x, y ) {
1016
+ this.position.x = parseInt( x, 10 );
1017
+ this.position.y = parseInt( y, 10 );
1018
+ };
1019
 
1020
  // ----- transition ----- //
1021
 
1022
+ /**
1023
+ * @param {Object} style - CSS
1024
+ * @param {Function} onTransitionEnd
1025
+ */
1026
 
1027
  // non transition, just trigger callback
1028
+ proto._nonTransition = function( args ) {
1029
+ this.css( args.to );
1030
+ if ( args.isCleaning ) {
1031
+ this._removeStyles( args.to );
1032
+ }
1033
+ for ( var prop in args.onTransitionEnd ) {
1034
+ args.onTransitionEnd[ prop ].call( this );
1035
+ }
1036
+ };
1037
 
1038
+ /**
1039
+ * proper transition
1040
+ * @param {Object} args - arguments
1041
+ * @param {Object} to - style to transition to
1042
+ * @param {Object} from - style to start transition from
1043
+ * @param {Boolean} isCleaning - removes transition styles after transition
1044
+ * @param {Function} onTransitionEnd - callback
1045
+ */
1046
+ proto.transition = function( args ) {
1047
+ // redirect to nonTransition if no transition duration
1048
+ if ( !parseFloat( this.layout.options.transitionDuration ) ) {
1049
+ this._nonTransition( args );
1050
+ return;
1051
+ }
1052
+
1053
+ var _transition = this._transn;
1054
+ // keep track of onTransitionEnd callback by css property
1055
+ for ( var prop in args.onTransitionEnd ) {
1056
+ _transition.onEnd[ prop ] = args.onTransitionEnd[ prop ];
1057
+ }
1058
+ // keep track of properties that are transitioning
1059
+ for ( prop in args.to ) {
1060
+ _transition.ingProperties[ prop ] = true;
1061
+ // keep track of properties to clean up when transition is done
1062
+ if ( args.isCleaning ) {
1063
+ _transition.clean[ prop ] = true;
1064
+ }
1065
+ }
1066
 
1067
+ // set from styles
1068
+ if ( args.from ) {
1069
+ this.css( args.from );
1070
+ // force redraw. http://blog.alexmaccaw.com/css-transitions
1071
+ var h = this.element.offsetHeight;
1072
+ // hack for JSHint to hush about unused var
1073
+ h = null;
1074
+ }
1075
+ // enable transition
1076
+ this.enableTransition( args.to );
1077
+ // set styles that are transitioning
1078
+ this.css( args.to );
1079
 
1080
+ this.isTransitioning = true;
1081
 
1082
+ };
1083
 
1084
  // dash before all cap letters, including first for
1085
  // WebkitTransform => -webkit-transform
1086
+ function toDashedAll( str ) {
1087
+ return str.replace( /([A-Z])/g, function( $1 ) {
1088
+ return '-' + $1.toLowerCase();
1089
+ });
1090
+ }
1091
+
1092
+ var transitionProps = 'opacity,' + toDashedAll( transformProperty );
1093
+
1094
+ proto.enableTransition = function(/* style */) {
1095
+ // HACK changing transitionProperty during a transition
1096
+ // will cause transition to jump
1097
+ if ( this.isTransitioning ) {
1098
+ return;
1099
+ }
1100
+
1101
+ // make `transition: foo, bar, baz` from style object
1102
+ // HACK un-comment this when enableTransition can work
1103
+ // while a transition is happening
1104
+ // var transitionValues = [];
1105
+ // for ( var prop in style ) {
1106
+ // // dash-ify camelCased properties like WebkitTransition
1107
+ // prop = vendorProperties[ prop ] || prop;
1108
+ // transitionValues.push( toDashedAll( prop ) );
1109
+ // }
1110
+ // munge number to millisecond, to match stagger
1111
+ var duration = this.layout.options.transitionDuration;
1112
+ duration = typeof duration == 'number' ? duration + 'ms' : duration;
1113
+ // enable transition styles
1114
+ this.css({
1115
+ transitionProperty: transitionProps,
1116
+ transitionDuration: duration,
1117
+ transitionDelay: this.staggerDelay || 0
1118
+ });
1119
+ // listen for transition end event
1120
+ this.element.addEventListener( transitionEndEvent, this, false );
1121
+ };
1122
 
1123
  // ----- events ----- //
1124
 
1125
+ proto.onwebkitTransitionEnd = function( event ) {
1126
+ this.ontransitionend( event );
1127
+ };
1128
 
1129
+ proto.onotransitionend = function( event ) {
1130
+ this.ontransitionend( event );
1131
+ };
1132
 
1133
  // properties that I munge to make my life easier
1134
+ var dashedVendorProperties = {
1135
+ '-webkit-transform': 'transform'
1136
+ };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1137
 
1138
+ proto.ontransitionend = function( event ) {
1139
+ // disregard bubbled events from children
1140
+ if ( event.target !== this.element ) {
1141
+ return;
1142
+ }
1143
+ var _transition = this._transn;
1144
+ // get property name of transitioned property, convert to prefix-free
1145
+ var propertyName = dashedVendorProperties[ event.propertyName ] || event.propertyName;
1146
+
1147
+ // remove property that has completed transitioning
1148
+ delete _transition.ingProperties[ propertyName ];
1149
+ // check if any properties are still transitioning
1150
+ if ( isEmptyObj( _transition.ingProperties ) ) {
1151
+ // all properties have completed transitioning
1152
+ this.disableTransition();
1153
+ }
1154
+ // clean style
1155
+ if ( propertyName in _transition.clean ) {
1156
+ // clean up style
1157
+ this.element.style[ event.propertyName ] = '';
1158
+ delete _transition.clean[ propertyName ];
1159
+ }
1160
+ // trigger onTransitionEnd callback
1161
+ if ( propertyName in _transition.onEnd ) {
1162
+ var onTransitionEnd = _transition.onEnd[ propertyName ];
1163
+ onTransitionEnd.call( this );
1164
+ delete _transition.onEnd[ propertyName ];
1165
+ }
1166
+
1167
+ this.emitEvent( 'transitionEnd', [ this ] );
1168
+ };
1169
+
1170
+ proto.disableTransition = function() {
1171
+ this.removeTransitionStyles();
1172
+ this.element.removeEventListener( transitionEndEvent, this, false );
1173
+ this.isTransitioning = false;
1174
+ };
1175
+
1176
+ /**
1177
+ * removes style property from element
1178
+ * @param {Object} style
1179
+ **/
1180
+ proto._removeStyles = function( style ) {
1181
+ // clean up transition styles
1182
+ var cleanStyle = {};
1183
+ for ( var prop in style ) {
1184
+ cleanStyle[ prop ] = '';
1185
+ }
1186
+ this.css( cleanStyle );
1187
+ };
1188
+
1189
+ var cleanTransitionStyle = {
1190
+ transitionProperty: '',
1191
+ transitionDuration: '',
1192
+ transitionDelay: ''
1193
+ };
1194
+
1195
+ proto.removeTransitionStyles = function() {
1196
+ // remove transition
1197
+ this.css( cleanTransitionStyle );
1198
+ };
1199
 
1200
  // ----- stagger ----- //
1201
 
1202
+ proto.stagger = function( delay ) {
1203
+ delay = isNaN( delay ) ? 0 : delay;
1204
+ this.staggerDelay = delay + 'ms';
1205
+ };
1206
 
1207
  // ----- show/hide/remove ----- //
1208
 
1209
  // remove element from DOM
1210
+ proto.removeElem = function() {
1211
+ this.element.parentNode.removeChild( this.element );
1212
+ // remove display: none
1213
+ this.css({ display: '' });
1214
+ this.emitEvent( 'remove', [ this ] );
1215
+ };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1216
 
1217
+ proto.remove = function() {
1218
+ // just remove element if no transition support or no transition
1219
+ if ( !transitionProperty || !parseFloat( this.layout.options.transitionDuration ) ) {
1220
+ this.removeElem();
1221
+ return;
1222
+ }
1223
+
1224
+ // start transition
1225
+ this.once( 'transitionEnd', function() {
1226
+ this.removeElem();
1227
+ });
1228
+ this.hide();
1229
+ };
1230
+
1231
+ proto.reveal = function() {
1232
+ delete this.isHidden;
1233
+ // remove display: none
1234
+ this.css({ display: '' });
1235
+
1236
+ var options = this.layout.options;
1237
+
1238
+ var onTransitionEnd = {};
1239
+ var transitionEndProperty = this.getHideRevealTransitionEndProperty('visibleStyle');
1240
+ onTransitionEnd[ transitionEndProperty ] = this.onRevealTransitionEnd;
1241
+
1242
+ this.transition({
1243
+ from: options.hiddenStyle,
1244
+ to: options.visibleStyle,
1245
+ isCleaning: true,
1246
+ onTransitionEnd: onTransitionEnd
1247
+ });
1248
+ };
1249
+
1250
+ proto.onRevealTransitionEnd = function() {
1251
+ // check if still visible
1252
+ // during transition, item may have been hidden
1253
+ if ( !this.isHidden ) {
1254
+ this.emitEvent('reveal');
1255
+ }
1256
+ };
1257
+
1258
+ /**
1259
+ * get style property use for hide/reveal transition end
1260
+ * @param {String} styleProperty - hiddenStyle/visibleStyle
1261
+ * @returns {String}
1262
+ */
1263
+ proto.getHideRevealTransitionEndProperty = function( styleProperty ) {
1264
+ var optionStyle = this.layout.options[ styleProperty ];
1265
+ // use opacity
1266
+ if ( optionStyle.opacity ) {
1267
+ return 'opacity';
1268
+ }
1269
+ // get first property
1270
+ for ( var prop in optionStyle ) {
1271
+ return prop;
1272
+ }
1273
+ };
1274
+
1275
+ proto.hide = function() {
1276
+ // set flag
1277
+ this.isHidden = true;
1278
+ // remove display: none
1279
+ this.css({ display: '' });
1280
+
1281
+ var options = this.layout.options;
1282
+
1283
+ var onTransitionEnd = {};
1284
+ var transitionEndProperty = this.getHideRevealTransitionEndProperty('hiddenStyle');
1285
+ onTransitionEnd[ transitionEndProperty ] = this.onHideTransitionEnd;
1286
+
1287
+ this.transition({
1288
+ from: options.visibleStyle,
1289
+ to: options.hiddenStyle,
1290
+ // keep hidden stuff hidden
1291
+ isCleaning: true,
1292
+ onTransitionEnd: onTransitionEnd
1293
+ });
1294
+ };
1295
+
1296
+ proto.onHideTransitionEnd = function() {
1297
+ // check if still hidden
1298
+ // during transition, item may have been un-hidden
1299
+ if ( this.isHidden ) {
1300
+ this.css({ display: 'none' });
1301
+ this.emitEvent('hide');
1302
+ }
1303
+ };
1304
+
1305
+ proto.destroy = function() {
1306
+ this.css({
1307
+ position: '',
1308
+ left: '',
1309
+ right: '',
1310
+ top: '',
1311
+ bottom: '',
1312
+ transition: '',
1313
+ transform: ''
1314
+ });
1315
+ };
1316
+
1317
+ return Item;
1318
 
1319
  }));
1320
 
1325
  */
1326
 
1327
  ( function( window, factory ) {
1328
+ 'use strict';
1329
+ // universal module definition
1330
+ /* jshint strict: false */ /* globals define, module, require */
1331
+ if ( typeof define == 'function' && define.amd ) {
1332
+ // AMD - RequireJS
1333
+ define( 'outlayer/outlayer',[
1334
+ 'ev-emitter/ev-emitter',
1335
+ 'get-size/get-size',
1336
+ 'fizzy-ui-utils/utils',
1337
+ './item'
1338
+ ],
1339
+ function( EvEmitter, getSize, utils, Item ) {
1340
+ return factory( window, EvEmitter, getSize, utils, Item);
1341
+ }
1342
+ );
1343
+ } else if ( typeof module == 'object' && module.exports ) {
1344
+ // CommonJS - Browserify, Webpack
1345
+ module.exports = factory(
1346
+ window,
1347
+ require('ev-emitter'),
1348
+ require('get-size'),
1349
+ require('fizzy-ui-utils'),
1350
+ require('./item')
1351
+ );
1352
+ } else {
1353
+ // browser global
1354
+ window.Outlayer = factory(
1355
+ window,
1356
+ window.EvEmitter,
1357
+ window.getSize,
1358
+ window.fizzyUIUtils,
1359
+ window.Outlayer.Item
1360
+ );
1361
+ }
1362
 
1363
  }( window, function factory( window, EvEmitter, getSize, utils, Item ) {
1364
+ 'use strict';
1365
 
1366
  // ----- vars ----- //
1367
 
1368
+ var console = window.console;
1369
+ var jQuery = window.jQuery;
1370
+ var noop = function() {};
1371
 
1372
  // -------------------------- Outlayer -------------------------- //
1373
 
1374
  // globally unique identifiers
1375
+ var GUID = 0;
1376
  // internal store of all Outlayer intances
1377
+ var instances = {};
1378
+
1379
+
1380
+ /**
1381
+ * @param {Element, String} element
1382
+ * @param {Object} options
1383
+ * @constructor
1384
+ */
1385
+ function Outlayer( element, options ) {
1386
+ var queryElement = utils.getQueryElement( element );
1387
+ if ( !queryElement ) {
1388
+ if ( console ) {
1389
+ console.error( 'Bad element for ' + this.constructor.namespace +
1390
+ ': ' + ( queryElement || element ) );
1391
+ }
1392
+ return;
1393
+ }
1394
+ this.element = queryElement;
1395
+ // add jQuery
1396
+ if ( jQuery ) {
1397
+ this.$element = jQuery( this.element );
1398
+ }
1399
 
1400
+ // options
1401
+ this.options = utils.extend( {}, this.constructor.defaults );
1402
+ this.option( options );
1403
 
1404
+ // add id for Outlayer.getFromElement
1405
+ var id = ++GUID;
1406
+ this.element.outlayerGUID = id; // expando
1407
+ instances[ id ] = this; // associate via id
1408
+
1409
+ // kick it off
1410
+ this._create();
1411
+
1412
+ var isInitLayout = this._getOption('initLayout');
1413
+ if ( isInitLayout ) {
1414
+ this.layout();
1415
+ }
1416
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1417
 
1418
  // settings are for internal use only
1419
+ Outlayer.namespace = 'outlayer';
1420
+ Outlayer.Item = Item;
1421
 
1422
  // default options
1423
+ Outlayer.defaults = {
1424
+ containerStyle: {
1425
+ position: 'relative'
1426
+ },
1427
+ initLayout: true,
1428
+ originLeft: true,
1429
+ originTop: true,
1430
+ resize: true,
1431
+ resizeContainer: true,
1432
+ // item options
1433
+ transitionDuration: '0.4s',
1434
+ hiddenStyle: {
1435
+ opacity: 0,
1436
+ transform: 'scale(0.001)'
1437
+ },
1438
+ visibleStyle: {
1439
+ opacity: 1,
1440
+ transform: 'scale(1)'
1441
+ }
1442
+ };
1443
+
1444
+ var proto = Outlayer.prototype;
1445
  // inherit EvEmitter
1446
+ utils.extend( proto, EvEmitter.prototype );
1447
+
1448
+ /**
1449
+ * set options
1450
+ * @param {Object} opts
1451
+ */
1452
+ proto.option = function( opts ) {
1453
+ utils.extend( this.options, opts );
1454
+ };
1455
 
1456
+ /**
1457
+ * get backwards compatible option value, check old name
1458
+ */
1459
+ proto._getOption = function( option ) {
1460
+ var oldOption = this.constructor.compatOptions[ option ];
1461
+ return oldOption && this.options[ oldOption ] !== undefined ?
1462
+ this.options[ oldOption ] : this.options[ option ];
1463
+ };
1464
 
1465
+ Outlayer.compatOptions = {
1466
+ // currentName: oldName
1467
+ initLayout: 'isInitLayout',
1468
+ horizontal: 'isHorizontal',
1469
+ layoutInstant: 'isLayoutInstant',
1470
+ originLeft: 'isOriginLeft',
1471
+ originTop: 'isOriginTop',
1472
+ resize: 'isResizeBound',
1473
+ resizeContainer: 'isResizingContainer'
1474
+ };
1475
+
1476
+ proto._create = function() {
1477
+ // get items from children
1478
+ this.reloadItems();
1479
+ // elements that affect layout, but are not laid out
1480
+ this.stamps = [];
1481
+ this.stamp( this.options.stamp );
1482
+ // set container style
1483
+ utils.extend( this.element.style, this.options.containerStyle );
1484
+
1485
+ // bind resize method
1486
+ var canBindResize = this._getOption('resize');
1487
+ if ( canBindResize ) {
1488
+ this.bindResize();
1489
+ }
1490
+ };
 
 
 
 
 
 
 
 
 
1491
 
1492
  // goes through all children again and gets bricks in proper order
1493
+ proto.reloadItems = function() {
1494
+ // collection of item elements
1495
+ this.items = this._itemize( this.element.children );
1496
+ };
1497
 
1498
 
1499
+ /**
1500
+ * turn elements into Outlayer.Items to be used in layout
1501
+ * @param {Array or NodeList or HTMLElement} elems
1502
+ * @returns {Array} items - collection of new Outlayer Items
1503
+ */
1504
+ proto._itemize = function( elems ) {
1505
 
1506
+ var itemElems = this._filterFindItemElements( elems );
1507
+ var Item = this.constructor.Item;
1508
 
1509
+ // create new Outlayer Items for collection
1510
+ var items = [];
1511
+ for ( var i=0; i < itemElems.length; i++ ) {
1512
+ var elem = itemElems[i];
1513
+ var item = new Item( elem, this );
1514
+ items.push( item );
1515
+ }
1516
 
1517
+ return items;
1518
+ };
1519
 
1520
+ /**
1521
+ * get item elements to be used in layout
1522
+ * @param {Array or NodeList or HTMLElement} elems
1523
+ * @returns {Array} items - item elements
1524
+ */
1525
+ proto._filterFindItemElements = function( elems ) {
1526
+ return utils.filterFindElements( elems, this.options.itemSelector );
1527
+ };
1528
 
1529
+ /**
1530
+ * getter method for getting item elements
1531
+ * @returns {Array} elems - collection of item elements
1532
+ */
1533
+ proto.getItemElements = function() {
1534
+ return this.items.map( function( item ) {
1535
+ return item.element;
1536
+ });
1537
+ };
1538
 
1539
  // ----- init & layout ----- //
1540
 
1541
+ /**
1542
+ * lays out all items
1543
+ */
1544
+ proto.layout = function() {
1545
+ this._resetLayout();
1546
+ this._manageStamps();
1547
+
1548
+ // don't animate first layout
1549
+ var layoutInstant = this._getOption('layoutInstant');
1550
+ var isInstant = layoutInstant !== undefined ?
1551
+ layoutInstant : !this._isLayoutInited;
1552
+ this.layoutItems( this.items, isInstant );
1553
+
1554
+ // flag for initalized
1555
+ this._isLayoutInited = true;
1556
+ };
1557
 
1558
+ // _init is alias for layout
1559
+ proto._init = proto.layout;
 
 
 
1560
 
1561
+ /**
1562
+ * logic before any new layout
1563
+ */
1564
+ proto._resetLayout = function() {
1565
+ this.getSize();
1566
+ };
1567
 
 
 
1568
 
1569
+ proto.getSize = function() {
1570
+ this.size = getSize( this.element );
1571
+ };
 
 
 
1572
 
1573
+ /**
1574
+ * get measurement from option, for columnWidth, rowHeight, gutter
1575
+ * if option is String -> get element from selector string, & get size of element
1576
+ * if option is Element -> get size of element
1577
+ * else use option as a number
1578
+ *
1579
+ * @param {String} measurement
1580
+ * @param {String} size - width or height
1581
+ * @private
1582
+ */
1583
+ proto._getMeasurement = function( measurement, size ) {
1584
+ var option = this.options[ measurement ];
1585
+ var elem;
1586
+ if ( !option ) {
1587
+ // default to 0
1588
+ this[ measurement ] = 0;
1589
+ } else {
1590
+ // use option as an element
1591
+ if ( typeof option == 'string' ) {
1592
+ elem = this.element.querySelector( option );
1593
+ } else if ( option instanceof HTMLElement ) {
1594
+ elem = option;
1595
+ }
1596
+ // use size of element, if element
1597
+ this[ measurement ] = elem ? getSize( elem )[ size ] : option;
1598
+ }
1599
+ };
1600
 
1601
+ /**
1602
+ * layout a collection of item elements
1603
+ * @api public
1604
+ */
1605
+ proto.layoutItems = function( items, isInstant ) {
1606
+ items = this._getItemsForLayout( items );
1607
 
1608
+ this._layoutItems( items, isInstant );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1609
 
1610
+ this._postLayout();
1611
+ };
 
 
 
 
1612
 
1613
+ /**
1614
+ * get the items to be laid out
1615
+ * you may want to skip over some items
1616
+ * @param {Array} items
1617
+ * @returns {Array} items
1618
+ */
1619
+ proto._getItemsForLayout = function( items ) {
1620
+ return items.filter( function( item ) {
1621
+ return !item.isIgnored;
1622
+ });
1623
+ };
1624
 
1625
+ /**
1626
+ * layout items
1627
+ * @param {Array} items
1628
+ * @param {Boolean} isInstant
1629
+ */
1630
+ proto._layoutItems = function( items, isInstant ) {
1631
+ this._emitCompleteOnItems( 'layout', items );
1632
+
1633
+ if ( !items || !items.length ) {
1634
+ // no items, emit event with empty array
1635
+ return;
1636
+ }
1637
 
1638
+ var queue = [];
 
 
 
 
 
 
 
 
 
 
1639
 
1640
+ items.forEach( function( item ) {
1641
+ // get x/y object from method
1642
+ var position = this._getItemLayoutPosition( item );
1643
+ // enqueue
1644
+ position.item = item;
1645
+ position.isInstant = isInstant || item.isLayoutInstant;
1646
+ queue.push( position );
1647
+ }, this );
1648
 
1649
+ this._processLayoutQueue( queue );
1650
+ };
 
 
1651
 
1652
+ /**
1653
+ * get item layout position
1654
+ * @param {Outlayer.Item} item
1655
+ * @returns {Object} x and y position
1656
+ */
1657
+ proto._getItemLayoutPosition = function( /* item */ ) {
1658
+ return {
1659
+ x: 0,
1660
+ y: 0
1661
+ };
1662
+ };
1663
 
1664
+ /**
1665
+ * iterate over array and position each item
1666
+ * Reason being - separating this logic prevents 'layout invalidation'
1667
+ * thx @paul_irish
1668
+ * @param {Array} queue
1669
+ */
1670
+ proto._processLayoutQueue = function( queue ) {
1671
+ this.updateStagger();
1672
+ queue.forEach( function( obj, i ) {
1673
+ this._positionItem( obj.item, obj.x, obj.y, obj.isInstant, i );
1674
+ }, this );
1675
+ };
1676
 
1677
+ // set stagger from option in milliseconds number
1678
+ proto.updateStagger = function() {
1679
+ var stagger = this.options.stagger;
1680
+ if ( stagger === null || stagger === undefined ) {
1681
+ this.stagger = 0;
1682
+ return;
1683
+ }
1684
+ this.stagger = getMilliseconds( stagger );
1685
+ return this.stagger;
1686
+ };
1687
 
1688
+ /**
1689
+ * Sets position of item in DOM
1690
+ * @param {Outlayer.Item} item
1691
+ * @param {Number} x - horizontal position
1692
+ * @param {Number} y - vertical position
1693
+ * @param {Boolean} isInstant - disables transitions
1694
+ */
1695
+ proto._positionItem = function( item, x, y, isInstant, i ) {
1696
+ if ( isInstant ) {
1697
+ // if not transition, just set CSS
1698
+ item.goTo( x, y );
1699
+ } else {
1700
+ item.stagger( i * this.stagger );
1701
+ item.moveTo( x, y );
1702
+ }
1703
+ };
1704
 
1705
+ /**
1706
+ * Any logic you want to do after each layout,
1707
+ * i.e. size the container
1708
+ */
1709
+ proto._postLayout = function() {
1710
+ this.resizeContainer();
1711
+ };
 
 
 
 
 
1712
 
1713
+ proto.resizeContainer = function() {
1714
+ var isResizingContainer = this._getOption('resizeContainer');
1715
+ if ( !isResizingContainer ) {
1716
+ return;
1717
+ }
1718
+ var size = this._getContainerSize();
1719
+ if ( size ) {
1720
+ this._setContainerMeasure( size.width, true );
1721
+ this._setContainerMeasure( size.height, false );
1722
+ }
1723
+ };
1724
 
1725
+ /**
1726
+ * Sets width or height of container if returned
1727
+ * @returns {Object} size
1728
+ * @param {Number} width
1729
+ * @param {Number} height
1730
+ */
1731
+ proto._getContainerSize = noop;
1732
+
1733
+ /**
1734
+ * @param {Number} measure - size of width or height
1735
+ * @param {Boolean} isWidth
1736
+ */
1737
+ proto._setContainerMeasure = function( measure, isWidth ) {
1738
+ if ( measure === undefined ) {
1739
+ return;
1740
+ }
1741
 
1742
+ var elemSize = this.size;
1743
+ // add padding and border width if border box
1744
+ if ( elemSize.isBorderBox ) {
1745
+ measure += isWidth ? elemSize.paddingLeft + elemSize.paddingRight +
1746
+ elemSize.borderLeftWidth + elemSize.borderRightWidth :
1747
+ elemSize.paddingBottom + elemSize.paddingTop +
1748
+ elemSize.borderTopWidth + elemSize.borderBottomWidth;
1749
+ }
 
 
 
 
 
 
 
 
 
 
 
1750
 
1751
+ measure = Math.max( measure, 0 );
1752
+ this.element.style[ isWidth ? 'width' : 'height' ] = measure + 'px';
1753
+ };
 
 
 
 
1754
 
1755
+ /**
1756
+ * emit eventComplete on a collection of items events
1757
+ * @param {String} eventName
1758
+ * @param {Array} items - Outlayer.Items
1759
+ */
1760
+ proto._emitCompleteOnItems = function( eventName, items ) {
1761
+ var _this = this;
1762
+ function onComplete() {
1763
+ _this.dispatchEvent( eventName + 'Complete', null, [ items ] );
1764
+ }
 
 
 
 
 
 
 
 
 
 
 
1765
 
1766
+ var count = items.length;
1767
+ if ( !items || !count ) {
1768
+ onComplete();
1769
+ return;
1770
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1771
 
1772
+ var doneCount = 0;
1773
+ function tick() {
1774
+ doneCount++;
1775
+ if ( doneCount == count ) {
1776
+ onComplete();
1777
+ }
1778
+ }
1779
 
1780
+ // bind callback
1781
+ items.forEach( function( item ) {
1782
+ item.once( eventName, tick );
1783
+ });
1784
+ };
1785
+
1786
+ /**
1787
+ * emits events via EvEmitter and jQuery events
1788
+ * @param {String} type - name of event
1789
+ * @param {Event} event - original event
1790
+ * @param {Array} args - extra arguments
1791
+ */
1792
+ proto.dispatchEvent = function( type, event, args ) {
1793
+ // add original event to arguments
1794
+ var emitArgs = event ? [ event ].concat( args ) : args;
1795
+ this.emitEvent( type, emitArgs );
1796
+
1797
+ if ( jQuery ) {
1798
+ // set this.$element
1799
+ this.$element = this.$element || jQuery( this.element );
1800
+ if ( event ) {
1801
+ // create jQuery event
1802
+ var $event = jQuery.Event( event );
1803
+ $event.type = type;
1804
+ this.$element.trigger( $event, args );
1805
+ } else {
1806
+ // just trigger with type if no event available
1807
+ this.$element.trigger( type, args );
1808
+ }
1809
+ }
1810
+ };
1811
 
1812
  // -------------------------- ignore & stamps -------------------------- //
1813
 
1814
 
1815
+ /**
1816
+ * keep item in collection, but do not lay it out
1817
+ * ignored items do not get skipped in layout
1818
+ * @param {Element} elem
1819
+ */
1820
+ proto.ignore = function( elem ) {
1821
+ var item = this.getItem( elem );
1822
+ if ( item ) {
1823
+ item.isIgnored = true;
1824
+ }
1825
+ };
1826
 
1827
+ /**
1828
+ * return item to layout collection
1829
+ * @param {Element} elem
1830
+ */
1831
+ proto.unignore = function( elem ) {
1832
+ var item = this.getItem( elem );
1833
+ if ( item ) {
1834
+ delete item.isIgnored;
1835
+ }
1836
+ };
1837
 
1838
+ /**
1839
+ * adds elements to stamps
1840
+ * @param {NodeList, Array, Element, or String} elems
1841
+ */
1842
+ proto.stamp = function( elems ) {
1843
+ elems = this._find( elems );
1844
+ if ( !elems ) {
1845
+ return;
1846
+ }
1847
 
1848
+ this.stamps = this.stamps.concat( elems );
1849
+ // ignore
1850
+ elems.forEach( this.ignore, this );
1851
+ };
1852
 
1853
+ /**
1854
+ * removes elements to stamps
1855
+ * @param {NodeList, Array, or Element} elems
1856
+ */
1857
+ proto.unstamp = function( elems ) {
1858
+ elems = this._find( elems );
1859
+ if ( !elems ){
1860
+ return;
1861
+ }
 
 
 
 
 
 
 
1862
 
1863
+ elems.forEach( function( elem ) {
1864
+ // filter out removed stamp elements
1865
+ utils.removeFrom( this.stamps, elem );
1866
+ this.unignore( elem );
1867
+ }, this );
1868
+ };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1869
 
1870
+ /**
1871
+ * finds child elements
1872
+ * @param {NodeList, Array, Element, or String} elems
1873
+ * @returns {Array} elems
1874
+ */
1875
+ proto._find = function( elems ) {
1876
+ if ( !elems ) {
1877
+ return;
1878
+ }
1879
+ // if string, use argument as selector string
1880
+ if ( typeof elems == 'string' ) {
1881
+ elems = this.element.querySelectorAll( elems );
1882
+ }
1883
+ elems = utils.makeArray( elems );
1884
+ return elems;
1885
+ };
1886
 
1887
+ proto._manageStamps = function() {
1888
+ if ( !this.stamps || !this.stamps.length ) {
1889
+ return;
1890
+ }
1891
 
1892
+ this._getBoundingRect();
1893
+
1894
+ this.stamps.forEach( this._manageStamp, this );
1895
+ };
1896
+
1897
+ // update boundingLeft / Top
1898
+ proto._getBoundingRect = function() {
1899
+ // get bounding rect for container element
1900
+ var boundingRect = this.element.getBoundingClientRect();
1901
+ var size = this.size;
1902
+ this._boundingRect = {
1903
+ left: boundingRect.left + size.paddingLeft + size.borderLeftWidth,
1904
+ top: boundingRect.top + size.paddingTop + size.borderTopWidth,
1905
+ right: boundingRect.right - ( size.paddingRight + size.borderRightWidth ),
1906
+ bottom: boundingRect.bottom - ( size.paddingBottom + size.borderBottomWidth )
1907
+ };
1908
+ };
1909
+
1910
+ /**
1911
+ * @param {Element} stamp
1912
+ **/
1913
+ proto._manageStamp = noop;
1914
+
1915
+ /**
1916
+ * get x/y position of element relative to container element
1917
+ * @param {Element} elem
1918
+ * @returns {Object} offset - has left, top, right, bottom
1919
+ */
1920
+ proto._getElementOffset = function( elem ) {
1921
+ var boundingRect = elem.getBoundingClientRect();
1922
+ var thisRect = this._boundingRect;
1923
+ var size = getSize( elem );
1924
+ var offset = {
1925
+ left: boundingRect.left - thisRect.left - size.marginLeft,
1926
+ top: boundingRect.top - thisRect.top - size.marginTop,
1927
+ right: thisRect.right - boundingRect.right - size.marginRight,
1928
+ bottom: thisRect.bottom - boundingRect.bottom - size.marginBottom
1929
+ };
1930
+ return offset;
1931
+ };
1932
 
1933
  // -------------------------- resize -------------------------- //
1934
 
1935
  // enable event handlers for listeners
1936
  // i.e. resize -> onresize
1937
+ proto.handleEvent = utils.handleEvent;
1938
+
1939
+ /**
1940
+ * Bind layout to window resizing
1941
+ */
1942
+ proto.bindResize = function() {
1943
+ window.addEventListener( 'resize', this );
1944
+ this.isResizeBound = true;
1945
+ };
1946
 
1947
+ /**
1948
+ * Unbind layout to window resizing
1949
+ */
1950
+ proto.unbindResize = function() {
1951
+ window.removeEventListener( 'resize', this );
1952
+ this.isResizeBound = false;
1953
+ };
1954
 
1955
+ proto.onresize = function() {
1956
+ this.resize();
1957
+ };
1958
 
1959
+ utils.debounceMethod( Outlayer, 'onresize', 100 );
1960
 
1961
+ proto.resize = function() {
1962
+ // don't trigger if size did not change
1963
+ // or if resize was unbound. See #9
1964
+ if ( !this.isResizeBound || !this.needsResizeLayout() ) {
1965
+ return;
1966
+ }
1967
 
1968
+ this.layout();
1969
+ };
1970
 
1971
+ /**
1972
+ * check if layout is needed post layout
1973
+ * @returns Boolean
1974
+ */
1975
+ proto.needsResizeLayout = function() {
1976
+ var size = getSize( this.element );
1977
+ // check that this.size and size are there
1978
+ // IE8 triggers resize on body size change, so they might not be
1979
+ var hasSizes = this.size && size;
1980
+ return hasSizes && size.innerWidth !== this.size.innerWidth;
1981
+ };
1982
 
1983
  // -------------------------- methods -------------------------- //
1984
 
1985
+ /**
1986
+ * add items to Outlayer instance
1987
+ * @param {Array or NodeList or Element} elems
1988
+ * @returns {Array} items - Outlayer.Items
1989
+ **/
1990
+ proto.addItems = function( elems ) {
1991
+ var items = this._itemize( elems );
1992
+ // add items to collection
1993
+ if ( items.length ) {
1994
+ this.items = this.items.concat( items );
1995
+ }
1996
+ return items;
1997
+ };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1998
 
1999
+ /**
2000
+ * Layout newly-appended item elements
2001
+ * @param {Array or NodeList or Element} elems
2002
+ */
2003
+ proto.appended = function( elems ) {
2004
+ var items = this.addItems( elems );
2005
+ if ( !items.length ) {
2006
+ return;
2007
+ }
2008
+ // layout and reveal just the new items
2009
+ this.layoutItems( items, true );
2010
+ this.reveal( items );
2011
+ };
 
 
 
 
 
 
 
 
2012
 
2013
+ /**
2014
+ * Layout prepended elements
2015
+ * @param {Array or NodeList or Element} elems
2016
+ */
2017
+ proto.prepended = function( elems ) {
2018
+ var items = this._itemize( elems );
2019
+ if ( !items.length ) {
2020
+ return;
2021
+ }
2022
+ // add items to beginning of collection
2023
+ var previousItems = this.items.slice(0);
2024
+ this.items = items.concat( previousItems );
2025
+ // start new layout
2026
+ this._resetLayout();
2027
+ this._manageStamps();
2028
+ // layout new stuff without transition
2029
+ this.layoutItems( items, true );
2030
+ this.reveal( items );
2031
+ // layout previous items
2032
+ this.layoutItems( previousItems );
2033
+ };
2034
 
2035
+ /**
2036
+ * reveal a collection of items
2037
+ * @param {Array of Outlayer.Items} items
2038
+ */
2039
+ proto.reveal = function( items ) {
2040
+ this._emitCompleteOnItems( 'reveal', items );
2041
+ if ( !items || !items.length ) {
2042
+ return;
2043
+ }
2044
+ var stagger = this.updateStagger();
2045
+ items.forEach( function( item, i ) {
2046
+ item.stagger( i * stagger );
2047
+ item.reveal();
2048
+ });
2049
+ };
2050
 
2051
+ /**
2052
+ * hide a collection of items
2053
+ * @param {Array of Outlayer.Items} items
2054
+ */
2055
+ proto.hide = function( items ) {
2056
+ this._emitCompleteOnItems( 'hide', items );
2057
+ if ( !items || !items.length ) {
2058
+ return;
2059
+ }
2060
+ var stagger = this.updateStagger();
2061
+ items.forEach( function( item, i ) {
2062
+ item.stagger( i * stagger );
2063
+ item.hide();
2064
+ });
2065
+ };
2066
 
2067
+ /**
2068
+ * reveal item elements
2069
+ * @param {Array}, {Element}, {NodeList} items
2070
+ */
2071
+ proto.revealItemElements = function( elems ) {
2072
+ var items = this.getItems( elems );
2073
+ this.reveal( items );
2074
+ };
2075
 
2076
+ /**
2077
+ * hide item elements
2078
+ * @param {Array}, {Element}, {NodeList} items
2079
+ */
2080
+ proto.hideItemElements = function( elems ) {
2081
+ var items = this.getItems( elems );
2082
+ this.hide( items );
2083
+ };
 
 
 
 
 
 
 
 
2084
 
2085
+ /**
2086
+ * get Outlayer.Item, given an Element
2087
+ * @param {Element} elem
2088
+ * @param {Function} callback
2089
+ * @returns {Outlayer.Item} item
2090
+ */
2091
+ proto.getItem = function( elem ) {
2092
+ // loop through items to get the one that matches
2093
+ for ( var i=0; i < this.items.length; i++ ) {
2094
+ var item = this.items[i];
2095
+ if ( item.element == elem ) {
2096
+ // return item
2097
+ return item;
2098
+ }
2099
+ }
2100
+ };
2101
 
2102
+ /**
2103
+ * get collection of Outlayer.Items, given Elements
2104
+ * @param {Array} elems
2105
+ * @returns {Array} items - Outlayer.Items
2106
+ */
2107
+ proto.getItems = function( elems ) {
2108
+ elems = utils.makeArray( elems );
2109
+ var items = [];
2110
+ elems.forEach( function( elem ) {
2111
+ var item = this.getItem( elem );
2112
+ if ( item ) {
2113
+ items.push( item );
2114
+ }
2115
+ }, this );
2116
+
2117
+ return items;
2118
+ };
2119
 
2120
+ /**
2121
+ * remove element(s) from instance and DOM
2122
+ * @param {Array or NodeList or Element} elems
2123
+ */
2124
+ proto.remove = function( elems ) {
2125
+ var removeItems = this.getItems( elems );
2126
 
2127
+ this._emitCompleteOnItems( 'remove', removeItems );
2128
 
2129
+ // bail if no items to remove
2130
+ if ( !removeItems || !removeItems.length ) {
2131
+ return;
2132
+ }
2133
 
2134
+ removeItems.forEach( function( item ) {
2135
+ item.remove();
2136
+ // remove item from collection
2137
+ utils.removeFrom( this.items, item );
2138
+ }, this );
2139
+ };
2140
 
2141
  // ----- destroy ----- //
2142
 
2143
  // remove and disable Outlayer instance
2144
+ proto.destroy = function() {
2145
+ // clean up dynamic styles
2146
+ var style = this.element.style;
2147
+ style.height = '';
2148
+ style.position = '';
2149
+ style.width = '';
2150
+ // destroy items
2151
+ this.items.forEach( function( item ) {
2152
+ item.destroy();
2153
+ });
2154
+
2155
+ this.unbindResize();
2156
+
2157
+ var id = this.element.outlayerGUID;
2158
+ delete instances[ id ]; // remove reference to instance by id
2159
+ delete this.element.outlayerGUID;
2160
+ // remove data for jQuery
2161
+ if ( jQuery ) {
2162
+ jQuery.removeData( this.element, this.constructor.namespace );
2163
+ }
2164
+
2165
+ };
2166
 
2167
  // -------------------------- data -------------------------- //
2168
 
2169
+ /**
2170
+ * get Outlayer instance from element
2171
+ * @param {Element} elem
2172
+ * @returns {Outlayer}
2173
+ */
2174
+ Outlayer.data = function( elem ) {
2175
+ elem = utils.getQueryElement( elem );
2176
+ var id = elem && elem.outlayerGUID;
2177
+ return id && instances[ id ];
2178
+ };
2179
 
2180
 
2181
  // -------------------------- create Outlayer class -------------------------- //
2182
 
2183
+ /**
2184
+ * create a layout class
2185
+ * @param {String} namespace
2186
+ */
2187
+ Outlayer.create = function( namespace, options ) {
2188
+ // sub-class Outlayer
2189
+ var Layout = subclass( Outlayer );
2190
+ // apply new options and compatOptions
2191
+ Layout.defaults = utils.extend( {}, Outlayer.defaults );
2192
+ utils.extend( Layout.defaults, options );
2193
+ Layout.compatOptions = utils.extend( {}, Outlayer.compatOptions );
2194
 
2195
+ Layout.namespace = namespace;
2196
 
2197
+ Layout.data = Outlayer.data;
2198
 
2199
+ // sub-class Item
2200
+ Layout.Item = subclass( Item );
2201
 
2202
+ // -------------------------- declarative -------------------------- //
2203
 
2204
+ utils.htmlInit( Layout, namespace );
2205
 
2206
+ // -------------------------- jQuery bridge -------------------------- //
2207
 
2208
+ // make into jQuery plugin
2209
+ if ( jQuery && jQuery.bridget ) {
2210
+ jQuery.bridget( namespace, Layout );
2211
+ }
2212
 
2213
+ return Layout;
2214
+ };
2215
 
2216
+ function subclass( Parent ) {
2217
+ function SubClass() {
2218
+ Parent.apply( this, arguments );
2219
+ }
2220
 
2221
+ SubClass.prototype = Object.create( Parent.prototype );
2222
+ SubClass.prototype.constructor = SubClass;
2223
 
2224
+ return SubClass;
2225
+ }
2226
 
2227
  // ----- helpers ----- //
2228
 
2229
  // how many milliseconds are in each unit
2230
+ var msUnits = {
2231
+ ms: 1,
2232
+ s: 1000
2233
+ };
2234
 
2235
  // munge time-like parameter into millisecond number
2236
  // '0.4s' -> 40
2237
+ function getMilliseconds( time ) {
2238
+ if ( typeof time == 'number' ) {
2239
+ return time;
2240
+ }
2241
+ var matches = time.match( /(^\d*\.?\d*)(\w*)/ );
2242
+ var num = matches && matches[1];
2243
+ var unit = matches && matches[2];
2244
+ if ( !num.length ) {
2245
+ return 0;
2246
+ }
2247
+ num = parseFloat( num );
2248
+ var mult = msUnits[ unit ] || 1;
2249
+ return num * mult;
2250
+ }
2251
 
2252
  // ----- fin ----- //
2253
 
2254
  // back in global
2255
+ Outlayer.Item = Item;
2256
 
2257
+ return Outlayer;
2258
 
2259
  }));
2260
 
2261
  /**
2262
  * Isotope Item
2263
+ **/
2264
 
2265
  ( function( window, factory ) {
2266
+ // universal module definition
2267
+ /* jshint strict: false */ /*globals define, module, require */
2268
+ if ( typeof define == 'function' && define.amd ) {
2269
+ // AMD
2270
+ define( 'isotope/js/item',[
2271
+ 'outlayer/outlayer'
2272
+ ],
2273
+ factory );
2274
+ } else if ( typeof module == 'object' && module.exports ) {
2275
+ // CommonJS
2276
+ module.exports = factory(
2277
+ require('outlayer')
2278
+ );
2279
+ } else {
2280
+ // browser global
2281
+ window.Isotope = window.Isotope || {};
2282
+ window.Isotope.Item = factory(
2283
+ window.Outlayer
2284
+ );
2285
+ }
2286
 
2287
  }( window, function factory( Outlayer ) {
2288
+ 'use strict';
2289
 
2290
  // -------------------------- Item -------------------------- //
2291
 
2292
  // sub-class Outlayer Item
2293
+ function Item() {
2294
+ Outlayer.Item.apply( this, arguments );
2295
+ }
2296
+
2297
+ var proto = Item.prototype = Object.create( Outlayer.Item.prototype );
2298
+
2299
+ var _create = proto._create;
2300
+ proto._create = function() {
2301
+ // assign id, used for original-order sorting
2302
+ this.id = this.layout.itemGUID++;
2303
+ _create.call( this );
2304
+ this.sortData = {};
2305
+ };
2306
+
2307
+ proto.updateSortData = function() {
2308
+ if ( this.isIgnored ) {
2309
+ return;
2310
+ }
2311
+ // default sorters
2312
+ this.sortData.id = this.id;
2313
+ // for backward compatibility
2314
+ this.sortData['original-order'] = this.id;
2315
+ this.sortData.random = Math.random();
2316
+ // go thru getSortData obj and apply the sorters
2317
+ var getSortData = this.layout.options.getSortData;
2318
+ var sorters = this.layout._sorters;
2319
+ for ( var key in getSortData ) {
2320
+ var sorter = sorters[ key ];
2321
+ this.sortData[ key ] = sorter( this.element, this );
2322
+ }
2323
+ };
2324
+
2325
+ var _destroy = proto.destroy;
2326
+ proto.destroy = function() {
2327
+ // call super
2328
+ _destroy.apply( this, arguments );
2329
+ // reset display, #741
2330
+ this.css({
2331
+ display: ''
2332
+ });
2333
+ };
2334
+
2335
+ return Item;
2336
 
2337
  }));
2338
 
2341
  */
2342
 
2343
  ( function( window, factory ) {
2344
+ // universal module definition
2345
+ /* jshint strict: false */ /*globals define, module, require */
2346
+ if ( typeof define == 'function' && define.amd ) {
2347
+ // AMD
2348
+ define( 'isotope/js/layout-mode',[
2349
+ 'get-size/get-size',
2350
+ 'outlayer/outlayer'
2351
+ ],
2352
+ factory );
2353
+ } else if ( typeof module == 'object' && module.exports ) {
2354
+ // CommonJS
2355
+ module.exports = factory(
2356
+ require('get-size'),
2357
+ require('outlayer')
2358
+ );
2359
+ } else {
2360
+ // browser global
2361
+ window.Isotope = window.Isotope || {};
2362
+ window.Isotope.LayoutMode = factory(
2363
+ window.getSize,
2364
+ window.Outlayer
2365
+ );
2366
+ }
2367
 
2368
  }( window, function factory( getSize, Outlayer ) {
2369
+ 'use strict';
2370
+
2371
+ // layout mode class
2372
+ function LayoutMode( isotope ) {
2373
+ this.isotope = isotope;
2374
+ // link properties
2375
+ if ( isotope ) {
2376
+ this.options = isotope.options[ this.namespace ];
2377
+ this.element = isotope.element;
2378
+ this.items = isotope.filteredItems;
2379
+ this.size = isotope.size;
2380
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2381
  }
 
 
 
 
 
 
2382
 
2383
+ var proto = LayoutMode.prototype;
2384
+
2385
+ /**
2386
+ * some methods should just defer to default Outlayer method
2387
+ * and reference the Isotope instance as `this`
2388
+ **/
2389
+ var facadeMethods = [
2390
+ '_resetLayout',
2391
+ '_getItemLayoutPosition',
2392
+ '_manageStamp',
2393
+ '_getContainerSize',
2394
+ '_getElementOffset',
2395
+ 'needsResizeLayout',
2396
+ '_getOption'
2397
+ ];
2398
+
2399
+ facadeMethods.forEach( function( methodName ) {
2400
+ proto[ methodName ] = function() {
2401
+ return Outlayer.prototype[ methodName ].apply( this.isotope, arguments );
2402
+ };
2403
+ });
2404
+
2405
+ // ----- ----- //
2406
 
2407
+ // for horizontal layout modes, check vertical size
2408
+ proto.needsVerticalResizeLayout = function() {
2409
+ // don't trigger if size did not change
2410
+ var size = getSize( this.isotope.element );
2411
+ // check that this.size and size are there
2412
+ // IE8 triggers resize on body size change, so they might not be
2413
+ var hasSizes = this.isotope.size && size;
2414
+ return hasSizes && size.innerHeight != this.isotope.size.innerHeight;
2415
+ };
2416
+
2417
+ // ----- measurements ----- //
2418
 
2419
+ proto._getMeasurement = function() {
2420
+ this.isotope._getMeasurement.apply( this, arguments );
2421
+ };
2422
 
2423
+ proto.getColumnWidth = function() {
2424
+ this.getSegmentSize( 'column', 'Width' );
2425
+ };
 
2426
 
2427
+ proto.getRowHeight = function() {
2428
+ this.getSegmentSize( 'row', 'Height' );
2429
+ };
2430
 
2431
+ /**
2432
+ * get columnWidth or rowHeight
2433
+ * segment: 'column' or 'row'
2434
+ * size 'Width' or 'Height'
2435
+ **/
2436
+ proto.getSegmentSize = function( segment, size ) {
2437
+ var segmentName = segment + size;
2438
+ var outerSize = 'outer' + size;
2439
+ // columnWidth / outerWidth // rowHeight / outerHeight
2440
+ this._getMeasurement( segmentName, outerSize );
2441
+ // got rowHeight or columnWidth, we can chill
2442
+ if ( this[ segmentName ] ) {
2443
+ return;
2444
+ }
2445
+ // fall back to item of first element
2446
+ var firstItemSize = this.getFirstItemSize();
2447
+ this[ segmentName ] = firstItemSize && firstItemSize[ outerSize ] ||
2448
+ // or size of container
2449
+ this.isotope.size[ 'inner' + size ];
2450
+ };
2451
 
2452
+ proto.getFirstItemSize = function() {
2453
+ var firstItem = this.isotope.filteredItems[0];
2454
+ return firstItem && firstItem.element && getSize( firstItem.element );
2455
+ };
2456
 
2457
+ // ----- methods that should reference isotope ----- //
 
 
2458
 
2459
+ proto.layout = function() {
2460
+ this.isotope.layout.apply( this.isotope, arguments );
2461
+ };
2462
 
2463
+ proto.getSize = function() {
2464
+ this.isotope.getSize();
2465
+ this.size = this.isotope.size;
2466
+ };
2467
 
2468
+ // -------------------------- create -------------------------- //
 
 
2469
 
2470
+ LayoutMode.modes = {};
 
2471
 
2472
+ LayoutMode.create = function( namespace, options ) {
2473
+
2474
+ function Mode() {
2475
+ LayoutMode.apply( this, arguments );
2476
+ }
2477
+
2478
+ Mode.prototype = Object.create( proto );
2479
+ Mode.prototype.constructor = Mode;
2480
+
2481
+ // default options
2482
+ if ( options ) {
2483
+ Mode.options = options;
2484
+ }
2485
+
2486
+ Mode.prototype.namespace = namespace;
2487
+ // register in Isotope
2488
+ LayoutMode.modes[ namespace ] = Mode;
2489
+
2490
+ return Mode;
2491
+ };
2492
+
2493
+ return LayoutMode;
2494
 
2495
  }));
2496
 
2503
  */
2504
 
2505
  ( function( window, factory ) {
2506
+ // universal module definition
2507
+ /* jshint strict: false */ /*globals define, module, require */
2508
+ if ( typeof define == 'function' && define.amd ) {
2509
+ // AMD
2510
+ define( 'masonry/masonry',[
2511
+ 'outlayer/outlayer',
2512
+ 'get-size/get-size'
2513
+ ],
2514
+ factory );
2515
+ } else if ( typeof module == 'object' && module.exports ) {
2516
+ // CommonJS
2517
+ module.exports = factory(
2518
+ require('outlayer'),
2519
+ require('get-size')
2520
+ );
2521
+ } else {
2522
+ // browser global
2523
+ window.Masonry = factory(
2524
+ window.Outlayer,
2525
+ window.getSize
2526
+ );
2527
+ }
2528
 
2529
  }( window, function factory( Outlayer, getSize ) {
2530
 
2532
 
2533
  // -------------------------- masonryDefinition -------------------------- //
2534
 
2535
+ // create an Outlayer layout class
2536
+ var Masonry = Outlayer.create('masonry');
2537
+ // isFitWidth -> fitWidth
2538
+ Masonry.compatOptions.fitWidth = 'isFitWidth';
2539
+
2540
+ Masonry.prototype._resetLayout = function() {
2541
+ this.getSize();
2542
+ this._getMeasurement( 'columnWidth', 'outerWidth' );
2543
+ this._getMeasurement( 'gutter', 'outerWidth' );
2544
+ this.measureColumns();
2545
+
2546
+ // reset column Y
2547
+ this.colYs = [];
2548
+ for ( var i=0; i < this.cols; i++ ) {
2549
+ this.colYs.push( 0 );
2550
+ }
2551
 
2552
+ this.maxY = 0;
2553
+ };
 
 
 
 
 
 
 
 
 
 
 
 
2554
 
2555
+ Masonry.prototype.measureColumns = function() {
2556
+ this.getContainerWidth();
2557
+ // if columnWidth is 0, default to outerWidth of first item
2558
+ if ( !this.columnWidth ) {
2559
+ var firstItem = this.items[0];
2560
+ var firstItemElem = firstItem && firstItem.element;
2561
+ // columnWidth fall back to item of first element
2562
+ this.columnWidth = firstItemElem && getSize( firstItemElem ).outerWidth ||
2563
+ // if first elem has no width, default to size of container
2564
+ this.containerWidth;
2565
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2566
 
2567
+ var columnWidth = this.columnWidth += this.gutter;
2568
+
2569
+ // calculate columns
2570
+ var containerWidth = this.containerWidth + this.gutter;
2571
+ var cols = containerWidth / columnWidth;
2572
+ // fix rounding errors, typically with gutters
2573
+ var excess = columnWidth - containerWidth % columnWidth;
2574
+ // if overshoot is less than a pixel, round up, otherwise floor it
2575
+ var mathMethod = excess && excess < 1 ? 'round' : 'floor';
2576
+ cols = Math[ mathMethod ]( cols );
2577
+ this.cols = Math.max( cols, 1 );
2578
+ };
2579
 
2580
+ Masonry.prototype.getContainerWidth = function() {
2581
+ // container is parent if fit width
2582
+ var isFitWidth = this._getOption('fitWidth');
2583
+ var container = isFitWidth ? this.element.parentNode : this.element;
2584
+ // check that this.size and size are there
2585
+ // IE8 triggers resize on body size change, so they might not be
2586
+ var size = getSize( container );
2587
+ this.containerWidth = size && size.innerWidth;
2588
+ };
2589
+
2590
+ Masonry.prototype._getItemLayoutPosition = function( item ) {
2591
+ item.getSize();
2592
+ // how many columns does this brick span
2593
+ var remainder = item.size.outerWidth % this.columnWidth;
2594
+ var mathMethod = remainder && remainder < 1 ? 'round' : 'ceil';
2595
+ // round if off by 1 pixel, otherwise use ceil
2596
+ var colSpan = Math[ mathMethod ]( item.size.outerWidth / this.columnWidth );
2597
+ colSpan = Math.min( colSpan, this.cols );
2598
+
2599
+ var colGroup = this._getColGroup( colSpan );
2600
+ // get the minimum Y value from the columns
2601
+ var minimumY = Math.min.apply( Math, colGroup );
2602
+ var shortColIndex = colGroup.indexOf( minimumY );
2603
+
2604
+ // position the brick
2605
+ var position = {
2606
+ x: this.columnWidth * shortColIndex,
2607
+ y: minimumY
2608
+ };
2609
+
2610
+ // apply setHeight to necessary columns
2611
+ var setHeight = minimumY + item.size.outerHeight;
2612
+ var setSpan = this.cols + 1 - colGroup.length;
2613
+ for ( var i = 0; i < setSpan; i++ ) {
2614
+ this.colYs[ shortColIndex + i ] = setHeight;
2615
+ }
2616
 
2617
+ return position;
 
 
 
2618
  };
2619
 
2620
+ /**
2621
+ * @param {Number} colSpan - number of columns the element spans
2622
+ * @returns {Array} colGroup
2623
+ */
2624
+ Masonry.prototype._getColGroup = function( colSpan ) {
2625
+ if ( colSpan < 2 ) {
2626
+ // if brick spans only one column, use all the column Ys
2627
+ return this.colYs;
2628
+ }
2629
 
2630
+ var colGroup = [];
2631
+ // how many different places could this brick fit horizontally
2632
+ var groupCount = this.cols + 1 - colSpan;
2633
+ // for each group potential horizontal position
2634
+ for ( var i = 0; i < groupCount; i++ ) {
2635
+ // make an array of colY values for that one group
2636
+ var groupColYs = this.colYs.slice( i, i + colSpan );
2637
+ // and get the max value of the array
2638
+ colGroup[i] = Math.max.apply( Math, groupColYs );
2639
+ }
2640
+ return colGroup;
2641
+ };
 
 
 
 
2642
 
2643
+ Masonry.prototype._manageStamp = function( stamp ) {
2644
+ var stampSize = getSize( stamp );
2645
+ var offset = this._getElementOffset( stamp );
2646
+ // get the columns that this stamp affects
2647
+ var isOriginLeft = this._getOption('originLeft');
2648
+ var firstX = isOriginLeft ? offset.left : offset.right;
2649
+ var lastX = firstX + stampSize.outerWidth;
2650
+ var firstCol = Math.floor( firstX / this.columnWidth );
2651
+ firstCol = Math.max( 0, firstCol );
2652
+ var lastCol = Math.floor( lastX / this.columnWidth );
2653
+ // lastCol should not go over if multiple of columnWidth #425
2654
+ lastCol -= lastX % this.columnWidth ? 0 : 1;
2655
+ lastCol = Math.min( this.cols - 1, lastCol );
2656
+ // set colYs to bottom of the stamp
2657
+
2658
+ var isOriginTop = this._getOption('originTop');
2659
+ var stampMaxY = ( isOriginTop ? offset.top : offset.bottom ) +
2660
+ stampSize.outerHeight;
2661
+ for ( var i = firstCol; i <= lastCol; i++ ) {
2662
+ this.colYs[i] = Math.max( stampMaxY, this.colYs[i] );
2663
+ }
2664
+ };
2665
+
2666
+ Masonry.prototype._getContainerSize = function() {
2667
+ this.maxY = Math.max.apply( Math, this.colYs );
2668
+ var size = {
2669
+ height: this.maxY
2670
+ };
2671
 
2672
+ if ( this._getOption('fitWidth') ) {
2673
+ size.width = this._getContainerFitWidth();
2674
+ }
2675
+
2676
+ return size;
2677
+ };
2678
+
2679
+ Masonry.prototype._getContainerFitWidth = function() {
2680
+ var unusedCols = 0;
2681
+ // count unused columns
2682
+ var i = this.cols;
2683
+ while ( --i ) {
2684
+ if ( this.colYs[i] !== 0 ) {
2685
+ break;
2686
+ }
2687
+ unusedCols++;
2688
+ }
2689
+ // fit container to columns that have been used
2690
+ return ( this.cols - unusedCols ) * this.columnWidth - this.gutter;
2691
+ };
2692
+
2693
+ Masonry.prototype.needsResizeLayout = function() {
2694
+ var previousWidth = this.containerWidth;
2695
+ this.getContainerWidth();
2696
+ return previousWidth != this.containerWidth;
2697
+ };
2698
+
2699
+ return Masonry;
2700
 
2701
  }));
2702
 
2707
  */
2708
 
2709
  ( function( window, factory ) {
2710
+ // universal module definition
2711
+ /* jshint strict: false */ /*globals define, module, require */
2712
+ if ( typeof define == 'function' && define.amd ) {
2713
+ // AMD
2714
+ define( 'isotope/js/layout-modes/masonry',[
2715
+ '../layout-mode',
2716
+ 'masonry/masonry'
2717
+ ],
2718
+ factory );
2719
+ } else if ( typeof module == 'object' && module.exports ) {
2720
+ // CommonJS
2721
+ module.exports = factory(
2722
+ require('../layout-mode'),
2723
+ require('masonry-layout')
2724
+ );
2725
+ } else {
2726
+ // browser global
2727
+ factory(
2728
+ window.Isotope.LayoutMode,
2729
+ window.Masonry
2730
+ );
2731
+ }
2732
 
2733
  }( window, function factory( LayoutMode, Masonry ) {
2734
+ 'use strict';
2735
 
2736
  // -------------------------- masonryDefinition -------------------------- //
2737
 
2738
+ // create an Outlayer layout class
2739
+ var MasonryMode = LayoutMode.create('masonry');
2740
 
2741
+ var proto = MasonryMode.prototype;
2742
 
2743
+ var keepModeMethods = {
2744
+ _getElementOffset: true,
2745
+ layout: true,
2746
+ _getMeasurement: true
2747
+ };
2748
 
2749
+ // inherit Masonry prototype
2750
+ for ( var method in Masonry.prototype ) {
2751
+ // do not inherit mode methods
2752
+ if ( !keepModeMethods[ method ] ) {
2753
+ proto[ method ] = Masonry.prototype[ method ];
2754
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2755
  }
 
 
2756
 
2757
+ var measureColumns = proto.measureColumns;
2758
+ proto.measureColumns = function() {
2759
+ // set items, used if measuring first item
2760
+ this.items = this.isotope.filteredItems;
2761
+ measureColumns.call( this );
2762
+ };
2763
+
2764
+ // point to mode options for fitWidth
2765
+ var _getOption = proto._getOption;
2766
+ proto._getOption = function( option ) {
2767
+ if ( option == 'fitWidth' ) {
2768
+ return this.options.isFitWidth !== undefined ?
2769
+ this.options.isFitWidth : this.options.fitWidth;
2770
+ }
2771
+ return _getOption.apply( this.isotope, arguments );
2772
+ };
2773
+
2774
+ return MasonryMode;
2775
 
2776
  }));
2777
 
2780
  */
2781
 
2782
  ( function( window, factory ) {
2783
+ // universal module definition
2784
+ /* jshint strict: false */ /*globals define, module, require */
2785
+ if ( typeof define == 'function' && define.amd ) {
2786
+ // AMD
2787
+ define( 'isotope/js/layout-modes/fit-rows',[
2788
+ '../layout-mode'
2789
+ ],
2790
+ factory );
2791
+ } else if ( typeof exports == 'object' ) {
2792
+ // CommonJS
2793
+ module.exports = factory(
2794
+ require('../layout-mode')
2795
+ );
2796
+ } else {
2797
+ // browser global
2798
+ factory(
2799
+ window.Isotope.LayoutMode
2800
+ );
2801
+ }
2802
 
2803
  }( window, function factory( LayoutMode ) {
2804
+ 'use strict';
2805
 
2806
+ var FitRows = LayoutMode.create('fitRows');
2807
 
2808
+ var proto = FitRows.prototype;
2809
 
2810
+ proto._resetLayout = function() {
2811
+ this.x = 0;
2812
+ this.y = 0;
2813
+ this.maxY = 0;
2814
+ this._getMeasurement( 'gutter', 'outerWidth' );
2815
+ };
2816
 
2817
+ proto._getItemLayoutPosition = function( item ) {
2818
+ item.getSize();
2819
 
2820
+ var itemWidth = item.size.outerWidth + this.gutter;
2821
+ // if this element cannot fit in the current row
2822
+ var containerWidth = this.isotope.size.innerWidth + this.gutter;
2823
+ if ( this.x !== 0 && itemWidth + this.x > containerWidth ) {
2824
+ this.x = 0;
2825
+ this.y = this.maxY;
2826
+ }
2827
 
2828
+ var position = {
2829
+ x: this.x,
2830
+ y: this.y
2831
+ };
2832
 
2833
+ this.maxY = Math.max( this.maxY, this.y + item.size.outerHeight );
2834
+ this.x += itemWidth;
2835
 
2836
+ return position;
2837
+ };
2838
 
2839
+ proto._getContainerSize = function() {
2840
+ return { height: this.maxY };
2841
+ };
2842
 
2843
+ return FitRows;
2844
 
2845
  }));
2846
 
2849
  */
2850
 
2851
  ( function( window, factory ) {
2852
+ // universal module definition
2853
+ /* jshint strict: false */ /*globals define, module, require */
2854
+ if ( typeof define == 'function' && define.amd ) {
2855
+ // AMD
2856
+ define( 'isotope/js/layout-modes/vertical',[
2857
+ '../layout-mode'
2858
+ ],
2859
+ factory );
2860
+ } else if ( typeof module == 'object' && module.exports ) {
2861
+ // CommonJS
2862
+ module.exports = factory(
2863
+ require('../layout-mode')
2864
+ );
2865
+ } else {
2866
+ // browser global
2867
+ factory(
2868
+ window.Isotope.LayoutMode
2869
+ );
2870
+ }
2871
 
2872
  }( window, function factory( LayoutMode ) {
2873
+ 'use strict';
2874
 
2875
+ var Vertical = LayoutMode.create( 'vertical', {
2876
+ horizontalAlignment: 0
2877
+ });
2878
 
2879
+ var proto = Vertical.prototype;
2880
 
2881
+ proto._resetLayout = function() {
2882
+ this.y = 0;
2883
+ };
2884
 
2885
+ proto._getItemLayoutPosition = function( item ) {
2886
+ item.getSize();
2887
+ var x = ( this.isotope.size.innerWidth - item.size.outerWidth ) *
2888
+ this.options.horizontalAlignment;
2889
+ var y = this.y;
2890
+ this.y += item.size.outerHeight;
2891
+ return { x: x, y: y };
2892
+ };
2893
 
2894
+ proto._getContainerSize = function() {
2895
+ return { height: this.y };
2896
+ };
2897
 
2898
+ return Vertical;
2899
 
2900
  }));
2901
 
2910
  */
2911
 
2912
  ( function( window, factory ) {
2913
+ // universal module definition
2914
+ /* jshint strict: false */ /*globals define, module, require */
2915
+ if ( typeof define == 'function' && define.amd ) {
2916
+ // AMD
2917
+ define( [
2918
+ 'outlayer/outlayer',
2919
+ 'get-size/get-size',
2920
+ 'desandro-matches-selector/matches-selector',
2921
+ 'fizzy-ui-utils/utils',
2922
+ 'isotope/js/item',
2923
+ 'isotope/js/layout-mode',
2924
+ // include default layout modes
2925
+ 'isotope/js/layout-modes/masonry',
2926
+ 'isotope/js/layout-modes/fit-rows',
2927
+ 'isotope/js/layout-modes/vertical'
2928
+ ],
2929
+ function( Outlayer, getSize, matchesSelector, utils, Item, LayoutMode ) {
2930
+ return factory( window, Outlayer, getSize, matchesSelector, utils, Item, LayoutMode );
2931
+ });
2932
+ } else if ( typeof module == 'object' && module.exports ) {
2933
+ // CommonJS
2934
+ module.exports = factory(
2935
+ window,
2936
+ require('outlayer'),
2937
+ require('get-size'),
2938
+ require('desandro-matches-selector'),
2939
+ require('fizzy-ui-utils'),
2940
+ require('isotope/js/item'),
2941
+ require('isotope/js/layout-mode'),
2942
+ // include default layout modes
2943
+ require('isotope/js/layout-modes/masonry'),
2944
+ require('isotope/js/layout-modes/fit-rows'),
2945
+ require('isotope/js/layout-modes/vertical')
2946
+ );
2947
+ } else {
2948
+ // browser global
2949
+ window.Isotope = factory(
2950
+ window,
2951
+ window.Outlayer,
2952
+ window.getSize,
2953
+ window.matchesSelector,
2954
+ window.fizzyUIUtils,
2955
+ window.Isotope.Item,
2956
+ window.Isotope.LayoutMode
2957
+ );
2958
+ }
2959
 
2960
  }( window, function factory( window, Outlayer, getSize, matchesSelector, utils,
2961
+ Item, LayoutMode ) {
2962
 
2963
 
2964
 
2965
  // -------------------------- vars -------------------------- //
2966
 
2967
+ var jQuery = window.jQuery;
2968
 
2969
  // -------------------------- helpers -------------------------- //
2970
 
2971
+ var trim = String.prototype.trim ?
2972
+ function( str ) {
2973
+ return str.trim();
2974
+ } :
2975
+ function( str ) {
2976
+ return str.replace( /^\s+|\s+$/g, '' );
2977
+ };
2978
 
2979
  // -------------------------- isotopeDefinition -------------------------- //
2980
 
2981
+ // create an Outlayer layout class
2982
+ var Isotope = Outlayer.create( 'isotope', {
2983
+ layoutMode: 'masonry',
2984
+ isJQueryFiltering: true,
2985
+ sortAscending: true
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2986
  });
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2987
 
2988
+ Isotope.Item = Item;
2989
+ Isotope.LayoutMode = LayoutMode;
2990
+
2991
+ var proto = Isotope.prototype;
2992
+
2993
+ proto._create = function() {
2994
+ this.itemGUID = 0;
2995
+ // functions that sort items
2996
+ this._sorters = {};
2997
+ this._getSorters();
2998
+ // call super
2999
+ Outlayer.prototype._create.call( this );
3000
+
3001
+ // create layout modes
3002
+ this.modes = {};
3003
+ // start filteredItems with all items
3004
+ this.filteredItems = this.items;
3005
+ // keep of track of sortBys
3006
+ this.sortHistory = [ 'original-order' ];
3007
+ // create from registered layout modes
3008
+ for ( var name in LayoutMode.modes ) {
3009
+ this._initLayoutMode( name );
3010
+ }
3011
+ };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3012
 
3013
+ proto.reloadItems = function() {
3014
+ // reset item ID counter
3015
+ this.itemGUID = 0;
3016
+ // call super
3017
+ Outlayer.prototype.reloadItems.call( this );
3018
+ };
3019
+
3020
+ proto._itemize = function() {
3021
+ var items = Outlayer.prototype._itemize.apply( this, arguments );
3022
+ // assign ID for original-order
3023
+ for ( var i=0; i < items.length; i++ ) {
3024
+ var item = items[i];
3025
+ item.id = this.itemGUID++;
3026
+ }
3027
+ this._updateItemsSortData( items );
3028
+ return items;
3029
+ };
3030
+
3031
+
3032
+ // -------------------------- layout -------------------------- //
3033
+
3034
+ proto._initLayoutMode = function( name ) {
3035
+ var Mode = LayoutMode.modes[ name ];
3036
+ // set mode options
3037
+ // HACK extend initial options, back-fill in default options
3038
+ var initialOpts = this.options[ name ] || {};
3039
+ this.options[ name ] = Mode.options ?
3040
+ utils.extend( Mode.options, initialOpts ) : initialOpts;
3041
+ // init layout mode instance
3042
+ this.modes[ name ] = new Mode( this );
3043
+ };
3044
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3045
 
3046
+ proto.layout = function() {
3047
+ // if first time doing layout, do all magic
3048
+ if ( !this._isLayoutInited && this._getOption('initLayout') ) {
3049
+ this.arrange();
3050
+ return;
3051
+ }
3052
+ this._layout();
3053
+ };
3054
+
3055
+ // private method to be used in layout() & magic()
3056
+ proto._layout = function() {
3057
+ // don't animate first layout
3058
+ var isInstant = this._getIsInstant();
3059
+ // layout flow
3060
+ this._resetLayout();
3061
+ this._manageStamps();
3062
+ this.layoutItems( this.filteredItems, isInstant );
3063
+
3064
+ // flag for initalized
3065
+ this._isLayoutInited = true;
3066
+ };
3067
+
3068
+ // filter + sort + layout
3069
+ proto.arrange = function( opts ) {
3070
+ // set any options pass
3071
+ this.option( opts );
3072
+ this._getIsInstant();
3073
+ // filter, sort, and layout
3074
+
3075
+ // filter
3076
+ var filtered = this._filter( this.items );
3077
+ this.filteredItems = filtered.matches;
3078
+
3079
+ this._bindArrangeComplete();
3080
+
3081
+ if ( this._isInstant ) {
3082
+ this._noTransition( this._hideReveal, [ filtered ] );
3083
+ } else {
3084
+ this._hideReveal( filtered );
3085
+ }
3086
+
3087
+ this._sort();
3088
+ this._layout();
3089
+ };
3090
+ // alias to _init for main plugin method
3091
+ proto._init = proto.arrange;
3092
+
3093
+ proto._hideReveal = function( filtered ) {
3094
+ this.reveal( filtered.needReveal );
3095
+ this.hide( filtered.needHide );
3096
+ };
3097
+
3098
+ // HACK
3099
+ // Don't animate/transition first layout
3100
+ // Or don't animate/transition other layouts
3101
+ proto._getIsInstant = function() {
3102
+ var isLayoutInstant = this._getOption('layoutInstant');
3103
+ var isInstant = isLayoutInstant !== undefined ? isLayoutInstant :
3104
+ !this._isLayoutInited;
3105
+ this._isInstant = isInstant;
3106
+ return isInstant;
3107
+ };
3108
+
3109
+ // listen for layoutComplete, hideComplete and revealComplete
3110
+ // to trigger arrangeComplete
3111
+ proto._bindArrangeComplete = function() {
3112
+ // listen for 3 events to trigger arrangeComplete
3113
+ var isLayoutComplete, isHideComplete, isRevealComplete;
3114
+ var _this = this;
3115
+ function arrangeParallelCallback() {
3116
+ if ( isLayoutComplete && isHideComplete && isRevealComplete ) {
3117
+ _this.dispatchEvent( 'arrangeComplete', null, [ _this.filteredItems ] );
3118
+ }
3119
+ }
3120
+ this.once( 'layoutComplete', function() {
3121
+ isLayoutComplete = true;
3122
+ arrangeParallelCallback();
3123
+ });
3124
+ this.once( 'hideComplete', function() {
3125
+ isHideComplete = true;
3126
+ arrangeParallelCallback();
3127
+ });
3128
+ this.once( 'revealComplete', function() {
3129
+ isRevealComplete = true;
3130
+ arrangeParallelCallback();
3131
+ });
3132
+ };
3133
+
3134
+ // -------------------------- filter -------------------------- //
3135
+
3136
+ proto._filter = function( items ) {
3137
+ var filter = this.options.filter;
3138
+ filter = filter || '*';
3139
+ var matches = [];
3140
+ var hiddenMatched = [];
3141
+ var visibleUnmatched = [];
3142
+
3143
+ var test = this._getFilterTest( filter );
3144
+
3145
+ // test each item
3146
+ for ( var i=0; i < items.length; i++ ) {
3147
+ var item = items[i];
3148
+ if ( item.isIgnored ) {
3149
+ continue;
3150
+ }
3151
+ // add item to either matched or unmatched group
3152
+ var isMatched = test( item );
3153
+ // item.isFilterMatched = isMatched;
3154
+ // add to matches if its a match
3155
+ if ( isMatched ) {
3156
+ matches.push( item );
3157
+ }
3158
+ // add to additional group if item needs to be hidden or revealed
3159
+ if ( isMatched && item.isHidden ) {
3160
+ hiddenMatched.push( item );
3161
+ } else if ( !isMatched && !item.isHidden ) {
3162
+ visibleUnmatched.push( item );
3163
+ }
3164
+ }
3165
+
3166
+ // return collections of items to be manipulated
3167
+ return {
3168
+ matches: matches,
3169
+ needReveal: hiddenMatched,
3170
+ needHide: visibleUnmatched
3171
  };
3172
+ };
3173
 
3174
+ // get a jQuery, function, or a matchesSelector test given the filter
3175
+ proto._getFilterTest = function( filter ) {
3176
+ if ( jQuery && this.options.isJQueryFiltering ) {
3177
+ // use jQuery
3178
+ return function( item ) {
3179
+ return jQuery( item.element ).is( filter );
3180
+ };
3181
+ }
3182
+ if ( typeof filter == 'function' ) {
3183
+ // use filter as function
3184
+ return function( item ) {
3185
+ return filter( item.element );
3186
+ };
3187
+ }
3188
+ // default, use filter as selector string
3189
+ return function( item ) {
3190
+ return matchesSelector( item.element, filter );
3191
+ };
3192
+ };
3193
 
3194
+ // -------------------------- sorting -------------------------- //
3195
+
3196
+ /**
3197
+ * @params {Array} elems
3198
+ * @public
3199
+ */
3200
+ proto.updateSortData = function( elems ) {
3201
+ // get items
3202
+ var items;
3203
+ if ( elems ) {
3204
+ elems = utils.makeArray( elems );
3205
+ items = this.getItems( elems );
3206
+ } else {
3207
+ // update all items if no elems provided
3208
+ items = this.items;
3209
+ }
3210
 
3211
+ this._getSorters();
3212
+ this._updateItemsSortData( items );
3213
+ };
 
 
 
 
 
 
3214
 
3215
+ proto._getSorters = function() {
3216
+ var getSortData = this.options.getSortData;
3217
+ for ( var key in getSortData ) {
3218
+ var sorter = getSortData[ key ];
3219
+ this._sorters[ key ] = mungeSorter( sorter );
3220
+ }
3221
+ };
3222
 
3223
+ /**
3224
+ * @params {Array} items - of Isotope.Items
3225
+ * @private
3226
+ */
3227
+ proto._updateItemsSortData = function( items ) {
3228
+ // do not update if no items
3229
+ var len = items && items.length;
3230
+
3231
+ for ( var i=0; len && i < len; i++ ) {
3232
+ var item = items[i];
3233
+ item.updateSortData();
3234
+ }
3235
+ };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3236
 
3237
+ // ----- munge sorter ----- //
3238
+
3239
+ // encapsulate this, as we just need mungeSorter
3240
+ // other functions in here are just for munging
3241
+ var mungeSorter = ( function() {
3242
+ // add a magic layer to sorters for convienent shorthands
3243
+ // `.foo-bar` will use the text of .foo-bar querySelector
3244
+ // `[foo-bar]` will use attribute
3245
+ // you can also add parser
3246
+ // `.foo-bar parseInt` will parse that as a number
3247
+ function mungeSorter( sorter ) {
3248
+ // if not a string, return function or whatever it is
3249
+ if ( typeof sorter != 'string' ) {
3250
+ return sorter;
3251
+ }
3252
+ // parse the sorter string
3253
+ var args = trim( sorter ).split(' ');
3254
+ var query = args[0];
3255
+ // check if query looks like [an-attribute]
3256
+ var attrMatch = query.match( /^\[(.+)\]$/ );
3257
+ var attr = attrMatch && attrMatch[1];
3258
+ var getValue = getValueGetter( attr, query );
3259
+ // use second argument as a parser
3260
+ var parser = Isotope.sortDataParsers[ args[1] ];
3261
+ // parse the value, if there was a parser
3262
+ sorter = parser ? function( elem ) {
3263
+ return elem && parser( getValue( elem ) );
3264
+ } :
3265
+ // otherwise just return value
3266
+ function( elem ) {
3267
+ return elem && getValue( elem );
3268
+ };
3269
+
3270
+ return sorter;
3271
+ }
3272
+
3273
+ // get an attribute getter, or get text of the querySelector
3274
+ function getValueGetter( attr, query ) {
3275
+ // if query looks like [foo-bar], get attribute
3276
+ if ( attr ) {
3277
+ return function getAttribute( elem ) {
3278
+ return elem.getAttribute( attr );
3279
+ };
3280
+ }
3281
+
3282
+ // otherwise, assume its a querySelector, and get its text
3283
+ return function getChildText( elem ) {
3284
+ var child = elem.querySelector( query );
3285
+ return child && child.textContent;
3286
+ };
3287
+ }
3288
+
3289
+ return mungeSorter;
3290
+ })();
3291
+
3292
+ // parsers used in getSortData shortcut strings
3293
+ Isotope.sortDataParsers = {
3294
+ 'parseInt': function( val ) {
3295
+ return parseInt( val, 10 );
3296
+ },
3297
+ 'parseFloat': function( val ) {
3298
+ return parseFloat( val );
3299
+ }
3300
+ };
3301
+
3302
+ // ----- sort method ----- //
3303
+
3304
+ // sort filteredItem order
3305
+ proto._sort = function() {
3306
+ var sortByOpt = this.options.sortBy;
3307
+ if ( !sortByOpt ) {
3308
+ return;
3309
+ }
3310
+ // concat all sortBy and sortHistory
3311
+ var sortBys = [].concat.apply( sortByOpt, this.sortHistory );
3312
+ // sort magic
3313
+ var itemSorter = getItemSorter( sortBys, this.options.sortAscending );
3314
+ this.filteredItems.sort( itemSorter );
3315
+ // keep track of sortBy History
3316
+ if ( sortByOpt != this.sortHistory[0] ) {
3317
+ // add to front, oldest goes in last
3318
+ this.sortHistory.unshift( sortByOpt );
3319
+ }
3320
+ };
3321
+
3322
+ // returns a function used for sorting
3323
+ function getItemSorter( sortBys, sortAsc ) {
3324
+ return function sorter( itemA, itemB ) {
3325
+ // cycle through all sortKeys
3326
+ for ( var i = 0; i < sortBys.length; i++ ) {
3327
+ var sortBy = sortBys[i];
3328
+ var a = itemA.sortData[ sortBy ];
3329
+ var b = itemB.sortData[ sortBy ];
3330
+ if ( a > b || a < b ) {
3331
+ // if sortAsc is an object, use the value given the sortBy key
3332
+ var isAscending = sortAsc[ sortBy ] !== undefined ? sortAsc[ sortBy ] : sortAsc;
3333
+ var direction = isAscending ? 1 : -1;
3334
+ return ( a > b ? 1 : -1 ) * direction;
3335
+ }
3336
+ }
3337
+ return 0;
3338
+ };
3339
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3340
 
3341
+ // -------------------------- methods -------------------------- //
3342
+
3343
+ // get layout mode
3344
+ proto._mode = function() {
3345
+ var layoutMode = this.options.layoutMode;
3346
+ var mode = this.modes[ layoutMode ];
3347
+ if ( !mode ) {
3348
+ // TODO console.error
3349
+ throw new Error( 'No layout mode: ' + layoutMode );
3350
+ }
3351
+ // HACK sync mode's options
3352
+ // any options set after init for layout mode need to be synced
3353
+ mode.options = this.options[ layoutMode ];
3354
+ return mode;
3355
+ };
3356
+
3357
+ proto._resetLayout = function() {
3358
+ // trigger original reset layout
3359
+ Outlayer.prototype._resetLayout.call( this );
3360
+ this._mode()._resetLayout();
3361
+ };
3362
+
3363
+ proto._getItemLayoutPosition = function( item ) {
3364
+ return this._mode()._getItemLayoutPosition( item );
3365
+ };
3366
+
3367
+ proto._manageStamp = function( stamp ) {
3368
+ this._mode()._manageStamp( stamp );
3369
+ };
3370
+
3371
+ proto._getContainerSize = function() {
3372
+ return this._mode()._getContainerSize();
3373
+ };
3374
+
3375
+ proto.needsResizeLayout = function() {
3376
+ return this._mode().needsResizeLayout();
3377
+ };
3378
+
3379
+ // -------------------------- adding & removing -------------------------- //
3380
+
3381
+ // HEADS UP overwrites default Outlayer appended
3382
+ proto.appended = function( elems ) {
3383
+ var items = this.addItems( elems );
3384
+ if ( !items.length ) {
3385
+ return;
3386
+ }
3387
+ // filter, layout, reveal new items
3388
+ var filteredItems = this._filterRevealAdded( items );
3389
+ // add to filteredItems
3390
+ this.filteredItems = this.filteredItems.concat( filteredItems );
3391
+ };
3392
+
3393
+ // HEADS UP overwrites default Outlayer prepended
3394
+ proto.prepended = function( elems ) {
3395
+ var items = this._itemize( elems );
3396
+ if ( !items.length ) {
3397
+ return;
3398
+ }
3399
+ // start new layout
3400
+ this._resetLayout();
3401
+ this._manageStamps();
3402
+ // filter, layout, reveal new items
3403
+ var filteredItems = this._filterRevealAdded( items );
3404
+ // layout previous items
3405
+ this.layoutItems( this.filteredItems );
3406
+ // add to items and filteredItems
3407
+ this.filteredItems = filteredItems.concat( this.filteredItems );
3408
+ this.items = items.concat( this.items );
3409
+ };
3410
+
3411
+ proto._filterRevealAdded = function( items ) {
3412
+ var filtered = this._filter( items );
3413
+ this.hide( filtered.needHide );
3414
+ // reveal all new items
3415
+ this.reveal( filtered.matches );
3416
+ // layout new items, no transition
3417
+ this.layoutItems( filtered.matches, true );
3418
+ return filtered.matches;
3419
+ };
3420
+
3421
+ /**
3422
+ * Filter, sort, and layout newly-appended item elements
3423
+ * @param {Array or NodeList or Element} elems
3424
+ */
3425
+ proto.insert = function( elems ) {
3426
+ var items = this.addItems( elems );
3427
+ if ( !items.length ) {
3428
+ return;
3429
+ }
3430
+ // append item elements
3431
+ var i, item;
3432
+ var len = items.length;
3433
+ for ( i=0; i < len; i++ ) {
3434
+ item = items[i];
3435
+ this.element.appendChild( item.element );
3436
+ }
3437
+ // filter new stuff
3438
+ var filteredInsertItems = this._filter( items ).matches;
3439
+ // set flag
3440
+ for ( i=0; i < len; i++ ) {
3441
+ items[i].isLayoutInstant = true;
3442
+ }
3443
+ this.arrange();
3444
+ // reset flag
3445
+ for ( i=0; i < len; i++ ) {
3446
+ delete items[i].isLayoutInstant;
3447
+ }
3448
+ this.reveal( filteredInsertItems );
3449
+ };
3450
+
3451
+ var _remove = proto.remove;
3452
+ proto.remove = function( elems ) {
3453
+ elems = utils.makeArray( elems );
3454
+ var removeItems = this.getItems( elems );
3455
+ // do regular thing
3456
+ _remove.call( this, elems );
3457
+ // bail if no items to remove
3458
+ var len = removeItems && removeItems.length;
3459
+ // remove elems from filteredItems
3460
+ for ( var i=0; len && i < len; i++ ) {
3461
+ var item = removeItems[i];
3462
+ // remove item from collection
3463
+ utils.removeFrom( this.filteredItems, item );
3464
+ }
3465
+ };
3466
+
3467
+ proto.shuffle = function() {
3468
+ // update random sortData
3469
+ for ( var i=0; i < this.items.length; i++ ) {
3470
+ var item = this.items[i];
3471
+ item.sortData.random = Math.random();
3472
+ }
3473
+ this.options.sortBy = 'random';
3474
+ this._sort();
3475
+ this._layout();
3476
+ };
3477
+
3478
+ /**
3479
+ * trigger fn without transition
3480
+ * kind of hacky to have this in the first place
3481
+ * @param {Function} fn
3482
+ * @param {Array} args
3483
+ * @returns ret
3484
+ * @private
3485
+ */
3486
+ proto._noTransition = function( fn, args ) {
3487
+ // save transitionDuration before disabling
3488
+ var transitionDuration = this.options.transitionDuration;
3489
+ // disable transition
3490
+ this.options.transitionDuration = 0;
3491
+ // do it
3492
+ var returnValue = fn.apply( this, args );
3493
+ // re-enable transition for reveal
3494
+ this.options.transitionDuration = transitionDuration;
3495
+ return returnValue;
3496
+ };
3497
+
3498
+ // ----- helper methods ----- //
3499
+
3500
+ /**
3501
+ * getter method for getting filtered item elements
3502
+ * @returns {Array} elems - collection of item elements
3503
+ */
3504
+ proto.getFilteredItemElements = function() {
3505
+ return this.filteredItems.map( function( item ) {
3506
+ return item.element;
3507
+ });
3508
+ };
3509
+
3510
+ // ----- ----- //
3511
 
3512
+ return Isotope;
3513
 
3514
  }));
3515
 
assets/js/isotope.pkgd.min.js CHANGED
@@ -9,4 +9,4 @@
9
  */
10
 
11
  !function(t,e){"function"==typeof define&&define.amd?define("jquery-bridget/jquery-bridget",["jquery"],function(i){return e(t,i)}):"object"==typeof module&&module.exports?module.exports=e(t,require("jquery")):t.jQueryBridget=e(t,t.jQuery)}(window,function(t,e){"use strict";function i(i,s,a){function u(t,e,n){var o,s="$()."+i+'("'+e+'")';return t.each(function(t,u){var h=a.data(u,i);if(!h)return void r(i+" not initialized. Cannot call methods, i.e. "+s);var d=h[e];if(!d||"_"==e.charAt(0))return void r(s+" is not a valid method");var l=d.apply(h,n);o=void 0===o?l:o}),void 0!==o?o:t}function h(t,e){t.each(function(t,n){var o=a.data(n,i);o?(o.option(e),o._init()):(o=new s(n,e),a.data(n,i,o))})}a=a||e||t.jQuery,a&&(s.prototype.option||(s.prototype.option=function(t){a.isPlainObject(t)&&(this.options=a.extend(!0,this.options,t))}),a.fn[i]=function(t){if("string"==typeof t){var e=o.call(arguments,1);return u(this,t,e)}return h(this,t),this},n(a))}function n(t){!t||t&&t.bridget||(t.bridget=i)}var o=Array.prototype.slice,s=t.console,r="undefined"==typeof s?function(){}:function(t){s.error(t)};return n(e||t.jQuery),i}),function(t,e){"function"==typeof define&&define.amd?define("ev-emitter/ev-emitter",e):"object"==typeof module&&module.exports?module.exports=e():t.EvEmitter=e()}("undefined"!=typeof window?window:this,function(){function t(){}var e=t.prototype;return e.on=function(t,e){if(t&&e){var i=this._events=this._events||{},n=i[t]=i[t]||[];return n.indexOf(e)==-1&&n.push(e),this}},e.once=function(t,e){if(t&&e){this.on(t,e);var i=this._onceEvents=this._onceEvents||{},n=i[t]=i[t]||{};return n[e]=!0,this}},e.off=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){var n=i.indexOf(e);return n!=-1&&i.splice(n,1),this}},e.emitEvent=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){var n=0,o=i[n];e=e||[];for(var s=this._onceEvents&&this._onceEvents[t];o;){var r=s&&s[o];r&&(this.off(t,o),delete s[o]),o.apply(this,e),n+=r?0:1,o=i[n]}return this}},t}),function(t,e){"use strict";"function"==typeof define&&define.amd?define("get-size/get-size",[],function(){return e()}):"object"==typeof module&&module.exports?module.exports=e():t.getSize=e()}(window,function(){"use strict";function t(t){var e=parseFloat(t),i=t.indexOf("%")==-1&&!isNaN(e);return i&&e}function e(){}function i(){for(var t={width:0,height:0,innerWidth:0,innerHeight:0,outerWidth:0,outerHeight:0},e=0;e<h;e++){var i=u[e];t[i]=0}return t}function n(t){var e=getComputedStyle(t);return e||a("Style returned "+e+". Are you running this code in a hidden iframe on Firefox? See http://bit.ly/getsizebug1"),e}function o(){if(!d){d=!0;var e=document.createElement("div");e.style.width="200px",e.style.padding="1px 2px 3px 4px",e.style.borderStyle="solid",e.style.borderWidth="1px 2px 3px 4px",e.style.boxSizing="border-box";var i=document.body||document.documentElement;i.appendChild(e);var o=n(e);s.isBoxSizeOuter=r=200==t(o.width),i.removeChild(e)}}function s(e){if(o(),"string"==typeof e&&(e=document.querySelector(e)),e&&"object"==typeof e&&e.nodeType){var s=n(e);if("none"==s.display)return i();var a={};a.width=e.offsetWidth,a.height=e.offsetHeight;for(var d=a.isBorderBox="border-box"==s.boxSizing,l=0;l<h;l++){var f=u[l],c=s[f],m=parseFloat(c);a[f]=isNaN(m)?0:m}var p=a.paddingLeft+a.paddingRight,y=a.paddingTop+a.paddingBottom,g=a.marginLeft+a.marginRight,v=a.marginTop+a.marginBottom,_=a.borderLeftWidth+a.borderRightWidth,I=a.borderTopWidth+a.borderBottomWidth,z=d&&r,x=t(s.width);x!==!1&&(a.width=x+(z?0:p+_));var S=t(s.height);return S!==!1&&(a.height=S+(z?0:y+I)),a.innerWidth=a.width-(p+_),a.innerHeight=a.height-(y+I),a.outerWidth=a.width+g,a.outerHeight=a.height+v,a}}var r,a="undefined"==typeof console?e:function(t){console.error(t)},u=["paddingLeft","paddingRight","paddingTop","paddingBottom","marginLeft","marginRight","marginTop","marginBottom","borderLeftWidth","borderRightWidth","borderTopWidth","borderBottomWidth"],h=u.length,d=!1;return s}),function(t,e){"use strict";"function"==typeof define&&define.amd?define("desandro-matches-selector/matches-selector",e):"object"==typeof module&&module.exports?module.exports=e():t.matchesSelector=e()}(window,function(){"use strict";var t=function(){var t=Element.prototype;if(t.matches)return"matches";if(t.matchesSelector)return"matchesSelector";for(var e=["webkit","moz","ms","o"],i=0;i<e.length;i++){var n=e[i],o=n+"MatchesSelector";if(t[o])return o}}();return function(e,i){return e[t](i)}}),function(t,e){"function"==typeof define&&define.amd?define("fizzy-ui-utils/utils",["desandro-matches-selector/matches-selector"],function(i){return e(t,i)}):"object"==typeof module&&module.exports?module.exports=e(t,require("desandro-matches-selector")):t.fizzyUIUtils=e(t,t.matchesSelector)}(window,function(t,e){var i={};i.extend=function(t,e){for(var i in e)t[i]=e[i];return t},i.modulo=function(t,e){return(t%e+e)%e},i.makeArray=function(t){var e=[];if(Array.isArray(t))e=t;else if(t&&"number"==typeof t.length)for(var i=0;i<t.length;i++)e.push(t[i]);else e.push(t);return e},i.removeFrom=function(t,e){var i=t.indexOf(e);i!=-1&&t.splice(i,1)},i.getParent=function(t,i){for(;t!=document.body;)if(t=t.parentNode,e(t,i))return t},i.getQueryElement=function(t){return"string"==typeof t?document.querySelector(t):t},i.handleEvent=function(t){var e="on"+t.type;this[e]&&this[e](t)},i.filterFindElements=function(t,n){t=i.makeArray(t);var o=[];return t.forEach(function(t){if(t instanceof HTMLElement){if(!n)return void o.push(t);e(t,n)&&o.push(t);for(var i=t.querySelectorAll(n),s=0;s<i.length;s++)o.push(i[s])}}),o},i.debounceMethod=function(t,e,i){var n=t.prototype[e],o=e+"Timeout";t.prototype[e]=function(){var t=this[o];t&&clearTimeout(t);var e=arguments,s=this;this[o]=setTimeout(function(){n.apply(s,e),delete s[o]},i||100)}},i.docReady=function(t){var e=document.readyState;"complete"==e||"interactive"==e?setTimeout(t):document.addEventListener("DOMContentLoaded",t)},i.toDashed=function(t){return t.replace(/(.)([A-Z])/g,function(t,e,i){return e+"-"+i}).toLowerCase()};var n=t.console;return i.htmlInit=function(e,o){i.docReady(function(){var s=i.toDashed(o),r="data-"+s,a=document.querySelectorAll("["+r+"]"),u=document.querySelectorAll(".js-"+s),h=i.makeArray(a).concat(i.makeArray(u)),d=r+"-options",l=t.jQuery;h.forEach(function(t){var i,s=t.getAttribute(r)||t.getAttribute(d);try{i=s&&JSON.parse(s)}catch(a){return void(n&&n.error("Error parsing "+r+" on "+t.className+": "+a))}var u=new e(t,i);l&&l.data(t,o,u)})})},i}),function(t,e){"function"==typeof define&&define.amd?define("outlayer/item",["ev-emitter/ev-emitter","get-size/get-size"],e):"object"==typeof module&&module.exports?module.exports=e(require("ev-emitter"),require("get-size")):(t.Outlayer={},t.Outlayer.Item=e(t.EvEmitter,t.getSize))}(window,function(t,e){"use strict";function i(t){for(var e in t)return!1;return e=null,!0}function n(t,e){t&&(this.element=t,this.layout=e,this.position={x:0,y:0},this._create())}function o(t){return t.replace(/([A-Z])/g,function(t){return"-"+t.toLowerCase()})}var s=document.documentElement.style,r="string"==typeof s.transition?"transition":"WebkitTransition",a="string"==typeof s.transform?"transform":"WebkitTransform",u={WebkitTransition:"webkitTransitionEnd",transition:"transitionend"}[r],h={transform:a,transition:r,transitionDuration:r+"Duration",transitionProperty:r+"Property",transitionDelay:r+"Delay"},d=n.prototype=Object.create(t.prototype);d.constructor=n,d._create=function(){this._transn={ingProperties:{},clean:{},onEnd:{}},this.css({position:"absolute"})},d.handleEvent=function(t){var e="on"+t.type;this[e]&&this[e](t)},d.getSize=function(){this.size=e(this.element)},d.css=function(t){var e=this.element.style;for(var i in t){var n=h[i]||i;e[n]=t[i]}},d.getPosition=function(){var t=getComputedStyle(this.element),e=this.layout._getOption("originLeft"),i=this.layout._getOption("originTop"),n=t[e?"left":"right"],o=t[i?"top":"bottom"],s=this.layout.size,r=n.indexOf("%")!=-1?parseFloat(n)/100*s.width:parseInt(n,10),a=o.indexOf("%")!=-1?parseFloat(o)/100*s.height:parseInt(o,10);r=isNaN(r)?0:r,a=isNaN(a)?0:a,r-=e?s.paddingLeft:s.paddingRight,a-=i?s.paddingTop:s.paddingBottom,this.position.x=r,this.position.y=a},d.layoutPosition=function(){var t=this.layout.size,e={},i=this.layout._getOption("originLeft"),n=this.layout._getOption("originTop"),o=i?"paddingLeft":"paddingRight",s=i?"left":"right",r=i?"right":"left",a=this.position.x+t[o];e[s]=this.getXValue(a),e[r]="";var u=n?"paddingTop":"paddingBottom",h=n?"top":"bottom",d=n?"bottom":"top",l=this.position.y+t[u];e[h]=this.getYValue(l),e[d]="",this.css(e),this.emitEvent("layout",[this])},d.getXValue=function(t){var e=this.layout._getOption("horizontal");return this.layout.options.percentPosition&&!e?t/this.layout.size.width*100+"%":t+"px"},d.getYValue=function(t){var e=this.layout._getOption("horizontal");return this.layout.options.percentPosition&&e?t/this.layout.size.height*100+"%":t+"px"},d._transitionTo=function(t,e){this.getPosition();var i=this.position.x,n=this.position.y,o=parseInt(t,10),s=parseInt(e,10),r=o===this.position.x&&s===this.position.y;if(this.setPosition(t,e),r&&!this.isTransitioning)return void this.layoutPosition();var a=t-i,u=e-n,h={};h.transform=this.getTranslate(a,u),this.transition({to:h,onTransitionEnd:{transform:this.layoutPosition},isCleaning:!0})},d.getTranslate=function(t,e){var i=this.layout._getOption("originLeft"),n=this.layout._getOption("originTop");return t=i?t:-t,e=n?e:-e,"translate3d("+t+"px, "+e+"px, 0)"},d.goTo=function(t,e){this.setPosition(t,e),this.layoutPosition()},d.moveTo=d._transitionTo,d.setPosition=function(t,e){this.position.x=parseInt(t,10),this.position.y=parseInt(e,10)},d._nonTransition=function(t){this.css(t.to),t.isCleaning&&this._removeStyles(t.to);for(var e in t.onTransitionEnd)t.onTransitionEnd[e].call(this)},d.transition=function(t){if(!parseFloat(this.layout.options.transitionDuration))return void this._nonTransition(t);var e=this._transn;for(var i in t.onTransitionEnd)e.onEnd[i]=t.onTransitionEnd[i];for(i in t.to)e.ingProperties[i]=!0,t.isCleaning&&(e.clean[i]=!0);if(t.from){this.css(t.from);var n=this.element.offsetHeight;n=null}this.enableTransition(t.to),this.css(t.to),this.isTransitioning=!0};var l="opacity,"+o(a);d.enableTransition=function(){if(!this.isTransitioning){var t=this.layout.options.transitionDuration;t="number"==typeof t?t+"ms":t,this.css({transitionProperty:l,transitionDuration:t,transitionDelay:this.staggerDelay||0}),this.element.addEventListener(u,this,!1)}},d.onwebkitTransitionEnd=function(t){this.ontransitionend(t)},d.onotransitionend=function(t){this.ontransitionend(t)};var f={"-webkit-transform":"transform"};d.ontransitionend=function(t){if(t.target===this.element){var e=this._transn,n=f[t.propertyName]||t.propertyName;if(delete e.ingProperties[n],i(e.ingProperties)&&this.disableTransition(),n in e.clean&&(this.element.style[t.propertyName]="",delete e.clean[n]),n in e.onEnd){var o=e.onEnd[n];o.call(this),delete e.onEnd[n]}this.emitEvent("transitionEnd",[this])}},d.disableTransition=function(){this.removeTransitionStyles(),this.element.removeEventListener(u,this,!1),this.isTransitioning=!1},d._removeStyles=function(t){var e={};for(var i in t)e[i]="";this.css(e)};var c={transitionProperty:"",transitionDuration:"",transitionDelay:""};return d.removeTransitionStyles=function(){this.css(c)},d.stagger=function(t){t=isNaN(t)?0:t,this.staggerDelay=t+"ms"},d.removeElem=function(){this.element.parentNode.removeChild(this.element),this.css({display:""}),this.emitEvent("remove",[this])},d.remove=function(){return r&&parseFloat(this.layout.options.transitionDuration)?(this.once("transitionEnd",function(){this.removeElem()}),void this.hide()):void this.removeElem()},d.reveal=function(){delete this.isHidden,this.css({display:""});var t=this.layout.options,e={},i=this.getHideRevealTransitionEndProperty("visibleStyle");e[i]=this.onRevealTransitionEnd,this.transition({from:t.hiddenStyle,to:t.visibleStyle,isCleaning:!0,onTransitionEnd:e})},d.onRevealTransitionEnd=function(){this.isHidden||this.emitEvent("reveal")},d.getHideRevealTransitionEndProperty=function(t){var e=this.layout.options[t];if(e.opacity)return"opacity";for(var i in e)return i},d.hide=function(){this.isHidden=!0,this.css({display:""});var t=this.layout.options,e={},i=this.getHideRevealTransitionEndProperty("hiddenStyle");e[i]=this.onHideTransitionEnd,this.transition({from:t.visibleStyle,to:t.hiddenStyle,isCleaning:!0,onTransitionEnd:e})},d.onHideTransitionEnd=function(){this.isHidden&&(this.css({display:"none"}),this.emitEvent("hide"))},d.destroy=function(){this.css({position:"",left:"",right:"",top:"",bottom:"",transition:"",transform:""})},n}),function(t,e){"use strict";"function"==typeof define&&define.amd?define("outlayer/outlayer",["ev-emitter/ev-emitter","get-size/get-size","fizzy-ui-utils/utils","./item"],function(i,n,o,s){return e(t,i,n,o,s)}):"object"==typeof module&&module.exports?module.exports=e(t,require("ev-emitter"),require("get-size"),require("fizzy-ui-utils"),require("./item")):t.Outlayer=e(t,t.EvEmitter,t.getSize,t.fizzyUIUtils,t.Outlayer.Item)}(window,function(t,e,i,n,o){"use strict";function s(t,e){var i=n.getQueryElement(t);if(!i)return void(u&&u.error("Bad element for "+this.constructor.namespace+": "+(i||t)));this.element=i,h&&(this.$element=h(this.element)),this.options=n.extend({},this.constructor.defaults),this.option(e);var o=++l;this.element.outlayerGUID=o,f[o]=this,this._create();var s=this._getOption("initLayout");s&&this.layout()}function r(t){function e(){t.apply(this,arguments)}return e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e}function a(t){if("number"==typeof t)return t;var e=t.match(/(^\d*\.?\d*)(\w*)/),i=e&&e[1],n=e&&e[2];if(!i.length)return 0;i=parseFloat(i);var o=m[n]||1;return i*o}var u=t.console,h=t.jQuery,d=function(){},l=0,f={};s.namespace="outlayer",s.Item=o,s.defaults={containerStyle:{position:"relative"},initLayout:!0,originLeft:!0,originTop:!0,resize:!0,resizeContainer:!0,transitionDuration:"0.4s",hiddenStyle:{opacity:0,transform:"scale(0.001)"},visibleStyle:{opacity:1,transform:"scale(1)"}};var c=s.prototype;n.extend(c,e.prototype),c.option=function(t){n.extend(this.options,t)},c._getOption=function(t){var e=this.constructor.compatOptions[t];return e&&void 0!==this.options[e]?this.options[e]:this.options[t]},s.compatOptions={initLayout:"isInitLayout",horizontal:"isHorizontal",layoutInstant:"isLayoutInstant",originLeft:"isOriginLeft",originTop:"isOriginTop",resize:"isResizeBound",resizeContainer:"isResizingContainer"},c._create=function(){this.reloadItems(),this.stamps=[],this.stamp(this.options.stamp),n.extend(this.element.style,this.options.containerStyle);var t=this._getOption("resize");t&&this.bindResize()},c.reloadItems=function(){this.items=this._itemize(this.element.children)},c._itemize=function(t){for(var e=this._filterFindItemElements(t),i=this.constructor.Item,n=[],o=0;o<e.length;o++){var s=e[o],r=new i(s,this);n.push(r)}return n},c._filterFindItemElements=function(t){return n.filterFindElements(t,this.options.itemSelector)},c.getItemElements=function(){return this.items.map(function(t){return t.element})},c.layout=function(){this._resetLayout(),this._manageStamps();var t=this._getOption("layoutInstant"),e=void 0!==t?t:!this._isLayoutInited;this.layoutItems(this.items,e),this._isLayoutInited=!0},c._init=c.layout,c._resetLayout=function(){this.getSize()},c.getSize=function(){this.size=i(this.element)},c._getMeasurement=function(t,e){var n,o=this.options[t];o?("string"==typeof o?n=this.element.querySelector(o):o instanceof HTMLElement&&(n=o),this[t]=n?i(n)[e]:o):this[t]=0},c.layoutItems=function(t,e){t=this._getItemsForLayout(t),this._layoutItems(t,e),this._postLayout()},c._getItemsForLayout=function(t){return t.filter(function(t){return!t.isIgnored})},c._layoutItems=function(t,e){if(this._emitCompleteOnItems("layout",t),t&&t.length){var i=[];t.forEach(function(t){var n=this._getItemLayoutPosition(t);n.item=t,n.isInstant=e||t.isLayoutInstant,i.push(n)},this),this._processLayoutQueue(i)}},c._getItemLayoutPosition=function(){return{x:0,y:0}},c._processLayoutQueue=function(t){this.updateStagger(),t.forEach(function(t,e){this._positionItem(t.item,t.x,t.y,t.isInstant,e)},this)},c.updateStagger=function(){var t=this.options.stagger;return null===t||void 0===t?void(this.stagger=0):(this.stagger=a(t),this.stagger)},c._positionItem=function(t,e,i,n,o){n?t.goTo(e,i):(t.stagger(o*this.stagger),t.moveTo(e,i))},c._postLayout=function(){this.resizeContainer()},c.resizeContainer=function(){var t=this._getOption("resizeContainer");if(t){var e=this._getContainerSize();e&&(this._setContainerMeasure(e.width,!0),this._setContainerMeasure(e.height,!1))}},c._getContainerSize=d,c._setContainerMeasure=function(t,e){if(void 0!==t){var i=this.size;i.isBorderBox&&(t+=e?i.paddingLeft+i.paddingRight+i.borderLeftWidth+i.borderRightWidth:i.paddingBottom+i.paddingTop+i.borderTopWidth+i.borderBottomWidth),t=Math.max(t,0),this.element.style[e?"width":"height"]=t+"px"}},c._emitCompleteOnItems=function(t,e){function i(){o.dispatchEvent(t+"Complete",null,[e])}function n(){r++,r==s&&i()}var o=this,s=e.length;if(!e||!s)return void i();var r=0;e.forEach(function(e){e.once(t,n)})},c.dispatchEvent=function(t,e,i){var n=e?[e].concat(i):i;if(this.emitEvent(t,n),h)if(this.$element=this.$element||h(this.element),e){var o=h.Event(e);o.type=t,this.$element.trigger(o,i)}else this.$element.trigger(t,i)},c.ignore=function(t){var e=this.getItem(t);e&&(e.isIgnored=!0)},c.unignore=function(t){var e=this.getItem(t);e&&delete e.isIgnored},c.stamp=function(t){t=this._find(t),t&&(this.stamps=this.stamps.concat(t),t.forEach(this.ignore,this))},c.unstamp=function(t){t=this._find(t),t&&t.forEach(function(t){n.removeFrom(this.stamps,t),this.unignore(t)},this)},c._find=function(t){if(t)return"string"==typeof t&&(t=this.element.querySelectorAll(t)),t=n.makeArray(t)},c._manageStamps=function(){this.stamps&&this.stamps.length&&(this._getBoundingRect(),this.stamps.forEach(this._manageStamp,this))},c._getBoundingRect=function(){var t=this.element.getBoundingClientRect(),e=this.size;this._boundingRect={left:t.left+e.paddingLeft+e.borderLeftWidth,top:t.top+e.paddingTop+e.borderTopWidth,right:t.right-(e.paddingRight+e.borderRightWidth),bottom:t.bottom-(e.paddingBottom+e.borderBottomWidth)}},c._manageStamp=d,c._getElementOffset=function(t){var e=t.getBoundingClientRect(),n=this._boundingRect,o=i(t),s={left:e.left-n.left-o.marginLeft,top:e.top-n.top-o.marginTop,right:n.right-e.right-o.marginRight,bottom:n.bottom-e.bottom-o.marginBottom};return s},c.handleEvent=n.handleEvent,c.bindResize=function(){t.addEventListener("resize",this),this.isResizeBound=!0},c.unbindResize=function(){t.removeEventListener("resize",this),this.isResizeBound=!1},c.onresize=function(){this.resize()},n.debounceMethod(s,"onresize",100),c.resize=function(){this.isResizeBound&&this.needsResizeLayout()&&this.layout()},c.needsResizeLayout=function(){var t=i(this.element),e=this.size&&t;return e&&t.innerWidth!==this.size.innerWidth},c.addItems=function(t){var e=this._itemize(t);return e.length&&(this.items=this.items.concat(e)),e},c.appended=function(t){var e=this.addItems(t);e.length&&(this.layoutItems(e,!0),this.reveal(e))},c.prepended=function(t){var e=this._itemize(t);if(e.length){var i=this.items.slice(0);this.items=e.concat(i),this._resetLayout(),this._manageStamps(),this.layoutItems(e,!0),this.reveal(e),this.layoutItems(i)}},c.reveal=function(t){if(this._emitCompleteOnItems("reveal",t),t&&t.length){var e=this.updateStagger();t.forEach(function(t,i){t.stagger(i*e),t.reveal()})}},c.hide=function(t){if(this._emitCompleteOnItems("hide",t),t&&t.length){var e=this.updateStagger();t.forEach(function(t,i){t.stagger(i*e),t.hide()})}},c.revealItemElements=function(t){var e=this.getItems(t);this.reveal(e)},c.hideItemElements=function(t){var e=this.getItems(t);this.hide(e)},c.getItem=function(t){for(var e=0;e<this.items.length;e++){var i=this.items[e];if(i.element==t)return i}},c.getItems=function(t){t=n.makeArray(t);var e=[];return t.forEach(function(t){var i=this.getItem(t);i&&e.push(i)},this),e},c.remove=function(t){var e=this.getItems(t);this._emitCompleteOnItems("remove",e),e&&e.length&&e.forEach(function(t){t.remove(),n.removeFrom(this.items,t)},this)},c.destroy=function(){var t=this.element.style;t.height="",t.position="",t.width="",this.items.forEach(function(t){t.destroy()}),this.unbindResize();var e=this.element.outlayerGUID;delete f[e],delete this.element.outlayerGUID,h&&h.removeData(this.element,this.constructor.namespace)},s.data=function(t){t=n.getQueryElement(t);var e=t&&t.outlayerGUID;return e&&f[e]},s.create=function(t,e){var i=r(s);return i.defaults=n.extend({},s.defaults),n.extend(i.defaults,e),i.compatOptions=n.extend({},s.compatOptions),i.namespace=t,i.data=s.data,i.Item=r(o),n.htmlInit(i,t),h&&h.bridget&&h.bridget(t,i),i};var m={ms:1,s:1e3};return s.Item=o,s}),function(t,e){"function"==typeof define&&define.amd?define("isotope/js/item",["outlayer/outlayer"],e):"object"==typeof module&&module.exports?module.exports=e(require("outlayer")):(t.Isotope=t.Isotope||{},t.Isotope.Item=e(t.Outlayer))}(window,function(t){"use strict";function e(){t.Item.apply(this,arguments)}var i=e.prototype=Object.create(t.Item.prototype),n=i._create;i._create=function(){this.id=this.layout.itemGUID++,n.call(this),this.sortData={}},i.updateSortData=function(){if(!this.isIgnored){this.sortData.id=this.id,this.sortData["original-order"]=this.id,this.sortData.random=Math.random();var t=this.layout.options.getSortData,e=this.layout._sorters;for(var i in t){var n=e[i];this.sortData[i]=n(this.element,this)}}};var o=i.destroy;return i.destroy=function(){o.apply(this,arguments),this.css({display:""})},e}),function(t,e){"function"==typeof define&&define.amd?define("isotope/js/layout-mode",["get-size/get-size","outlayer/outlayer"],e):"object"==typeof module&&module.exports?module.exports=e(require("get-size"),require("outlayer")):(t.Isotope=t.Isotope||{},t.Isotope.LayoutMode=e(t.getSize,t.Outlayer))}(window,function(t,e){"use strict";function i(t){this.isotope=t,t&&(this.options=t.options[this.namespace],this.element=t.element,this.items=t.filteredItems,this.size=t.size)}var n=i.prototype,o=["_resetLayout","_getItemLayoutPosition","_manageStamp","_getContainerSize","_getElementOffset","needsResizeLayout","_getOption"];return o.forEach(function(t){n[t]=function(){return e.prototype[t].apply(this.isotope,arguments)}}),n.needsVerticalResizeLayout=function(){var e=t(this.isotope.element),i=this.isotope.size&&e;return i&&e.innerHeight!=this.isotope.size.innerHeight},n._getMeasurement=function(){this.isotope._getMeasurement.apply(this,arguments)},n.getColumnWidth=function(){this.getSegmentSize("column","Width")},n.getRowHeight=function(){this.getSegmentSize("row","Height")},n.getSegmentSize=function(t,e){var i=t+e,n="outer"+e;if(this._getMeasurement(i,n),!this[i]){var o=this.getFirstItemSize();this[i]=o&&o[n]||this.isotope.size["inner"+e]}},n.getFirstItemSize=function(){var e=this.isotope.filteredItems[0];return e&&e.element&&t(e.element)},n.layout=function(){this.isotope.layout.apply(this.isotope,arguments)},n.getSize=function(){this.isotope.getSize(),this.size=this.isotope.size},i.modes={},i.create=function(t,e){function o(){i.apply(this,arguments)}return o.prototype=Object.create(n),o.prototype.constructor=o,e&&(o.options=e),o.prototype.namespace=t,i.modes[t]=o,o},i}),function(t,e){"function"==typeof define&&define.amd?define("masonry/masonry",["outlayer/outlayer","get-size/get-size"],e):"object"==typeof module&&module.exports?module.exports=e(require("outlayer"),require("get-size")):t.Masonry=e(t.Outlayer,t.getSize)}(window,function(t,e){var i=t.create("masonry");return i.compatOptions.fitWidth="isFitWidth",i.prototype._resetLayout=function(){this.getSize(),this._getMeasurement("columnWidth","outerWidth"),this._getMeasurement("gutter","outerWidth"),this.measureColumns(),this.colYs=[];for(var t=0;t<this.cols;t++)this.colYs.push(0);this.maxY=0},i.prototype.measureColumns=function(){if(this.getContainerWidth(),!this.columnWidth){var t=this.items[0],i=t&&t.element;this.columnWidth=i&&e(i).outerWidth||this.containerWidth}var n=this.columnWidth+=this.gutter,o=this.containerWidth+this.gutter,s=o/n,r=n-o%n,a=r&&r<1?"round":"floor";s=Math[a](s),this.cols=Math.max(s,1)},i.prototype.getContainerWidth=function(){var t=this._getOption("fitWidth"),i=t?this.element.parentNode:this.element,n=e(i);this.containerWidth=n&&n.innerWidth},i.prototype._getItemLayoutPosition=function(t){t.getSize();var e=t.size.outerWidth%this.columnWidth,i=e&&e<1?"round":"ceil",n=Math[i](t.size.outerWidth/this.columnWidth);n=Math.min(n,this.cols);for(var o=this._getColGroup(n),s=Math.min.apply(Math,o),r=o.indexOf(s),a={x:this.columnWidth*r,y:s},u=s+t.size.outerHeight,h=this.cols+1-o.length,d=0;d<h;d++)this.colYs[r+d]=u;return a},i.prototype._getColGroup=function(t){if(t<2)return this.colYs;for(var e=[],i=this.cols+1-t,n=0;n<i;n++){var o=this.colYs.slice(n,n+t);e[n]=Math.max.apply(Math,o)}return e},i.prototype._manageStamp=function(t){var i=e(t),n=this._getElementOffset(t),o=this._getOption("originLeft"),s=o?n.left:n.right,r=s+i.outerWidth,a=Math.floor(s/this.columnWidth);a=Math.max(0,a);var u=Math.floor(r/this.columnWidth);u-=r%this.columnWidth?0:1,u=Math.min(this.cols-1,u);for(var h=this._getOption("originTop"),d=(h?n.top:n.bottom)+i.outerHeight,l=a;l<=u;l++)this.colYs[l]=Math.max(d,this.colYs[l])},i.prototype._getContainerSize=function(){this.maxY=Math.max.apply(Math,this.colYs);var t={height:this.maxY};return this._getOption("fitWidth")&&(t.width=this._getContainerFitWidth()),t},i.prototype._getContainerFitWidth=function(){for(var t=0,e=this.cols;--e&&0===this.colYs[e];)t++;return(this.cols-t)*this.columnWidth-this.gutter},i.prototype.needsResizeLayout=function(){var t=this.containerWidth;return this.getContainerWidth(),t!=this.containerWidth},i}),function(t,e){"function"==typeof define&&define.amd?define("isotope/js/layout-modes/masonry",["../layout-mode","masonry/masonry"],e):"object"==typeof module&&module.exports?module.exports=e(require("../layout-mode"),require("masonry-layout")):e(t.Isotope.LayoutMode,t.Masonry)}(window,function(t,e){"use strict";var i=t.create("masonry"),n=i.prototype,o={_getElementOffset:!0,layout:!0,_getMeasurement:!0};for(var s in e.prototype)o[s]||(n[s]=e.prototype[s]);var r=n.measureColumns;n.measureColumns=function(){this.items=this.isotope.filteredItems,r.call(this)};var a=n._getOption;return n._getOption=function(t){return"fitWidth"==t?void 0!==this.options.isFitWidth?this.options.isFitWidth:this.options.fitWidth:a.apply(this.isotope,arguments)},i}),function(t,e){"function"==typeof define&&define.amd?define("isotope/js/layout-modes/fit-rows",["../layout-mode"],e):"object"==typeof exports?module.exports=e(require("../layout-mode")):e(t.Isotope.LayoutMode)}(window,function(t){"use strict";var e=t.create("fitRows"),i=e.prototype;return i._resetLayout=function(){this.x=0,this.y=0,this.maxY=0,this._getMeasurement("gutter","outerWidth")},i._getItemLayoutPosition=function(t){t.getSize();var e=t.size.outerWidth+this.gutter,i=this.isotope.size.innerWidth+this.gutter;0!==this.x&&e+this.x>i&&(this.x=0,this.y=this.maxY);var n={x:this.x,y:this.y};return this.maxY=Math.max(this.maxY,this.y+t.size.outerHeight),this.x+=e,n},i._getContainerSize=function(){return{height:this.maxY}},e}),function(t,e){"function"==typeof define&&define.amd?define("isotope/js/layout-modes/vertical",["../layout-mode"],e):"object"==typeof module&&module.exports?module.exports=e(require("../layout-mode")):e(t.Isotope.LayoutMode)}(window,function(t){"use strict";var e=t.create("vertical",{horizontalAlignment:0}),i=e.prototype;return i._resetLayout=function(){this.y=0},i._getItemLayoutPosition=function(t){t.getSize();var e=(this.isotope.size.innerWidth-t.size.outerWidth)*this.options.horizontalAlignment,i=this.y;return this.y+=t.size.outerHeight,{x:e,y:i}},i._getContainerSize=function(){return{height:this.y}},e}),function(t,e){"function"==typeof define&&define.amd?define(["outlayer/outlayer","get-size/get-size","desandro-matches-selector/matches-selector","fizzy-ui-utils/utils","isotope/js/item","isotope/js/layout-mode","isotope/js/layout-modes/masonry","isotope/js/layout-modes/fit-rows","isotope/js/layout-modes/vertical"],function(i,n,o,s,r,a){return e(t,i,n,o,s,r,a)}):"object"==typeof module&&module.exports?module.exports=e(t,require("outlayer"),require("get-size"),require("desandro-matches-selector"),require("fizzy-ui-utils"),require("isotope/js/item"),require("isotope/js/layout-mode"),require("isotope/js/layout-modes/masonry"),require("isotope/js/layout-modes/fit-rows"),require("isotope/js/layout-modes/vertical")):t.Isotope=e(t,t.Outlayer,t.getSize,t.matchesSelector,t.fizzyUIUtils,t.Isotope.Item,t.Isotope.LayoutMode)}(window,function(t,e,i,n,o,s,r){function a(t,e){return function(i,n){for(var o=0;o<t.length;o++){var s=t[o],r=i.sortData[s],a=n.sortData[s];if(r>a||r<a){var u=void 0!==e[s]?e[s]:e,h=u?1:-1;return(r>a?1:-1)*h}}return 0}}var u=t.jQuery,h=String.prototype.trim?function(t){return t.trim()}:function(t){return t.replace(/^\s+|\s+$/g,"")},d=e.create("isotope",{layoutMode:"masonry",isJQueryFiltering:!0,sortAscending:!0});d.Item=s,d.LayoutMode=r;var l=d.prototype;l._create=function(){this.itemGUID=0,this._sorters={},this._getSorters(),e.prototype._create.call(this),this.modes={},this.filteredItems=this.items,this.sortHistory=["original-order"];for(var t in r.modes)this._initLayoutMode(t)},l.reloadItems=function(){this.itemGUID=0,e.prototype.reloadItems.call(this)},l._itemize=function(){for(var t=e.prototype._itemize.apply(this,arguments),i=0;i<t.length;i++){var n=t[i];n.id=this.itemGUID++}return this._updateItemsSortData(t),t},l._initLayoutMode=function(t){var e=r.modes[t],i=this.options[t]||{};this.options[t]=e.options?o.extend(e.options,i):i,this.modes[t]=new e(this)},l.layout=function(){return!this._isLayoutInited&&this._getOption("initLayout")?void this.arrange():void this._layout()},l._layout=function(){var t=this._getIsInstant();this._resetLayout(),this._manageStamps(),this.layoutItems(this.filteredItems,t),this._isLayoutInited=!0},l.arrange=function(t){this.option(t),this._getIsInstant();var e=this._filter(this.items);this.filteredItems=e.matches,this._bindArrangeComplete(),this._isInstant?this._noTransition(this._hideReveal,[e]):this._hideReveal(e),this._sort(),this._layout()},l._init=l.arrange,l._hideReveal=function(t){this.reveal(t.needReveal),this.hide(t.needHide)},l._getIsInstant=function(){var t=this._getOption("layoutInstant"),e=void 0!==t?t:!this._isLayoutInited;return this._isInstant=e,e},l._bindArrangeComplete=function(){function t(){e&&i&&n&&o.dispatchEvent("arrangeComplete",null,[o.filteredItems])}var e,i,n,o=this;this.once("layoutComplete",function(){e=!0,t()}),this.once("hideComplete",function(){i=!0,t()}),this.once("revealComplete",function(){n=!0,t()})},l._filter=function(t){var e=this.options.filter;e=e||"*";for(var i=[],n=[],o=[],s=this._getFilterTest(e),r=0;r<t.length;r++){var a=t[r];if(!a.isIgnored){var u=s(a);u&&i.push(a),u&&a.isHidden?n.push(a):u||a.isHidden||o.push(a)}}return{matches:i,needReveal:n,needHide:o}},l._getFilterTest=function(t){return u&&this.options.isJQueryFiltering?function(e){return u(e.element).is(t)}:"function"==typeof t?function(e){return t(e.element)}:function(e){return n(e.element,t)}},l.updateSortData=function(t){var e;t?(t=o.makeArray(t),e=this.getItems(t)):e=this.items,this._getSorters(),this._updateItemsSortData(e)},l._getSorters=function(){var t=this.options.getSortData;for(var e in t){var i=t[e];this._sorters[e]=f(i)}},l._updateItemsSortData=function(t){for(var e=t&&t.length,i=0;e&&i<e;i++){var n=t[i];n.updateSortData()}};var f=function(){function t(t){if("string"!=typeof t)return t;var i=h(t).split(" "),n=i[0],o=n.match(/^\[(.+)\]$/),s=o&&o[1],r=e(s,n),a=d.sortDataParsers[i[1]];
12
- return t=a?function(t){return t&&a(r(t))}:function(t){return t&&r(t)}}function e(t,e){return t?function(e){return e.getAttribute(t)}:function(t){var i=t.querySelector(e);return i&&i.textContent}}return t}();d.sortDataParsers={parseInt:function(t){return parseInt(t,10)},parseFloat:function(t){return parseFloat(t)}},l._sort=function(){var t=this.options.sortBy;if(t){var e=[].concat.apply(t,this.sortHistory),i=a(e,this.options.sortAscending);this.filteredItems.sort(i),t!=this.sortHistory[0]&&this.sortHistory.unshift(t)}},l._mode=function(){var t=this.options.layoutMode,e=this.modes[t];if(!e)throw new Error("No layout mode: "+t);return e.options=this.options[t],e},l._resetLayout=function(){e.prototype._resetLayout.call(this),this._mode()._resetLayout()},l._getItemLayoutPosition=function(t){return this._mode()._getItemLayoutPosition(t)},l._manageStamp=function(t){this._mode()._manageStamp(t)},l._getContainerSize=function(){return this._mode()._getContainerSize()},l.needsResizeLayout=function(){return this._mode().needsResizeLayout()},l.appended=function(t){var e=this.addItems(t);if(e.length){var i=this._filterRevealAdded(e);this.filteredItems=this.filteredItems.concat(i)}},l.prepended=function(t){var e=this._itemize(t);if(e.length){this._resetLayout(),this._manageStamps();var i=this._filterRevealAdded(e);this.layoutItems(this.filteredItems),this.filteredItems=i.concat(this.filteredItems),this.items=e.concat(this.items)}},l._filterRevealAdded=function(t){var e=this._filter(t);return this.hide(e.needHide),this.reveal(e.matches),this.layoutItems(e.matches,!0),e.matches},l.insert=function(t){var e=this.addItems(t);if(e.length){var i,n,o=e.length;for(i=0;i<o;i++)n=e[i],this.element.appendChild(n.element);var s=this._filter(e).matches;for(i=0;i<o;i++)e[i].isLayoutInstant=!0;for(this.arrange(),i=0;i<o;i++)delete e[i].isLayoutInstant;this.reveal(s)}};var c=l.remove;return l.remove=function(t){t=o.makeArray(t);var e=this.getItems(t);c.call(this,t);for(var i=e&&e.length,n=0;i&&n<i;n++){var s=e[n];o.removeFrom(this.filteredItems,s)}},l.shuffle=function(){for(var t=0;t<this.items.length;t++){var e=this.items[t];e.sortData.random=Math.random()}this.options.sortBy="random",this._sort(),this._layout()},l._noTransition=function(t,e){var i=this.options.transitionDuration;this.options.transitionDuration=0;var n=t.apply(this,e);return this.options.transitionDuration=i,n},l.getFilteredItemElements=function(){return this.filteredItems.map(function(t){return t.element})},d});
9
  */
10
 
11
  !function(t,e){"function"==typeof define&&define.amd?define("jquery-bridget/jquery-bridget",["jquery"],function(i){return e(t,i)}):"object"==typeof module&&module.exports?module.exports=e(t,require("jquery")):t.jQueryBridget=e(t,t.jQuery)}(window,function(t,e){"use strict";function i(i,s,a){function u(t,e,n){var o,s="$()."+i+'("'+e+'")';return t.each(function(t,u){var h=a.data(u,i);if(!h)return void r(i+" not initialized. Cannot call methods, i.e. "+s);var d=h[e];if(!d||"_"==e.charAt(0))return void r(s+" is not a valid method");var l=d.apply(h,n);o=void 0===o?l:o}),void 0!==o?o:t}function h(t,e){t.each(function(t,n){var o=a.data(n,i);o?(o.option(e),o._init()):(o=new s(n,e),a.data(n,i,o))})}a=a||e||t.jQuery,a&&(s.prototype.option||(s.prototype.option=function(t){a.isPlainObject(t)&&(this.options=a.extend(!0,this.options,t))}),a.fn[i]=function(t){if("string"==typeof t){var e=o.call(arguments,1);return u(this,t,e)}return h(this,t),this},n(a))}function n(t){!t||t&&t.bridget||(t.bridget=i)}var o=Array.prototype.slice,s=t.console,r="undefined"==typeof s?function(){}:function(t){s.error(t)};return n(e||t.jQuery),i}),function(t,e){"function"==typeof define&&define.amd?define("ev-emitter/ev-emitter",e):"object"==typeof module&&module.exports?module.exports=e():t.EvEmitter=e()}("undefined"!=typeof window?window:this,function(){function t(){}var e=t.prototype;return e.on=function(t,e){if(t&&e){var i=this._events=this._events||{},n=i[t]=i[t]||[];return n.indexOf(e)==-1&&n.push(e),this}},e.once=function(t,e){if(t&&e){this.on(t,e);var i=this._onceEvents=this._onceEvents||{},n=i[t]=i[t]||{};return n[e]=!0,this}},e.off=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){var n=i.indexOf(e);return n!=-1&&i.splice(n,1),this}},e.emitEvent=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){var n=0,o=i[n];e=e||[];for(var s=this._onceEvents&&this._onceEvents[t];o;){var r=s&&s[o];r&&(this.off(t,o),delete s[o]),o.apply(this,e),n+=r?0:1,o=i[n]}return this}},t}),function(t,e){"use strict";"function"==typeof define&&define.amd?define("get-size/get-size",[],function(){return e()}):"object"==typeof module&&module.exports?module.exports=e():t.getSize=e()}(window,function(){"use strict";function t(t){var e=parseFloat(t),i=t.indexOf("%")==-1&&!isNaN(e);return i&&e}function e(){}function i(){for(var t={width:0,height:0,innerWidth:0,innerHeight:0,outerWidth:0,outerHeight:0},e=0;e<h;e++){var i=u[e];t[i]=0}return t}function n(t){var e=getComputedStyle(t);return e||a("Style returned "+e+". Are you running this code in a hidden iframe on Firefox? See http://bit.ly/getsizebug1"),e}function o(){if(!d){d=!0;var e=document.createElement("div");e.style.width="200px",e.style.padding="1px 2px 3px 4px",e.style.borderStyle="solid",e.style.borderWidth="1px 2px 3px 4px",e.style.boxSizing="border-box";var i=document.body||document.documentElement;i.appendChild(e);var o=n(e);s.isBoxSizeOuter=r=200==t(o.width),i.removeChild(e)}}function s(e){if(o(),"string"==typeof e&&(e=document.querySelector(e)),e&&"object"==typeof e&&e.nodeType){var s=n(e);if("none"==s.display)return i();var a={};a.width=e.offsetWidth,a.height=e.offsetHeight;for(var d=a.isBorderBox="border-box"==s.boxSizing,l=0;l<h;l++){var f=u[l],c=s[f],m=parseFloat(c);a[f]=isNaN(m)?0:m}var p=a.paddingLeft+a.paddingRight,y=a.paddingTop+a.paddingBottom,g=a.marginLeft+a.marginRight,v=a.marginTop+a.marginBottom,_=a.borderLeftWidth+a.borderRightWidth,I=a.borderTopWidth+a.borderBottomWidth,z=d&&r,x=t(s.width);x!==!1&&(a.width=x+(z?0:p+_));var S=t(s.height);return S!==!1&&(a.height=S+(z?0:y+I)),a.innerWidth=a.width-(p+_),a.innerHeight=a.height-(y+I),a.outerWidth=a.width+g,a.outerHeight=a.height+v,a}}var r,a="undefined"==typeof console?e:function(t){console.error(t)},u=["paddingLeft","paddingRight","paddingTop","paddingBottom","marginLeft","marginRight","marginTop","marginBottom","borderLeftWidth","borderRightWidth","borderTopWidth","borderBottomWidth"],h=u.length,d=!1;return s}),function(t,e){"use strict";"function"==typeof define&&define.amd?define("desandro-matches-selector/matches-selector",e):"object"==typeof module&&module.exports?module.exports=e():t.matchesSelector=e()}(window,function(){"use strict";var t=function(){var t=Element.prototype;if(t.matches)return"matches";if(t.matchesSelector)return"matchesSelector";for(var e=["webkit","moz","ms","o"],i=0;i<e.length;i++){var n=e[i],o=n+"MatchesSelector";if(t[o])return o}}();return function(e,i){return e[t](i)}}),function(t,e){"function"==typeof define&&define.amd?define("fizzy-ui-utils/utils",["desandro-matches-selector/matches-selector"],function(i){return e(t,i)}):"object"==typeof module&&module.exports?module.exports=e(t,require("desandro-matches-selector")):t.fizzyUIUtils=e(t,t.matchesSelector)}(window,function(t,e){var i={};i.extend=function(t,e){for(var i in e)t[i]=e[i];return t},i.modulo=function(t,e){return(t%e+e)%e},i.makeArray=function(t){var e=[];if(Array.isArray(t))e=t;else if(t&&"number"==typeof t.length)for(var i=0;i<t.length;i++)e.push(t[i]);else e.push(t);return e},i.removeFrom=function(t,e){var i=t.indexOf(e);i!=-1&&t.splice(i,1)},i.getParent=function(t,i){for(;t!=document.body;)if(t=t.parentNode,e(t,i))return t},i.getQueryElement=function(t){return"string"==typeof t?document.querySelector(t):t},i.handleEvent=function(t){var e="on"+t.type;this[e]&&this[e](t)},i.filterFindElements=function(t,n){t=i.makeArray(t);var o=[];return t.forEach(function(t){if(t instanceof HTMLElement){if(!n)return void o.push(t);e(t,n)&&o.push(t);for(var i=t.querySelectorAll(n),s=0;s<i.length;s++)o.push(i[s])}}),o},i.debounceMethod=function(t,e,i){var n=t.prototype[e],o=e+"Timeout";t.prototype[e]=function(){var t=this[o];t&&clearTimeout(t);var e=arguments,s=this;this[o]=setTimeout(function(){n.apply(s,e),delete s[o]},i||100)}},i.docReady=function(t){var e=document.readyState;"complete"==e||"interactive"==e?setTimeout(t):document.addEventListener("DOMContentLoaded",t)},i.toDashed=function(t){return t.replace(/(.)([A-Z])/g,function(t,e,i){return e+"-"+i}).toLowerCase()};var n=t.console;return i.htmlInit=function(e,o){i.docReady(function(){var s=i.toDashed(o),r="data-"+s,a=document.querySelectorAll("["+r+"]"),u=document.querySelectorAll(".js-"+s),h=i.makeArray(a).concat(i.makeArray(u)),d=r+"-options",l=t.jQuery;h.forEach(function(t){var i,s=t.getAttribute(r)||t.getAttribute(d);try{i=s&&JSON.parse(s)}catch(a){return void(n&&n.error("Error parsing "+r+" on "+t.className+": "+a))}var u=new e(t,i);l&&l.data(t,o,u)})})},i}),function(t,e){"function"==typeof define&&define.amd?define("outlayer/item",["ev-emitter/ev-emitter","get-size/get-size"],e):"object"==typeof module&&module.exports?module.exports=e(require("ev-emitter"),require("get-size")):(t.Outlayer={},t.Outlayer.Item=e(t.EvEmitter,t.getSize))}(window,function(t,e){"use strict";function i(t){for(var e in t)return!1;return e=null,!0}function n(t,e){t&&(this.element=t,this.layout=e,this.position={x:0,y:0},this._create())}function o(t){return t.replace(/([A-Z])/g,function(t){return"-"+t.toLowerCase()})}var s=document.documentElement.style,r="string"==typeof s.transition?"transition":"WebkitTransition",a="string"==typeof s.transform?"transform":"WebkitTransform",u={WebkitTransition:"webkitTransitionEnd",transition:"transitionend"}[r],h={transform:a,transition:r,transitionDuration:r+"Duration",transitionProperty:r+"Property",transitionDelay:r+"Delay"},d=n.prototype=Object.create(t.prototype);d.constructor=n,d._create=function(){this._transn={ingProperties:{},clean:{},onEnd:{}},this.css({position:"absolute"})},d.handleEvent=function(t){var e="on"+t.type;this[e]&&this[e](t)},d.getSize=function(){this.size=e(this.element)},d.css=function(t){var e=this.element.style;for(var i in t){var n=h[i]||i;e[n]=t[i]}},d.getPosition=function(){var t=getComputedStyle(this.element),e=this.layout._getOption("originLeft"),i=this.layout._getOption("originTop"),n=t[e?"left":"right"],o=t[i?"top":"bottom"],s=this.layout.size,r=n.indexOf("%")!=-1?parseFloat(n)/100*s.width:parseInt(n,10),a=o.indexOf("%")!=-1?parseFloat(o)/100*s.height:parseInt(o,10);r=isNaN(r)?0:r,a=isNaN(a)?0:a,r-=e?s.paddingLeft:s.paddingRight,a-=i?s.paddingTop:s.paddingBottom,this.position.x=r,this.position.y=a},d.layoutPosition=function(){var t=this.layout.size,e={},i=this.layout._getOption("originLeft"),n=this.layout._getOption("originTop"),o=i?"paddingLeft":"paddingRight",s=i?"left":"right",r=i?"right":"left",a=this.position.x+t[o];e[s]=this.getXValue(a),e[r]="";var u=n?"paddingTop":"paddingBottom",h=n?"top":"bottom",d=n?"bottom":"top",l=this.position.y+t[u];e[h]=this.getYValue(l),e[d]="",this.css(e),this.emitEvent("layout",[this])},d.getXValue=function(t){var e=this.layout._getOption("horizontal");return this.layout.options.percentPosition&&!e?t/this.layout.size.width*100+"%":t+"px"},d.getYValue=function(t){var e=this.layout._getOption("horizontal");return this.layout.options.percentPosition&&e?t/this.layout.size.height*100+"%":t+"px"},d._transitionTo=function(t,e){this.getPosition();var i=this.position.x,n=this.position.y,o=parseInt(t,10),s=parseInt(e,10),r=o===this.position.x&&s===this.position.y;if(this.setPosition(t,e),r&&!this.isTransitioning)return void this.layoutPosition();var a=t-i,u=e-n,h={};h.transform=this.getTranslate(a,u),this.transition({to:h,onTransitionEnd:{transform:this.layoutPosition},isCleaning:!0})},d.getTranslate=function(t,e){var i=this.layout._getOption("originLeft"),n=this.layout._getOption("originTop");return t=i?t:-t,e=n?e:-e,"translate3d("+t+"px, "+e+"px, 0)"},d.goTo=function(t,e){this.setPosition(t,e),this.layoutPosition()},d.moveTo=d._transitionTo,d.setPosition=function(t,e){this.position.x=parseInt(t,10),this.position.y=parseInt(e,10)},d._nonTransition=function(t){this.css(t.to),t.isCleaning&&this._removeStyles(t.to);for(var e in t.onTransitionEnd)t.onTransitionEnd[e].call(this)},d.transition=function(t){if(!parseFloat(this.layout.options.transitionDuration))return void this._nonTransition(t);var e=this._transn;for(var i in t.onTransitionEnd)e.onEnd[i]=t.onTransitionEnd[i];for(i in t.to)e.ingProperties[i]=!0,t.isCleaning&&(e.clean[i]=!0);if(t.from){this.css(t.from);var n=this.element.offsetHeight;n=null}this.enableTransition(t.to),this.css(t.to),this.isTransitioning=!0};var l="opacity,"+o(a);d.enableTransition=function(){if(!this.isTransitioning){var t=this.layout.options.transitionDuration;t="number"==typeof t?t+"ms":t,this.css({transitionProperty:l,transitionDuration:t,transitionDelay:this.staggerDelay||0}),this.element.addEventListener(u,this,!1)}},d.onwebkitTransitionEnd=function(t){this.ontransitionend(t)},d.onotransitionend=function(t){this.ontransitionend(t)};var f={"-webkit-transform":"transform"};d.ontransitionend=function(t){if(t.target===this.element){var e=this._transn,n=f[t.propertyName]||t.propertyName;if(delete e.ingProperties[n],i(e.ingProperties)&&this.disableTransition(),n in e.clean&&(this.element.style[t.propertyName]="",delete e.clean[n]),n in e.onEnd){var o=e.onEnd[n];o.call(this),delete e.onEnd[n]}this.emitEvent("transitionEnd",[this])}},d.disableTransition=function(){this.removeTransitionStyles(),this.element.removeEventListener(u,this,!1),this.isTransitioning=!1},d._removeStyles=function(t){var e={};for(var i in t)e[i]="";this.css(e)};var c={transitionProperty:"",transitionDuration:"",transitionDelay:""};return d.removeTransitionStyles=function(){this.css(c)},d.stagger=function(t){t=isNaN(t)?0:t,this.staggerDelay=t+"ms"},d.removeElem=function(){this.element.parentNode.removeChild(this.element),this.css({display:""}),this.emitEvent("remove",[this])},d.remove=function(){return r&&parseFloat(this.layout.options.transitionDuration)?(this.once("transitionEnd",function(){this.removeElem()}),void this.hide()):void this.removeElem()},d.reveal=function(){delete this.isHidden,this.css({display:""});var t=this.layout.options,e={},i=this.getHideRevealTransitionEndProperty("visibleStyle");e[i]=this.onRevealTransitionEnd,this.transition({from:t.hiddenStyle,to:t.visibleStyle,isCleaning:!0,onTransitionEnd:e})},d.onRevealTransitionEnd=function(){this.isHidden||this.emitEvent("reveal")},d.getHideRevealTransitionEndProperty=function(t){var e=this.layout.options[t];if(e.opacity)return"opacity";for(var i in e)return i},d.hide=function(){this.isHidden=!0,this.css({display:""});var t=this.layout.options,e={},i=this.getHideRevealTransitionEndProperty("hiddenStyle");e[i]=this.onHideTransitionEnd,this.transition({from:t.visibleStyle,to:t.hiddenStyle,isCleaning:!0,onTransitionEnd:e})},d.onHideTransitionEnd=function(){this.isHidden&&(this.css({display:"none"}),this.emitEvent("hide"))},d.destroy=function(){this.css({position:"",left:"",right:"",top:"",bottom:"",transition:"",transform:""})},n}),function(t,e){"use strict";"function"==typeof define&&define.amd?define("outlayer/outlayer",["ev-emitter/ev-emitter","get-size/get-size","fizzy-ui-utils/utils","./item"],function(i,n,o,s){return e(t,i,n,o,s)}):"object"==typeof module&&module.exports?module.exports=e(t,require("ev-emitter"),require("get-size"),require("fizzy-ui-utils"),require("./item")):t.Outlayer=e(t,t.EvEmitter,t.getSize,t.fizzyUIUtils,t.Outlayer.Item)}(window,function(t,e,i,n,o){"use strict";function s(t,e){var i=n.getQueryElement(t);if(!i)return void(u&&u.error("Bad element for "+this.constructor.namespace+": "+(i||t)));this.element=i,h&&(this.$element=h(this.element)),this.options=n.extend({},this.constructor.defaults),this.option(e);var o=++l;this.element.outlayerGUID=o,f[o]=this,this._create();var s=this._getOption("initLayout");s&&this.layout()}function r(t){function e(){t.apply(this,arguments)}return e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e}function a(t){if("number"==typeof t)return t;var e=t.match(/(^\d*\.?\d*)(\w*)/),i=e&&e[1],n=e&&e[2];if(!i.length)return 0;i=parseFloat(i);var o=m[n]||1;return i*o}var u=t.console,h=t.jQuery,d=function(){},l=0,f={};s.namespace="outlayer",s.Item=o,s.defaults={containerStyle:{position:"relative"},initLayout:!0,originLeft:!0,originTop:!0,resize:!0,resizeContainer:!0,transitionDuration:"0.4s",hiddenStyle:{opacity:0,transform:"scale(0.001)"},visibleStyle:{opacity:1,transform:"scale(1)"}};var c=s.prototype;n.extend(c,e.prototype),c.option=function(t){n.extend(this.options,t)},c._getOption=function(t){var e=this.constructor.compatOptions[t];return e&&void 0!==this.options[e]?this.options[e]:this.options[t]},s.compatOptions={initLayout:"isInitLayout",horizontal:"isHorizontal",layoutInstant:"isLayoutInstant",originLeft:"isOriginLeft",originTop:"isOriginTop",resize:"isResizeBound",resizeContainer:"isResizingContainer"},c._create=function(){this.reloadItems(),this.stamps=[],this.stamp(this.options.stamp),n.extend(this.element.style,this.options.containerStyle);var t=this._getOption("resize");t&&this.bindResize()},c.reloadItems=function(){this.items=this._itemize(this.element.children)},c._itemize=function(t){for(var e=this._filterFindItemElements(t),i=this.constructor.Item,n=[],o=0;o<e.length;o++){var s=e[o],r=new i(s,this);n.push(r)}return n},c._filterFindItemElements=function(t){return n.filterFindElements(t,this.options.itemSelector)},c.getItemElements=function(){return this.items.map(function(t){return t.element})},c.layout=function(){this._resetLayout(),this._manageStamps();var t=this._getOption("layoutInstant"),e=void 0!==t?t:!this._isLayoutInited;this.layoutItems(this.items,e),this._isLayoutInited=!0},c._init=c.layout,c._resetLayout=function(){this.getSize()},c.getSize=function(){this.size=i(this.element)},c._getMeasurement=function(t,e){var n,o=this.options[t];o?("string"==typeof o?n=this.element.querySelector(o):o instanceof HTMLElement&&(n=o),this[t]=n?i(n)[e]:o):this[t]=0},c.layoutItems=function(t,e){t=this._getItemsForLayout(t),this._layoutItems(t,e),this._postLayout()},c._getItemsForLayout=function(t){return t.filter(function(t){return!t.isIgnored})},c._layoutItems=function(t,e){if(this._emitCompleteOnItems("layout",t),t&&t.length){var i=[];t.forEach(function(t){var n=this._getItemLayoutPosition(t);n.item=t,n.isInstant=e||t.isLayoutInstant,i.push(n)},this),this._processLayoutQueue(i)}},c._getItemLayoutPosition=function(){return{x:0,y:0}},c._processLayoutQueue=function(t){this.updateStagger(),t.forEach(function(t,e){this._positionItem(t.item,t.x,t.y,t.isInstant,e)},this)},c.updateStagger=function(){var t=this.options.stagger;return null===t||void 0===t?void(this.stagger=0):(this.stagger=a(t),this.stagger)},c._positionItem=function(t,e,i,n,o){n?t.goTo(e,i):(t.stagger(o*this.stagger),t.moveTo(e,i))},c._postLayout=function(){this.resizeContainer()},c.resizeContainer=function(){var t=this._getOption("resizeContainer");if(t){var e=this._getContainerSize();e&&(this._setContainerMeasure(e.width,!0),this._setContainerMeasure(e.height,!1))}},c._getContainerSize=d,c._setContainerMeasure=function(t,e){if(void 0!==t){var i=this.size;i.isBorderBox&&(t+=e?i.paddingLeft+i.paddingRight+i.borderLeftWidth+i.borderRightWidth:i.paddingBottom+i.paddingTop+i.borderTopWidth+i.borderBottomWidth),t=Math.max(t,0),this.element.style[e?"width":"height"]=t+"px"}},c._emitCompleteOnItems=function(t,e){function i(){o.dispatchEvent(t+"Complete",null,[e])}function n(){r++,r==s&&i()}var o=this,s=e.length;if(!e||!s)return void i();var r=0;e.forEach(function(e){e.once(t,n)})},c.dispatchEvent=function(t,e,i){var n=e?[e].concat(i):i;if(this.emitEvent(t,n),h)if(this.$element=this.$element||h(this.element),e){var o=h.Event(e);o.type=t,this.$element.trigger(o,i)}else this.$element.trigger(t,i)},c.ignore=function(t){var e=this.getItem(t);e&&(e.isIgnored=!0)},c.unignore=function(t){var e=this.getItem(t);e&&delete e.isIgnored},c.stamp=function(t){t=this._find(t),t&&(this.stamps=this.stamps.concat(t),t.forEach(this.ignore,this))},c.unstamp=function(t){t=this._find(t),t&&t.forEach(function(t){n.removeFrom(this.stamps,t),this.unignore(t)},this)},c._find=function(t){if(t)return"string"==typeof t&&(t=this.element.querySelectorAll(t)),t=n.makeArray(t)},c._manageStamps=function(){this.stamps&&this.stamps.length&&(this._getBoundingRect(),this.stamps.forEach(this._manageStamp,this))},c._getBoundingRect=function(){var t=this.element.getBoundingClientRect(),e=this.size;this._boundingRect={left:t.left+e.paddingLeft+e.borderLeftWidth,top:t.top+e.paddingTop+e.borderTopWidth,right:t.right-(e.paddingRight+e.borderRightWidth),bottom:t.bottom-(e.paddingBottom+e.borderBottomWidth)}},c._manageStamp=d,c._getElementOffset=function(t){var e=t.getBoundingClientRect(),n=this._boundingRect,o=i(t),s={left:e.left-n.left-o.marginLeft,top:e.top-n.top-o.marginTop,right:n.right-e.right-o.marginRight,bottom:n.bottom-e.bottom-o.marginBottom};return s},c.handleEvent=n.handleEvent,c.bindResize=function(){t.addEventListener("resize",this),this.isResizeBound=!0},c.unbindResize=function(){t.removeEventListener("resize",this),this.isResizeBound=!1},c.onresize=function(){this.resize()},n.debounceMethod(s,"onresize",100),c.resize=function(){this.isResizeBound&&this.needsResizeLayout()&&this.layout()},c.needsResizeLayout=function(){var t=i(this.element),e=this.size&&t;return e&&t.innerWidth!==this.size.innerWidth},c.addItems=function(t){var e=this._itemize(t);return e.length&&(this.items=this.items.concat(e)),e},c.appended=function(t){var e=this.addItems(t);e.length&&(this.layoutItems(e,!0),this.reveal(e))},c.prepended=function(t){var e=this._itemize(t);if(e.length){var i=this.items.slice(0);this.items=e.concat(i),this._resetLayout(),this._manageStamps(),this.layoutItems(e,!0),this.reveal(e),this.layoutItems(i)}},c.reveal=function(t){if(this._emitCompleteOnItems("reveal",t),t&&t.length){var e=this.updateStagger();t.forEach(function(t,i){t.stagger(i*e),t.reveal()})}},c.hide=function(t){if(this._emitCompleteOnItems("hide",t),t&&t.length){var e=this.updateStagger();t.forEach(function(t,i){t.stagger(i*e),t.hide()})}},c.revealItemElements=function(t){var e=this.getItems(t);this.reveal(e)},c.hideItemElements=function(t){var e=this.getItems(t);this.hide(e)},c.getItem=function(t){for(var e=0;e<this.items.length;e++){var i=this.items[e];if(i.element==t)return i}},c.getItems=function(t){t=n.makeArray(t);var e=[];return t.forEach(function(t){var i=this.getItem(t);i&&e.push(i)},this),e},c.remove=function(t){var e=this.getItems(t);this._emitCompleteOnItems("remove",e),e&&e.length&&e.forEach(function(t){t.remove(),n.removeFrom(this.items,t)},this)},c.destroy=function(){var t=this.element.style;t.height="",t.position="",t.width="",this.items.forEach(function(t){t.destroy()}),this.unbindResize();var e=this.element.outlayerGUID;delete f[e],delete this.element.outlayerGUID,h&&h.removeData(this.element,this.constructor.namespace)},s.data=function(t){t=n.getQueryElement(t);var e=t&&t.outlayerGUID;return e&&f[e]},s.create=function(t,e){var i=r(s);return i.defaults=n.extend({},s.defaults),n.extend(i.defaults,e),i.compatOptions=n.extend({},s.compatOptions),i.namespace=t,i.data=s.data,i.Item=r(o),n.htmlInit(i,t),h&&h.bridget&&h.bridget(t,i),i};var m={ms:1,s:1e3};return s.Item=o,s}),function(t,e){"function"==typeof define&&define.amd?define("isotope/js/item",["outlayer/outlayer"],e):"object"==typeof module&&module.exports?module.exports=e(require("outlayer")):(t.Isotope=t.Isotope||{},t.Isotope.Item=e(t.Outlayer))}(window,function(t){"use strict";function e(){t.Item.apply(this,arguments)}var i=e.prototype=Object.create(t.Item.prototype),n=i._create;i._create=function(){this.id=this.layout.itemGUID++,n.call(this),this.sortData={}},i.updateSortData=function(){if(!this.isIgnored){this.sortData.id=this.id,this.sortData["original-order"]=this.id,this.sortData.random=Math.random();var t=this.layout.options.getSortData,e=this.layout._sorters;for(var i in t){var n=e[i];this.sortData[i]=n(this.element,this)}}};var o=i.destroy;return i.destroy=function(){o.apply(this,arguments),this.css({display:""})},e}),function(t,e){"function"==typeof define&&define.amd?define("isotope/js/layout-mode",["get-size/get-size","outlayer/outlayer"],e):"object"==typeof module&&module.exports?module.exports=e(require("get-size"),require("outlayer")):(t.Isotope=t.Isotope||{},t.Isotope.LayoutMode=e(t.getSize,t.Outlayer))}(window,function(t,e){"use strict";function i(t){this.isotope=t,t&&(this.options=t.options[this.namespace],this.element=t.element,this.items=t.filteredItems,this.size=t.size)}var n=i.prototype,o=["_resetLayout","_getItemLayoutPosition","_manageStamp","_getContainerSize","_getElementOffset","needsResizeLayout","_getOption"];return o.forEach(function(t){n[t]=function(){return e.prototype[t].apply(this.isotope,arguments)}}),n.needsVerticalResizeLayout=function(){var e=t(this.isotope.element),i=this.isotope.size&&e;return i&&e.innerHeight!=this.isotope.size.innerHeight},n._getMeasurement=function(){this.isotope._getMeasurement.apply(this,arguments)},n.getColumnWidth=function(){this.getSegmentSize("column","Width")},n.getRowHeight=function(){this.getSegmentSize("row","Height")},n.getSegmentSize=function(t,e){var i=t+e,n="outer"+e;if(this._getMeasurement(i,n),!this[i]){var o=this.getFirstItemSize();this[i]=o&&o[n]||this.isotope.size["inner"+e]}},n.getFirstItemSize=function(){var e=this.isotope.filteredItems[0];return e&&e.element&&t(e.element)},n.layout=function(){this.isotope.layout.apply(this.isotope,arguments)},n.getSize=function(){this.isotope.getSize(),this.size=this.isotope.size},i.modes={},i.create=function(t,e){function o(){i.apply(this,arguments)}return o.prototype=Object.create(n),o.prototype.constructor=o,e&&(o.options=e),o.prototype.namespace=t,i.modes[t]=o,o},i}),function(t,e){"function"==typeof define&&define.amd?define("masonry/masonry",["outlayer/outlayer","get-size/get-size"],e):"object"==typeof module&&module.exports?module.exports=e(require("outlayer"),require("get-size")):t.Masonry=e(t.Outlayer,t.getSize)}(window,function(t,e){var i=t.create("masonry");return i.compatOptions.fitWidth="isFitWidth",i.prototype._resetLayout=function(){this.getSize(),this._getMeasurement("columnWidth","outerWidth"),this._getMeasurement("gutter","outerWidth"),this.measureColumns(),this.colYs=[];for(var t=0;t<this.cols;t++)this.colYs.push(0);this.maxY=0},i.prototype.measureColumns=function(){if(this.getContainerWidth(),!this.columnWidth){var t=this.items[0],i=t&&t.element;this.columnWidth=i&&e(i).outerWidth||this.containerWidth}var n=this.columnWidth+=this.gutter,o=this.containerWidth+this.gutter,s=o/n,r=n-o%n,a=r&&r<1?"round":"floor";s=Math[a](s),this.cols=Math.max(s,1)},i.prototype.getContainerWidth=function(){var t=this._getOption("fitWidth"),i=t?this.element.parentNode:this.element,n=e(i);this.containerWidth=n&&n.innerWidth},i.prototype._getItemLayoutPosition=function(t){t.getSize();var e=t.size.outerWidth%this.columnWidth,i=e&&e<1?"round":"ceil",n=Math[i](t.size.outerWidth/this.columnWidth);n=Math.min(n,this.cols);for(var o=this._getColGroup(n),s=Math.min.apply(Math,o),r=o.indexOf(s),a={x:this.columnWidth*r,y:s},u=s+t.size.outerHeight,h=this.cols+1-o.length,d=0;d<h;d++)this.colYs[r+d]=u;return a},i.prototype._getColGroup=function(t){if(t<2)return this.colYs;for(var e=[],i=this.cols+1-t,n=0;n<i;n++){var o=this.colYs.slice(n,n+t);e[n]=Math.max.apply(Math,o)}return e},i.prototype._manageStamp=function(t){var i=e(t),n=this._getElementOffset(t),o=this._getOption("originLeft"),s=o?n.left:n.right,r=s+i.outerWidth,a=Math.floor(s/this.columnWidth);a=Math.max(0,a);var u=Math.floor(r/this.columnWidth);u-=r%this.columnWidth?0:1,u=Math.min(this.cols-1,u);for(var h=this._getOption("originTop"),d=(h?n.top:n.bottom)+i.outerHeight,l=a;l<=u;l++)this.colYs[l]=Math.max(d,this.colYs[l])},i.prototype._getContainerSize=function(){this.maxY=Math.max.apply(Math,this.colYs);var t={height:this.maxY};return this._getOption("fitWidth")&&(t.width=this._getContainerFitWidth()),t},i.prototype._getContainerFitWidth=function(){for(var t=0,e=this.cols;--e&&0===this.colYs[e];)t++;return(this.cols-t)*this.columnWidth-this.gutter},i.prototype.needsResizeLayout=function(){var t=this.containerWidth;return this.getContainerWidth(),t!=this.containerWidth},i}),function(t,e){"function"==typeof define&&define.amd?define("isotope/js/layout-modes/masonry",["../layout-mode","masonry/masonry"],e):"object"==typeof module&&module.exports?module.exports=e(require("../layout-mode"),require("masonry-layout")):e(t.Isotope.LayoutMode,t.Masonry)}(window,function(t,e){"use strict";var i=t.create("masonry"),n=i.prototype,o={_getElementOffset:!0,layout:!0,_getMeasurement:!0};for(var s in e.prototype)o[s]||(n[s]=e.prototype[s]);var r=n.measureColumns;n.measureColumns=function(){this.items=this.isotope.filteredItems,r.call(this)};var a=n._getOption;return n._getOption=function(t){return"fitWidth"==t?void 0!==this.options.isFitWidth?this.options.isFitWidth:this.options.fitWidth:a.apply(this.isotope,arguments)},i}),function(t,e){"function"==typeof define&&define.amd?define("isotope/js/layout-modes/fit-rows",["../layout-mode"],e):"object"==typeof exports?module.exports=e(require("../layout-mode")):e(t.Isotope.LayoutMode)}(window,function(t){"use strict";var e=t.create("fitRows"),i=e.prototype;return i._resetLayout=function(){this.x=0,this.y=0,this.maxY=0,this._getMeasurement("gutter","outerWidth")},i._getItemLayoutPosition=function(t){t.getSize();var e=t.size.outerWidth+this.gutter,i=this.isotope.size.innerWidth+this.gutter;0!==this.x&&e+this.x>i&&(this.x=0,this.y=this.maxY);var n={x:this.x,y:this.y};return this.maxY=Math.max(this.maxY,this.y+t.size.outerHeight),this.x+=e,n},i._getContainerSize=function(){return{height:this.maxY}},e}),function(t,e){"function"==typeof define&&define.amd?define("isotope/js/layout-modes/vertical",["../layout-mode"],e):"object"==typeof module&&module.exports?module.exports=e(require("../layout-mode")):e(t.Isotope.LayoutMode)}(window,function(t){"use strict";var e=t.create("vertical",{horizontalAlignment:0}),i=e.prototype;return i._resetLayout=function(){this.y=0},i._getItemLayoutPosition=function(t){t.getSize();var e=(this.isotope.size.innerWidth-t.size.outerWidth)*this.options.horizontalAlignment,i=this.y;return this.y+=t.size.outerHeight,{x:e,y:i}},i._getContainerSize=function(){return{height:this.y}},e}),function(t,e){"function"==typeof define&&define.amd?define(["outlayer/outlayer","get-size/get-size","desandro-matches-selector/matches-selector","fizzy-ui-utils/utils","isotope/js/item","isotope/js/layout-mode","isotope/js/layout-modes/masonry","isotope/js/layout-modes/fit-rows","isotope/js/layout-modes/vertical"],function(i,n,o,s,r,a){return e(t,i,n,o,s,r,a)}):"object"==typeof module&&module.exports?module.exports=e(t,require("outlayer"),require("get-size"),require("desandro-matches-selector"),require("fizzy-ui-utils"),require("isotope/js/item"),require("isotope/js/layout-mode"),require("isotope/js/layout-modes/masonry"),require("isotope/js/layout-modes/fit-rows"),require("isotope/js/layout-modes/vertical")):t.Isotope=e(t,t.Outlayer,t.getSize,t.matchesSelector,t.fizzyUIUtils,t.Isotope.Item,t.Isotope.LayoutMode)}(window,function(t,e,i,n,o,s,r){function a(t,e){return function(i,n){for(var o=0;o<t.length;o++){var s=t[o],r=i.sortData[s],a=n.sortData[s];if(r>a||r<a){var u=void 0!==e[s]?e[s]:e,h=u?1:-1;return(r>a?1:-1)*h}}return 0}}var u=t.jQuery,h=String.prototype.trim?function(t){return t.trim()}:function(t){return t.replace(/^\s+|\s+$/g,"")},d=e.create("isotope",{layoutMode:"masonry",isJQueryFiltering:!0,sortAscending:!0});d.Item=s,d.LayoutMode=r;var l=d.prototype;l._create=function(){this.itemGUID=0,this._sorters={},this._getSorters(),e.prototype._create.call(this),this.modes={},this.filteredItems=this.items,this.sortHistory=["original-order"];for(var t in r.modes)this._initLayoutMode(t)},l.reloadItems=function(){this.itemGUID=0,e.prototype.reloadItems.call(this)},l._itemize=function(){for(var t=e.prototype._itemize.apply(this,arguments),i=0;i<t.length;i++){var n=t[i];n.id=this.itemGUID++}return this._updateItemsSortData(t),t},l._initLayoutMode=function(t){var e=r.modes[t],i=this.options[t]||{};this.options[t]=e.options?o.extend(e.options,i):i,this.modes[t]=new e(this)},l.layout=function(){return!this._isLayoutInited&&this._getOption("initLayout")?void this.arrange():void this._layout()},l._layout=function(){var t=this._getIsInstant();this._resetLayout(),this._manageStamps(),this.layoutItems(this.filteredItems,t),this._isLayoutInited=!0},l.arrange=function(t){this.option(t),this._getIsInstant();var e=this._filter(this.items);this.filteredItems=e.matches,this._bindArrangeComplete(),this._isInstant?this._noTransition(this._hideReveal,[e]):this._hideReveal(e),this._sort(),this._layout()},l._init=l.arrange,l._hideReveal=function(t){this.reveal(t.needReveal),this.hide(t.needHide)},l._getIsInstant=function(){var t=this._getOption("layoutInstant"),e=void 0!==t?t:!this._isLayoutInited;return this._isInstant=e,e},l._bindArrangeComplete=function(){function t(){e&&i&&n&&o.dispatchEvent("arrangeComplete",null,[o.filteredItems])}var e,i,n,o=this;this.once("layoutComplete",function(){e=!0,t()}),this.once("hideComplete",function(){i=!0,t()}),this.once("revealComplete",function(){n=!0,t()})},l._filter=function(t){var e=this.options.filter;e=e||"*";for(var i=[],n=[],o=[],s=this._getFilterTest(e),r=0;r<t.length;r++){var a=t[r];if(!a.isIgnored){var u=s(a);u&&i.push(a),u&&a.isHidden?n.push(a):u||a.isHidden||o.push(a)}}return{matches:i,needReveal:n,needHide:o}},l._getFilterTest=function(t){return u&&this.options.isJQueryFiltering?function(e){return u(e.element).is(t)}:"function"==typeof t?function(e){return t(e.element)}:function(e){return n(e.element,t)}},l.updateSortData=function(t){var e;t?(t=o.makeArray(t),e=this.getItems(t)):e=this.items,this._getSorters(),this._updateItemsSortData(e)},l._getSorters=function(){var t=this.options.getSortData;for(var e in t){var i=t[e];this._sorters[e]=f(i)}},l._updateItemsSortData=function(t){for(var e=t&&t.length,i=0;e&&i<e;i++){var n=t[i];n.updateSortData()}};var f=function(){function t(t){if("string"!=typeof t)return t;var i=h(t).split(" "),n=i[0],o=n.match(/^\[(.+)\]$/),s=o&&o[1],r=e(s,n),a=d.sortDataParsers[i[1]];
12
+ return t=a?function(t){return t&&a(r(t))}:function(t){return t&&r(t)}}function e(t,e){return t?function(e){return e.getAttribute(t)}:function(t){var i=t.querySelector(e);return i&&i.textContent}}return t}();d.sortDataParsers={parseInt:function(t){return parseInt(t,10)},parseFloat:function(t){return parseFloat(t)}},l._sort=function(){var t=this.options.sortBy;if(t){var e=[].concat.apply(t,this.sortHistory),i=a(e,this.options.sortAscending);this.filteredItems.sort(i),t!=this.sortHistory[0]&&this.sortHistory.unshift(t)}},l._mode=function(){var t=this.options.layoutMode,e=this.modes[t];if(!e)throw new Error("No layout mode: "+t);return e.options=this.options[t],e},l._resetLayout=function(){e.prototype._resetLayout.call(this),this._mode()._resetLayout()},l._getItemLayoutPosition=function(t){return this._mode()._getItemLayoutPosition(t)},l._manageStamp=function(t){this._mode()._manageStamp(t)},l._getContainerSize=function(){return this._mode()._getContainerSize()},l.needsResizeLayout=function(){return this._mode().needsResizeLayout()},l.appended=function(t){var e=this.addItems(t);if(e.length){var i=this._filterRevealAdded(e);this.filteredItems=this.filteredItems.concat(i)}},l.prepended=function(t){var e=this._itemize(t);if(e.length){this._resetLayout(),this._manageStamps();var i=this._filterRevealAdded(e);this.layoutItems(this.filteredItems),this.filteredItems=i.concat(this.filteredItems),this.items=e.concat(this.items)}},l._filterRevealAdded=function(t){var e=this._filter(t);return this.hide(e.needHide),this.reveal(e.matches),this.layoutItems(e.matches,!0),e.matches},l.insert=function(t){var e=this.addItems(t);if(e.length){var i,n,o=e.length;for(i=0;i<o;i++)n=e[i],this.element.appendChild(n.element);var s=this._filter(e).matches;for(i=0;i<o;i++)e[i].isLayoutInstant=!0;for(this.arrange(),i=0;i<o;i++)delete e[i].isLayoutInstant;this.reveal(s)}};var c=l.remove;return l.remove=function(t){t=o.makeArray(t);var e=this.getItems(t);c.call(this,t);for(var i=e&&e.length,n=0;i&&n<i;n++){var s=e[n];o.removeFrom(this.filteredItems,s)}},l.shuffle=function(){for(var t=0;t<this.items.length;t++){var e=this.items[t];e.sortData.random=Math.random()}this.options.sortBy="random",this._sort(),this._layout()},l._noTransition=function(t,e){var i=this.options.transitionDuration;this.options.transitionDuration=0;var n=t.apply(this,e);return this.options.transitionDuration=i,n},l.getFilteredItemElements=function(){return this.filteredItems.map(function(t){return t.element})},d});
assets/js/jquery.waypoints.js CHANGED
@@ -9,493 +9,493 @@ https://github.com/imakewebthings/jquery-waypoints/blob/master/licenses.txt
9
 
10
 
11
  (function() {
12
- var __indexOf = [].indexOf || function(item) { for (var i = 0, l = this.length; i < l; i++) { if (i in this && this[i] === item) return i; } return -1; },
13
- __slice = [].slice;
14
 
15
- (function(root, factory) {
16
- if (typeof define === 'function' && define.amd) {
17
- return define('waypoints', ['jquery'], function($) {
18
- return factory($, root);
19
- });
20
- } else {
21
- return factory(root.jQuery, root);
22
- }
23
- })(this, function($, window) {
24
- var $w, Context, Waypoint, allWaypoints, contextCounter, contextKey, contexts, isTouch, jQMethods, methods, resizeEvent, scrollEvent, waypointCounter, waypointKey, wp, wps;
25
- $w = $(window);
26
- isTouch = __indexOf.call(window, 'ontouchstart') >= 0;
27
- allWaypoints = {
28
- horizontal: {},
29
- vertical: {}
30
- };
31
- contextCounter = 1;
32
- contexts = {};
33
- contextKey = 'waypoints-context-id';
34
- resizeEvent = 'resize.waypoints';
35
- scrollEvent = 'scroll.waypoints';
36
- waypointCounter = 1;
37
- waypointKey = 'waypoints-waypoint-ids';
38
- wp = 'waypoint';
39
- wps = 'waypoints';
40
- Context = (function() {
41
-
42
- function Context($element) {
43
- var _this = this;
44
- this.$element = $element;
45
- this.element = $element[0];
46
- this.didResize = false;
47
- this.didScroll = false;
48
- this.id = 'context' + contextCounter++;
49
- this.oldScroll = {
50
- x: $element.scrollLeft(),
51
- y: $element.scrollTop()
52
- };
53
- this.waypoints = {
54
- horizontal: {},
55
- vertical: {}
56
- };
57
- $element.data(contextKey, this.id);
58
- contexts[this.id] = this;
59
- $element.bind(scrollEvent, function() {
60
- var scrollHandler;
61
- if (!(_this.didScroll || isTouch)) {
62
- _this.didScroll = true;
63
- scrollHandler = function() {
64
- _this.doScroll();
65
- return _this.didScroll = false;
66
- };
67
- return window.setTimeout(scrollHandler, $[wps].settings.scrollThrottle);
68
- }
69
- });
70
- $element.bind(resizeEvent, function() {
71
- var resizeHandler;
72
- if (!_this.didResize) {
73
- _this.didResize = true;
74
- resizeHandler = function() {
75
- $[wps]('refresh');
76
- return _this.didResize = false;
77
- };
78
- return window.setTimeout(resizeHandler, $[wps].settings.resizeThrottle);
79
- }
80
- });
81
- }
82
-
83
- Context.prototype.doScroll = function() {
84
- var axes,
85
- _this = this;
86
- axes = {
87
- horizontal: {
88
- newScroll: this.$element.scrollLeft(),
89
- oldScroll: this.oldScroll.x,
90
- forward: 'right',
91
- backward: 'left'
92
- },
93
- vertical: {
94
- newScroll: this.$element.scrollTop(),
95
- oldScroll: this.oldScroll.y,
96
- forward: 'down',
97
- backward: 'up'
98
- }
99
- };
100
- if (isTouch && (!axes.vertical.oldScroll || !axes.vertical.newScroll)) {
101
- $[wps]('refresh');
102
  }
103
- $.each(axes, function(aKey, axis) {
104
- var direction, isForward, triggered;
105
- triggered = [];
106
- isForward = axis.newScroll > axis.oldScroll;
107
- direction = isForward ? axis.forward : axis.backward;
108
- $.each(_this.waypoints[aKey], function(wKey, waypoint) {
109
- var _ref, _ref1;
110
- if ((axis.oldScroll < (_ref = waypoint.offset) && _ref <= axis.newScroll)) {
111
- return triggered.push(waypoint);
112
- } else if ((axis.newScroll < (_ref1 = waypoint.offset) && _ref1 <= axis.oldScroll)) {
113
- return triggered.push(waypoint);
114
- }
115
- });
116
- triggered.sort(function(a, b) {
117
- return a.offset - b.offset;
118
- });
119
- if (!isForward) {
120
- triggered.reverse();
121
- }
122
- return $.each(triggered, function(i, waypoint) {
123
- if (waypoint.options.continuous || i === triggered.length - 1) {
124
- return waypoint.trigger([direction]);
125
- }
126
- });
127
- });
128
- return this.oldScroll = {
129
- x: axes.horizontal.newScroll,
130
- y: axes.vertical.newScroll
131
  };
132
- };
 
 
 
 
 
 
 
 
 
133
 
134
- Context.prototype.refresh = function() {
135
- var axes, cOffset, isWin,
136
- _this = this;
137
- isWin = $.isWindow(this.element);
138
- cOffset = this.$element.offset();
139
- this.doScroll();
140
- axes = {
141
- horizontal: {
142
- contextOffset: isWin ? 0 : cOffset.left,
143
- contextScroll: isWin ? 0 : this.oldScroll.x,
144
- contextDimension: this.$element.width(),
145
- oldScroll: this.oldScroll.x,
146
- forward: 'right',
147
- backward: 'left',
148
- offsetProp: 'left'
149
- },
150
- vertical: {
151
- contextOffset: isWin ? 0 : cOffset.top,
152
- contextScroll: isWin ? 0 : this.oldScroll.y,
153
- contextDimension: isWin ? $[wps]('viewportHeight') : this.$element.height(),
154
- oldScroll: this.oldScroll.y,
155
- forward: 'down',
156
- backward: 'up',
157
- offsetProp: 'top'
158
- }
159
- };
160
- return $.each(axes, function(aKey, axis) {
161
- return $.each(_this.waypoints[aKey], function(i, waypoint) {
162
- var adjustment, elementOffset, oldOffset, _ref, _ref1;
163
- adjustment = waypoint.options.offset;
164
- oldOffset = waypoint.offset;
165
- elementOffset = $.isWindow(waypoint.element) ? 0 : waypoint.$element.offset()[axis.offsetProp];
166
- if ($.isFunction(adjustment)) {
167
- adjustment = adjustment.apply(waypoint.element);
168
- } else if (typeof adjustment === 'string') {
169
- adjustment = parseFloat(adjustment);
170
- if (waypoint.options.offset.indexOf('%') > -1) {
171
- adjustment = Math.ceil(axis.contextDimension * adjustment / 100);
172
- }
173
  }
174
- waypoint.offset = elementOffset - axis.contextOffset + axis.contextScroll - adjustment;
175
- if ((waypoint.options.onlyOnScroll && (oldOffset != null)) || !waypoint.enabled) {
176
- return;
177
- }
178
- if (oldOffset !== null && (oldOffset < (_ref = axis.oldScroll) && _ref <= waypoint.offset)) {
179
- return waypoint.trigger([axis.backward]);
180
- } else if (oldOffset !== null && (oldOffset > (_ref1 = axis.oldScroll) && _ref1 >= waypoint.offset)) {
181
- return waypoint.trigger([axis.forward]);
182
- } else if (oldOffset === null && axis.oldScroll >= waypoint.offset) {
183
- return waypoint.trigger([axis.forward]);
184
- }
185
- });
186
- });
187
- };
188
 
189
- Context.prototype.checkEmpty = function() {
190
- if ($.isEmptyObject(this.waypoints.horizontal) && $.isEmptyObject(this.waypoints.vertical)) {
191
- this.$element.unbind([resizeEvent, scrollEvent].join(' '));
192
- return delete contexts[this.id];
193
- }
194
- };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
195
 
196
- return Context;
197
 
198
- })();
199
- Waypoint = (function() {
200
 
201
- function Waypoint($element, context, options) {
202
- var idList, _ref;
203
- options = $.extend({}, $.fn[wp].defaults, options);
204
- if (options.offset === 'bottom-in-view') {
205
- options.offset = function() {
206
- var contextHeight;
207
- contextHeight = $[wps]('viewportHeight');
208
- if (!$.isWindow(context.element)) {
209
- contextHeight = context.$element.height();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
210
  }
211
- return contextHeight - $(this).outerHeight();
212
- };
213
- }
214
- this.$element = $element;
215
- this.element = $element[0];
216
- this.axis = options.horizontal ? 'horizontal' : 'vertical';
217
- this.callback = options.handler;
218
- this.context = context;
219
- this.enabled = options.enabled;
220
- this.id = 'waypoints' + waypointCounter++;
221
- this.offset = null;
222
- this.options = options;
223
- context.waypoints[this.axis][this.id] = this;
224
- allWaypoints[this.axis][this.id] = this;
225
- idList = (_ref = $element.data(waypointKey)) != null ? _ref : [];
226
- idList.push(this.id);
227
- $element.data(waypointKey, idList);
228
- }
229
 
230
- Waypoint.prototype.trigger = function(args) {
231
- if (!this.enabled) {
232
- return;
233
- }
234
- if (this.callback != null) {
235
- this.callback.apply(this.element, args);
236
- }
237
- if (this.options.triggerOnce) {
238
- return this.destroy();
239
- }
240
- };
241
 
242
- Waypoint.prototype.disable = function() {
243
- return this.enabled = false;
244
- };
245
 
246
- Waypoint.prototype.enable = function() {
247
- this.context.refresh();
248
- return this.enabled = true;
249
- };
250
 
251
- Waypoint.prototype.destroy = function() {
252
- delete allWaypoints[this.axis][this.id];
253
- delete this.context.waypoints[this.axis][this.id];
254
- return this.context.checkEmpty();
255
- };
256
 
257
- Waypoint.getWaypointsByElement = function(element) {
258
- var all, ids;
259
- ids = $(element).data(waypointKey);
260
- if (!ids) {
261
- return [];
262
- }
263
- all = $.extend({}, allWaypoints.horizontal, allWaypoints.vertical);
264
- return $.map(ids, function(id) {
265
- return all[id];
266
- });
267
- };
268
 
269
- return Waypoint;
270
 
271
- })();
272
- methods = {
273
- init: function(f, options) {
274
- var _ref;
275
- if (options == null) {
276
- options = {};
277
- }
278
- if ((_ref = options.handler) == null) {
279
- options.handler = f;
280
- }
281
- this.each(function() {
282
- var $this, context, contextElement, _ref1;
283
- $this = $(this);
284
- contextElement = (_ref1 = options.context) != null ? _ref1 : $.fn[wp].defaults.context;
285
- if (!$.isWindow(contextElement)) {
286
- contextElement = $this.closest(contextElement);
287
- }
288
- contextElement = $(contextElement);
289
- context = contexts[contextElement.data(contextKey)];
290
- if (!context) {
291
- context = new Context(contextElement);
292
- }
293
- return new Waypoint($this, context, options);
294
- });
295
- $[wps]('refresh');
296
- return this;
297
- },
298
- disable: function() {
299
- return methods._invoke(this, 'disable');
300
- },
301
- enable: function() {
302
- return methods._invoke(this, 'enable');
303
- },
304
- destroy: function() {
305
- return methods._invoke(this, 'destroy');
306
- },
307
- prev: function(axis, selector) {
308
- return methods._traverse.call(this, axis, selector, function(stack, index, waypoints) {
309
- if (index > 0) {
310
- return stack.push(waypoints[index - 1]);
311
- }
312
- });
313
- },
314
- next: function(axis, selector) {
315
- return methods._traverse.call(this, axis, selector, function(stack, index, waypoints) {
316
- if (index < waypoints.length - 1) {
317
- return stack.push(waypoints[index + 1]);
318
- }
319
- });
320
- },
321
- _traverse: function(axis, selector, push) {
322
- var stack, waypoints;
323
- if (axis == null) {
324
- axis = 'vertical';
325
- }
326
- if (selector == null) {
327
- selector = window;
328
- }
329
- waypoints = jQMethods.aggregate(selector);
330
- stack = [];
331
- this.each(function() {
332
- var index;
333
- index = $.inArray(this, waypoints[axis]);
334
- return push(stack, index, waypoints[axis]);
335
- });
336
- return this.pushStack(stack);
337
- },
338
- _invoke: function($elements, method) {
339
- $elements.each(function() {
340
- var waypoints;
341
- waypoints = Waypoint.getWaypointsByElement(this);
342
- return $.each(waypoints, function(i, waypoint) {
343
- waypoint[method]();
344
- return true;
345
- });
346
- });
347
- return this;
348
- }
349
- };
350
- $.fn[wp] = function() {
351
- var args, method;
352
- method = arguments[0], args = 2 <= arguments.length ? __slice.call(arguments, 1) : [];
353
- if (methods[method]) {
354
- return methods[method].apply(this, args);
355
- } else if ($.isFunction(method)) {
356
- return methods.init.apply(this, arguments);
357
- } else if ($.isPlainObject(method)) {
358
- return methods.init.apply(this, [null, method]);
359
- } else if (!method) {
360
- return $.error("jQuery Waypoints needs a callback function or handler option.");
361
- } else {
362
- return $.error("The " + method + " method does not exist in jQuery Waypoints.");
363
- }
364
- };
365
- $.fn[wp].defaults = {
366
- context: window,
367
- continuous: true,
368
- enabled: true,
369
- horizontal: false,
370
- offset: 0,
371
- triggerOnce: false
372
- };
373
- jQMethods = {
374
- refresh: function() {
375
- return $.each(contexts, function(i, context) {
376
- return context.refresh();
377
- });
378
- },
379
- viewportHeight: function() {
380
- var _ref;
381
- return (_ref = window.innerHeight) != null ? _ref : $w.height();
382
- },
383
- aggregate: function(contextSelector) {
384
- var collection, waypoints, _ref;
385
- collection = allWaypoints;
386
- if (contextSelector) {
387
- collection = (_ref = contexts[$(contextSelector).data(contextKey)]) != null ? _ref.waypoints : void 0;
388
- }
389
- if (!collection) {
390
- return [];
391
- }
392
- waypoints = {
393
- horizontal: [],
394
- vertical: []
395
  };
396
- $.each(waypoints, function(axis, arr) {
397
- $.each(collection[axis], function(key, waypoint) {
398
- return arr.push(waypoint);
399
- });
400
- arr.sort(function(a, b) {
401
- return a.offset - b.offset;
402
- });
403
- waypoints[axis] = $.map(arr, function(waypoint) {
404
- return waypoint.element;
405
- });
406
- return waypoints[axis] = $.unique(waypoints[axis]);
407
- });
408
- return waypoints;
409
- },
410
- above: function(contextSelector) {
411
- if (contextSelector == null) {
412
- contextSelector = window;
413
- }
414
- return jQMethods._filter(contextSelector, 'vertical', function(context, waypoint) {
415
- return waypoint.offset <= context.oldScroll.y;
416
- });
417
- },
418
- below: function(contextSelector) {
419
- if (contextSelector == null) {
420
- contextSelector = window;
421
- }
422
- return jQMethods._filter(contextSelector, 'vertical', function(context, waypoint) {
423
- return waypoint.offset > context.oldScroll.y;
424
- });
425
- },
426
- left: function(contextSelector) {
427
- if (contextSelector == null) {
428
- contextSelector = window;
429
- }
430
- return jQMethods._filter(contextSelector, 'horizontal', function(context, waypoint) {
431
- return waypoint.offset <= context.oldScroll.x;
432
- });
433
- },
434
- right: function(contextSelector) {
435
- if (contextSelector == null) {
436
- contextSelector = window;
437
- }
438
- return jQMethods._filter(contextSelector, 'horizontal', function(context, waypoint) {
439
- return waypoint.offset > context.oldScroll.x;
440
- });
441
- },
442
- enable: function() {
443
- return jQMethods._invoke('enable');
444
- },
445
- disable: function() {
446
- return jQMethods._invoke('disable');
447
- },
448
- destroy: function() {
449
- return jQMethods._invoke('destroy');
450
- },
451
- extendFn: function(methodName, f) {
452
- return methods[methodName] = f;
453
- },
454
- _invoke: function(method) {
455
- var waypoints;
456
- waypoints = $.extend({}, allWaypoints.vertical, allWaypoints.horizontal);
457
- return $.each(waypoints, function(key, waypoint) {
458
- waypoint[method]();
459
- return true;
460
- });
461
- },
462
- _filter: function(selector, axis, test) {
463
- var context, waypoints;
464
- context = contexts[$(selector).data(contextKey)];
465
- if (!context) {
466
- return [];
467
- }
468
- waypoints = [];
469
- $.each(context.waypoints[axis], function(i, waypoint) {
470
- if (test(context, waypoint)) {
471
- return waypoints.push(waypoint);
472
- }
473
- });
474
- waypoints.sort(function(a, b) {
475
- return a.offset - b.offset;
476
- });
477
- return $.map(waypoints, function(waypoint) {
478
- return waypoint.element;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
479
  });
480
- }
481
- };
482
- $[wps] = function() {
483
- var args, method;
484
- method = arguments[0], args = 2 <= arguments.length ? __slice.call(arguments, 1) : [];
485
- if (jQMethods[method]) {
486
- return jQMethods[method].apply(null, args);
487
- } else {
488
- return jQMethods.aggregate.call(null, method);
489
- }
490
- };
491
- $[wps].settings = {
492
- resizeThrottle: 100,
493
- scrollThrottle: 30
494
- };
495
- return $w.load(function() {
496
- return $[wps]('refresh');
497
  });
498
- });
499
 
500
  }).call(this);
501
 
9
 
10
 
11
  (function() {
12
+ var __indexOf = [].indexOf || function(item) { for (var i = 0, l = this.length; i < l; i++) { if (i in this && this[i] === item) return i; } return -1; },
13
+ __slice = [].slice;
14
 
15
+ (function(root, factory) {
16
+ if (typeof define === 'function' && define.amd) {
17
+ return define('waypoints', ['jquery'], function($) {
18
+ return factory($, root);
19
+ });
20
+ } else {
21
+ return factory(root.jQuery, root);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
22
  }
23
+ })(this, function($, window) {
24
+ var $w, Context, Waypoint, allWaypoints, contextCounter, contextKey, contexts, isTouch, jQMethods, methods, resizeEvent, scrollEvent, waypointCounter, waypointKey, wp, wps;
25
+ $w = $(window);
26
+ isTouch = __indexOf.call(window, 'ontouchstart') >= 0;
27
+ allWaypoints = {
28
+ horizontal: {},
29
+ vertical: {}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
30
  };
31
+ contextCounter = 1;
32
+ contexts = {};
33
+ contextKey = 'waypoints-context-id';
34
+ resizeEvent = 'resize.waypoints';
35
+ scrollEvent = 'scroll.waypoints';
36
+ waypointCounter = 1;
37
+ waypointKey = 'waypoints-waypoint-ids';
38
+ wp = 'waypoint';
39
+ wps = 'waypoints';
40
+ Context = (function() {
41
 
42
+ function Context($element) {
43
+ var _this = this;
44
+ this.$element = $element;
45
+ this.element = $element[0];
46
+ this.didResize = false;
47
+ this.didScroll = false;
48
+ this.id = 'context' + contextCounter++;
49
+ this.oldScroll = {
50
+ x: $element.scrollLeft(),
51
+ y: $element.scrollTop()
52
+ };
53
+ this.waypoints = {
54
+ horizontal: {},
55
+ vertical: {}
56
+ };
57
+ $element.data(contextKey, this.id);
58
+ contexts[this.id] = this;
59
+ $element.bind(scrollEvent, function() {
60
+ var scrollHandler;
61
+ if (!(_this.didScroll || isTouch)) {
62
+ _this.didScroll = true;
63
+ scrollHandler = function() {
64
+ _this.doScroll();
65
+ return _this.didScroll = false;
66
+ };
67
+ return window.setTimeout(scrollHandler, $[wps].settings.scrollThrottle);
68
+ }
69
+ });
70
+ $element.bind(resizeEvent, function() {
71
+ var resizeHandler;
72
+ if (!_this.didResize) {
73
+ _this.didResize = true;
74
+ resizeHandler = function() {
75
+ $[wps]('refresh');
76
+ return _this.didResize = false;
77
+ };
78
+ return window.setTimeout(resizeHandler, $[wps].settings.resizeThrottle);
79
+ }
80
+ });
81
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
82
 
83
+ Context.prototype.doScroll = function() {
84
+ var axes,
85
+ _this = this;
86
+ axes = {
87
+ horizontal: {
88
+ newScroll: this.$element.scrollLeft(),
89
+ oldScroll: this.oldScroll.x,
90
+ forward: 'right',
91
+ backward: 'left'
92
+ },
93
+ vertical: {
94
+ newScroll: this.$element.scrollTop(),
95
+ oldScroll: this.oldScroll.y,
96
+ forward: 'down',
97
+ backward: 'up'
98
+ }
99
+ };
100
+ if (isTouch && (!axes.vertical.oldScroll || !axes.vertical.newScroll)) {
101
+ $[wps]('refresh');
102
+ }
103
+ $.each(axes, function(aKey, axis) {
104
+ var direction, isForward, triggered;
105
+ triggered = [];
106
+ isForward = axis.newScroll > axis.oldScroll;
107
+ direction = isForward ? axis.forward : axis.backward;
108
+ $.each(_this.waypoints[aKey], function(wKey, waypoint) {
109
+ var _ref, _ref1;
110
+ if ((axis.oldScroll < (_ref = waypoint.offset) && _ref <= axis.newScroll)) {
111
+ return triggered.push(waypoint);
112
+ } else if ((axis.newScroll < (_ref1 = waypoint.offset) && _ref1 <= axis.oldScroll)) {
113
+ return triggered.push(waypoint);
114
+ }
115
+ });
116
+ triggered.sort(function(a, b) {
117
+ return a.offset - b.offset;
118
+ });
119
+ if (!isForward) {
120
+ triggered.reverse();
121
+ }
122
+ return $.each(triggered, function(i, waypoint) {
123
+ if (waypoint.options.continuous || i === triggered.length - 1) {
124
+ return waypoint.trigger([direction]);
125
+ }
126
+ });
127
+ });
128
+ return this.oldScroll = {
129
+ x: axes.horizontal.newScroll,
130
+ y: axes.vertical.newScroll
131
+ };
132
+ };
133
+
134
+ Context.prototype.refresh = function() {
135
+ var axes, cOffset, isWin,
136
+ _this = this;
137
+ isWin = $.isWindow(this.element);
138
+ cOffset = this.$element.offset();
139
+ this.doScroll();
140
+ axes = {
141
+ horizontal: {
142
+ contextOffset: isWin ? 0 : cOffset.left,
143
+ contextScroll: isWin ? 0 : this.oldScroll.x,
144
+ contextDimension: this.$element.width(),
145
+ oldScroll: this.oldScroll.x,
146
+ forward: 'right',
147
+ backward: 'left',
148
+ offsetProp: 'left'
149
+ },
150
+ vertical: {
151
+ contextOffset: isWin ? 0 : cOffset.top,
152
+ contextScroll: isWin ? 0 : this.oldScroll.y,
153
+ contextDimension: isWin ? $[wps]('viewportHeight') : this.$element.height(),
154
+ oldScroll: this.oldScroll.y,
155
+ forward: 'down',
156
+ backward: 'up',
157
+ offsetProp: 'top'
158
+ }
159
+ };
160
+ return $.each(axes, function(aKey, axis) {
161
+ return $.each(_this.waypoints[aKey], function(i, waypoint) {
162
+ var adjustment, elementOffset, oldOffset, _ref, _ref1;
163
+ adjustment = waypoint.options.offset;
164
+ oldOffset = waypoint.offset;
165
+ elementOffset = $.isWindow(waypoint.element) ? 0 : waypoint.$element.offset()[axis.offsetProp];
166
+ if ($.isFunction(adjustment)) {
167
+ adjustment = adjustment.apply(waypoint.element);
168
+ } else if (typeof adjustment === 'string') {
169
+ adjustment = parseFloat(adjustment);
170
+ if (waypoint.options.offset.indexOf('%') > -1) {
171
+ adjustment = Math.ceil(axis.contextDimension * adjustment / 100);
172
+ }
173
+ }
174
+ waypoint.offset = elementOffset - axis.contextOffset + axis.contextScroll - adjustment;
175
+ if ((waypoint.options.onlyOnScroll && (oldOffset != null)) || !waypoint.enabled) {
176
+ return;
177
+ }
178
+ if (oldOffset !== null && (oldOffset < (_ref = axis.oldScroll) && _ref <= waypoint.offset)) {
179
+ return waypoint.trigger([axis.backward]);
180
+ } else if (oldOffset !== null && (oldOffset > (_ref1 = axis.oldScroll) && _ref1 >= waypoint.offset)) {
181
+ return waypoint.trigger([axis.forward]);
182
+ } else if (oldOffset === null && axis.oldScroll >= waypoint.offset) {
183
+ return waypoint.trigger([axis.forward]);
184
+ }
185
+ });
186
+ });
187
+ };
188
+
189
+ Context.prototype.checkEmpty = function() {
190
+ if ($.isEmptyObject(this.waypoints.horizontal) && $.isEmptyObject(this.waypoints.vertical)) {
191
+ this.$element.unbind([resizeEvent, scrollEvent].join(' '));
192
+ return delete contexts[this.id];
193
+ }
194
+ };
195
 
196
+ return Context;
197
 
198
+ })();
199
+ Waypoint = (function() {
200
 
201
+ function Waypoint($element, context, options) {
202
+ var idList, _ref;
203
+ options = $.extend({}, $.fn[wp].defaults, options);
204
+ if (options.offset === 'bottom-in-view') {
205
+ options.offset = function() {
206
+ var contextHeight;
207
+ contextHeight = $[wps]('viewportHeight');
208
+ if (!$.isWindow(context.element)) {
209
+ contextHeight = context.$element.height();
210
+ }
211
+ return contextHeight - $(this).outerHeight();
212
+ };
213
+ }
214
+ this.$element = $element;
215
+ this.element = $element[0];
216
+ this.axis = options.horizontal ? 'horizontal' : 'vertical';
217
+ this.callback = options.handler;
218
+ this.context = context;
219
+ this.enabled = options.enabled;
220
+ this.id = 'waypoints' + waypointCounter++;
221
+ this.offset = null;
222
+ this.options = options;
223
+ context.waypoints[this.axis][this.id] = this;
224
+ allWaypoints[this.axis][this.id] = this;
225
+ idList = (_ref = $element.data(waypointKey)) != null ? _ref : [];
226
+ idList.push(this.id);
227
+ $element.data(waypointKey, idList);
228
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
229
 
230
+ Waypoint.prototype.trigger = function(args) {
231
+ if (!this.enabled) {
232
+ return;
233
+ }
234
+ if (this.callback != null) {
235
+ this.callback.apply(this.element, args);
236
+ }
237
+ if (this.options.triggerOnce) {
238
+ return this.destroy();
239
+ }
240
+ };
241
 
242
+ Waypoint.prototype.disable = function() {
243
+ return this.enabled = false;
244
+ };
245
 
246
+ Waypoint.prototype.enable = function() {
247
+ this.context.refresh();
248
+ return this.enabled = true;
249
+ };
250
 
251
+ Waypoint.prototype.destroy = function() {
252
+ delete allWaypoints[this.axis][this.id];
253
+ delete this.context.waypoints[this.axis][this.id];
254
+ return this.context.checkEmpty();
255
+ };
256
 
257
+ Waypoint.getWaypointsByElement = function(element) {
258
+ var all, ids;
259
+ ids = $(element).data(waypointKey);
260
+ if (!ids) {
261
+ return [];
262
+ }
263
+ all = $.extend({}, allWaypoints.horizontal, allWaypoints.vertical);
264
+ return $.map(ids, function(id) {
265
+ return all[id];
266
+ });
267
+ };
268
 
269
+ return Waypoint;
270
 
271
+ })();
272
+ methods = {
273
+ init: function(f, options) {
274
+ var _ref;
275
+ if (options == null) {
276
+ options = {};
277
+ }
278
+ if ((_ref = options.handler) == null) {
279
+ options.handler = f;
280
+ }
281
+ this.each(function() {
282
+ var $this, context, contextElement, _ref1;
283
+ $this = $(this);
284
+ contextElement = (_ref1 = options.context) != null ? _ref1 : $.fn[wp].defaults.context;
285
+ if (!$.isWindow(contextElement)) {
286
+ contextElement = $this.closest(contextElement);
287
+ }
288
+ contextElement = $(contextElement);
289
+ context = contexts[contextElement.data(contextKey)];
290
+ if (!context) {
291
+ context = new Context(contextElement);
292
+ }
293
+ return new Waypoint($this, context, options);
294
+ });
295
+ $[wps]('refresh');
296
+ return this;
297
+ },
298
+ disable: function() {
299
+ return methods._invoke(this, 'disable');
300
+ },
301
+ enable: function() {
302
+ return methods._invoke(this, 'enable');
303
+ },
304
+ destroy: function() {
305
+ return methods._invoke(this, 'destroy');
306
+ },
307
+ prev: function(axis, selector) {
308
+ return methods._traverse.call(this, axis, selector, function(stack, index, waypoints) {
309
+ if (index > 0) {
310
+ return stack.push(waypoints[index - 1]);
311
+ }
312
+ });
313
+ },
314
+ next: function(axis, selector) {
315
+ return methods._traverse.call(this, axis, selector, function(stack, index, waypoints) {
316
+ if (index < waypoints.length - 1) {
317
+ return stack.push(waypoints[index + 1]);
318
+ }
319
+ });
320
+ },
321
+ _traverse: function(axis, selector, push) {
322
+ var stack, waypoints;
323
+ if (axis == null) {
324
+ axis = 'vertical';
325
+ }
326
+ if (selector == null) {
327
+ selector = window;
328
+ }
329
+ waypoints = jQMethods.aggregate(selector);
330
+ stack = [];
331
+ this.each(function() {
332
+ var index;
333
+ index = $.inArray(this, waypoints[axis]);
334
+ return push(stack, index, waypoints[axis]);
335
+ });
336
+ return this.pushStack(stack);
337
+ },
338
+ _invoke: function($elements, method) {
339
+ $elements.each(function() {
340
+ var waypoints;
341
+ waypoints = Waypoint.getWaypointsByElement(this);
342
+ return $.each(waypoints, function(i, waypoint) {
343
+ waypoint[method]();
344
+ return true;
345
+ });
346
+ });
347
+ return this;
348
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
349
  };
350
+ $.fn[wp] = function() {
351
+ var args, method;
352
+ method = arguments[0], args = 2 <= arguments.length ? __slice.call(arguments, 1) : [];
353
+ if (methods[method]) {
354
+ return methods[method].apply(this, args);
355
+ } else if ($.isFunction(method)) {
356
+ return methods.init.apply(this, arguments);
357
+ } else if ($.isPlainObject(method)) {
358
+ return methods.init.apply(this, [null, method]);
359
+ } else if (!method) {
360
+ return $.error("jQuery Waypoints needs a callback function or handler option.");
361
+ } else {
362
+ return $.error("The " + method + " method does not exist in jQuery Waypoints.");
363
+ }
364
+ };
365
+ $.fn[wp].defaults = {
366
+ context: window,
367
+ continuous: true,
368
+ enabled: true,
369
+ horizontal: false,
370
+ offset: 0,
371
+ triggerOnce: false
372
+ };
373
+ jQMethods = {
374
+ refresh: function() {
375
+ return $.each(contexts, function(i, context) {
376
+ return context.refresh();
377
+ });
378
+ },
379
+ viewportHeight: function() {
380
+ var _ref;
381
+ return (_ref = window.innerHeight) != null ? _ref : $w.height();
382
+ },
383
+ aggregate: function(contextSelector) {
384
+ var collection, waypoints, _ref;
385
+ collection = allWaypoints;
386
+ if (contextSelector) {
387
+ collection = (_ref = contexts[$(contextSelector).data(contextKey)]) != null ? _ref.waypoints : void 0;
388
+ }
389
+ if (!collection) {
390
+ return [];
391
+ }
392
+ waypoints = {
393
+ horizontal: [],
394
+ vertical: []
395
+ };
396
+ $.each(waypoints, function(axis, arr) {
397
+ $.each(collection[axis], function(key, waypoint) {
398
+ return arr.push(waypoint);
399
+ });
400
+ arr.sort(function(a, b) {
401
+ return a.offset - b.offset;
402
+ });
403
+ waypoints[axis] = $.map(arr, function(waypoint) {
404
+ return waypoint.element;
405
+ });
406
+ return waypoints[axis] = $.unique(waypoints[axis]);
407
+ });
408
+ return waypoints;
409
+ },
410
+ above: function(contextSelector) {
411
+ if (contextSelector == null) {
412
+ contextSelector = window;
413
+ }
414
+ return jQMethods._filter(contextSelector, 'vertical', function(context, waypoint) {
415
+ return waypoint.offset <= context.oldScroll.y;
416
+ });
417
+ },
418
+ below: function(contextSelector) {
419
+ if (contextSelector == null) {
420
+ contextSelector = window;
421
+ }
422
+ return jQMethods._filter(contextSelector, 'vertical', function(context, waypoint) {
423
+ return waypoint.offset > context.oldScroll.y;
424
+ });
425
+ },
426
+ left: function(contextSelector) {
427
+ if (contextSelector == null) {
428
+ contextSelector = window;
429
+ }
430
+ return jQMethods._filter(contextSelector, 'horizontal', function(context, waypoint) {
431
+ return waypoint.offset <= context.oldScroll.x;
432
+ });
433
+ },
434
+ right: function(contextSelector) {
435
+ if (contextSelector == null) {
436
+ contextSelector = window;
437
+ }
438
+ return jQMethods._filter(contextSelector, 'horizontal', function(context, waypoint) {
439
+ return waypoint.offset > context.oldScroll.x;
440
+ });
441
+ },
442
+ enable: function() {
443
+ return jQMethods._invoke('enable');
444
+ },
445
+ disable: function() {
446
+ return jQMethods._invoke('disable');
447
+ },
448
+ destroy: function() {
449
+ return jQMethods._invoke('destroy');
450
+ },
451
+ extendFn: function(methodName, f) {
452
+ return methods[methodName] = f;
453
+ },
454
+ _invoke: function(method) {
455
+ var waypoints;
456
+ waypoints = $.extend({}, allWaypoints.vertical, allWaypoints.horizontal);
457
+ return $.each(waypoints, function(key, waypoint) {
458
+ waypoint[method]();
459
+ return true;
460
+ });
461
+ },
462
+ _filter: function(selector, axis, test) {
463
+ var context, waypoints;
464
+ context = contexts[$(selector).data(contextKey)];
465
+ if (!context) {
466
+ return [];
467
+ }
468
+ waypoints = [];
469
+ $.each(context.waypoints[axis], function(i, waypoint) {
470
+ if (test(context, waypoint)) {
471
+ return waypoints.push(waypoint);
472
+ }
473
+ });
474
+ waypoints.sort(function(a, b) {
475
+ return a.offset - b.offset;
476
+ });
477
+ return $.map(waypoints, function(waypoint) {
478
+ return waypoint.element;
479
+ });
480
+ }
481
+ };
482
+ $[wps] = function() {
483
+ var args, method;
484
+ method = arguments[0], args = 2 <= arguments.length ? __slice.call(arguments, 1) : [];
485
+ if (jQMethods[method]) {
486
+ return jQMethods[method].apply(null, args);
487
+ } else {
488
+ return jQMethods.aggregate.call(null, method);
489
+ }
490
+ };
491
+ $[wps].settings = {
492
+ resizeThrottle: 100,
493
+ scrollThrottle: 30
494
+ };
495
+ return $w.load(function() {
496
+ return $[wps]('refresh');
497
  });
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
498
  });
 
499
 
500
  }).call(this);
501
 
includes/addons/accordion/class-lvca-accordion.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Accordion
5
  Description: Displays collapsible content panels to help display information when space is limited.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -90,12 +90,12 @@ class LVCA_Accordion {
90
 
91
  //Register "container" content element. It will hold all your inner (child) content elements
92
  vc_map(array(
93
- "name" => __("Livemesh Accordion", "livemesh-vc-addons"),
94
  "base" => "lvca_accordion",
95
  "as_parent" => array('only' => 'lvca_panel'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
96
  "content_element" => true,
97
  "show_settings_on_create" => false,
98
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
99
  "is_container" => true,
100
  'description' => __('Display collapsible content panels.', 'livemesh-vc-addons'),
101
  "js_view" => 'VcColumnView',
@@ -134,7 +134,7 @@ class LVCA_Accordion {
134
  function map_child_vc_element() {
135
  if (function_exists("vc_map")) {
136
  vc_map(array(
137
- "name" => __("Livemesh Panel", "my-text-domain"),
138
  "base" => "lvca_panel",
139
  "content_element" => true,
140
  "as_child" => array('only' => 'lvca_accordion'), // Use only|except attributes to limit parent (separate multiple values with comma)
1
  <?php
2
 
3
  /*
4
+ Widget Name: Accordion
5
  Description: Displays collapsible content panels to help display information when space is limited.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
90
 
91
  //Register "container" content element. It will hold all your inner (child) content elements
92
  vc_map(array(
93
+ "name" => __("Accordion", "livemesh-vc-addons"),
94
  "base" => "lvca_accordion",
95
  "as_parent" => array('only' => 'lvca_panel'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
96
  "content_element" => true,
97
  "show_settings_on_create" => false,
98
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
99
  "is_container" => true,
100
  'description' => __('Display collapsible content panels.', 'livemesh-vc-addons'),
101
  "js_view" => 'VcColumnView',
134
  function map_child_vc_element() {
135
  if (function_exists("vc_map")) {
136
  vc_map(array(
137
+ "name" => __("Panel", "my-text-domain"),
138
  "base" => "lvca_panel",
139
  "content_element" => true,
140
  "as_child" => array('only' => 'lvca_accordion'), // Use only|except attributes to limit parent (separate multiple values with comma)
includes/addons/carousel/class-lvca-carousel.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Carousel
5
  Description: Display a list of custom HTML content as a carousel.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -107,14 +107,14 @@ class LVCA_Carousel {
107
 
108
  //Register "container" content element. It will hold all your inner (child) content elements
109
  vc_map(array(
110
- "name" => __("Livemesh Carousel", "livemesh-vc-addons"),
111
  "base" => "lvca_carousel",
112
  "as_parent" => array('only' => 'lvca_carousel_item'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
113
  "content_element" => true,
114
  "show_settings_on_create" => true,
115
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
116
  "is_container" => true,
117
- 'description' => __('Display a carousel of html elements.', 'livemesh-vc-addons'),
118
  "js_view" => 'VcColumnView',
119
  "icon" => 'icon-lvca-carousel',
120
  "params" => $carousel_params
@@ -129,12 +129,12 @@ class LVCA_Carousel {
129
  if (function_exists("vc_map")) {
130
 
131
  vc_map(array(
132
- "name" => __("Livemesh Carousel", "livemesh-vc-addons"),
133
  "base" => "lvca_carousel_item",
134
  "content_element" => true,
135
  "as_child" => array('only' => 'lvca_carousel'), // Use only|except attributes to limit parent (separate multiple values with comma)
136
  "icon" => 'icon-lvca-carousel-item',
137
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
138
  "params" => array(
139
  array(
140
  'type' => 'textfield',
1
  <?php
2
 
3
  /*
4
+ Widget Name: Carousel
5
  Description: Display a list of custom HTML content as a carousel.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
107
 
108
  //Register "container" content element. It will hold all your inner (child) content elements
109
  vc_map(array(
110
+ "name" => __("Carousel", "livemesh-vc-addons"),
111
  "base" => "lvca_carousel",
112
  "as_parent" => array('only' => 'lvca_carousel_item'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
113
  "content_element" => true,
114
  "show_settings_on_create" => true,
115
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
116
  "is_container" => true,
117
+ 'description' => __('Display a carousel of HTML elements.', 'livemesh-vc-addons'),
118
  "js_view" => 'VcColumnView',
119
  "icon" => 'icon-lvca-carousel',
120
  "params" => $carousel_params
129
  if (function_exists("vc_map")) {
130
 
131
  vc_map(array(
132
+ "name" => __("Carousel", "livemesh-vc-addons"),
133
  "base" => "lvca_carousel_item",
134
  "content_element" => true,
135
  "as_child" => array('only' => 'lvca_carousel'), // Use only|except attributes to limit parent (separate multiple values with comma)
136
  "icon" => 'icon-lvca-carousel-item',
137
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
138
  "params" => array(
139
  array(
140
  'type' => 'textfield',
includes/addons/clients/class-lvca-clients.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Clients
5
  Description: Display list of your clients in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -112,12 +112,12 @@ class LVCA_Clients {
112
 
113
  //Register "container" content element. It will hold all your inner (child) content elements
114
  vc_map(array(
115
- "name" => __("Livemesh Clients", "livemesh-vc-addons"),
116
  "base" => "lvca_clients",
117
  "as_parent" => array('only' => 'lvca_single_client'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
118
  "content_element" => true,
119
  "show_settings_on_create" => true,
120
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
121
  "is_container" => true,
122
  'description' => __('Display clients in a multi-column grid.', 'livemesh-vc-addons'),
123
  "js_view" => 'VcColumnView',
@@ -145,7 +145,7 @@ class LVCA_Clients {
145
  function map_child_vc_element() {
146
  if (function_exists("vc_map")) {
147
  vc_map(array(
148
- "name" => __("Livemesh Client", "my-text-domain"),
149
  "base" => "lvca_single_client",
150
  "content_element" => true,
151
  "as_child" => array('only' => 'lvca_clients'), // Use only|except attributes to limit parent (separate multiple values with comma)
1
  <?php
2
 
3
  /*
4
+ Widget Name: Clients
5
  Description: Display list of your clients in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
112
 
113
  //Register "container" content element. It will hold all your inner (child) content elements
114
  vc_map(array(
115
+ "name" => __("Clients", "livemesh-vc-addons"),
116
  "base" => "lvca_clients",
117
  "as_parent" => array('only' => 'lvca_single_client'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
118
  "content_element" => true,
119
  "show_settings_on_create" => true,
120
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
121
  "is_container" => true,
122
  'description' => __('Display clients in a multi-column grid.', 'livemesh-vc-addons'),
123
  "js_view" => 'VcColumnView',
145
  function map_child_vc_element() {
146
  if (function_exists("vc_map")) {
147
  vc_map(array(
148
+ "name" => __("Client", "my-text-domain"),
149
  "base" => "lvca_single_client",
150
  "content_element" => true,
151
  "as_child" => array('only' => 'lvca_clients'), // Use only|except attributes to limit parent (separate multiple values with comma)
includes/addons/heading/class-lvca-heading.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Heading
5
  Description: Create heading for display on the top of a section.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -76,11 +76,11 @@ class LVCA_Heading {
76
 
77
  //Register "container" content element. It will hold all your inner (child) content elements
78
  vc_map(array(
79
- "name" => __("Livemesh Heading", "livemesh-vc-addons"),
80
  "base" => "lvca_heading",
81
  "content_element" => true,
82
  "show_settings_on_create" => true,
83
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
84
  'description' => __('Create heading for a section.', 'livemesh-vc-addons'),
85
  "icon" => 'icon-lvca-heading',
86
  "params" => array(
1
  <?php
2
 
3
  /*
4
+ Widget Name: Heading
5
  Description: Create heading for display on the top of a section.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
76
 
77
  //Register "container" content element. It will hold all your inner (child) content elements
78
  vc_map(array(
79
+ "name" => __("Heading", "livemesh-vc-addons"),
80
  "base" => "lvca_heading",
81
  "content_element" => true,
82
  "show_settings_on_create" => true,
83
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
84
  'description' => __('Create heading for a section.', 'livemesh-vc-addons'),
85
  "icon" => 'icon-lvca-heading',
86
  "params" => array(
includes/addons/odometers/class-lvca-odometers.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Odometers
5
  Description: Display one or more animated odometer statistics in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -146,12 +146,12 @@ class LVCA_Odometers {
146
 
147
  //Register "container" content element. It will hold all your inner (child) content elements
148
  vc_map(array(
149
- "name" => __("Livemesh Odometers", "livemesh-vc-addons"),
150
  "base" => "lvca_odometers",
151
  "as_parent" => array('only' => 'lvca_odometer_item'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
152
  "content_element" => true,
153
  "show_settings_on_create" => true,
154
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
155
  "is_container" => true,
156
  'description' => __('Display odometers in a multi-column grid.', 'livemesh-vc-addons'),
157
  "js_view" => 'VcColumnView',
@@ -179,7 +179,7 @@ class LVCA_Odometers {
179
  function map_child_vc_element() {
180
  if (function_exists("vc_map")) {
181
  vc_map(array(
182
- "name" => __("Livemesh Odometer", "my-text-domain"),
183
  "base" => "lvca_odometer_item",
184
  "content_element" => true,
185
  "as_child" => array('only' => 'lvca_odometers'), // Use only|except attributes to limit parent (separate multiple values with comma)
1
  <?php
2
 
3
  /*
4
+ Widget Name: Odometers
5
  Description: Display one or more animated odometer statistics in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
146
 
147
  //Register "container" content element. It will hold all your inner (child) content elements
148
  vc_map(array(
149
+ "name" => __("Odometers", "livemesh-vc-addons"),
150
  "base" => "lvca_odometers",
151
  "as_parent" => array('only' => 'lvca_odometer_item'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
152
  "content_element" => true,
153
  "show_settings_on_create" => true,
154
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
155
  "is_container" => true,
156
  'description' => __('Display odometers in a multi-column grid.', 'livemesh-vc-addons'),
157
  "js_view" => 'VcColumnView',
179
  function map_child_vc_element() {
180
  if (function_exists("vc_map")) {
181
  vc_map(array(
182
+ "name" => __("Odometer", "my-text-domain"),
183
  "base" => "lvca_odometer_item",
184
  "content_element" => true,
185
  "as_child" => array('only' => 'lvca_odometers'), // Use only|except attributes to limit parent (separate multiple values with comma)
includes/addons/odometers/js/odometer.min.js CHANGED
@@ -1 +1 @@
1
- jQuery(function(t){t(".lvca-odometers").waypoint(function(e){t(this).find(".lvca-odometer .lvca-number").each(function(){var e=t(this);setTimeout(function(){var o=e.attr("data-stop");t(e).text(o)},100)})},{offset:t.waypoints("viewportHeight")-100,triggerOnce:!0})});
1
+ jQuery(function($){$(".lvca-odometers").waypoint(function(direction){$(this).find(".lvca-odometer .lvca-number").each(function(){var odometer=$(this);setTimeout(function(){var data_stop=odometer.attr("data-stop");$(odometer).text(data_stop)},100)})},{offset:$.waypoints("viewportHeight")-100,triggerOnce:true})});
includes/addons/piecharts/class-lvca-piecharts.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Piecharts
5
  Description: Display one or more piecharts depicting a percentage value in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -115,12 +115,12 @@ class LVCA_Piecharts {
115
 
116
  //Register "container" content element. It will hold all your inner (child) content elements
117
  vc_map(array(
118
- "name" => __("Livemesh Piecharts", "livemesh-vc-addons"),
119
  "base" => "lvca_piecharts",
120
  "as_parent" => array('only' => 'lvca_piechart_item'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
121
  "content_element" => true,
122
  "show_settings_on_create" => true,
123
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
124
  "is_container" => true,
125
  'description' => __('Display piecharts in a multi-column grid.', 'livemesh-vc-addons'),
126
  "js_view" => 'VcColumnView',
@@ -161,7 +161,7 @@ class LVCA_Piecharts {
161
  function map_child_vc_element() {
162
  if (function_exists("vc_map")) {
163
  vc_map(array(
164
- "name" => __("Livemesh Pierchart", "my-text-domain"),
165
  "base" => "lvca_piechart_item",
166
  "content_element" => true,
167
  "as_child" => array('only' => 'lvca_piecharts'), // Use only|except attributes to limit parent (separate multiple values with comma)
1
  <?php
2
 
3
  /*
4
+ Widget Name: Piecharts
5
  Description: Display one or more piecharts depicting a percentage value in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
115
 
116
  //Register "container" content element. It will hold all your inner (child) content elements
117
  vc_map(array(
118
+ "name" => __("Piecharts", "livemesh-vc-addons"),
119
  "base" => "lvca_piecharts",
120
  "as_parent" => array('only' => 'lvca_piechart_item'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
121
  "content_element" => true,
122
  "show_settings_on_create" => true,
123
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
124
  "is_container" => true,
125
  'description' => __('Display piecharts in a multi-column grid.', 'livemesh-vc-addons'),
126
  "js_view" => 'VcColumnView',
161
  function map_child_vc_element() {
162
  if (function_exists("vc_map")) {
163
  vc_map(array(
164
+ "name" => __("Pierchart", "my-text-domain"),
165
  "base" => "lvca_piechart_item",
166
  "content_element" => true,
167
  "as_child" => array('only' => 'lvca_piecharts'), // Use only|except attributes to limit parent (separate multiple values with comma)
includes/addons/piecharts/js/piechart.min.js CHANGED
@@ -1 +1 @@
1
- jQuery(function(a){a(".lvca-piecharts").waypoint(function(t){a(this).find(".lvca-piechart .lvca-percentage").each(function(){var t=a(this).data("track-color"),e=a(this).data("bar-color");a(this).easyPieChart({animate:2e3,lineWidth:5,barColor:e,trackColor:t,scaleColor:!1,lineCap:"square",size:220})})},{offset:a.waypoints("viewportHeight")-100,triggerOnce:!0})});
1
+ jQuery(function($){$(".lvca-piecharts").waypoint(function(direction){$(this).find(".lvca-piechart .lvca-percentage").each(function(){var track_color=$(this).data("track-color");var bar_color=$(this).data("bar-color");$(this).easyPieChart({animate:2e3,lineWidth:5,barColor:bar_color,trackColor:track_color,scaleColor:false,lineCap:"square",size:220})})},{offset:$.waypoints("viewportHeight")-100,triggerOnce:true})});
includes/addons/portfolio/class-lvca-portfolio.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Grid
5
  Description: Display posts or custom post types in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -46,14 +46,14 @@ class LVCA_Portfolio {
46
  $chosen_terms[] = get_term($term_id, 'post_tag');
47
  }
48
  }
49
- elseif (!empty($query_args['tax_query'])) {
50
- $terms_query = $query_args['tax_query'];
51
- foreach ($terms_query as $term_query) {
52
- if (is_array($term_query) && ($term_query['field'] == 'term_id')) {
53
- $chosen_terms[] = get_term($term_query['terms'], $term_query['taxonomy']);
54
- $this->_taxonomy_filter = $term_query['taxonomy'];
55
- }
56
  }
 
57
  }
58
  return $chosen_terms;
59
  }
@@ -475,12 +475,12 @@ class LVCA_Portfolio {
475
 
476
  //Register "container" content element. It will hold all your inner (child) content elements
477
  vc_map(array(
478
- "name" => __("Livemesh Grid", "livemesh-vc-addons"),
479
  "base" => "lvca_portfolio",
480
  "content_element" => true,
481
  "show_settings_on_create" => true,
482
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
483
- 'description' => __('Display work or posts with a filterable grid.', 'livemesh-vc-addons'),
484
  "icon" => 'icon-lvca-portfolio',
485
  "params" => $params
486
  ));
1
  <?php
2
 
3
  /*
4
+ Widget Name: Posts Grid
5
  Description: Display posts or custom post types in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
46
  $chosen_terms[] = get_term($term_id, 'post_tag');
47
  }
48
  }
49
+ elseif (isset($query_args['tax_query'][0])) {
50
+ $terms_query = $query_args['tax_query'][0];
51
+ $taxonomy_filter = $terms_query['taxonomy'];
52
+ $terms = $terms_query['terms'];
53
+ foreach ($terms as $term_id) {
54
+ $chosen_terms[] = get_term_by('id', $term_id, $taxonomy_filter);
 
55
  }
56
+ $this->_taxonomy_filter = $taxonomy_filter;
57
  }
58
  return $chosen_terms;
59
  }
475
 
476
  //Register "container" content element. It will hold all your inner (child) content elements
477
  vc_map(array(
478
+ "name" => __("Posts Grid", "livemesh-vc-addons"),
479
  "base" => "lvca_portfolio",
480
  "content_element" => true,
481
  "show_settings_on_create" => true,
482
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
483
+ 'description' => __('Display posts or post types with a filterable grid.', 'livemesh-vc-addons'),
484
  "icon" => 'icon-lvca-portfolio',
485
  "params" => $params
486
  ));
includes/addons/posts-carousel/class-lvca-posts-carousel.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Posts Carousel
5
  Description: Display blog posts or custom post types as a carousel.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -287,11 +287,11 @@ class LVCA_Posts_Carousel {
287
 
288
  //Register "container" content element. It will hold all your inner (child) content elements
289
  vc_map(array(
290
- "name" => __("Livemesh Posts Carousel", "livemesh-vc-addons"),
291
  "base" => "lvca_posts_carousel",
292
  "content_element" => true,
293
  "show_settings_on_create" => true,
294
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
295
  'description' => __('Display posts or post types as a carousel.', 'livemesh-vc-addons'),
296
  "icon" => 'icon-lvca-posts-carousel',
297
  "params" => $carousel_params
1
  <?php
2
 
3
  /*
4
+ Widget Name: Posts Carousel
5
  Description: Display blog posts or custom post types as a carousel.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
287
 
288
  //Register "container" content element. It will hold all your inner (child) content elements
289
  vc_map(array(
290
+ "name" => __("Posts Carousel", "livemesh-vc-addons"),
291
  "base" => "lvca_posts_carousel",
292
  "content_element" => true,
293
  "show_settings_on_create" => true,
294
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
295
  'description' => __('Display posts or post types as a carousel.', 'livemesh-vc-addons'),
296
  "icon" => 'icon-lvca-posts-carousel',
297
  "params" => $carousel_params
includes/addons/pricing-table/class-lvca-pricing-table.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Pricing Table
5
  Description: Display pricing plans in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -191,12 +191,12 @@ class LVCA_Pricing_Table {
191
 
192
  //Register "container" content element. It will hold all your inner (child) content elements
193
  vc_map(array(
194
- "name" => __("Livemesh Pricing Table", "livemesh-vc-addons"),
195
  "base" => "lvca_pricing_table",
196
  "as_parent" => array('only' => 'lvca_pricing_plan'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
197
  "content_element" => true,
198
  "show_settings_on_create" => true,
199
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
200
  "is_container" => true,
201
  'description' => __('Display pricing table in a multi-column grid.', 'livemesh-vc-addons'),
202
  "js_view" => 'VcColumnView',
@@ -224,7 +224,7 @@ class LVCA_Pricing_Table {
224
  function map_child_vc_element() {
225
  if (function_exists("vc_map")) {
226
  vc_map(array(
227
- "name" => __("Livemesh Pricing Plan", "my-text-domain"),
228
  "base" => "lvca_pricing_plan",
229
  "content_element" => true,
230
  "as_child" => array('only' => 'lvca_pricing_table'), // Use only|except attributes to limit parent (separate multiple values with comma)
1
  <?php
2
 
3
  /*
4
+ Widget Name: Pricing Table
5
  Description: Display pricing plans in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
191
 
192
  //Register "container" content element. It will hold all your inner (child) content elements
193
  vc_map(array(
194
+ "name" => __("Pricing Table", "livemesh-vc-addons"),
195
  "base" => "lvca_pricing_table",
196
  "as_parent" => array('only' => 'lvca_pricing_plan'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
197
  "content_element" => true,
198
  "show_settings_on_create" => true,
199
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
200
  "is_container" => true,
201
  'description' => __('Display pricing table in a multi-column grid.', 'livemesh-vc-addons'),
202
  "js_view" => 'VcColumnView',
224
  function map_child_vc_element() {
225
  if (function_exists("vc_map")) {
226
  vc_map(array(
227
+ "name" => __("Pricing Plan", "my-text-domain"),
228
  "base" => "lvca_pricing_plan",
229
  "content_element" => true,
230
  "as_child" => array('only' => 'lvca_pricing_table'), // Use only|except attributes to limit parent (separate multiple values with comma)
includes/addons/services/class-lvca-services.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Services
5
  Description: Capture services in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -145,12 +145,12 @@ class LVCA_Services {
145
 
146
  //Register "container" content element. It will hold all your inner (child) content elements
147
  vc_map(array(
148
- "name" => __("Livemesh Services", "livemesh-vc-addons"),
149
  "base" => "lvca_services",
150
  "as_parent" => array('only' => 'lvca_service_item'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
151
  "content_element" => true,
152
  "show_settings_on_create" => true,
153
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
154
  "is_container" => true,
155
  'description' => __('Display services in a column grid.', 'livemesh-vc-addons'),
156
  "js_view" => 'VcColumnView',
@@ -190,7 +190,7 @@ class LVCA_Services {
190
  function map_child_vc_element() {
191
  if (function_exists("vc_map")) {
192
  vc_map(array(
193
- "name" => __("Livemesh Service", "my-text-domain"),
194
  "base" => "lvca_service_item",
195
  "content_element" => true,
196
  "as_child" => array('only' => 'lvca_services'), // Use only|except attributes to limit parent (separate multiple values with comma)
1
  <?php
2
 
3
  /*
4
+ Widget Name: Services
5
  Description: Capture services in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
145
 
146
  //Register "container" content element. It will hold all your inner (child) content elements
147
  vc_map(array(
148
+ "name" => __("Services", "livemesh-vc-addons"),
149
  "base" => "lvca_services",
150
  "as_parent" => array('only' => 'lvca_service_item'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
151
  "content_element" => true,
152
  "show_settings_on_create" => true,
153
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
154
  "is_container" => true,
155
  'description' => __('Display services in a column grid.', 'livemesh-vc-addons'),
156
  "js_view" => 'VcColumnView',
190
  function map_child_vc_element() {
191
  if (function_exists("vc_map")) {
192
  vc_map(array(
193
+ "name" => __("Service", "my-text-domain"),
194
  "base" => "lvca_service_item",
195
  "content_element" => true,
196
  "as_child" => array('only' => 'lvca_services'), // Use only|except attributes to limit parent (separate multiple values with comma)
includes/addons/spacer/class-lvca-spacer.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Spacer
5
  Description: Add spacer between rows and elements that changes based on device resolution.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -63,11 +63,11 @@ class LVCA_Spacer {
63
 
64
  //Register "container" content element. It will hold all your inner (child) content elements
65
  vc_map(array(
66
- "name" => __("Livemesh Spacer", "livemesh-vc-addons"),
67
  "base" => "lvca_spacer",
68
  "content_element" => true,
69
  "show_settings_on_create" => false,
70
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
71
  'description' => __('Add spacer between rows and elements.', 'livemesh-vc-addons'),
72
  "icon" => 'icon-lvca-spacer',
73
  "params" => array(
1
  <?php
2
 
3
  /*
4
+ Widget Name: Spacer
5
  Description: Add spacer between rows and elements that changes based on device resolution.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
63
 
64
  //Register "container" content element. It will hold all your inner (child) content elements
65
  vc_map(array(
66
+ "name" => __("Spacer", "livemesh-vc-addons"),
67
  "base" => "lvca_spacer",
68
  "content_element" => true,
69
  "show_settings_on_create" => false,
70
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
71
  'description' => __('Add spacer between rows and elements.', 'livemesh-vc-addons'),
72
  "icon" => 'icon-lvca-spacer',
73
  "params" => array(
includes/addons/stats-bar/class-lvca-stats-bar.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Stats Bars
5
  Description: Display multiple stats bars that talk about skills or other percentage stats.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -111,12 +111,12 @@ class LVCA_Stats_Bars {
111
 
112
  //Register "container" content element. It will hold all your inner (child) content elements
113
  vc_map(array(
114
- "name" => __("Livemesh Stats Bars", "livemesh-vc-addons"),
115
  "base" => "lvca_statsbars",
116
  "as_parent" => array('only' => 'lvca_statsbar_item'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
117
  "content_element" => true,
118
  "show_settings_on_create" => false,
119
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
120
  "is_container" => true,
121
  'description' => __('Display stats bars of skills or percentage stats.', 'livemesh-vc-addons'),
122
  "js_view" => 'VcColumnView',
@@ -141,7 +141,7 @@ class LVCA_Stats_Bars {
141
  function map_child_vc_element() {
142
  if (function_exists("vc_map")) {
143
  vc_map(array(
144
- "name" => __("Livemesh Stats Bar", "my-text-domain"),
145
  "base" => "lvca_statsbar_item",
146
  "content_element" => true,
147
  "as_child" => array('only' => 'lvca_statsbars'), // Use only|except attributes to limit parent (separate multiple values with comma)
1
  <?php
2
 
3
  /*
4
+ Widget Name: Stats Bars
5
  Description: Display multiple stats bars that talk about skills or other percentage stats.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
111
 
112
  //Register "container" content element. It will hold all your inner (child) content elements
113
  vc_map(array(
114
+ "name" => __("Stats Bars", "livemesh-vc-addons"),
115
  "base" => "lvca_statsbars",
116
  "as_parent" => array('only' => 'lvca_statsbar_item'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
117
  "content_element" => true,
118
  "show_settings_on_create" => false,
119
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
120
  "is_container" => true,
121
  'description' => __('Display stats bars of skills or percentage stats.', 'livemesh-vc-addons'),
122
  "js_view" => 'VcColumnView',
141
  function map_child_vc_element() {
142
  if (function_exists("vc_map")) {
143
  vc_map(array(
144
+ "name" => __("Stats Bar", "my-text-domain"),
145
  "base" => "lvca_statsbar_item",
146
  "content_element" => true,
147
  "as_child" => array('only' => 'lvca_statsbars'), // Use only|except attributes to limit parent (separate multiple values with comma)
includes/addons/stats-bar/js/stats-bar.min.js CHANGED
@@ -1 +1 @@
1
- jQuery(function(t){t(".lvca-stats-bars").waypoint(function(a){t(this).find(".lvca-stats-bar-content").each(function(){var a=t(this).attr("data-perc");t(this).animate({width:a+"%"},20*a)})},{offset:t.waypoints("viewportHeight")-150,triggerOnce:!0})});
1
+ jQuery(function($){$(".lvca-stats-bars").waypoint(function(direction){$(this).find(".lvca-stats-bar-content").each(function(){var dataperc=$(this).attr("data-perc");$(this).animate({width:dataperc+"%"},dataperc*20)})},{offset:$.waypoints("viewportHeight")-150,triggerOnce:true})});
includes/addons/tabs/class-lvca-tabs.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Tabs
5
  Description: Display tabbed content in variety of styles.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -225,12 +225,12 @@ class LVCA_Tabs {
225
 
226
  //Register "container" content element. It will hold all your inner (child) content elements
227
  vc_map(array(
228
- "name" => __("Livemesh Tabs", "livemesh-vc-addons"),
229
  "base" => "lvca_tabs",
230
  "as_parent" => array('only' => 'lvca_tab'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
231
  "content_element" => true,
232
  "show_settings_on_create" => false,
233
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
234
  "is_container" => true,
235
  'description' => __('Display tabbed content in variety of styles.', 'livemesh-vc-addons'),
236
  "js_view" => 'VcColumnView',
@@ -290,7 +290,7 @@ class LVCA_Tabs {
290
  function map_child_vc_element() {
291
  if (function_exists("vc_map")) {
292
  vc_map(array(
293
- "name" => __("Livemesh Tab", "my-text-domain"),
294
  "base" => "lvca_tab",
295
  "content_element" => true,
296
  "as_child" => array('only' => 'lvca_tabs'), // Use only|except attributes to limit parent (separate multiple values with comma)
1
  <?php
2
 
3
  /*
4
+ Widget Name: Tabs
5
  Description: Display tabbed content in variety of styles.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
225
 
226
  //Register "container" content element. It will hold all your inner (child) content elements
227
  vc_map(array(
228
+ "name" => __("Tabs", "livemesh-vc-addons"),
229
  "base" => "lvca_tabs",
230
  "as_parent" => array('only' => 'lvca_tab'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
231
  "content_element" => true,
232
  "show_settings_on_create" => false,
233
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
234
  "is_container" => true,
235
  'description' => __('Display tabbed content in variety of styles.', 'livemesh-vc-addons'),
236
  "js_view" => 'VcColumnView',
290
  function map_child_vc_element() {
291
  if (function_exists("vc_map")) {
292
  vc_map(array(
293
+ "name" => __("Tab", "my-text-domain"),
294
  "base" => "lvca_tab",
295
  "content_element" => true,
296
  "as_child" => array('only' => 'lvca_tabs'), // Use only|except attributes to limit parent (separate multiple values with comma)
includes/addons/team/class-lvca-team.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Team Members
5
  Description: Display a list of your team members optionally in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -164,12 +164,12 @@ class LVCA_Team {
164
 
165
  //Register "container" content element. It will hold all your inner (child) content elements
166
  vc_map(array(
167
- "name" => __("Livemesh Team", "livemesh-vc-addons"),
168
  "base" => "lvca_team",
169
  "as_parent" => array('only' => 'lvca_team_member'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
170
  "content_element" => true,
171
  "show_settings_on_create" => true,
172
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
173
  "is_container" => true,
174
  'description' => __('Create team members.', 'livemesh-vc-addons'),
175
  "js_view" => 'VcColumnView',
@@ -212,12 +212,12 @@ class LVCA_Team {
212
  function map_child_vc_element() {
213
  if (function_exists("vc_map")) {
214
  vc_map(array(
215
- "name" => __("Livemesh Team Member", "my-text-domain"),
216
  "base" => "lvca_team_member",
217
  "content_element" => true,
218
  "as_child" => array('only' => 'lvca_team'), // Use only|except attributes to limit parent (separate multiple values with comma)
219
  "icon" => 'icon-lvca-team-member',
220
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
221
  "params" => array(
222
  // add params same as with any other content element
223
  array(
1
  <?php
2
 
3
  /*
4
+ Widget Name: Team Members
5
  Description: Display a list of your team members optionally in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
164
 
165
  //Register "container" content element. It will hold all your inner (child) content elements
166
  vc_map(array(
167
+ "name" => __("Team Members", "livemesh-vc-addons"),
168
  "base" => "lvca_team",
169
  "as_parent" => array('only' => 'lvca_team_member'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
170
  "content_element" => true,
171
  "show_settings_on_create" => true,
172
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
173
  "is_container" => true,
174
  'description' => __('Create team members.', 'livemesh-vc-addons'),
175
  "js_view" => 'VcColumnView',
212
  function map_child_vc_element() {
213
  if (function_exists("vc_map")) {
214
  vc_map(array(
215
+ "name" => __("Team Member", "my-text-domain"),
216
  "base" => "lvca_team_member",
217
  "content_element" => true,
218
  "as_child" => array('only' => 'lvca_team'), // Use only|except attributes to limit parent (separate multiple values with comma)
219
  "icon" => 'icon-lvca-team-member',
220
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
221
  "params" => array(
222
  // add params same as with any other content element
223
  array(
includes/addons/testimonials-slider/class-lvca-testimonials-slider.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Testimonials Slider
5
  Description: Display responsive touch friendly slider of testimonials from clients/customers.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -139,12 +139,12 @@ class LVCA_Testimonials_Slider {
139
 
140
  //Register "container" content element. It will hold all your inner (child) content elements
141
  vc_map(array(
142
- "name" => __("Livemesh Testimonials Slider", "livemesh-vc-addons"),
143
  "base" => "lvca_testimonials_slider",
144
  "as_parent" => array('only' => 'lvca_testimonial_slide'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
145
  "content_element" => true,
146
  "show_settings_on_create" => true,
147
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
148
  "is_container" => true,
149
  'description' => __('Capture client testimonials in a slider.', 'livemesh-vc-addons'),
150
  "js_view" => 'VcColumnView',
@@ -210,12 +210,12 @@ class LVCA_Testimonials_Slider {
210
  $testimonial_params = vc_map_integrate_shortcode('lvca_testimonial', '', __('Testimonials', 'livemesh-vc-addons'));
211
 
212
  vc_map(array(
213
- "name" => __("Livemesh Testimonial Slide", "livemesh-vc-addons"),
214
  "base" => "lvca_testimonial_slide",
215
  "content_element" => true,
216
  "as_child" => array('only' => 'lvca_testimonials_slider'), // Use only|except attributes to limit parent (separate multiple values with comma)
217
  "icon" => 'icon-lvca-testimonials-slide',
218
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
219
  "params" => $testimonial_params
220
  )
221
 
1
  <?php
2
 
3
  /*
4
+ Widget Name: Testimonials Slider
5
  Description: Display responsive touch friendly slider of testimonials from clients/customers.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
139
 
140
  //Register "container" content element. It will hold all your inner (child) content elements
141
  vc_map(array(
142
+ "name" => __("Testimonials Slider", "livemesh-vc-addons"),
143
  "base" => "lvca_testimonials_slider",
144
  "as_parent" => array('only' => 'lvca_testimonial_slide'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
145
  "content_element" => true,
146
  "show_settings_on_create" => true,
147
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
148
  "is_container" => true,
149
  'description' => __('Capture client testimonials in a slider.', 'livemesh-vc-addons'),
150
  "js_view" => 'VcColumnView',
210
  $testimonial_params = vc_map_integrate_shortcode('lvca_testimonial', '', __('Testimonials', 'livemesh-vc-addons'));
211
 
212
  vc_map(array(
213
+ "name" => __("Testimonial Slide", "livemesh-vc-addons"),
214
  "base" => "lvca_testimonial_slide",
215
  "content_element" => true,
216
  "as_child" => array('only' => 'lvca_testimonials_slider'), // Use only|except attributes to limit parent (separate multiple values with comma)
217
  "icon" => 'icon-lvca-testimonials-slide',
218
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
219
  "params" => $testimonial_params
220
  )
221
 
includes/addons/testimonials/class-lvca-testimonials.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  /*
4
- Widget Name: Livemesh Testimonials
5
  Description: Display testimonials from your clients/customers in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
@@ -115,12 +115,12 @@ class LVCA_Testimonials {
115
 
116
  //Register "container" content element. It will hold all your inner (child) content elements
117
  vc_map(array(
118
- "name" => __("Livemesh Testimonials", "livemesh-vc-addons"),
119
  "base" => "lvca_testimonials",
120
  "as_parent" => array('only' => 'lvca_testimonial'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
121
  "content_element" => true,
122
  "show_settings_on_create" => true,
123
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
124
  "is_container" => true,
125
  'description' => __('Display testimonials in a multi-column grid.', 'livemesh-vc-addons'),
126
  "js_view" => 'VcColumnView',
@@ -147,12 +147,12 @@ class LVCA_Testimonials {
147
  function map_child_vc_element() {
148
  if (function_exists("vc_map")) {
149
  vc_map(array(
150
- "name" => __("Livemesh Testimonial", "my-text-domain"),
151
  "base" => "lvca_testimonial",
152
  "content_element" => true,
153
  "as_child" => array('only' => 'lvca_testimonials'), // Use only|except attributes to limit parent (separate multiple values with comma)
154
  "icon" => 'icon-lvca-testimonial',
155
- "category" => __("Livemesh VC Addons", "livemesh-vc-addons"),
156
  "params" => array(
157
  // add params same as with any other content element
158
  array(
1
  <?php
2
 
3
  /*
4
+ Widget Name: Testimonials
5
  Description: Display testimonials from your clients/customers in a multi-column grid.
6
  Author: LiveMesh
7
  Author URI: https://www.livemeshthemes.com
115
 
116
  //Register "container" content element. It will hold all your inner (child) content elements
117
  vc_map(array(
118
+ "name" => __("Testimonials", "livemesh-vc-addons"),
119
  "base" => "lvca_testimonials",
120
  "as_parent" => array('only' => 'lvca_testimonial'), // Use only|except attributes to limit child shortcodes (separate multiple values with comma)
121
  "content_element" => true,
122
  "show_settings_on_create" => true,
123
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
124
  "is_container" => true,
125
  'description' => __('Display testimonials in a multi-column grid.', 'livemesh-vc-addons'),
126
  "js_view" => 'VcColumnView',
147
  function map_child_vc_element() {
148
  if (function_exists("vc_map")) {
149
  vc_map(array(
150
+ "name" => __("Testimonial", "my-text-domain"),
151
  "base" => "lvca_testimonial",
152
  "content_element" => true,
153
  "as_child" => array('only' => 'lvca_testimonials'), // Use only|except attributes to limit parent (separate multiple values with comma)
154
  "icon" => 'icon-lvca-testimonial',
155
+ "category" => __("Livemesh Addons", "livemesh-vc-addons"),
156
  "params" => array(
157
  // add params same as with any other content element
158
  array(
includes/interfaces.php CHANGED
@@ -3,7 +3,7 @@
3
  if ( ! defined( 'ABSPATH' ) ) exit;
4
 
5
  /**
6
- * Interface for VC addons
7
  */
8
  interface LVCA_Addon {
9
 
3
  if ( ! defined( 'ABSPATH' ) ) exit;
4
 
5
  /**
6
+ * Interface for WPBakery Page Builder Addons
7
  */
8
  interface LVCA_Addon {
9
 
livemesh-vc-addons.php CHANGED
@@ -1,28 +1,28 @@
1
  <?php
2
  /**
3
- * Plugin Name: Addons for Visual Composer
4
- * Plugin URI: https://www.livemeshthemes.com/visual-composer-addons
5
- * Description: A collection of premium quality addons or extensions for use in Visual Composer page builder. Visual composer must be installed and activated.
6
  * Author: Livemesh
7
- * Author URI: https://www.livemeshthemes.com/visual-composer-addons
8
  * License: GPL3
9
  * License URI: https://www.gnu.org/licenses/gpl-3.0.txt
10
- * Version: 1.8.2
11
  * Text Domain: livemesh-vc-addons
12
  * Domain Path: languages
13
  *
14
- * Addons for Visual Composer is free software: you can redistribute it and/or modify
15
  * it under the terms of the GNU General Public License as published by
16
  * the Free Software Foundation, either version 2 of the License, or
17
  * any later version.
18
  *
19
- * Addons for Visual Composer is distributed in the hope that it will be useful,
20
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
21
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22
  * GNU General Public License for more details.
23
  *
24
  * You should have received a copy of the GNU General Public License
25
- * along with Addons for Visual Composer. If not, see <http://www.gnu.org/licenses/>.
26
  *
27
  */
28
 
@@ -75,7 +75,7 @@ if (!class_exists('Livemesh_VC_Addons')) :
75
  */
76
  public function __clone() {
77
  // Cloning instances of the class is forbidden
78
- _doing_it_wrong(__FUNCTION__, __('Cheatin&#8217; huh?', 'livemesh-vc-addons'), '1.8.2');
79
  }
80
 
81
  /**
@@ -84,7 +84,7 @@ if (!class_exists('Livemesh_VC_Addons')) :
84
  */
85
  public function __wakeup() {
86
  // Unserializing instances of the class is forbidden
87
- _doing_it_wrong(__FUNCTION__, __('Cheatin&#8217; huh?', 'livemesh-vc-addons'), '1.8.2');
88
  }
89
 
90
  /**
@@ -95,7 +95,7 @@ if (!class_exists('Livemesh_VC_Addons')) :
95
 
96
  // Plugin version
97
  if (!defined('LVCA_VERSION')) {
98
- define('LVCA_VERSION', '1.8.2');
99
  }
100
 
101
  // Plugin Folder Path
1
  <?php
2
  /**
3
+ * Plugin Name: Addons for WPBakery Page Builder
4
+ * Plugin URI: https://www.livemeshthemes.com/wpbakery-page-builder-addons
5
+ * Description: A collection of premium quality addons or extensions for use in WPBakery Page Builder. WPBakery Page Builder must be installed and activated.
6
  * Author: Livemesh
7
+ * Author URI: https://www.livemeshthemes.com/wpbakery-page-builder-addons
8
  * License: GPL3
9
  * License URI: https://www.gnu.org/licenses/gpl-3.0.txt
10
+ * Version: 1.9.1
11
  * Text Domain: livemesh-vc-addons
12
  * Domain Path: languages
13
  *
14
+ * Addons for WPBakery Page Builder is free software: you can redistribute it and/or modify
15
  * it under the terms of the GNU General Public License as published by
16
  * the Free Software Foundation, either version 2 of the License, or
17
  * any later version.
18
  *
19
+ * Addons for WPBakery Page Builder is distributed in the hope that it will be useful,
20
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
21
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22
  * GNU General Public License for more details.
23
  *
24
  * You should have received a copy of the GNU General Public License
25
+ * along with Addons for WPBakery Page Builder. If not, see <http://www.gnu.org/licenses/>.
26
  *
27
  */
28
 
75
  */
76
  public function __clone() {
77
  // Cloning instances of the class is forbidden
78
+ _doing_it_wrong(__FUNCTION__, __('Cheatin&#8217; huh?', 'livemesh-vc-addons'), '1.9.1');
79
  }
80
 
81
  /**
84
  */
85
  public function __wakeup() {
86
  // Unserializing instances of the class is forbidden
87
+ _doing_it_wrong(__FUNCTION__, __('Cheatin&#8217; huh?', 'livemesh-vc-addons'), '1.9.1');
88
  }
89
 
90
  /**
95
 
96
  // Plugin version
97
  if (!defined('LVCA_VERSION')) {
98
+ define('LVCA_VERSION', '1.9.1');
99
  }
100
 
101
  // Plugin Folder Path
readme.txt CHANGED
@@ -1,66 +1,66 @@
1
- === Addons for Visual Composer ===
2
- Author URI: https://www.livemeshthemes.com/visual-composer-addons
3
- Plugin URI: https://www.livemeshthemes.com/visual-composer-addons
4
  Contributors: livemesh
5
- Tags: visual composer, visual composer addons, vc addons, visual composer extensions, vc extensions, page builder, portfolio, carousel, post, posts, shortcodes, tabs, admin, plugin, page
6
  Requires at least: 4.5
7
  Tested up to: 4.9
8
- Stable Tag: 1.8.2
9
  License: GPLv2 or later
10
  License URI: http://www.gnu.org/licenses/gpl-2.0.html-func
11
 
12
- A collection of premium quality addons or extensions for Visual Composer page builder. Visual composer must be installed and activated.
13
 
14
  == Description ==
15
 
16
- Addons for Visual Composer features professional looking, easy to use yet highly functional extensions that can be used in a WPBakery Visual Composer page builder. This is really a premium plugin that you can get for free.
17
 
18
- This plugin comes with widgets for just about everything you need to build a professional website without switching to a premium theme - services, team profiles, counters, bar charts, piecharts, testimonials, clients list, portfolio/posts grid, posts carousels, varieties of tabs, accordions or toggles, pricing plan and much more in the <a href="https://www.livemeshthemes.com/visual-composer-addons" title="Addons for Visual Composer Premium Version">PRO version</a>. All the addons that help turn your free theme into a premium one with just a few clicks. Every premium page builder element you need is available for easy drag and drop into your page by just activating this plugin.
19
 
20
- Visual Composer plugin must be installed and activated to use this plugin. After you activate the required plugins, the elements should be available for use in Visual Composer.
21
 
22
  See the all of addon elements in action here -
23
 
24
- <a href="https://www.livemeshthemes.com/visual-composer-addons/addons-demo#demo-section" title="Addons for Visual Composer Demo Site"><strong>LIVE DEMO</strong></a> | <a href="https://www.livemeshthemes.com/visual-composer-addons/pricing/" title="Addons for Visual Composer Premium Version"><strong>PRO Version</strong></a>.
25
 
26
- The plugin comes with the following VC addons or extensions. <strong>Almost all of the elements come with a dark version.</strong> -
27
 
28
  <ul>
29
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/services/" title="Services Extension">Services</a> that capture what you can offer for your clients/customers.</li>
30
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/tabs/" title="Responsive Tabs Addon">Responsive Tabs</a> that function seamlessly across all devices and resolutions.</li>
31
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/accordions/" title="Accordion Extension">Accordion/Toggle</a> that capture collapsible content panels when space is limited.</li>
32
  <li>Heading styles to capture effective headings for your page sections.</li>
33
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/portfolio-grid/" title="Portfolio Grid Addon">Portfolio Grid addon</a> that displays portfolio/blog entries in a nice responsive grid. Masonry and packed options are supported.</li>
34
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/posts-grid/" title="Posts Grid Extension">Blog Posts Grid</a> that displays portfolio/blog entries in a nice responsive grid. Masonry and packed options are supported.</li>
35
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/team-member-profiles/" title="Team Profiles Addon">Team Profiles</a> extension to display all the team members.</li>
36
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/odometer-counters/" title="Odometer/Counters Extension">Odometers/Counters</a> to show impressive numbers pertaining to your work or company.</li>
37
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/progress-bars/" title="Bar Charts">Bar charts addon</a> to capture skills or any type of percentage stats.</li>
38
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/piecharts/" title="Piecharts Extension">Animated Pie charts</a> for visual depiction of percentage stats.</li>
39
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/testimonials/" title="Testimonials Addon">Testimonials</a> to tell everyone the good things you often hear from your clients/customers.</li>
40
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/testimonial-slider/" title="Testimonial Slider Addon">Testimonials slider</a> is a responsive touch enabled slider that cycles through testimonials.</li>
41
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/posts-carousel/" title="Posts Carousel Extension">Post Carousel extension</a> that displays your posts as a highly responsive carousel.</li>
42
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/generic-carousel/" title="Generic Carousel Addon">Generic Carousel</a> element that displays lets you present a list of HTML content in a carousel.</li>
43
  <li>Spacer element that displays lets you set space between elements and vary the spacing across device resolutions.</li>
44
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/clients-element/" title="Clients List Element">Clients List</a> extension to showcase the clients that you have handled.</li>
45
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/pricing-table/" title="Pricing Table Extension">Pricing Plans</a> to help get more sales.</li></ul>
46
 
47
- The <strong><a href="https://www.livemeshthemes.com/visual-composer-addons/" title="Addons for Visual Composer Pro" target="_blank">PRO version</a></strong> of the plugin comes with additional addons and advanced features added to elements above -
48
 
49
  <ul>
50
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/posts-block/" title="Posts Block Addon">Posts Block</a> to help present your blog posts, events, news items or portfolio in a dozen creative ways. Comes with AJAX filtering, pagination and load more features to help visitors navigate your entire collection of blog posts or custom post types and their categories without reloading the page.</li>
51
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/sliders/" title="Image Slider Extension">Image Slider</a> to create a responsive slider of images with support for captions, multiple slider types like Nivo, Flex, Slick and lightweight sliders, thumbnail navigation etc.</li>
52
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/image-gallery/" title="Image Gallery Addon">Image Gallery</a> addon that lets you create a grid of images with options for masonry or fit rows, pagination, lazy load, lightbox support etc.</li>
53
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/video-gallery/" title="Video Gallery Addon">Video Gallery</a> to build a beautiful grid of videos to help showcase a collection of YouTube/Vimeo videos on your site.</li>
54
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/gallery-carousel/" title="Image Carousel">Image Carousel</a> for a responsive carousel of images.</li>
55
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/gallery-carousel/" title="Video Carousel">Video Carousel</a> for creation of a responsive carousel of YouTube/Vimeo videos.</li>
56
  <li>Countdown extension to display a countdown timer on your site pages such as those that feature events or under construction/coming soon pages.</li>
57
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/faq-element/" title="FAQ Element">FAQ element</a> to display a set of Frequently Asked Questions in a page.</li>
58
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/features/" title="Features Addon">Features Addon</a> for showcasing product features or services provided by an agency/business.</li>
59
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/buttons/" title="Icon Lists and Buttons">Flat style buttons</a> with rich set of customization options.</li>
60
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/services-advanced/" title="Advanced Services">Advanced Services</a> with additional styles and animations for services addon.</li>
61
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/icon-lists/" title="Icon List element">Icon list addon</a> that lets you use either images or icon fonts to create custom social icons list, capture payment options etc.</li>
62
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/portfolio-grid-pro/" title="Livemesh Grid">Lazy Load</a> - The portfolio/post grid and image gallery addons incorporate option to lazy load posts/images with the click of a Load More button.</li>
63
- <li><a href="https://www.livemeshthemes.com/visual-composer-addons/portfolio-grid-pro/" title="Livemesh Grid">Pagination</a> - Create a grid of posts or custom post types with AJAX based pagination support. </li>
64
  <li>Lightbox Support - The premium version comes with support for Lightbox for grid and carousel addons.</li>
65
  <li>Customizations - Ability to choose custom font size, color or hover color for certain addons. More coming.</li>
66
  <li>Custom Animations - Choose from over <strong>40+ animations</strong> for most addon elements (excludes sliders, carousels and grid). The animations display on user scrolling to the element or when the element becomes visible in the browser window.</li>
@@ -73,8 +73,8 @@ http://twitter.com/live_mesh
73
 
74
  == Installation ==
75
 
76
- 1. Install and activate the Visual Composer page builder.
77
- 2. Unzip the downloaded addons-for-visual-composer.zip file and upload to the `/wp-content/plugins/` directory or install the Visual Composer Addons by Livemesh plugin from WordPress repository. Activate the plugin through the 'Plugins' menu in WordPress.
78
  4. For Portfolio element, install and activate the <strong>optional plugin</strong> <a href="https://wordpress.org/plugins/portfolio-post-type/" title="Portfolio Post Type">Portfolio Post Type plugin</a>. The Portfolio addon can be built using custom post type registered by this plugin.
79
 
80
  Optionally, you can import the sample data that replicates the demo site for you by importing the file sample-data.xml file located in the plugin directory. The import option is available under Tools &gt; Import in WordPress admin.
@@ -85,13 +85,13 @@ Optionally, you can import the sample data that replicates the demo site for you
85
 
86
  Our tests indicate that the addons work well with most themes that are well coded. You may need some minor custom CSS with themes that hijack the styling for heading tags by using !important keyword.
87
 
88
- Some themes override default templates provided by Visual Composer. The themes that override VC Row template may require you to manually set the attributes required for the dark version (see below).
89
 
90
  The demo site is best recreated with a theme that supports a full width page template without sidebars. The elements can still be used in the pages of default template.
91
 
92
  = How to enable the dark version for any element? =
93
 
94
- In Visual Composer page builder, add a row wrapper for the element, edit row and check the option 'Dark Background?' at the end of General tab of the row or an inner row element.
95
 
96
  For themes that override the VC row template with one of their own, you may need to add a custom class 'lvca-dark-bg' manually to the VC row wrapper element to activate the dark version of an element.
97
 
@@ -100,14 +100,24 @@ For themes that override the VC row template with one of their own, you may need
100
  Pls install and activate the <a href="https://wordpress.org/plugins/portfolio-post-type/" title="Portfolio Post Type">Portfolio Post Type plugin</a> to enable custom post type Portfolio.
101
 
102
  == Screenshots ==
103
- 1. The plugin Addons for Visual Composer tab in Visual Composer Add Element window.
104
- 2. Visual Composer addon elements in action in Visual Composer Page Builder tab of Page Edit window.
105
- 3. Editing a addon/extension element in the Visual Composer Page Builder.
106
 
107
  == Changelog ==
108
 
 
 
 
 
 
 
 
 
 
 
109
  = 1.8.2 =
110
- * Fixed – Livemesh Grid columns can break in certain resolutions in FireFox.
111
  * Fixed - The piechart value is not being rounded.
112
  * Fixed - The post grid and posts carousel date format not reflecting the user preference specified in Settings page.
113
 
@@ -126,7 +136,7 @@ Pls install and activate the <a href="https://wordpress.org/plugins/portfolio-po
126
  * Fixed – The post image in a grid or posts carousel was not clickable to the link specified
127
  * Fixed – The grid filters would not center when a heading was not specified.
128
  * Fixed – The grid filters will not display multi-line on devices of lower resolutions like mobile devices.
129
- * Fixed – The plugin caused some minor styling changes to occur in Visual Composer backend.
130
  * Updated - Compatibility with WordPress 4.9 version
131
 
132
  = 1.6.1 =
1
+ === Addons for WPBakery Page Builder ===
2
+ Author URI: https://www.livemeshthemes.com/wpbakery-page-builder-addons
3
+ Plugin URI: https://www.livemeshthemes.com/wpbakery-page-builder-addons
4
  Contributors: livemesh
5
+ Tags: wpbakery page builder, wpbakery page builder addons, wpbakery, wpbakery page builder extensions, visual composer, visual composer addons, visual composer extensions, page builder, portfolio, carousel, post, posts, shortcodes, tabs, plugin, page
6
  Requires at least: 4.5
7
  Tested up to: 4.9
8
+ Stable Tag: 1.9.1
9
  License: GPLv2 or later
10
  License URI: http://www.gnu.org/licenses/gpl-2.0.html-func
11
 
12
+ A collection of premium quality addons or extensions for WPBakery Page Builder(formerly Visual Composer).
13
 
14
  == Description ==
15
 
16
+ Addons for WPBakery Page Builder(formerly Visual Composer) features professional looking, easy to use yet highly functional extensions that can be used in WPBakery Page Builder. This is really a premium plugin that you can get for free.
17
 
18
+ This plugin comes with widgets for just about everything you need to build a professional website without switching to a premium theme - services, team profiles, counters, bar charts, piecharts, testimonials, clients list, portfolio/posts grid, posts carousels, varieties of tabs, accordions or toggles, pricing plan and much more in the <a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons" title="Addons for WPBakery Page Builder Premium Version">PRO version</a>. All the addons that help turn your free theme into a premium one with just a few clicks. Every premium page builder element you need is available for easy drag and drop into your page by just activating this plugin.
19
 
20
+ WPBakery Page Builder(formerly Visual Composer) plugin must be installed and activated to use this plugin. After you activate the required plugins, the elements should be available for use in WPBakery Page Builder.
21
 
22
  See the all of addon elements in action here -
23
 
24
+ <a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/addons-demo#demo-section" title="Addons for WPBakery Page Builder Demo Site"><strong>LIVE DEMO</strong></a> | <a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing/" title="Addons for WPBakery Page Builder Premium Version"><strong>PRO Version</strong></a>.
25
 
26
+ The plugin comes with the following WPBakery Page Builder Addons or extensions. <strong>Almost all of the elements come with a dark version.</strong> -
27
 
28
  <ul>
29
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/services/" title="Services Extension">Services</a> that capture what you can offer for your clients/customers.</li>
30
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/tabs/" title="Responsive Tabs Addon">Responsive Tabs</a> that function seamlessly across all devices and resolutions.</li>
31
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/accordions/" title="Accordion Extension">Accordion/Toggle</a> that capture collapsible content panels when space is limited.</li>
32
  <li>Heading styles to capture effective headings for your page sections.</li>
33
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/portfolio-grid/" title="Portfolio Grid Addon">Portfolio Grid addon</a> that displays portfolio/blog entries in a nice responsive grid. Masonry and packed options are supported.</li>
34
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/posts-grid/" title="Posts Grid Extension">Blog Posts Grid</a> that displays portfolio/blog entries in a nice responsive grid. Masonry and packed options are supported.</li>
35
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/team-member-profiles/" title="Team Profiles Addon">Team Profiles</a> extension to display all the team members.</li>
36
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/odometer-counters/" title="Odometer/Counters Extension">Odometers/Counters</a> to show impressive numbers pertaining to your work or company.</li>
37
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/progress-bars/" title="Bar Charts">Bar charts addon</a> to capture skills or any type of percentage stats.</li>
38
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/piecharts/" title="Piecharts Extension">Animated Pie charts</a> for visual depiction of percentage stats.</li>
39
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/testimonials/" title="Testimonials Addon">Testimonials</a> to tell everyone the good things you often hear from your clients/customers.</li>
40
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/testimonial-slider/" title="Testimonial Slider Addon">Testimonials slider</a> is a responsive touch enabled slider that cycles through testimonials.</li>
41
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/posts-carousel/" title="Posts Carousel Extension">Post Carousel extension</a> that displays your posts as a highly responsive carousel.</li>
42
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/generic-carousel/" title="Generic Carousel Addon">Generic Carousel</a> element that displays lets you present a list of HTML content in a carousel.</li>
43
  <li>Spacer element that displays lets you set space between elements and vary the spacing across device resolutions.</li>
44
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/clients-element/" title="Clients List Element">Clients List</a> extension to showcase the clients that you have handled.</li>
45
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/pricing-table/" title="Pricing Table Extension">Pricing Plans</a> to help get more sales.</li></ul>
46
 
47
+ The <strong><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/" title="Addons for WPBakery Page Builder Pro" target="_blank">PRO version</a></strong> of the plugin comes with additional addons and advanced features added to elements above -
48
 
49
  <ul>
50
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/posts-block/" title="Posts Block Addon">Posts Block</a> to help present your blog posts, events, news items or portfolio in a dozen creative ways. Comes with AJAX filtering, pagination and load more features to help visitors navigate your entire collection of blog posts or custom post types and their categories without reloading the page.</li>
51
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/sliders/" title="Image Slider Extension">Image Slider</a> to create a responsive slider of images with support for captions, multiple slider types like Nivo, Flex, Slick and lightweight sliders, thumbnail navigation etc.</li>
52
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/image-gallery/" title="Image Gallery Addon">Image Gallery</a> addon that lets you create a grid of images with options for masonry or fit rows, pagination, lazy load, lightbox support etc.</li>
53
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/video-gallery/" title="Video Gallery Addon">Video Gallery</a> to build a beautiful grid of videos to help showcase a collection of YouTube/Vimeo videos on your site.</li>
54
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/gallery-carousel/" title="Image Carousel">Image Carousel</a> for a responsive carousel of images.</li>
55
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/gallery-carousel/" title="Video Carousel">Video Carousel</a> for creation of a responsive carousel of YouTube/Vimeo videos.</li>
56
  <li>Countdown extension to display a countdown timer on your site pages such as those that feature events or under construction/coming soon pages.</li>
57
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/faq-element/" title="FAQ Element">FAQ element</a> to display a set of Frequently Asked Questions in a page.</li>
58
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/features/" title="Features Addon">Features Addon</a> for showcasing product features or services provided by an agency/business.</li>
59
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/buttons/" title="Icon Lists and Buttons">Flat style buttons</a> with rich set of customization options.</li>
60
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/services-advanced/" title="Advanced Services">Advanced Services</a> with additional styles and animations for services addon.</li>
61
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/icon-lists/" title="Icon List element">Icon list addon</a> that lets you use either images or icon fonts to create custom social icons list, capture payment options etc.</li>
62
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/portfolio-grid-pro/" title="Posts/Portfolio Grid">Lazy Load</a> - The portfolio/post grid and image gallery addons incorporate option to lazy load posts/images with the click of a Load More button.</li>
63
+ <li><a href="https://www.livemeshthemes.com/wpbakery-page-builder-addons/portfolio-grid-pro/" title="Posts/Portfolio Grid">Pagination</a> - Create a grid of posts or custom post types with AJAX based pagination support. </li>
64
  <li>Lightbox Support - The premium version comes with support for Lightbox for grid and carousel addons.</li>
65
  <li>Customizations - Ability to choose custom font size, color or hover color for certain addons. More coming.</li>
66
  <li>Custom Animations - Choose from over <strong>40+ animations</strong> for most addon elements (excludes sliders, carousels and grid). The animations display on user scrolling to the element or when the element becomes visible in the browser window.</li>
73
 
74
  == Installation ==
75
 
76
+ 1. Install and activate the WPBakery Page Builder(formerly Visual Composer).
77
+ 2. Unzip the downloaded addons-for-visual-composer.zip file and upload to the `/wp-content/plugins/` directory or install the WPBakery Page Builder Addons by Livemesh plugin from WordPress repository. Activate the plugin through the 'Plugins' menu in WordPress.
78
  4. For Portfolio element, install and activate the <strong>optional plugin</strong> <a href="https://wordpress.org/plugins/portfolio-post-type/" title="Portfolio Post Type">Portfolio Post Type plugin</a>. The Portfolio addon can be built using custom post type registered by this plugin.
79
 
80
  Optionally, you can import the sample data that replicates the demo site for you by importing the file sample-data.xml file located in the plugin directory. The import option is available under Tools &gt; Import in WordPress admin.
85
 
86
  Our tests indicate that the addons work well with most themes that are well coded. You may need some minor custom CSS with themes that hijack the styling for heading tags by using !important keyword.
87
 
88
+ Some themes override default templates provided by WPBakery Page Builder. The themes that override VC Row template may require you to manually set the attributes required for the dark version (see below).
89
 
90
  The demo site is best recreated with a theme that supports a full width page template without sidebars. The elements can still be used in the pages of default template.
91
 
92
  = How to enable the dark version for any element? =
93
 
94
+ In WPBakery Page Builder, add a row wrapper for the element, edit row and check the option 'Dark Background?' at the end of General tab of the row or an inner row element.
95
 
96
  For themes that override the VC row template with one of their own, you may need to add a custom class 'lvca-dark-bg' manually to the VC row wrapper element to activate the dark version of an element.
97
 
100
  Pls install and activate the <a href="https://wordpress.org/plugins/portfolio-post-type/" title="Portfolio Post Type">Portfolio Post Type plugin</a> to enable custom post type Portfolio.
101
 
102
  == Screenshots ==
103
+ 1. The plugin Addons for WPBakery Page Builder tab in WPBakery Page Builder Add Element window.
104
+ 2. WPBakery Page Builder addon elements in action in WPBakery Page Builder tab of Page Edit window.
105
+ 3. Editing a addon/extension element in the WPBakery Page Builder.
106
 
107
  == Changelog ==
108
 
109
+ = 1.9.1 =
110
+ * Rolled back – Update done to WayPoints script since WPBakery Page Builder is yet to upgrade to new version. Some reports have come in which suggests that the change broke some pages with certain WPBakery page builder elements.
111
+
112
+ = 1.9.0 =
113
+ * Updated – Changed plugin name to Addons for WPBakery Page Builder to help reflect recent renaming of Visual Composer to WPBakery Page Builder.
114
+ * Updated - Changed plugin options menu title from VC Addons to WPBakery Addons in WordPress admin.
115
+ * Updated - Removed annoying Livemesh prefix from all elements. For example, Livemesh Services is now named Services, Livemesh Tabs is now Tabs, Livemesh Grid is now Posts Grid etc.
116
+ * Updated - Moved to latest version of waypoints script.
117
+ * Fixed - The grid won't display filters when specific taxonomy terms are chosen in the build query.
118
+
119
  = 1.8.2 =
120
+ * Fixed – Posts Grid columns can break in certain resolutions in FireFox.
121
  * Fixed - The piechart value is not being rounded.
122
  * Fixed - The post grid and posts carousel date format not reflecting the user preference specified in Settings page.
123
 
136
  * Fixed – The post image in a grid or posts carousel was not clickable to the link specified
137
  * Fixed – The grid filters would not center when a heading was not specified.
138
  * Fixed – The grid filters will not display multi-line on devices of lower resolutions like mobile devices.
139
+ * Fixed – The plugin caused some minor styling changes to occur in WPBakery Page Builder backend.
140
  * Updated - Compatibility with WordPress 4.9 version
141
 
142
  = 1.6.1 =