Version Description
Fixed: XSS vulnerabilities on settings page. Fixed: Disable pagination during page load.
Download this release
Release Info
| Developer | 10web |
| Plugin | |
| Version | 1.4.22 |
| Comparing to | |
| See all releases | |
Code changes from version 1.4.21 to 1.4.22
- admin/controllers/WDIControllerWidget.php +10 -11
- admin/controllers/feeds.php +1 -1
- admin/views/feeds.php +2 -2
- config.php +1 -1
- css/wdi_frontend.css +11 -7
- css/wdi_frontend.min.css +1 -1
- framework/WDIInstagram.php +1 -1
- framework/WDILibrary.php +1 -1
- frontend/views/imagebrowser.php +45 -45
- frontend/views/thumbnails.php +50 -58
- js/wdi_frontend.js +65 -108
- js/wdi_frontend.min.js +1 -1
- js/wdi_instagram.js +8 -6
- readme.txt +5 -1
- wd-instagram-feed.php +1 -1
admin/controllers/WDIControllerWidget.php
CHANGED
|
@@ -27,30 +27,29 @@ class WDIControllerWidget extends WP_Widget {
|
|
| 27 |
}
|
| 28 |
|
| 29 |
public function form( $instance ) {
|
| 30 |
-
|
| 31 |
$this->view->form(
|
| 32 |
-
$instance,
|
| 33 |
-
parent::get_field_id('title'),
|
| 34 |
parent::get_field_name('title'),
|
| 35 |
-
parent::get_field_id('feed_id'),
|
| 36 |
-
parent::get_field_name('feed_id'),
|
| 37 |
-
parent::get_field_id('img_number'),
|
| 38 |
parent::get_field_name('img_number'),
|
| 39 |
parent::get_field_id('show_description'),
|
| 40 |
parent::get_field_name('show_description'),
|
| 41 |
parent::get_field_id('show_likes_comments'),
|
| 42 |
parent::get_field_name('show_likes_comments'),
|
| 43 |
-
parent::get_field_id('number_of_columns'),
|
| 44 |
parent::get_field_name('number_of_columns'),
|
| 45 |
-
parent::get_field_id('enable_loading_buttons'),
|
| 46 |
parent::get_field_name('enable_loading_buttons')
|
| 47 |
-
);
|
| 48 |
-
|
| 49 |
|
| 50 |
// Update Settings.
|
| 51 |
public function update($new_instance, $old_instance) {
|
| 52 |
|
| 53 |
-
$instance['title'] = wp_filter_nohtml_kses($new_instance['title']);
|
| 54 |
$instance['feed_id'] = intval($new_instance['feed_id']);
|
| 55 |
$instance['img_number'] = intval($new_instance['img_number']) ? intval($new_instance['img_number']) : 4;
|
| 56 |
$instance['show_description'] = isset($new_instance['show_description']) ? 1 : 0;
|
| 27 |
}
|
| 28 |
|
| 29 |
public function form( $instance ) {
|
|
|
|
| 30 |
$this->view->form(
|
| 31 |
+
$instance,
|
| 32 |
+
parent::get_field_id('title'),
|
| 33 |
parent::get_field_name('title'),
|
| 34 |
+
parent::get_field_id('feed_id'),
|
| 35 |
+
parent::get_field_name('feed_id'),
|
| 36 |
+
parent::get_field_id('img_number'),
|
| 37 |
parent::get_field_name('img_number'),
|
| 38 |
parent::get_field_id('show_description'),
|
| 39 |
parent::get_field_name('show_description'),
|
| 40 |
parent::get_field_id('show_likes_comments'),
|
| 41 |
parent::get_field_name('show_likes_comments'),
|
| 42 |
+
parent::get_field_id('number_of_columns'),
|
| 43 |
parent::get_field_name('number_of_columns'),
|
| 44 |
+
parent::get_field_id('enable_loading_buttons'),
|
| 45 |
parent::get_field_name('enable_loading_buttons')
|
| 46 |
+
);
|
| 47 |
+
}
|
| 48 |
|
| 49 |
// Update Settings.
|
| 50 |
public function update($new_instance, $old_instance) {
|
| 51 |
|
| 52 |
+
$instance['title'] = wp_filter_nohtml_kses(htmlspecialchars($new_instance['title']));
|
| 53 |
$instance['feed_id'] = intval($new_instance['feed_id']);
|
| 54 |
$instance['img_number'] = intval($new_instance['img_number']) ? intval($new_instance['img_number']) : 4;
|
| 55 |
$instance['show_description'] = isset($new_instance['show_description']) ? 1 : 0;
|
admin/controllers/feeds.php
CHANGED
|
@@ -517,7 +517,7 @@ class Feeds_controller_wdi {
|
|
| 517 |
}
|
| 518 |
|
| 519 |
private function sanitize_string( $value, $default ) {
|
| 520 |
-
$sanitized_val = strip_tags(stripslashes($value));
|
| 521 |
if ( $sanitized_val == '' ) {
|
| 522 |
return $default;
|
| 523 |
}
|
| 517 |
}
|
| 518 |
|
| 519 |
private function sanitize_string( $value, $default ) {
|
| 520 |
+
$sanitized_val = strip_tags(stripslashes(esc_html($value)));
|
| 521 |
if ( $sanitized_val == '' ) {
|
| 522 |
return $default;
|
| 523 |
}
|
admin/views/feeds.php
CHANGED
|
@@ -110,7 +110,7 @@ class Feeds_view_wdi {
|
|
| 110 |
$instagram_preview_post = $this->model->get_instagram_preview_post();
|
| 111 |
foreach ($rows_data as $row_data) {
|
| 112 |
$prev_img_url = WDI_URL . '/images/no-image.png';
|
| 113 |
-
$feed_users = json_decode($row_data->feed_users, TRUE);
|
| 114 |
foreach ( $feed_users as $user ) {
|
| 115 |
if ( empty($users['tag_id']) ) {
|
| 116 |
$username = $user['username'];
|
|
@@ -803,7 +803,7 @@ class Feeds_view_wdi {
|
|
| 803 |
|
| 804 |
if ($current_id != '') {
|
| 805 |
$feed_row = WDILibrary::objectToarray($this->model->get_feed_row($current_id));
|
| 806 |
-
$users = (array) json_decode($feed_row['feed_users'], TRUE);
|
| 807 |
if ( !empty($users) ) {
|
| 808 |
foreach($users as $user) {
|
| 809 |
if( substr($user['username'], 0, 1) === '#' ) {
|
| 110 |
$instagram_preview_post = $this->model->get_instagram_preview_post();
|
| 111 |
foreach ($rows_data as $row_data) {
|
| 112 |
$prev_img_url = WDI_URL . '/images/no-image.png';
|
| 113 |
+
$feed_users = json_decode(htmlspecialchars_decode($row_data->feed_users), TRUE);
|
| 114 |
foreach ( $feed_users as $user ) {
|
| 115 |
if ( empty($users['tag_id']) ) {
|
| 116 |
$username = $user['username'];
|
| 803 |
|
| 804 |
if ($current_id != '') {
|
| 805 |
$feed_row = WDILibrary::objectToarray($this->model->get_feed_row($current_id));
|
| 806 |
+
$users = (array) json_decode(htmlspecialchars_decode($feed_row['feed_users']), TRUE);
|
| 807 |
if ( !empty($users) ) {
|
| 808 |
foreach($users as $user) {
|
| 809 |
if( substr($user['username'], 0, 1) === '#' ) {
|
config.php
CHANGED
|
@@ -3,7 +3,7 @@ if ( !defined('ABSPATH') ) {
|
|
| 3 |
exit;
|
| 4 |
}
|
| 5 |
|
| 6 |
-
define('WDI_VERSION', '1.4.
|
| 7 |
define('WDI_IS_FREE', TRUE);
|
| 8 |
define('WDI_PREFIX', 'wdi');
|
| 9 |
define('WDI_DIR', WP_PLUGIN_DIR . "/" . plugin_basename(dirname(__FILE__)));
|
| 3 |
exit;
|
| 4 |
}
|
| 5 |
|
| 6 |
+
define('WDI_VERSION', '1.4.22');
|
| 7 |
define('WDI_IS_FREE', TRUE);
|
| 8 |
define('WDI_PREFIX', 'wdi');
|
| 9 |
define('WDI_DIR', WP_PLUGIN_DIR . "/" . plugin_basename(dirname(__FILE__)));
|
css/wdi_frontend.css
CHANGED
|
@@ -428,9 +428,9 @@ div[id^="wdi_container"] p {
|
|
| 428 |
/* .wdi_layout_th */
|
| 429 |
|
| 430 |
.wdi_layout_th .wdi_feed_container {
|
|
|
|
| 431 |
min-width: 160px;
|
| 432 |
margin: 0 auto;
|
| 433 |
-
|
| 434 |
}
|
| 435 |
|
| 436 |
.wdi_layout_th .wdi_feed_wrapper {
|
|
@@ -1366,21 +1366,25 @@ div[id^="wdi_container"] p {
|
|
| 1366 |
color: #003569;
|
| 1367 |
text-decoration: none;
|
| 1368 |
}
|
| 1369 |
-
|
| 1370 |
-
.elementor-editor-active .wdi_front_overlay{
|
| 1371 |
position: absolute;
|
| 1372 |
-
top:0;
|
| 1373 |
left: 0;
|
|
|
|
|
|
|
| 1374 |
width: 100%;
|
| 1375 |
height: 100%;
|
|
|
|
|
|
|
|
|
|
| 1376 |
background-color: rgba(0,0,0,0.2);
|
| 1377 |
}
|
| 1378 |
|
| 1379 |
#wdi_added_comments {
|
| 1380 |
-
|
| 1381 |
}
|
| 1382 |
|
| 1383 |
.wdi_comment_container #ajax_loading {
|
| 1384 |
-
|
| 1385 |
-
|
| 1386 |
}
|
| 428 |
/* .wdi_layout_th */
|
| 429 |
|
| 430 |
.wdi_layout_th .wdi_feed_container {
|
| 431 |
+
position: relative;
|
| 432 |
min-width: 160px;
|
| 433 |
margin: 0 auto;
|
|
|
|
| 434 |
}
|
| 435 |
|
| 436 |
.wdi_layout_th .wdi_feed_wrapper {
|
| 1366 |
color: #003569;
|
| 1367 |
text-decoration: none;
|
| 1368 |
}
|
| 1369 |
+
.wdi_front_overlay {
|
|
|
|
| 1370 |
position: absolute;
|
| 1371 |
+
top: 0;
|
| 1372 |
left: 0;
|
| 1373 |
+
right: 0;
|
| 1374 |
+
bottom: 0;
|
| 1375 |
width: 100%;
|
| 1376 |
height: 100%;
|
| 1377 |
+
}
|
| 1378 |
+
|
| 1379 |
+
.elementor-editor-active .wdi_front_overlay {
|
| 1380 |
background-color: rgba(0,0,0,0.2);
|
| 1381 |
}
|
| 1382 |
|
| 1383 |
#wdi_added_comments {
|
| 1384 |
+
padding-top: 20px;
|
| 1385 |
}
|
| 1386 |
|
| 1387 |
.wdi_comment_container #ajax_loading {
|
| 1388 |
+
left: calc(50% - 25px);
|
| 1389 |
+
top: calc(50% - 25px);
|
| 1390 |
}
|
css/wdi_frontend.min.css
CHANGED
|
@@ -1 +1 @@
|
|
| 1 |
-
.wdi_clear{clear:both}.wdi_feed_main_container .table{display:table}.wdi_feed_main_container .table-cell{display:table-cell}.wdi_feed_main_container .table-row{display:table-row}.wdi_feed_main_container{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none}.wdi_follow_button:hover{cursor:pointer}.wdi_hidden{display:none!important}.wdi_hover_off:hover{background-color:transparent!important}.wdi_cursor_off:hover{cursor:auto!important}.wdi_filter_active span{color:#fff}.wdi_disabled{visibility:hidden}.wdi_ajax_loading{width:50px;height:50px;margin:auto}.wdi_page_loading{position:absolute;top:calc(50% - 25px);left:calc(50% - 25px);width:50px;height:50px;margin:auto}.wdi_feed_main_container{width:100%;position:relative}.wdi_feed_main_container .wdi_img{margin:0}.wdi_feed_main_container .wdi_follow_btn{display:inline-block;background:0 0;border-style:solid;border-width:1px;font-weight:500;outline:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;-webkit-appearance:none;vertical-align:text-bottom}.wdi_feed_main_container .wdi_follow_btn:hover{cursor:pointer}.wdi_feed_main_container .wdi_pagination{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none}.wdi_feed_main_container .wdi_pagination_ctrl{display:inline-block}.wdi_feed_main_container .wdi_pagination_ctrl:hover{cursor:pointer}.wdi_feed_main_container .wdi_filter_icon span{display:block;font-size:25px;color:#fff}.wdi_feed_main_container .wdi_filter_icon span::before{width:20px;height:20px;position:absolute;opacity:1;right:0;left:0;top:0;bottom:0;margin:auto}.wdi_photo_img{position:relative;overflow:hidden}.wdi_photo_overlay{width:100%;height:100%;position:absolute;top:0;left:0;background-color:transparent;transition:all .1s ease}.wdi_photo_overlay:hover .wdi_thumb_icon i{display:block}.wdi_feed_main_container .tenweb{font-family:tenweb!important;font-style:normal;width:auto;speak:none;display:inline-block;line-height:1;font-weight:400;font-variant:normal;text-transform:none;vertical-align:top;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.wdi_media_info .tenweb-i:before{margin-right:6px}.wdi_spider_popup_loading{background-image:url(../images/ajax_loader.png);background-color:rgba(0,0,0,0);background-repeat:no-repeat;background-position:0 0;background-size:50px 50px;border:none!important;display:none;height:50px;left:50%;margin-left:-20px;margin-top:-20px;overflow:hidden;position:fixed;top:50%;width:50px;z-index:10102;-moz-animation:spin 2.5s infinite linear;-o-animation:spin 2.5s infinite linear;-webkit-animation:spin 2.5s infinite linear;animation:spin 2.5s infinite linear}.wdi_spider_popup_overlay{cursor:pointer;background-color:rgba(0,0,0,.5);display:none;height:100%;left:0;position:fixed;top:0;width:100%;z-index:10100}div[id^=wdi_container] p{padding:0!important;margin:0!important}.footer-list-block .bwp_gallery .wdi_spider_popup_loading,.footer-list-block .bwp_gallery_tags .wdi_spider_popup_loading,.wdi_spider_popup_loading{background-image:url(../images/ajax_loader.png);background-color:rgba(0,0,0,0);background-repeat:no-repeat;background-position:0 0;background-size:50px 50px;border:none!important;display:none;height:50px;left:50%;margin-left:-20px;margin-top:-20px;overflow:hidden;position:fixed;top:50%;width:50px;z-index:10102;-moz-animation:spin 2.5s infinite linear;-o-animation:spin 2.5s infinite linear;-webkit-animation:spin 2.5s infinite linear;animation:spin 2.5s infinite linear}.wdi_spider_ajax_loading{border:none!important;-moz-animation:spin 2.5s infinite linear;-o-animation:spin 2.5s infinite linear;-webkit-animation:spin 2.5s infinite linear;animation:spin 2.5s infinite linear}.footer-list-block .bwp_gallery .wdi_spider_popup_overlay,.footer-list-block .bwp_gallery_tags .wdi_spider_popup_overlay,.wdi_spider_popup_overlay{cursor:pointer;display:none;height:100%;left:0;position:fixed;top:0;width:100%;z-index:10100}.wdi_spider_popup_close,.wdi_spider_popup_close_fullscreen{-moz-box-sizing:content-box!important;box-sizing:content-box!important;cursor:pointer;display:table;line-height:0;position:absolute;z-index:11100}#wdi_spider_popup_left{left:0}#wdi_spider_popup_right{right:0}#wdi_spider_popup_left:hover,#wdi_spider_popup_right:hover{visibility:visible}#wdi_spider_popup_left:hover span{left:20px}#wdi_spider_popup_right:hover span{left:auto;right:20px}#wdi_spider_popup_left,#wdi_spider_popup_right{background:transparent url(../images/blank.gif) repeat scroll 0 0;bottom:35%;cursor:pointer;display:inline;height:30%;outline:medium none;position:absolute;width:35%;z-index:10130}#wdi_spider_popup_left-ico,#wdi_spider_popup_right-ico{-moz-box-sizing:border-box;box-sizing:border-box;cursor:pointer;display:table;left:-9999px;line-height:0;margin-top:-15px;position:absolute;top:50%;z-index:10135}.wdi_image_info_container1{height:100%;margin:0 auto;position:absolute;width:100%}.wdi_image_info_container2{display:table;height:100%;margin:0 auto;position:absolute;width:100%}.wdi_image_info_spun{display:table-cell;height:100%;left:0;top:0;width:100%;overflow:hidden;position:relative}.wdi_image_info{display:inline-block;position:relative;text-decoration:none;word-wrap:break-word;z-index:11}.wdi_photo_wrap_inner{text-align:center}.wdi_feed_item[wdi_type=slideshow] .tenweb-i-clone{-webkit-transform:rotate(180deg);-moz-transform:rotate(180deg);-o-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.wdi_js_error_no_animate,.wdi_token_error{text-align:center;font-size:14px}.wdi_js_error{text-align:center;-webkit-animation-name:wdi_js_error;-moz-animation-name:wdi_js_error;-o-animation-name:wdi_js_error;animation-name:wdi_js_error;-webkit-animation-duration:.5s;-moz-animation-duration:.5s;-o-animation-duration:.5s;animation-duration:.5s;-webkit-animation-delay:20s;-moz-animation-delay:20s;-o-animation-delay:20s;animation-delay:20s;-webkit-animation-fill-mode:forwards;-moz-animation-fill-mode:forwards;-o-animation-fill-mode:forwards;animation-fill-mode:forwards;color:#c00;-webkit-transform:scale(0);-moz-transform:scale(0);-ms-transform:scale(0);-o-transform:scale(0);transform:scale(0);font-size:12px}@keyframes wdi_js_error{from{visibility:hidden;-webkit-transform:scale(0);-moz-transform:scale(0);-ms-transform:scale(0);-o-transform:scale(0);transform:scale(0)}to{visibility:visible;-webkit-transform:scale(1);-moz-transform:scale(1);-ms-transform:scale(1);-o-transform:scale(1);transform:scale(1)}}.wdi_layout_th .wdi_feed_container{min-width:160px;margin:0 auto}.wdi_layout_th .wdi_feed_wrapper{margin:0 auto}.wdi_layout_th .wdi_header_wrapper{display:inline-table}.wdi_layout_th .wdi_header_img_wrap{overflow:hidden}.wdi_layout_th .wdi_header_text{display:table-cell;vertical-align:middle}.wdi_layout_th .wdi_single_user{display:inline-block;float:left}.wdi_layout_th .wdi_user_img_wrap{display:inline-block;float:left;position:relative}.wdi_layout_th .wdi_header_user_text{display:inline-block;float:left;width:100%}.wdi_layout_th .wdi_followers,.wdi_layout_th .wdi_posts{display:inline-block}.wdi_layout_th .wdi_feed_container .wdi_feed_info .wdi_header_user_text h3{display:inline-block;text-transform:none}.wdi_layout_th .wdi_header_user_text h3:hover{cursor:pointer}.wdi_layout_th .wdi_user_img_wrap img{overflow:hidden;display:block;margin:0}.wdi_layout_th .wdi_feed_container .wdi_feed_info .wdi_header_user_text h3{margin-left:10px;margin-bottom:0;padding:0}.wdi_layout_th .wdi_feed_container .wdi_feed_info .wdi_media_info p{margin-top:0;margin-bottom:0}.wdi_layout_th .wdi_user_controls{margin-left:0;display:inline-block;vertical-align:middle}.wdi_layout_th .wdi_bio{float:left}.wdi_layout_th .wdi_feed_container .wdi_feed_info .wdi_header_user_text .wdi_followers{margin-left:10px}.wdi_layout_th .wdi_filter_overlay{position:absolute;z-index:2;top:0;left:0;opacity:0;transition:opacity .1s ease}.wdi_layout_th .wdi_filter_overlay:hover{opacity:.9;cursor:pointer}.wdi_layout_th .wdi_photo_wrap{position:relative;display:inline-block;overflow:hidden;box-sizing:content-box}.wdi_layout_th .wdi_photo_wrap:after{padding-top:100%;display:block;content:""}.wdi_layout_th .wdi_photo_wrap_inner{position:absolute;top:0;bottom:0;left:0;right:0}.wdi_layout_th .wdi_photo_img{width:100%;height:100%}.wdi_layout_th .wdi_img{display:block;position:absolute;top:50%;left:50%;max-width:none;-webkit-transform:translateX(-50%) translateY(-50%);-moz-transform:translateX(-50%) translateY(-50%);-ms-transform:translateX(-50%) translateY(-50%);-o-transform:translateX(-50%) translateY(-50%);transform:translateX(-50%) translateY(-50%)}.wdi_layout_th .wdi_shape_portrait .wdi_img,.wdi_layout_th .wdi_shape_square .wdi_img{width:100%;height:auto}.wdi_layout_th .wdi_shape_landscape .wdi_img{height:100%!important;width:auto}.wdi_layout_th .wdi_feed_item{width:100%;display:inline-block;vertical-align:top;overflow:hidden}.wdi_layout_th .wdi_photo_meta{text-align:center;padding-bottom:10px;line-height:1.4}.wdi_layout_th .wdi_thumb_comments i,.wdi_layout_th .wdi_thumb_likes i{width:100%}.wdi_layout_th .wdi_photo_title{text-overflow:ellipsis;overflow:hidden;white-space:nowrap;width:90%;margin-left:5%;margin-right:5%;text-align:center}.wdi_layout_th .wdi_photo_title:hover{cursor:pointer}@-moz-keyframes wdi_rotate{from{transform:rotate(0)}to{transform:rotate(360deg)}}@-o-keyframes wdi_rotate{from{transform:rotate(0)}to{transform:rotate(360deg)}}@-ms-keyframes wdi_rotate{from{transform:rotate(0)}to{transform:rotate(360deg)}}@-webkit-keyframes wdi_rotate{from{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes wdi_rotate{from{transform:rotate(0)}to{transform:rotate(360deg)}}.wdi_layout_bs .wdi_load_more_spinner,.wdi_layout_ms .wdi_load_more_spinner,.wdi_layout_th .wdi_load_more_spinner{display:table-cell;vertical-align:middle;-webkit-animation:wdi_rotate 1.5s infinite;-moz-animation:wdi_rotate 1.5s infinite;-o-animation:wdi_rotate 1.5s infinite;animation:wdi_rotate 1.5s infinite}.wdi_layout_th .wdi_load_more,.wdi_layout_th .wdi_spinner{padding:10px;transition:all .2s ease}.wdi_layout_th .wdi_load_more_wrap,.wdi_layout_th .wdi_spinner_wrap{display:inline-table;box-sizing:border-box}.wdi_layout_th .wdi_load_more_wrap_inner,.wdi_layout_th .wdi_spinner_wrap_inner{display:table-row;text-align:center}.wdi_layout_th .wdi_load_more_text{display:table-cell;vertical-align:middle}.wdi_layout_th .wdi_load_more_text img{float:left}.wdi_layout_th .wdi_load_more_wrap:hover{cursor:pointer}.wdi_layout_th .wdi_photo_overlay{transition:all .5s ease}.wdi_layout_th .wdi_photo_overlay:hover{cursor:pointer}.wdi_layout_th .wdi_photo_overlay i{color:transparent;transition:all .5s ease}.wdi_layout_th .wdi_photo_img img{transition:all .5s ease}.wdi_layout_th .wdi_load_more_container{display:inline-block}.wdi_layout_th .wdi_media_user{position:absolute;bottom:0;right:0;font-size:16px;border-radius:100px 0 0 0;padding-left:10px;padding-right:5px;line-height:1.5}.wdi_layout_ms .wdi_feed_container{min-width:160px;margin:0 auto}.wdi_layout_ms .wdi_feed_wrapper{position:relative;margin:0 auto}.wdi_layout_ms .wdi_header_wrapper{display:inline-table}.wdi_layout_ms .wdi_header_img_wrap,.wdi_layout_ms .wdi_users_img_wrap{overflow:hidden}.wdi_layout_ms .wdi_header_text{display:table-cell;vertical-align:middle}.wdi_layout_ms .wdi_single_user{display:inline-block;float:left}.wdi_layout_ms .wdi_user_img_wrap{display:inline-block;float:left;position:relative}.wdi_layout_ms .wdi_header_user_text{display:inline-block;float:left;width:100%}.wdi_layout_ms .wdi_followers,.wdi_layout_ms .wdi_posts{display:inline-block}.wdi_layout_ms .wdi_header_user_text h3{display:inline-block;text-transform:none}.wdi_layout_ms .wdi_header_user_text h3:hover{cursor:pointer}.wdi_layout_ms .wdi_user_img_wrap img{overflow:hidden;display:block;margin:0}.wdi_layout_ms .wdi_feed_container .wdi_feed_info .wdi_header_user_text h3{margin-left:10px;margin-bottom:0}.wdi_layout_ms .wdi_feed_container .wdi_feed_info .wdi_media_info p{margin-top:0;margin-bottom:0}.wdi_layout_ms .wdi_user_controls{margin-left:0;display:inline-block;vertical-align:middle}.wdi_layout_ms .wdi_bio{float:left}.wdi_layout_ms .wdi_feed_container .wdi_feed_info .wdi_header_user_text .wdi_followers{margin-left:10px}.wdi_layout_ms .wdi_filter_overlay{position:absolute;z-index:2;top:0;left:0;opacity:0;transition:opacity .1s ease}.wdi_layout_ms .wdi_filter_overlay:hover{opacity:.9;cursor:pointer}.wdi_layout_ms .wdi_photo_wrap{overflow:hidden;box-sizing:content-box}.wdi_layout_ms .wdi_img{width:100%;display:block}.wdi_layout_ms .wdi_masonry_column{display:block;overflow:hidden;float:left}.wdi_layout_ms .wdi_photo_meta{text-align:center;padding-bottom:10px}.wdi_layout_ms .wdi_likes i,.wdi_layout_ms .wdi_thumb_comments i{width:100%}.wdi_layout_ms .wdi_photo_title{text-overflow:ellipsis;overflow:hidden;width:90%;margin-left:5%;margin-right:5%;text-align:center}.wdi_layout_ms .wdi_photo_title:hover{cursor:pointer}.wdi_layout_ms .wdi_load_more,.wdi_layout_ms .wdi_spinner{padding:10px;transition:all .2s ease}.wdi_layout_ms .wdi_load_more_wrap,.wdi_layout_ms .wdi_spinner_wrap{display:inline-table;box-sizing:border-box}.wdi_layout_ms .wdi_load_more_wrap_inner,.wdi_layout_ms .wdi_spinner_wrap_inner{display:table-row;text-align:center}.wdi_layout_ms .wdi_load_more_text{display:table-cell;vertical-align:middle}.wdi_layout_ms .wdi_load_more_text img{float:left}.wdi_layout_ms .wdi_load_more_wrap:hover{cursor:pointer}.wdi_layout_ms .wdi_photo_overlay{transition:all .5s ease}.wdi_layout_ms .wdi_photo_overlay:hover{cursor:pointer}.wdi_layout_ms .wdi_photo_overlay i{color:transparent;transition:all .5s ease}.wdi_layout_ms .wdi_photo_img img{transition:all .5s ease}.wdi_layout_ms .wdi_load_more_container{display:inline-block}.wdi_layout_ms .wdi_media_user{position:absolute;bottom:0;right:0;font-size:16px;border-radius:100px 0 0 0;padding-left:10px;padding-right:5px}.wdi_layout_ib .wdi_feed_container{min-width:160px;margin:0 auto}.wdi_layout_ib .wdi_feed_wrapper{margin:0 auto}.wdi_layout_ib .wdi_header_wrapper{display:inline-table}.wdi_layout_ib .wdi_header_img_wrap,.wdi_layout_ib .wdi_users_img_wrap{overflow:hidden}.wdi_layout_ib .wdi_header_text{display:table-cell;vertical-align:middle}.wdi_layout_ib .wdi_single_user{display:inline-block;float:left}.wdi_layout_ib .wdi_user_img_wrap{display:inline-block;float:left;position:relative}.wdi_layout_ib .wdi_header_user_text{display:inline-block;float:left;width:100%}.wdi_layout_ib .wdi_followers,.wdi_layout_ib .wdi_posts{display:inline-block}.wdi_layout_ib .wdi_feed_container .wdi_feed_info .wdi_header_user_text h3{display:inline-block;text-transform:none}.wdi_layout_ib .wdi_header_user_text h3:hover{cursor:pointer}.wdi_layout_ib .wdi_user_img_wrap img{overflow:hidden;display:block;margin:0}.wdi_layout_ib .wdi_feed_container .wdi_feed_info .wdi_header_user_text h3{margin-left:10px;margin-bottom:0;padding:0}.wdi_layout_ib .wdi_feed_container .wdi_feed_info .wdi_media_info p{margin-top:0;margin-bottom:0}.wdi_layout_ib .wdi_user_controls{margin-left:0;display:inline-block;vertical-align:middle}.wdi_layout_ib .wdi_bio{float:left}.wdi_layout_ib .wdi_feed_container .wdi_feed_info .wdi_header_user_text .wdi_followers{margin-left:10px}.wdi_layout_ib .wdi_filter_overlay{position:absolute;z-index:2;top:0;left:0;opacity:0;transition:opacity .1s ease}.wdi_layout_ib .wdi_filter_overlay:hover{opacity:.9;cursor:pointer}.wdi_layout_ib .wdi_photo_wrap{overflow:hidden;box-sizing:content-box}.wdi_layout_ib .wdi_img{width:100%;display:block}.wdi_layout_ib .wdi_feed_item{display:inline-block;overflow:hidden}.wdi_layout_ib .wdi_photo_meta{text-align:center;padding-bottom:10px}.wdi_layout_ib .wdi_thumb_comments i,.wdi_layout_ib .wdi_thumb_likes i{width:100%}.wdi_layout_ib .wdi_photo_title{text-overflow:ellipsis;overflow:hidden;white-space:nowrap;width:90%;margin-left:5%;margin-right:5%;text-align:center}.wdi_layout_ib .wdi_photo_title:hover{cursor:pointer}.wdi_layout_ib .wdi_load_more{padding:10px;transition:all .2s ease}.wdi_layout_ib .wdi_load_more_wrap{display:inline-table;box-sizing:border-box}.wdi_layout_ib .wdi_load_more_wrap_inner{display:table-row;text-align:center}.wdi_layout_ib .wdi_load_more_text{display:table-cell;vertical-align:middle}.wdi_layout_ib .wdi_load_more_text img{float:left}.wdi_layout_ib .wdi_load_more_wrap:hover{cursor:pointer}.wdi_layout_ib .wdi_photo_overlay:hover{cursor:pointer}.wdi_layout_ib .wdi_load_more_container{display:inline-block}.wdi_layout_bs .wdi_feed_container{min-width:160px;margin:0 auto}.wdi_layout_bs .wdi_feed_wrapper{margin:0 auto}.wdi_layout_bs .wdi_header_wrapper{display:inline-table}.wdi_layout_bs .wdi_header_img_wrap,.wdi_layout_bs .wdi_users_img_wrap{overflow:hidden}.wdi_layout_bs .wdi_header_text{display:table-cell;vertical-align:middle}.wdi_layout_bs .wdi_single_user{display:inline-block;float:left}.wdi_layout_bs .wdi_user_img_wrap{display:inline-block;float:left;position:relative}.wdi_layout_bs .wdi_header_user_text{display:inline-block;float:left;width:100%}.wdi_layout_bs .wdi_followers,.wdi_layout_bs .wdi_posts{display:inline-block}.wdi_layout_bs .wdi_header_user_text h3{display:inline-block;text-transform:none}.wdi_layout_bs .wdi_header_user_text h3:hover{cursor:pointer}.wdi_layout_bs .wdi_user_img_wrap img{overflow:hidden;display:block;margin:0}.wdi_layout_bs .wdi_feed_container .wdi_feed_info .wdi_header_user_text h3{margin-left:10px;margin-bottom:0}.wdi_feed_info .wdi_header_user_text h3{padding-top:0}.wdi_layout_bs .wdi_feed_container .wdi_feed_info .wdi_media_info p{margin-top:0;margin-bottom:0}.wdi_layout_bs .wdi_user_controls{margin-left:0;display:inline-block;vertical-align:middle}.wdi_layout_bs .wdi_bio{float:left}.wdi_layout_bs .wdi_feed_container .wdi_feed_info .wdi_header_user_text .wdi_followers{margin-left:10px}.wdi_layout_bs .wdi_filter_overlay{position:absolute;z-index:2;top:0;left:0;opacity:0;transition:opacity .1s ease}.wdi_layout_bs .wdi_filter_overlay:hover{opacity:.9;cursor:pointer}.wdi_layout_bs .wdi_photo_wrap{overflow:hidden;box-sizing:content-box}.wdi_layout_bs .wdi_img{width:100%;display:block}.wdi_layout_bs .wdi_feed_item{display:inline-block;overflow:hidden}.wdi_layout_bs .wdi_photo_meta{text-align:center;padding-bottom:10px}.wdi_layout_bs .wdi_thumb_comments i,.wdi_layout_bs .wdi_thumb_likes i{width:100%}.wdi_layout_bs .wdi_photo_title{text-overflow:ellipsis;overflow:hidden;white-space:normal;width:90%;margin-left:5%;margin-right:5%;text-align:center}.wdi_layout_bs .wdi_load_more,.wdi_layout_bs .wdi_spinner{padding:10px;transition:all .2s ease}.wdi_layout_bs .wdi_load_more_wrap,.wdi_layout_bs .wdi_spinner_wrap{display:inline-table;box-sizing:border-box}.wdi_layout_bs .wdi_load_more_wrap_inner,.wdi_layout_bs .wdi_spinner_wrap_inner{display:table-row;text-align:center}.wdi_layout_bs .wdi_load_more_text{display:table-cell;vertical-align:middle}.wdi_layout_bs .wdi_load_more_text img{float:left}.wdi_layout_bs .wdi_load_more_wrap:hover{cursor:pointer}.wdi_layout_bs .wdi_photo_overlay:hover{cursor:pointer}.wdi_layout_bs .wdi_load_more_container{display:inline-block}.wdi_embed_frame video{display:inline-block}.wdi_image_container img{display:inline}.wdi_carousel_btn_container{height:20px;position:absolute;width:100%;bottom:65px;z-index:10150;font-size:0}.wdi_carousel_btn_container span{background:rgba(255,255,255,.5);width:10px;height:10px;display:inline-block;border-radius:5px;cursor:pointer;margin-right:9px;position:relative;left:0;transition:left .3s;-webkit-transition:left .3s;-moz-transition:left .3s}.wdi_carousel_btn_container span:last-child{margin-right:0}.wdi_carousel_btn_container span.active{background:#fff}.wdi_carousel_btn_container span.small{width:7px;height:7px;margin-right:12px;top:-2px}.wdi_carousel_btn_content{display:inline-block;overflow:hidden;white-space:nowrap;position:relative;padding:8px 9px;background:rgba(0,0,0,.17);border-radius:21px}.wdi_image_container .carousel_media:not(.active){display:none}.wdi_website{width:100%;display:block;float:left}.wdi_website a{box-shadow:none!important;color:#003569;text-decoration:none}.elementor-editor-active .wdi_front_overlay{position:absolute;top:0;left:0;width:100%;height:100%;background-color:rgba(0,0,0,.2)}#wdi_added_comments{padding-top:20px}.wdi_comment_container #ajax_loading{left:calc(50% - 25px);top:calc(50% - 25px)}
|
| 1 |
+
.wdi_clear{clear:both}.wdi_feed_main_container .table{display:table}.wdi_feed_main_container .table-cell{display:table-cell}.wdi_feed_main_container .table-row{display:table-row}.wdi_feed_main_container{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none}.wdi_follow_button:hover{cursor:pointer}.wdi_hidden{display:none!important}.wdi_hover_off:hover{background-color:transparent!important}.wdi_cursor_off:hover{cursor:auto!important}.wdi_filter_active span{color:#fff}.wdi_disabled{visibility:hidden}.wdi_ajax_loading{width:50px;height:50px;margin:auto}.wdi_page_loading{position:absolute;top:calc(50% - 25px);left:calc(50% - 25px);width:50px;height:50px;margin:auto}.wdi_feed_main_container{width:100%;position:relative}.wdi_feed_main_container .wdi_img{margin:0}.wdi_feed_main_container .wdi_follow_btn{display:inline-block;background:0 0;border-style:solid;border-width:1px;font-weight:500;outline:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;-webkit-appearance:none;vertical-align:text-bottom}.wdi_feed_main_container .wdi_follow_btn:hover{cursor:pointer}.wdi_feed_main_container .wdi_pagination{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none}.wdi_feed_main_container .wdi_pagination_ctrl{display:inline-block}.wdi_feed_main_container .wdi_pagination_ctrl:hover{cursor:pointer}.wdi_feed_main_container .wdi_filter_icon span{display:block;font-size:25px;color:#fff}.wdi_feed_main_container .wdi_filter_icon span::before{width:20px;height:20px;position:absolute;opacity:1;right:0;left:0;top:0;bottom:0;margin:auto}.wdi_photo_img{position:relative;overflow:hidden}.wdi_photo_overlay{width:100%;height:100%;position:absolute;top:0;left:0;background-color:transparent;transition:all .1s ease}.wdi_photo_overlay:hover .wdi_thumb_icon i{display:block}.wdi_feed_main_container .tenweb{font-family:tenweb!important;font-style:normal;width:auto;speak:none;display:inline-block;line-height:1;font-weight:400;font-variant:normal;text-transform:none;vertical-align:top;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.wdi_media_info .tenweb-i:before{margin-right:6px}.wdi_spider_popup_loading{background-image:url(../images/ajax_loader.png);background-color:rgba(0,0,0,0);background-repeat:no-repeat;background-position:0 0;background-size:50px 50px;border:none!important;display:none;height:50px;left:50%;margin-left:-20px;margin-top:-20px;overflow:hidden;position:fixed;top:50%;width:50px;z-index:10102;-moz-animation:spin 2.5s infinite linear;-o-animation:spin 2.5s infinite linear;-webkit-animation:spin 2.5s infinite linear;animation:spin 2.5s infinite linear}.wdi_spider_popup_overlay{cursor:pointer;background-color:rgba(0,0,0,.5);display:none;height:100%;left:0;position:fixed;top:0;width:100%;z-index:10100}div[id^=wdi_container] p{padding:0!important;margin:0!important}.footer-list-block .bwp_gallery .wdi_spider_popup_loading,.footer-list-block .bwp_gallery_tags .wdi_spider_popup_loading,.wdi_spider_popup_loading{background-image:url(../images/ajax_loader.png);background-color:rgba(0,0,0,0);background-repeat:no-repeat;background-position:0 0;background-size:50px 50px;border:none!important;display:none;height:50px;left:50%;margin-left:-20px;margin-top:-20px;overflow:hidden;position:fixed;top:50%;width:50px;z-index:10102;-moz-animation:spin 2.5s infinite linear;-o-animation:spin 2.5s infinite linear;-webkit-animation:spin 2.5s infinite linear;animation:spin 2.5s infinite linear}.wdi_spider_ajax_loading{border:none!important;-moz-animation:spin 2.5s infinite linear;-o-animation:spin 2.5s infinite linear;-webkit-animation:spin 2.5s infinite linear;animation:spin 2.5s infinite linear}.footer-list-block .bwp_gallery .wdi_spider_popup_overlay,.footer-list-block .bwp_gallery_tags .wdi_spider_popup_overlay,.wdi_spider_popup_overlay{cursor:pointer;display:none;height:100%;left:0;position:fixed;top:0;width:100%;z-index:10100}.wdi_spider_popup_close,.wdi_spider_popup_close_fullscreen{-moz-box-sizing:content-box!important;box-sizing:content-box!important;cursor:pointer;display:table;line-height:0;position:absolute;z-index:11100}#wdi_spider_popup_left{left:0}#wdi_spider_popup_right{right:0}#wdi_spider_popup_left:hover,#wdi_spider_popup_right:hover{visibility:visible}#wdi_spider_popup_left:hover span{left:20px}#wdi_spider_popup_right:hover span{left:auto;right:20px}#wdi_spider_popup_left,#wdi_spider_popup_right{background:transparent url(../images/blank.gif) repeat scroll 0 0;bottom:35%;cursor:pointer;display:inline;height:30%;outline:medium none;position:absolute;width:35%;z-index:10130}#wdi_spider_popup_left-ico,#wdi_spider_popup_right-ico{-moz-box-sizing:border-box;box-sizing:border-box;cursor:pointer;display:table;left:-9999px;line-height:0;margin-top:-15px;position:absolute;top:50%;z-index:10135}.wdi_image_info_container1{height:100%;margin:0 auto;position:absolute;width:100%}.wdi_image_info_container2{display:table;height:100%;margin:0 auto;position:absolute;width:100%}.wdi_image_info_spun{display:table-cell;height:100%;left:0;top:0;width:100%;overflow:hidden;position:relative}.wdi_image_info{display:inline-block;position:relative;text-decoration:none;word-wrap:break-word;z-index:11}.wdi_photo_wrap_inner{text-align:center}.wdi_feed_item[wdi_type=slideshow] .tenweb-i-clone{-webkit-transform:rotate(180deg);-moz-transform:rotate(180deg);-o-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.wdi_js_error_no_animate,.wdi_token_error{text-align:center;font-size:14px}.wdi_js_error{text-align:center;-webkit-animation-name:wdi_js_error;-moz-animation-name:wdi_js_error;-o-animation-name:wdi_js_error;animation-name:wdi_js_error;-webkit-animation-duration:.5s;-moz-animation-duration:.5s;-o-animation-duration:.5s;animation-duration:.5s;-webkit-animation-delay:20s;-moz-animation-delay:20s;-o-animation-delay:20s;animation-delay:20s;-webkit-animation-fill-mode:forwards;-moz-animation-fill-mode:forwards;-o-animation-fill-mode:forwards;animation-fill-mode:forwards;color:#c00;-webkit-transform:scale(0);-moz-transform:scale(0);-ms-transform:scale(0);-o-transform:scale(0);transform:scale(0);font-size:12px}@keyframes wdi_js_error{from{visibility:hidden;-webkit-transform:scale(0);-moz-transform:scale(0);-ms-transform:scale(0);-o-transform:scale(0);transform:scale(0)}to{visibility:visible;-webkit-transform:scale(1);-moz-transform:scale(1);-ms-transform:scale(1);-o-transform:scale(1);transform:scale(1)}}.wdi_layout_th .wdi_feed_container{position:relative;min-width:160px;margin:0 auto}.wdi_layout_th .wdi_feed_wrapper{margin:0 auto}.wdi_layout_th .wdi_header_wrapper{display:inline-table}.wdi_layout_th .wdi_header_img_wrap{overflow:hidden}.wdi_layout_th .wdi_header_text{display:table-cell;vertical-align:middle}.wdi_layout_th .wdi_single_user{display:inline-block;float:left}.wdi_layout_th .wdi_user_img_wrap{display:inline-block;float:left;position:relative}.wdi_layout_th .wdi_header_user_text{display:inline-block;float:left;width:100%}.wdi_layout_th .wdi_followers,.wdi_layout_th .wdi_posts{display:inline-block}.wdi_layout_th .wdi_feed_container .wdi_feed_info .wdi_header_user_text h3{display:inline-block;text-transform:none}.wdi_layout_th .wdi_header_user_text h3:hover{cursor:pointer}.wdi_layout_th .wdi_user_img_wrap img{overflow:hidden;display:block;margin:0}.wdi_layout_th .wdi_feed_container .wdi_feed_info .wdi_header_user_text h3{margin-left:10px;margin-bottom:0;padding:0}.wdi_layout_th .wdi_feed_container .wdi_feed_info .wdi_media_info p{margin-top:0;margin-bottom:0}.wdi_layout_th .wdi_user_controls{margin-left:0;display:inline-block;vertical-align:middle}.wdi_layout_th .wdi_bio{float:left}.wdi_layout_th .wdi_feed_container .wdi_feed_info .wdi_header_user_text .wdi_followers{margin-left:10px}.wdi_layout_th .wdi_filter_overlay{position:absolute;z-index:2;top:0;left:0;opacity:0;transition:opacity .1s ease}.wdi_layout_th .wdi_filter_overlay:hover{opacity:.9;cursor:pointer}.wdi_layout_th .wdi_photo_wrap{position:relative;display:inline-block;overflow:hidden;box-sizing:content-box}.wdi_layout_th .wdi_photo_wrap:after{padding-top:100%;display:block;content:""}.wdi_layout_th .wdi_photo_wrap_inner{position:absolute;top:0;bottom:0;left:0;right:0}.wdi_layout_th .wdi_photo_img{width:100%;height:100%}.wdi_layout_th .wdi_img{display:block;position:absolute;top:50%;left:50%;max-width:none;-webkit-transform:translateX(-50%) translateY(-50%);-moz-transform:translateX(-50%) translateY(-50%);-ms-transform:translateX(-50%) translateY(-50%);-o-transform:translateX(-50%) translateY(-50%);transform:translateX(-50%) translateY(-50%)}.wdi_layout_th .wdi_shape_portrait .wdi_img,.wdi_layout_th .wdi_shape_square .wdi_img{width:100%;height:auto}.wdi_layout_th .wdi_shape_landscape .wdi_img{height:100%!important;width:auto}.wdi_layout_th .wdi_feed_item{width:100%;display:inline-block;vertical-align:top;overflow:hidden}.wdi_layout_th .wdi_photo_meta{text-align:center;padding-bottom:10px;line-height:1.4}.wdi_layout_th .wdi_thumb_comments i,.wdi_layout_th .wdi_thumb_likes i{width:100%}.wdi_layout_th .wdi_photo_title{text-overflow:ellipsis;overflow:hidden;white-space:nowrap;width:90%;margin-left:5%;margin-right:5%;text-align:center}.wdi_layout_th .wdi_photo_title:hover{cursor:pointer}@-moz-keyframes wdi_rotate{from{transform:rotate(0)}to{transform:rotate(360deg)}}@-o-keyframes wdi_rotate{from{transform:rotate(0)}to{transform:rotate(360deg)}}@-ms-keyframes wdi_rotate{from{transform:rotate(0)}to{transform:rotate(360deg)}}@-webkit-keyframes wdi_rotate{from{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes wdi_rotate{from{transform:rotate(0)}to{transform:rotate(360deg)}}.wdi_layout_bs .wdi_load_more_spinner,.wdi_layout_ms .wdi_load_more_spinner,.wdi_layout_th .wdi_load_more_spinner{display:table-cell;vertical-align:middle;-webkit-animation:wdi_rotate 1.5s infinite;-moz-animation:wdi_rotate 1.5s infinite;-o-animation:wdi_rotate 1.5s infinite;animation:wdi_rotate 1.5s infinite}.wdi_layout_th .wdi_load_more,.wdi_layout_th .wdi_spinner{padding:10px;transition:all .2s ease}.wdi_layout_th .wdi_load_more_wrap,.wdi_layout_th .wdi_spinner_wrap{display:inline-table;box-sizing:border-box}.wdi_layout_th .wdi_load_more_wrap_inner,.wdi_layout_th .wdi_spinner_wrap_inner{display:table-row;text-align:center}.wdi_layout_th .wdi_load_more_text{display:table-cell;vertical-align:middle}.wdi_layout_th .wdi_load_more_text img{float:left}.wdi_layout_th .wdi_load_more_wrap:hover{cursor:pointer}.wdi_layout_th .wdi_photo_overlay{transition:all .5s ease}.wdi_layout_th .wdi_photo_overlay:hover{cursor:pointer}.wdi_layout_th .wdi_photo_overlay i{color:transparent;transition:all .5s ease}.wdi_layout_th .wdi_photo_img img{transition:all .5s ease}.wdi_layout_th .wdi_load_more_container{display:inline-block}.wdi_layout_th .wdi_media_user{position:absolute;bottom:0;right:0;font-size:16px;border-radius:100px 0 0 0;padding-left:10px;padding-right:5px;line-height:1.5}.wdi_layout_ms .wdi_feed_container{min-width:160px;margin:0 auto}.wdi_layout_ms .wdi_feed_wrapper{position:relative;margin:0 auto}.wdi_layout_ms .wdi_header_wrapper{display:inline-table}.wdi_layout_ms .wdi_header_img_wrap,.wdi_layout_ms .wdi_users_img_wrap{overflow:hidden}.wdi_layout_ms .wdi_header_text{display:table-cell;vertical-align:middle}.wdi_layout_ms .wdi_single_user{display:inline-block;float:left}.wdi_layout_ms .wdi_user_img_wrap{display:inline-block;float:left;position:relative}.wdi_layout_ms .wdi_header_user_text{display:inline-block;float:left;width:100%}.wdi_layout_ms .wdi_followers,.wdi_layout_ms .wdi_posts{display:inline-block}.wdi_layout_ms .wdi_header_user_text h3{display:inline-block;text-transform:none}.wdi_layout_ms .wdi_header_user_text h3:hover{cursor:pointer}.wdi_layout_ms .wdi_user_img_wrap img{overflow:hidden;display:block;margin:0}.wdi_layout_ms .wdi_feed_container .wdi_feed_info .wdi_header_user_text h3{margin-left:10px;margin-bottom:0}.wdi_layout_ms .wdi_feed_container .wdi_feed_info .wdi_media_info p{margin-top:0;margin-bottom:0}.wdi_layout_ms .wdi_user_controls{margin-left:0;display:inline-block;vertical-align:middle}.wdi_layout_ms .wdi_bio{float:left}.wdi_layout_ms .wdi_feed_container .wdi_feed_info .wdi_header_user_text .wdi_followers{margin-left:10px}.wdi_layout_ms .wdi_filter_overlay{position:absolute;z-index:2;top:0;left:0;opacity:0;transition:opacity .1s ease}.wdi_layout_ms .wdi_filter_overlay:hover{opacity:.9;cursor:pointer}.wdi_layout_ms .wdi_photo_wrap{overflow:hidden;box-sizing:content-box}.wdi_layout_ms .wdi_img{width:100%;display:block}.wdi_layout_ms .wdi_masonry_column{display:block;overflow:hidden;float:left}.wdi_layout_ms .wdi_photo_meta{text-align:center;padding-bottom:10px}.wdi_layout_ms .wdi_likes i,.wdi_layout_ms .wdi_thumb_comments i{width:100%}.wdi_layout_ms .wdi_photo_title{text-overflow:ellipsis;overflow:hidden;width:90%;margin-left:5%;margin-right:5%;text-align:center}.wdi_layout_ms .wdi_photo_title:hover{cursor:pointer}.wdi_layout_ms .wdi_load_more,.wdi_layout_ms .wdi_spinner{padding:10px;transition:all .2s ease}.wdi_layout_ms .wdi_load_more_wrap,.wdi_layout_ms .wdi_spinner_wrap{display:inline-table;box-sizing:border-box}.wdi_layout_ms .wdi_load_more_wrap_inner,.wdi_layout_ms .wdi_spinner_wrap_inner{display:table-row;text-align:center}.wdi_layout_ms .wdi_load_more_text{display:table-cell;vertical-align:middle}.wdi_layout_ms .wdi_load_more_text img{float:left}.wdi_layout_ms .wdi_load_more_wrap:hover{cursor:pointer}.wdi_layout_ms .wdi_photo_overlay{transition:all .5s ease}.wdi_layout_ms .wdi_photo_overlay:hover{cursor:pointer}.wdi_layout_ms .wdi_photo_overlay i{color:transparent;transition:all .5s ease}.wdi_layout_ms .wdi_photo_img img{transition:all .5s ease}.wdi_layout_ms .wdi_load_more_container{display:inline-block}.wdi_layout_ms .wdi_media_user{position:absolute;bottom:0;right:0;font-size:16px;border-radius:100px 0 0 0;padding-left:10px;padding-right:5px}.wdi_layout_ib .wdi_feed_container{min-width:160px;margin:0 auto}.wdi_layout_ib .wdi_feed_wrapper{margin:0 auto}.wdi_layout_ib .wdi_header_wrapper{display:inline-table}.wdi_layout_ib .wdi_header_img_wrap,.wdi_layout_ib .wdi_users_img_wrap{overflow:hidden}.wdi_layout_ib .wdi_header_text{display:table-cell;vertical-align:middle}.wdi_layout_ib .wdi_single_user{display:inline-block;float:left}.wdi_layout_ib .wdi_user_img_wrap{display:inline-block;float:left;position:relative}.wdi_layout_ib .wdi_header_user_text{display:inline-block;float:left;width:100%}.wdi_layout_ib .wdi_followers,.wdi_layout_ib .wdi_posts{display:inline-block}.wdi_layout_ib .wdi_feed_container .wdi_feed_info .wdi_header_user_text h3{display:inline-block;text-transform:none}.wdi_layout_ib .wdi_header_user_text h3:hover{cursor:pointer}.wdi_layout_ib .wdi_user_img_wrap img{overflow:hidden;display:block;margin:0}.wdi_layout_ib .wdi_feed_container .wdi_feed_info .wdi_header_user_text h3{margin-left:10px;margin-bottom:0;padding:0}.wdi_layout_ib .wdi_feed_container .wdi_feed_info .wdi_media_info p{margin-top:0;margin-bottom:0}.wdi_layout_ib .wdi_user_controls{margin-left:0;display:inline-block;vertical-align:middle}.wdi_layout_ib .wdi_bio{float:left}.wdi_layout_ib .wdi_feed_container .wdi_feed_info .wdi_header_user_text .wdi_followers{margin-left:10px}.wdi_layout_ib .wdi_filter_overlay{position:absolute;z-index:2;top:0;left:0;opacity:0;transition:opacity .1s ease}.wdi_layout_ib .wdi_filter_overlay:hover{opacity:.9;cursor:pointer}.wdi_layout_ib .wdi_photo_wrap{overflow:hidden;box-sizing:content-box}.wdi_layout_ib .wdi_img{width:100%;display:block}.wdi_layout_ib .wdi_feed_item{display:inline-block;overflow:hidden}.wdi_layout_ib .wdi_photo_meta{text-align:center;padding-bottom:10px}.wdi_layout_ib .wdi_thumb_comments i,.wdi_layout_ib .wdi_thumb_likes i{width:100%}.wdi_layout_ib .wdi_photo_title{text-overflow:ellipsis;overflow:hidden;white-space:nowrap;width:90%;margin-left:5%;margin-right:5%;text-align:center}.wdi_layout_ib .wdi_photo_title:hover{cursor:pointer}.wdi_layout_ib .wdi_load_more{padding:10px;transition:all .2s ease}.wdi_layout_ib .wdi_load_more_wrap{display:inline-table;box-sizing:border-box}.wdi_layout_ib .wdi_load_more_wrap_inner{display:table-row;text-align:center}.wdi_layout_ib .wdi_load_more_text{display:table-cell;vertical-align:middle}.wdi_layout_ib .wdi_load_more_text img{float:left}.wdi_layout_ib .wdi_load_more_wrap:hover{cursor:pointer}.wdi_layout_ib .wdi_photo_overlay:hover{cursor:pointer}.wdi_layout_ib .wdi_load_more_container{display:inline-block}.wdi_layout_bs .wdi_feed_container{min-width:160px;margin:0 auto}.wdi_layout_bs .wdi_feed_wrapper{margin:0 auto}.wdi_layout_bs .wdi_header_wrapper{display:inline-table}.wdi_layout_bs .wdi_header_img_wrap,.wdi_layout_bs .wdi_users_img_wrap{overflow:hidden}.wdi_layout_bs .wdi_header_text{display:table-cell;vertical-align:middle}.wdi_layout_bs .wdi_single_user{display:inline-block;float:left}.wdi_layout_bs .wdi_user_img_wrap{display:inline-block;float:left;position:relative}.wdi_layout_bs .wdi_header_user_text{display:inline-block;float:left;width:100%}.wdi_layout_bs .wdi_followers,.wdi_layout_bs .wdi_posts{display:inline-block}.wdi_layout_bs .wdi_header_user_text h3{display:inline-block;text-transform:none}.wdi_layout_bs .wdi_header_user_text h3:hover{cursor:pointer}.wdi_layout_bs .wdi_user_img_wrap img{overflow:hidden;display:block;margin:0}.wdi_layout_bs .wdi_feed_container .wdi_feed_info .wdi_header_user_text h3{margin-left:10px;margin-bottom:0}.wdi_feed_info .wdi_header_user_text h3{padding-top:0}.wdi_layout_bs .wdi_feed_container .wdi_feed_info .wdi_media_info p{margin-top:0;margin-bottom:0}.wdi_layout_bs .wdi_user_controls{margin-left:0;display:inline-block;vertical-align:middle}.wdi_layout_bs .wdi_bio{float:left}.wdi_layout_bs .wdi_feed_container .wdi_feed_info .wdi_header_user_text .wdi_followers{margin-left:10px}.wdi_layout_bs .wdi_filter_overlay{position:absolute;z-index:2;top:0;left:0;opacity:0;transition:opacity .1s ease}.wdi_layout_bs .wdi_filter_overlay:hover{opacity:.9;cursor:pointer}.wdi_layout_bs .wdi_photo_wrap{overflow:hidden;box-sizing:content-box}.wdi_layout_bs .wdi_img{width:100%;display:block}.wdi_layout_bs .wdi_feed_item{display:inline-block;overflow:hidden}.wdi_layout_bs .wdi_photo_meta{text-align:center;padding-bottom:10px}.wdi_layout_bs .wdi_thumb_comments i,.wdi_layout_bs .wdi_thumb_likes i{width:100%}.wdi_layout_bs .wdi_photo_title{text-overflow:ellipsis;overflow:hidden;white-space:normal;width:90%;margin-left:5%;margin-right:5%;text-align:center}.wdi_layout_bs .wdi_load_more,.wdi_layout_bs .wdi_spinner{padding:10px;transition:all .2s ease}.wdi_layout_bs .wdi_load_more_wrap,.wdi_layout_bs .wdi_spinner_wrap{display:inline-table;box-sizing:border-box}.wdi_layout_bs .wdi_load_more_wrap_inner,.wdi_layout_bs .wdi_spinner_wrap_inner{display:table-row;text-align:center}.wdi_layout_bs .wdi_load_more_text{display:table-cell;vertical-align:middle}.wdi_layout_bs .wdi_load_more_text img{float:left}.wdi_layout_bs .wdi_load_more_wrap:hover{cursor:pointer}.wdi_layout_bs .wdi_photo_overlay:hover{cursor:pointer}.wdi_layout_bs .wdi_load_more_container{display:inline-block}.wdi_embed_frame video{display:inline-block}.wdi_image_container img{display:inline}.wdi_carousel_btn_container{height:20px;position:absolute;width:100%;bottom:65px;z-index:10150;font-size:0}.wdi_carousel_btn_container span{background:rgba(255,255,255,.5);width:10px;height:10px;display:inline-block;border-radius:5px;cursor:pointer;margin-right:9px;position:relative;left:0;transition:left .3s;-webkit-transition:left .3s;-moz-transition:left .3s}.wdi_carousel_btn_container span:last-child{margin-right:0}.wdi_carousel_btn_container span.active{background:#fff}.wdi_carousel_btn_container span.small{width:7px;height:7px;margin-right:12px;top:-2px}.wdi_carousel_btn_content{display:inline-block;overflow:hidden;white-space:nowrap;position:relative;padding:8px 9px;background:rgba(0,0,0,.17);border-radius:21px}.wdi_image_container .carousel_media:not(.active){display:none}.wdi_website{width:100%;display:block;float:left}.wdi_website a{box-shadow:none!important;color:#003569;text-decoration:none}.wdi_front_overlay{position:absolute;top:0;left:0;right:0;bottom:0;width:100%;height:100%}.elementor-editor-active .wdi_front_overlay{background-color:rgba(0,0,0,.2)}#wdi_added_comments{padding-top:20px}.wdi_comment_container #ajax_loading{left:calc(50% - 25px);top:calc(50% - 25px)}
|
framework/WDIInstagram.php
CHANGED
|
@@ -138,7 +138,7 @@ class WDIInstagram {
|
|
| 138 |
|
| 139 |
return json_encode($data);
|
| 140 |
}
|
| 141 |
-
|
| 142 |
/**
|
| 143 |
* Get all cache datas for feed and merge in one array
|
| 144 |
*
|
| 138 |
|
| 139 |
return json_encode($data);
|
| 140 |
}
|
| 141 |
+
|
| 142 |
/**
|
| 143 |
* Get all cache datas for feed and merge in one array
|
| 144 |
*
|
framework/WDILibrary.php
CHANGED
|
@@ -892,7 +892,7 @@ class WDILibrary {
|
|
| 892 |
return $feed_row;
|
| 893 |
}
|
| 894 |
|
| 895 |
-
$users = json_decode($feed_row['feed_users']);
|
| 896 |
$new_users_list = array();
|
| 897 |
$users_list = self::get_users_list();
|
| 898 |
if(is_array($users)) {
|
| 892 |
return $feed_row;
|
| 893 |
}
|
| 894 |
|
| 895 |
+
$users = json_decode(htmlspecialchars_decode($feed_row['feed_users']));
|
| 896 |
$new_users_list = array();
|
| 897 |
$users_list = self::get_users_list();
|
| 898 |
if(is_array($users)) {
|
frontend/views/imagebrowser.php
CHANGED
|
@@ -38,63 +38,63 @@ class WDI_ImageBrowser_view {
|
|
| 38 |
if ($feed_row['feed_display_view'] === 'pagination' && $style['pagination_position_vert'] === 'top') {
|
| 39 |
?>
|
| 40 |
<div id="wdi_pagination" class="wdi_pagination wdi_hidden">
|
| 41 |
-
|
| 42 |
-
|
| 43 |
-
|
| 44 |
-
id="
|
| 45 |
-
class="tenweb-i tenweb-i-arrow-
|
| 46 |
-
|
| 47 |
-
|
| 48 |
-
|
| 49 |
-
|
| 50 |
-
class="tenweb-i tenweb-i-step-forward wdi_pagination_ctrl wdi_disabled"></i></div></div> <?php
|
| 51 |
}
|
| 52 |
?>
|
| 53 |
-
<div class="wdi_feed_wrapper <?php echo 'wdi_col_' . $feed_row['number_of_columns'] ?>"
|
| 54 |
-
wdi-res='<?php echo 'wdi_col_' . $feed_row['number_of_columns'] ?>'></div>
|
| 55 |
<div class="wdi_clear"></div>
|
| 56 |
-
<?php
|
| 57 |
-
|
| 58 |
-
|
| 59 |
-
|
| 60 |
-
|
| 61 |
-
<div class="
|
| 62 |
-
<div class="
|
| 63 |
-
<div class="
|
|
|
|
|
|
|
| 64 |
</div>
|
| 65 |
-
</div
|
| 66 |
-
|
| 67 |
-
|
| 68 |
-
|
| 69 |
-
|
| 70 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 71 |
?>
|
| 72 |
-
<div id="
|
| 73 |
-
<div class="wdi_pagination_container"><i id="wdi_first_page"
|
| 74 |
-
title="<?php echo __('First Page', "wd-instagram-feed") ?>"
|
| 75 |
-
class="tenweb-i tenweb-i-step-backward wdi_pagination_ctrl wdi_disabled"></i><i
|
| 76 |
-
id="wdi_prev" title="<?php echo __('Previous Page', "wd-instagram-feed") ?>"
|
| 77 |
-
class="tenweb-i tenweb-i-arrow-left wdi_pagination_ctrl"></i><i id="wdi_current_page" class="wdi_pagination_ctrl"
|
| 78 |
-
style="font-style:normal">1</i><i id="wdi_next"
|
| 79 |
-
title="<?php echo __('Next Page', "wd-instagram-feed") ?>"
|
| 80 |
-
class="tenweb-i tenweb-i-arrow-right wdi_pagination_ctrl"></i>
|
| 81 |
-
<i id="wdi_last_page" title="<?php echo __('Last Page', "wd-instagram-feed") ?>"
|
| 82 |
-
class="tenweb-i tenweb-i-step-forward wdi_pagination_ctrl wdi_disabled"></i></div></div> <?php
|
| 83 |
}
|
| 84 |
-
|
| 85 |
-
break;
|
| 86 |
}
|
| 87 |
-
|
| 88 |
-
|
| 89 |
-
|
| 90 |
}
|
| 91 |
-
}
|
| 92 |
?>
|
| 93 |
</div>
|
| 94 |
-
|
| 95 |
</div>
|
| 96 |
<?php
|
| 97 |
-
|
| 98 |
}
|
| 99 |
|
| 100 |
public function pass_feed_data_to_js()
|
| 38 |
if ($feed_row['feed_display_view'] === 'pagination' && $style['pagination_position_vert'] === 'top') {
|
| 39 |
?>
|
| 40 |
<div id="wdi_pagination" class="wdi_pagination wdi_hidden">
|
| 41 |
+
<div class="wdi_pagination_container">
|
| 42 |
+
<i id="wdi_first_page" title="<?php echo __('First Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-step-backward wdi_pagination_ctrl wdi_disabled"></i>
|
| 43 |
+
<i id="wdi_prev" title="<?php echo __('Previous Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-arrow-left wdi_pagination_ctrl"></i>
|
| 44 |
+
<i id="wdi_current_page" class="wdi_pagination_ctrl" style="font-style:normal">1</i>
|
| 45 |
+
<i id="wdi_next" title="<?php echo __('Next Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-arrow-right wdi_pagination_ctrl"></i>
|
| 46 |
+
<i id="wdi_last_page" title="<?php echo __('Last Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-step-forward wdi_pagination_ctrl wdi_disabled"></i>
|
| 47 |
+
</div>
|
| 48 |
+
</div>
|
| 49 |
+
<?php
|
|
|
|
| 50 |
}
|
| 51 |
?>
|
| 52 |
+
<div class="wdi_feed_wrapper <?php echo 'wdi_col_' . $feed_row['number_of_columns'] ?>" wdi-res='<?php echo 'wdi_col_' . $feed_row['number_of_columns'] ?>'></div>
|
|
|
|
| 53 |
<div class="wdi_clear"></div>
|
| 54 |
+
<?php
|
| 55 |
+
switch ($feed_row['feed_display_view']) {
|
| 56 |
+
case 'load_more_btn': {
|
| 57 |
+
?>
|
| 58 |
+
<div class="wdi_load_more">
|
| 59 |
+
<div class="wdi_load_more_container">
|
| 60 |
+
<div class="wdi_load_more_wrap">
|
| 61 |
+
<div class="wdi_load_more_wrap_inner">
|
| 62 |
+
<div class="wdi_load_more_text"><?php echo __('Load More', "wd-instagram-feed"); ?></div>
|
| 63 |
+
</div>
|
| 64 |
</div>
|
| 65 |
+
</div></div><?php
|
| 66 |
+
break;
|
| 67 |
+
}
|
| 68 |
+
case 'pagination': {
|
| 69 |
+
if ($style['pagination_position_vert'] === 'bottom') {
|
| 70 |
+
?>
|
| 71 |
+
<div id="wdi_pagination" class="wdi_pagination wdi_hidden">
|
| 72 |
+
<div class="wdi_pagination_container">
|
| 73 |
+
<i id="wdi_first_page" title="<?php echo __('First Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-step-backward wdi_pagination_ctrl wdi_disabled"></i>
|
| 74 |
+
<i id="wdi_prev" title="<?php echo __('Previous Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-arrow-left wdi_pagination_ctrl"></i>
|
| 75 |
+
<i id="wdi_current_page" class="wdi_pagination_ctrl" style="font-style:normal">1</i>
|
| 76 |
+
<i id="wdi_next" title="<?php echo __('Next Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-arrow-right wdi_pagination_ctrl"></i>
|
| 77 |
+
<i id="wdi_last_page" title="<?php echo __('Last Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-step-forward wdi_pagination_ctrl wdi_disabled"></i>
|
| 78 |
+
</div>
|
| 79 |
+
</div>
|
| 80 |
+
<?php
|
| 81 |
+
}
|
| 82 |
+
break;
|
| 83 |
+
}
|
| 84 |
+
case 'infinite_scroll': {
|
| 85 |
?>
|
| 86 |
+
<div id="wdi_infinite_scroll" class="wdi_infinite_scroll"></div> <?php
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 87 |
}
|
|
|
|
|
|
|
| 88 |
}
|
| 89 |
+
if ($feed_row['feed_display_view'] === 'pagination') { ?>
|
| 90 |
+
<div class="wdi_page_loading wdi_hidden"><img class="wdi_load_more_spinner" src="<?php echo WDI_URL ?>/images/ajax_loader.png"></div>
|
| 91 |
+
<?php
|
| 92 |
}
|
|
|
|
| 93 |
?>
|
| 94 |
</div>
|
| 95 |
+
<div class="wdi_front_overlay"></div>
|
| 96 |
</div>
|
| 97 |
<?php
|
|
|
|
| 98 |
}
|
| 99 |
|
| 100 |
public function pass_feed_data_to_js()
|
frontend/views/thumbnails.php
CHANGED
|
@@ -33,78 +33,70 @@ class WDI_Thumbnails_view {
|
|
| 33 |
} ?>
|
| 34 |
</div>
|
| 35 |
</div>
|
| 36 |
-
<?php
|
| 37 |
-
if ($feed_row['feed_display_view'] === 'pagination' && $style['pagination_position_vert'] === 'top') {
|
| 38 |
-
?>
|
| 39 |
<div id="wdi_pagination" class="wdi_pagination wdi_hidden">
|
| 40 |
-
<div class="wdi_pagination_container"
|
| 41 |
-
|
| 42 |
-
|
| 43 |
-
|
| 44 |
-
|
| 45 |
-
|
| 46 |
-
|
| 47 |
-
|
| 48 |
-
|
| 49 |
-
class="tenweb-i tenweb-i-step-forward wdi_pagination_ctrl wdi_disabled"></i></div></div> <?php
|
| 50 |
-
}
|
| 51 |
-
?>
|
| 52 |
<div class="wdi_feed_wrapper <?php echo 'wdi_col_' . $feed_row['number_of_columns'] ?>" wdi-res='<?php echo 'wdi_col_' . $feed_row['number_of_columns'] ?>'></div>
|
| 53 |
<div class="wdi_clear"></div>
|
| 54 |
-
|
| 55 |
-
|
| 56 |
-
|
| 57 |
-
|
| 58 |
-
|
| 59 |
-
|
| 60 |
-
|
| 61 |
-
|
| 62 |
-
|
|
|
|
| 63 |
</div>
|
| 64 |
</div>
|
| 65 |
</div>
|
| 66 |
-
|
| 67 |
-
|
| 68 |
-
|
| 69 |
-
|
| 70 |
-
|
| 71 |
</div>
|
| 72 |
</div>
|
| 73 |
-
|
| 74 |
-
<?php
|
| 75 |
|
| 76 |
-
|
| 77 |
-
|
| 78 |
-
|
| 79 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 80 |
?>
|
| 81 |
-
<div id="
|
| 82 |
-
<div class="wdi_pagination_container"><i id="wdi_first_page"
|
| 83 |
-
title="<?php echo __('First Page', "wd-instagram-feed") ?>"
|
| 84 |
-
class="tenweb-i tenweb-i-step-backward wdi_disabled wdi_pagination_ctrl"></i><i
|
| 85 |
-
id="wdi_prev" title="<?php echo __('Previous Page', "wd-instagram-feed") ?>"
|
| 86 |
-
class="tenweb-i tenweb-i-arrow-left wdi_pagination_ctrl"></i><i id="wdi_current_page" class="wdi_pagination_ctrl"
|
| 87 |
-
style="font-style:normal">1</i><i id="wdi_next"
|
| 88 |
-
title="<?php echo __('Next Page', "wd-instagram-feed") ?>"
|
| 89 |
-
class="tenweb-i tenweb-i-arrow-right wdi_pagination_ctrl"></i>
|
| 90 |
-
<i id="wdi_last_page" title="<?php echo __('Last Page', "wd-instagram-feed") ?>"
|
| 91 |
-
class="tenweb-i tenweb-i-step-forward wdi_pagination_ctrl wdi_disabled"></i></div></div> <?php
|
| 92 |
}
|
| 93 |
-
|
| 94 |
-
break;
|
| 95 |
}
|
| 96 |
-
case 'infinite_scroll': {
|
| 97 |
-
?>
|
| 98 |
-
<div id="wdi_infinite_scroll" class="wdi_infinite_scroll"></div> <?php
|
| 99 |
-
}
|
| 100 |
-
}
|
| 101 |
|
| 102 |
-
|
| 103 |
-
|
| 104 |
-
|
| 105 |
-
|
| 106 |
?>
|
| 107 |
-
|
| 108 |
</div>
|
| 109 |
<div class="wdi_front_overlay"></div>
|
| 110 |
</div>
|
| 33 |
} ?>
|
| 34 |
</div>
|
| 35 |
</div>
|
| 36 |
+
<?php if ($feed_row['feed_display_view'] === 'pagination' && $style['pagination_position_vert'] === 'top') { ?>
|
|
|
|
|
|
|
| 37 |
<div id="wdi_pagination" class="wdi_pagination wdi_hidden">
|
| 38 |
+
<div class="wdi_pagination_container">
|
| 39 |
+
<i id="wdi_first_page" title="<?php echo __('First Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-step-backward wdi_pagination_ctrl wdi_disabled"></i>
|
| 40 |
+
<i id="wdi_prev" title="<?php echo __('Previous Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-arrow-left wdi_pagination_ctrl"></i>
|
| 41 |
+
<i id="wdi_current_page" class="wdi_pagination_ctrl" style="font-style:normal">1</i>
|
| 42 |
+
<i id="wdi_next" title="<?php echo __('Next Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-arrow-right wdi_pagination_ctrl"></i>
|
| 43 |
+
<i id="wdi_last_page" title="<?php echo __('Last Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-step-forward wdi_pagination_ctrl wdi_disabled"></i>
|
| 44 |
+
</div>
|
| 45 |
+
</div>
|
| 46 |
+
<?php } ?>
|
|
|
|
|
|
|
|
|
|
| 47 |
<div class="wdi_feed_wrapper <?php echo 'wdi_col_' . $feed_row['number_of_columns'] ?>" wdi-res='<?php echo 'wdi_col_' . $feed_row['number_of_columns'] ?>'></div>
|
| 48 |
<div class="wdi_clear"></div>
|
| 49 |
+
<?php
|
| 50 |
+
switch ($feed_row['feed_display_view']) {
|
| 51 |
+
case 'load_more_btn': {
|
| 52 |
+
?>
|
| 53 |
+
<div class="wdi_load_more wdi_hidden">
|
| 54 |
+
<div class="wdi_load_more_container">
|
| 55 |
+
<div class="wdi_load_more_wrap">
|
| 56 |
+
<div class="wdi_load_more_wrap_inner">
|
| 57 |
+
<div class="wdi_load_more_text"><?php echo __('Load More', "wd-instagram-feed"); ?></div>
|
| 58 |
+
</div>
|
| 59 |
</div>
|
| 60 |
</div>
|
| 61 |
</div>
|
| 62 |
+
<div class="wdi_spinner">
|
| 63 |
+
<div class="wdi_spinner_container">
|
| 64 |
+
<div class="wdi_spinner_wrap">
|
| 65 |
+
<div class="wdi_spinner_wrap_inner"><i class="wdi_load_more_spinner tenweb-i tenweb-i-spinner"></i></div>
|
| 66 |
+
</div>
|
| 67 |
</div>
|
| 68 |
</div>
|
| 69 |
+
<?php
|
|
|
|
| 70 |
|
| 71 |
+
break;
|
| 72 |
+
}
|
| 73 |
+
case 'pagination': {
|
| 74 |
+
if ($style['pagination_position_vert'] === 'bottom') {
|
| 75 |
+
?>
|
| 76 |
+
<div id="wdi_pagination" class="wdi_pagination wdi_hidden">
|
| 77 |
+
<div class="wdi_pagination_container">
|
| 78 |
+
<i id="wdi_first_page" title="<?php echo __('First Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-step-backward wdi_disabled wdi_pagination_ctrl"></i>
|
| 79 |
+
<i id="wdi_prev" title="<?php echo __('Previous Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-arrow-left wdi_pagination_ctrl"></i>
|
| 80 |
+
<i id="wdi_current_page" class="wdi_pagination_ctrl" style="font-style:normal">1</i>
|
| 81 |
+
<i id="wdi_next" title="<?php echo __('Next Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-arrow-right wdi_pagination_ctrl"></i>
|
| 82 |
+
<i id="wdi_last_page" title="<?php echo __('Last Page', "wd-instagram-feed") ?>" class="tenweb-i tenweb-i-step-forward wdi_pagination_ctrl wdi_disabled"></i>
|
| 83 |
+
</div>
|
| 84 |
+
</div>
|
| 85 |
+
<?php
|
| 86 |
+
}
|
| 87 |
+
break;
|
| 88 |
+
}
|
| 89 |
+
case 'infinite_scroll': {
|
| 90 |
?>
|
| 91 |
+
<div id="wdi_infinite_scroll" class="wdi_infinite_scroll"></div> <?php
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 92 |
}
|
|
|
|
|
|
|
| 93 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 94 |
|
| 95 |
+
if ($feed_row['feed_display_view'] === 'pagination') { ?>
|
| 96 |
+
<div class="wdi_page_loading wdi_hidden"><img class="wdi_load_more_spinner" src="<?php echo WDI_URL ?>/images/ajax_loader.png"></div>
|
| 97 |
+
<?php
|
| 98 |
+
}
|
| 99 |
?>
|
|
|
|
| 100 |
</div>
|
| 101 |
<div class="wdi_front_overlay"></div>
|
| 102 |
</div>
|
js/wdi_frontend.js
CHANGED
|
@@ -620,7 +620,6 @@ wdi_front.displayFeed = function (currentFeed, page_number) {
|
|
| 620 |
wdi_front.displayFeedItems(data, currentFeed);
|
| 621 |
}
|
| 622 |
|
| 623 |
-
|
| 624 |
//checking if display_view is pagination and we are not on the last page then enable
|
| 625 |
//last page button
|
| 626 |
if (currentFeed.feed_row.feed_display_view == 'pagination' && currentFeed.currentPage < currentFeed.paginator) {
|
|
@@ -657,7 +656,6 @@ wdi_front.updateUsersImages = function (currentFeed) {
|
|
| 657 |
|
| 658 |
wdi_front.checkLoaded = function (currentFeed) {
|
| 659 |
var wdi_feed_counter = currentFeed.feed_row['wdi_feed_counter'];
|
| 660 |
-
|
| 661 |
var feed_container = jQuery('#wdi_feed_' + wdi_feed_counter);
|
| 662 |
/* if there are images which can be loaded */
|
| 663 |
if( currentFeed['dataStorageList'].length > (currentFeed['already_loaded_count']) ) {
|
|
@@ -669,101 +667,89 @@ wdi_front.checkLoaded = function (currentFeed) {
|
|
| 669 |
}
|
| 670 |
setTimeout(function () {
|
| 671 |
feed_container.find('.wdi_ajax_loading').addClass('wdi_hidden');
|
|
|
|
|
|
|
| 672 |
}, 500);
|
| 673 |
}
|
| 674 |
|
| 675 |
-
|
| 676 |
/**
|
| 677 |
* Displays data in masonry layout
|
| 678 |
* @param {Object} data data to be displayed
|
| 679 |
* @param {Object} currentFeed
|
| 680 |
*/
|
| 681 |
-
wdi_front.masonryDisplayFeedItems = function (data, currentFeed) {
|
| 682 |
var masonryColEnds = [];
|
| 683 |
var masonryColumns = [];
|
| 684 |
-
if (jQuery('#wdi_feed_' + currentFeed.feed_row.wdi_feed_counter + " .wdi_feed_wrapper").length == 0) {
|
| 685 |
//no feed in DOM, ignore
|
| 686 |
return;
|
| 687 |
}
|
| 688 |
-
jQuery('#wdi_feed_' + currentFeed.feed_row['wdi_feed_counter'] + ' .wdi_masonry_column').each(function ()
|
| 689 |
-
{
|
| 690 |
-
|
| 691 |
//if resorte after load more is on then reset columns on every load more
|
| 692 |
-
if (currentFeed.feed_row.resort_after_load_more == 1) {
|
| 693 |
jQuery(this).html('');
|
| 694 |
currentFeed.imageIndex = 0;
|
| 695 |
}
|
| 696 |
-
|
| 697 |
//if custom filter is set or changed then reset masonry columns
|
| 698 |
-
if (currentFeed.customFilterChanged == true) {
|
| 699 |
jQuery(this).html('');
|
| 700 |
currentFeed.imageIndex = 0;
|
| 701 |
}
|
| 702 |
-
|
| 703 |
//check if pagination is enabled then each page should have resetted colEnds
|
| 704 |
//else give previous colEnds
|
| 705 |
-
if (currentFeed.feed_row.feed_display_view == 'pagination') {
|
| 706 |
masonryColEnds.push(0);
|
| 707 |
-
}
|
|
|
|
| 708 |
masonryColEnds.push(jQuery(this).height());
|
| 709 |
}
|
| 710 |
-
|
| 711 |
masonryColumns.push(jQuery(this));
|
| 712 |
});
|
| 713 |
-
|
| 714 |
//if custom filter is set or changed then reset masonry columns
|
| 715 |
-
if (currentFeed.customFilterChanged == true) {
|
| 716 |
currentFeed.customFilterChanged = false;
|
| 717 |
}
|
| 718 |
-
|
| 719 |
//loop for displaying items
|
| 720 |
-
for (var i = 0; i < data.length; i++) {
|
| 721 |
-
|
| 722 |
if ( typeof data[i]['videos'] === 'object' ) {
|
| 723 |
if ( data[i]['videos'].standard_resolution == null ) {
|
| 724 |
continue;
|
| 725 |
}
|
| 726 |
}
|
| 727 |
-
|
| 728 |
currentFeed.displayedData.push(data[i]);
|
| 729 |
/*carousel feature*/
|
| 730 |
var wdi_media_type = "";
|
| 731 |
-
if(typeof data[i]["wdi_hashtag"] != "undefined"){
|
| 732 |
wdi_media_type = data[i]["wdi_hashtag"];
|
| 733 |
}
|
| 734 |
-
if (data[i]['type'] == 'image') {
|
| 735 |
var photoTemplate = wdi_front.getPhotoTemplate(currentFeed, wdi_media_type);
|
| 736 |
-
}
|
|
|
|
| 737 |
var photoTemplate = wdi_front.getVideoTemplate(currentFeed, wdi_media_type);
|
| 738 |
}
|
| 739 |
-
else{
|
| 740 |
var photoTemplate = wdi_front.getSliderTemplate(currentFeed, wdi_media_type);
|
| 741 |
}
|
| 742 |
-
|
| 743 |
var rawItem = data[i];
|
| 744 |
var item = wdi_front.createObject(rawItem, currentFeed);
|
| 745 |
var html = photoTemplate(item);
|
| 746 |
-
|
| 747 |
//find column with minumum height and append to it new object
|
| 748 |
var shortCol = wdi_front.array_min(masonryColEnds);
|
| 749 |
var imageResolution = wdi_front.getImageResolution(data[i]);
|
| 750 |
-
|
| 751 |
masonryColumns[shortCol['index']].html(masonryColumns[shortCol['index']].html() + html);
|
| 752 |
masonryColEnds[shortCol['index']] += masonryColumns[shortCol['index']].width() * imageResolution;
|
| 753 |
currentFeed.imageIndex++;
|
| 754 |
-
|
| 755 |
//changing responsive indexes for pagination
|
| 756 |
-
if (currentFeed.feed_row.feed_display_view == 'pagination') {
|
| 757 |
-
if ((i + 1) % currentFeed.feed_row.pagination_per_page_number === 0) {
|
| 758 |
currentFeed.resIndex += currentFeed.freeSpaces + 1;
|
| 759 |
-
}
|
|
|
|
| 760 |
currentFeed.resIndex++;
|
| 761 |
}
|
| 762 |
}
|
| 763 |
}
|
| 764 |
-
|
| 765 |
-
|
| 766 |
-
|
| 767 |
//binding onload event for ajax loader
|
| 768 |
currentFeed.wdi_loadedImages = 0;
|
| 769 |
var columnFlag = false;
|
|
@@ -771,24 +757,18 @@ wdi_front.masonryDisplayFeedItems = function (data, currentFeed) {
|
|
| 771 |
var wdi_feed_counter = currentFeed.feed_row['wdi_feed_counter'];
|
| 772 |
var feed_wrapper = jQuery('#wdi_feed_' + wdi_feed_counter + ' .wdi_img').on('load', function () {
|
| 773 |
currentFeed.wdi_loadedImages++;
|
| 774 |
-
|
| 775 |
-
|
| 776 |
//calls wdi_responsive.columnControl() which calculates column number on page
|
| 777 |
//and gives feed_wrapper proper column class
|
| 778 |
-
if (columnFlag === false) {
|
| 779 |
wdi_responsive.columnControl(currentFeed, 1);
|
| 780 |
columnFlag = true;
|
| 781 |
}
|
| 782 |
});
|
| 783 |
-
|
| 784 |
wdi_front.checkLoaded(currentFeed);
|
| 785 |
-
|
| 786 |
-
|
| 787 |
//checking if pagination next button was clicked then change page
|
| 788 |
-
if (currentFeed.paginatorNextFlag == true) {
|
| 789 |
wdi_front.updatePagination(currentFeed, 'next');
|
| 790 |
}
|
| 791 |
-
|
| 792 |
//check if load more done successfully then set infinite scroll flag to false
|
| 793 |
currentFeed.infiniteScrollFlag = false;
|
| 794 |
}
|
|
@@ -850,8 +830,8 @@ wdi_front.getArrayContentLength = function (array, data) {
|
|
| 850 |
* @param {Object} data data to be displayed
|
| 851 |
* @param {Object} currentFeed
|
| 852 |
*/
|
| 853 |
-
wdi_front.displayFeedItems = function (data, currentFeed) {
|
| 854 |
-
if (jQuery('#wdi_feed_' + currentFeed.feed_row.wdi_feed_counter + " .wdi_feed_wrapper").length == 0) {
|
| 855 |
//no feed in DOM, ignore
|
| 856 |
return;
|
| 857 |
}
|
|
@@ -859,11 +839,9 @@ wdi_front.displayFeedItems = function (data, currentFeed) {
|
|
| 859 |
var wdi_feed_counter = currentFeed.feed_row['wdi_feed_counter'];
|
| 860 |
var feed_wrapper = jQuery('#wdi_feed_' + wdi_feed_counter + ' .wdi_feed_wrapper');
|
| 861 |
/*
|
| 862 |
-
|
| 863 |
-
|
| 864 |
-
|
| 865 |
-
* also do the same thing when recievied data has lenght equal to zero
|
| 866 |
-
*!/
|
| 867 |
if (currentFeed.feed_row.feed_display_view == 'pagination') {
|
| 868 |
var local_load_more_number = currentFeed.feed_row.load_more_number;
|
| 869 |
if(currentFeed.feed_row.feed_type == 'image_browser') {
|
|
@@ -871,23 +849,23 @@ wdi_front.displayFeedItems = function (data, currentFeed) {
|
|
| 871 |
}
|
| 872 |
}
|
| 873 |
*/
|
| 874 |
-
for (var i = 0; i < data.length; i++) {
|
| 875 |
-
if (typeof data[i] == 'undefined') {
|
| 876 |
return;
|
| 877 |
}
|
| 878 |
-
if (typeof data[i]['videos'] === 'object') {
|
| 879 |
-
if (data[i]['videos'].standard_resolution == null) {
|
| 880 |
continue;
|
| 881 |
}
|
| 882 |
}
|
| 883 |
var wdi_media_type = "";
|
| 884 |
-
if (typeof data[i]["wdi_hashtag"] != "undefined") {
|
| 885 |
wdi_media_type = data[i]["wdi_hashtag"];
|
| 886 |
}
|
| 887 |
-
if (data[i]['type'] == 'image') {
|
| 888 |
var photoTemplate = wdi_front.getPhotoTemplate(currentFeed, wdi_media_type);
|
| 889 |
}
|
| 890 |
-
else if (data[i].hasOwnProperty('videos')) {
|
| 891 |
var photoTemplate = wdi_front.getVideoTemplate(currentFeed, wdi_media_type);
|
| 892 |
}
|
| 893 |
else {
|
|
@@ -897,14 +875,14 @@ wdi_front.displayFeedItems = function (data, currentFeed) {
|
|
| 897 |
var item = wdi_front.createObject(rawItem, currentFeed);
|
| 898 |
var html = '';
|
| 899 |
/* undefined when carousel media not defined */
|
| 900 |
-
if (typeof item !== 'undefined') {
|
| 901 |
html = photoTemplate(item);
|
| 902 |
}
|
| 903 |
feed_wrapper.html(feed_wrapper.html() + html);
|
| 904 |
currentFeed.imageIndex++;
|
| 905 |
//changing responsive indexes for pagination
|
| 906 |
-
if (currentFeed.feed_row.feed_display_view == 'pagination') {
|
| 907 |
-
if ((i + 1) % currentFeed.feed_row.pagination_per_page_number === 0) {
|
| 908 |
currentFeed.resIndex += currentFeed.freeSpaces + 1;
|
| 909 |
}
|
| 910 |
else {
|
|
@@ -912,26 +890,7 @@ wdi_front.displayFeedItems = function (data, currentFeed) {
|
|
| 912 |
}
|
| 913 |
}
|
| 914 |
}
|
| 915 |
-
checkLoaded();
|
| 916 |
-
|
| 917 |
-
//checks if all iamges have been succesfully loaded then it updates variables for next time use
|
| 918 |
-
function checkLoaded()
|
| 919 |
-
{
|
| 920 |
-
var wdi_feed_counter = currentFeed.feed_row['wdi_feed_counter'];
|
| 921 |
-
|
| 922 |
-
var feed_container = jQuery('#wdi_feed_' + wdi_feed_counter);
|
| 923 |
-
/* if there are images which can be loaded */
|
| 924 |
-
if( currentFeed['dataStorageList'].length > (currentFeed['already_loaded_count']) ) {
|
| 925 |
-
feed_container.find('.wdi_load_more').removeClass('wdi_hidden');
|
| 926 |
-
feed_container.find('.wdi_spinner').addClass('wdi_hidden');
|
| 927 |
-
} else {
|
| 928 |
-
feed_container.find('.wdi_load_more').addClass('wdi_hidden');
|
| 929 |
-
feed_container.find('.wdi_spinner').addClass('wdi_hidden');
|
| 930 |
-
}
|
| 931 |
-
setTimeout(function () {
|
| 932 |
-
feed_container.find('.wdi_ajax_loading').addClass('wdi_hidden');
|
| 933 |
-
}, 500);
|
| 934 |
-
}
|
| 935 |
}
|
| 936 |
|
| 937 |
wdi_front.checkFeedFinished = function (currentFeed) {
|
|
@@ -1067,7 +1026,6 @@ wdi_front.getPhotoTemplate = function (currentFeed , type) {
|
|
| 1067 |
}
|
| 1068 |
}
|
| 1069 |
|
| 1070 |
-
|
| 1071 |
//creating onclick string for different options
|
| 1072 |
switch (currentFeed.feed_row.feed_item_onclick) {
|
| 1073 |
case 'lightbox':
|
|
@@ -1116,11 +1074,11 @@ wdi_front.getPhotoTemplate = function (currentFeed , type) {
|
|
| 1116 |
var imageIndex = currentFeed['imageIndex'];
|
| 1117 |
if (currentFeed['feed_row']['show_likes'] === '1' || currentFeed['feed_row']['show_comments'] === '1' || currentFeed['feed_row']['show_description'] === '1') {
|
| 1118 |
source += '<div class="wdi_photo_meta">';
|
| 1119 |
-
var likes_count = ( typeof currentFeed['dataStorageList'][imageIndex]['
|
| 1120 |
if (currentFeed['feed_row']['show_likes'] === '1' && likes_count !== 0) {
|
| 1121 |
source += '<div class="wdi_thumb_likes"><i class="tenweb-i tenweb-i-heart-o"> <%= likes%></i></div>';
|
| 1122 |
}
|
| 1123 |
-
var comments_count = ( typeof currentFeed['dataStorageList'][imageIndex]['
|
| 1124 |
if (currentFeed['feed_row']['show_comments'] === '1' && comments_count !== 0) {
|
| 1125 |
source += '<div class="wdi_thumb_comments"><i class="tenweb-i tenweb-i-comment-square"> <%= comments%></i></div>';
|
| 1126 |
}
|
|
@@ -1223,7 +1181,7 @@ wdi_front.getSliderTemplate = function (currentFeed, type) {
|
|
| 1223 |
var imageIndex = currentFeed['imageIndex'];
|
| 1224 |
if (currentFeed['feed_row']['show_likes'] === '1' || currentFeed['feed_row']['show_comments'] === '1' || currentFeed['feed_row']['show_description'] === '1') {
|
| 1225 |
source += '<div class="wdi_photo_meta">';
|
| 1226 |
-
var likes_count = ( typeof currentFeed['dataStorageList'][imageIndex]['likes']['count'] !== 'undefined' ) ? currentFeed['dataStorageList'][imageIndex]['likes']['count'] : currentFeed['dataStorageList'][imageIndex]['likes'];
|
| 1227 |
if (currentFeed['feed_row']['show_likes'] === '1' && likes_count !== 0) {
|
| 1228 |
source += '<div class="wdi_thumb_likes"><i class="tenweb-i tenweb-i-heart-o"> <%= likes%></i></div>';
|
| 1229 |
}
|
|
@@ -1339,7 +1297,7 @@ wdi_front.getVideoTemplate = function (currentFeed, type) {
|
|
| 1339 |
var imageIndex = currentFeed['imageIndex'];
|
| 1340 |
if (currentFeed['feed_row']['show_likes'] === '1' || currentFeed['feed_row']['show_comments'] === '1' || currentFeed['feed_row']['show_description'] === '1') {
|
| 1341 |
source += '<div class="wdi_photo_meta">';
|
| 1342 |
-
var likes_count = ( typeof currentFeed['dataStorageList'][imageIndex]['likes']['count'] !== 'undefined' ) ? currentFeed['dataStorageList'][imageIndex]['likes']['count'] : currentFeed['dataStorageList'][imageIndex]['likes'];
|
| 1343 |
if (currentFeed['feed_row']['show_likes'] === '1' && likes_count !== 0) {
|
| 1344 |
source += '<div class="wdi_thumb_likes"><i class="tenweb-i tenweb-i-heart-o"> <%= likes%></i></div>';
|
| 1345 |
}
|
|
@@ -1435,37 +1393,36 @@ wdi_front.infiniteScroll = function (currentFeed) {
|
|
| 1435 |
}
|
| 1436 |
}
|
| 1437 |
|
| 1438 |
-
|
| 1439 |
-
wdi_front.changePage = function (btn, currentFeed) {
|
| 1440 |
-
var feed_container = btn.closest(".wdi_feed_container");
|
| 1441 |
-
feed_container.find(".wdi_page_loading").removeClass("wdi_hidden");
|
| 1442 |
-
|
| 1443 |
new_page_number = currentFeed.currentPage;
|
| 1444 |
-
if( new_page_number > 1 ) {
|
| 1445 |
-
|
| 1446 |
-
} else if( new_page_number === 1 ) {
|
| 1447 |
-
jQuery("#wdi_first_page").addClass("wdi_disabled");
|
| 1448 |
}
|
| 1449 |
-
if( new_page_number
|
| 1450 |
-
|
| 1451 |
-
} else if( new_page_number < parseInt(currentFeed.paginator) ) {
|
| 1452 |
-
jQuery("#wdi_last_page").removeClass("wdi_disabled");
|
| 1453 |
}
|
| 1454 |
-
if (
|
| 1455 |
-
|
| 1456 |
-
}
|
| 1457 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1458 |
}
|
| 1459 |
btn.parent().find("#wdi_current_page").empty().text(new_page_number);
|
| 1460 |
-
wdi_front.displayFeed(currentFeed, new_page_number);
|
| 1461 |
-
feed_container.find(".wdi_page_loading").addClass("wdi_hidden")
|
| 1462 |
-
}
|
| 1463 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1464 |
|
| 1465 |
//displays proper images for specific page after pagination buttons click event
|
| 1466 |
-
wdi_front.updatePagination = function (currentFeed, dir, oldPage)
|
| 1467 |
-
{
|
| 1468 |
-
|
| 1469 |
var currentFeedString = '#wdi_feed_' + currentFeed.feed_row['wdi_feed_counter'];
|
| 1470 |
jQuery(currentFeedString + ' [wdi_page="' + currentFeed.currentPage + '"]').each(function ()
|
| 1471 |
{
|
| 620 |
wdi_front.displayFeedItems(data, currentFeed);
|
| 621 |
}
|
| 622 |
|
|
|
|
| 623 |
//checking if display_view is pagination and we are not on the last page then enable
|
| 624 |
//last page button
|
| 625 |
if (currentFeed.feed_row.feed_display_view == 'pagination' && currentFeed.currentPage < currentFeed.paginator) {
|
| 656 |
|
| 657 |
wdi_front.checkLoaded = function (currentFeed) {
|
| 658 |
var wdi_feed_counter = currentFeed.feed_row['wdi_feed_counter'];
|
|
|
|
| 659 |
var feed_container = jQuery('#wdi_feed_' + wdi_feed_counter);
|
| 660 |
/* if there are images which can be loaded */
|
| 661 |
if( currentFeed['dataStorageList'].length > (currentFeed['already_loaded_count']) ) {
|
| 667 |
}
|
| 668 |
setTimeout(function () {
|
| 669 |
feed_container.find('.wdi_ajax_loading').addClass('wdi_hidden');
|
| 670 |
+
feed_container.find(".wdi_page_loading").addClass("wdi_hidden");
|
| 671 |
+
feed_container.find('.wdi_front_overlay').addClass('wdi_hidden');
|
| 672 |
}, 500);
|
| 673 |
}
|
| 674 |
|
|
|
|
| 675 |
/**
|
| 676 |
* Displays data in masonry layout
|
| 677 |
* @param {Object} data data to be displayed
|
| 678 |
* @param {Object} currentFeed
|
| 679 |
*/
|
| 680 |
+
wdi_front.masonryDisplayFeedItems = function ( data, currentFeed ) {
|
| 681 |
var masonryColEnds = [];
|
| 682 |
var masonryColumns = [];
|
| 683 |
+
if ( jQuery('#wdi_feed_' + currentFeed.feed_row.wdi_feed_counter + " .wdi_feed_wrapper").length == 0 ) {
|
| 684 |
//no feed in DOM, ignore
|
| 685 |
return;
|
| 686 |
}
|
| 687 |
+
jQuery('#wdi_feed_' + currentFeed.feed_row['wdi_feed_counter'] + ' .wdi_masonry_column').each(function () {
|
|
|
|
|
|
|
| 688 |
//if resorte after load more is on then reset columns on every load more
|
| 689 |
+
if ( currentFeed.feed_row.resort_after_load_more == 1 ) {
|
| 690 |
jQuery(this).html('');
|
| 691 |
currentFeed.imageIndex = 0;
|
| 692 |
}
|
|
|
|
| 693 |
//if custom filter is set or changed then reset masonry columns
|
| 694 |
+
if ( currentFeed.customFilterChanged == true ) {
|
| 695 |
jQuery(this).html('');
|
| 696 |
currentFeed.imageIndex = 0;
|
| 697 |
}
|
|
|
|
| 698 |
//check if pagination is enabled then each page should have resetted colEnds
|
| 699 |
//else give previous colEnds
|
| 700 |
+
if ( currentFeed.feed_row.feed_display_view == 'pagination' ) {
|
| 701 |
masonryColEnds.push(0);
|
| 702 |
+
}
|
| 703 |
+
else {
|
| 704 |
masonryColEnds.push(jQuery(this).height());
|
| 705 |
}
|
|
|
|
| 706 |
masonryColumns.push(jQuery(this));
|
| 707 |
});
|
|
|
|
| 708 |
//if custom filter is set or changed then reset masonry columns
|
| 709 |
+
if ( currentFeed.customFilterChanged == true ) {
|
| 710 |
currentFeed.customFilterChanged = false;
|
| 711 |
}
|
|
|
|
| 712 |
//loop for displaying items
|
| 713 |
+
for ( var i = 0; i < data.length; i++ ) {
|
|
|
|
| 714 |
if ( typeof data[i]['videos'] === 'object' ) {
|
| 715 |
if ( data[i]['videos'].standard_resolution == null ) {
|
| 716 |
continue;
|
| 717 |
}
|
| 718 |
}
|
|
|
|
| 719 |
currentFeed.displayedData.push(data[i]);
|
| 720 |
/*carousel feature*/
|
| 721 |
var wdi_media_type = "";
|
| 722 |
+
if ( typeof data[i]["wdi_hashtag"] != "undefined" ) {
|
| 723 |
wdi_media_type = data[i]["wdi_hashtag"];
|
| 724 |
}
|
| 725 |
+
if ( data[i]['type'] == 'image' ) {
|
| 726 |
var photoTemplate = wdi_front.getPhotoTemplate(currentFeed, wdi_media_type);
|
| 727 |
+
}
|
| 728 |
+
else if ( data[i].hasOwnProperty('videos') || data[i]['type'] == 'video' ) {
|
| 729 |
var photoTemplate = wdi_front.getVideoTemplate(currentFeed, wdi_media_type);
|
| 730 |
}
|
| 731 |
+
else {
|
| 732 |
var photoTemplate = wdi_front.getSliderTemplate(currentFeed, wdi_media_type);
|
| 733 |
}
|
|
|
|
| 734 |
var rawItem = data[i];
|
| 735 |
var item = wdi_front.createObject(rawItem, currentFeed);
|
| 736 |
var html = photoTemplate(item);
|
|
|
|
| 737 |
//find column with minumum height and append to it new object
|
| 738 |
var shortCol = wdi_front.array_min(masonryColEnds);
|
| 739 |
var imageResolution = wdi_front.getImageResolution(data[i]);
|
|
|
|
| 740 |
masonryColumns[shortCol['index']].html(masonryColumns[shortCol['index']].html() + html);
|
| 741 |
masonryColEnds[shortCol['index']] += masonryColumns[shortCol['index']].width() * imageResolution;
|
| 742 |
currentFeed.imageIndex++;
|
|
|
|
| 743 |
//changing responsive indexes for pagination
|
| 744 |
+
if ( currentFeed.feed_row.feed_display_view == 'pagination' ) {
|
| 745 |
+
if ( (i + 1) % currentFeed.feed_row.pagination_per_page_number === 0 ) {
|
| 746 |
currentFeed.resIndex += currentFeed.freeSpaces + 1;
|
| 747 |
+
}
|
| 748 |
+
else {
|
| 749 |
currentFeed.resIndex++;
|
| 750 |
}
|
| 751 |
}
|
| 752 |
}
|
|
|
|
|
|
|
|
|
|
| 753 |
//binding onload event for ajax loader
|
| 754 |
currentFeed.wdi_loadedImages = 0;
|
| 755 |
var columnFlag = false;
|
| 757 |
var wdi_feed_counter = currentFeed.feed_row['wdi_feed_counter'];
|
| 758 |
var feed_wrapper = jQuery('#wdi_feed_' + wdi_feed_counter + ' .wdi_img').on('load', function () {
|
| 759 |
currentFeed.wdi_loadedImages++;
|
|
|
|
|
|
|
| 760 |
//calls wdi_responsive.columnControl() which calculates column number on page
|
| 761 |
//and gives feed_wrapper proper column class
|
| 762 |
+
if ( columnFlag === false ) {
|
| 763 |
wdi_responsive.columnControl(currentFeed, 1);
|
| 764 |
columnFlag = true;
|
| 765 |
}
|
| 766 |
});
|
|
|
|
| 767 |
wdi_front.checkLoaded(currentFeed);
|
|
|
|
|
|
|
| 768 |
//checking if pagination next button was clicked then change page
|
| 769 |
+
if ( currentFeed.paginatorNextFlag == true ) {
|
| 770 |
wdi_front.updatePagination(currentFeed, 'next');
|
| 771 |
}
|
|
|
|
| 772 |
//check if load more done successfully then set infinite scroll flag to false
|
| 773 |
currentFeed.infiniteScrollFlag = false;
|
| 774 |
}
|
| 830 |
* @param {Object} data data to be displayed
|
| 831 |
* @param {Object} currentFeed
|
| 832 |
*/
|
| 833 |
+
wdi_front.displayFeedItems = function ( data, currentFeed ) {
|
| 834 |
+
if ( jQuery('#wdi_feed_' + currentFeed.feed_row.wdi_feed_counter + " .wdi_feed_wrapper").length == 0 ) {
|
| 835 |
//no feed in DOM, ignore
|
| 836 |
return;
|
| 837 |
}
|
| 839 |
var wdi_feed_counter = currentFeed.feed_row['wdi_feed_counter'];
|
| 840 |
var feed_wrapper = jQuery('#wdi_feed_' + wdi_feed_counter + ' .wdi_feed_wrapper');
|
| 841 |
/*
|
| 842 |
+
// if feed display view is set to pagination then check if the current page has not enough photos to be a complete page then
|
| 843 |
+
// --currentPage so that after loading new images we stay on the same page and see new images which will be located in that page
|
| 844 |
+
// also do the same thing when recievied data has lenght equal to zero
|
|
|
|
|
|
|
| 845 |
if (currentFeed.feed_row.feed_display_view == 'pagination') {
|
| 846 |
var local_load_more_number = currentFeed.feed_row.load_more_number;
|
| 847 |
if(currentFeed.feed_row.feed_type == 'image_browser') {
|
| 849 |
}
|
| 850 |
}
|
| 851 |
*/
|
| 852 |
+
for ( var i = 0; i < data.length; i++ ) {
|
| 853 |
+
if ( typeof data[i] == 'undefined' ) {
|
| 854 |
return;
|
| 855 |
}
|
| 856 |
+
if ( typeof data[i]['videos'] === 'object' ) {
|
| 857 |
+
if ( data[i]['videos'].standard_resolution == null ) {
|
| 858 |
continue;
|
| 859 |
}
|
| 860 |
}
|
| 861 |
var wdi_media_type = "";
|
| 862 |
+
if ( typeof data[i]["wdi_hashtag"] != "undefined" ) {
|
| 863 |
wdi_media_type = data[i]["wdi_hashtag"];
|
| 864 |
}
|
| 865 |
+
if ( data[i]['type'] == 'image' ) {
|
| 866 |
var photoTemplate = wdi_front.getPhotoTemplate(currentFeed, wdi_media_type);
|
| 867 |
}
|
| 868 |
+
else if ( data[i].hasOwnProperty('videos') ) {
|
| 869 |
var photoTemplate = wdi_front.getVideoTemplate(currentFeed, wdi_media_type);
|
| 870 |
}
|
| 871 |
else {
|
| 875 |
var item = wdi_front.createObject(rawItem, currentFeed);
|
| 876 |
var html = '';
|
| 877 |
/* undefined when carousel media not defined */
|
| 878 |
+
if ( typeof item !== 'undefined' ) {
|
| 879 |
html = photoTemplate(item);
|
| 880 |
}
|
| 881 |
feed_wrapper.html(feed_wrapper.html() + html);
|
| 882 |
currentFeed.imageIndex++;
|
| 883 |
//changing responsive indexes for pagination
|
| 884 |
+
if ( currentFeed.feed_row.feed_display_view == 'pagination' ) {
|
| 885 |
+
if ( (i + 1) % currentFeed.feed_row.pagination_per_page_number === 0 ) {
|
| 886 |
currentFeed.resIndex += currentFeed.freeSpaces + 1;
|
| 887 |
}
|
| 888 |
else {
|
| 890 |
}
|
| 891 |
}
|
| 892 |
}
|
| 893 |
+
wdi_front.checkLoaded(currentFeed);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 894 |
}
|
| 895 |
|
| 896 |
wdi_front.checkFeedFinished = function (currentFeed) {
|
| 1026 |
}
|
| 1027 |
}
|
| 1028 |
|
|
|
|
| 1029 |
//creating onclick string for different options
|
| 1030 |
switch (currentFeed.feed_row.feed_item_onclick) {
|
| 1031 |
case 'lightbox':
|
| 1074 |
var imageIndex = currentFeed['imageIndex'];
|
| 1075 |
if (currentFeed['feed_row']['show_likes'] === '1' || currentFeed['feed_row']['show_comments'] === '1' || currentFeed['feed_row']['show_description'] === '1') {
|
| 1076 |
source += '<div class="wdi_photo_meta">';
|
| 1077 |
+
var likes_count = ( typeof currentFeed['dataStorageList'][imageIndex] !== 'undefined' && typeof currentFeed['dataStorageList'][imageIndex]['likes'] !== 'undefined' && typeof currentFeed['dataStorageList'][imageIndex]['likes']['count'] !== 'undefined' ) ? currentFeed['dataStorageList'][imageIndex]['likes']['count'] : 0;
|
| 1078 |
if (currentFeed['feed_row']['show_likes'] === '1' && likes_count !== 0) {
|
| 1079 |
source += '<div class="wdi_thumb_likes"><i class="tenweb-i tenweb-i-heart-o"> <%= likes%></i></div>';
|
| 1080 |
}
|
| 1081 |
+
var comments_count = ( typeof currentFeed['dataStorageList'][imageIndex] !== 'undefined' && typeof currentFeed['dataStorageList'][imageIndex]['comments'] !== 'undefined' && typeof currentFeed['dataStorageList'][imageIndex]['comments']['count'] !== 'undefined' ) ? currentFeed['dataStorageList'][imageIndex]['comments']['count'] : 0;
|
| 1082 |
if (currentFeed['feed_row']['show_comments'] === '1' && comments_count !== 0) {
|
| 1083 |
source += '<div class="wdi_thumb_comments"><i class="tenweb-i tenweb-i-comment-square"> <%= comments%></i></div>';
|
| 1084 |
}
|
| 1181 |
var imageIndex = currentFeed['imageIndex'];
|
| 1182 |
if (currentFeed['feed_row']['show_likes'] === '1' || currentFeed['feed_row']['show_comments'] === '1' || currentFeed['feed_row']['show_description'] === '1') {
|
| 1183 |
source += '<div class="wdi_photo_meta">';
|
| 1184 |
+
var likes_count = ( typeof currentFeed['dataStorageList'][imageIndex] !== 'undefined' && typeof currentFeed['dataStorageList'][imageIndex]['likes'] !== 'undefined' && typeof currentFeed['dataStorageList'][imageIndex]['likes']['count'] !== 'undefined' ) ? currentFeed['dataStorageList'][imageIndex]['likes']['count'] : currentFeed['dataStorageList'][imageIndex]['likes'];
|
| 1185 |
if (currentFeed['feed_row']['show_likes'] === '1' && likes_count !== 0) {
|
| 1186 |
source += '<div class="wdi_thumb_likes"><i class="tenweb-i tenweb-i-heart-o"> <%= likes%></i></div>';
|
| 1187 |
}
|
| 1297 |
var imageIndex = currentFeed['imageIndex'];
|
| 1298 |
if (currentFeed['feed_row']['show_likes'] === '1' || currentFeed['feed_row']['show_comments'] === '1' || currentFeed['feed_row']['show_description'] === '1') {
|
| 1299 |
source += '<div class="wdi_photo_meta">';
|
| 1300 |
+
var likes_count = ( typeof currentFeed['dataStorageList'][imageIndex] !== 'undefined' && typeof currentFeed['dataStorageList'][imageIndex]['likes'] !== 'undefined' && typeof currentFeed['dataStorageList'][imageIndex]['likes']['count'] !== 'undefined' ) ? currentFeed['dataStorageList'][imageIndex]['likes']['count'] : currentFeed['dataStorageList'][imageIndex]['likes'];
|
| 1301 |
if (currentFeed['feed_row']['show_likes'] === '1' && likes_count !== 0) {
|
| 1302 |
source += '<div class="wdi_thumb_likes"><i class="tenweb-i tenweb-i-heart-o"> <%= likes%></i></div>';
|
| 1303 |
}
|
| 1393 |
}
|
| 1394 |
}
|
| 1395 |
|
| 1396 |
+
wdi_front.changePage = function ( btn, currentFeed ) {
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1397 |
new_page_number = currentFeed.currentPage;
|
| 1398 |
+
if ( new_page_number > 1 ) {
|
| 1399 |
+
jQuery("#wdi_first_page").removeClass("wdi_disabled");
|
|
|
|
|
|
|
| 1400 |
}
|
| 1401 |
+
else if ( new_page_number === 1 ) {
|
| 1402 |
+
jQuery("#wdi_first_page").addClass("wdi_disabled");
|
|
|
|
|
|
|
| 1403 |
}
|
| 1404 |
+
if ( new_page_number == parseInt(currentFeed.paginator) ) {
|
| 1405 |
+
jQuery("#wdi_last_page").addClass("wdi_disabled");
|
| 1406 |
+
}
|
| 1407 |
+
else if ( new_page_number < parseInt(currentFeed.paginator) ) {
|
| 1408 |
+
jQuery("#wdi_last_page").removeClass("wdi_disabled");
|
| 1409 |
+
}
|
| 1410 |
+
if ( currentFeed.feed_row.feed_type == 'masonry' ) {
|
| 1411 |
+
btn.parent().parent().parent().find(".wdi_feed_wrapper .wdi_masonry_column").empty();
|
| 1412 |
+
}
|
| 1413 |
+
else {
|
| 1414 |
+
btn.parent().parent().parent().find(".wdi_feed_wrapper").empty();
|
| 1415 |
}
|
| 1416 |
btn.parent().find("#wdi_current_page").empty().text(new_page_number);
|
|
|
|
|
|
|
|
|
|
| 1417 |
|
| 1418 |
+
var feed_container = btn.closest(".wdi_feed_container");
|
| 1419 |
+
feed_container.parents('.wdi_feed_main_container').find(".wdi_front_overlay").removeClass("wdi_hidden");
|
| 1420 |
+
feed_container.parents('.wdi_feed_main_container').find(".wdi_page_loading").removeClass("wdi_hidden");
|
| 1421 |
+
wdi_front.displayFeed(currentFeed, new_page_number);
|
| 1422 |
+
}
|
| 1423 |
|
| 1424 |
//displays proper images for specific page after pagination buttons click event
|
| 1425 |
+
wdi_front.updatePagination = function (currentFeed, dir, oldPage) {
|
|
|
|
|
|
|
| 1426 |
var currentFeedString = '#wdi_feed_' + currentFeed.feed_row['wdi_feed_counter'];
|
| 1427 |
jQuery(currentFeedString + ' [wdi_page="' + currentFeed.currentPage + '"]').each(function ()
|
| 1428 |
{
|
js/wdi_frontend.min.js
CHANGED
|
@@ -1 +1 @@
|
|
| 1 |
-
"undefined"==typeof wdi_front&&(wdi_front={type:"not_declared"});var wdi_error_show=!(wdi_front.detectEvent=function(){var e="click";return/android|webos|iphone|ipad|ipod|blackberry|iemobile|opera mini/i.test(navigator.userAgent.toLowerCase())&&(e="touchend"),e}),wdi_error_init=!1;function wdi_baseName(e){var i=e.substr(e.lastIndexOf("/"));return e.replace(i,"")}wdi_front.escape_tags=function(e){return void 0===e&&(e=""),e=e.toString().replace(/</g,"<").replace(/>/g,">").replace(/'/g,"'").replace(/"/g,""")},wdi_front.show_alert=function(e,i,d){var r,t;void 0!==(d=jQuery("#wdi_feed_"+d.feed_row.wdi_feed_counter))&&(wdi_error_show=!0,d.find(".wdi_spinner").remove(),r=d.find(".wdi_js_error"),t=d.find(".wdi_token_error"),0!=i&&(void 0!==i.meta&&1==i.meta.error&&"OAuthException"===i.meta.error_type||void 0!==i.error&&"OAuthException"===i.error.type)?(d.find(".wdi_single_user").remove(),t.removeClass("wdi_hidden"),"1"!=wdi_front_messages.wdi_token_error_flag&&jQuery.ajax({type:"POST",url:wdi_url.ajax_url,dataType:"json",data:{action:"wdi_token_flag",wdi_token_flag_nonce:wdi_front_messages.wdi_token_flag_nonce},success:function(e){}})):void 0!==i.error&&void 0!==i.error.message&&(r.html(i.error.message),d.find(".wdi_single_user").remove(),r.removeClass("wdi_js_error"),r.addClass("wdi_js_error_no_animate"),jQuery(".wdi_js_error_no_animate").show()),wdi_front_messages.show_alerts||console.log("%c"+e,"color:#cc0000;")),wdi_error_show=!0},wdi_front.globalInit=function(){var e=wdi_front.feed_counter,i=0;void 0!==wdi_ajax.ajax_response&&(i=wdi_feed_counter_init.wdi_feed_counter_init);for(var d,r=i;r<=e;r++)0!==jQuery("#wdi_feed_"+r).length&&((d=new WDIFeed(window["wdi_feed_"+r])).instagram=new WDIInstagram,d.instagram.filterArguments={feed:d},d.instagram.addToken(d.feed_row.access_token),wdi_front.access_token=d.feed_row.access_token,d.dataLoaded=0,d.dataStorageRaw=[],d.dataStorage=[],d.dataStorageList=[],d.allResponseLength=0,d.currentResponseLength=0,d.temproraryUsersData=[],d.removedUsers=0,d.nowLoadingImages=!0,d.imageIndex=0,d.resIndex=0,d.currentPage=1,d.currentPageLoadMore=0,d.userSortFlags=[],d.customFilterChanged=!1,d.maxConditionalFiltersRequestCount=10,d.instagramRequestCounter=0,d.mediaRequestsDone=!1,d.conditionalFilterBuffer=[],d.stopInfiniteScrollFlag=!1,"masonry"==d.feed_row.feed_type&&(d.displayedData=[]),"pagination"==d.feed_row.feed_display_view?(d.feed_row.resort_after_load_more=0,"image_browser"!=d.feed_row.feed_type?(d.feed_row.load_more_number=parseInt(d.feed_row.pagination_per_page_number),d.feed_row.number_of_photos=d.allResponseLength):(d.feed_row.number_of_photos=1+parseInt(d.feed_row.image_browser_preload_number),d.feed_row.load_more_number=parseInt(d.feed_row.image_browser_load_number)),d.freeSpaces=(Math.floor(d.feed_row.pagination_per_page_number/d.feed_row.number_of_columns)+1)*d.feed_row.number_of_columns-d.feed_row.pagination_per_page_number):d.freeSpaces=0,d.galleryBox=function(e){wdi_spider_createpopup(wdi_url.ajax_url+"?gallery_id="+this.feed_row.id+"&image_id="+e,this.feed_row.wdi_feed_counter,this.feed_row.lightbox_width,this.feed_row.lightbox_height,1,"testpopup",5,this,e)},wdi_responsive.columnControl(d),"masonry"==d.feed_row.feed_type&&jQuery(window).trigger("resize"),wdi_front.bindEvents(d),window["wdi_feed_"+r]=d,wdi_front.init(d))},wdi_front.init=function(e){if(jQuery(".wdi_js_error").hide(),e.photoCounter=e.feed_row.number_of_photos,"liked"==e.feed_row.liked_feed)e.feed_users=["self"];else{if(!wdi_front.isJsonString(e.feed_row.feed_users))return void wdi_front.show_alert(wdi_front_messages.invalid_users_format,!1,e);e.feed_users=JSON.parse(e.feed_row.feed_users)}var i=[],d=[],r=[];void 0!==window.wdi_all_tags&&(i=window.wdi_all_tags);for(var t=0;t<e.feed_users.length;t++)"#"===e.feed_users[t].username[0]&&void 0!==e.feed_users[t].tag_id?(i[e.feed_users[t].tag_id]=e.feed_users[t],r[t]=e.feed_users[t]):d[0]=e.feed_users[t];window.wdi_all_tags=i,e.feed_users=void 0===r||wdi_front.isEmpty(r)?d:r;var a=wdi_front.getFeedItemResolution(e);e.feedImageResolution=a.image,e.feedVideoResolution=a.video,e.dataCount=e.feed_users.length;for(var o=0;o<e.dataCount;o++)wdi_front.instagramRequest(o,e);0<e.feed_row.number_of_photos&&wdi_front.ajaxLoader(e),"1"===e.feed_row.display_header&&wdi_front.show("header",e),"1"===e.feed_row.show_usernames&&wdi_front.show("users",e)},wdi_front.getFeedItemResolution=function(e){var i={image:"standard_resolution",video:"standard_resolution"};if("thumbnail"===e.feed_row.feed_resolution)return{image:"thumbnail",video:"low_bandwidth"};if("low"===e.feed_row.feed_resolution)return{image:"low_resolution",video:"low_resolution"};if("standard"===e.feed_row.feed_resolution)return{image:"standard_resolution",video:"standard_resolution"};var d=jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter).find(".wdi_feed_wrapper");d.append('<div class="wdi_feed_item" id="wdi_feed_item_example"></div>'),wdi_responsive.columnControl(e,1);e=d.attr("wdi-res").split("wdi_col_");if(d.find("#wdi_feed_item_example").remove(),2!==e.length)return i;e=parseInt(e[1]);if(e<=0)return i;e=d.width()/e-10;return e<=150?(i.image="thumbnail",i.video="low_bandwidth"):150<e&&e<=320?(i.image="low_resolution",i.video="low_resolution"):(i.image="standard_resolution",i.video="standard_resolution"),i},wdi_front.isJsonString=function(e){try{JSON.parse(e)}catch(e){return!1}return!0},wdi_front.instagramRequest=function(i,d){var r=this,e=d.feed_users;if("string"==typeof e[i]&&"self"===e[i])d.instagram.getRecentLikedMedia({success:function(e){void 0!==e.meta&&void 0!==e.meta.error_type&&wdi_front.show_alert(!1,e,d),d.mediaRequestsDone=!0,0!=(e=r.checkMediaResponse(e,d))&&r.saveSelfUserData(e,d)}});else if("hashtag"==this.getInputType(e[i].username)){if(this.isJsonString(d.feed_row.feed_users))for(var t in json_feed_users=JSON.parse(d.feed_row.feed_users),json_feed_users)"#"!==json_feed_users[t].username.charAt(0)&&(user=json_feed_users[t]);d.instagram.getTagRecentMedia(this.stripHashtag(e[i].username),{feed_id:d.feed_row.id,user_id:user.id,user_name:user.username,success:function(e){if(void 0!==e.error&&"undefined"!=e.error.type||void 0!==e.meta&&1==e.meta.error)return d.dataLoaded=1,wdi_front.show_alert(!1,e,d),!1;d.mediaRequestsDone=!0,e=r.checkMediaResponse(e,d),d.dataLoaded=1,0!=e&&r.saveUserData(e,d.feed_users[i],d)}},null,d.feed_row.hashtag_top_recent,0)}else"user"==this.getInputType(e[i].username)&&d.instagram.getUserMedia({feed_id:d.feed_row.id,user_id:e[i].id,user_name:e[i].username,success:function(e){if(void 0!==e.meta&&1==typeof e.meta.error)return d.dataLoaded=1,wdi_front.show_alert(!1,e,d),!1;d.mediaRequestsDone=!0,d.dataLoaded=1,0!=(e=r.checkMediaResponse(e,d))?r.saveUserData(e,d.feed_users[i],d):wdi_front.allImagesLoaded(d)}},"",0)},wdi_front.isHashtag=function(e){return"#"===e[0]},wdi_front.saveUserData=function(e,i,d){e.user_id=i.id,e.username=i.username,"#"===e.user_id[0]&&(e.data=wdi_front.appendRequestHashtag(e.data,e.user_id)),d.usersData.push(e),d.currentResponseLength=wdi_front.getArrayContentLength(d.usersData,"data"),d.allResponseLength+=d.currentResponseLength,d.dataCount==d.usersData.length&&(d.currentResponseLength<d.feed_row.number_of_photos&&!wdi_front.userHasNoPhoto(d)?wdi_front.loadMore("initial-keep",d):(wdi_front.displayFeed(d),wdi_front.applyFilters(d),wdi_front.activeUsersCount(d)||"load_more_btn"==d.feed_row.feed_display_view&&((d=jQuery("#wdi_feed_"+d.feed_row.wdi_feed_counter)).find(".wdi_load_more").addClass("wdi_hidden"),d.find(".wdi_spinner").addClass("wdi_hidden"))))},wdi_front.saveSelfUserData=function(e,i){e.user_id="",e.username="",i.usersData.push(e),i.currentResponseLength=wdi_front.getArrayContentLength(i.usersData,"data"),i.allResponseLength+=i.currentResponseLength,i.dataCount==i.usersData.length&&(i.currentResponseLength<i.feed_row.number_of_photos&&!wdi_front.userHasNoPhoto(i)?wdi_front.loadMore("initial-keep",i):(wdi_front.displayFeed(i),wdi_front.applyFilters(i),wdi_front.activeUsersCount(i)||"load_more_btn"==i.feed_row.feed_display_view&&((i=jQuery("#wdi_feed_"+i.feed_row.wdi_feed_counter)).find(".wdi_load_more").addClass("wdi_hidden"),i.find(".wdi_spinner").addClass("wdi_hidden"))))},wdi_front.userHasNoPhoto=function(e,i){var d=0,r=e.usersData;void 0!==i&&(r=i);for(var t=0;t<r.length;t++)void 0===r[t].pagination&&(r[t].pagination=[]),"liked"===e.feed_row.liked_feed?void 0===r[t].pagination.next_max_like_id&&d++:void 0===r[t].pagination.next_max_id&&d++;return d==r.length?1:0},wdi_front.appendRequestHashtag=function(e,i){for(var d=0;d<e.length;d++)e[d].wdi_hashtag=i;return e},wdi_front.displayFeed=function(e,i){void 0===i&&(i=1);for(var d=0;d<e.usersData.length;d++)e.dataStorageList=e.usersData[d].data,e.dataStorage[d]=e.usersData[d].data;var r=e.feed_row.number_of_photos,t=e.feed_row.load_more_number,a=0,o=r,r="";"pagination"==e.feed_row.feed_display_view?(1<e.allResponseLength&&jQuery("#wdi_pagination").removeClass("wdi_hidden"),e.feed_row.number_of_photos=e.allResponseLength,"image_browser"==e.feed_row.feed_type?e.paginator=parseInt(e.feed_row.number_of_photos):e.paginator=Math.ceil(parseInt(e.feed_row.number_of_photos)/parseInt(t)),r=(o=1===i?(a=0,"image_browser"==e.feed_row.feed_type?1:t):"image_browser"==e.feed_row.feed_type?(a=i-1)+1:(a=(i-1)*t)+t,e.dataStorageList.slice(a,o))):void 0!==e.already_loaded_count?(a=parseInt(e.already_loaded_count),o=e.already_loaded_count+parseInt(t),r=e.dataStorageList.slice(a,o),e.already_loaded_count+=r.length):(r=e.dataStorageList.slice(a,o),e.already_loaded_count=r.length),e.parsedData=wdi_front.parseLighboxData(e,!0),"masonry"==e.feed_row.feed_type&&wdi_front.masonryDisplayFeedItems(r,e),"thumbnails"!=e.feed_row.feed_type&&"blog_style"!=e.feed_row.feed_type&&"image_browser"!=e.feed_row.feed_type||wdi_front.displayFeedItems(r,e),"pagination"==e.feed_row.feed_display_view&&e.currentPage<e.paginator&&jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter).find("#wdi_last_page").removeClass("wdi_disabled"),wdi_front.updateUsersImages(e)},wdi_front.updateUsersImages=function(i){jQuery("#wdi_feed_"+i.feed_row.wdi_feed_counter).find(".wdi_single_user .wdi_user_img_wrap img").each(function(){if((jQuery(this).attr("src")==wdi_url.plugin_url+"images/missing.png"||""==jQuery(this).attr("src"))&&"liked"!=i.feed_row.liked_feed)for(var e=0;e<i.usersData.length;e++)i.usersData[e].username==jQuery(this).parent().parent().find("h3").text()&&0!=i.usersData[e].data.length&&jQuery(this).attr("src",i.usersData[e].data[0].images.thumbnail.url)})},wdi_front.checkLoaded=function(e){var i=e.feed_row.wdi_feed_counter,d=jQuery("#wdi_feed_"+i);e.dataStorageList.length>e.already_loaded_count?d.find(".wdi_load_more").removeClass("wdi_hidden"):d.find(".wdi_load_more").addClass("wdi_hidden"),d.find(".wdi_spinner").addClass("wdi_hidden"),setTimeout(function(){d.find(".wdi_ajax_loading").addClass("wdi_hidden")},500)},wdi_front.masonryDisplayFeedItems=function(e,i){var d=[],r=[];if(0!=jQuery("#wdi_feed_"+i.feed_row.wdi_feed_counter+" .wdi_feed_wrapper").length){jQuery("#wdi_feed_"+i.feed_row.wdi_feed_counter+" .wdi_masonry_column").each(function(){1==i.feed_row.resort_after_load_more&&(jQuery(this).html(""),i.imageIndex=0),1==i.customFilterChanged&&(jQuery(this).html(""),i.imageIndex=0),"pagination"==i.feed_row.feed_display_view?d.push(0):d.push(jQuery(this).height()),r.push(jQuery(this))}),1==i.customFilterChanged&&(i.customFilterChanged=!1);for(var t,a,o,n=0;n<e.length;n++)"object"==typeof e[n].videos&&null==e[n].videos.standard_resolution||(i.displayedData.push(e[n]),t="",void 0!==e[n].wdi_hashtag&&(t=e[n].wdi_hashtag),a="image"==e[n].type?wdi_front.getPhotoTemplate(i,t):e[n].hasOwnProperty("videos")||"video"==e[n].type?wdi_front.getVideoTemplate(i,t):wdi_front.getSliderTemplate(i,t),o=e[n],t=a(wdi_front.createObject(o,i)),a=wdi_front.array_min(d),o=wdi_front.getImageResolution(e[n]),r[a.index].html(r[a.index].html()+t),d[a.index]+=r[a.index].width()*o,i.imageIndex++,"pagination"==i.feed_row.feed_display_view&&((n+1)%i.feed_row.pagination_per_page_number==0?i.resIndex+=i.freeSpaces+1:i.resIndex++));i.wdi_loadedImages=0;var s=!1;i.wdi_load_count=n;var _=i.feed_row.wdi_feed_counter;jQuery("#wdi_feed_"+_+" .wdi_img").on("load",function(){i.wdi_loadedImages++,!1===s&&(wdi_responsive.columnControl(i,1),s=!0)});wdi_front.checkLoaded(i),1==i.paginatorNextFlag&&wdi_front.updatePagination(i,"next"),i.infiniteScrollFlag=!1}},wdi_front.getImageResolution=function(e){var i;return e="image"===e.type?(i=e.images.standard_resolution.height,e.images.standard_resolution.width):"video"===e.type?(i=e.videos.standard_resolution.height,e.videos.standard_resolution.width):(i=(e.carousel_media[0].images||e.carousel_media[0].videos).standard_resolution.height,(e.carousel_media[0].images||e.carousel_media[0].videos).standard_resolution.width),i/e},wdi_front.getDataLength=function(e,i){var d=0;if(void 0===i)for(var r=0;r<e.dataStorage.length;r++)d+=e.dataStorage[r].length;else for(r=0;r<i.length;r++)d+=i[r].length;return d},wdi_front.getArrayContentLength=function(e,i){for(var d=0,r=0;r<e.length;r++)"finished"!=e[r].finished&&void 0===e[r].error&&(d+=e[r][i].length);return d},wdi_front.displayFeedItems=function(e,d){if(0!=jQuery("#wdi_feed_"+d.feed_row.wdi_feed_counter+" .wdi_feed_wrapper").length){for(var i,r,t,a=d.feed_row.wdi_feed_counter,o=jQuery("#wdi_feed_"+a+" .wdi_feed_wrapper"),n=0;n<e.length;n++){if(void 0===e[n])return;"object"==typeof e[n].videos&&null==e[n].videos.standard_resolution||(t="",void 0!==e[n].wdi_hashtag&&(t=e[n].wdi_hashtag),i="image"==e[n].type?wdi_front.getPhotoTemplate(d,t):e[n].hasOwnProperty("videos")?wdi_front.getVideoTemplate(d,t):wdi_front.getSliderTemplate(d,t),r=e[n],t="",void 0!==(r=wdi_front.createObject(r,d))&&(t=i(r)),o.html(o.html()+t),d.imageIndex++,"pagination"==d.feed_row.feed_display_view&&((n+1)%d.feed_row.pagination_per_page_number==0?d.resIndex+=d.freeSpaces+1:d.resIndex++))}!function(){var e=d.feed_row.wdi_feed_counter,i=jQuery("#wdi_feed_"+e);d.dataStorageList.length>d.already_loaded_count?i.find(".wdi_load_more").removeClass("wdi_hidden"):i.find(".wdi_load_more").addClass("wdi_hidden"),i.find(".wdi_spinner").addClass("wdi_hidden");setTimeout(function(){i.find(".wdi_ajax_loading").addClass("wdi_hidden")},500)}()}},wdi_front.checkFeedFinished=function(e){for(var i=0;i<e.usersData.length;i++)if(void 0===e.usersData[i].finished)return!1;return!0},wdi_front.createObject=function(e,i){var d=null!=e.caption?e.caption.text:" ";switch(e.type){case"image":var r=e.images[i.feedImageResolution].url,t=void 0,a=e.hasOwnProperty("thumbnail")?e.thumbnail:wdi_url.plugin_url+"images/missing.png";break;case"video":r=void 0,t=e.hasOwnProperty("videos")?e.videos[i.feedVideoResolution].url:wdi_url.plugin_url+"images/video_missing.png",a=e.hasOwnProperty("thumbnail")?e.thumbnail:wdi_url.plugin_url+"images/video_missing.png";break;case"carousel":if(0===e.carousel_media.length)r=wdi_url.plugin_url+"images/missing.png",t=void 0,a=wdi_url.plugin_url+"images/missing.png";else switch(e.carousel_media[0].type){case"image":r=e.carousel_media[0].images[i.feedImageResolution].url,t=void 0,a=e.hasOwnProperty("thumbnail")?e.thumbnail:wdi_url.plugin_url+"images/missing.png";break;case"video":r=void 0,t=e.carousel_media[0].videos[i.feedVideoResolution].url,a=e.hasOwnProperty("thumbnail")?e.thumbnail:wdi_url.plugin_url+"images/video_missing.png";break;default:r=wdi_url.plugin_url+"images/missing.png",t=void 0,a=wdi_url.plugin_url+"images/missing.png"}break;default:r=wdi_url.plugin_url+"images/missing.png",t=void 0,a=wdi_url.plugin_url+"images/missing.png"}var o,n=i.imageIndex,s="square";(_="image"===e.type?(o=e.images.standard_resolution.height,e.images.standard_resolution.width):"video"===e.type?(o=e.videos.standard_resolution.height,e.videos.standard_resolution.width):(o=(e.carousel_media[0].images||e.carousel_media[0].videos).standard_resolution.height,(e.carousel_media[0].images||e.carousel_media[0].videos).standard_resolution.width))<o?s="portrait":o<_&&(s="landscape");var _=e.user.username;return""===_&&(_="no_user"),{id:e.id,thumb_url:a,caption:wdi_front.escape_tags(d),image_url:r,likes:void 0!==e.likes.count?e.likes.count:e.likes,comments:void 0!==e.comments.count?e.comments.count:e.comments,wdi_index:n,wdi_res_index:i.resIndex,wdi_media_user:_,link:e.link,video_url:t,wdi_username:_,wdi_shape:s}},wdi_front.getPhotoTemplate=function(e,i){var d="",r="",t="",a="tenweb-i-arrows-out",o="";"blog_style"!=e.feed_row.feed_type&&"image_browser"!=e.feed_row.feed_type||(a=""),"1"==e.feed_row.show_username_on_thumb&&e.data.length&&""!==e.data[0].user.username&&(o='<span class="wdi_media_user">@<%= wdi_username%></span>'),1==e.feed_row.show_full_description&&"masonry"==e.feed_row.feed_type&&(d+=" wdi_full_caption");var n="";switch("blog_style"!==e.feed_row.feed_type&&(n="masonry"==e.feed_row.feed_type?"wdi_responsive.showMasonryCaption(jQuery(this),"+e.feed_row.wdi_feed_counter+");":"wdi_responsive.showCaption(jQuery(this),"+e.feed_row.wdi_feed_counter+");"),e.feed_row.feed_item_onclick){case"lightbox":r="onclick=wdi_feed_"+e.feed_row.wdi_feed_counter+".galleryBox('<%=id%>')";break;case"instagram":r="onclick=\"window.open ('<%= link%>','_blank')\"",t="wdi_hover_off",a="";break;case"custom_redirect":r="onclick=\"window.open ('"+e.feed_row.redirect_url+"','_self')\"",t="wdi_hover_off",a="";break;case"none":t="wdi_cursor_off wdi_hover_off",a=r=""}var s='<div class="wdi_feed_item '+d+'" wdi_index=<%= wdi_index%> wdi_res_index=<%= wdi_res_index%> wdi_media_user=<%= wdi_media_user%> wdi_type="image" id="wdi_'+e.feed_row.wdi_feed_counter+'_<%=id%>"><div class="wdi_photo_wrap"><div class="wdi_photo_wrap_inner"><div class="wdi_photo_img <%= wdi_shape == \'square\' ? \'wdi_shape_square\' : (wdi_shape == \'portrait\' ? \'wdi_shape_portrait\' : (wdi_shape == \'landscape\' ? \'wdi_shape_landscape\' : \'wdi_shape_square\') ) %>"><img class="wdi_img" src="<%=thumb_url%>" alt="feed_image" onerror="wdi_front.brokenImageHandler(this);"><div class="wdi_photo_overlay '+t+'" >'+o+'<div class="wdi_thumb_icon" '+r+' style="display:table;width:100%;height:100%;"><div style="display:table-cell;vertical-align:middle;text-align:center;color:white;"><i class="tenweb-i '+a+'"></i></div></div></div></div></div></div>',d=e.imageIndex;return"1"!==e.feed_row.show_likes&&"1"!==e.feed_row.show_comments&&"1"!==e.feed_row.show_description||(s+='<div class="wdi_photo_meta">',o=void 0!==e.dataStorageList[d].likes.count?e.dataStorageList[d].likes.count:e.dataStorageList[d].likes,"1"===e.feed_row.show_likes&&0!==o&&(s+='<div class="wdi_thumb_likes"><i class="tenweb-i tenweb-i-heart-o"> <%= likes%></i></div>'),d=void 0!==e.dataStorageList[d].comments.count?e.dataStorageList[d].comments.count:e.dataStorageList[d].comments,"1"===e.feed_row.show_comments&&0!==d&&(s+='<div class="wdi_thumb_comments"><i class="tenweb-i tenweb-i-comment-square"> <%= comments%></i></div>'),s+='<div class="wdi_clear"></div>',"1"===e.feed_row.show_description&&(s+='<div class="wdi_photo_title" onclick='+n+" ><%=caption%></div>"),s+="</div>"),s+="</div>",_.template(s)},wdi_front.getSliderTemplate=function(e,i){var d="",r="",t="",a="tenweb-i-clone",o="";"blog_style"!=e.feed_row.feed_type&&"image_browser"!=e.feed_row.feed_type||(a=""),"1"==e.feed_row.show_username_on_thumb&&e.data.length&&""!==e.data[0].user.username&&(o='<span class="wdi_media_user">@<%= wdi_username%></span>'),1==e.feed_row.show_full_description&&"masonry"==e.feed_row.feed_type&&(d+=" wdi_full_caption");var n="";switch("blog_style"!==e.feed_row.feed_type&&(n="masonry"==e.feed_row.feed_type?"wdi_responsive.showMasonryCaption(jQuery(this),"+e.feed_row.wdi_feed_counter+");":"wdi_responsive.showCaption(jQuery(this),"+e.feed_row.wdi_feed_counter+");"),e.feed_row.feed_item_onclick){case"lightbox":r="onclick=wdi_feed_"+e.feed_row.wdi_feed_counter+".galleryBox('<%=id%>')";break;case"instagram":r="onclick=\"window.open ('<%= link%>','_blank')\"",t="wdi_hover_off",a="tenweb-i-clone";break;case"custom_redirect":r="onclick=\"window.open ('"+e.feed_row.redirect_url+"','_self')\"",t="wdi_hover_off",a="";break;case"none":t="wdi_cursor_off wdi_hover_off",a=r=""}var s='<div class="wdi_feed_item '+d+'" wdi_index=<%= wdi_index%> wdi_res_index=<%= wdi_res_index%> wdi_media_user=<%= wdi_media_user%> wdi_type="slideshow" id="wdi_'+e.feed_row.wdi_feed_counter+'_<%=id%>"><div class="wdi_photo_wrap"><div class="wdi_photo_wrap_inner"><div class="wdi_photo_img <%= wdi_shape == \'square\' ? \'wdi_shape_square\' : (wdi_shape == \'portrait\' ? \'wdi_shape_portrait\' : (wdi_shape == \'landscape\' ? \'wdi_shape_landscape\' : \'wdi_shape_square\') ) %>"><img class="wdi_img" src="<%=thumb_url%>" alt="feed_image" onerror="wdi_front.brokenImageHandler(this);"><div class="wdi_photo_overlay '+t+'" >'+o+'<div class="wdi_thumb_icon" '+r+' style="display:table;width:100%;height:100%;"><div style="display:table-cell;vertical-align:middle;text-align:center;color:white;"><i class="tenweb-i '+a+'"></i></div></div></div></div></div></div>',d=e.imageIndex;return"1"!==e.feed_row.show_likes&&"1"!==e.feed_row.show_comments&&"1"!==e.feed_row.show_description||(s+='<div class="wdi_photo_meta">',o=void 0!==e.dataStorageList[d].likes.count?e.dataStorageList[d].likes.count:e.dataStorageList[d].likes,"1"===e.feed_row.show_likes&&0!==o&&(s+='<div class="wdi_thumb_likes"><i class="tenweb-i tenweb-i-heart-o"> <%= likes%></i></div>'),d=void 0!==e.dataStorageList[d].comments.count?e.dataStorageList[d].comments.count:e.dataStorageList[d].comments,"1"===e.feed_row.show_comments&&0!==d&&(s+='<div class="wdi_thumb_comments"><i class="tenweb-i tenweb-i-comment-square"> <%= comments%></i></div>'),s+='<div class="wdi_clear"></div>',"1"===e.feed_row.show_description&&(s+='<div class="wdi_photo_title" onclick='+n+" ><%=caption%></div>"),s+="</div>"),s+="</div>",_.template(s)},wdi_front.replaceToVideo=function(e,i,d){overlayHtml="<video style='width:auto !important; height:auto !important; max-width:100% !important; max-height:100% !important; margin:0 !important;' controls=''><source src='"+e+"' type='video/mp4'>Your browser does not support the video tag. </video>",jQuery("#wdi_feed_"+d+' [wdi_index="'+i+'"] .wdi_photo_wrap_inner').html(overlayHtml),jQuery("#wdi_feed_"+d+' [wdi_index="'+i+'"] .wdi_photo_wrap_inner video').get(0).play()},wdi_front.getVideoTemplate=function(e,i){var d="",r="tenweb-i-play",t="",a="",o="";"1"==e.feed_row.show_username_on_thumb&&e.data.length&&""!==e.data[0].user.username&&(o='<span class="wdi_media_user">@<%= wdi_username%></span>'),1==e.feed_row.show_full_description&&"masonry"==e.feed_row.feed_type&&(d+=" wdi_full_caption");var n="";switch("blog_style"!==e.feed_row.feed_type&&(n="masonry"==e.feed_row.feed_type?"wdi_responsive.showMasonryCaption(jQuery(this),"+e.feed_row.wdi_feed_counter+");":"wdi_responsive.showCaption(jQuery(this),"+e.feed_row.wdi_feed_counter+");"),e.feed_row.feed_item_onclick){case"lightbox":t="onclick=wdi_feed_"+e.feed_row.wdi_feed_counter+".galleryBox('<%=id%>')";break;case"instagram":t="onclick=\"window.open ('<%= link%>','_blank')\"",a="wdi_hover_off",r="tenweb-i-play";break;case"custom_redirect":t="onclick=\"window.open ('"+e.feed_row.redirect_url+"','_self')\"",a="wdi_hover_off",r="";break;case"none":a="wdi_cursor_off wdi_hover_off",r="","blog_style"!=e.feed_row.feed_type&&"image_browser"!=e.feed_row.feed_type||(t="onclick=wdi_front.replaceToVideo('<%= video_url%>','<%= wdi_index%>',"+e.feed_row.wdi_feed_counter+")",a="",r="tenweb-i-play")}var s='<div class="wdi_feed_item '+d+'" wdi_index=<%= wdi_index%> wdi_res_index=<%= wdi_res_index%> wdi_media_user=<%= wdi_media_user%> wdi_type="image" id="wdi_'+e.feed_row.wdi_feed_counter+'_<%=id%>"><div class="wdi_photo_wrap"><div class="wdi_photo_wrap_inner"><div class="wdi_photo_img <%= wdi_shape == \'square\' ? \'wdi_shape_square\' : (wdi_shape == \'portrait\' ? \'wdi_shape_portrait\' : (wdi_shape == \'landscape\' ? \'wdi_shape_landscape\' : \'wdi_shape_square\') ) %>"><img class="wdi_img" src="<%=thumb_url%>" alt="feed_image" onerror="wdi_front.brokenImageHandler(this);"><div class="wdi_photo_overlay '+a+'" '+t+">"+o+'<div class="wdi_thumb_icon" style="display:table;width:100%;height:100%;"><div style="display:table-cell;vertical-align:middle;text-align:center;color:white;"><i class="tenweb-i '+r+'"></i></div></div></div></div></div></div>',d=e.imageIndex;return"1"!==e.feed_row.show_likes&&"1"!==e.feed_row.show_comments&&"1"!==e.feed_row.show_description||(s+='<div class="wdi_photo_meta">',o=void 0!==e.dataStorageList[d].likes.count?e.dataStorageList[d].likes.count:e.dataStorageList[d].likes,"1"===e.feed_row.show_likes&&0!==o&&(s+='<div class="wdi_thumb_likes"><i class="tenweb-i tenweb-i-heart-o"> <%= likes%></i></div>'),d=void 0!==e.dataStorageList[d].comments.count?e.dataStorageList[d].comments.count:e.dataStorageList[d].comments,"1"===e.feed_row.show_comments&&0!==d&&(s+='<div class="wdi_thumb_comments"><i class="tenweb-i tenweb-i-comment-square"> <%= comments%></i></div>'),s+='<div class="wdi_clear"></div>',"1"===e.feed_row.show_description&&(s+='<div class="wdi_photo_title" onclick='+n+" ><%=caption%></div>"),s+="</div>"),s+="</div>",_.template(s)},wdi_front.bindEvents=function(e){0!=jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_feed_wrapper").length&&("load_more_btn"==e.feed_row.feed_display_view&&jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_load_more_container").on(wdi_front.clickOrTouch,function(){jQuery(document).find("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_load_more").addClass("wdi_hidden"),jQuery(document).find("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_spinner").removeClass("wdi_hidden"),setTimeout(function(){wdi_front.loadMore(jQuery(this).find(".wdi_load_more_wrap"),e)},1e3)}),"pagination"==e.feed_row.feed_display_view&&(jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" #wdi_next").on(wdi_front.clickOrTouch,function(){parseInt(jQuery("#wdi_current_page").text())+1>e.paginator||(e.currentPage=parseInt(jQuery("#wdi_current_page").text())+1,wdi_front.changePage(jQuery(this),e))}),jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" #wdi_prev").on(wdi_front.clickOrTouch,function(){parseInt(jQuery("#wdi_current_page").text())-1<=0||(e.currentPage=parseInt(jQuery("#wdi_current_page").text())-1,wdi_front.changePage(jQuery(this),e))}),jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" #wdi_last_page").on(wdi_front.clickOrTouch,function(){e.currentPage=e.paginator,wdi_front.changePage(jQuery(this),e)}),jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" #wdi_first_page").on(wdi_front.clickOrTouch,function(){e.currentPage=1,wdi_front.changePage(jQuery(this),e)}),e.paginatorNextFlag=!1),"infinite_scroll"==e.feed_row.feed_display_view&&(jQuery(window).on("scroll",function(){wdi_front.infiniteScroll(e)}),e.infiniteScrollFlag=!1))},wdi_front.infiniteScroll=function(e){jQuery(window).scrollTop()+jQuery(window).height()-100>=jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" #wdi_infinite_scroll").offset().top&&(e.dataStorageList.length>e.already_loaded_count||void 0===e.already_loaded_count?(e.infiniteScrollFlag=!0,wdi_front.loadMore(jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" #wdi_infinite_scroll"),e)):wdi_front.allImagesLoaded(e))},wdi_front.changePage=function(e,i){var d=e.closest(".wdi_feed_container");d.find(".wdi_page_loading").removeClass("wdi_hidden"),new_page_number=i.currentPage,1<new_page_number?jQuery("#wdi_first_page").removeClass("wdi_disabled"):1===new_page_number&&jQuery("#wdi_first_page").addClass("wdi_disabled"),new_page_number==parseInt(i.paginator)?jQuery("#wdi_last_page").addClass("wdi_disabled"):new_page_number<parseInt(i.paginator)&&jQuery("#wdi_last_page").removeClass("wdi_disabled"),("masonry"==i.feed_row.feed_type?e.parent().parent().parent().find(".wdi_feed_wrapper .wdi_masonry_column"):e.parent().parent().parent().find(".wdi_feed_wrapper")).empty(),e.parent().find("#wdi_current_page").empty().text(new_page_number),wdi_front.displayFeed(i,new_page_number),d.find(".wdi_page_loading").addClass("wdi_hidden")},wdi_front.updatePagination=function(e,i,d){var r="#wdi_feed_"+e.feed_row.wdi_feed_counter;switch(jQuery(r+' [wdi_page="'+e.currentPage+'"]').each(function(){jQuery(this).removeClass("wdi_hidden")}),i){case"next":var d=e.currentPage-1;jQuery(r+" .wdi_feed_wrapper").height(jQuery(".wdi_feed_wrapper").height()),jQuery(r+' [wdi_page="'+d+'"]').each(function(){jQuery(this).addClass("wdi_hidden")});break;case"prev":d=e.currentPage+1;jQuery(r+" .wdi_feed_wrapper").height(jQuery(".wdi_feed_wrapper").height()),jQuery(r+' [wdi_page="'+d+'"]').each(function(){jQuery(this).addClass("wdi_hidden")});break;case"custom":(d=d)!=e.currentPage&&(jQuery(r+" .wdi_feed_wrapper").height(jQuery(".wdi_feed_wrapper").height()),jQuery(r+' [wdi_page="'+d+'"]').each(function(){jQuery(this).addClass("wdi_hidden")}))}e.paginatorNextFlag=!1,jQuery(r+" .wdi_feed_wrapper").css("height","auto"),jQuery(r+" #wdi_current_page").text(e.currentPage)},wdi_front.loadMore=function(e,i){var d;if(""!=e&&void 0!==e&&"initial"!=e&&"initial-keep"!=e&&(d=window[e.parent().parent().parent().parent().attr("id")]),void 0!==i&&(d=i),wdi_front.ajaxLoader(d),this.isJsonString(d.feed_row.feed_users))for(var r in json_feed_users=JSON.parse(d.feed_row.feed_users),json_feed_users)iuser=json_feed_users[r],"#"!==json_feed_users[r].username.charAt(0)&&(iuser=json_feed_users[r]);"masonry"===d.feed_row.feed_type&&"pagination"==d.feed_row.feed_display_view&&jQuery("#wdi_feed_"+wdi_front.feed_counter+" .wdi_full_caption").each(function(){jQuery(this).find(".wdi_photo_title").trigger(wdi_front.clickOrTouch)}),d.loadMoreDataCount=d.feed_users.length,wdi_front.displayFeed(d)},wdi_front.loadMoreRequest=function(e,i,d,r){d.mediaRequestsDone&&""!=i&&d.usersData},wdi_front.checkForLoadMoreDone=function(e,i){var d,r=e.feed_row.load_more_number,t=e.feed_row.number_of_photos;0==e.loadMoreDataCount&&(e.temproraryUsersData=wdi_front.mergeData(e.temproraryUsersData,e.usersData),d=wdi_front.getArrayContentLength(e.temproraryUsersData,"data"),"initial-keep"==i&&(i="initial"),"initial"==i?d<t&&!wdi_front.userHasNoPhoto(e,e.temproraryUsersData)&&e.instagramRequestCounter<=e.maxConditionalFiltersRequestCount?wdi_front.loadMore("initial",e):(e.usersData=e.temproraryUsersData,wdi_front.displayFeed(e),wdi_front.applyFilters(e),e.temproraryUsersData=[]):d<r&&!wdi_front.userHasNoPhoto(e,e.temproraryUsersData)&&e.instagramRequestCounter<=e.maxConditionalFiltersRequestCount?wdi_front.loadMore(void 0,e):(e.usersData=e.temproraryUsersData,wdi_front.activeUsersCount(e)&&(wdi_front.displayFeed(e,r),wdi_front.applyFilters(e),e.temproraryUsersData=[])))},wdi_front.allDataHasFinished=function(e){for(var i=0,d=0;d<e.dataStorageRaw.length;d++)""==e.usersData[d].pagination.next_url&&(i++,e.usersData[d].finished="finished");return i==e.dataStorageRaw.length&&(jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_load_more").remove(),!0)},wdi_front.mergeData=function(e,i){for(var d=0;d<i.length;d++)void 0!==e[d]?"finished"!=i[d].finished&&(void 0===e[d].pagination.next_max_id&&void 0===e[d].pagination.next_max_like_id||(e[d].data=e[d].data.concat(i[d].data),e[d].pagination=i[d].pagination,e[d].user_id=i[d].user_id,e[d].username=i[d].username,e[d].meta=i[d].meta)):e.push(i[d]);return e},wdi_front.brokenImageHandler=function(e){return!0},wdi_front.ajaxLoader=function(e){var i,d=e.feed_row.wdi_feed_counter,d=jQuery(document).find("#wdi_feed_"+d);return"load_more_btn"==e.feed_row.feed_display_view&&(d.find(".wdi_load_more").addClass("wdi_hidden"),d.find(".wdi_spinner").removeClass("wdi_hidden")),"infinite_scroll"==e.feed_row.feed_display_view&&(0==d.find(".wdi_ajax_loading").length?(i=jQuery('<div class="wdi_ajax_loading"><div><div><img class="wdi_load_more_spinner" src="'+wdi_url.plugin_url+'images/ajax_loader.png"></div></div></div>'),d.find(".wdi_feed_container").append(i)):i=d.find(".wdi_ajax_loading"),i.removeClass("wdi_hidden")),1},wdi_front.allImagesLoaded=function(e){wdi_front.getDataLength(e);e.mediaRequestsDone||jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_feed_wrapper").remove("wdi_nomedia"),0==e.allResponseLength&&1===e.dataLoaded&&jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_feed_wrapper").append("<p class='wdi_nomedia'>"+wdi_front_messages.feed_nomedia+"</p>");var i=e.feed_row.wdi_feed_counter,i=jQuery("#wdi_feed_"+i);"load_more_btn"==e.feed_row.feed_display_view&&(parseInt(e.allResponseLength)>parseInt(e.feed_row.number_of_photos)&&i.find(".wdi_load_more").removeClass("wdi_hidden"),i.find(".wdi_spinner").addClass("wdi_hidden")),"infinite_scroll"==e.feed_row.feed_display_view&&jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_ajax_loading").addClass("wdi_hidden")},wdi_front.show=function(e,i){var d,r,t=i.feed_row.wdi_feed_counter,a=jQuery("#wdi_feed_"+t+" .wdi_feed_container");"header"===e&&(d={feed_thumb:i.feed_row.feed_thumb,feed_name:i.feed_row.feed_name},r=wdi_front.getHeaderTemplate()(d),d=a.find(".wdi_feed_header").html(),a.find(".wdi_feed_header").html(d+r))},wdi_front.getUserTemplate=function(e,i){var d=e.dataCount,r="#"===i[0]?"//instagram.com/explore/tags/"+i.substr(1,i.length):"//instagram.com/"+i,t="onclick='"+('window.open("'+r+'","_blank")')+"'",r='<div class="wdi_single_user" user_index="<%=user_index%>"><div class="wdi_header_user_text <%=hashtagClass%>"><div class="wdi_user_img_wrap"><img onerror="wdi_front.brokenImageHandler(this);" src="<%= user_img_url%>">';return 1<d&&(r+='<div title="'+wdi_front_messages.filter_title+'" class="wdi_filter_overlay"><div class="wdi_filter_icon"><span onclick="wdi_front.addFilter(<%=user_index%>,<%=feed_counter%>);" class="tenweb-i tenweb-i-filter"></span></div></div>'),r+="</div>",r+="<h3 "+t+"><%= user_name%></h3>","#"!==i[0]?("1"==e.feed_row.follow_on_instagram_btn&&(r+='<div class="wdi_user_controls"><div class="wdi_follow_btn" onclick="window.open(\'//instagram.com/<%= user_name%>\',\'_blank\')"><span> '+wdi_front_messages.follow+"</span></div></div>"),r+='<div class="wdi_media_info"><p class="wdi_posts"><span class="tenweb-i tenweb-i-camera-retro"></span><%= counts.media%></p><p class="wdi_followers"><span class="tenweb-i tenweb-i-user"></span><%= counts.followed_by%></p></div>'):r+='<div class="wdi_user_controls"></div><div class="wdi_media_info"><p class="wdi_posts"><span class="tenweb-i tenweb-i-camera-retro"></span><%= counts.media%></p><p class="wdi_followers"><span></span></p></div>',r+='<div class="wdi_clear"></div>',1==d&&"#"!==i[0]&&"1"==e.feed_row.display_user_info&&(r+='<div class="wdi_bio"><%= bio%></div>',r+='<div class="wdi_website"><a target="_blank" href="<%= website_url%>" ><%= website%></a></div>'),r+="</div></div>",_.template(r)},wdi_front.getHeaderTemplate=function(){return _.template('<div class="wdi_header_wrapper"><div class="wdi_header_img_wrap"><img src="<%=feed_thumb%>"></div><div class="wdi_header_text"><%=feed_name%></div><div class="wdi_clear"></div>')},wdi_front.addFilter=function(e,i){var d=window["wdi_feed_"+i],i=d.dataCount;if(!(i<2)&&0==d.nowLoadingImages){i=jQuery("#wdi_feed_"+d.feed_row.wdi_feed_counter+'_users [user_index="'+e+'"]');i.find(".wdi_filter_overlay").toggleClass("wdi_filter_active_bg"),i.find(".wdi_header_user_text h3").toggleClass("wdi_filter_active_col"),i.find(".wdi_media_info").toggleClass("wdi_filter_active_col"),i.find(".wdi_follow_btn").toggleClass("wdi_filter_active_col"),d.customFilterChanged=!0,0==d.userSortFlags[e].flag?d.userSortFlags[e].flag=!0:d.userSortFlags[e].flag=!1;for(var r=0,t=0;t<d.userSortFlags.length;t++)1==d.userSortFlags[t].flag&&r++;"pagination"==d.feed_row.feed_display_view&&(d.resIndex=0),0!=r?wdi_front.filterData(d):d.customFilteredData=d.dataStorageList,wdi_front.displayFeed(d),"pagination"==d.feed_row.feed_display_view&&(d.paginator=Math.ceil(d.imageIndex/parseInt(d.feed_row.pagination_per_page_number)),d.currentPage=d.paginator,wdi_front.updatePagination(d,"custom",1),jQuery("#wdi_first_page").removeClass("wdi_disabled"),jQuery("#wdi_last_page").addClass("wdi_disabled"))}},wdi_front.filterData=function(e){var i=e.userSortFlags;e.customFilteredData=[];for(var d=0;d<e.dataStorageList.length;d++)for(var r=0;r<i.length;r++)(void 0!==e.dataStorageList[d].user.id&&e.dataStorageList[d].user.id==i[r].id||e.dataStorageList[d].wdi_hashtag==i[r].name)&&1==i[r].flag&&e.customFilteredData.push(e.dataStorageList[d])},wdi_front.applyFilters=function(e){for(var i=0;i<e.userSortFlags.length;i++)1==e.userSortFlags[i].flag&&(jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+'[user_index="'+i+'"]'),wdi_front.addFilter(i,e.feed_row.wdi_feed_counter),wdi_front.addFilter(i,e.feed_row.wdi_feed_counter))},wdi_front.getImgCount=function(e){for(var i=e.dataStorage,d=0,r=0;r<i.length;r++)d+=i[r].length;return d},wdi_front.parseLighboxData=function(e,i){for(var d,r,t,a,o=e.dataStorage,n=[],s=[],_=0;_<o.length;_++)for(var w=0;w<o[_].length;w++)n.push(o[_][w]);for(_=0;_<n.length;_++)void 0!==n[_]&&(r=void 0!==n[_]&&void 0!==n[_].media_url?n[_].media_url:wdi_url.plugin_url+"images/video_missing.png",r=n[_].thumbnail,void 0!==n[_]&&void 0===n[_].media_url&&("carousel"!==n[_].type||(void 0!==(a=n[_].carousel_media[0])&&void 0!==a.images||void 0!==a&&void 0!==a.videos)&&(r=a.thumbnail)),a=void(t=0)!==n[_].comments.count?n[_].comments.count:n[_].comments,void 0!==n[_]&&void 0!==a&&(t=a),d={alt:"",avg_rating:"",comment_count:t,date:wdi_front.convertUnixDate(n[_].created_time),description:wdi_front.getDescription(void 0!==n[_].caption&&null!==n[_].caption?wdi_front.escape_tags(n[_].caption.text):""),filename:wdi_front.getFileName(n[_]),filetype:wdi_front.getFileType(n[_]),hit_count:"0",id:n[_].id,image_url:n[_].link,number:0,rate:"",rate_count:"0",username:void 0!==n[_].user?n[_].user.username:"",profile_picture:void 0!==n[_].user?n[_].user.profile_picture:"",thumb_url:r,comments_data:void 0!==n[_].comments?n[_].comments.data:"",images:n[_].images||n[_].videos,carousel_media:void 0!==n[_].carousel_media?n[_].carousel_media:null},s.push(d));return s},wdi_front.convertUnixDate=function(e){var i=new Date(e).getTime()/1e3,e=new Date(0);e.setUTCSeconds(i);i=e.getFullYear()+"-"+(e.getMonth()+1)+"-"+e.getDate();return i+=" "+e.getHours()+":"+e.getMinutes()},wdi_front.getDescription=function(e){return e=e.replace(/\r?\n|\r/g," ")},wdi_front.getFileName=function(e){if(void 0!==e){var i=e.link;if("video"===e.type&&e.hasOwnProperty("videos")&&null!=e.videos.standard_resolution)return e.videos.standard_resolution.url;if(void 0===i)return"";i=i.split("/");return i[i.length-2]}},wdi_front.getFileType=function(e){return"video"==e.type&&e.hasOwnProperty("videos")?"EMBED_OEMBED_INSTAGRAM_VIDEO":"carousel"==e.type&&e.hasOwnProperty("carousel_media")?"EMBED_OEMBED_INSTAGRAM_CAROUSEL":"EMBED_OEMBED_INSTAGRAM_IMAGE"},wdi_front.array_max=function(e){for(var i=e[0],d=0,r=1;r<e.length;r++)i<e[r]&&(i=e[r],d=r);return{value:i,index:d}},wdi_front.array_min=function(e){for(var i=e[0],d=0,r=1;r<e.length;r++)i>e[r]&&(i=e[r],d=r);return{value:i,index:d}},wdi_front.activeUsersCount=function(e){for(var i=0,d=0;d<e.usersData.length;d++)"finished"!=e.usersData[d].finished&&i++;return i},wdi_front.checkMediaResponse=function(e,i){return""==e||void 0===e||null==e||void 0!==e.error?(errorMessage=wdi_front_messages.connection_error,wdi_front.show_alert(errorMessage,e,i),!1):""!=e&&void 0!==e&&null!=e&&void 0!==e.meta&&200!=e.meta.code?(errorMessage=e.meta.error_message,wdi_front.show_alert(errorMessage,e,i),!1):e},wdi_front.stripHashtag=function(e){return"#"!==e[0]?e:e.substr(1,e.length)},wdi_front.getInputType=function(e){switch(e[0]){case"#":return"hashtag";case"%":return"location";default:return"user"}},wdi_front.regexpTestCaption=function(e,i){var d=!1,r=!1,t=i.replace(/[-[\]{}()*+?.,\\^$|]/g,"\\$&"),i=new RegExp("(?:^|\\s)"+t+"(?:^|\\s)"),a=new RegExp("(?:^|\\s)"+t,"g");for(null!=i.exec(e)&&(d=!0);null!=(match=a.exec(e));)r=!0;return 1==d||1==r},wdi_front.replaceNewLines=function(e){var i,d="vUkCJvN2ps3t",r=[];for(e=e.replace(/\r?\n|\r/g,d),i=new RegExp(d,"g");null!=(match=i.exec(e));)r.push(match.index);for(var t=e.split(d),a=0,o=0;o<t.length;o++)""==t[o]?a++:a=0,0<a&&(t.splice(o,1),a--,o--);return e=t.join(" ")},wdi_front.isEmptyObject=function(e){for(var i in e)if(e.hasOwnProperty(i))return!1;return!0},wdi_front.isEmpty=function(e){return!e||0===e.length};var WDIFeed=function(e){this.data=e.data,this.dataCount=e.dataCount,this.feed_row=e.feed_row,this.usersData=e.usersData,(_this=this).set_images_loading_flag=function(e){window.addEventListener("load",function(){e.nowLoadingImages=!1})},this.set_images_loading_flag(_this)};function wdi_extractHostname(e){return void 0===e||""===e?"":e.replace(/(^\w+:|^)\/\//,"")}WDIFeed.prototype.mediaExists=function(e,i){for(var d=0;d<i.length;d++)if(e.id==i[d].id)return!0;return!1},WDIFeed.prototype.getIdFromUrl=function(e){for(var i=e.split("/"),d=!1,r=0;r<i.length;r++)if("p"==i[r]&&void 0!==i[r+1]){d=i[r+1];break}return d},WDIFeed.prototype.avoidDuplicateMedia=function(e){var i=e.data,d=[];void 0===i&&(i=[]);for(var r=0;r<i.length;r++)this.mediaExists(i[r],this.dataStorageList)||this.mediaExists(i[r],d)||this.mediaExists(i[r],this.conditionalFilterBuffer)||d.push(i[r]);return this.conditionalFilterBuffer=this.conditionalFilterBuffer.concat(d),{data:d,meta:e.meta,pagination:e.pagination}},WDIFeed.prototype.storeRawData=function(e,i){var r=this;if("object"==typeof this[i]&&"number"==typeof this[i].length)for(var d=0;d<e.length;d++){var t="";wdi_front.isHashtag(e[d].user_id)?void 0!==e[d].pagination.cursors&&(t=e[d].pagination.cursors.after):"liked"==r.feed_row.liked_feed?void 0===(t=e[d].pagination.next_max_like_id)&&(t=""):(null==e[d].pagination&&(e[d].pagination=[]),void 0===(t=e[d].pagination.next_max_id)&&(t="")),void 0===this[i][d]?this[i].push({data:e[d].data,index:0,locked:!1,hash_id:t,usersDataFinished:!1,userId:e[d].user_id,length:function(){return this.data.length-this.index},getData:function(e){var i=this.data.slice(this.index,this.index+e);if(this.index+=Math.min(e,this.length()),this.index==this.data.length&&1==this.locked&&0==this.usersDataFinished)for(var d=0;d<r.usersData.length;d++)if(r.usersData[d].user_id==this.userId){this.usersDataFinished=!0;break}return i}}):0==this[i][d].locked&&(t!=this[i][d].hash_id?(this[i][d].data=this[i][d].data.concat(e[d].data),this[i][d].hash_id=t):this[i][d].locked=!0)}},wdi_front.updateUsersIfNecessary=function(o){for(var n=o.feed_users,e=!1,i=0;i<n.length;i++)"#"!=n[i].username.substr(0,1)?""!=n[i].id&&"username"!=n[i].id||(e=!0,o.instagram.searchForUsersByName(n[i].username,{success:function(e){if(void 0!==e.meta&&void 0!==e.meta.error_type&&wdi_front.show_alert(!1,e,o),200==e.meta.code&&0<e.data.length){for(var i=!1,d=0;d<e.data.length;d++)if(e.data[d].username==e.args.username){i=!0;break}if(i)for(var r=0;r<n.length;r++)e.data[d].username==n[r].username&&(n[r].id=e.data[d].id)}for(var t=!1,a=0;a<n.length;a++)if(""==n[a].id||"username"==n[a].id){t=!0;break}t||(o.feed_row.feed_users=JSON.stringify(n),wdi_front.init(o))},username:n[i].username})):n[i].id=n[i].username;return e},void 0!==wdi_ajax.ajax_response?jQuery(document).one("ajaxStop",function(){"not_declared"!=wdi_front.type&&(wdi_front.clickOrTouch=wdi_front.detectEvent(),wdi_front.globalInit())}):jQuery(document).ready(function(){"not_declared"!=wdi_front.type&&(wdi_front.clickOrTouch=wdi_front.detectEvent(),wdi_front.globalInit())}),jQuery(document).ready(function(){setTimeout(function(){"1"===wdi_front_messages.show_alerts&&"I"!==jQuery(".wdi_check_fontawesome .tenweb-i-instagram").prop("tagName")&&console.log("Font Awesome is not loaded properly. Please ask for support https://wordpress.org/support/plugin/wd-instagram-feed/")},2e3)});
|
| 1 |
+
"undefined"==typeof wdi_front&&(wdi_front={type:"not_declared"});var wdi_error_show=!(wdi_front.detectEvent=function(){var e="click";return/android|webos|iphone|ipad|ipod|blackberry|iemobile|opera mini/i.test(navigator.userAgent.toLowerCase())&&(e="touchend"),e}),wdi_error_init=!1;function wdi_baseName(e){var i=e.substr(e.lastIndexOf("/"));return e.replace(i,"")}wdi_front.escape_tags=function(e){return void 0===e&&(e=""),e=e.toString().replace(/</g,"<").replace(/>/g,">").replace(/'/g,"'").replace(/"/g,""")},wdi_front.show_alert=function(e,i,d){var r,t;void 0!==(d=jQuery("#wdi_feed_"+d.feed_row.wdi_feed_counter))&&(wdi_error_show=!0,d.find(".wdi_spinner").remove(),r=d.find(".wdi_js_error"),t=d.find(".wdi_token_error"),0!=i&&(void 0!==i.meta&&1==i.meta.error&&"OAuthException"===i.meta.error_type||void 0!==i.error&&"OAuthException"===i.error.type)?(d.find(".wdi_single_user").remove(),t.removeClass("wdi_hidden"),"1"!=wdi_front_messages.wdi_token_error_flag&&jQuery.ajax({type:"POST",url:wdi_url.ajax_url,dataType:"json",data:{action:"wdi_token_flag",wdi_token_flag_nonce:wdi_front_messages.wdi_token_flag_nonce},success:function(e){}})):void 0!==i.error&&void 0!==i.error.message&&(r.html(i.error.message),d.find(".wdi_single_user").remove(),r.removeClass("wdi_js_error"),r.addClass("wdi_js_error_no_animate"),jQuery(".wdi_js_error_no_animate").show()),wdi_front_messages.show_alerts||console.log("%c"+e,"color:#cc0000;")),wdi_error_show=!0},wdi_front.globalInit=function(){var e=wdi_front.feed_counter,i=0;void 0!==wdi_ajax.ajax_response&&(i=wdi_feed_counter_init.wdi_feed_counter_init);for(var d,r=i;r<=e;r++)0!==jQuery("#wdi_feed_"+r).length&&((d=new WDIFeed(window["wdi_feed_"+r])).instagram=new WDIInstagram,d.instagram.filterArguments={feed:d},d.instagram.addToken(d.feed_row.access_token),wdi_front.access_token=d.feed_row.access_token,d.dataLoaded=0,d.dataStorageRaw=[],d.dataStorage=[],d.dataStorageList=[],d.allResponseLength=0,d.currentResponseLength=0,d.temproraryUsersData=[],d.removedUsers=0,d.nowLoadingImages=!0,d.imageIndex=0,d.resIndex=0,d.currentPage=1,d.currentPageLoadMore=0,d.userSortFlags=[],d.customFilterChanged=!1,d.maxConditionalFiltersRequestCount=10,d.instagramRequestCounter=0,d.mediaRequestsDone=!1,d.conditionalFilterBuffer=[],d.stopInfiniteScrollFlag=!1,"masonry"==d.feed_row.feed_type&&(d.displayedData=[]),"pagination"==d.feed_row.feed_display_view?(d.feed_row.resort_after_load_more=0,"image_browser"!=d.feed_row.feed_type?(d.feed_row.load_more_number=parseInt(d.feed_row.pagination_per_page_number),d.feed_row.number_of_photos=d.allResponseLength):(d.feed_row.number_of_photos=1+parseInt(d.feed_row.image_browser_preload_number),d.feed_row.load_more_number=parseInt(d.feed_row.image_browser_load_number)),d.freeSpaces=(Math.floor(d.feed_row.pagination_per_page_number/d.feed_row.number_of_columns)+1)*d.feed_row.number_of_columns-d.feed_row.pagination_per_page_number):d.freeSpaces=0,d.galleryBox=function(e){wdi_spider_createpopup(wdi_url.ajax_url+"?gallery_id="+this.feed_row.id+"&image_id="+e,this.feed_row.wdi_feed_counter,this.feed_row.lightbox_width,this.feed_row.lightbox_height,1,"testpopup",5,this,e)},wdi_responsive.columnControl(d),"masonry"==d.feed_row.feed_type&&jQuery(window).trigger("resize"),wdi_front.bindEvents(d),window["wdi_feed_"+r]=d,wdi_front.init(d))},wdi_front.init=function(e){if(jQuery(".wdi_js_error").hide(),e.photoCounter=e.feed_row.number_of_photos,"liked"==e.feed_row.liked_feed)e.feed_users=["self"];else{if(!wdi_front.isJsonString(e.feed_row.feed_users))return void wdi_front.show_alert(wdi_front_messages.invalid_users_format,!1,e);e.feed_users=JSON.parse(e.feed_row.feed_users)}var i=[],d=[],r=[];void 0!==window.wdi_all_tags&&(i=window.wdi_all_tags);for(var t=0;t<e.feed_users.length;t++)"#"===e.feed_users[t].username[0]&&void 0!==e.feed_users[t].tag_id?(i[e.feed_users[t].tag_id]=e.feed_users[t],r[t]=e.feed_users[t]):d[0]=e.feed_users[t];window.wdi_all_tags=i,e.feed_users=void 0===r||wdi_front.isEmpty(r)?d:r;var a=wdi_front.getFeedItemResolution(e);e.feedImageResolution=a.image,e.feedVideoResolution=a.video,e.dataCount=e.feed_users.length;for(var o=0;o<e.dataCount;o++)wdi_front.instagramRequest(o,e);0<e.feed_row.number_of_photos&&wdi_front.ajaxLoader(e),"1"===e.feed_row.display_header&&wdi_front.show("header",e),"1"===e.feed_row.show_usernames&&wdi_front.show("users",e)},wdi_front.getFeedItemResolution=function(e){var i={image:"standard_resolution",video:"standard_resolution"};if("thumbnail"===e.feed_row.feed_resolution)return{image:"thumbnail",video:"low_bandwidth"};if("low"===e.feed_row.feed_resolution)return{image:"low_resolution",video:"low_resolution"};if("standard"===e.feed_row.feed_resolution)return{image:"standard_resolution",video:"standard_resolution"};var d=jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter).find(".wdi_feed_wrapper");d.append('<div class="wdi_feed_item" id="wdi_feed_item_example"></div>'),wdi_responsive.columnControl(e,1);e=d.attr("wdi-res").split("wdi_col_");if(d.find("#wdi_feed_item_example").remove(),2!==e.length)return i;e=parseInt(e[1]);if(e<=0)return i;e=d.width()/e-10;return e<=150?(i.image="thumbnail",i.video="low_bandwidth"):150<e&&e<=320?(i.image="low_resolution",i.video="low_resolution"):(i.image="standard_resolution",i.video="standard_resolution"),i},wdi_front.isJsonString=function(e){try{JSON.parse(e)}catch(e){return!1}return!0},wdi_front.instagramRequest=function(i,d){var r=this,e=d.feed_users;if("string"==typeof e[i]&&"self"===e[i])d.instagram.getRecentLikedMedia({success:function(e){void 0!==e.meta&&void 0!==e.meta.error_type&&wdi_front.show_alert(!1,e,d),d.mediaRequestsDone=!0,0!=(e=r.checkMediaResponse(e,d))&&r.saveSelfUserData(e,d)}});else if("hashtag"==this.getInputType(e[i].username)){if(this.isJsonString(d.feed_row.feed_users))for(var t in json_feed_users=JSON.parse(d.feed_row.feed_users),json_feed_users)"#"!==json_feed_users[t].username.charAt(0)&&(user=json_feed_users[t]);d.instagram.getTagRecentMedia(this.stripHashtag(e[i].username),{feed_id:d.feed_row.id,user_id:user.id,user_name:user.username,success:function(e){if(void 0!==e.error&&"undefined"!=e.error.type||void 0!==e.meta&&1==e.meta.error)return d.dataLoaded=1,wdi_front.show_alert(!1,e,d),!1;d.mediaRequestsDone=!0,e=r.checkMediaResponse(e,d),d.dataLoaded=1,0!=e&&r.saveUserData(e,d.feed_users[i],d)}},null,d.feed_row.hashtag_top_recent,0)}else"user"==this.getInputType(e[i].username)&&d.instagram.getUserMedia({feed_id:d.feed_row.id,user_id:e[i].id,user_name:e[i].username,success:function(e){if(void 0!==e.meta&&1==typeof e.meta.error)return d.dataLoaded=1,wdi_front.show_alert(!1,e,d),!1;d.mediaRequestsDone=!0,d.dataLoaded=1,0!=(e=r.checkMediaResponse(e,d))?r.saveUserData(e,d.feed_users[i],d):wdi_front.allImagesLoaded(d)}},"",0)},wdi_front.isHashtag=function(e){return"#"===e[0]},wdi_front.saveUserData=function(e,i,d){e.user_id=i.id,e.username=i.username,"#"===e.user_id[0]&&(e.data=wdi_front.appendRequestHashtag(e.data,e.user_id)),d.usersData.push(e),d.currentResponseLength=wdi_front.getArrayContentLength(d.usersData,"data"),d.allResponseLength+=d.currentResponseLength,d.dataCount==d.usersData.length&&(d.currentResponseLength<d.feed_row.number_of_photos&&!wdi_front.userHasNoPhoto(d)?wdi_front.loadMore("initial-keep",d):(wdi_front.displayFeed(d),wdi_front.applyFilters(d),wdi_front.activeUsersCount(d)||"load_more_btn"==d.feed_row.feed_display_view&&((d=jQuery("#wdi_feed_"+d.feed_row.wdi_feed_counter)).find(".wdi_load_more").addClass("wdi_hidden"),d.find(".wdi_spinner").addClass("wdi_hidden"))))},wdi_front.saveSelfUserData=function(e,i){e.user_id="",e.username="",i.usersData.push(e),i.currentResponseLength=wdi_front.getArrayContentLength(i.usersData,"data"),i.allResponseLength+=i.currentResponseLength,i.dataCount==i.usersData.length&&(i.currentResponseLength<i.feed_row.number_of_photos&&!wdi_front.userHasNoPhoto(i)?wdi_front.loadMore("initial-keep",i):(wdi_front.displayFeed(i),wdi_front.applyFilters(i),wdi_front.activeUsersCount(i)||"load_more_btn"==i.feed_row.feed_display_view&&((i=jQuery("#wdi_feed_"+i.feed_row.wdi_feed_counter)).find(".wdi_load_more").addClass("wdi_hidden"),i.find(".wdi_spinner").addClass("wdi_hidden"))))},wdi_front.userHasNoPhoto=function(e,i){var d=0,r=e.usersData;void 0!==i&&(r=i);for(var t=0;t<r.length;t++)void 0===r[t].pagination&&(r[t].pagination=[]),"liked"===e.feed_row.liked_feed?void 0===r[t].pagination.next_max_like_id&&d++:void 0===r[t].pagination.next_max_id&&d++;return d==r.length?1:0},wdi_front.appendRequestHashtag=function(e,i){for(var d=0;d<e.length;d++)e[d].wdi_hashtag=i;return e},wdi_front.displayFeed=function(e,i){void 0===i&&(i=1);for(var d=0;d<e.usersData.length;d++)e.dataStorageList=e.usersData[d].data,e.dataStorage[d]=e.usersData[d].data;var r=e.feed_row.number_of_photos,t=e.feed_row.load_more_number,a=0,o=r,r="";"pagination"==e.feed_row.feed_display_view?(1<e.allResponseLength&&jQuery("#wdi_pagination").removeClass("wdi_hidden"),e.feed_row.number_of_photos=e.allResponseLength,"image_browser"==e.feed_row.feed_type?e.paginator=parseInt(e.feed_row.number_of_photos):e.paginator=Math.ceil(parseInt(e.feed_row.number_of_photos)/parseInt(t)),r=(o=1===i?(a=0,"image_browser"==e.feed_row.feed_type?1:t):"image_browser"==e.feed_row.feed_type?(a=i-1)+1:(a=(i-1)*t)+t,e.dataStorageList.slice(a,o))):void 0!==e.already_loaded_count?(a=parseInt(e.already_loaded_count),o=e.already_loaded_count+parseInt(t),r=e.dataStorageList.slice(a,o),e.already_loaded_count+=r.length):(r=e.dataStorageList.slice(a,o),e.already_loaded_count=r.length),e.parsedData=wdi_front.parseLighboxData(e,!0),"masonry"==e.feed_row.feed_type&&wdi_front.masonryDisplayFeedItems(r,e),"thumbnails"!=e.feed_row.feed_type&&"blog_style"!=e.feed_row.feed_type&&"image_browser"!=e.feed_row.feed_type||wdi_front.displayFeedItems(r,e),"pagination"==e.feed_row.feed_display_view&&e.currentPage<e.paginator&&jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter).find("#wdi_last_page").removeClass("wdi_disabled"),wdi_front.updateUsersImages(e)},wdi_front.updateUsersImages=function(i){jQuery("#wdi_feed_"+i.feed_row.wdi_feed_counter).find(".wdi_single_user .wdi_user_img_wrap img").each(function(){if((jQuery(this).attr("src")==wdi_url.plugin_url+"images/missing.png"||""==jQuery(this).attr("src"))&&"liked"!=i.feed_row.liked_feed)for(var e=0;e<i.usersData.length;e++)i.usersData[e].username==jQuery(this).parent().parent().find("h3").text()&&0!=i.usersData[e].data.length&&jQuery(this).attr("src",i.usersData[e].data[0].images.thumbnail.url)})},wdi_front.checkLoaded=function(e){var i=e.feed_row.wdi_feed_counter,d=jQuery("#wdi_feed_"+i);e.dataStorageList.length>e.already_loaded_count?d.find(".wdi_load_more").removeClass("wdi_hidden"):d.find(".wdi_load_more").addClass("wdi_hidden"),d.find(".wdi_spinner").addClass("wdi_hidden"),setTimeout(function(){d.find(".wdi_ajax_loading").addClass("wdi_hidden"),d.find(".wdi_page_loading").addClass("wdi_hidden"),d.find(".wdi_front_overlay").addClass("wdi_hidden")},500)},wdi_front.masonryDisplayFeedItems=function(e,i){var d=[],r=[];if(0!=jQuery("#wdi_feed_"+i.feed_row.wdi_feed_counter+" .wdi_feed_wrapper").length){jQuery("#wdi_feed_"+i.feed_row.wdi_feed_counter+" .wdi_masonry_column").each(function(){1==i.feed_row.resort_after_load_more&&(jQuery(this).html(""),i.imageIndex=0),1==i.customFilterChanged&&(jQuery(this).html(""),i.imageIndex=0),"pagination"==i.feed_row.feed_display_view?d.push(0):d.push(jQuery(this).height()),r.push(jQuery(this))}),1==i.customFilterChanged&&(i.customFilterChanged=!1);for(var t,a,o,n=0;n<e.length;n++)"object"==typeof e[n].videos&&null==e[n].videos.standard_resolution||(i.displayedData.push(e[n]),t="",void 0!==e[n].wdi_hashtag&&(t=e[n].wdi_hashtag),a="image"==e[n].type?wdi_front.getPhotoTemplate(i,t):e[n].hasOwnProperty("videos")||"video"==e[n].type?wdi_front.getVideoTemplate(i,t):wdi_front.getSliderTemplate(i,t),o=e[n],t=a(wdi_front.createObject(o,i)),a=wdi_front.array_min(d),o=wdi_front.getImageResolution(e[n]),r[a.index].html(r[a.index].html()+t),d[a.index]+=r[a.index].width()*o,i.imageIndex++,"pagination"==i.feed_row.feed_display_view&&((n+1)%i.feed_row.pagination_per_page_number==0?i.resIndex+=i.freeSpaces+1:i.resIndex++));i.wdi_loadedImages=0;var s=!1;i.wdi_load_count=n;var _=i.feed_row.wdi_feed_counter;jQuery("#wdi_feed_"+_+" .wdi_img").on("load",function(){i.wdi_loadedImages++,!1===s&&(wdi_responsive.columnControl(i,1),s=!0)});wdi_front.checkLoaded(i),1==i.paginatorNextFlag&&wdi_front.updatePagination(i,"next"),i.infiniteScrollFlag=!1}},wdi_front.getImageResolution=function(e){var i;return e="image"===e.type?(i=e.images.standard_resolution.height,e.images.standard_resolution.width):"video"===e.type?(i=e.videos.standard_resolution.height,e.videos.standard_resolution.width):(i=(e.carousel_media[0].images||e.carousel_media[0].videos).standard_resolution.height,(e.carousel_media[0].images||e.carousel_media[0].videos).standard_resolution.width),i/e},wdi_front.getDataLength=function(e,i){var d=0;if(void 0===i)for(var r=0;r<e.dataStorage.length;r++)d+=e.dataStorage[r].length;else for(r=0;r<i.length;r++)d+=i[r].length;return d},wdi_front.getArrayContentLength=function(e,i){for(var d=0,r=0;r<e.length;r++)"finished"!=e[r].finished&&void 0===e[r].error&&(d+=e[r][i].length);return d},wdi_front.displayFeedItems=function(e,i){if(0!=jQuery("#wdi_feed_"+i.feed_row.wdi_feed_counter+" .wdi_feed_wrapper").length){for(var d,r,t,a=i.feed_row.wdi_feed_counter,o=jQuery("#wdi_feed_"+a+" .wdi_feed_wrapper"),n=0;n<e.length;n++){if(void 0===e[n])return;"object"==typeof e[n].videos&&null==e[n].videos.standard_resolution||(t="",void 0!==e[n].wdi_hashtag&&(t=e[n].wdi_hashtag),d="image"==e[n].type?wdi_front.getPhotoTemplate(i,t):e[n].hasOwnProperty("videos")?wdi_front.getVideoTemplate(i,t):wdi_front.getSliderTemplate(i,t),r=e[n],t="",void 0!==(r=wdi_front.createObject(r,i))&&(t=d(r)),o.html(o.html()+t),i.imageIndex++,"pagination"==i.feed_row.feed_display_view&&((n+1)%i.feed_row.pagination_per_page_number==0?i.resIndex+=i.freeSpaces+1:i.resIndex++))}wdi_front.checkLoaded(i)}},wdi_front.checkFeedFinished=function(e){for(var i=0;i<e.usersData.length;i++)if(void 0===e.usersData[i].finished)return!1;return!0},wdi_front.createObject=function(e,i){var d=null!=e.caption?e.caption.text:" ";switch(e.type){case"image":var r=e.images[i.feedImageResolution].url,t=void 0,a=e.hasOwnProperty("thumbnail")?e.thumbnail:wdi_url.plugin_url+"images/missing.png";break;case"video":r=void 0,t=e.hasOwnProperty("videos")?e.videos[i.feedVideoResolution].url:wdi_url.plugin_url+"images/video_missing.png",a=e.hasOwnProperty("thumbnail")?e.thumbnail:wdi_url.plugin_url+"images/video_missing.png";break;case"carousel":if(0===e.carousel_media.length)r=wdi_url.plugin_url+"images/missing.png",t=void 0,a=wdi_url.plugin_url+"images/missing.png";else switch(e.carousel_media[0].type){case"image":r=e.carousel_media[0].images[i.feedImageResolution].url,t=void 0,a=e.hasOwnProperty("thumbnail")?e.thumbnail:wdi_url.plugin_url+"images/missing.png";break;case"video":r=void 0,t=e.carousel_media[0].videos[i.feedVideoResolution].url,a=e.hasOwnProperty("thumbnail")?e.thumbnail:wdi_url.plugin_url+"images/video_missing.png";break;default:r=wdi_url.plugin_url+"images/missing.png",t=void 0,a=wdi_url.plugin_url+"images/missing.png"}break;default:r=wdi_url.plugin_url+"images/missing.png",t=void 0,a=wdi_url.plugin_url+"images/missing.png"}var o,n=i.imageIndex,s="square";(_="image"===e.type?(o=e.images.standard_resolution.height,e.images.standard_resolution.width):"video"===e.type?(o=e.videos.standard_resolution.height,e.videos.standard_resolution.width):(o=(e.carousel_media[0].images||e.carousel_media[0].videos).standard_resolution.height,(e.carousel_media[0].images||e.carousel_media[0].videos).standard_resolution.width))<o?s="portrait":o<_&&(s="landscape");var _=e.user.username;return""===_&&(_="no_user"),{id:e.id,thumb_url:a,caption:wdi_front.escape_tags(d),image_url:r,likes:void 0!==e.likes.count?e.likes.count:e.likes,comments:void 0!==e.comments.count?e.comments.count:e.comments,wdi_index:n,wdi_res_index:i.resIndex,wdi_media_user:_,link:e.link,video_url:t,wdi_username:_,wdi_shape:s}},wdi_front.getPhotoTemplate=function(e,i){var d="",r="",t="",a="tenweb-i-arrows-out",o="";"blog_style"!=e.feed_row.feed_type&&"image_browser"!=e.feed_row.feed_type||(a=""),"1"==e.feed_row.show_username_on_thumb&&e.data.length&&""!==e.data[0].user.username&&(o='<span class="wdi_media_user">@<%= wdi_username%></span>'),1==e.feed_row.show_full_description&&"masonry"==e.feed_row.feed_type&&(d+=" wdi_full_caption");var n="";switch("blog_style"!==e.feed_row.feed_type&&(n="masonry"==e.feed_row.feed_type?"wdi_responsive.showMasonryCaption(jQuery(this),"+e.feed_row.wdi_feed_counter+");":"wdi_responsive.showCaption(jQuery(this),"+e.feed_row.wdi_feed_counter+");"),e.feed_row.feed_item_onclick){case"lightbox":r="onclick=wdi_feed_"+e.feed_row.wdi_feed_counter+".galleryBox('<%=id%>')";break;case"instagram":r="onclick=\"window.open ('<%= link%>','_blank')\"",t="wdi_hover_off",a="";break;case"custom_redirect":r="onclick=\"window.open ('"+e.feed_row.redirect_url+"','_self')\"",t="wdi_hover_off",a="";break;case"none":t="wdi_cursor_off wdi_hover_off",a=r=""}var s='<div class="wdi_feed_item '+d+'" wdi_index=<%= wdi_index%> wdi_res_index=<%= wdi_res_index%> wdi_media_user=<%= wdi_media_user%> wdi_type="image" id="wdi_'+e.feed_row.wdi_feed_counter+'_<%=id%>"><div class="wdi_photo_wrap"><div class="wdi_photo_wrap_inner"><div class="wdi_photo_img <%= wdi_shape == \'square\' ? \'wdi_shape_square\' : (wdi_shape == \'portrait\' ? \'wdi_shape_portrait\' : (wdi_shape == \'landscape\' ? \'wdi_shape_landscape\' : \'wdi_shape_square\') ) %>"><img class="wdi_img" src="<%=thumb_url%>" alt="feed_image" onerror="wdi_front.brokenImageHandler(this);"><div class="wdi_photo_overlay '+t+'" >'+o+'<div class="wdi_thumb_icon" '+r+' style="display:table;width:100%;height:100%;"><div style="display:table-cell;vertical-align:middle;text-align:center;color:white;"><i class="tenweb-i '+a+'"></i></div></div></div></div></div></div>',d=e.imageIndex;return"1"!==e.feed_row.show_likes&&"1"!==e.feed_row.show_comments&&"1"!==e.feed_row.show_description||(s+='<div class="wdi_photo_meta">',o=void 0!==e.dataStorageList[d]&&void 0!==e.dataStorageList[d].likes&&void 0!==e.dataStorageList[d].likes.count?e.dataStorageList[d].likes.count:0,"1"===e.feed_row.show_likes&&0!==o&&(s+='<div class="wdi_thumb_likes"><i class="tenweb-i tenweb-i-heart-o"> <%= likes%></i></div>'),d=void 0!==e.dataStorageList[d]&&void 0!==e.dataStorageList[d].comments&&void 0!==e.dataStorageList[d].comments.count?e.dataStorageList[d].comments.count:0,"1"===e.feed_row.show_comments&&0!==d&&(s+='<div class="wdi_thumb_comments"><i class="tenweb-i tenweb-i-comment-square"> <%= comments%></i></div>'),s+='<div class="wdi_clear"></div>',"1"===e.feed_row.show_description&&(s+='<div class="wdi_photo_title" onclick='+n+" ><%=caption%></div>"),s+="</div>"),s+="</div>",_.template(s)},wdi_front.getSliderTemplate=function(e,i){var d="",r="",t="",a="tenweb-i-clone",o="";"blog_style"!=e.feed_row.feed_type&&"image_browser"!=e.feed_row.feed_type||(a=""),"1"==e.feed_row.show_username_on_thumb&&e.data.length&&""!==e.data[0].user.username&&(o='<span class="wdi_media_user">@<%= wdi_username%></span>'),1==e.feed_row.show_full_description&&"masonry"==e.feed_row.feed_type&&(d+=" wdi_full_caption");var n="";switch("blog_style"!==e.feed_row.feed_type&&(n="masonry"==e.feed_row.feed_type?"wdi_responsive.showMasonryCaption(jQuery(this),"+e.feed_row.wdi_feed_counter+");":"wdi_responsive.showCaption(jQuery(this),"+e.feed_row.wdi_feed_counter+");"),e.feed_row.feed_item_onclick){case"lightbox":r="onclick=wdi_feed_"+e.feed_row.wdi_feed_counter+".galleryBox('<%=id%>')";break;case"instagram":r="onclick=\"window.open ('<%= link%>','_blank')\"",t="wdi_hover_off",a="tenweb-i-clone";break;case"custom_redirect":r="onclick=\"window.open ('"+e.feed_row.redirect_url+"','_self')\"",t="wdi_hover_off",a="";break;case"none":t="wdi_cursor_off wdi_hover_off",a=r=""}var s='<div class="wdi_feed_item '+d+'" wdi_index=<%= wdi_index%> wdi_res_index=<%= wdi_res_index%> wdi_media_user=<%= wdi_media_user%> wdi_type="slideshow" id="wdi_'+e.feed_row.wdi_feed_counter+'_<%=id%>"><div class="wdi_photo_wrap"><div class="wdi_photo_wrap_inner"><div class="wdi_photo_img <%= wdi_shape == \'square\' ? \'wdi_shape_square\' : (wdi_shape == \'portrait\' ? \'wdi_shape_portrait\' : (wdi_shape == \'landscape\' ? \'wdi_shape_landscape\' : \'wdi_shape_square\') ) %>"><img class="wdi_img" src="<%=thumb_url%>" alt="feed_image" onerror="wdi_front.brokenImageHandler(this);"><div class="wdi_photo_overlay '+t+'" >'+o+'<div class="wdi_thumb_icon" '+r+' style="display:table;width:100%;height:100%;"><div style="display:table-cell;vertical-align:middle;text-align:center;color:white;"><i class="tenweb-i '+a+'"></i></div></div></div></div></div></div>',d=e.imageIndex;return"1"!==e.feed_row.show_likes&&"1"!==e.feed_row.show_comments&&"1"!==e.feed_row.show_description||(s+='<div class="wdi_photo_meta">',o=void 0!==e.dataStorageList[d]&&void 0!==e.dataStorageList[d].likes&&void 0!==e.dataStorageList[d].likes.count?e.dataStorageList[d].likes.count:e.dataStorageList[d].likes,"1"===e.feed_row.show_likes&&0!==o&&(s+='<div class="wdi_thumb_likes"><i class="tenweb-i tenweb-i-heart-o"> <%= likes%></i></div>'),d=void 0!==e.dataStorageList[d].comments.count?e.dataStorageList[d].comments.count:e.dataStorageList[d].comments,"1"===e.feed_row.show_comments&&0!==d&&(s+='<div class="wdi_thumb_comments"><i class="tenweb-i tenweb-i-comment-square"> <%= comments%></i></div>'),s+='<div class="wdi_clear"></div>',"1"===e.feed_row.show_description&&(s+='<div class="wdi_photo_title" onclick='+n+" ><%=caption%></div>"),s+="</div>"),s+="</div>",_.template(s)},wdi_front.replaceToVideo=function(e,i,d){overlayHtml="<video style='width:auto !important; height:auto !important; max-width:100% !important; max-height:100% !important; margin:0 !important;' controls=''><source src='"+e+"' type='video/mp4'>Your browser does not support the video tag. </video>",jQuery("#wdi_feed_"+d+' [wdi_index="'+i+'"] .wdi_photo_wrap_inner').html(overlayHtml),jQuery("#wdi_feed_"+d+' [wdi_index="'+i+'"] .wdi_photo_wrap_inner video').get(0).play()},wdi_front.getVideoTemplate=function(e,i){var d="",r="tenweb-i-play",t="",a="",o="";"1"==e.feed_row.show_username_on_thumb&&e.data.length&&""!==e.data[0].user.username&&(o='<span class="wdi_media_user">@<%= wdi_username%></span>'),1==e.feed_row.show_full_description&&"masonry"==e.feed_row.feed_type&&(d+=" wdi_full_caption");var n="";switch("blog_style"!==e.feed_row.feed_type&&(n="masonry"==e.feed_row.feed_type?"wdi_responsive.showMasonryCaption(jQuery(this),"+e.feed_row.wdi_feed_counter+");":"wdi_responsive.showCaption(jQuery(this),"+e.feed_row.wdi_feed_counter+");"),e.feed_row.feed_item_onclick){case"lightbox":t="onclick=wdi_feed_"+e.feed_row.wdi_feed_counter+".galleryBox('<%=id%>')";break;case"instagram":t="onclick=\"window.open ('<%= link%>','_blank')\"",a="wdi_hover_off",r="tenweb-i-play";break;case"custom_redirect":t="onclick=\"window.open ('"+e.feed_row.redirect_url+"','_self')\"",a="wdi_hover_off",r="";break;case"none":a="wdi_cursor_off wdi_hover_off",r="","blog_style"!=e.feed_row.feed_type&&"image_browser"!=e.feed_row.feed_type||(t="onclick=wdi_front.replaceToVideo('<%= video_url%>','<%= wdi_index%>',"+e.feed_row.wdi_feed_counter+")",a="",r="tenweb-i-play")}var s='<div class="wdi_feed_item '+d+'" wdi_index=<%= wdi_index%> wdi_res_index=<%= wdi_res_index%> wdi_media_user=<%= wdi_media_user%> wdi_type="image" id="wdi_'+e.feed_row.wdi_feed_counter+'_<%=id%>"><div class="wdi_photo_wrap"><div class="wdi_photo_wrap_inner"><div class="wdi_photo_img <%= wdi_shape == \'square\' ? \'wdi_shape_square\' : (wdi_shape == \'portrait\' ? \'wdi_shape_portrait\' : (wdi_shape == \'landscape\' ? \'wdi_shape_landscape\' : \'wdi_shape_square\') ) %>"><img class="wdi_img" src="<%=thumb_url%>" alt="feed_image" onerror="wdi_front.brokenImageHandler(this);"><div class="wdi_photo_overlay '+a+'" '+t+">"+o+'<div class="wdi_thumb_icon" style="display:table;width:100%;height:100%;"><div style="display:table-cell;vertical-align:middle;text-align:center;color:white;"><i class="tenweb-i '+r+'"></i></div></div></div></div></div></div>',d=e.imageIndex;return"1"!==e.feed_row.show_likes&&"1"!==e.feed_row.show_comments&&"1"!==e.feed_row.show_description||(s+='<div class="wdi_photo_meta">',o=void 0!==e.dataStorageList[d]&&void 0!==e.dataStorageList[d].likes&&void 0!==e.dataStorageList[d].likes.count?e.dataStorageList[d].likes.count:e.dataStorageList[d].likes,"1"===e.feed_row.show_likes&&0!==o&&(s+='<div class="wdi_thumb_likes"><i class="tenweb-i tenweb-i-heart-o"> <%= likes%></i></div>'),d=void 0!==e.dataStorageList[d].comments.count?e.dataStorageList[d].comments.count:e.dataStorageList[d].comments,"1"===e.feed_row.show_comments&&0!==d&&(s+='<div class="wdi_thumb_comments"><i class="tenweb-i tenweb-i-comment-square"> <%= comments%></i></div>'),s+='<div class="wdi_clear"></div>',"1"===e.feed_row.show_description&&(s+='<div class="wdi_photo_title" onclick='+n+" ><%=caption%></div>"),s+="</div>"),s+="</div>",_.template(s)},wdi_front.bindEvents=function(e){0!=jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_feed_wrapper").length&&("load_more_btn"==e.feed_row.feed_display_view&&jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_load_more_container").on(wdi_front.clickOrTouch,function(){jQuery(document).find("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_load_more").addClass("wdi_hidden"),jQuery(document).find("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_spinner").removeClass("wdi_hidden"),setTimeout(function(){wdi_front.loadMore(jQuery(this).find(".wdi_load_more_wrap"),e)},1e3)}),"pagination"==e.feed_row.feed_display_view&&(jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" #wdi_next").on(wdi_front.clickOrTouch,function(){parseInt(jQuery("#wdi_current_page").text())+1>e.paginator||(e.currentPage=parseInt(jQuery("#wdi_current_page").text())+1,wdi_front.changePage(jQuery(this),e))}),jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" #wdi_prev").on(wdi_front.clickOrTouch,function(){parseInt(jQuery("#wdi_current_page").text())-1<=0||(e.currentPage=parseInt(jQuery("#wdi_current_page").text())-1,wdi_front.changePage(jQuery(this),e))}),jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" #wdi_last_page").on(wdi_front.clickOrTouch,function(){e.currentPage=e.paginator,wdi_front.changePage(jQuery(this),e)}),jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" #wdi_first_page").on(wdi_front.clickOrTouch,function(){e.currentPage=1,wdi_front.changePage(jQuery(this),e)}),e.paginatorNextFlag=!1),"infinite_scroll"==e.feed_row.feed_display_view&&(jQuery(window).on("scroll",function(){wdi_front.infiniteScroll(e)}),e.infiniteScrollFlag=!1))},wdi_front.infiniteScroll=function(e){jQuery(window).scrollTop()+jQuery(window).height()-100>=jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" #wdi_infinite_scroll").offset().top&&(e.dataStorageList.length>e.already_loaded_count||void 0===e.already_loaded_count?(e.infiniteScrollFlag=!0,wdi_front.loadMore(jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" #wdi_infinite_scroll"),e)):wdi_front.allImagesLoaded(e))},wdi_front.changePage=function(e,i){new_page_number=i.currentPage,1<new_page_number?jQuery("#wdi_first_page").removeClass("wdi_disabled"):1===new_page_number&&jQuery("#wdi_first_page").addClass("wdi_disabled"),new_page_number==parseInt(i.paginator)?jQuery("#wdi_last_page").addClass("wdi_disabled"):new_page_number<parseInt(i.paginator)&&jQuery("#wdi_last_page").removeClass("wdi_disabled"),("masonry"==i.feed_row.feed_type?e.parent().parent().parent().find(".wdi_feed_wrapper .wdi_masonry_column"):e.parent().parent().parent().find(".wdi_feed_wrapper")).empty(),e.parent().find("#wdi_current_page").empty().text(new_page_number);e=e.closest(".wdi_feed_container");e.parents(".wdi_feed_main_container").find(".wdi_front_overlay").removeClass("wdi_hidden"),e.parents(".wdi_feed_main_container").find(".wdi_page_loading").removeClass("wdi_hidden"),wdi_front.displayFeed(i,new_page_number)},wdi_front.updatePagination=function(e,i,d){var r="#wdi_feed_"+e.feed_row.wdi_feed_counter;switch(jQuery(r+' [wdi_page="'+e.currentPage+'"]').each(function(){jQuery(this).removeClass("wdi_hidden")}),i){case"next":var d=e.currentPage-1;jQuery(r+" .wdi_feed_wrapper").height(jQuery(".wdi_feed_wrapper").height()),jQuery(r+' [wdi_page="'+d+'"]').each(function(){jQuery(this).addClass("wdi_hidden")});break;case"prev":d=e.currentPage+1;jQuery(r+" .wdi_feed_wrapper").height(jQuery(".wdi_feed_wrapper").height()),jQuery(r+' [wdi_page="'+d+'"]').each(function(){jQuery(this).addClass("wdi_hidden")});break;case"custom":(d=d)!=e.currentPage&&(jQuery(r+" .wdi_feed_wrapper").height(jQuery(".wdi_feed_wrapper").height()),jQuery(r+' [wdi_page="'+d+'"]').each(function(){jQuery(this).addClass("wdi_hidden")}))}e.paginatorNextFlag=!1,jQuery(r+" .wdi_feed_wrapper").css("height","auto"),jQuery(r+" #wdi_current_page").text(e.currentPage)},wdi_front.loadMore=function(e,i){var d;if(""!=e&&void 0!==e&&"initial"!=e&&"initial-keep"!=e&&(d=window[e.parent().parent().parent().parent().attr("id")]),void 0!==i&&(d=i),wdi_front.ajaxLoader(d),this.isJsonString(d.feed_row.feed_users))for(var r in json_feed_users=JSON.parse(d.feed_row.feed_users),json_feed_users)iuser=json_feed_users[r],"#"!==json_feed_users[r].username.charAt(0)&&(iuser=json_feed_users[r]);"masonry"===d.feed_row.feed_type&&"pagination"==d.feed_row.feed_display_view&&jQuery("#wdi_feed_"+wdi_front.feed_counter+" .wdi_full_caption").each(function(){jQuery(this).find(".wdi_photo_title").trigger(wdi_front.clickOrTouch)}),d.loadMoreDataCount=d.feed_users.length,wdi_front.displayFeed(d)},wdi_front.loadMoreRequest=function(e,i,d,r){d.mediaRequestsDone&&""!=i&&d.usersData},wdi_front.checkForLoadMoreDone=function(e,i){var d,r=e.feed_row.load_more_number,t=e.feed_row.number_of_photos;0==e.loadMoreDataCount&&(e.temproraryUsersData=wdi_front.mergeData(e.temproraryUsersData,e.usersData),d=wdi_front.getArrayContentLength(e.temproraryUsersData,"data"),"initial-keep"==i&&(i="initial"),"initial"==i?d<t&&!wdi_front.userHasNoPhoto(e,e.temproraryUsersData)&&e.instagramRequestCounter<=e.maxConditionalFiltersRequestCount?wdi_front.loadMore("initial",e):(e.usersData=e.temproraryUsersData,wdi_front.displayFeed(e),wdi_front.applyFilters(e),e.temproraryUsersData=[]):d<r&&!wdi_front.userHasNoPhoto(e,e.temproraryUsersData)&&e.instagramRequestCounter<=e.maxConditionalFiltersRequestCount?wdi_front.loadMore(void 0,e):(e.usersData=e.temproraryUsersData,wdi_front.activeUsersCount(e)&&(wdi_front.displayFeed(e,r),wdi_front.applyFilters(e),e.temproraryUsersData=[])))},wdi_front.allDataHasFinished=function(e){for(var i=0,d=0;d<e.dataStorageRaw.length;d++)""==e.usersData[d].pagination.next_url&&(i++,e.usersData[d].finished="finished");return i==e.dataStorageRaw.length&&(jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_load_more").remove(),!0)},wdi_front.mergeData=function(e,i){for(var d=0;d<i.length;d++)void 0!==e[d]?"finished"!=i[d].finished&&(void 0===e[d].pagination.next_max_id&&void 0===e[d].pagination.next_max_like_id||(e[d].data=e[d].data.concat(i[d].data),e[d].pagination=i[d].pagination,e[d].user_id=i[d].user_id,e[d].username=i[d].username,e[d].meta=i[d].meta)):e.push(i[d]);return e},wdi_front.brokenImageHandler=function(e){return!0},wdi_front.ajaxLoader=function(e){var i,d=e.feed_row.wdi_feed_counter,d=jQuery(document).find("#wdi_feed_"+d);return"load_more_btn"==e.feed_row.feed_display_view&&(d.find(".wdi_load_more").addClass("wdi_hidden"),d.find(".wdi_spinner").removeClass("wdi_hidden")),"infinite_scroll"==e.feed_row.feed_display_view&&(0==d.find(".wdi_ajax_loading").length?(i=jQuery('<div class="wdi_ajax_loading"><div><div><img class="wdi_load_more_spinner" src="'+wdi_url.plugin_url+'images/ajax_loader.png"></div></div></div>'),d.find(".wdi_feed_container").append(i)):i=d.find(".wdi_ajax_loading"),i.removeClass("wdi_hidden")),1},wdi_front.allImagesLoaded=function(e){wdi_front.getDataLength(e);e.mediaRequestsDone||jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_feed_wrapper").remove("wdi_nomedia"),0==e.allResponseLength&&1===e.dataLoaded&&jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_feed_wrapper").append("<p class='wdi_nomedia'>"+wdi_front_messages.feed_nomedia+"</p>");var i=e.feed_row.wdi_feed_counter,i=jQuery("#wdi_feed_"+i);"load_more_btn"==e.feed_row.feed_display_view&&(parseInt(e.allResponseLength)>parseInt(e.feed_row.number_of_photos)&&i.find(".wdi_load_more").removeClass("wdi_hidden"),i.find(".wdi_spinner").addClass("wdi_hidden")),"infinite_scroll"==e.feed_row.feed_display_view&&jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+" .wdi_ajax_loading").addClass("wdi_hidden")},wdi_front.show=function(e,i){var d,r,t=i.feed_row.wdi_feed_counter,a=jQuery("#wdi_feed_"+t+" .wdi_feed_container");"header"===e&&(d={feed_thumb:i.feed_row.feed_thumb,feed_name:i.feed_row.feed_name},r=wdi_front.getHeaderTemplate()(d),d=a.find(".wdi_feed_header").html(),a.find(".wdi_feed_header").html(d+r))},wdi_front.getUserTemplate=function(e,i){var d=e.dataCount,r="#"===i[0]?"//instagram.com/explore/tags/"+i.substr(1,i.length):"//instagram.com/"+i,t="onclick='"+('window.open("'+r+'","_blank")')+"'",r='<div class="wdi_single_user" user_index="<%=user_index%>"><div class="wdi_header_user_text <%=hashtagClass%>"><div class="wdi_user_img_wrap"><img onerror="wdi_front.brokenImageHandler(this);" src="<%= user_img_url%>">';return 1<d&&(r+='<div title="'+wdi_front_messages.filter_title+'" class="wdi_filter_overlay"><div class="wdi_filter_icon"><span onclick="wdi_front.addFilter(<%=user_index%>,<%=feed_counter%>);" class="tenweb-i tenweb-i-filter"></span></div></div>'),r+="</div>",r+="<h3 "+t+"><%= user_name%></h3>","#"!==i[0]?("1"==e.feed_row.follow_on_instagram_btn&&(r+='<div class="wdi_user_controls"><div class="wdi_follow_btn" onclick="window.open(\'//instagram.com/<%= user_name%>\',\'_blank\')"><span> '+wdi_front_messages.follow+"</span></div></div>"),r+='<div class="wdi_media_info"><p class="wdi_posts"><span class="tenweb-i tenweb-i-camera-retro"></span><%= counts.media%></p><p class="wdi_followers"><span class="tenweb-i tenweb-i-user"></span><%= counts.followed_by%></p></div>'):r+='<div class="wdi_user_controls"></div><div class="wdi_media_info"><p class="wdi_posts"><span class="tenweb-i tenweb-i-camera-retro"></span><%= counts.media%></p><p class="wdi_followers"><span></span></p></div>',r+='<div class="wdi_clear"></div>',1==d&&"#"!==i[0]&&"1"==e.feed_row.display_user_info&&(r+='<div class="wdi_bio"><%= bio%></div>',r+='<div class="wdi_website"><a target="_blank" href="<%= website_url%>" ><%= website%></a></div>'),r+="</div></div>",_.template(r)},wdi_front.getHeaderTemplate=function(){return _.template('<div class="wdi_header_wrapper"><div class="wdi_header_img_wrap"><img src="<%=feed_thumb%>"></div><div class="wdi_header_text"><%=feed_name%></div><div class="wdi_clear"></div>')},wdi_front.addFilter=function(e,i){var d=window["wdi_feed_"+i],i=d.dataCount;if(!(i<2)&&0==d.nowLoadingImages){i=jQuery("#wdi_feed_"+d.feed_row.wdi_feed_counter+'_users [user_index="'+e+'"]');i.find(".wdi_filter_overlay").toggleClass("wdi_filter_active_bg"),i.find(".wdi_header_user_text h3").toggleClass("wdi_filter_active_col"),i.find(".wdi_media_info").toggleClass("wdi_filter_active_col"),i.find(".wdi_follow_btn").toggleClass("wdi_filter_active_col"),d.customFilterChanged=!0,0==d.userSortFlags[e].flag?d.userSortFlags[e].flag=!0:d.userSortFlags[e].flag=!1;for(var r=0,t=0;t<d.userSortFlags.length;t++)1==d.userSortFlags[t].flag&&r++;"pagination"==d.feed_row.feed_display_view&&(d.resIndex=0),0!=r?wdi_front.filterData(d):d.customFilteredData=d.dataStorageList,wdi_front.displayFeed(d),"pagination"==d.feed_row.feed_display_view&&(d.paginator=Math.ceil(d.imageIndex/parseInt(d.feed_row.pagination_per_page_number)),d.currentPage=d.paginator,wdi_front.updatePagination(d,"custom",1),jQuery("#wdi_first_page").removeClass("wdi_disabled"),jQuery("#wdi_last_page").addClass("wdi_disabled"))}},wdi_front.filterData=function(e){var i=e.userSortFlags;e.customFilteredData=[];for(var d=0;d<e.dataStorageList.length;d++)for(var r=0;r<i.length;r++)(void 0!==e.dataStorageList[d].user.id&&e.dataStorageList[d].user.id==i[r].id||e.dataStorageList[d].wdi_hashtag==i[r].name)&&1==i[r].flag&&e.customFilteredData.push(e.dataStorageList[d])},wdi_front.applyFilters=function(e){for(var i=0;i<e.userSortFlags.length;i++)1==e.userSortFlags[i].flag&&(jQuery("#wdi_feed_"+e.feed_row.wdi_feed_counter+'[user_index="'+i+'"]'),wdi_front.addFilter(i,e.feed_row.wdi_feed_counter),wdi_front.addFilter(i,e.feed_row.wdi_feed_counter))},wdi_front.getImgCount=function(e){for(var i=e.dataStorage,d=0,r=0;r<i.length;r++)d+=i[r].length;return d},wdi_front.parseLighboxData=function(e,i){for(var d,r,t,a,o=e.dataStorage,n=[],s=[],_=0;_<o.length;_++)for(var w=0;w<o[_].length;w++)n.push(o[_][w]);for(_=0;_<n.length;_++)void 0!==n[_]&&(r=void 0!==n[_]&&void 0!==n[_].media_url?n[_].media_url:wdi_url.plugin_url+"images/video_missing.png",r=n[_].thumbnail,void 0!==n[_]&&void 0===n[_].media_url&&("carousel"!==n[_].type||(void 0!==(a=n[_].carousel_media[0])&&void 0!==a.images||void 0!==a&&void 0!==a.videos)&&(r=a.thumbnail)),a=void(t=0)!==n[_].comments.count?n[_].comments.count:n[_].comments,void 0!==n[_]&&void 0!==a&&(t=a),d={alt:"",avg_rating:"",comment_count:t,date:wdi_front.convertUnixDate(n[_].created_time),description:wdi_front.getDescription(void 0!==n[_].caption&&null!==n[_].caption?wdi_front.escape_tags(n[_].caption.text):""),filename:wdi_front.getFileName(n[_]),filetype:wdi_front.getFileType(n[_]),hit_count:"0",id:n[_].id,image_url:n[_].link,number:0,rate:"",rate_count:"0",username:void 0!==n[_].user?n[_].user.username:"",profile_picture:void 0!==n[_].user?n[_].user.profile_picture:"",thumb_url:r,comments_data:void 0!==n[_].comments?n[_].comments.data:"",images:n[_].images||n[_].videos,carousel_media:void 0!==n[_].carousel_media?n[_].carousel_media:null},s.push(d));return s},wdi_front.convertUnixDate=function(e){var i=new Date(e).getTime()/1e3,e=new Date(0);e.setUTCSeconds(i);i=e.getFullYear()+"-"+(e.getMonth()+1)+"-"+e.getDate();return i+=" "+e.getHours()+":"+e.getMinutes()},wdi_front.getDescription=function(e){return e=e.replace(/\r?\n|\r/g," ")},wdi_front.getFileName=function(e){if(void 0!==e){var i=e.link;if("video"===e.type&&e.hasOwnProperty("videos")&&null!=e.videos.standard_resolution)return e.videos.standard_resolution.url;if(void 0===i)return"";i=i.split("/");return i[i.length-2]}},wdi_front.getFileType=function(e){return"video"==e.type&&e.hasOwnProperty("videos")?"EMBED_OEMBED_INSTAGRAM_VIDEO":"carousel"==e.type&&e.hasOwnProperty("carousel_media")?"EMBED_OEMBED_INSTAGRAM_CAROUSEL":"EMBED_OEMBED_INSTAGRAM_IMAGE"},wdi_front.array_max=function(e){for(var i=e[0],d=0,r=1;r<e.length;r++)i<e[r]&&(i=e[r],d=r);return{value:i,index:d}},wdi_front.array_min=function(e){for(var i=e[0],d=0,r=1;r<e.length;r++)i>e[r]&&(i=e[r],d=r);return{value:i,index:d}},wdi_front.activeUsersCount=function(e){for(var i=0,d=0;d<e.usersData.length;d++)"finished"!=e.usersData[d].finished&&i++;return i},wdi_front.checkMediaResponse=function(e,i){return""==e||void 0===e||null==e||void 0!==e.error?(errorMessage=wdi_front_messages.connection_error,wdi_front.show_alert(errorMessage,e,i),!1):""!=e&&void 0!==e&&null!=e&&void 0!==e.meta&&200!=e.meta.code?(errorMessage=e.meta.error_message,wdi_front.show_alert(errorMessage,e,i),!1):e},wdi_front.stripHashtag=function(e){return"#"!==e[0]?e:e.substr(1,e.length)},wdi_front.getInputType=function(e){switch(e[0]){case"#":return"hashtag";case"%":return"location";default:return"user"}},wdi_front.regexpTestCaption=function(e,i){var d=!1,r=!1,t=i.replace(/[-[\]{}()*+?.,\\^$|]/g,"\\$&"),i=new RegExp("(?:^|\\s)"+t+"(?:^|\\s)"),a=new RegExp("(?:^|\\s)"+t,"g");for(null!=i.exec(e)&&(d=!0);null!=(match=a.exec(e));)r=!0;return 1==d||1==r},wdi_front.replaceNewLines=function(e){var i,d="vUkCJvN2ps3t",r=[];for(e=e.replace(/\r?\n|\r/g,d),i=new RegExp(d,"g");null!=(match=i.exec(e));)r.push(match.index);for(var t=e.split(d),a=0,o=0;o<t.length;o++)""==t[o]?a++:a=0,0<a&&(t.splice(o,1),a--,o--);return e=t.join(" ")},wdi_front.isEmptyObject=function(e){for(var i in e)if(e.hasOwnProperty(i))return!1;return!0},wdi_front.isEmpty=function(e){return!e||0===e.length};var WDIFeed=function(e){this.data=e.data,this.dataCount=e.dataCount,this.feed_row=e.feed_row,this.usersData=e.usersData,(_this=this).set_images_loading_flag=function(e){window.addEventListener("load",function(){e.nowLoadingImages=!1})},this.set_images_loading_flag(_this)};function wdi_extractHostname(e){return void 0===e||""===e?"":e.replace(/(^\w+:|^)\/\//,"")}WDIFeed.prototype.mediaExists=function(e,i){for(var d=0;d<i.length;d++)if(e.id==i[d].id)return!0;return!1},WDIFeed.prototype.getIdFromUrl=function(e){for(var i=e.split("/"),d=!1,r=0;r<i.length;r++)if("p"==i[r]&&void 0!==i[r+1]){d=i[r+1];break}return d},WDIFeed.prototype.avoidDuplicateMedia=function(e){var i=e.data,d=[];void 0===i&&(i=[]);for(var r=0;r<i.length;r++)this.mediaExists(i[r],this.dataStorageList)||this.mediaExists(i[r],d)||this.mediaExists(i[r],this.conditionalFilterBuffer)||d.push(i[r]);return this.conditionalFilterBuffer=this.conditionalFilterBuffer.concat(d),{data:d,meta:e.meta,pagination:e.pagination}},WDIFeed.prototype.storeRawData=function(e,i){var r=this;if("object"==typeof this[i]&&"number"==typeof this[i].length)for(var d=0;d<e.length;d++){var t="";wdi_front.isHashtag(e[d].user_id)?void 0!==e[d].pagination.cursors&&(t=e[d].pagination.cursors.after):"liked"==r.feed_row.liked_feed?void 0===(t=e[d].pagination.next_max_like_id)&&(t=""):(null==e[d].pagination&&(e[d].pagination=[]),void 0===(t=e[d].pagination.next_max_id)&&(t="")),void 0===this[i][d]?this[i].push({data:e[d].data,index:0,locked:!1,hash_id:t,usersDataFinished:!1,userId:e[d].user_id,length:function(){return this.data.length-this.index},getData:function(e){var i=this.data.slice(this.index,this.index+e);if(this.index+=Math.min(e,this.length()),this.index==this.data.length&&1==this.locked&&0==this.usersDataFinished)for(var d=0;d<r.usersData.length;d++)if(r.usersData[d].user_id==this.userId){this.usersDataFinished=!0;break}return i}}):0==this[i][d].locked&&(t!=this[i][d].hash_id?(this[i][d].data=this[i][d].data.concat(e[d].data),this[i][d].hash_id=t):this[i][d].locked=!0)}},wdi_front.updateUsersIfNecessary=function(o){for(var n=o.feed_users,e=!1,i=0;i<n.length;i++)"#"!=n[i].username.substr(0,1)?""!=n[i].id&&"username"!=n[i].id||(e=!0,o.instagram.searchForUsersByName(n[i].username,{success:function(e){if(void 0!==e.meta&&void 0!==e.meta.error_type&&wdi_front.show_alert(!1,e,o),200==e.meta.code&&0<e.data.length){for(var i=!1,d=0;d<e.data.length;d++)if(e.data[d].username==e.args.username){i=!0;break}if(i)for(var r=0;r<n.length;r++)e.data[d].username==n[r].username&&(n[r].id=e.data[d].id)}for(var t=!1,a=0;a<n.length;a++)if(""==n[a].id||"username"==n[a].id){t=!0;break}t||(o.feed_row.feed_users=JSON.stringify(n),wdi_front.init(o))},username:n[i].username})):n[i].id=n[i].username;return e},void 0!==wdi_ajax.ajax_response?jQuery(document).one("ajaxStop",function(){"not_declared"!=wdi_front.type&&(wdi_front.clickOrTouch=wdi_front.detectEvent(),wdi_front.globalInit())}):jQuery(document).ready(function(){"not_declared"!=wdi_front.type&&(wdi_front.clickOrTouch=wdi_front.detectEvent(),wdi_front.globalInit())}),jQuery(document).ready(function(){setTimeout(function(){"1"===wdi_front_messages.show_alerts&&"I"!==jQuery(".wdi_check_fontawesome .tenweb-i-instagram").prop("tagName")&&console.log("Font Awesome is not loaded properly. Please ask for support https://wordpress.org/support/plugin/wd-instagram-feed/")},2e3)});
|
js/wdi_instagram.js
CHANGED
|
@@ -944,7 +944,8 @@ function WDIInstagram(args) {
|
|
| 944 |
|
| 945 |
if( typeof response['data'] === 'undefined' || (typeof response['data'] !== 'undefined' && response['data'].length === 0 && after_cache === 0)) {
|
| 946 |
_this.set_cache_data('', user_name, feed_id,'', 0, 1, '', '', '', args);
|
| 947 |
-
}
|
|
|
|
| 948 |
if( response['data'].length !== 0 ) {
|
| 949 |
response.meta = {'code': 200, 'error': error, 'error_type': error_type};
|
| 950 |
if (successFlag) {
|
|
@@ -972,11 +973,11 @@ function WDIInstagram(args) {
|
|
| 972 |
args.success(response);
|
| 973 |
}
|
| 974 |
}
|
| 975 |
-
}
|
|
|
|
| 976 |
response.meta = {'code': 400, 'error': error, 'error_type': error_type};
|
| 977 |
args.success(response);
|
| 978 |
}
|
| 979 |
-
|
| 980 |
}
|
| 981 |
},
|
| 982 |
error: function (response)
|
|
@@ -1085,7 +1086,6 @@ function WDIInstagram(args) {
|
|
| 1085 |
success: function ( response ) {
|
| 1086 |
if( response['next_url'] != '' ) {
|
| 1087 |
response['iter']++;
|
| 1088 |
-
|
| 1089 |
if( response['iter'] >= wdi_cache_request_count ) {
|
| 1090 |
if( frontend === 1 ) {
|
| 1091 |
if( tag_id === 'false' ) {
|
|
@@ -1097,11 +1097,13 @@ function WDIInstagram(args) {
|
|
| 1097 |
jQuery("#wdi_save_loading").addClass("wdi_hidden");
|
| 1098 |
window.location = comlete_redirect_url;
|
| 1099 |
}
|
| 1100 |
-
}
|
|
|
|
| 1101 |
/* Recall function for next iteration */
|
| 1102 |
_this.set_cache_data(comlete_redirect_url, user_name, feed_id, response['next_url'], response['iter'], frontend, tagname, tag_id, endpoint, args);
|
| 1103 |
}
|
| 1104 |
-
}
|
|
|
|
| 1105 |
if( frontend === 1 ) {
|
| 1106 |
if(tag_id === 'false') {
|
| 1107 |
_this.getTagRecentMedia( tagname, args, next_url, endpoint, 1);
|
| 944 |
|
| 945 |
if( typeof response['data'] === 'undefined' || (typeof response['data'] !== 'undefined' && response['data'].length === 0 && after_cache === 0)) {
|
| 946 |
_this.set_cache_data('', user_name, feed_id,'', 0, 1, '', '', '', args);
|
| 947 |
+
}
|
| 948 |
+
else {
|
| 949 |
if( response['data'].length !== 0 ) {
|
| 950 |
response.meta = {'code': 200, 'error': error, 'error_type': error_type};
|
| 951 |
if (successFlag) {
|
| 973 |
args.success(response);
|
| 974 |
}
|
| 975 |
}
|
| 976 |
+
}
|
| 977 |
+
else {
|
| 978 |
response.meta = {'code': 400, 'error': error, 'error_type': error_type};
|
| 979 |
args.success(response);
|
| 980 |
}
|
|
|
|
| 981 |
}
|
| 982 |
},
|
| 983 |
error: function (response)
|
| 1086 |
success: function ( response ) {
|
| 1087 |
if( response['next_url'] != '' ) {
|
| 1088 |
response['iter']++;
|
|
|
|
| 1089 |
if( response['iter'] >= wdi_cache_request_count ) {
|
| 1090 |
if( frontend === 1 ) {
|
| 1091 |
if( tag_id === 'false' ) {
|
| 1097 |
jQuery("#wdi_save_loading").addClass("wdi_hidden");
|
| 1098 |
window.location = comlete_redirect_url;
|
| 1099 |
}
|
| 1100 |
+
}
|
| 1101 |
+
else {
|
| 1102 |
/* Recall function for next iteration */
|
| 1103 |
_this.set_cache_data(comlete_redirect_url, user_name, feed_id, response['next_url'], response['iter'], frontend, tagname, tag_id, endpoint, args);
|
| 1104 |
}
|
| 1105 |
+
}
|
| 1106 |
+
else {
|
| 1107 |
if( frontend === 1 ) {
|
| 1108 |
if(tag_id === 'false') {
|
| 1109 |
_this.getTagRecentMedia( tagname, args, next_url, endpoint, 1);
|
readme.txt
CHANGED
|
@@ -4,7 +4,7 @@ Tags: custom instagram feed, feed, instagram, hashtag, Instagram feed, instagram
|
|
| 4 |
Requires at least: 3.9
|
| 5 |
Requires PHP: 5.2
|
| 6 |
Tested up to: 5.8
|
| 7 |
-
Stable tag: 1.4.
|
| 8 |
License: GPLv2 or later
|
| 9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
| 10 |
|
|
@@ -505,6 +505,10 @@ Please make sure you don't have any important information before you proceed.
|
|
| 505 |
10Web Social Photo Feed for Instagram plugin uses Instagram API on website front end. You have to authorize the plugin via sign in to get data from Instagram on your behalf. The plugin does not send any user’s data to Instagram. All the data received from Instagram via API is cached in WordPress database for some short customizable period to provide front end optimization. You can delete or update cached data. Instagram saves some cookies in browsers of website visitors via API data. These cookies are mostly used for security purposes. They are regulated under terms of Instagram’s privacy policy https://instagram.com/legal/privacy. The plugin asks for your consent to collect site administrator’s email address and site URL to offer customer support, deals and discounts on premium products and more.
|
| 506 |
|
| 507 |
== Changelog ==
|
|
|
|
|
|
|
|
|
|
|
|
|
| 508 |
= 1.4.21 =
|
| 509 |
Fixed: Connecting to the Business account.
|
| 510 |
|
| 4 |
Requires at least: 3.9
|
| 5 |
Requires PHP: 5.2
|
| 6 |
Tested up to: 5.8
|
| 7 |
+
Stable tag: 1.4.22
|
| 8 |
License: GPLv2 or later
|
| 9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
| 10 |
|
| 505 |
10Web Social Photo Feed for Instagram plugin uses Instagram API on website front end. You have to authorize the plugin via sign in to get data from Instagram on your behalf. The plugin does not send any user’s data to Instagram. All the data received from Instagram via API is cached in WordPress database for some short customizable period to provide front end optimization. You can delete or update cached data. Instagram saves some cookies in browsers of website visitors via API data. These cookies are mostly used for security purposes. They are regulated under terms of Instagram’s privacy policy https://instagram.com/legal/privacy. The plugin asks for your consent to collect site administrator’s email address and site URL to offer customer support, deals and discounts on premium products and more.
|
| 506 |
|
| 507 |
== Changelog ==
|
| 508 |
+
= 1.4.22 =
|
| 509 |
+
Fixed: XSS vulnerabilities on settings page.
|
| 510 |
+
Fixed: Disable pagination during page load.
|
| 511 |
+
|
| 512 |
= 1.4.21 =
|
| 513 |
Fixed: Connecting to the Business account.
|
| 514 |
|
wd-instagram-feed.php
CHANGED
|
@@ -3,7 +3,7 @@
|
|
| 3 |
* Plugin Name: 10Web Social Photo Feed
|
| 4 |
* Plugin URI: https://10web.io/plugins/wordpress-instagram-feed/?utm_source=instagram_feed&utm_medium=free_plugin
|
| 5 |
* Description: 10Web Social Photo Feed is a user-friendly tool for displaying user or hashtag-based feeds on your website. You can create feeds with one of the available layouts. It allows displaying image metadata, open up images in lightbox, download them and even share in social networking websites.
|
| 6 |
-
* Version: 1.4.
|
| 7 |
* Author: 10Web
|
| 8 |
* Author URI: https://10Web.io/plugins/?utm_source=instagram_feed&utm_medium=free_plugin
|
| 9 |
* License: GPLv2 or later
|
| 3 |
* Plugin Name: 10Web Social Photo Feed
|
| 4 |
* Plugin URI: https://10web.io/plugins/wordpress-instagram-feed/?utm_source=instagram_feed&utm_medium=free_plugin
|
| 5 |
* Description: 10Web Social Photo Feed is a user-friendly tool for displaying user or hashtag-based feeds on your website. You can create feeds with one of the available layouts. It allows displaying image metadata, open up images in lightbox, download them and even share in social networking websites.
|
| 6 |
+
* Version: 1.4.22
|
| 7 |
* Author: 10Web
|
| 8 |
* Author URI: https://10Web.io/plugins/?utm_source=instagram_feed&utm_medium=free_plugin
|
| 9 |
* License: GPLv2 or later
|
