YITH WooCommerce Zoom Magnifier - Version 1.3.13

Version Description

Download this release

Release Info

Developer yithemes
Plugin Icon 128x128 YITH WooCommerce Zoom Magnifier
Version 1.3.13
Comparing to
See all releases

Code changes from version 1.3.12 to 1.3.13

README.txt CHANGED
@@ -3,8 +3,8 @@
3
  Contributors: yithemes
4
  Tags: zoom, magnifier, slider, carousel, woocommerce
5
  Requires at least: 4.0
6
- Tested up to: 5.2
7
- Stable tag: 1.3.12
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
  Documentation: https://docs.yithemes.com/yith-woocommerce-zoom-magnifier/
@@ -52,6 +52,10 @@ YITH WooCommerce Zoom Magnifier will add a new tab called "Zoom Magnifier" in "Y
52
 
53
  == Changelog ==
54
 
 
 
 
 
55
  = Version 1.3.12 - Released: Oct 30, 2019 =
56
 
57
  * Update: plugin framework
3
  Contributors: yithemes
4
  Tags: zoom, magnifier, slider, carousel, woocommerce
5
  Requires at least: 4.0
6
+ Tested up to: 5.3
7
+ Stable tag: 1.3.13
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
  Documentation: https://docs.yithemes.com/yith-woocommerce-zoom-magnifier/
52
 
53
  == Changelog ==
54
 
55
+ = Version 1.3.13 - Released: Nov 11, 2019 =
56
+
57
+ * Update: plugin framework
58
+
59
  = Version 1.3.12 - Released: Oct 30, 2019 =
60
 
61
  * Update: plugin framework
init.php CHANGED
@@ -3,13 +3,13 @@
3
  * Plugin Name: YITH WooCommerce Zoom Magnifier
4
  * Plugin URI: https://yithemes.com/themes/plugins/yith-woocommerce-zoom-magnifier/
5
  * Description: <code><strong>YITH WooCommerce Zoom Magnifier</strong></code> allows you to add a zoom effect to product images and a thumbnail slider for the product image gallery. <a href="https://yithemes.com/" target="_blank">Get more plugins for your e-commerce shop on <strong>YITH</strong></a>.
6
- * Version: 1.3.12
7
  * Author: YITH
8
  * Author URI: https://yithemes.com/
9
  * Text Domain: yith-woocommerce-zoom-magnifier
10
  * Domain Path: /languages/
11
  * WC requires at least: 3.3.0
12
- * WC tested up to: 3.7.x
13
  **/
14
 
15
  /* Copyright 2013-2018 Your Inspiration Themes (email : plugins@yithemes.com)
@@ -78,7 +78,7 @@ register_activation_hook ( __FILE__, 'yith_plugin_registration_hook' );
78
 
79
  defined ( 'YITH_YWZM_FREE_INIT' ) || define ( 'YITH_YWZM_FREE_INIT', plugin_basename ( __FILE__ ) );
80
  defined ( 'YITH_YWZM_SLUG' ) || define ( 'YITH_YWZM_SLUG', 'yith-woocommerce-zoom-magnifier' );
81
- defined ( 'YITH_YWZM_VERSION' ) || define ( 'YITH_YWZM_VERSION', '1.3.12' );
82
  defined ( 'YITH_YWZM_FILE' ) || define ( 'YITH_YWZM_FILE', __FILE__ );
83
  defined ( 'YITH_YWZM_DIR' ) || define ( 'YITH_YWZM_DIR', plugin_dir_path ( __FILE__ ) );
84
  defined ( 'YITH_YWZM_URL' ) || define ( 'YITH_YWZM_URL', plugins_url ( '/', __FILE__ ) );
3
  * Plugin Name: YITH WooCommerce Zoom Magnifier
4
  * Plugin URI: https://yithemes.com/themes/plugins/yith-woocommerce-zoom-magnifier/
5
  * Description: <code><strong>YITH WooCommerce Zoom Magnifier</strong></code> allows you to add a zoom effect to product images and a thumbnail slider for the product image gallery. <a href="https://yithemes.com/" target="_blank">Get more plugins for your e-commerce shop on <strong>YITH</strong></a>.
6
+ * Version: 1.3.13
7
  * Author: YITH
8
  * Author URI: https://yithemes.com/
9
  * Text Domain: yith-woocommerce-zoom-magnifier
10
  * Domain Path: /languages/
11
  * WC requires at least: 3.3.0
12
+ * WC tested up to: 3.8
13
  **/
14
 
15
  /* Copyright 2013-2018 Your Inspiration Themes (email : plugins@yithemes.com)
78
 
79
  defined ( 'YITH_YWZM_FREE_INIT' ) || define ( 'YITH_YWZM_FREE_INIT', plugin_basename ( __FILE__ ) );
80
  defined ( 'YITH_YWZM_SLUG' ) || define ( 'YITH_YWZM_SLUG', 'yith-woocommerce-zoom-magnifier' );
81
+ defined ( 'YITH_YWZM_VERSION' ) || define ( 'YITH_YWZM_VERSION', '1.3.13' );
82
  defined ( 'YITH_YWZM_FILE' ) || define ( 'YITH_YWZM_FILE', __FILE__ );
83
  defined ( 'YITH_YWZM_DIR' ) || define ( 'YITH_YWZM_DIR', plugin_dir_path ( __FILE__ ) );
84
  defined ( 'YITH_YWZM_URL' ) || define ( 'YITH_YWZM_URL', plugins_url ( '/', __FILE__ ) );
lib/class.yith-ywzm-plugin-fw-loader.php CHANGED
@@ -135,8 +135,10 @@ if ( ! class_exists( 'YITH_YWZM_Plugin_FW_Loader' ) ) {
135
  'parent_page' => 'yit_plugin_panel',
136
  'page' => $this->_panel_page,
137
  'admin-tabs' => $admin_tabs,
138
- 'options-path' => YITH_YWZM_DIR . '/plugin-options'
139
- );
 
 
140
 
141
  /* === Fixed: not updated theme === */
142
  if ( ! class_exists( 'YIT_Plugin_Panel_WooCommerce' ) ) {
135
  'parent_page' => 'yit_plugin_panel',
136
  'page' => $this->_panel_page,
137
  'admin-tabs' => $admin_tabs,
138
+ 'options-path' => YITH_YWZM_DIR . '/plugin-options',
139
+ 'class' => yith_set_wrapper_class(),
140
+
141
+ );
142
 
143
  /* === Fixed: not updated theme === */
144
  if ( ! class_exists( 'YIT_Plugin_Panel_WooCommerce' ) ) {
plugin-fw/.gitignore DELETED
@@ -1,4 +0,0 @@
1
-
2
- assets/\.DS_Store
3
-
4
- \.DS_Store
 
 
 
 
plugin-fw/assets/css/yith-fields.css CHANGED
@@ -29,6 +29,7 @@
29
 
30
  .yith-plugin-fw-title-field-wrapper h3.title {
31
  width: 100%;
 
32
  }
33
 
34
  .the-metabox .yith-plugin-fw-title-field-wrapper h3.title {
@@ -460,6 +461,10 @@ YITH UI
460
  -moz-osx-font-smoothing: grayscale;
461
  }
462
 
 
 
 
 
463
  .yith-icon-calendar_add:before {
464
  content: "\e913";
465
  color: #757575;
@@ -764,7 +769,9 @@ YITH UI
764
  .yith-plugin-ui #plugin-fw-wc table.form-table th, #yith-plugin-fw-panel table.form-table th.titledesc, .yith-plugin-ui #plugin-fw-wc table.form-table td, #yith-plugin-fw-panel table.form-table td.forminp {
765
  padding: 30px 20px;
766
  }
767
-
 
 
768
  .yith-plugin-ui #plugin-fw-wc h2 + div {
769
  background: #fff;
770
  border-left: 1px solid #d9d9d9;
@@ -1194,11 +1201,7 @@ YITH UI
1194
  .yith-plugin-ui .select2-container--default .select2-results__option[data-selected=true],
1195
  .yith-plugin-ui .select2-container--default .select2-results__option[aria-selected=true],
1196
  .yith-plugin-fw-panel .select2-container--default .select2-results__option[data-selected=true],
1197
- .yith-plugin-fw-panel .select2-container--default .select2-results__option[aria-selected=true] {
1198
- background-color: #fff;
1199
- outline: none;
1200
- }
1201
-
1202
  .yith-plugin-ui .select2-container--default .select2-results__option--highlighted[aria-selected],
1203
  .yith-plugin-ui .select2-container--default .select2-results__option--highlighted[data-selected],
1204
  .yith-plugin-fw-panel .select2-container--default .select2-results__option--highlighted[aria-selected],
@@ -1675,7 +1678,7 @@ DATEPICKER
1675
  }
1676
 
1677
  .yith-plugin-ui .wp-picker-default-custom:before {
1678
- content: "\e910";
1679
  text-indent: 0;
1680
  font-family: 'yith-icon';
1681
  font-size: 20px;
@@ -1797,7 +1800,9 @@ DATEPICKER
1797
  cursor: pointer;
1798
  transition: all ease 0.5s;
1799
  }
1800
-
 
 
1801
  .yith-plugin-ui .yith-toggle-row.highlight {
1802
  transition: all ease 0.5s;
1803
  /*box-shadow: 0 0 7px rgb(81, 117, 129);*/
@@ -1882,7 +1887,7 @@ DATEPICKER
1882
  }
1883
 
1884
  .yith-plugin-ui .yith-add-box-row label,
1885
- .yith-plugin-ui .yith-toggle-row-opened .yith-toggle-content .yith-toggle-content-row label {
1886
  display: table-cell;
1887
  width: 200px;
1888
  padding-right: 21px;
@@ -2089,16 +2094,35 @@ DATEPICKER
2089
  border: 0;
2090
  }
2091
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2092
  @media screen and (max-width: 1440px) {
2093
  .yith-plugin-ui .yith-add-box,
2094
- .yith-plugin-ui .yith-toggle-row {
2095
  width: 80%;
2096
  }
2097
  }
2098
 
2099
  @media screen and (max-width: 1024px) {
2100
  .yith-plugin-ui .yith-add-box,
2101
- .yith-plugin-ui .yith-toggle-row {
2102
  width: 90%;
2103
  }
2104
 
29
 
30
  .yith-plugin-fw-title-field-wrapper h3.title {
31
  width: 100%;
32
+ padding: 0 !important;
33
  }
34
 
35
  .the-metabox .yith-plugin-fw-title-field-wrapper h3.title {
461
  -moz-osx-font-smoothing: grayscale;
462
  }
463
 
464
+ .yith-icon-reply:before {
465
+ content: "\e91a";
466
+ color: #757575;
467
+ }
468
  .yith-icon-calendar_add:before {
469
  content: "\e913";
470
  color: #757575;
769
  .yith-plugin-ui #plugin-fw-wc table.form-table th, #yith-plugin-fw-panel table.form-table th.titledesc, .yith-plugin-ui #plugin-fw-wc table.form-table td, #yith-plugin-fw-panel table.form-table td.forminp {
770
  padding: 30px 20px;
771
  }
772
+ .yith-plugin-ui #plugin-fw-wc table.form-table tr.toggle-element-fixed td, #yith-plugin-fw-panel table.form-table tr.toggle-element-fixed td.forminp {
773
+ padding: 0 20px 30px;
774
+ }
775
  .yith-plugin-ui #plugin-fw-wc h2 + div {
776
  background: #fff;
777
  border-left: 1px solid #d9d9d9;
1201
  .yith-plugin-ui .select2-container--default .select2-results__option[data-selected=true],
1202
  .yith-plugin-ui .select2-container--default .select2-results__option[aria-selected=true],
1203
  .yith-plugin-fw-panel .select2-container--default .select2-results__option[data-selected=true],
1204
+ .yith-plugin-fw-panel .select2-container--default .select2-results__option[aria-selected=true],
 
 
 
 
1205
  .yith-plugin-ui .select2-container--default .select2-results__option--highlighted[aria-selected],
1206
  .yith-plugin-ui .select2-container--default .select2-results__option--highlighted[data-selected],
1207
  .yith-plugin-fw-panel .select2-container--default .select2-results__option--highlighted[aria-selected],
1678
  }
1679
 
1680
  .yith-plugin-ui .wp-picker-default-custom:before {
1681
+ content: "\e91a";
1682
  text-indent: 0;
1683
  font-family: 'yith-icon';
1684
  font-size: 20px;
1800
  cursor: pointer;
1801
  transition: all ease 0.5s;
1802
  }
1803
+ .yith-plugin-ui .yith-toggle-row.fixed {
1804
+ margin: 0;
1805
+ }
1806
  .yith-plugin-ui .yith-toggle-row.highlight {
1807
  transition: all ease 0.5s;
1808
  /*box-shadow: 0 0 7px rgb(81, 117, 129);*/
1887
  }
1888
 
1889
  .yith-plugin-ui .yith-add-box-row label,
1890
+ .yith-plugin-ui .yith-toggle-row-opened .yith-toggle-content .yith-toggle-content-row > label {
1891
  display: table-cell;
1892
  width: 200px;
1893
  padding-right: 21px;
2094
  border: 0;
2095
  }
2096
 
2097
+ /** MULTI SELECT **/
2098
+ .yith-plugin-ui .yith-plugin-fw-multi-select .yith-single-select {
2099
+ display: inline-block;
2100
+ width: 30%;
2101
+ margin-right: 3%;
2102
+ max-width: 400px;
2103
+ }
2104
+ .yith-plugin-ui .yith-plugin-fw-multi-select .yith-single-select label {
2105
+ display: block;
2106
+ font-size: 11px;
2107
+ font-weight: 600;
2108
+ margin: 0 0 10px 0;
2109
+ }
2110
+ .yith-plugin-ui .yith-plugin-fw-multi-select .yith-single-select select,
2111
+ .yith-plugin-ui .yith-plugin-fw-multi-select .yith-single-select span.select2 {
2112
+ width: 100% !important;
2113
+ min-width: auto !important;
2114
+ }
2115
+
2116
  @media screen and (max-width: 1440px) {
2117
  .yith-plugin-ui .yith-add-box,
2118
+ .yith-plugin-ui .yith-toggle-row:not(.fixed) {
2119
  width: 80%;
2120
  }
2121
  }
2122
 
2123
  @media screen and (max-width: 1024px) {
2124
  .yith-plugin-ui .yith-add-box,
2125
+ .yith-plugin-ui .yith-toggle-row:not(.fixed) {
2126
  width: 90%;
2127
  }
2128
 
plugin-fw/assets/fonts/yith-icon.eot CHANGED
Binary file
plugin-fw/assets/fonts/yith-icon.svg CHANGED
@@ -33,4 +33,5 @@
33
  <glyph unicode="&#xe917;" glyph-name="shield_money" d="M146.091 837.12v-530.261l365.909-284.501 365.909 284.672v530.091h-219.477v-73.216h-36.523v109.739h-219.648v-109.739h-36.523v73.216h-219.648zM475.477 690.859v109.739h73.216v-109.739h182.955v73.216h73.216v-421.205l-292.864-227.669-292.693 227.669v421.035h73.216v-73.216h182.955zM548.523 324.949h-73.216c-20.139 0-36.523 16.384-36.523 36.523h-73.216c0-60.587 49.152-109.739 109.739-109.739v-36.523h73.216v36.523c60.587 0 109.739 49.152 109.739 109.739s-49.152 109.739-109.739 109.739h-73.216c-20.139 0-36.523 16.384-36.523 36.523s16.384 36.523 36.523 36.523h73.216c20.139 0 36.523-16.384 36.523-36.523h73.216c0 60.587-49.152 109.739-109.739 109.739v36.523h-73.216v-36.523c-60.587 0-109.739-49.152-109.739-109.739s49.152-109.739 109.739-109.739h73.216c20.139 0 36.523-16.384 36.523-36.523s-16.213-36.523-36.523-36.523z" />
34
  <glyph unicode="&#xe918;" glyph-name="time_check" d="M86.528 448.341c-0.341-235.008 189.952-425.643 424.96-425.984s425.643 189.952 425.984 424.96c0.171 83.968-24.576 166.059-71.168 236.032l-60.075-63.488c22.528-39.765 37.035-83.627 42.325-129.195h-80.384v-84.651h80.384c-19.627-154.795-141.483-276.651-296.277-296.277v84.651h-84.651v-84.651c-154.795 19.456-276.821 141.483-296.277 296.277h84.651v84.651h-84.651c18.432 155.307 140.971 277.845 296.277 296.277v-82.603h84.651v81.749c46.251-5.803 90.795-21.163 130.731-44.885l61.44 61.44c-68.779 46.080-149.675 70.827-232.448 71.168-234.837-0.341-425.301-190.635-425.472-425.472zM414.549 605.355l-59.563-59.733 157.013-157.013 410.624 410.965-59.733 59.733-350.891-350.891z" />
35
  <glyph unicode="&#xe919;" glyph-name="world_settings" d="M833.707 597.333l48.981 81.92-139.435 139.435-81.92-48.981c-8.875 4.267-18.091 7.851-27.648 11.435l-23.040 92.672h-98.645c-235.179-0.171-425.643-190.635-425.643-425.813s190.464-425.643 425.643-425.643h98.645l23.040 92.672c9.557 3.584 18.773 7.168 27.648 11.435l81.92-48.981 139.435 139.435-48.981 81.92c3.925 8.875 7.851 18.091 11.435 27.648l92.672 23.040v197.12l-92.672 23.040c-3.584 9.557-7.168 20.139-11.435 27.648zM319.659 448c0.171 35.669 3.243 71.339 9.216 106.496h147.627v-212.821h-147.627c-5.973 34.987-9.045 70.656-9.216 106.325zM476.501 795.989v-170.667h-129.877c28.16 86.699 75.264 150.869 129.877 170.667zM476.501 270.677v-171.008c-54.613 19.797-101.888 84.139-129.877 171.008h129.877zM547.499 547.669c55.125-20.309 83.456-81.579 63.147-136.704-10.752-29.184-33.792-52.224-63.147-63.147v199.851zM323.925 748.203c-22.869-38.4-40.277-79.701-51.712-122.709h-67.072c29.013 49.835 69.803 91.989 118.784 122.709zM173.568 554.496h83.797c-11.435-70.485-11.435-142.336 0-212.821h-83.797c-21.845 69.12-21.845 143.531 0 212.821zM205.141 270.677h67.072c11.435-43.179 29.013-84.651 51.712-123.051-48.981 30.72-89.771 73.045-118.784 123.051zM866.816 404.651l-77.312-19.456-5.632-19.115c-5.632-18.091-12.8-35.669-21.675-52.565l-9.557-17.749 40.789-68.096-61.099-61.44-68.437 41.301-17.749-9.557c-16.725-8.875-34.133-16.043-52.224-21.675l-19.456-5.632-19.115-77.312h-7.851v180.907c96.085 19.456 158.037 113.152 138.581 209.067-14.165 69.803-68.779 124.416-138.581 138.581v180.907h7.851l19.115-77.312 19.456-5.632c18.091-5.973 35.669-13.824 52.224-23.381l17.749-9.557 68.437 40.789 61.099-61.099-40.96-66.731 9.557-17.749c8.875-16.555 16.213-34.133 21.675-52.224l5.632-19.456 77.312-19.115 0.171-86.699z" />
 
36
  </font></defs></svg>
33
  <glyph unicode="&#xe917;" glyph-name="shield_money" d="M146.091 837.12v-530.261l365.909-284.501 365.909 284.672v530.091h-219.477v-73.216h-36.523v109.739h-219.648v-109.739h-36.523v73.216h-219.648zM475.477 690.859v109.739h73.216v-109.739h182.955v73.216h73.216v-421.205l-292.864-227.669-292.693 227.669v421.035h73.216v-73.216h182.955zM548.523 324.949h-73.216c-20.139 0-36.523 16.384-36.523 36.523h-73.216c0-60.587 49.152-109.739 109.739-109.739v-36.523h73.216v36.523c60.587 0 109.739 49.152 109.739 109.739s-49.152 109.739-109.739 109.739h-73.216c-20.139 0-36.523 16.384-36.523 36.523s16.384 36.523 36.523 36.523h73.216c20.139 0 36.523-16.384 36.523-36.523h73.216c0 60.587-49.152 109.739-109.739 109.739v36.523h-73.216v-36.523c-60.587 0-109.739-49.152-109.739-109.739s49.152-109.739 109.739-109.739h73.216c20.139 0 36.523-16.384 36.523-36.523s-16.213-36.523-36.523-36.523z" />
34
  <glyph unicode="&#xe918;" glyph-name="time_check" d="M86.528 448.341c-0.341-235.008 189.952-425.643 424.96-425.984s425.643 189.952 425.984 424.96c0.171 83.968-24.576 166.059-71.168 236.032l-60.075-63.488c22.528-39.765 37.035-83.627 42.325-129.195h-80.384v-84.651h80.384c-19.627-154.795-141.483-276.651-296.277-296.277v84.651h-84.651v-84.651c-154.795 19.456-276.821 141.483-296.277 296.277h84.651v84.651h-84.651c18.432 155.307 140.971 277.845 296.277 296.277v-82.603h84.651v81.749c46.251-5.803 90.795-21.163 130.731-44.885l61.44 61.44c-68.779 46.080-149.675 70.827-232.448 71.168-234.837-0.341-425.301-190.635-425.472-425.472zM414.549 605.355l-59.563-59.733 157.013-157.013 410.624 410.965-59.733 59.733-350.891-350.891z" />
35
  <glyph unicode="&#xe919;" glyph-name="world_settings" d="M833.707 597.333l48.981 81.92-139.435 139.435-81.92-48.981c-8.875 4.267-18.091 7.851-27.648 11.435l-23.040 92.672h-98.645c-235.179-0.171-425.643-190.635-425.643-425.813s190.464-425.643 425.643-425.643h98.645l23.040 92.672c9.557 3.584 18.773 7.168 27.648 11.435l81.92-48.981 139.435 139.435-48.981 81.92c3.925 8.875 7.851 18.091 11.435 27.648l92.672 23.040v197.12l-92.672 23.040c-3.584 9.557-7.168 20.139-11.435 27.648zM319.659 448c0.171 35.669 3.243 71.339 9.216 106.496h147.627v-212.821h-147.627c-5.973 34.987-9.045 70.656-9.216 106.325zM476.501 795.989v-170.667h-129.877c28.16 86.699 75.264 150.869 129.877 170.667zM476.501 270.677v-171.008c-54.613 19.797-101.888 84.139-129.877 171.008h129.877zM547.499 547.669c55.125-20.309 83.456-81.579 63.147-136.704-10.752-29.184-33.792-52.224-63.147-63.147v199.851zM323.925 748.203c-22.869-38.4-40.277-79.701-51.712-122.709h-67.072c29.013 49.835 69.803 91.989 118.784 122.709zM173.568 554.496h83.797c-11.435-70.485-11.435-142.336 0-212.821h-83.797c-21.845 69.12-21.845 143.531 0 212.821zM205.141 270.677h67.072c11.435-43.179 29.013-84.651 51.712-123.051-48.981 30.72-89.771 73.045-118.784 123.051zM866.816 404.651l-77.312-19.456-5.632-19.115c-5.632-18.091-12.8-35.669-21.675-52.565l-9.557-17.749 40.789-68.096-61.099-61.44-68.437 41.301-17.749-9.557c-16.725-8.875-34.133-16.043-52.224-21.675l-19.456-5.632-19.115-77.312h-7.851v180.907c96.085 19.456 158.037 113.152 138.581 209.067-14.165 69.803-68.779 124.416-138.581 138.581v180.907h7.851l19.115-77.312 19.456-5.632c18.091-5.973 35.669-13.824 52.224-23.381l17.749-9.557 68.437 40.789 61.099-61.099-40.96-66.731 9.557-17.749c8.875-16.555 16.213-34.133 21.675-52.224l5.632-19.456 77.312-19.115 0.171-86.699z" />
36
+ <glyph unicode="&#xe91a;" glyph-name="reply" d="M426 554.667q208-30 321-159t149-311q-154 218-470 218v-174l-298 298 298 298v-170z" />
37
  </font></defs></svg>
plugin-fw/assets/fonts/yith-icon.ttf CHANGED
Binary file
plugin-fw/assets/fonts/yith-icon.woff CHANGED
Binary file
plugin-fw/init.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
  /**
3
  * Framework Name: YIT Plugin Framework
4
- * Version: 3.3.13
5
  * Author: YITHEMES
6
  * Text Domain: yith-plugin-fw
7
  * Domain Path: /languages/
1
  <?php
2
  /**
3
  * Framework Name: YIT Plugin Framework
4
+ * Version: 3.3.15
5
  * Author: YITHEMES
6
  * Text Domain: yith-plugin-fw
7
  * Domain Path: /languages/
plugin-fw/lib/promo/yith-promo.php CHANGED
@@ -12,6 +12,7 @@ if( ! function_exists( 'simplexml_load_string' ) ){
12
  return false;
13
  }
14
 
 
15
  add_action( 'admin_notices', 'yith_plugin_fw_promo_notices', 15 );
16
  add_action( 'admin_enqueue_scripts', 'yith_plugin_fw_notice_dismiss', 20 );
17
 
@@ -36,33 +37,38 @@ if( ! function_exists( 'yith_plugin_fw_promo_notices' ) ){
36
 
37
  if ( ! is_wp_error( $remote_data ) && ! empty( $remote_data ) ) {
38
  $promo_data = @simplexml_load_string( $remote_data );
39
- if( true === $create_transient ){
40
- $is_membership_user = false;
41
- $license = function_exists( 'YITH_Plugin_Licence' ) ? YITH_Plugin_Licence()->get_licence() : array();
42
- $xml_expiry_date = '';
43
-
44
- if( is_array( $license ) && apply_filters( 'yith_plugin_fw_check_for_membership_user', true ) ){
45
- /* === Check is the user have the YITH Club === */
46
- foreach( $license as $plugin => $data ){
47
- if( ! empty( $data['is_membership'] ) ){
48
- $is_membership_user = true;
49
- $xml_expiry_date = $data['licence_expires'];
50
- $remote_data = $promo_data = array();
51
- break;
52
- }
 
 
 
53
  }
54
- }
 
55
 
56
- if( empty( $is_membership_user ) && ! empty( $promo_data->expiry_date ) ){
57
- $xml_expiry_date = $promo_data->expiry_date;
58
- }
59
 
 
60
  //Set Site Transient
61
  set_site_transient( $transient, $remote_data, yith_plugin_fw_get_promo_transient_expiry_date( $xml_expiry_date ) );
62
  }
63
 
64
  if ( $promo_data && ! empty( $promo_data->promo ) ) {
65
- $now = strtotime( current_time( 'mysql' ) );
66
 
67
  foreach ($promo_data->promo as $promo ){
68
  $show_promo = true;
@@ -186,4 +192,13 @@ if( ! function_exists( 'yith_plugin_fw_get_promo_transient_expiry_date' ) ){
186
 
187
  return $expiry_date;
188
  }
 
 
 
 
 
 
 
 
 
189
  }
12
  return false;
13
  }
14
 
15
+ add_action( 'admin_notices', 'yith_plugin_fw_regenerate_transient' );
16
  add_action( 'admin_notices', 'yith_plugin_fw_promo_notices', 15 );
17
  add_action( 'admin_enqueue_scripts', 'yith_plugin_fw_notice_dismiss', 20 );
18
 
37
 
38
  if ( ! is_wp_error( $remote_data ) && ! empty( $remote_data ) ) {
39
  $promo_data = @simplexml_load_string( $remote_data );
40
+
41
+ /**
42
+ * Check if current user is an YITH Club Members
43
+ */
44
+ $is_membership_user = false;
45
+ $license = function_exists( 'YITH_Plugin_Licence' ) ? YITH_Plugin_Licence()->get_licence() : array();
46
+ $xml_expiry_date = '';
47
+
48
+ if( is_array( $license ) && apply_filters( 'yith_plugin_fw_check_for_membership_user', true ) ){
49
+ /* === Check is the user have the YITH Club === */
50
+ foreach( $license as $plugin => $data ){
51
+ if( ! empty( $data['is_membership'] ) ){
52
+ $is_membership_user = true;
53
+ $xml_expiry_date = $data['licence_expires'];
54
+ $remote_data = $promo_data = array();
55
+ $create_transient = true;
56
+ break;
57
  }
58
+ }
59
+ }
60
 
61
+ if( empty( $is_membership_user ) && ! empty( $promo_data->expiry_date ) ){
62
+ $xml_expiry_date = $promo_data->expiry_date;
63
+ }
64
 
65
+ if( true === $create_transient ){
66
  //Set Site Transient
67
  set_site_transient( $transient, $remote_data, yith_plugin_fw_get_promo_transient_expiry_date( $xml_expiry_date ) );
68
  }
69
 
70
  if ( $promo_data && ! empty( $promo_data->promo ) ) {
71
+ $now = apply_filters( 'yith_plugin_fw_promo_now_date', strtotime( current_time( 'mysql' ) ) );
72
 
73
  foreach ($promo_data->promo as $promo ){
74
  $show_promo = true;
192
 
193
  return $expiry_date;
194
  }
195
+ }
196
+
197
+ if( ! function_exists( 'yith_plugin_fw_regenerate_transient' ) ){
198
+ function yith_plugin_fw_regenerate_transient(){
199
+ if( false === get_option( 'yith_plugin_fw_promo_2019', false ) ){
200
+ delete_site_transient( 'yith_promo_message' );
201
+ update_option( 'yith_plugin_fw_promo_2019', true );
202
+ }
203
+ }
204
  }
plugin-fw/lib/promo/yith-promo.xml CHANGED
@@ -28,7 +28,7 @@
28
  <banner>cyber.jpg</banner>
29
  <title><![CDATA[<strong>YITH Cyber Monday</strong>]]></title>
30
  <description><![CDATA[
31
- Don't miss our <strong>30% discount</strong> on all our products! No coupon needed in cart. Valid from <strong>28th November</strong> to <strong>30th November</strong>.
32
  ]]></description>
33
  <link>
34
  <label>Get your deals now!</label>
@@ -47,7 +47,7 @@
47
  <banner>black.jpg</banner>
48
  <title><![CDATA[<strong>YITH Black Friday</strong>]]></title>
49
  <description><![CDATA[
50
- Don't miss our <strong>30% discount</strong> on all our products! No coupon needed in cart. Valid from <strong>1st December</strong> to <strong>2nd December</strong>.
51
  ]]></description>
52
  <link>
53
  <label>Get your deals now!</label>
28
  <banner>cyber.jpg</banner>
29
  <title><![CDATA[<strong>YITH Cyber Monday</strong>]]></title>
30
  <description><![CDATA[
31
+ Don't miss our <strong>30% discount</strong> on all our products! No coupon needed in cart. Valid from <strong>1st December</strong> to <strong>2nd December</strong>.
32
  ]]></description>
33
  <link>
34
  <label>Get your deals now!</label>
47
  <banner>black.jpg</banner>
48
  <title><![CDATA[<strong>YITH Black Friday</strong>]]></title>
49
  <description><![CDATA[
50
+ Don't miss our <strong>30% discount</strong> on all our products! No coupon needed in cart. Valid from <strong>28th November</strong> to <strong>30th November</strong>.
51
  ]]></description>
52
  <link>
53
  <label>Get your deals now!</label>
plugin-fw/lib/yit-cpt-unlimited.php CHANGED
@@ -1592,7 +1592,7 @@ class YIT_CPT_Unlimited {
1592
  public function admin_assets() {
1593
  $suffix = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min';
1594
  wp_enqueue_media();
1595
- wp_enqueue_script( 'yit-cptu', YIT_CORE_PLUGIN_URL . '/assets/js/yit-cpt-unlimited' . $suffix . 'js', array('jquery'), '', true );
1596
  }
1597
 
1598
  /**
1592
  public function admin_assets() {
1593
  $suffix = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min';
1594
  wp_enqueue_media();
1595
+ wp_enqueue_script( 'yit-cptu', YIT_CORE_PLUGIN_URL . '/assets/js/yit-cpt-unlimited' . $suffix . '.js', array('jquery'), '', true );
1596
  }
1597
 
1598
  /**
plugin-fw/lib/yit-plugin-panel-wc.php CHANGED
@@ -588,7 +588,7 @@ if ( !class_exists( 'YIT_Plugin_Panel_WooCommerce' ) ) {
588
 
589
  $value = apply_filters( 'yith_plugin_fw_wc_panel_pre_field_value', null, $field );
590
  if ( is_null( $value ) ) {
591
- if ( 'toggle-element' === $field[ 'type' ] ) {
592
  $value = get_option( $field[ 'id' ], $field[ 'default' ] );
593
  } else {
594
  $value = WC_Admin_Settings::get_option( $field[ 'id' ], $field[ 'default' ] );
588
 
589
  $value = apply_filters( 'yith_plugin_fw_wc_panel_pre_field_value', null, $field );
590
  if ( is_null( $value ) ) {
591
+ if ( 'toggle-element' === $field[ 'type' ] || 'toggle-element-fixed' === $field[ 'type' ] ) {
592
  $value = get_option( $field[ 'id' ], $field[ 'default' ] );
593
  } else {
594
  $value = WC_Admin_Settings::get_option( $field[ 'id' ], $field[ 'default' ] );
plugin-fw/templates/fields/multi-select.php ADDED
@@ -0,0 +1,46 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * This file belongs to the YIT Plugin Framework.
4
+ *
5
+ * This source file is subject to the GNU GENERAL PUBLIC LICENSE (GPL 3.0)
6
+ * that is bundled with this package in the file LICENSE.txt.
7
+ * It is also available through the world-wide-web at this URL:
8
+ * http://www.gnu.org/licenses/gpl-3.0.txt
9
+ *
10
+ * @var array $field
11
+ */
12
+
13
+ !defined( 'ABSPATH' ) && exit; // Exit if accessed directly
14
+
15
+ extract( $field );
16
+ if ( empty( $selects ) ){
17
+ return;
18
+ }
19
+ ?>
20
+ <div class="yith-plugin-fw-multi-select" id="<?php echo esc_attr( $id ) ?>">
21
+ <?php
22
+ for( $i = 0; $i < count( $selects ); $i++ ) :
23
+ // open group
24
+ if( ( $i%2 ) == 0 ) : ?>
25
+ <div class="yith-select-group">
26
+ <?php endif; ?>
27
+
28
+ <div class="yith-single-select">
29
+ <?php
30
+ $select = $selects[$i];
31
+ $select['type'] = 'select';
32
+ $select['title'] = isset( $select['title'] ) ? $select['title'] : $select['name'];
33
+ $select['name'] = $name."[{$select['id']}]";
34
+ $select['value'] = isset( $value[$select['id']] ) ? $value[$select['id']] : $select['default'];
35
+ $select['id'] = $name."_".$select['id'];
36
+ $select['class'] = $class
37
+ ?>
38
+ <label for="<?php echo esc_attr( $select['id'] ); ?>"><?php echo esc_html( $select['title'] ); ?></label>
39
+ <?php yith_plugin_fw_get_field( $select, true, false ); ?>
40
+ </div>
41
+
42
+ <?php if( ( $i%2 ) != 0 || ! isset( $selects[$i+1] ) ) : ?>
43
+ </div>
44
+ <?php endif;
45
+ endfor; ?>
46
+ </div>
plugin-fw/templates/fields/select.php CHANGED
@@ -30,9 +30,17 @@ $class = isset( $class ) ? $class : 'yith-plugin-fw-select';
30
  <?php echo $placeholder ?>
31
  <?php echo $custom_attributes ?>
32
  <?php if ( isset( $data ) ) echo yith_plugin_fw_html_data_to_string( $data ); ?>>
33
- <?php foreach ( $options as $key => $item ) : ?>
34
- <option value="<?php echo esc_attr( $key ) ?>" <?php if ( $multiple ): selected( true, in_array( $key, $value ) );
35
- else: selected( $key, $value ); endif; ?> ><?php echo $item ?></option>
 
 
 
 
 
 
 
 
36
  <?php endforeach; ?>
37
  </select>
38
 
30
  <?php echo $placeholder ?>
31
  <?php echo $custom_attributes ?>
32
  <?php if ( isset( $data ) ) echo yith_plugin_fw_html_data_to_string( $data ); ?>>
33
+ <?php foreach ( $options as $key => $item ) :
34
+ if( is_array( $item ) ): ?>
35
+ <optgroup label="<?php esc_attr_e( $item['label'] ) ?>">
36
+ <?php foreach( $item['options'] as $option_key => $option ) : ?>
37
+ <option value="<?php echo esc_attr( $option_key ) ?>" <?php selected( $option_key, $value ); ?>><?php echo $option ?></option>
38
+ <?php endforeach; ?>
39
+ </optgroup>
40
+ <?php else: ?>
41
+ <option value="<?php echo esc_attr( $key ) ?>" <?php if ( $multiple ): selected( true, in_array( $key, $value ) );
42
+ else: selected( $key, $value ); endif; ?> ><?php echo $item ?></option>
43
+ <?php endif; ?>
44
  <?php endforeach; ?>
45
  </select>
46
 
plugin-fw/templates/fields/title.php CHANGED
@@ -13,5 +13,5 @@
13
 
14
  extract( $field );
15
  ?>
16
- <h3 class="title" <?php echo $custom_attributes ?>
17
  <?php if ( isset( $data ) ) echo yith_plugin_fw_html_data_to_string( $data ); ?>><?php echo $desc ?></h3>
13
 
14
  extract( $field );
15
  ?>
16
+ <h3 id="<?php echo $id ?>" class="title" <?php echo $custom_attributes ?>
17
  <?php if ( isset( $data ) ) echo yith_plugin_fw_html_data_to_string( $data ); ?>><?php echo $desc ?></h3>
plugin-fw/templates/fields/toggle-element-fixed.php ADDED
@@ -0,0 +1,68 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) {
3
+ exit;
4
+ }
5
+
6
+ $defaults = array(
7
+ 'id' => '',
8
+ 'name' => '',
9
+ 'class' => '',
10
+ 'custom_attributes' => '',
11
+ 'elements' => [],
12
+ 'onoff_field' => true,
13
+
14
+ );
15
+ $field = wp_parse_args( $field, $defaults );
16
+
17
+ extract( $field );
18
+
19
+ empty( $name ) && $name = $id;
20
+ $value = get_option( $name, [] );
21
+ ?>
22
+ <div class="yith-toggle_fixed_wrapper" id="<?php echo $id ?>" >
23
+ <div class="yith-toggle-elements">
24
+ <div id="<?php echo $id; ?>" class="yith-toggle-row fixed <?php echo ! empty( $subtitle ) ? 'with-subtitle' : ''; ?> <?php echo $class; ?>" <?php echo $custom_attributes; ?>>
25
+ <div class="yith-toggle-title">
26
+ <h3>
27
+ <span class="title"><?php echo $title ?></span>
28
+ <?php if ( ! empty( $subtitle ) ): ?>
29
+ <span class="subtitle"><?php echo $subtitle; ?></span>
30
+ <?php endif; ?>
31
+ </h3>
32
+ <span class="yith-toggle"><span class="yith-icon yith-icon-arrow_right ui-sortable-handle"></span></span>
33
+ <?php
34
+ // add on off field if needed
35
+ if( ! empty( $onoff_field ) ) : ?>
36
+ <span class="yith-toggle-onoff">
37
+ <?php yith_plugin_fw_get_field( [
38
+ 'type' => 'onoff',
39
+ 'name' => "{$name}[enabled]",
40
+ 'id' => "{$id}_enabled",
41
+ 'value' => isset( $value['enabled'] ) ? $value['enabled'] : 'no',
42
+ ], true );
43
+ ?>
44
+ </span>
45
+ <?php endif; ?>
46
+ </div>
47
+ <div class="yith-toggle-content">
48
+ <?php foreach ( $elements as $element ):
49
+ // build correct name and id
50
+ $field_id = $element['id'];
51
+ $element['name'] = "{$name}[{$field_id}]";
52
+ $element['id'] = "{$id}_{$field_id}";
53
+ // get value
54
+ $element['value'] = isset( $value[ $field_id ] ) ? $value[ $field_id ] : ( isset( $element['default'] ) ? $element['default'] : '' );
55
+ ?>
56
+ <div class="yith-toggle-content-row <?php echo $element['type'] ?>">
57
+ <label for="<?php echo $element['id']; ?>"><?php echo $element['title']; ?></label>
58
+ <div class="yith-plugin-fw-option-with-description">
59
+ <?php yith_plugin_fw_get_field( $element, true ); ?>
60
+ <span class="description"><?php echo ! empty( $element['desc'] ) ? $element['desc'] : ''; ?></span>
61
+ </div>
62
+ </div>
63
+ <?php endforeach;
64
+ ?>
65
+ </div>
66
+ </div>
67
+ </div>
68
+ </div>
plugin-fw/templates/sysinfo/system-information-panel.php CHANGED
@@ -10,6 +10,19 @@
10
 
11
  $system_info = get_option( 'yith_system_info' );
12
  $recommended_memory = 134217728;
 
 
 
 
 
 
 
 
 
 
 
 
 
13
 
14
  ?>
15
  <div id="yith-sysinfo" class="wrap yith-system-info">
@@ -19,6 +32,25 @@ $recommended_memory = 134217728;
19
 
20
  <?php if ( ! isset( $_GET['yith-phpinfo'] ) || $_GET['yith-phpinfo'] != 'true' ): ?>
21
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
22
  <table class="widefat striped">
23
  <?php foreach ( $system_info['system_info'] as $key => $item ): ?>
24
  <?php
10
 
11
  $system_info = get_option( 'yith_system_info' );
12
  $recommended_memory = 134217728;
13
+ $output_ip = 'n/a';
14
+
15
+ if ( function_exists( 'curl_init' ) && apply_filters( 'yith_system_status_check_ip', true ) ) {
16
+ //Get Output IP Address
17
+ $ch = curl_init();
18
+ curl_setopt( $ch, CURLOPT_URL, 'https://ifconfig.co/ip' );
19
+ curl_setopt( $ch, CURLOPT_SSL_VERIFYHOST, 0 );
20
+ curl_setopt( $ch, CURLOPT_SSL_VERIFYPEER, 0 );
21
+ curl_setopt( $ch, CURLOPT_RETURNTRANSFER, 1 );
22
+ $data = curl_exec( $ch );
23
+ curl_close( $ch );
24
+ $output_ip = $data != '' ? $data : 'n/a';
25
+ }
26
 
27
  ?>
28
  <div id="yith-sysinfo" class="wrap yith-system-info">
32
 
33
  <?php if ( ! isset( $_GET['yith-phpinfo'] ) || $_GET['yith-phpinfo'] != 'true' ): ?>
34
 
35
+ <table class="widefat striped">
36
+ <tr>
37
+ <th>
38
+ <?php _e( 'Site URL', 'yith-plugin-fw' ); ?>
39
+ </th>
40
+ <td class="requirement-value">
41
+ <?php echo get_site_url() ?>
42
+ </td>
43
+ </tr>
44
+ <tr>
45
+ <th>
46
+ <?php _e( 'Output IP Address', 'yith-plugin-fw' ); ?>
47
+ </th>
48
+ <td class="requirement-value">
49
+ <?php echo $output_ip ?>
50
+ </td>
51
+ </tr>
52
+ </table>
53
+
54
  <table class="widefat striped">
55
  <?php foreach ( $system_info['system_info'] as $key => $item ): ?>
56
  <?php
plugin-fw/yit-functions.php CHANGED
@@ -1008,6 +1008,12 @@ if ( !function_exists( 'yith_plugin_fw_get_field' ) ) {
1008
 
1009
  $field_template = yith_plugin_fw_get_field_template_path( $field );
1010
 
 
 
 
 
 
 
1011
  if ( $field_template ) {
1012
  if ( !$echo )
1013
  ob_start();
1008
 
1009
  $field_template = yith_plugin_fw_get_field_template_path( $field );
1010
 
1011
+ if ( !isset( $field[ 'id' ] ) ) {
1012
+ static $field_number = 1;
1013
+ $field[ 'id' ] = "yith-plugin-fw-field__{$field_number}";
1014
+ $field_number++;
1015
+ }
1016
+
1017
  if ( $field_template ) {
1018
  if ( !$echo )
1019
  ob_start();
plugin-options/general-options.php CHANGED
@@ -100,6 +100,7 @@ $magnifier_settings = array(
100
  'std' => 'right',
101
  'default' => 'right',
102
  'type' => 'select',
 
103
  'options' => array(
104
  'right' => __( 'Right', 'yith-woocommerce-zoom-magnifier' ),
105
  'inside' => __( 'Inside', 'yith-woocommerce-zoom-magnifier' )
@@ -112,6 +113,7 @@ $magnifier_settings = array(
112
  'std' => 'default',
113
  'default' => 'inside',
114
  'type' => 'select',
 
115
  'options' => array(
116
  'default' => __( 'Default', 'yith-woocommerce-zoom-magnifier' ),
117
  'inside' => __( 'Inside', 'yith-woocommerce-zoom-magnifier' ),
@@ -131,11 +133,9 @@ $magnifier_settings = array(
131
  'name' => __( 'Lens Opacity', 'yith-woocommerce-zoom-magnifier' ),
132
  'desc' => '',
133
  'id' => 'yith_wcmg_lens_opacity',
134
- 'std' => 0.5,
135
- 'default' => 0.5,
136
- 'type' => 'slider',
137
- 'min' => 0,
138
- 'max' => 1,
139
  'step' => .1
140
  ),
141
  array(
@@ -176,11 +176,10 @@ $slider_settings = array(
176
  'name' => __( 'Items', 'yith-woocommerce-zoom-magnifier' ),
177
  'desc' => __( 'Number of items to show', 'yith-woocommerce-zoom-magnifier' ),
178
  'id' => 'yith_wcmg_slider_items',
179
- 'std' => 3,
180
  'default' => 3,
181
- 'type' => 'slider',
182
- 'min' => 1,
183
- 'max' => 10,
184
  'step' => 1
185
  ),
186
  array(
100
  'std' => 'right',
101
  'default' => 'right',
102
  'type' => 'select',
103
+ 'class' => 'wc-enhanced-select',
104
  'options' => array(
105
  'right' => __( 'Right', 'yith-woocommerce-zoom-magnifier' ),
106
  'inside' => __( 'Inside', 'yith-woocommerce-zoom-magnifier' )
113
  'std' => 'default',
114
  'default' => 'inside',
115
  'type' => 'select',
116
+ 'class' => 'wc-enhanced-select',
117
  'options' => array(
118
  'default' => __( 'Default', 'yith-woocommerce-zoom-magnifier' ),
119
  'inside' => __( 'Inside', 'yith-woocommerce-zoom-magnifier' ),
133
  'name' => __( 'Lens Opacity', 'yith-woocommerce-zoom-magnifier' ),
134
  'desc' => '',
135
  'id' => 'yith_wcmg_lens_opacity',
136
+ 'type' => 'yith-field',
137
+ 'yith-type' => 'slider',
138
+ 'option' => array( 'min' => 0, 'max' => 1 ),
 
 
139
  'step' => .1
140
  ),
141
  array(
176
  'name' => __( 'Items', 'yith-woocommerce-zoom-magnifier' ),
177
  'desc' => __( 'Number of items to show', 'yith-woocommerce-zoom-magnifier' ),
178
  'id' => 'yith_wcmg_slider_items',
 
179
  'default' => 3,
180
+ 'type' => 'yith-field',
181
+ 'yith-type' => 'slider',
182
+ 'option' => array( 'min' => 1, 'max' => 10 ),
183
  'step' => 1
184
  ),
185
  array(