Version Description
Download this release
Release Info
Developer | themeisle |
Plugin | FEEDZY RSS Feeds Lite |
Version | 3.7.3 |
Comparing to | |
See all releases |
Code changes from version 3.7.2 to 3.7.3
- CHANGELOG.md +13 -0
- css/feedzy-rss-feeds.css +1 -1
- css/settings.css +21 -1
- feedzy-rss-feed.php +1 -1
- includes/abstract/feedzy-rss-feeds-admin-abstract.php +23 -7
- includes/admin/feedzy-rss-feeds-admin.php +18 -0
- includes/admin/feedzy-rss-feeds-import.php +22 -3
- includes/admin/feedzy-wp-widget.php +3 -0
- includes/feedzy-rss-feeds-feed-tweaks.php +34 -1
- includes/feedzy-rss-feeds.php +1 -1
- includes/gutenberg/build/block.js +1 -1
- includes/gutenberg/feedzy-rss-feeds-gutenberg-block.php +1 -0
- includes/layouts/settings.php +15 -1
- includes/views/import-metabox-edit.php +1 -1
- js/feedzy-setting.js +48 -0
- readme.txt +17 -1
- vendor/autoload.php +1 -1
- vendor/composer/autoload_real.php +7 -7
- vendor/composer/autoload_static.php +2 -2
- vendor/composer/installed.php +6 -6
CHANGELOG.md
CHANGED
@@ -1,3 +1,16 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
##### [Version 3.7.2](https://github.com/Codeinwp/feedzy-rss-feeds/compare/v3.7.1...v3.7.2) (2021-08-04)
|
2 |
|
3 |
#### Features
|
1 |
+
##### [Version 3.7.3](https://github.com/Codeinwp/feedzy-rss-feeds/compare/v3.7.2...v3.7.3) (2021-08-27)
|
2 |
+
|
3 |
+
#### Features
|
4 |
+
* Support default Gutenberg editor instead of importing content in the Classic block
|
5 |
+
* Adds support for Feedzy widget in the widget block editor
|
6 |
+
* Adds default thumbnail image support when no image is available
|
7 |
+
|
8 |
+
#### Fixes
|
9 |
+
* Title Character Limit and the Description Character Limit parameter in the Feedzy Block
|
10 |
+
* Displaying Default Thumbnail Image does not show in Block or Shortcode approach
|
11 |
+
* Custom tag is trimmed on save of the import if used inside <iframe>
|
12 |
+
* Keyword filters break the import with PHP 8.0
|
13 |
+
|
14 |
##### [Version 3.7.2](https://github.com/Codeinwp/feedzy-rss-feeds/compare/v3.7.1...v3.7.2) (2021-08-04)
|
15 |
|
16 |
#### Features
|
css/feedzy-rss-feeds.css
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
* feedzy-rss-feeds.css
|
3 |
* Feedzy RSS Feed
|
4 |
* Copyright: (c) 2016 Themeisle, themeisle.com
|
5 |
-
* Version: 3.7.
|
6 |
* Plugin Name: FEEDZY RSS Feeds
|
7 |
* Plugin URI: http://themeisle.com/plugins/feedzy-rss-feeds/
|
8 |
* Author: Themeisle
|
2 |
* feedzy-rss-feeds.css
|
3 |
* Feedzy RSS Feed
|
4 |
* Copyright: (c) 2016 Themeisle, themeisle.com
|
5 |
+
* Version: 3.7.3
|
6 |
* Plugin Name: FEEDZY RSS Feeds
|
7 |
* Plugin URI: http://themeisle.com/plugins/feedzy-rss-feeds/
|
8 |
* Author: Themeisle
|
css/settings.css
CHANGED
@@ -172,4 +172,24 @@
|
|
172 |
|
173 |
.fz-feature-centered {
|
174 |
text-align: center;
|
175 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
172 |
|
173 |
.fz-feature-centered {
|
174 |
text-align: center;
|
175 |
+
}
|
176 |
+
|
177 |
+
.button.feedzy-open-media {
|
178 |
+
font-weight: 700;
|
179 |
+
}
|
180 |
+
|
181 |
+
.button.feedzy-remove-media {
|
182 |
+
visibility: hidden;
|
183 |
+
}
|
184 |
+
|
185 |
+
.button.feedzy-remove-media,
|
186 |
+
.button.feedzy-remove-media:hover {
|
187 |
+
color: #f1f1f1;
|
188 |
+
border-color: #F00;
|
189 |
+
background: #F00;
|
190 |
+
font-weight: 700;
|
191 |
+
}
|
192 |
+
|
193 |
+
.button.is-show {
|
194 |
+
visibility: visible;
|
195 |
+
}
|
feedzy-rss-feed.php
CHANGED
@@ -15,7 +15,7 @@
|
|
15 |
* Plugin Name: Feedzy RSS Feeds Lite
|
16 |
* Plugin URI: https://themeisle.com/plugins/feedzy-rss-feeds-lite/
|
17 |
* Description: A small and lightweight RSS aggregator plugin. Fast and very easy to use, it allows you to aggregate multiple RSS feeds into your WordPress site through fully customizable shortcodes & widgets.
|
18 |
-
* Version: 3.7.
|
19 |
* Author: Themeisle
|
20 |
* Author URI: http://themeisle.com
|
21 |
* License: GPL-2.0+
|
15 |
* Plugin Name: Feedzy RSS Feeds Lite
|
16 |
* Plugin URI: https://themeisle.com/plugins/feedzy-rss-feeds-lite/
|
17 |
* Description: A small and lightweight RSS aggregator plugin. Fast and very easy to use, it allows you to aggregate multiple RSS feeds into your WordPress site through fully customizable shortcodes & widgets.
|
18 |
+
* Version: 3.7.3
|
19 |
* Author: Themeisle
|
20 |
* Author URI: http://themeisle.com
|
21 |
* License: GPL-2.0+
|
includes/abstract/feedzy-rss-feeds-admin-abstract.php
CHANGED
@@ -35,12 +35,14 @@ abstract class Feedzy_Rss_Feeds_Admin_Abstract {
|
|
35 |
* @since 3.0.0
|
36 |
* @access public
|
37 |
*
|
38 |
-
* @param string $
|
39 |
*
|
40 |
* @return string
|
41 |
*/
|
42 |
-
public function feedzy_define_default_image( $
|
43 |
-
$default_img
|
|
|
|
|
44 |
|
45 |
return apply_filters( 'feedzy_define_default_image_filter', $default_img );
|
46 |
}
|
@@ -708,6 +710,7 @@ abstract class Feedzy_Rss_Feeds_Admin_Abstract {
|
|
708 |
'days' => DAY_IN_SECONDS,
|
709 |
);
|
710 |
$cache_time = 12 * HOUR_IN_SECONDS;
|
|
|
711 |
if ( isset( $cache ) && '' !== $cache ) {
|
712 |
list( $value, $unit ) = explode( '_', $cache );
|
713 |
if ( isset( $value ) && is_numeric( $value ) && $value >= 1 && $value <= 100 ) {
|
@@ -944,18 +947,30 @@ abstract class Feedzy_Rss_Feeds_Admin_Abstract {
|
|
944 |
$sc['size'] = '150';
|
945 |
}
|
946 |
if ( ! empty( $sc['keywords_title'] ) ) {
|
|
|
|
|
|
|
947 |
$sc['keywords_title'] = rtrim( $sc['keywords_title'], ',' );
|
948 |
$sc['keywords_title'] = array_map( 'trim', explode( ',', $sc['keywords_title'] ) );
|
949 |
}
|
950 |
if ( ! empty( $sc['keywords_inc'] ) ) {
|
|
|
|
|
|
|
951 |
$sc['keywords_inc'] = rtrim( $sc['keywords_inc'], ',' );
|
952 |
$sc['keywords_inc'] = array_map( 'trim', explode( ',', $sc['keywords_inc'] ) );
|
953 |
}
|
954 |
if ( ! empty( $sc['keywords_ban'] ) ) {
|
|
|
|
|
|
|
955 |
$sc['keywords_ban'] = rtrim( $sc['keywords_ban'], ',' );
|
956 |
$sc['keywords_ban'] = array_map( 'trim', explode( ',', $sc['keywords_ban'] ) );
|
957 |
}
|
958 |
if ( ! empty( $sc['keywords_exc'] ) ) {
|
|
|
|
|
|
|
959 |
$sc['keywords_exc'] = rtrim( $sc['keywords_exc'], ',' );
|
960 |
$sc['keywords_exc'] = array_map( 'trim', explode( ',', $sc['keywords_exc'] ) );
|
961 |
}
|
@@ -1266,8 +1281,6 @@ abstract class Feedzy_Rss_Feeds_Admin_Abstract {
|
|
1266 |
$length = intval( $sc['title'] );
|
1267 |
if ( $length > 0 && strlen( $content_title ) > $length ) {
|
1268 |
$content_title = preg_replace( '/\s+?(\S+)?$/', '', substr( $content_title, 0, $length ) ) . '...';
|
1269 |
-
} elseif ( 0 === $length ) {
|
1270 |
-
$content_title = '';
|
1271 |
}
|
1272 |
}
|
1273 |
if ( empty( $content_title ) ) {
|
@@ -1519,8 +1532,11 @@ abstract class Feedzy_Rss_Feeds_Admin_Abstract {
|
|
1519 |
}
|
1520 |
|
1521 |
$the_thumbnail = html_entity_decode( $the_thumbnail, ENT_QUOTES, 'UTF-8' );
|
|
|
|
|
|
|
|
|
1522 |
$the_thumbnail = apply_filters( 'feedzy_retrieve_image', $the_thumbnail, $item );
|
1523 |
-
|
1524 |
return $the_thumbnail;
|
1525 |
}
|
1526 |
|
@@ -1573,7 +1589,7 @@ abstract class Feedzy_Rss_Feeds_Admin_Abstract {
|
|
1573 |
* @return string
|
1574 |
*/
|
1575 |
public function feedzy_scrape_image( $string, $link = '' ) {
|
1576 |
-
$pattern = '/src=[\'"]
|
1577 |
$match = $link;
|
1578 |
preg_match( $pattern, $string, $link );
|
1579 |
if ( ! empty( $link ) && isset( $link[1] ) ) {
|
35 |
* @since 3.0.0
|
36 |
* @access public
|
37 |
*
|
38 |
+
* @param string $default_img The image source, currently not used.
|
39 |
*
|
40 |
* @return string
|
41 |
*/
|
42 |
+
public function feedzy_define_default_image( $default_img ) {
|
43 |
+
if ( empty( $default_img ) ) {
|
44 |
+
$default_img = FEEDZY_ABSURL . 'img/feedzy.svg';
|
45 |
+
}
|
46 |
|
47 |
return apply_filters( 'feedzy_define_default_image_filter', $default_img );
|
48 |
}
|
710 |
'days' => DAY_IN_SECONDS,
|
711 |
);
|
712 |
$cache_time = 12 * HOUR_IN_SECONDS;
|
713 |
+
$cache = trim( $cache );
|
714 |
if ( isset( $cache ) && '' !== $cache ) {
|
715 |
list( $value, $unit ) = explode( '_', $cache );
|
716 |
if ( isset( $value ) && is_numeric( $value ) && $value >= 1 && $value <= 100 ) {
|
947 |
$sc['size'] = '150';
|
948 |
}
|
949 |
if ( ! empty( $sc['keywords_title'] ) ) {
|
950 |
+
if ( is_array( $sc['keywords_title'] ) ) {
|
951 |
+
$sc['keywords_title'] = implode( ',', $sc['keywords_title'] );
|
952 |
+
}
|
953 |
$sc['keywords_title'] = rtrim( $sc['keywords_title'], ',' );
|
954 |
$sc['keywords_title'] = array_map( 'trim', explode( ',', $sc['keywords_title'] ) );
|
955 |
}
|
956 |
if ( ! empty( $sc['keywords_inc'] ) ) {
|
957 |
+
if ( is_array( $sc['keywords_inc'] ) ) {
|
958 |
+
$sc['keywords_inc'] = implode( ',', $sc['keywords_inc'] );
|
959 |
+
}
|
960 |
$sc['keywords_inc'] = rtrim( $sc['keywords_inc'], ',' );
|
961 |
$sc['keywords_inc'] = array_map( 'trim', explode( ',', $sc['keywords_inc'] ) );
|
962 |
}
|
963 |
if ( ! empty( $sc['keywords_ban'] ) ) {
|
964 |
+
if ( is_array( $sc['keywords_ban'] ) ) {
|
965 |
+
$sc['keywords_ban'] = implode( ',', $sc['keywords_ban'] );
|
966 |
+
}
|
967 |
$sc['keywords_ban'] = rtrim( $sc['keywords_ban'], ',' );
|
968 |
$sc['keywords_ban'] = array_map( 'trim', explode( ',', $sc['keywords_ban'] ) );
|
969 |
}
|
970 |
if ( ! empty( $sc['keywords_exc'] ) ) {
|
971 |
+
if ( is_array( $sc['keywords_exc'] ) ) {
|
972 |
+
$sc['keywords_exc'] = implode( ',', $sc['keywords_exc'] );
|
973 |
+
}
|
974 |
$sc['keywords_exc'] = rtrim( $sc['keywords_exc'], ',' );
|
975 |
$sc['keywords_exc'] = array_map( 'trim', explode( ',', $sc['keywords_exc'] ) );
|
976 |
}
|
1281 |
$length = intval( $sc['title'] );
|
1282 |
if ( $length > 0 && strlen( $content_title ) > $length ) {
|
1283 |
$content_title = preg_replace( '/\s+?(\S+)?$/', '', substr( $content_title, 0, $length ) ) . '...';
|
|
|
|
|
1284 |
}
|
1285 |
}
|
1286 |
if ( empty( $content_title ) ) {
|
1532 |
}
|
1533 |
|
1534 |
$the_thumbnail = html_entity_decode( $the_thumbnail, ENT_QUOTES, 'UTF-8' );
|
1535 |
+
if ( ! defined( 'REST_REQUEST' ) || ! REST_REQUEST ) {
|
1536 |
+
$feed_url = $this->normalize_urls( $sc['feeds'] );
|
1537 |
+
$the_thumbnail = ! empty( $the_thumbnail ) ? $the_thumbnail : apply_filters( 'feedzy_default_image', $sc['default'], $feed_url );
|
1538 |
+
}
|
1539 |
$the_thumbnail = apply_filters( 'feedzy_retrieve_image', $the_thumbnail, $item );
|
|
|
1540 |
return $the_thumbnail;
|
1541 |
}
|
1542 |
|
1589 |
* @return string
|
1590 |
*/
|
1591 |
public function feedzy_scrape_image( $string, $link = '' ) {
|
1592 |
+
$pattern = '/src=[\'"](.*?:\/\/.*\.(?:jpg|JPG|jpeg|JPEG|jpe|JPE|gif|GIF|png|PNG)+)[\'" >]/';
|
1593 |
$match = $link;
|
1594 |
preg_match( $pattern, $string, $link );
|
1595 |
if ( ! empty( $link ) && isset( $link[1] ) ) {
|
includes/admin/feedzy-rss-feeds-admin.php
CHANGED
@@ -142,6 +142,23 @@ class Feedzy_Rss_Feeds_Admin extends Feedzy_Rss_Feeds_Admin_Abstract {
|
|
142 |
);
|
143 |
}
|
144 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
145 |
if ( in_array( $screen->base, array( 'post' ), true ) ) {
|
146 |
wp_enqueue_style( $this->plugin_name . '-admin', FEEDZY_ABSURL . 'css/admin.css', array(), $this->version, 'all' );
|
147 |
}
|
@@ -499,6 +516,7 @@ class Feedzy_Rss_Feeds_Admin extends Feedzy_Rss_Feeds_Admin_Abstract {
|
|
499 |
switch ( $post_tab ) {
|
500 |
case 'general':
|
501 |
$settings['general']['rss-feeds'] = isset( $_POST['rss-feeds'] ) ? (int) filter_input( INPUT_POST, 'rss-feeds', FILTER_SANITIZE_NUMBER_INT ) : '';
|
|
|
502 |
break;
|
503 |
case 'headers':
|
504 |
$settings['header']['user-agent'] = isset( $_POST['user-agent'] ) ? filter_input( INPUT_POST, 'user-agent', FILTER_SANITIZE_STRING ) : '';
|
142 |
);
|
143 |
}
|
144 |
|
145 |
+
if ( 'feedzy_page_feedzy-settings' === $screen->base ) {
|
146 |
+
if ( ! did_action( 'wp_enqueue_media' ) ) {
|
147 |
+
wp_enqueue_media();
|
148 |
+
}
|
149 |
+
wp_enqueue_script( $this->plugin_name . '_setting', FEEDZY_ABSURL . 'js/feedzy-setting.js', array( 'jquery' ), $this->version, true );
|
150 |
+
wp_localize_script(
|
151 |
+
$this->plugin_name . '_setting',
|
152 |
+
'feedzy_setting',
|
153 |
+
array(
|
154 |
+
'l10n' => array(
|
155 |
+
'media_iframe_title' => __( 'Select image', 'feedzy-rss-feeds' ),
|
156 |
+
'media_iframe_button' => __( 'Set default image', 'feedzy-rss-feeds' ),
|
157 |
+
),
|
158 |
+
)
|
159 |
+
);
|
160 |
+
}
|
161 |
+
|
162 |
if ( in_array( $screen->base, array( 'post' ), true ) ) {
|
163 |
wp_enqueue_style( $this->plugin_name . '-admin', FEEDZY_ABSURL . 'css/admin.css', array(), $this->version, 'all' );
|
164 |
}
|
516 |
switch ( $post_tab ) {
|
517 |
case 'general':
|
518 |
$settings['general']['rss-feeds'] = isset( $_POST['rss-feeds'] ) ? (int) filter_input( INPUT_POST, 'rss-feeds', FILTER_SANITIZE_NUMBER_INT ) : '';
|
519 |
+
$settings['general']['default-thumbnail-id'] = isset( $_POST['default-thumbnail-id'] ) ? (int) filter_input( INPUT_POST, 'default-thumbnail-id', FILTER_SANITIZE_NUMBER_INT ) : 0;
|
520 |
break;
|
521 |
case 'headers':
|
522 |
$settings['header']['user-agent'] = isset( $_POST['user-agent'] ) ? filter_input( INPUT_POST, 'user-agent', FILTER_SANITIZE_STRING ) : '';
|
includes/admin/feedzy-rss-feeds-import.php
CHANGED
@@ -391,7 +391,12 @@ class Feedzy_Rss_Feeds_Import {
|
|
391 |
$data_meta[ sanitize_text_field( $key ) ][ sanitize_text_field( $sub_key ) ] = wp_kses( $sub_val, apply_filters( 'feedzy_wp_kses_allowed_html', array() ) );
|
392 |
}
|
393 |
} else {
|
394 |
-
|
|
|
|
|
|
|
|
|
|
|
395 |
}
|
396 |
}
|
397 |
}
|
@@ -437,11 +442,14 @@ class Feedzy_Rss_Feeds_Import {
|
|
437 |
}
|
438 |
if ( 'import_post_content' === $key ) {
|
439 |
add_filter( 'wp_kses_allowed_html', array( $this, 'allow_iframe_tag_item_content' ), 10, 2 );
|
|
|
|
|
|
|
440 |
}
|
441 |
if ( get_post_meta( $post_id, $key, false ) ) {
|
442 |
-
update_post_meta( $post_id, $key,
|
443 |
} else {
|
444 |
-
add_post_meta( $post_id, $key,
|
445 |
}
|
446 |
if ( ! $value ) {
|
447 |
delete_post_meta( $post_id, $key );
|
@@ -1360,6 +1368,10 @@ class Feedzy_Rss_Feeds_Import {
|
|
1360 |
|
1361 |
if ( ! defined( 'FEEDZY_ALLOW_UNSAFE_HTML' ) || ! FEEDZY_ALLOW_UNSAFE_HTML ) {
|
1362 |
$post_content = wp_kses( $post_content, apply_filters( 'feedzy_wp_kses_allowed_html', array() ) );
|
|
|
|
|
|
|
|
|
1363 |
}
|
1364 |
$new_post = apply_filters(
|
1365 |
'feedzy_insert_post_args',
|
@@ -1503,6 +1515,12 @@ class Feedzy_Rss_Feeds_Import {
|
|
1503 |
}
|
1504 |
}
|
1505 |
|
|
|
|
|
|
|
|
|
|
|
|
|
1506 |
if ( ! $img_success ) {
|
1507 |
$import_image_errors++;
|
1508 |
}
|
@@ -2095,6 +2113,7 @@ class Feedzy_Rss_Feeds_Import {
|
|
2095 |
'width' => true,
|
2096 |
'frameborder' => true,
|
2097 |
'allowfullscreen' => true,
|
|
|
2098 |
);
|
2099 |
}
|
2100 |
return $tags;
|
391 |
$data_meta[ sanitize_text_field( $key ) ][ sanitize_text_field( $sub_key ) ] = wp_kses( $sub_val, apply_filters( 'feedzy_wp_kses_allowed_html', array() ) );
|
392 |
}
|
393 |
} else {
|
394 |
+
if ( 'import_post_content' === $key ) {
|
395 |
+
$val = feedzy_custom_tag_escape( $val );
|
396 |
+
} else {
|
397 |
+
$val = wp_kses( $val, apply_filters( 'feedzy_wp_kses_allowed_html', array() ) );
|
398 |
+
}
|
399 |
+
$data_meta[ sanitize_text_field( $key ) ] = $val;
|
400 |
}
|
401 |
}
|
402 |
}
|
442 |
}
|
443 |
if ( 'import_post_content' === $key ) {
|
444 |
add_filter( 'wp_kses_allowed_html', array( $this, 'allow_iframe_tag_item_content' ), 10, 2 );
|
445 |
+
$value = feedzy_custom_tag_escape( $value );
|
446 |
+
} else {
|
447 |
+
$value = wp_kses( $value, wp_kses_allowed_html( 'post' ) );
|
448 |
}
|
449 |
if ( get_post_meta( $post_id, $key, false ) ) {
|
450 |
+
update_post_meta( $post_id, $key, $value );
|
451 |
} else {
|
452 |
+
add_post_meta( $post_id, $key, $value );
|
453 |
}
|
454 |
if ( ! $value ) {
|
455 |
delete_post_meta( $post_id, $key );
|
1368 |
|
1369 |
if ( ! defined( 'FEEDZY_ALLOW_UNSAFE_HTML' ) || ! FEEDZY_ALLOW_UNSAFE_HTML ) {
|
1370 |
$post_content = wp_kses( $post_content, apply_filters( 'feedzy_wp_kses_allowed_html', array() ) );
|
1371 |
+
if ( use_block_editor_for_post_type( $import_post_type ) ) {
|
1372 |
+
$post_content = ! empty( $post_content ) ? '<!-- wp:html -->' . trim( force_balance_tags( wpautop( $post_content, 'br' ) ) ) . '<!-- /wp:html -->' : $post_content;
|
1373 |
+
$post_content = trim( $post_content );
|
1374 |
+
}
|
1375 |
}
|
1376 |
$new_post = apply_filters(
|
1377 |
'feedzy_insert_post_args',
|
1515 |
}
|
1516 |
}
|
1517 |
|
1518 |
+
// Set default thumbnail image.
|
1519 |
+
if ( ! $img_success && isset( $this->free_settings['general']['default-thumbnail-id'] ) ) {
|
1520 |
+
$default_thumbnail = $this->free_settings['general']['default-thumbnail-id'];
|
1521 |
+
$img_success = set_post_thumbnail( $new_post_id, $default_thumbnail );
|
1522 |
+
}
|
1523 |
+
|
1524 |
if ( ! $img_success ) {
|
1525 |
$import_image_errors++;
|
1526 |
}
|
2113 |
'width' => true,
|
2114 |
'frameborder' => true,
|
2115 |
'allowfullscreen' => true,
|
2116 |
+
'data-*' => true,
|
2117 |
);
|
2118 |
}
|
2119 |
return $tags;
|
includes/admin/feedzy-wp-widget.php
CHANGED
@@ -64,6 +64,9 @@ class feedzy_wp_widget extends WP_Widget {
|
|
64 |
* @access public
|
65 |
*/
|
66 |
public function registerWidget() {
|
|
|
|
|
|
|
67 |
register_widget( 'feedzy_wp_widget' );
|
68 |
}
|
69 |
|
64 |
* @access public
|
65 |
*/
|
66 |
public function registerWidget() {
|
67 |
+
if ( function_exists( 'wp_use_widgets_block_editor' ) && wp_use_widgets_block_editor() ) {
|
68 |
+
return;
|
69 |
+
}
|
70 |
register_widget( 'feedzy_wp_widget' );
|
71 |
}
|
72 |
|
includes/feedzy-rss-feeds-feed-tweaks.php
CHANGED
@@ -61,7 +61,10 @@ function display_external_post_image( $html, $post_id, $post_thumbnail_id, $size
|
|
61 |
$attr['style'] = isset( $attr['style'] ) ? $attr['style'] : '';
|
62 |
|
63 |
// Get image dimensions.
|
64 |
-
if (
|
|
|
|
|
|
|
65 |
$_wp_additional_image_sizes = wp_get_registered_image_subsizes();
|
66 |
if ( isset( $_wp_additional_image_sizes[ $size ] ) ) {
|
67 |
$sizes = $_wp_additional_image_sizes[ $size ];
|
@@ -159,6 +162,35 @@ function feedzy_is_pro_older_than( $version ) {
|
|
159 |
return version_compare( FEEDZY_PRO_VERSION, $version, '<' );
|
160 |
}
|
161 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
162 |
add_filter(
|
163 |
'feedzy_wp_kses_allowed_html',
|
164 |
function( $allowed_html = array() ) {
|
@@ -246,6 +278,7 @@ add_filter(
|
|
246 |
'width' => array(),
|
247 |
'frameborder' => array(),
|
248 |
'allowfullscreen' => array(),
|
|
|
249 |
),
|
250 |
);
|
251 |
}
|
61 |
$attr['style'] = isset( $attr['style'] ) ? $attr['style'] : '';
|
62 |
|
63 |
// Get image dimensions.
|
64 |
+
if ( is_array( $size ) ) {
|
65 |
+
$dimensions = wp_sprintf( 'width:%dpx; height:%dpx;', $size[0], $size[1] );
|
66 |
+
$attr['style'] .= $dimensions;
|
67 |
+
} elseif ( function_exists( 'wp_get_registered_image_subsizes' ) ) {
|
68 |
$_wp_additional_image_sizes = wp_get_registered_image_subsizes();
|
69 |
if ( isset( $_wp_additional_image_sizes[ $size ] ) ) {
|
70 |
$sizes = $_wp_additional_image_sizes[ $size ];
|
162 |
return version_compare( FEEDZY_PRO_VERSION, $version, '<' );
|
163 |
}
|
164 |
|
165 |
+
/**
|
166 |
+
* Feedzy escape custom tag in html attributes.
|
167 |
+
*
|
168 |
+
* @param string $content Content.
|
169 |
+
* @return string
|
170 |
+
*/
|
171 |
+
function feedzy_custom_tag_escape( $content = '' ) {
|
172 |
+
if ( $content ) {
|
173 |
+
// Match feedzy custom tags in the src attribute.
|
174 |
+
preg_match_all( '/(\w+)="([^"]*)"/i', $content, $matches, PREG_SET_ORDER );
|
175 |
+
|
176 |
+
// If preg match found custom tags in src attribute.
|
177 |
+
if ( ! empty( $matches ) ) {
|
178 |
+
foreach ( $matches as $key => $match ) {
|
179 |
+
if ( isset( $match[2] ) && false !== stripos( $match[2], '[#item_custom_media:' ) ) {
|
180 |
+
$replace_with = $match[1];
|
181 |
+
$replace_to = wp_sprintf( 'data-feedzy_%d_%s', $key, $replace_with );
|
182 |
+
$content = str_replace( $replace_with, $replace_to, $content );
|
183 |
+
}
|
184 |
+
}
|
185 |
+
$content = wp_kses( $content, wp_kses_allowed_html( 'post' ) );
|
186 |
+
$content = preg_replace( '/data-feedzy_([0-9_]+)/', '', $content );
|
187 |
+
} else {
|
188 |
+
$content = wp_kses( $content, wp_kses_allowed_html( 'post' ) );
|
189 |
+
}
|
190 |
+
}
|
191 |
+
return $content;
|
192 |
+
}
|
193 |
+
|
194 |
add_filter(
|
195 |
'feedzy_wp_kses_allowed_html',
|
196 |
function( $allowed_html = array() ) {
|
278 |
'width' => array(),
|
279 |
'frameborder' => array(),
|
280 |
'allowfullscreen' => array(),
|
281 |
+
'data-*' => true,
|
282 |
),
|
283 |
);
|
284 |
}
|
includes/feedzy-rss-feeds.php
CHANGED
@@ -104,7 +104,7 @@ class Feedzy_Rss_Feeds {
|
|
104 |
*/
|
105 |
public function init() {
|
106 |
self::$plugin_name = 'feedzy-rss-feeds';
|
107 |
-
self::$version = '3.7.
|
108 |
self::$instance->load_dependencies();
|
109 |
self::$instance->set_locale();
|
110 |
self::$instance->define_admin_hooks();
|
104 |
*/
|
105 |
public function init() {
|
106 |
self::$plugin_name = 'feedzy-rss-feeds';
|
107 |
+
self::$version = '3.7.3';
|
108 |
self::$instance->load_dependencies();
|
109 |
self::$instance->set_locale();
|
110 |
self::$instance->define_admin_hooks();
|
includes/gutenberg/build/block.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
(()=>{"use strict";var e={20:e=>{var t="%[a-f0-9]{2}",r=new RegExp(t,"gi"),a=new RegExp("("+t+")+","gi");function n(e,t){try{return decodeURIComponent(e.join(""))}catch(e){}if(1===e.length)return e;t=t||1;var r=e.slice(0,t),a=e.slice(t);return Array.prototype.concat.call([],n(r),n(a))}function s(e){try{return decodeURIComponent(e)}catch(s){for(var t=e.match(r),a=1;a<t.length;a++)t=(e=n(t,a).join("")).match(r);return e}}e.exports=function(e){if("string"!=typeof e)throw new TypeError("Expected `encodedURI` to be of type `string`, got `"+typeof e+"`");try{return e=e.replace(/\+/g," "),decodeURIComponent(e)}catch(t){return function(e){for(var t={"%FE%FF":"��","%FF%FE":"��"},r=a.exec(e);r;){try{t[r[0]]=decodeURIComponent(r[0])}catch(e){var n=s(r[0]);n!==r[0]&&(t[r[0]]=n)}r=a.exec(e)}t["%C2"]="�";for(var o=Object.keys(t),i=0;i<o.length;i++){var l=o[i];e=e.replace(new RegExp(l,"g"),t[l])}return e}(e)}}},806:e=>{e.exports=function(e,t){for(var r={},a=Object.keys(e),n=Array.isArray(t),s=0;s<a.length;s++){var o=a[s],i=e[o];(n?-1!==t.indexOf(o):t(o,i,e))&&(r[o]=i)}return r}},563:(e,t,r)=>{const a=r(610),n=r(20),s=r(500),o=r(806);function i(e){if("string"!=typeof e||1!==e.length)throw new TypeError("arrayFormatSeparator must be single character string")}function l(e,t){return t.encode?t.strict?a(e):encodeURIComponent(e):e}function p(e,t){return t.decode?n(e):e}function u(e){return Array.isArray(e)?e.sort():"object"==typeof e?u(Object.keys(e)).sort(((e,t)=>Number(e)-Number(t))).map((t=>e[t])):e}function c(e){const t=e.indexOf("#");return-1!==t&&(e=e.slice(0,t)),e}function m(e){const t=(e=c(e)).indexOf("?");return-1===t?"":e.slice(t+1)}function d(e,t){return t.parseNumbers&&!Number.isNaN(Number(e))&&"string"==typeof e&&""!==e.trim()?e=Number(e):!t.parseBooleans||null===e||"true"!==e.toLowerCase()&&"false"!==e.toLowerCase()||(e="true"===e.toLowerCase()),e}function f(e,t){i((t=Object.assign({decode:!0,sort:!0,arrayFormat:"none",arrayFormatSeparator:",",parseNumbers:!1,parseBooleans:!1},t)).arrayFormatSeparator);const r=function(e){let t;switch(e.arrayFormat){case"index":return(e,r,a)=>{t=/\[(\d*)\]$/.exec(e),e=e.replace(/\[\d*\]$/,""),t?(void 0===a[e]&&(a[e]={}),a[e][t[1]]=r):a[e]=r};case"bracket":return(e,r,a)=>{t=/(\[\])$/.exec(e),e=e.replace(/\[\]$/,""),t?void 0!==a[e]?a[e]=[].concat(a[e],r):a[e]=[r]:a[e]=r};case"comma":case"separator":return(t,r,a)=>{const n="string"==typeof r&&r.includes(e.arrayFormatSeparator),s="string"==typeof r&&!n&&p(r,e).includes(e.arrayFormatSeparator);r=s?p(r,e):r;const o=n||s?r.split(e.arrayFormatSeparator).map((t=>p(t,e))):null===r?r:p(r,e);a[t]=o};case"bracket-separator":return(t,r,a)=>{const n=/(\[\])$/.test(t);if(t=t.replace(/\[\]$/,""),!n)return void(a[t]=r?p(r,e):r);const s=null===r?[]:r.split(e.arrayFormatSeparator).map((t=>p(t,e)));void 0!==a[t]?a[t]=[].concat(a[t],s):a[t]=s};default:return(e,t,r)=>{void 0!==r[e]?r[e]=[].concat(r[e],t):r[e]=t}}}(t),a=Object.create(null);if("string"!=typeof e)return a;if(!(e=e.trim().replace(/^[?#&]/,"")))return a;for(const n of e.split("&")){if(""===n)continue;let[e,o]=s(t.decode?n.replace(/\+/g," "):n,"=");o=void 0===o?null:["comma","separator","bracket-separator"].includes(t.arrayFormat)?o:p(o,t),r(p(e,t),o,a)}for(const e of Object.keys(a)){const r=a[e];if("object"==typeof r&&null!==r)for(const e of Object.keys(r))r[e]=d(r[e],t);else a[e]=d(r,t)}return!1===t.sort?a:(!0===t.sort?Object.keys(a).sort():Object.keys(a).sort(t.sort)).reduce(((e,t)=>{const r=a[t];return Boolean(r)&&"object"==typeof r&&!Array.isArray(r)?e[t]=u(r):e[t]=r,e}),Object.create(null))}t.extract=m,t.parse=f,t.stringify=(e,t)=>{if(!e)return"";i((t=Object.assign({encode:!0,strict:!0,arrayFormat:"none",arrayFormatSeparator:","},t)).arrayFormatSeparator);const r=r=>t.skipNull&&null==e[r]||t.skipEmptyString&&""===e[r],a=function(e){switch(e.arrayFormat){case"index":return t=>(r,a)=>{const n=r.length;return void 0===a||e.skipNull&&null===a||e.skipEmptyString&&""===a?r:null===a?[...r,[l(t,e),"[",n,"]"].join("")]:[...r,[l(t,e),"[",l(n,e),"]=",l(a,e)].join("")]};case"bracket":return t=>(r,a)=>void 0===a||e.skipNull&&null===a||e.skipEmptyString&&""===a?r:null===a?[...r,[l(t,e),"[]"].join("")]:[...r,[l(t,e),"[]=",l(a,e)].join("")];case"comma":case"separator":case"bracket-separator":{const t="bracket-separator"===e.arrayFormat?"[]=":"=";return r=>(a,n)=>void 0===n||e.skipNull&&null===n||e.skipEmptyString&&""===n?a:(n=null===n?"":n,0===a.length?[[l(r,e),t,l(n,e)].join("")]:[[a,l(n,e)].join(e.arrayFormatSeparator)])}default:return t=>(r,a)=>void 0===a||e.skipNull&&null===a||e.skipEmptyString&&""===a?r:null===a?[...r,l(t,e)]:[...r,[l(t,e),"=",l(a,e)].join("")]}}(t),n={};for(const t of Object.keys(e))r(t)||(n[t]=e[t]);const s=Object.keys(n);return!1!==t.sort&&s.sort(t.sort),s.map((r=>{const n=e[r];return void 0===n?"":null===n?l(r,t):Array.isArray(n)?0===n.length&&"bracket-separator"===t.arrayFormat?l(r,t)+"[]":n.reduce(a(r),[]).join("&"):l(r,t)+"="+l(n,t)})).filter((e=>e.length>0)).join("&")},t.parseUrl=(e,t)=>{t=Object.assign({decode:!0},t);const[r,a]=s(e,"#");return Object.assign({url:r.split("?")[0]||"",query:f(m(e),t)},t&&t.parseFragmentIdentifier&&a?{fragmentIdentifier:p(a,t)}:{})},t.stringifyUrl=(e,r)=>{r=Object.assign({encode:!0,strict:!0},r);const a=c(e.url).split("?")[0]||"",n=t.extract(e.url),s=t.parse(n,{sort:!1}),o=Object.assign(s,e.query);let i=t.stringify(o,r);i&&(i=`?${i}`);let p=function(e){let t="";const r=e.indexOf("#");return-1!==r&&(t=e.slice(r)),t}(e.url);return e.fragmentIdentifier&&(p=`#${l(e.fragmentIdentifier,r)}`),`${a}${i}${p}`},t.pick=(e,r,a)=>{a=Object.assign({parseFragmentIdentifier:!0},a);const{url:n,query:s,fragmentIdentifier:i}=t.parseUrl(e,a);return t.stringifyUrl({url:n,query:o(s,r),fragmentIdentifier:i},a)},t.exclude=(e,r,a)=>{const n=Array.isArray(r)?e=>!r.includes(e):(e,t)=>!r(e,t);return t.pick(e,n,a)}},500:e=>{e.exports=(e,t)=>{if("string"!=typeof e||"string"!=typeof t)throw new TypeError("Expected the arguments to be of type `string`");if(""===t)return[e];const r=e.indexOf(t);return-1===r?[e]:[e.slice(0,r),e.slice(r+t.length)]}},610:e=>{e.exports=e=>encodeURIComponent(e).replace(/[!'()*]/g,(e=>`%${e.charCodeAt(0).toString(16).toUpperCase()}`))}},t={};function r(a){var n=t[a];if(void 0!==n)return n.exports;var s=t[a]={exports:{}};return e[a](s,s.exports,r),s.exports}(()=>{var e=r(563),t=lodash.isEmpty,a=wp.components.BaseControl;const n=(0,wp.compose.withInstanceId)((function(e){var r=e.label,n=e.selected,s=e.help,o=e.instanceId,i=e.onChange,l=e.disabled,p=e.options,u=void 0===p?[]:p,c="inspector-radio-image-control-".concat(o),m=function(e){return i(e.target.value)};return!t(u)&&wp.element.createElement(a,{label:r,id:c,help:s,className:"components-radio-image-control"},wp.element.createElement("div",{className:"components-radio-image-control__container"},u.map((function(e,t){return wp.element.createElement("div",{key:"".concat(c,"-").concat(t),className:"components-radio-image-control__option"},wp.element.createElement("input",{id:"".concat(c,"-").concat(t),className:"components-radio-image-control__input",type:"radio",name:c,value:e.value,onChange:m,checked:e.value===n,"aria-describedby":s?"".concat(c,"__help"):void 0,disabled:l}),wp.element.createElement("label",{htmlFor:"".concat(c,"-").concat(t),title:e.label},wp.element.createElement("img",{src:e.src}),wp.element.createElement("span",{class:"image-clickable"})))}))))}));function s(e){return(s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){for(var r=0;r<t.length;r++){var a=t[r];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function l(e,t){return(l=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function p(e,t){return!t||"object"!==s(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function u(e){return(u=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var c=wp.i18n.__,m=wp.blockEditor||wp.editor,d=m.InspectorControls,f=m.MediaUpload,h=wp.element,y=h.Component,b=(h.Fragment,wp.components),g=b.BaseControl,v=b.ExternalLink,w=b.PanelBody,E=b.RangeControl,k=b.TextControl,C=b.Button,T=b.ToggleControl,x=b.SelectControl,z=b.ResponsiveWrapper;const N=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&l(e,t)}(h,e);var t,r,a,s,m=(a=h,s=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=u(a);if(s){var r=u(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return p(this,e)});function h(){return o(this,h),m.apply(this,arguments)}return t=h,(r=[{key:"render",value:function(){var e=this,t="";return"https"===this.props.attributes.http&&(t+=c("Please verify that the images exist on HTTPS.")),wp.element.createElement(d,{key:"inspector"},0!==this.props.attributes.status&&wp.element.createElement(w,null,wp.element.createElement(k,{label:c("Feed Source"),className:"feedzy-source",value:this.props.attributes.feeds,onChange:this.props.edit.onChangeFeed}),wp.element.createElement(C,{isLarge:!0,isPrimary:!0,type:"submit",onClick:this.props.edit.loadFeed,className:"loadFeed"},c("Load Feed"))),"fetched"===this.props.state.route&&[wp.element.createElement(w,{title:c("Feed Settings"),initialOpen:!0,className:"feedzy-options"},wp.element.createElement(E,{label:c("Number of Items"),value:Number(this.props.attributes.max)||5,onChange:this.props.edit.onChangeMax,min:1,max:this.props.attributes.feedData.items.length||10,beforeIcon:"sort",className:"feedzy-max"}),wp.element.createElement(E,{label:c("Ignore first N items"),value:Number(this.props.attributes.offset)||0,onChange:this.props.edit.onChangeOffset,min:0,max:this.props.attributes.feedData.items.length,beforeIcon:"sort",className:"feedzy-offset"}),null!==this.props.attributes.feedData.channel&&wp.element.createElement(T,{label:c("Display feed title?"),checked:!!this.props.attributes.feed_title,onChange:this.props.edit.onToggleFeedTitle,className:"feedzy-title"}),wp.element.createElement(T,{label:c("Lazy load feed?"),checked:!!this.props.attributes.lazy,onChange:this.props.edit.onToggleLazy,className:"feedzy-lazy",help:c("Only on the front end.")}),wp.element.createElement(x,{label:c("Feed Caching Time"),value:this.props.attributes.refresh,options:[{label:c("1 Hour"),value:"1_hours"},{label:c("2 Hours"),value:"3_hours"},{label:c("12 Hours"),value:"12_hours"},{label:c("1 Day"),value:"1_days"},{label:c("3 Days"),value:"3_days"},{label:c("15 Days"),value:"15_days"}],onChange:this.props.edit.onRefresh,className:"feedzy-refresh"}),wp.element.createElement(x,{label:c("Sorting Order"),value:this.props.attributes.sort,options:[{label:c("Default"),value:"default"},{label:c("Date Descending"),value:"date_desc"},{label:c("Date Ascending"),value:"date_asc"},{label:c("Title Descending"),value:"title_desc"},{label:c("Title Ascending"),value:"title_asc"}],onChange:this.props.edit.onSort,className:"feedzy-sort"})),wp.element.createElement(w,{title:c("Item Options"),initialOpen:!1,className:"feedzy-item-options"},wp.element.createElement(x,{label:c("Open Links In"),value:this.props.attributes.target,options:[{label:c("New Tab"),value:"_blank"},{label:c("Same Tab"),value:"_self"}],onChange:this.props.edit.onTarget}),wp.element.createElement(k,{label:c("Title Character Limit"),help:c("Leave empty to show full title."),type:"number",value:this.props.attributes.title,onChange:this.props.edit.onTitle,className:"feedzy-title-length"}),wp.element.createElement(g,null,wp.element.createElement(k,{label:feedzyjs.isPro?c("Should we display additional meta fields out of author, date, time or categories? (comma-separated list, in order of display)."):c("Should we display additional meta fields out of author, date or time? (comma-separated list, in order of display)."),help:c('Leave empty to display all and "no" to display nothing.'),placeholder:feedzyjs.isPro?c("(eg: author, date, time, tz=local, categories)"):c("(eg: author, date, time, tz=local)"),value:this.props.attributes.metafields,onChange:this.props.edit.onChangeMeta,className:"feedzy-meta"}),wp.element.createElement(k,{label:c("When using multiple sources, should we display additional meta fields? - source (comma-separated list)."),placeholder:c("(eg: source)"),value:this.props.attributes.multiple_meta,onChange:this.props.edit.onChangeMultipleMeta,className:"feedzy-multiple-meta"}),wp.element.createElement(v,{href:"https://docs.themeisle.com/article/1089-how-to-display-author-date-or-time-from-the-feed"},c("You can find more info about available meta field values here."))),wp.element.createElement(T,{label:c("Display post description?"),checked:!!this.props.attributes.summary,onChange:this.props.edit.onToggleSummary,className:"feedzy-summary"}),this.props.attributes.summary&&wp.element.createElement(k,{label:c("Description Character Limit"),help:c("Leave empty to show full description."),type:"number",value:this.props.attributes.summarylength,onChange:this.props.edit.onSummaryLength,className:"feedzy-summary-length"}),feedzyjs.isPro&&[wp.element.createElement(k,{label:c("Only display if title contains:"),help:c("Comma-separated list/case sensitive."),value:this.props.attributes.keywords_title,onChange:this.props.edit.onKeywordsTitle,className:"feedzy-include"}),wp.element.createElement(k,{label:c("Exclude if title contains:"),help:c("Comma-separated list/case sensitive."),value:this.props.attributes.keywords_ban,onChange:this.props.edit.onKeywordsBan,className:"feedzy-ban"})]),wp.element.createElement(w,{title:c("Item Image Options"),initialOpen:!1,className:"feedzy-image-options"},wp.element.createElement(x,{label:c("Display first image if available?"),value:this.props.attributes.thumb,options:[{label:c("Yes (without a fallback image)"),value:"auto"},{label:c("Yes (with a fallback image)"),value:"yes"},{label:c("No"),value:"no"}],onChange:this.props.edit.onThumb,className:"feedzy-thumb"}),"no"!==this.props.attributes.thumb&&["auto"!==this.props.attributes.thumb&&wp.element.createElement("div",{className:"feedzy-blocks-base-control"},wp.element.createElement("label",{className:"blocks-base-control__label",for:"inspector-media-upload"},c("Fallback image if no image is found.")),wp.element.createElement(f,{type:"image",id:"inspector-media-upload",value:this.props.attributes.default,onSelect:this.props.edit.onDefault,render:function(t){var r=t.open;return[void 0!==e.props.attributes.default&&[wp.element.createElement(z,{naturalWidth:e.props.attributes.default.width,naturalHeight:e.props.attributes.default.height},wp.element.createElement("img",{src:e.props.attributes.default.url,alt:c("Featured image")})),wp.element.createElement(C,{isLarge:!0,isSecondary:!0,onClick:function(){return e.props.setAttributes({default:void 0})},style:{marginTop:"10px"}},c("Remove Image"))],wp.element.createElement(C,{isLarge:!0,isPrimary:!0,onClick:r,style:{marginTop:"10px"},className:void 0===e.props.attributes.default&&"feedzy_image_upload"},c("Upload Image"))]}})),wp.element.createElement(k,{label:c("Thumbnails dimension."),type:"number",value:this.props.attributes.size,onChange:this.props.edit.onSize}),wp.element.createElement(x,{label:c("How should we treat HTTP images?"),value:this.props.attributes.http,options:[{label:c("Show with HTTP link"),value:"auto"},{label:c("Force HTTPS"),value:"https"},{label:c("Ignore and show the default image instead"),value:"default"}],onChange:this.props.edit.onHTTP,className:"feedzy-http",help:t})]),feedzyjs.isPro&&wp.element.createElement(w,{title:c("Pro Features"),initialOpen:!1,className:"feedzy-pro-options"},wp.element.createElement(T,{label:c("Display price if available?"),help:this.props.attributes.price&&"default"===this.props.attributes.template?c("Choose a different template for this to work."):null,checked:!!this.props.attributes.price,onChange:this.props.edit.onTogglePrice,className:"feedzy-pro-price"}),wp.element.createElement(k,{label:c("Referral URL parameters."),help:c('Without ("?")'),placeholder:_("(eg. promo_code=feedzy_is_awesome)"),value:this.props.attributes.referral_url,onChange:this.props.edit.onReferralURL}),wp.element.createElement(E,{label:c("Columns"),help:c("How many columns we should use to display the feed items?"),value:this.props.attributes.columns||1,onChange:this.props.edit.onColumns,min:1,max:6,beforeIcon:"sort",allowReset:!0}),wp.element.createElement(n,{label:c("Feed Template"),selected:this.props.attributes.template,options:[{label:c("Default"),src:feedzyjs.imagepath+"feedzy-default-template.jpg",value:"default"},{label:c("Style 1"),src:feedzyjs.imagepath+"feedzy-style1-template.jpg",value:"style1"},{label:c("Style 2"),src:feedzyjs.imagepath+"feedzy-style2-template.jpg",value:"style2"}],onChange:this.props.edit.onTemplate,className:"feedzy-pro-template"}))])}}])&&i(t.prototype,r),h}(y);var S=function(e){var t=document.createElement("div");return t.innerHTML=e,void 0!==t.innerText?t.innerText:t.textContent};function O(e){return(O="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function F(){return(F=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var a in r)Object.prototype.hasOwnProperty.call(r,a)&&(e[a]=r[a])}return e}).apply(this,arguments)}function j(e,t,r,a,n,s,o){try{var i=e[s](o),l=i.value}catch(e){return void r(e)}i.done?t(l):Promise.resolve(l).then(a,n)}function R(e){return function(){var t=this,r=arguments;return new Promise((function(a,n){var s=e.apply(t,r);function o(e){j(s,a,n,o,i,"next",e)}function i(e){j(s,a,n,o,i,"throw",e)}o(void 0)}))}}function A(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function L(e,t){for(var r=0;r<t.length;r++){var a=t[r];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function P(e,t){return(P=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function I(e,t){return!t||"object"!==O(t)&&"function"!=typeof t?D(e):t}function D(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function U(e){return(U=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var M=wp.i18n.__,B=wp,H=(B.apiFetch,B.apiRequest),$=wp.element,K=$.Component,Y=($.Fragment,wp.components),V=Y.ExternalLink,q=Y.Placeholder,W=Y.TextControl,Q=Y.Button,G=Y.Spinner;wp.date.date;const J=function(t){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&P(e,t)}(p,t);var r,a,n,s,o,i,l=(o=p,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=U(o);if(i){var r=U(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return I(this,e)});function p(){var e;return A(this,p),(e=l.apply(this,arguments)).loadFeed=e.loadFeed.bind(D(e)),e.loadCategories=e.loadCategories.bind(D(e)),e.metaExists=e.metaExists.bind(D(e)),e.multipleMetaExists=e.multipleMetaExists.bind(D(e)),e.getImageURL=e.getImageURL.bind(D(e)),e.getValidateURL=e.getValidateURL.bind(D(e)),e.onChangeFeed=e.onChangeFeed.bind(D(e)),e.onChangeMax=e.onChangeMax.bind(D(e)),e.onChangeOffset=e.onChangeOffset.bind(D(e)),e.onToggleFeedTitle=e.onToggleFeedTitle.bind(D(e)),e.onRefresh=e.onRefresh.bind(D(e)),e.onSort=e.onSort.bind(D(e)),e.onTarget=e.onTarget.bind(D(e)),e.onTitle=e.onTitle.bind(D(e)),e.onChangeMeta=e.onChangeMeta.bind(D(e)),e.onChangeMultipleMeta=e.onChangeMultipleMeta.bind(D(e)),e.onToggleSummary=e.onToggleSummary.bind(D(e)),e.onToggleLazy=e.onToggleLazy.bind(D(e)),e.onSummaryLength=e.onSummaryLength.bind(D(e)),e.onKeywordsTitle=e.onKeywordsTitle.bind(D(e)),e.onKeywordsBan=e.onKeywordsBan.bind(D(e)),e.onThumb=e.onThumb.bind(D(e)),e.onDefault=e.onDefault.bind(D(e)),e.onSize=e.onSize.bind(D(e)),e.onHTTP=e.onHTTP.bind(D(e)),e.onReferralURL=e.onReferralURL.bind(D(e)),e.onColumns=e.onColumns.bind(D(e)),e.onTemplate=e.onTemplate.bind(D(e)),e.onTogglePrice=e.onTogglePrice.bind(D(e)),e.state={route:e.props.attributes.route,loading:!1,error:!1},e}return r=p,(a=[{key:"componentDidMount",value:(s=R(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:this.loadFeed(),void 0===this.props.attributes.categories&&(this.props.attributes.meta||this.props.setAttributes({meta:!0,metafields:"no"}),this.loadCategories());case 2:case"end":return e.stop()}}),e,this)}))),function(){return s.apply(this,arguments)})},{key:"componentDidUpdate",value:(n=R(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:"reload"===this.state.route&&this.loadFeed();case 1:case"end":return e.stop()}}),e,this)}))),function(e){return n.apply(this,arguments)})},{key:"loadFeed",value:function(){var t=this,r=this.props.attributes.feeds;if(void 0!==r){if(function(e,t){if(void 0===t)return!1;for(var r=!1,a=0;a<t.length;a++)if(t[a]===e){r=!0;break}return r}(r,this.props.attributes.categories)){var a=r;r=e.stringify({category:a},{arrayFormat:"bracket"})}else r=r.replace(/\s/g,"").split(",").filter((function(e){return""!==e})),r=e.stringify({url:r},{arrayFormat:"bracket"});this.setState({route:"home",loading:!0}),H({path:"/feedzy/v1/feed?".concat(r),method:"POST",data:this.props.attributes}).then((function(e){return t.unmounting?e:e.error?(t.setState({route:"home",loading:!1,error:!0}),e):(t.props.setAttributes({feedData:e}),t.setState({route:"fetched",loading:!1}),e)})).fail((function(e){return t.setState({route:"home",loading:!1,error:!0}),e}))}}},{key:"loadCategories",value:function(){var e=this;H({path:"/wp/v2/feedzy_categories"}).then((function(t){if(e.unmounting)return t;var r=0,a=[];t.forEach((function(e){a[r]=e.slug,r+=1}));var n=e;n.props.setAttributes({categories:a}),jQuery(".feedzy-source input").autocomplete({source:a,select:function(e,t){n.props.setAttributes({feeds:t.item.label})}})})).fail((function(e){return e}))}},{key:"metaExists",value:function(e){return 0<=this.props.attributes.metafields.replace(/\s/g,"").split(",").indexOf(e)||""===this.props.attributes.metafields}},{key:"multipleMetaExists",value:function(e){return 0<=this.props.attributes.multiple_meta.replace(/\s/g,"").split(",").indexOf(e)||""===this.props.attributes.multiple_meta}},{key:"getImageURL",value:function(e,t){var r=e.thumbnail?e.thumbnail:this.props.attributes.default?this.props.attributes.default.url:feedzyjs.imagepath+"feedzy.svg";switch(this.props.attributes.http){case"default":-1===r.indexOf("https")&&0===r.indexOf("http")&&(r=this.props.attributes.default?this.props.attributes.default.url:feedzyjs.imagepath+"feedzy.svg");break;case"https":r=r.replace(/http:/g,"https:")}return t&&(r="url("+r+")"),r}},{key:"onChangeFeed",value:function(e){this.props.setAttributes({feeds:e})}},{key:"onChangeMax",value:function(e){this.props.setAttributes({max:e?Number(e):5})}},{key:"onChangeOffset",value:function(e){this.props.setAttributes({offset:Number(e)})}},{key:"onToggleFeedTitle",value:function(e){this.props.setAttributes({feed_title:!this.props.attributes.feed_title})}},{key:"onRefresh",value:function(e){this.props.setAttributes({refresh:e})}},{key:"onSort",value:function(e){this.props.setAttributes({sort:e})}},{key:"onTarget",value:function(e){this.props.setAttributes({target:e})}},{key:"onTitle",value:function(e){this.props.setAttributes({title:Number(e)})}},{key:"onChangeMeta",value:function(e){this.props.setAttributes({metafields:e})}},{key:"onChangeMultipleMeta",value:function(e){this.props.setAttributes({multiple_meta:e})}},{key:"onToggleSummary",value:function(e){this.props.setAttributes({summary:!this.props.attributes.summary})}},{key:"onToggleLazy",value:function(e){this.props.setAttributes({lazy:!this.props.attributes.lazy})}},{key:"onSummaryLength",value:function(e){this.props.setAttributes({summarylength:Number(e)})}},{key:"onKeywordsTitle",value:function(e){this.props.setAttributes({keywords_title:e})}},{key:"onKeywordsBan",value:function(e){this.props.setAttributes({keywords_ban:e})}},{key:"onThumb",value:function(e){this.props.setAttributes({thumb:e})}},{key:"onDefault",value:function(e){this.props.setAttributes({default:e}),this.setState({route:"reload"})}},{key:"onSize",value:function(e){this.props.setAttributes({size:e?Number(e):150})}},{key:"onHTTP",value:function(e){this.props.setAttributes({http:e}),this.setState({route:"reload"})}},{key:"onReferralURL",value:function(e){this.props.setAttributes({referral_url:e})}},{key:"onColumns",value:function(e){this.props.setAttributes({columns:e})}},{key:"onTemplate",value:function(e){this.props.setAttributes({template:e})}},{key:"onTogglePrice",value:function(e){this.props.setAttributes({price:!this.props.attributes.price})}},{key:"getValidateURL",value:function(){var e="https://validator.w3.org/feed/";return this.props.attributes.feeds&&(e+="check.cgi?url="+this.props.attributes.feeds),e}},{key:"render",value:function(){var e,t,r,a,n,s,o=this;return["fetched"===this.state.route&&wp.element.createElement(N,F({edit:this,state:this.state},this.props)),"home"===this.state.route&&wp.element.createElement("div",{className:this.props.className},wp.element.createElement(q,{key:"placeholder",icon:"rss",label:M("Feedzy RSS Feeds")},this.state.loading?wp.element.createElement("div",{key:"loading",className:"wp-block-embed is-loading"},wp.element.createElement(G,null),wp.element.createElement("p",null,M("Fetching..."))):[wp.element.createElement(W,{type:"url",className:"feedzy-source",placeholder:M("Enter URL or category of your feed here..."),onChange:this.onChangeFeed,value:this.props.attributes.feeds}),wp.element.createElement(Q,{isLarge:!0,isPrimary:!0,type:"submit",onClick:this.loadFeed},M("Load Feed")),wp.element.createElement(V,{href:this.getValidateURL(),title:M("Validate Feed ")},M("Validate ")),this.state.error&&wp.element.createElement("div",null,M("Feed URL is invalid. Invalid feeds will NOT display items."))])),!("fetched"!==this.state.route||void 0===this.props.attributes.feedData)&&wp.element.createElement("div",{className:"feedzy-rss"},this.props.attributes.feed_title&&null!==this.props.attributes.feedData.channel&&wp.element.createElement("div",{className:"rss_header"},wp.element.createElement("h2",null,wp.element.createElement("a",{className:"rss_title"},S(this.props.attributes.feedData.channel.title)),wp.element.createElement("span",{className:"rss_description"}," "+S(this.props.attributes.feedData.channel.description)))),wp.element.createElement("ul",{className:"feedzy-".concat(this.props.attributes.template)},(e=this.props.attributes.feedData.items,t=this.props.attributes.sort,r=this.props.attributes.keywords_title,a=this.props.attributes.keywords_ban,n=this.props.attributes.max,s=this.props.attributes.offset,e=Array.from(e).sort((function(e,r){var a,n;return"date_desc"===t||"date_asc"===t?(a=e.pubDate,n=r.pubDate):"title_desc"!==t&&"title_asc"!==t||(a=e.title.toUpperCase(),n=r.title.toUpperCase()),a<n?"date_desc"===t||"title_desc"===t?1:-1:a>n?"date_desc"===t||"title_desc"===t?-1:1:0})).filter((function(e){return!r||r.split(",").filter((function(e){return""!==e.replace(/\s/g,"")})).some((function(t){return e.title.includes(t.trim())}))})).filter((function(e){return!a||a.split(",").filter((function(e){return""!==e.replace(/\s/g,"")})).every((function(t){return!1===e.title.includes(t.trim())}))})).slice(s,n+s)).map((function(e,t){var r=(e.date||"")+" "+(e.time||"")+" UTC +0000",a=S(e.date)||"",n=S(e.time)||"",s=S(e.categories)||"";if(o.metaExists("tz=local")){var i=new Date(r);i=i.toUTCString(),a=moment.utc(i).format("MMMM D, YYYY"),n=moment.utc(i).format("h:mm A")}var l=e.creator&&o.metaExists("author")?e.creator:"";""!==o.props.attributes.multiple_meta&&"no"!==o.props.attributes.multiple_meta&&((o.multipleMetaExists("source")||o.multipleMetaExists("yes"))&&""!==l&&""!==e.source?l=l+" ("+e.source+")":(o.multipleMetaExists("source")||o.multipleMetaExists("yes"))&&""!==e.source&&(l=e.source));var p=new Object;return p.author=M("by")+" "+l,p.date=M("on")+" "+S(a),p.time=M("at")+" "+S(n),p.categories=M("in")+" "+S(s),wp.element.createElement("li",{key:t,style:{padding:"15px 0 25px"},className:"rss_item feedzy-rss-col-".concat(o.props.attributes.columns)},(e.thumbnail&&"auto"===o.props.attributes.thumb||"yes"===o.props.attributes.thumb)&&wp.element.createElement("div",{className:"rss_image",style:{width:o.props.attributes.size+"px",height:o.props.attributes.size+"px"}},wp.element.createElement("a",{title:S(e.title),style:{width:o.props.attributes.size+"px",height:o.props.attributes.size+"px"}},wp.element.createElement("span",{className:"fetched",style:{width:o.props.attributes.size+"px",height:o.props.attributes.size+"px",backgroundImage:o.getImageURL(e,!0)},title:S(e.title)}))),wp.element.createElement("div",{className:"rss_content_wrap"},wp.element.createElement("span",{className:"title"},wp.element.createElement("a",null,o.props.attributes.title&&S(e.title).length>o.props.attributes.title?S(e.title).substring(0,o.props.attributes.title)+"...":S(e.title))),wp.element.createElement("div",{className:"rss_content"},"no"!==o.props.attributes.metafields&&wp.element.createElement("small",{className:"meta"},function(e,t){var r="";""===t&&(t="author, date, time");for(var a=t.replace(/\s/g,"").split(","),n=0;n<a.length;n++)void 0!==e[a[n]]&&(r=r+" "+e[a[n]]);return r}(p,o.props.attributes.metafields)),o.props.attributes.summary&&wp.element.createElement("p",{className:"description"},o.props.attributes.summarylength&&S(e.description).length>o.props.attributes.summarylength?S(e.description).substring(0,o.props.attributes.summarylength)+" [...]":S(e.description)),feedzyjs.isPro&&e.media&&e.media.src&&wp.element.createElement("audio",{controls:!0,controlsList:"nodownload"},wp.element.createElement("source",{src:e.media.src,type:e.media.type}),M("Your browser does not support the audio element. But you can check this for the original link: "),wp.element.createElement("a",{href:e.media.src},e.media.src)),feedzyjs.isPro&&o.props.attributes.price&&e.price&&"default"!==o.props.attributes.template&&wp.element.createElement("div",{className:"price-wrap"},wp.element.createElement("a",null,wp.element.createElement("button",{className:"price"},e.price))))))}))))]}}])&&L(r.prototype,a),p}(K);var X=wp.i18n.__;(0,wp.blocks.registerBlockType)("feedzy-rss-feeds/feedzy-block",{title:X("Feedzy RSS Feeds"),category:"common",icon:"rss",keywords:[X("Feedzy RSS Feeds"),X("RSS"),X("Feeds")],supports:{html:!1},attributes:{feeds:{type:"string"},max:{type:"number",default:5},offset:{type:"number",default:0},feed_title:{type:"boolean",default:!0},refresh:{type:"string",default:"12_hours"},sort:{type:"string",default:"default"},target:{type:"string",default:"_blank"},title:{type:"number"},meta:{type:"boolean",default:!0},lazy:{type:"boolean",default:!1},metafields:{type:"string",default:""},multiple_meta:{type:"string",default:""},summary:{type:"boolean",default:!0},summarylength:{type:"number"},keywords_title:{type:"string"},keywords_ban:{type:"string"},thumb:{type:"string",default:"auto"},default:{type:"object"},size:{type:"number",default:150},http:{type:"string"},referral_url:{type:"string"},columns:{type:"number",default:1},template:{type:"string",default:"default"},price:{type:"boolean",default:!0},route:{type:"string",default:"home"},feedData:{type:"object"},categories:{type:"object"}},edit:J,save:function(){return null}})})()})();
|
1 |
+
(()=>{"use strict";var e={20:e=>{var t="%[a-f0-9]{2}",r=new RegExp(t,"gi"),a=new RegExp("("+t+")+","gi");function n(e,t){try{return decodeURIComponent(e.join(""))}catch(e){}if(1===e.length)return e;t=t||1;var r=e.slice(0,t),a=e.slice(t);return Array.prototype.concat.call([],n(r),n(a))}function s(e){try{return decodeURIComponent(e)}catch(s){for(var t=e.match(r),a=1;a<t.length;a++)t=(e=n(t,a).join("")).match(r);return e}}e.exports=function(e){if("string"!=typeof e)throw new TypeError("Expected `encodedURI` to be of type `string`, got `"+typeof e+"`");try{return e=e.replace(/\+/g," "),decodeURIComponent(e)}catch(t){return function(e){for(var t={"%FE%FF":"��","%FF%FE":"��"},r=a.exec(e);r;){try{t[r[0]]=decodeURIComponent(r[0])}catch(e){var n=s(r[0]);n!==r[0]&&(t[r[0]]=n)}r=a.exec(e)}t["%C2"]="�";for(var o=Object.keys(t),i=0;i<o.length;i++){var l=o[i];e=e.replace(new RegExp(l,"g"),t[l])}return e}(e)}}},806:e=>{e.exports=function(e,t){for(var r={},a=Object.keys(e),n=Array.isArray(t),s=0;s<a.length;s++){var o=a[s],i=e[o];(n?-1!==t.indexOf(o):t(o,i,e))&&(r[o]=i)}return r}},563:(e,t,r)=>{const a=r(610),n=r(20),s=r(500),o=r(806);function i(e){if("string"!=typeof e||1!==e.length)throw new TypeError("arrayFormatSeparator must be single character string")}function l(e,t){return t.encode?t.strict?a(e):encodeURIComponent(e):e}function p(e,t){return t.decode?n(e):e}function u(e){return Array.isArray(e)?e.sort():"object"==typeof e?u(Object.keys(e)).sort(((e,t)=>Number(e)-Number(t))).map((t=>e[t])):e}function c(e){const t=e.indexOf("#");return-1!==t&&(e=e.slice(0,t)),e}function m(e){const t=(e=c(e)).indexOf("?");return-1===t?"":e.slice(t+1)}function d(e,t){return t.parseNumbers&&!Number.isNaN(Number(e))&&"string"==typeof e&&""!==e.trim()?e=Number(e):!t.parseBooleans||null===e||"true"!==e.toLowerCase()&&"false"!==e.toLowerCase()||(e="true"===e.toLowerCase()),e}function f(e,t){i((t=Object.assign({decode:!0,sort:!0,arrayFormat:"none",arrayFormatSeparator:",",parseNumbers:!1,parseBooleans:!1},t)).arrayFormatSeparator);const r=function(e){let t;switch(e.arrayFormat){case"index":return(e,r,a)=>{t=/\[(\d*)\]$/.exec(e),e=e.replace(/\[\d*\]$/,""),t?(void 0===a[e]&&(a[e]={}),a[e][t[1]]=r):a[e]=r};case"bracket":return(e,r,a)=>{t=/(\[\])$/.exec(e),e=e.replace(/\[\]$/,""),t?void 0!==a[e]?a[e]=[].concat(a[e],r):a[e]=[r]:a[e]=r};case"comma":case"separator":return(t,r,a)=>{const n="string"==typeof r&&r.includes(e.arrayFormatSeparator),s="string"==typeof r&&!n&&p(r,e).includes(e.arrayFormatSeparator);r=s?p(r,e):r;const o=n||s?r.split(e.arrayFormatSeparator).map((t=>p(t,e))):null===r?r:p(r,e);a[t]=o};case"bracket-separator":return(t,r,a)=>{const n=/(\[\])$/.test(t);if(t=t.replace(/\[\]$/,""),!n)return void(a[t]=r?p(r,e):r);const s=null===r?[]:r.split(e.arrayFormatSeparator).map((t=>p(t,e)));void 0!==a[t]?a[t]=[].concat(a[t],s):a[t]=s};default:return(e,t,r)=>{void 0!==r[e]?r[e]=[].concat(r[e],t):r[e]=t}}}(t),a=Object.create(null);if("string"!=typeof e)return a;if(!(e=e.trim().replace(/^[?#&]/,"")))return a;for(const n of e.split("&")){if(""===n)continue;let[e,o]=s(t.decode?n.replace(/\+/g," "):n,"=");o=void 0===o?null:["comma","separator","bracket-separator"].includes(t.arrayFormat)?o:p(o,t),r(p(e,t),o,a)}for(const e of Object.keys(a)){const r=a[e];if("object"==typeof r&&null!==r)for(const e of Object.keys(r))r[e]=d(r[e],t);else a[e]=d(r,t)}return!1===t.sort?a:(!0===t.sort?Object.keys(a).sort():Object.keys(a).sort(t.sort)).reduce(((e,t)=>{const r=a[t];return Boolean(r)&&"object"==typeof r&&!Array.isArray(r)?e[t]=u(r):e[t]=r,e}),Object.create(null))}t.extract=m,t.parse=f,t.stringify=(e,t)=>{if(!e)return"";i((t=Object.assign({encode:!0,strict:!0,arrayFormat:"none",arrayFormatSeparator:","},t)).arrayFormatSeparator);const r=r=>t.skipNull&&null==e[r]||t.skipEmptyString&&""===e[r],a=function(e){switch(e.arrayFormat){case"index":return t=>(r,a)=>{const n=r.length;return void 0===a||e.skipNull&&null===a||e.skipEmptyString&&""===a?r:null===a?[...r,[l(t,e),"[",n,"]"].join("")]:[...r,[l(t,e),"[",l(n,e),"]=",l(a,e)].join("")]};case"bracket":return t=>(r,a)=>void 0===a||e.skipNull&&null===a||e.skipEmptyString&&""===a?r:null===a?[...r,[l(t,e),"[]"].join("")]:[...r,[l(t,e),"[]=",l(a,e)].join("")];case"comma":case"separator":case"bracket-separator":{const t="bracket-separator"===e.arrayFormat?"[]=":"=";return r=>(a,n)=>void 0===n||e.skipNull&&null===n||e.skipEmptyString&&""===n?a:(n=null===n?"":n,0===a.length?[[l(r,e),t,l(n,e)].join("")]:[[a,l(n,e)].join(e.arrayFormatSeparator)])}default:return t=>(r,a)=>void 0===a||e.skipNull&&null===a||e.skipEmptyString&&""===a?r:null===a?[...r,l(t,e)]:[...r,[l(t,e),"=",l(a,e)].join("")]}}(t),n={};for(const t of Object.keys(e))r(t)||(n[t]=e[t]);const s=Object.keys(n);return!1!==t.sort&&s.sort(t.sort),s.map((r=>{const n=e[r];return void 0===n?"":null===n?l(r,t):Array.isArray(n)?0===n.length&&"bracket-separator"===t.arrayFormat?l(r,t)+"[]":n.reduce(a(r),[]).join("&"):l(r,t)+"="+l(n,t)})).filter((e=>e.length>0)).join("&")},t.parseUrl=(e,t)=>{t=Object.assign({decode:!0},t);const[r,a]=s(e,"#");return Object.assign({url:r.split("?")[0]||"",query:f(m(e),t)},t&&t.parseFragmentIdentifier&&a?{fragmentIdentifier:p(a,t)}:{})},t.stringifyUrl=(e,r)=>{r=Object.assign({encode:!0,strict:!0},r);const a=c(e.url).split("?")[0]||"",n=t.extract(e.url),s=t.parse(n,{sort:!1}),o=Object.assign(s,e.query);let i=t.stringify(o,r);i&&(i=`?${i}`);let p=function(e){let t="";const r=e.indexOf("#");return-1!==r&&(t=e.slice(r)),t}(e.url);return e.fragmentIdentifier&&(p=`#${l(e.fragmentIdentifier,r)}`),`${a}${i}${p}`},t.pick=(e,r,a)=>{a=Object.assign({parseFragmentIdentifier:!0},a);const{url:n,query:s,fragmentIdentifier:i}=t.parseUrl(e,a);return t.stringifyUrl({url:n,query:o(s,r),fragmentIdentifier:i},a)},t.exclude=(e,r,a)=>{const n=Array.isArray(r)?e=>!r.includes(e):(e,t)=>!r(e,t);return t.pick(e,n,a)}},500:e=>{e.exports=(e,t)=>{if("string"!=typeof e||"string"!=typeof t)throw new TypeError("Expected the arguments to be of type `string`");if(""===t)return[e];const r=e.indexOf(t);return-1===r?[e]:[e.slice(0,r),e.slice(r+t.length)]}},610:e=>{e.exports=e=>encodeURIComponent(e).replace(/[!'()*]/g,(e=>`%${e.charCodeAt(0).toString(16).toUpperCase()}`))}},t={};function r(a){var n=t[a];if(void 0!==n)return n.exports;var s=t[a]={exports:{}};return e[a](s,s.exports,r),s.exports}(()=>{var e=r(563),t=lodash.isEmpty,a=wp.components.BaseControl;const n=(0,wp.compose.withInstanceId)((function(e){var r=e.label,n=e.selected,s=e.help,o=e.instanceId,i=e.onChange,l=e.disabled,p=e.options,u=void 0===p?[]:p,c="inspector-radio-image-control-".concat(o),m=function(e){return i(e.target.value)};return!t(u)&&wp.element.createElement(a,{label:r,id:c,help:s,className:"components-radio-image-control"},wp.element.createElement("div",{className:"components-radio-image-control__container"},u.map((function(e,t){return wp.element.createElement("div",{key:"".concat(c,"-").concat(t),className:"components-radio-image-control__option"},wp.element.createElement("input",{id:"".concat(c,"-").concat(t),className:"components-radio-image-control__input",type:"radio",name:c,value:e.value,onChange:m,checked:e.value===n,"aria-describedby":s?"".concat(c,"__help"):void 0,disabled:l}),wp.element.createElement("label",{htmlFor:"".concat(c,"-").concat(t),title:e.label},wp.element.createElement("img",{src:e.src}),wp.element.createElement("span",{class:"image-clickable"})))}))))}));function s(e){return(s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){for(var r=0;r<t.length;r++){var a=t[r];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function l(e,t){return(l=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function p(e,t){return!t||"object"!==s(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function u(e){return(u=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var c=wp.i18n.__,m=wp.blockEditor||wp.editor,d=m.InspectorControls,f=m.MediaUpload,h=wp.element,y=h.Component,b=(h.Fragment,wp.components),g=b.BaseControl,v=b.ExternalLink,w=b.PanelBody,E=b.RangeControl,k=b.TextControl,C=b.Button,T=b.ToggleControl,x=b.SelectControl,z=b.ResponsiveWrapper;const N=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&l(e,t)}(h,e);var t,r,a,s,m=(a=h,s=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=u(a);if(s){var r=u(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return p(this,e)});function h(){return o(this,h),m.apply(this,arguments)}return t=h,(r=[{key:"render",value:function(){var e=this,t="";return"https"===this.props.attributes.http&&(t+=c("Please verify that the images exist on HTTPS.")),wp.element.createElement(d,{key:"inspector"},0!==this.props.attributes.status&&wp.element.createElement(w,null,wp.element.createElement(k,{label:c("Feed Source"),className:"feedzy-source",value:this.props.attributes.feeds,onChange:this.props.edit.onChangeFeed}),wp.element.createElement(C,{isLarge:!0,isPrimary:!0,type:"submit",onClick:this.props.edit.loadFeed,className:"loadFeed"},c("Load Feed"))),"fetched"===this.props.state.route&&[wp.element.createElement(w,{title:c("Feed Settings"),initialOpen:!0,className:"feedzy-options"},wp.element.createElement(E,{label:c("Number of Items"),value:Number(this.props.attributes.max)||5,onChange:this.props.edit.onChangeMax,min:1,max:this.props.attributes.feedData.items.length||10,beforeIcon:"sort",className:"feedzy-max"}),wp.element.createElement(E,{label:c("Ignore first N items"),value:Number(this.props.attributes.offset)||0,onChange:this.props.edit.onChangeOffset,min:0,max:this.props.attributes.feedData.items.length,beforeIcon:"sort",className:"feedzy-offset"}),null!==this.props.attributes.feedData.channel&&wp.element.createElement(T,{label:c("Display feed title?"),checked:!!this.props.attributes.feed_title,onChange:this.props.edit.onToggleFeedTitle,className:"feedzy-title"}),wp.element.createElement(T,{label:c("Lazy load feed?"),checked:!!this.props.attributes.lazy,onChange:this.props.edit.onToggleLazy,className:"feedzy-lazy",help:c("Only on the front end.")}),wp.element.createElement(x,{label:c("Feed Caching Time"),value:this.props.attributes.refresh,options:[{label:c("1 Hour"),value:"1_hours"},{label:c("2 Hours"),value:"3_hours"},{label:c("12 Hours"),value:"12_hours"},{label:c("1 Day"),value:"1_days"},{label:c("3 Days"),value:"3_days"},{label:c("15 Days"),value:"15_days"}],onChange:this.props.edit.onRefresh,className:"feedzy-refresh"}),wp.element.createElement(x,{label:c("Sorting Order"),value:this.props.attributes.sort,options:[{label:c("Default"),value:"default"},{label:c("Date Descending"),value:"date_desc"},{label:c("Date Ascending"),value:"date_asc"},{label:c("Title Descending"),value:"title_desc"},{label:c("Title Ascending"),value:"title_asc"}],onChange:this.props.edit.onSort,className:"feedzy-sort"})),wp.element.createElement(w,{title:c("Item Options"),initialOpen:!1,className:"feedzy-item-options"},wp.element.createElement(x,{label:c("Open Links In"),value:this.props.attributes.target,options:[{label:c("New Tab"),value:"_blank"},{label:c("Same Tab"),value:"_self"}],onChange:this.props.edit.onTarget}),wp.element.createElement(k,{label:c("Title Character Limit"),help:c("Leave empty to show full title."),type:"number",value:this.props.attributes.title,onChange:this.props.edit.onTitle,className:"feedzy-title-length",min:0}),wp.element.createElement(g,null,wp.element.createElement(k,{label:feedzyjs.isPro?c("Should we display additional meta fields out of author, date, time or categories? (comma-separated list, in order of display)."):c("Should we display additional meta fields out of author, date or time? (comma-separated list, in order of display)."),help:c('Leave empty to display all and "no" to display nothing.'),placeholder:feedzyjs.isPro?c("(eg: author, date, time, tz=local, categories)"):c("(eg: author, date, time, tz=local)"),value:this.props.attributes.metafields,onChange:this.props.edit.onChangeMeta,className:"feedzy-meta"}),wp.element.createElement(k,{label:c("When using multiple sources, should we display additional meta fields? - source (comma-separated list)."),placeholder:c("(eg: source)"),value:this.props.attributes.multiple_meta,onChange:this.props.edit.onChangeMultipleMeta,className:"feedzy-multiple-meta"}),wp.element.createElement(v,{href:"https://docs.themeisle.com/article/1089-how-to-display-author-date-or-time-from-the-feed"},c("You can find more info about available meta field values here."))),wp.element.createElement(T,{label:c("Display post description?"),checked:!!this.props.attributes.summary,onChange:this.props.edit.onToggleSummary,className:"feedzy-summary"}),this.props.attributes.summary&&wp.element.createElement(k,{label:c("Description Character Limit"),help:c("Leave empty to show full description."),type:"number",value:this.props.attributes.summarylength,onChange:this.props.edit.onSummaryLength,className:"feedzy-summary-length",min:0}),feedzyjs.isPro&&[wp.element.createElement(k,{label:c("Only display if title contains:"),help:c("Comma-separated list/case sensitive."),value:this.props.attributes.keywords_title,onChange:this.props.edit.onKeywordsTitle,className:"feedzy-include"}),wp.element.createElement(k,{label:c("Exclude if title contains:"),help:c("Comma-separated list/case sensitive."),value:this.props.attributes.keywords_ban,onChange:this.props.edit.onKeywordsBan,className:"feedzy-ban"})]),wp.element.createElement(w,{title:c("Item Image Options"),initialOpen:!1,className:"feedzy-image-options"},wp.element.createElement(x,{label:c("Display first image if available?"),value:this.props.attributes.thumb,options:[{label:c("Yes (without a fallback image)"),value:"auto"},{label:c("Yes (with a fallback image)"),value:"yes"},{label:c("No"),value:"no"}],onChange:this.props.edit.onThumb,className:"feedzy-thumb"}),"no"!==this.props.attributes.thumb&&["auto"!==this.props.attributes.thumb&&wp.element.createElement("div",{className:"feedzy-blocks-base-control"},wp.element.createElement("label",{className:"blocks-base-control__label",for:"inspector-media-upload"},c("Fallback image if no image is found.")),wp.element.createElement(f,{type:"image",id:"inspector-media-upload",value:this.props.attributes.default,onSelect:this.props.edit.onDefault,render:function(t){var r=t.open;return[void 0!==e.props.attributes.default&&[wp.element.createElement(z,{naturalWidth:e.props.attributes.default.width,naturalHeight:e.props.attributes.default.height},wp.element.createElement("img",{src:e.props.attributes.default.url,alt:c("Featured image")})),wp.element.createElement(C,{isLarge:!0,isSecondary:!0,onClick:function(){return e.props.setAttributes({default:void 0})},style:{marginTop:"10px"}},c("Remove Image"))],wp.element.createElement(C,{isLarge:!0,isPrimary:!0,onClick:r,style:{marginTop:"10px"},className:void 0===e.props.attributes.default&&"feedzy_image_upload"},c("Upload Image"))]}})),wp.element.createElement(k,{label:c("Thumbnails dimension."),type:"number",value:this.props.attributes.size,onChange:this.props.edit.onSize}),wp.element.createElement(x,{label:c("How should we treat HTTP images?"),value:this.props.attributes.http,options:[{label:c("Show with HTTP link"),value:"auto"},{label:c("Force HTTPS"),value:"https"},{label:c("Ignore and show the default image instead"),value:"default"}],onChange:this.props.edit.onHTTP,className:"feedzy-http",help:t})]),feedzyjs.isPro&&wp.element.createElement(w,{title:c("Pro Features"),initialOpen:!1,className:"feedzy-pro-options"},wp.element.createElement(T,{label:c("Display price if available?"),help:this.props.attributes.price&&"default"===this.props.attributes.template?c("Choose a different template for this to work."):null,checked:!!this.props.attributes.price,onChange:this.props.edit.onTogglePrice,className:"feedzy-pro-price"}),wp.element.createElement(k,{label:c("Referral URL parameters."),help:c('Without ("?")'),placeholder:_("(eg. promo_code=feedzy_is_awesome)"),value:this.props.attributes.referral_url,onChange:this.props.edit.onReferralURL}),wp.element.createElement(E,{label:c("Columns"),help:c("How many columns we should use to display the feed items?"),value:this.props.attributes.columns||1,onChange:this.props.edit.onColumns,min:1,max:6,beforeIcon:"sort",allowReset:!0}),wp.element.createElement(n,{label:c("Feed Template"),selected:this.props.attributes.template,options:[{label:c("Default"),src:feedzyjs.imagepath+"feedzy-default-template.jpg",value:"default"},{label:c("Style 1"),src:feedzyjs.imagepath+"feedzy-style1-template.jpg",value:"style1"},{label:c("Style 2"),src:feedzyjs.imagepath+"feedzy-style2-template.jpg",value:"style2"}],onChange:this.props.edit.onTemplate,className:"feedzy-pro-template"}))])}}])&&i(t.prototype,r),h}(y);var S=function(e){var t=document.createElement("div");return t.innerHTML=e,void 0!==t.innerText?t.innerText:t.textContent};function O(e){return(O="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function F(){return(F=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var a in r)Object.prototype.hasOwnProperty.call(r,a)&&(e[a]=r[a])}return e}).apply(this,arguments)}function j(e,t,r,a,n,s,o){try{var i=e[s](o),l=i.value}catch(e){return void r(e)}i.done?t(l):Promise.resolve(l).then(a,n)}function R(e){return function(){var t=this,r=arguments;return new Promise((function(a,n){var s=e.apply(t,r);function o(e){j(s,a,n,o,i,"next",e)}function i(e){j(s,a,n,o,i,"throw",e)}o(void 0)}))}}function A(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function L(e,t){for(var r=0;r<t.length;r++){var a=t[r];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function P(e,t){return(P=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function I(e,t){return!t||"object"!==O(t)&&"function"!=typeof t?D(e):t}function D(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function U(e){return(U=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var M=wp.i18n.__,B=wp,H=(B.apiFetch,B.apiRequest),$=wp.element,K=$.Component,Y=($.Fragment,wp.components),V=Y.ExternalLink,q=Y.Placeholder,W=Y.TextControl,Q=Y.Button,G=Y.Spinner;wp.date.date;const J=function(t){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&P(e,t)}(p,t);var r,a,n,s,o,i,l=(o=p,i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=U(o);if(i){var r=U(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return I(this,e)});function p(){var e;return A(this,p),(e=l.apply(this,arguments)).loadFeed=e.loadFeed.bind(D(e)),e.loadCategories=e.loadCategories.bind(D(e)),e.metaExists=e.metaExists.bind(D(e)),e.multipleMetaExists=e.multipleMetaExists.bind(D(e)),e.getImageURL=e.getImageURL.bind(D(e)),e.getValidateURL=e.getValidateURL.bind(D(e)),e.onChangeFeed=e.onChangeFeed.bind(D(e)),e.onChangeMax=e.onChangeMax.bind(D(e)),e.onChangeOffset=e.onChangeOffset.bind(D(e)),e.onToggleFeedTitle=e.onToggleFeedTitle.bind(D(e)),e.onRefresh=e.onRefresh.bind(D(e)),e.onSort=e.onSort.bind(D(e)),e.onTarget=e.onTarget.bind(D(e)),e.onTitle=e.onTitle.bind(D(e)),e.onChangeMeta=e.onChangeMeta.bind(D(e)),e.onChangeMultipleMeta=e.onChangeMultipleMeta.bind(D(e)),e.onToggleSummary=e.onToggleSummary.bind(D(e)),e.onToggleLazy=e.onToggleLazy.bind(D(e)),e.onSummaryLength=e.onSummaryLength.bind(D(e)),e.onKeywordsTitle=e.onKeywordsTitle.bind(D(e)),e.onKeywordsBan=e.onKeywordsBan.bind(D(e)),e.onThumb=e.onThumb.bind(D(e)),e.onDefault=e.onDefault.bind(D(e)),e.onSize=e.onSize.bind(D(e)),e.onHTTP=e.onHTTP.bind(D(e)),e.onReferralURL=e.onReferralURL.bind(D(e)),e.onColumns=e.onColumns.bind(D(e)),e.onTemplate=e.onTemplate.bind(D(e)),e.onTogglePrice=e.onTogglePrice.bind(D(e)),e.state={route:e.props.attributes.route,loading:!1,error:!1},e}return r=p,(a=[{key:"componentDidMount",value:(s=R(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:this.loadFeed(),void 0===this.props.attributes.categories&&(this.props.attributes.meta||this.props.setAttributes({meta:!0,metafields:"no"}),this.loadCategories());case 2:case"end":return e.stop()}}),e,this)}))),function(){return s.apply(this,arguments)})},{key:"componentDidUpdate",value:(n=R(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:"reload"===this.state.route&&this.loadFeed();case 1:case"end":return e.stop()}}),e,this)}))),function(e){return n.apply(this,arguments)})},{key:"loadFeed",value:function(){var t=this,r=this.props.attributes.feeds;if(void 0!==r){if(function(e,t){if(void 0===t)return!1;for(var r=!1,a=0;a<t.length;a++)if(t[a]===e){r=!0;break}return r}(r,this.props.attributes.categories)){var a=r;r=e.stringify({category:a},{arrayFormat:"bracket"})}else r=r.replace(/\s/g,"").split(",").filter((function(e){return""!==e})),r=e.stringify({url:r},{arrayFormat:"bracket"});this.setState({route:"home",loading:!0}),H({path:"/feedzy/v1/feed?".concat(r),method:"POST",data:this.props.attributes}).then((function(e){return t.unmounting?e:e.error?(t.setState({route:"home",loading:!1,error:!0}),e):(t.props.setAttributes({feedData:e}),t.setState({route:"fetched",loading:!1}),e)})).fail((function(e){return t.setState({route:"home",loading:!1,error:!0}),e}))}}},{key:"loadCategories",value:function(){var e=this;H({path:"/wp/v2/feedzy_categories"}).then((function(t){if(e.unmounting)return t;var r=0,a=[];t.forEach((function(e){a[r]=e.slug,r+=1}));var n=e;n.props.setAttributes({categories:a}),jQuery(".feedzy-source input").autocomplete({source:a,select:function(e,t){n.props.setAttributes({feeds:t.item.label})}})})).fail((function(e){return e}))}},{key:"metaExists",value:function(e){return 0<=this.props.attributes.metafields.replace(/\s/g,"").split(",").indexOf(e)||""===this.props.attributes.metafields}},{key:"multipleMetaExists",value:function(e){return 0<=this.props.attributes.multiple_meta.replace(/\s/g,"").split(",").indexOf(e)||""===this.props.attributes.multiple_meta}},{key:"getImageURL",value:function(e,t){var r=e.thumbnail?e.thumbnail:this.props.attributes.default?this.props.attributes.default.url:feedzyjs.imagepath+"feedzy.svg";switch(this.props.attributes.http){case"default":-1===r.indexOf("https")&&0===r.indexOf("http")&&(r=this.props.attributes.default?this.props.attributes.default.url:feedzyjs.imagepath+"feedzy.svg");break;case"https":r=r.replace(/http:/g,"https:")}return t&&(r="url("+r+")"),r}},{key:"onChangeFeed",value:function(e){this.props.setAttributes({feeds:e})}},{key:"onChangeMax",value:function(e){this.props.setAttributes({max:e?Number(e):5})}},{key:"onChangeOffset",value:function(e){this.props.setAttributes({offset:Number(e)})}},{key:"onToggleFeedTitle",value:function(e){this.props.setAttributes({feed_title:!this.props.attributes.feed_title})}},{key:"onRefresh",value:function(e){this.props.setAttributes({refresh:e})}},{key:"onSort",value:function(e){this.props.setAttributes({sort:e})}},{key:"onTarget",value:function(e){this.props.setAttributes({target:e})}},{key:"onTitle",value:function(e){this.props.setAttributes({title:Number(e)})}},{key:"onChangeMeta",value:function(e){this.props.setAttributes({metafields:e})}},{key:"onChangeMultipleMeta",value:function(e){this.props.setAttributes({multiple_meta:e})}},{key:"onToggleSummary",value:function(e){this.props.setAttributes({summary:!this.props.attributes.summary})}},{key:"onToggleLazy",value:function(e){this.props.setAttributes({lazy:!this.props.attributes.lazy})}},{key:"onSummaryLength",value:function(e){this.props.setAttributes({summarylength:Number(e)})}},{key:"onKeywordsTitle",value:function(e){this.props.setAttributes({keywords_title:e})}},{key:"onKeywordsBan",value:function(e){this.props.setAttributes({keywords_ban:e})}},{key:"onThumb",value:function(e){this.props.setAttributes({thumb:e})}},{key:"onDefault",value:function(e){this.props.setAttributes({default:e}),this.setState({route:"reload"})}},{key:"onSize",value:function(e){this.props.setAttributes({size:e?Number(e):150})}},{key:"onHTTP",value:function(e){this.props.setAttributes({http:e}),this.setState({route:"reload"})}},{key:"onReferralURL",value:function(e){this.props.setAttributes({referral_url:e})}},{key:"onColumns",value:function(e){this.props.setAttributes({columns:e})}},{key:"onTemplate",value:function(e){this.props.setAttributes({template:e})}},{key:"onTogglePrice",value:function(e){this.props.setAttributes({price:!this.props.attributes.price})}},{key:"getValidateURL",value:function(){var e="https://validator.w3.org/feed/";return this.props.attributes.feeds&&(e+="check.cgi?url="+this.props.attributes.feeds),e}},{key:"render",value:function(){var e,t,r,a,n,s,o=this;return["fetched"===this.state.route&&wp.element.createElement(N,F({edit:this,state:this.state},this.props)),"home"===this.state.route&&wp.element.createElement("div",{className:this.props.className},wp.element.createElement(q,{key:"placeholder",icon:"rss",label:M("Feedzy RSS Feeds")},this.state.loading?wp.element.createElement("div",{key:"loading",className:"wp-block-embed is-loading"},wp.element.createElement(G,null),wp.element.createElement("p",null,M("Fetching..."))):[wp.element.createElement(W,{type:"url",className:"feedzy-source",placeholder:M("Enter URL or category of your feed here..."),onChange:this.onChangeFeed,value:this.props.attributes.feeds}),wp.element.createElement(Q,{isLarge:!0,isPrimary:!0,type:"submit",onClick:this.loadFeed},M("Load Feed")),wp.element.createElement(V,{href:this.getValidateURL(),title:M("Validate Feed ")},M("Validate ")),this.state.error&&wp.element.createElement("div",null,M("Feed URL is invalid. Invalid feeds will NOT display items."))])),!("fetched"!==this.state.route||void 0===this.props.attributes.feedData)&&wp.element.createElement("div",{className:"feedzy-rss"},this.props.attributes.feed_title&&null!==this.props.attributes.feedData.channel&&wp.element.createElement("div",{className:"rss_header"},wp.element.createElement("h2",null,wp.element.createElement("a",{className:"rss_title"},S(this.props.attributes.feedData.channel.title)),wp.element.createElement("span",{className:"rss_description"}," "+S(this.props.attributes.feedData.channel.description)))),wp.element.createElement("ul",{className:"feedzy-".concat(this.props.attributes.template)},(e=this.props.attributes.feedData.items,t=this.props.attributes.sort,r=this.props.attributes.keywords_title,a=this.props.attributes.keywords_ban,n=this.props.attributes.max,s=this.props.attributes.offset,e=Array.from(e).sort((function(e,r){var a,n;return"date_desc"===t||"date_asc"===t?(a=e.pubDate,n=r.pubDate):"title_desc"!==t&&"title_asc"!==t||(a=e.title.toUpperCase(),n=r.title.toUpperCase()),a<n?"date_desc"===t||"title_desc"===t?1:-1:a>n?"date_desc"===t||"title_desc"===t?-1:1:0})).filter((function(e){return!r||r.split(",").filter((function(e){return""!==e.replace(/\s/g,"")})).some((function(t){return e.title.includes(t.trim())}))})).filter((function(e){return!a||a.split(",").filter((function(e){return""!==e.replace(/\s/g,"")})).every((function(t){return!1===e.title.includes(t.trim())}))})).slice(s,n+s)).map((function(e,t){var r=(e.date||"")+" "+(e.time||"")+" UTC +0000",a=S(e.date)||"",n=S(e.time)||"",s=S(e.categories)||"";if(o.metaExists("tz=local")){var i=new Date(r);i=i.toUTCString(),a=moment.utc(i).format("MMMM D, YYYY"),n=moment.utc(i).format("h:mm A")}var l=e.creator&&o.metaExists("author")?e.creator:"";""!==o.props.attributes.multiple_meta&&"no"!==o.props.attributes.multiple_meta&&((o.multipleMetaExists("source")||o.multipleMetaExists("yes"))&&""!==l&&""!==e.source?l=l+" ("+e.source+")":(o.multipleMetaExists("source")||o.multipleMetaExists("yes"))&&""!==e.source&&(l=e.source)),""===e.thumbnail&&"auto"===o.props.attributes.thumb&&(e.thumbnail=e.default_img);var p=new Object;return p.author=M("by")+" "+l,p.date=M("on")+" "+S(a),p.time=M("at")+" "+S(n),p.categories=M("in")+" "+S(s),wp.element.createElement("li",{key:t,style:{padding:"15px 0 25px"},className:"rss_item feedzy-rss-col-".concat(o.props.attributes.columns)},(e.thumbnail&&"auto"===o.props.attributes.thumb||"yes"===o.props.attributes.thumb)&&wp.element.createElement("div",{className:"rss_image",style:{width:o.props.attributes.size+"px",height:o.props.attributes.size+"px"}},wp.element.createElement("a",{title:S(e.title),style:{width:o.props.attributes.size+"px",height:o.props.attributes.size+"px"}},wp.element.createElement("span",{className:"fetched",style:{width:o.props.attributes.size+"px",height:o.props.attributes.size+"px",backgroundImage:o.getImageURL(e,!0)},title:S(e.title)}))),wp.element.createElement("div",{className:"rss_content_wrap"},wp.element.createElement("span",{className:"title"},wp.element.createElement("a",null,o.props.attributes.title&&S(e.title).length>o.props.attributes.title?S(e.title).substring(0,o.props.attributes.title)+"...":S(e.title))),wp.element.createElement("div",{className:"rss_content"},"no"!==o.props.attributes.metafields&&wp.element.createElement("small",{className:"meta"},function(e,t){var r="";""===t&&(t="author, date, time");for(var a=t.replace(/\s/g,"").split(","),n=0;n<a.length;n++)void 0!==e[a[n]]&&(r=r+" "+e[a[n]]);return r}(p,o.props.attributes.metafields)),o.props.attributes.summary&&wp.element.createElement("p",{className:"description"},o.props.attributes.summarylength&&S(e.description).length>o.props.attributes.summarylength?S(e.description).substring(0,o.props.attributes.summarylength)+" [...]":S(e.description)),feedzyjs.isPro&&e.media&&e.media.src&&wp.element.createElement("audio",{controls:!0,controlsList:"nodownload"},wp.element.createElement("source",{src:e.media.src,type:e.media.type}),M("Your browser does not support the audio element. But you can check this for the original link: "),wp.element.createElement("a",{href:e.media.src},e.media.src)),feedzyjs.isPro&&o.props.attributes.price&&e.price&&"default"!==o.props.attributes.template&&wp.element.createElement("div",{className:"price-wrap"},wp.element.createElement("a",null,wp.element.createElement("button",{className:"price"},e.price))))))}))))]}}])&&L(r.prototype,a),p}(K);var X=wp.i18n.__;(0,wp.blocks.registerBlockType)("feedzy-rss-feeds/feedzy-block",{title:X("Feedzy RSS Feeds"),category:"common",icon:"rss",keywords:[X("Feedzy RSS Feeds"),X("RSS"),X("Feeds")],supports:{html:!1},attributes:{feeds:{type:"string"},max:{type:"number",default:5},offset:{type:"number",default:0},feed_title:{type:"boolean",default:!0},refresh:{type:"string",default:"12_hours"},sort:{type:"string",default:"default"},target:{type:"string",default:"_blank"},title:{type:"number"},meta:{type:"boolean",default:!0},lazy:{type:"boolean",default:!1},metafields:{type:"string",default:""},multiple_meta:{type:"string",default:""},summary:{type:"boolean",default:!0},summarylength:{type:"number"},keywords_title:{type:"string"},keywords_ban:{type:"string"},thumb:{type:"string",default:"auto"},default:{type:"object"},size:{type:"number",default:150},http:{type:"string"},referral_url:{type:"string"},columns:{type:"number",default:1},template:{type:"string",default:"default"},price:{type:"boolean",default:!0},route:{type:"string",default:"home"},feedData:{type:"object"},categories:{type:"object"}},edit:J,save:function(){return null}})})()})();
|
includes/gutenberg/feedzy-rss-feeds-gutenberg-block.php
CHANGED
@@ -297,6 +297,7 @@ class Feedzy_Rss_Feeds_Gutenberg_Block {
|
|
297 |
'time' => ( ( $item->get_date() ) ? date_i18n( $meta_args['time_format'], $item->get_date( 'U' ) ) : null ),
|
298 |
'description' => isset( $item_attrs['item_description'] ) ? $item_attrs['item_description'] : ( $item->get_description() ? $item->get_description() : null ),
|
299 |
'thumbnail' => $admin->feedzy_retrieve_image( $item ),
|
|
|
300 |
'price' => isset( $item_attrs['item_price'] ) ? $item_attrs['item_price'] : null,
|
301 |
'media' => isset( $item_attrs['item_media'] ) ? $item_attrs['item_media'] : null,
|
302 |
'categories' => isset( $item_attrs['item_categories'] ) ? $item_attrs['item_categories'] : null,
|
297 |
'time' => ( ( $item->get_date() ) ? date_i18n( $meta_args['time_format'], $item->get_date( 'U' ) ) : null ),
|
298 |
'description' => isset( $item_attrs['item_description'] ) ? $item_attrs['item_description'] : ( $item->get_description() ? $item->get_description() : null ),
|
299 |
'thumbnail' => $admin->feedzy_retrieve_image( $item ),
|
300 |
+
'default_img' => apply_filters( 'feedzy_default_image', '', $url ),
|
301 |
'price' => isset( $item_attrs['item_price'] ) ? $item_attrs['item_price'] : null,
|
302 |
'media' => isset( $item_attrs['item_media'] ) ? $item_attrs['item_media'] : null,
|
303 |
'categories' => isset( $item_attrs['item_categories'] ) ? $item_attrs['item_categories'] : null,
|
includes/layouts/settings.php
CHANGED
@@ -50,6 +50,8 @@
|
|
50 |
$disble_featured_image = 'checked';
|
51 |
}
|
52 |
|
|
|
|
|
53 |
switch ( $active_tab ) {
|
54 |
case 'general':
|
55 |
?>
|
@@ -58,7 +60,19 @@
|
|
58 |
<input type="checkbox" id="rss-feeds" class="fz-form-control" name="rss-feeds"
|
59 |
value="1" <?php echo esc_html( $disble_featured_image ); ?> />
|
60 |
<label for="rss-feeds"><?php echo esc_html_e( 'Do NOT add the featured image to the website\'s RSS feed.', 'feedzy-rss-feeds' ); ?></label>
|
61 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
62 |
</div>
|
63 |
<?php
|
64 |
break;
|
50 |
$disble_featured_image = 'checked';
|
51 |
}
|
52 |
|
53 |
+
$default_thumbnail_id = isset( $settings['general']['default-thumbnail-id'] ) ? $settings['general']['default-thumbnail-id'] : 0;
|
54 |
+
|
55 |
switch ( $active_tab ) {
|
56 |
case 'general':
|
57 |
?>
|
60 |
<input type="checkbox" id="rss-feeds" class="fz-form-control" name="rss-feeds"
|
61 |
value="1" <?php echo esc_html( $disble_featured_image ); ?> />
|
62 |
<label for="rss-feeds"><?php echo esc_html_e( 'Do NOT add the featured image to the website\'s RSS feed.', 'feedzy-rss-feeds' ); ?></label>
|
63 |
+
</div>
|
64 |
+
<div class="fz-form-group">
|
65 |
+
<label><?php esc_html_e( 'Choose default thumbnail image(Feed2Post):', 'feedzy-rss-feeds' ); ?></label>
|
66 |
+
</div>
|
67 |
+
<?php if ( $default_thumbnail_id ) : ?>
|
68 |
+
<div class="fz-form-group feedzy-media-preview">
|
69 |
+
<?php echo wp_get_attachment_image( $default_thumbnail_id, 'thumbnail' ); ?>
|
70 |
+
</div>
|
71 |
+
<?php endif; ?>
|
72 |
+
<div class="fz-form-group">
|
73 |
+
<a href="javascript:;" class="feedzy-open-media button action"><?php esc_html_e( 'Choose image', 'feedzy-rss-feeds' ); ?></a>
|
74 |
+
<a href="javascript:;" class="feedzy-remove-media button action <?php echo $default_thumbnail_id ? esc_attr( 'is-show' ) : ''; ?>"><?php esc_html_e( 'Remove image', 'feedzy-rss-feeds' ); ?></a>
|
75 |
+
<input type="hidden" name="default-thumbnail-id" id="feed-post-default-thumbnail" value="<?php echo esc_attr( $default_thumbnail_id ); ?>">
|
76 |
</div>
|
77 |
<?php
|
78 |
break;
|
includes/views/import-metabox-edit.php
CHANGED
@@ -320,7 +320,7 @@
|
|
320 |
</div>
|
321 |
<div class="feedzy-separator dashicons dashicons-leftright"></div>
|
322 |
<div class="form-group input-group form_item">
|
323 |
-
<textarea name="feedzy_meta_data[import_post_content]" placeholder="<?php esc_html_e( 'Post Content', 'feedzy-rss-feeds' ); ?>" class="form-control"><?php echo
|
324 |
<div class="input-group-btn">
|
325 |
<button type="button" class="btn btn-add-fields dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
326 |
<?php esc_html_e( 'Insert Tag', 'feedzy-rss-feeds' ); ?> <span class="dashicons dashicons-arrow-down-alt2"></span>
|
320 |
</div>
|
321 |
<div class="feedzy-separator dashicons dashicons-leftright"></div>
|
322 |
<div class="form-group input-group form_item">
|
323 |
+
<textarea name="feedzy_meta_data[import_post_content]" placeholder="<?php esc_html_e( 'Post Content', 'feedzy-rss-feeds' ); ?>" class="form-control"><?php echo esc_html( feedzy_custom_tag_escape( $import_content ) ); ?></textarea>
|
324 |
<div class="input-group-btn">
|
325 |
<button type="button" class="btn btn-add-fields dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
326 |
<?php esc_html_e( 'Insert Tag', 'feedzy-rss-feeds' ); ?> <span class="dashicons dashicons-arrow-down-alt2"></span>
|
js/feedzy-setting.js
ADDED
@@ -0,0 +1,48 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/**
|
2 |
+
* Plugin Name: FEEDZY RSS Feeds
|
3 |
+
* Plugin URI: http://themeisle.com/plugins/feedzy-rss-feeds/
|
4 |
+
* Author: Themeisle
|
5 |
+
*
|
6 |
+
* @package feedzy-rss-feeds
|
7 |
+
*/
|
8 |
+
/* global feedzy_setting */
|
9 |
+
/* jshint unused:false */
|
10 |
+
jQuery( function( $ ) {
|
11 |
+
// on upload button click
|
12 |
+
$( 'body' ).on( 'click', '.feedzy-open-media', function( e ) {
|
13 |
+
e.preventDefault();
|
14 |
+
var button = $( this ),
|
15 |
+
wp_media_uploader = wp.media( {
|
16 |
+
title: feedzy_setting.l10n.media_iframe_title,
|
17 |
+
library : {
|
18 |
+
type : 'image'
|
19 |
+
},
|
20 |
+
button: {
|
21 |
+
text: feedzy_setting.l10n.media_iframe_button
|
22 |
+
},
|
23 |
+
multiple: false
|
24 |
+
} ).on( 'select', function() { // it also has "open" and "close" events
|
25 |
+
var attachment = wp_media_uploader.state().get( 'selection' ).first().toJSON();
|
26 |
+
var attachmentUrl = attachment.url;
|
27 |
+
if ( attachment.sizes.thumbnail ) {
|
28 |
+
attachmentUrl = attachment.sizes.thumbnail.url;
|
29 |
+
}
|
30 |
+
if ( $( '.feedzy-media-preview' ).length ) {
|
31 |
+
$( '.feedzy-media-preview' ).find( 'img' ).attr( 'src', attachmentUrl );
|
32 |
+
} else {
|
33 |
+
$( '<div class="fz-form-group feedzy-media-preview"><img src="' + attachmentUrl + '"></div>' ).insertBefore( button.parent() );
|
34 |
+
}
|
35 |
+
button.parent().find( '.feedzy-remove-media' ).addClass( 'is-show' );
|
36 |
+
button.parent().find( 'input:hidden' ).val( attachment.id );
|
37 |
+
} ).open();
|
38 |
+
});
|
39 |
+
|
40 |
+
// on remove button click
|
41 |
+
$( 'body' ).on( 'click', '.feedzy-remove-media', function( e ) {
|
42 |
+
e.preventDefault();
|
43 |
+
var button = $( this );
|
44 |
+
button.parent().prev( '.feedzy-media-preview' ).remove();
|
45 |
+
button.removeClass( 'is-show' );
|
46 |
+
button.parent().find( 'input:hidden' ).val( '' );
|
47 |
+
});
|
48 |
+
});
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: themeisle,codeinwp,hardeepasrani,rozroz
|
|
3 |
Tags: rss aggregator, news aggregator, autoblogging, feed to post, rss import
|
4 |
Requires at least: 3.7
|
5 |
Requires PHP: 5.6
|
6 |
-
Tested up to: 5.
|
7 |
Stable tag: trunk
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
@@ -462,6 +462,22 @@ You have to check first if your feed is valid. Please test it here: https://vali
|
|
462 |
|
463 |
== Changelog ==
|
464 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
465 |
##### [Version 3.7.2](https://github.com/Codeinwp/feedzy-rss-feeds/compare/v3.7.1...v3.7.2) (2021-08-04)
|
466 |
|
467 |
#### Features
|
3 |
Tags: rss aggregator, news aggregator, autoblogging, feed to post, rss import
|
4 |
Requires at least: 3.7
|
5 |
Requires PHP: 5.6
|
6 |
+
Tested up to: 5.8
|
7 |
Stable tag: trunk
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
462 |
|
463 |
== Changelog ==
|
464 |
|
465 |
+
##### [Version 3.7.3](https://github.com/Codeinwp/feedzy-rss-feeds/compare/v3.7.2...v3.7.3) (2021-08-27)
|
466 |
+
|
467 |
+
#### Features
|
468 |
+
* Support default Gutenberg editor instead of importing content in the Classic block
|
469 |
+
* Adds support for Feedzy widget in the widget block editor
|
470 |
+
* Adds default thumbnail image support when no image is available
|
471 |
+
|
472 |
+
#### Fixes
|
473 |
+
* Title Character Limit and the Description Character Limit parameter in the Feedzy Block
|
474 |
+
* Displaying Default Thumbnail Image does not show in Block or Shortcode approach
|
475 |
+
* Custom tag is trimmed on save of the import if used inside <iframe>
|
476 |
+
* Keyword filters break the import with PHP 8.0
|
477 |
+
|
478 |
+
|
479 |
+
|
480 |
+
|
481 |
##### [Version 3.7.2](https://github.com/Codeinwp/feedzy-rss-feeds/compare/v3.7.1...v3.7.2) (2021-08-04)
|
482 |
|
483 |
#### Features
|
vendor/autoload.php
CHANGED
@@ -4,4 +4,4 @@
|
|
4 |
|
5 |
require_once __DIR__ . '/composer/autoload_real.php';
|
6 |
|
7 |
-
return
|
4 |
|
5 |
require_once __DIR__ . '/composer/autoload_real.php';
|
6 |
|
7 |
+
return ComposerAutoloaderInitdb9401a7a99948370e33520b6abd1fd3::getLoader();
|
vendor/composer/autoload_real.php
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
|
3 |
// autoload_real.php @generated by Composer
|
4 |
|
5 |
-
class
|
6 |
{
|
7 |
private static $loader;
|
8 |
|
@@ -22,15 +22,15 @@ class ComposerAutoloaderInit3bc68f15086e1834a6e0a921a8469ebe
|
|
22 |
return self::$loader;
|
23 |
}
|
24 |
|
25 |
-
spl_autoload_register(array('
|
26 |
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__)));
|
27 |
-
spl_autoload_unregister(array('
|
28 |
|
29 |
$useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
|
30 |
if ($useStaticLoader) {
|
31 |
require __DIR__ . '/autoload_static.php';
|
32 |
|
33 |
-
call_user_func(\Composer\Autoload\
|
34 |
} else {
|
35 |
$map = require __DIR__ . '/autoload_namespaces.php';
|
36 |
foreach ($map as $namespace => $path) {
|
@@ -51,19 +51,19 @@ class ComposerAutoloaderInit3bc68f15086e1834a6e0a921a8469ebe
|
|
51 |
$loader->register(true);
|
52 |
|
53 |
if ($useStaticLoader) {
|
54 |
-
$includeFiles = Composer\Autoload\
|
55 |
} else {
|
56 |
$includeFiles = require __DIR__ . '/autoload_files.php';
|
57 |
}
|
58 |
foreach ($includeFiles as $fileIdentifier => $file) {
|
59 |
-
|
60 |
}
|
61 |
|
62 |
return $loader;
|
63 |
}
|
64 |
}
|
65 |
|
66 |
-
function
|
67 |
{
|
68 |
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
|
69 |
require $file;
|
2 |
|
3 |
// autoload_real.php @generated by Composer
|
4 |
|
5 |
+
class ComposerAutoloaderInitdb9401a7a99948370e33520b6abd1fd3
|
6 |
{
|
7 |
private static $loader;
|
8 |
|
22 |
return self::$loader;
|
23 |
}
|
24 |
|
25 |
+
spl_autoload_register(array('ComposerAutoloaderInitdb9401a7a99948370e33520b6abd1fd3', 'loadClassLoader'), true, true);
|
26 |
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__)));
|
27 |
+
spl_autoload_unregister(array('ComposerAutoloaderInitdb9401a7a99948370e33520b6abd1fd3', 'loadClassLoader'));
|
28 |
|
29 |
$useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
|
30 |
if ($useStaticLoader) {
|
31 |
require __DIR__ . '/autoload_static.php';
|
32 |
|
33 |
+
call_user_func(\Composer\Autoload\ComposerStaticInitdb9401a7a99948370e33520b6abd1fd3::getInitializer($loader));
|
34 |
} else {
|
35 |
$map = require __DIR__ . '/autoload_namespaces.php';
|
36 |
foreach ($map as $namespace => $path) {
|
51 |
$loader->register(true);
|
52 |
|
53 |
if ($useStaticLoader) {
|
54 |
+
$includeFiles = Composer\Autoload\ComposerStaticInitdb9401a7a99948370e33520b6abd1fd3::$files;
|
55 |
} else {
|
56 |
$includeFiles = require __DIR__ . '/autoload_files.php';
|
57 |
}
|
58 |
foreach ($includeFiles as $fileIdentifier => $file) {
|
59 |
+
composerRequiredb9401a7a99948370e33520b6abd1fd3($fileIdentifier, $file);
|
60 |
}
|
61 |
|
62 |
return $loader;
|
63 |
}
|
64 |
}
|
65 |
|
66 |
+
function composerRequiredb9401a7a99948370e33520b6abd1fd3($fileIdentifier, $file)
|
67 |
{
|
68 |
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
|
69 |
require $file;
|
vendor/composer/autoload_static.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
|
5 |
namespace Composer\Autoload;
|
6 |
|
7 |
-
class
|
8 |
{
|
9 |
public static $files = array (
|
10 |
'3df8ee254224091c21b9aebb792d2f8b' => __DIR__ . '/..' . '/codeinwp/themeisle-sdk/load.php',
|
@@ -17,7 +17,7 @@ class ComposerStaticInit3bc68f15086e1834a6e0a921a8469ebe
|
|
17 |
public static function getInitializer(ClassLoader $loader)
|
18 |
{
|
19 |
return \Closure::bind(function () use ($loader) {
|
20 |
-
$loader->classMap =
|
21 |
|
22 |
}, null, ClassLoader::class);
|
23 |
}
|
4 |
|
5 |
namespace Composer\Autoload;
|
6 |
|
7 |
+
class ComposerStaticInitdb9401a7a99948370e33520b6abd1fd3
|
8 |
{
|
9 |
public static $files = array (
|
10 |
'3df8ee254224091c21b9aebb792d2f8b' => __DIR__ . '/..' . '/codeinwp/themeisle-sdk/load.php',
|
17 |
public static function getInitializer(ClassLoader $loader)
|
18 |
{
|
19 |
return \Closure::bind(function () use ($loader) {
|
20 |
+
$loader->classMap = ComposerStaticInitdb9401a7a99948370e33520b6abd1fd3::$classMap;
|
21 |
|
22 |
}, null, ClassLoader::class);
|
23 |
}
|
vendor/composer/installed.php
CHANGED
@@ -1,22 +1,22 @@
|
|
1 |
<?php return array(
|
2 |
'root' => array(
|
3 |
-
'pretty_version' => 'v3.7.
|
4 |
-
'version' => '3.7.
|
5 |
'type' => 'wordpress-plugin',
|
6 |
'install_path' => __DIR__ . '/../../',
|
7 |
'aliases' => array(),
|
8 |
-
'reference' => '
|
9 |
'name' => 'codeinwp/feedzy-rss-feeds',
|
10 |
'dev' => false,
|
11 |
),
|
12 |
'versions' => array(
|
13 |
'codeinwp/feedzy-rss-feeds' => array(
|
14 |
-
'pretty_version' => 'v3.7.
|
15 |
-
'version' => '3.7.
|
16 |
'type' => 'wordpress-plugin',
|
17 |
'install_path' => __DIR__ . '/../../',
|
18 |
'aliases' => array(),
|
19 |
-
'reference' => '
|
20 |
'dev_requirement' => false,
|
21 |
),
|
22 |
'codeinwp/themeisle-sdk' => array(
|
1 |
<?php return array(
|
2 |
'root' => array(
|
3 |
+
'pretty_version' => 'v3.7.3',
|
4 |
+
'version' => '3.7.3.0',
|
5 |
'type' => 'wordpress-plugin',
|
6 |
'install_path' => __DIR__ . '/../../',
|
7 |
'aliases' => array(),
|
8 |
+
'reference' => 'd73fed973497c5c1d8cb21a1ba473a2e7e2f9a65',
|
9 |
'name' => 'codeinwp/feedzy-rss-feeds',
|
10 |
'dev' => false,
|
11 |
),
|
12 |
'versions' => array(
|
13 |
'codeinwp/feedzy-rss-feeds' => array(
|
14 |
+
'pretty_version' => 'v3.7.3',
|
15 |
+
'version' => '3.7.3.0',
|
16 |
'type' => 'wordpress-plugin',
|
17 |
'install_path' => __DIR__ . '/../../',
|
18 |
'aliases' => array(),
|
19 |
+
'reference' => 'd73fed973497c5c1d8cb21a1ba473a2e7e2f9a65',
|
20 |
'dev_requirement' => false,
|
21 |
),
|
22 |
'codeinwp/themeisle-sdk' => array(
|