Version Description
Download this release
Release Info
Developer | damian-gora |
Plugin | Ajax Search for WooCommerce |
Version | 1.8.1 |
Comparing to | |
See all releases |
Code changes from version 1.8.0 to 1.8.1
- ajax-search-for-woocommerce.php +2 -5
- assets/css/style.css +17 -10
- assets/css/style.min.css +1 -1
- assets/img/admin-troubleshooting-woof.png +0 -0
- assets/js/admin.js +2 -2
- assets/js/admin.min.js +1 -1
- assets/js/search.js +31 -5
- assets/js/search.min.js +1 -1
- composer/composer.json +1 -4
- composer/composer.lock +7 -57
- includes/Admin/Troubleshooting.php +52 -2
- includes/Helpers.php +18 -11
- includes/Integrations/Themes/Astra/Astra.php +6 -18
- includes/Integrations/Themes/Flatsome/Flatsome.php +33 -1
- includes/Integrations/Themes/Rehub/Rehub.php +20 -0
- includes/Integrations/Themes/Supro/Supro.php +20 -0
- includes/Integrations/Themes/ThemesCompatibility.php +8 -0
- includes/Personalization.php +6 -29
- includes/Setup.php +0 -13
- partials/themes/astra.php +183 -0
- partials/themes/divi.php +5 -6
- partials/themes/rehub-theme.php +53 -0
- partials/themes/supro.php +39 -0
- readme.txt +15 -1
- vendor/autoload.php +1 -1
- vendor/composer/ClassLoader.php +3 -3
- vendor/composer/InstalledVersions.php +209 -0
- vendor/composer/autoload_classmap.php +1 -1
- vendor/composer/autoload_namespaces.php +0 -1
- vendor/composer/autoload_real.php +8 -5
- vendor/composer/autoload_static.php +5 -16
- vendor/composer/installed.json +5 -56
- vendor/composer/installed.php +24 -0
- vendor/mobiledetect/mobiledetectlib/LICENSE.txt +0 -48
- vendor/mobiledetect/mobiledetectlib/Mobile_Detect.json +0 -1
- vendor/mobiledetect/mobiledetectlib/Mobile_Detect.php +0 -1477
- vendor/mobiledetect/mobiledetectlib/README.md +0 -344
- vendor/mobiledetect/mobiledetectlib/composer.json +0 -31
- vendor/mobiledetect/mobiledetectlib/composer.lock +0 -983
- vendor/mobiledetect/mobiledetectlib/docker-compose.yml +0 -16
- vendor/mobiledetect/mobiledetectlib/docs/CONTRIBUTING.md +0 -48
- vendor/mobiledetect/mobiledetectlib/docs/HISTORY.md +0 -11
- vendor/mobiledetect/mobiledetectlib/docs/ISSUE_TEMPLATE.md +0 -15
- vendor/mobiledetect/mobiledetectlib/docs/KNOWN_LIMITATIONS.md +0 -12
- vendor/mobiledetect/mobiledetectlib/export/exportToJSON.php +0 -67
- vendor/mobiledetect/mobiledetectlib/namespaced/Detection/MobileDetect.php +0 -22
- vendor/mobiledetect/mobiledetectlib/phpcs.xml +0 -20
ajax-search-for-woocommerce.php
CHANGED
@@ -4,13 +4,13 @@
|
|
4 |
* Plugin Name: AJAX Search for WooCommerce
|
5 |
* Plugin URI: https://ajaxsearch.pro?utm_source=wp-admin&utm_medium=referral&utm_campaign=author_uri&utm_gen=utmdc
|
6 |
* Description: The most popular WooCommerce product search. Gives your users a well-designed advanced AJAX search bar with live search suggestions.
|
7 |
-
* Version: 1.8.
|
8 |
* Author: Damian Góra
|
9 |
* Author URI: https://ajaxsearch.pro?utm_source=wp-admin&utm_medium=referral&utm_campaign=author_uri&utm_gen=utmdc
|
10 |
* Text Domain: ajax-search-for-woocommerce
|
11 |
* Domain Path: /languages
|
12 |
* WC requires at least: 3.3
|
13 |
-
* WC tested up to: 4.
|
14 |
*
|
15 |
*/
|
16 |
// Exit if accessed directly
|
@@ -43,7 +43,6 @@ if ( !class_exists( 'DGWT_WC_Ajax_Search' ) && !function_exists( 'dgoraAsfwFs' )
|
|
43 |
public $tntsearchValid = false ;
|
44 |
public $tntsearchMySql ;
|
45 |
public $tntsearchMySqlValid = false ;
|
46 |
-
public $mobileDetect ;
|
47 |
public $searchInstances = 0 ;
|
48 |
public static function getInstance()
|
49 |
{
|
@@ -56,9 +55,7 @@ if ( !class_exists( 'DGWT_WC_Ajax_Search' ) && !function_exists( 'dgoraAsfwFs' )
|
|
56 |
return;
|
57 |
}
|
58 |
self::$instance->systemHooks();
|
59 |
-
$mobileDetectExist = class_exists( 'Mobile_Detect' );
|
60 |
self::$instance->autoload();
|
61 |
-
self::$instance->mobileDetect = ( !$mobileDetectExist ? new \Detection\MobileDetect() : new \Mobile_Detect() );
|
62 |
$setup = new \DgoraWcas\Setup();
|
63 |
$setup->init();
|
64 |
self::$instance->settings = new \DgoraWcas\Settings();
|
4 |
* Plugin Name: AJAX Search for WooCommerce
|
5 |
* Plugin URI: https://ajaxsearch.pro?utm_source=wp-admin&utm_medium=referral&utm_campaign=author_uri&utm_gen=utmdc
|
6 |
* Description: The most popular WooCommerce product search. Gives your users a well-designed advanced AJAX search bar with live search suggestions.
|
7 |
+
* Version: 1.8.1
|
8 |
* Author: Damian Góra
|
9 |
* Author URI: https://ajaxsearch.pro?utm_source=wp-admin&utm_medium=referral&utm_campaign=author_uri&utm_gen=utmdc
|
10 |
* Text Domain: ajax-search-for-woocommerce
|
11 |
* Domain Path: /languages
|
12 |
* WC requires at least: 3.3
|
13 |
+
* WC tested up to: 4.8
|
14 |
*
|
15 |
*/
|
16 |
// Exit if accessed directly
|
43 |
public $tntsearchValid = false ;
|
44 |
public $tntsearchMySql ;
|
45 |
public $tntsearchMySqlValid = false ;
|
|
|
46 |
public $searchInstances = 0 ;
|
47 |
public static function getInstance()
|
48 |
{
|
55 |
return;
|
56 |
}
|
57 |
self::$instance->systemHooks();
|
|
|
58 |
self::$instance->autoload();
|
|
|
59 |
$setup = new \DgoraWcas\Setup();
|
60 |
$setup->init();
|
61 |
self::$instance->settings = new \DgoraWcas\Settings();
|
assets/css/style.css
CHANGED
@@ -1031,6 +1031,7 @@ input[type="submit"].dgwt-wcas-search-submit, button.dgwt-wcas-search-submit {
|
|
1031 |
cursor: pointer;
|
1032 |
height: 40px;
|
1033 |
min-width: 50px;
|
|
|
1034 |
line-height: 100%;
|
1035 |
min-height: 100%;
|
1036 |
right: 0;
|
@@ -1109,10 +1110,6 @@ input[type="submit"].dgwt-wcas-search-submit, button.dgwt-wcas-search-submit {
|
|
1109 |
padding: 0;
|
1110 |
}
|
1111 |
|
1112 |
-
.dgwt-wcas-ico-magnifier {
|
1113 |
-
fill: #fff;
|
1114 |
-
}
|
1115 |
-
|
1116 |
.dgwt-wcas-details-wrapp .added_to_cart {
|
1117 |
display: block;
|
1118 |
}
|
@@ -1176,6 +1173,11 @@ body:not(.dgwt-wcas-is-details) .dgwt-wcas-suggestion:last-child {
|
|
1176 |
padding-left: 0;
|
1177 |
}
|
1178 |
|
|
|
|
|
|
|
|
|
|
|
1179 |
.dgwt-wcas-no-submit .dgwt-wcas-ico-magnifier {
|
1180 |
height: 50%;
|
1181 |
margin: auto;
|
@@ -1203,6 +1205,8 @@ body:not(.dgwt-wcas-is-details) .dgwt-wcas-suggestion:last-child {
|
|
1203 |
.dgwt-wcas-overlay-mobile-on,
|
1204 |
.dgwt-wcas-overlay-mobile-on body {
|
1205 |
overflow: hidden;
|
|
|
|
|
1206 |
}
|
1207 |
|
1208 |
.dgwt-wcas-om-bar {
|
@@ -1238,6 +1242,10 @@ body:not(.dgwt-wcas-is-details) .dgwt-wcas-suggestion:last-child {
|
|
1238 |
transform: rotate(180deg);
|
1239 |
}
|
1240 |
|
|
|
|
|
|
|
|
|
1241 |
.dgwt-wcas-om-bar .dgwt-wcas-has-submit-off .dgwt-wcas-preloader {
|
1242 |
right: 0 !important;
|
1243 |
}
|
@@ -1393,21 +1401,20 @@ html:not(.dgwt-wcas-overlay-mobile-on) .dgwt-wcas-icon-handler .dgwt-wcas-ico-ma
|
|
1393 |
display: none;
|
1394 |
}
|
1395 |
|
1396 |
-
.dgwt-wcas-overlay-mobile-on
|
1397 |
height: calc(100% - 45px) !important;
|
1398 |
}
|
1399 |
|
1400 |
-
.dgwt-wcas-overlay-mobile-on
|
1401 |
overflow: visible;
|
1402 |
-
overflow-x: hidden;
|
1403 |
}
|
1404 |
|
1405 |
-
.dgwt-wcas-overlay-mobile-on
|
1406 |
max-height: none !important;
|
1407 |
height: auto !important;
|
1408 |
}
|
1409 |
|
1410 |
-
.dgwt-wcas-overlay-mobile-on
|
1411 |
display: none;
|
1412 |
}
|
1413 |
|
@@ -1468,7 +1475,7 @@ html:not(.dgwt-wcas-overlay-mobile-on) .dgwt-wcas-search-wrapp.dgwt-wcas-layout-
|
|
1468 |
opacity: 0.6;
|
1469 |
}
|
1470 |
|
1471 |
-
.dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon.dgwt-wcas-layout-icon-open .dgwt-wcas-sf-wrapp .dgwt-wcas-ico-magnifier {
|
1472 |
display: none;
|
1473 |
}
|
1474 |
.dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon.dgwt-wcas-layout-icon-open.dgwt-wcas-no-submit .dgwt-wcas-sf-wrapp input[type="search"].dgwt-wcas-search-input {
|
1031 |
cursor: pointer;
|
1032 |
height: 40px;
|
1033 |
min-width: 50px;
|
1034 |
+
width: auto;
|
1035 |
line-height: 100%;
|
1036 |
min-height: 100%;
|
1037 |
right: 0;
|
1110 |
padding: 0;
|
1111 |
}
|
1112 |
|
|
|
|
|
|
|
|
|
1113 |
.dgwt-wcas-details-wrapp .added_to_cart {
|
1114 |
display: block;
|
1115 |
}
|
1173 |
padding-left: 0;
|
1174 |
}
|
1175 |
|
1176 |
+
.dgwt-wcas-ico-magnifier,
|
1177 |
+
.dgwt-wcas-ico-magnifier-handler {
|
1178 |
+
max-width: 20px;
|
1179 |
+
}
|
1180 |
+
|
1181 |
.dgwt-wcas-no-submit .dgwt-wcas-ico-magnifier {
|
1182 |
height: 50%;
|
1183 |
margin: auto;
|
1205 |
.dgwt-wcas-overlay-mobile-on,
|
1206 |
.dgwt-wcas-overlay-mobile-on body {
|
1207 |
overflow: hidden;
|
1208 |
+
min-width: 100vw;
|
1209 |
+
min-height: 100vh;
|
1210 |
}
|
1211 |
|
1212 |
.dgwt-wcas-om-bar {
|
1242 |
transform: rotate(180deg);
|
1243 |
}
|
1244 |
|
1245 |
+
.dgwt-wcas-has-submit .dgwt-wcas-search-submit svg path {
|
1246 |
+
fill: #fff;
|
1247 |
+
}
|
1248 |
+
|
1249 |
.dgwt-wcas-om-bar .dgwt-wcas-has-submit-off .dgwt-wcas-preloader {
|
1250 |
right: 0 !important;
|
1251 |
}
|
1401 |
display: none;
|
1402 |
}
|
1403 |
|
1404 |
+
.dgwt-wcas-overlay-mobile-on.dgwt-wcas-is-ios .dgwt-wcas-suggestions-wrapp {
|
1405 |
height: calc(100% - 45px) !important;
|
1406 |
}
|
1407 |
|
1408 |
+
.dgwt-wcas-overlay-mobile-on.dgwt-wcas-is-ios {
|
1409 |
overflow: visible;
|
|
|
1410 |
}
|
1411 |
|
1412 |
+
.dgwt-wcas-overlay-mobile-on.dgwt-wcas-is-ios .dgwt-wcas-suggestions-wrapp {
|
1413 |
max-height: none !important;
|
1414 |
height: auto !important;
|
1415 |
}
|
1416 |
|
1417 |
+
.dgwt-wcas-overlay-mobile-on.dgwt-wcas-is-ios body:not(.dgwt-wcas-theme-flatsome) > *:not(.dgwt-wcas-overlay-mobile) {
|
1418 |
display: none;
|
1419 |
}
|
1420 |
|
1475 |
opacity: 0.6;
|
1476 |
}
|
1477 |
|
1478 |
+
.dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon.dgwt-wcas-layout-icon-open:not(.dgwt-wcas-has-submit) .dgwt-wcas-sf-wrapp .dgwt-wcas-ico-magnifier {
|
1479 |
display: none;
|
1480 |
}
|
1481 |
.dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon.dgwt-wcas-layout-icon-open.dgwt-wcas-no-submit .dgwt-wcas-sf-wrapp input[type="search"].dgwt-wcas-search-input {
|
assets/css/style.min.css
CHANGED
@@ -1 +1 @@
|
|
1 |
-
.dgwt-wcas-block-scroll{overflow:hidden}.dgwt-wcas-search-wrapp{position:relative;line-height:100%;display:block;color:#444;min-width:230px;width:100%;text-align:left;margin:0 auto;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.dgwt-wcas-tpd-image img{margin:0 15px 0 0!important;display:block}.rtl .dgwt-wcas-tpd-image img{margin:0 0 0 15px!important}.dgwt-wcas-preloader-wrapp img{margin:10px auto 0 auto;display:block;max-width:200px}.dgwt-wcas-preloader-wrapp img.dgwt-wcas-placeholder-preloader{display:block;width:100%;height:auto;max-width:300px;margin:0}.dgwt-wcas-suggestions-wrapp{background:#fff none repeat scroll 0 0;border:1px solid #ddd;border-top:none;padding:0;margin:0;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;overflow-y:auto}.dgwt-wcas-details-wrapp *,.dgwt-wcas-search-wrapp *,.dgwt-wcas-suggestions-wrapp *{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.dgwt-wcas-details-wrapp a:focus,.dgwt-wcas-suggestions-wrapp a:focus{outline:0}.dgwt-wcas-suggestions-wrapp.dgwt-wcas-suggestions-wrapp--top{border:1px solid #ddd;border-bottom:none}.dgwt-wcas-is-detail-box .dgwt-wcas-suggestions-wrapp{max-width:550px}.dgwt-wcas-full-width.dgwt-wcas-is-detail-box .dgwt-wcas-suggestion{padding:8px 15px}.dgwt-wcas-details-left .dgwt-wcas-suggestions-wrapp{border-radius:0 0 5px 0;border-left-color:#eee}.dgwt-wcas-details-right .dgwt-wcas-suggestions-wrapp{border-radius:0 0 0 5px;border-right-color:#eee}.dgwt-wcas-suggestion{cursor:pointer;font-size:12px;line-height:110%;text-align:left;padding:7px 10px;position:relative;border-bottom:1px solid #dfdfdf;display:flex;flex-direction:row;justify-content:space-between;align-items:center;resize:vertical;width:100%}.dgwt-wcas-suggestion.dgwt-wcas-suggestion-more{justify-content:center;color:#6d6d6d}a.dgwt-wcas-details-more-products{padding:15px 0 10px 0;display:block;border-top:1px solid #eee;text-align:center;font-size:12px;text-transform:uppercase;color:#6d6d6d;transition:all .2s ease-in-out}a.dgwt-wcas-details-more-products:hover{text-decoration:underline}a.dgwt-wcas-product-details-readmore{display:block;text-align:right;margin-top:15px;color:#6d6d6d;text-transform:uppercase;letter-spacing:1px;font-weight:400;font-size:12px}a.dgwt-wcas-product-details-readmore:hover{text-decoration:underline}.dgwt-wcas-suggestion.dgwt-wcas-suggestion-no-border-bottom{border-bottom:none}.dgwt-wcas-suggestion:after{clear:both;display:block;content:''}.dgwt-wcas-suggestion.dgwt-wcas-nores{cursor:default;opacity:.5}.dgwt-wcas-has-img .dgwt-wcas-suggestion.dgwt-wcas-suggestion-product{padding-top:8px;padding-bottom:8px;min-height:60px}.dgwt-wcas-is-details .dgwt-wcas-has-img .dgwt-wcas-suggestion.dgwt-wcas-suggestion-more,.dgwt-wcas-suggestion.dgwt-wcas-suggestion-more{min-height:30px;text-transform:uppercase}.dgwt-wcas-suggestion.dgwt-wcas-suggestion-more .dgwt-wcas-st-more{padding:0 10px;text-align:center}.dgwt-wcas-st{display:block;color:#444;font-size:15px;width:100%;line-height:110%}.dgwt-wcas-st>span{display:inline-block;vertical-align:middle}.dgwt-wcas-has-sku .dgwt-wcas-st-title{margin-right:6px}.dgwt-wcas-st>span.dgwt-wcas-st--direct-headline{display:block;font-style:italic;font-size:10px;text-transform:uppercase;opacity:.4;line-height:10px;margin-bottom:1px;letter-spacing:2px}.dgwt-wcas-st-breadcrumbs{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:80%;text-align:left;opacity:.6;width:100%;padding-right:10px}.rtl .dgwt-wcas-st-breadcrumbs{padding-right:0;padding-left:10px;text-align:right}.dgwt-wcas-sku{font-size:80%}.dgwt-wcas-si{width:50px;display:block;height:100%}.dgwt-wcas-si img{background:#fff none repeat scroll 0 0;border:1px solid #e8e8e8;border-radius:3px;display:block;margin:auto;padding:2px;height:auto;width:auto;max-height:90%;max-width:100%}.dgwt-wcas-content-wrapp{display:flex;height:100%;width:100%;justify-content:space-between;align-items:center;resize:vertical;padding-left:10px}.rtl .dgwt-wcas-content-wrapp{padding-left:0;padding-right:10px}.dgwt-wcas-sp{color:#555;font-size:14px;line-height:120%;text-align:right;line-height:4px;padding-left:10px}.dgwt-wcas-sp *{line-height:130%}.dgwt-wcas-search-form{margin:0;padding:0;width:100%}.dgwt-wcas-sp del{opacity:.5;font-size:12px}.dgwt-wcas-sd{color:#777;display:block;line-height:14px;width:100%;margin-top:5px;font-size:.8em}.dgwt-wcas-suggestion-selected{background-color:#eee}.dgwt-wcas-suggestion-selected:first-child{border-top:none}.rtl .dgwt-wcas-suggestion{padding-left:0;padding-right:15px;text-align:right}.dgwt-wcas-details-wrapp{background:#fff none repeat scroll 0 0;border:1px solid #ddd;border-top:none;border-left:none;padding:0;width:300px;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;z-index:100;min-height:340px}.rtl .dgwt-wcas-details-wrapp{border-left:1px solid #ddd;border-right:none}.dgwt-wcas-details-outside .dgwt-wcas-details-wrapp{margin-top:-1px;border-top:1px solid #ddd}.dgwt-wcas-details-outside.dgwt-wcas-is-details .dgwt-wcas-suggestions-wrapp{margin-top:-1px;border-top:1px solid #ddd}.dgwt-wcas-details-right .dgwt-wcas-details-wrapp{border-left:none;border-right:1px solid #ddd;border-radius:0 5px 5px 0}.dgwt-wcas-details-left .dgwt-wcas-details-wrapp{border-right:none;border-left:1px solid #ddd;border-radius:5px 0 0 5px}.dgwt-wcas-details-notfit .dgwt-wcas-details-wrapp{display:none}.dgwt-wcas-full-width .dgwt-wcas-suggestions-wrapp{border-radius:0 0 0 5px}.dgwt-wcas-full-width .dgwt-wcas-details-wrapp{border-radius:0 0 5px 0}.rtl.dgwt-wcas-full-width .dgwt-wcas-suggestions-wrapp{border-radius:0 0 5px 0}.rtl.dgwt-wcas-full-width .dgwt-wcas-details-wrapp{border-radius:0 0 0 5px}.dgwt-wcas-details-inner-taxonomy{margin-top:11px}.woocommerce .dgwt-wcas-pd-rating .star-rating{float:left;margin-right:5px;font-size:12px;color:#ccae72}.rtl .dgwt-wcas-pd-rating .star-rating{float:right;margin-left:5px;margin-right:0}.dgwt-wcas-datails-title{border-bottom:1px dashed #eee;display:block;margin-bottom:15px;padding-bottom:5px;font-size:14px}.dgwt-wcas-pd-title{border-bottom:1px dashed #eee;margin-bottom:15px;padding-bottom:5px;display:block;color:#202020;text-decoration:none}.dgwt-wcas-pd-title .product-title{font-weight:900;color:#202020;text-transform:uppercase;letter-spacing:-1px;margin:0}.dgwt-wcas-details-title-tax{text-transform:uppercase;font-weight:900;letter-spacing:-1px;margin-right:3px}.dgwt-wcas-tax-product-details{text-decoration:none;display:flex;align-items:center;justify-content:left;transition:all .2s ease-in-out;padding:5px;margin:0 -5px 15px -5px}.dgwt-wcas-tax-product-details:after{content:'';clear:both;display:block}.dgwt-wcas-tax-product-details:hover{box-shadow:0 0 11px 2px rgba(0,0,0,.05)}.dgwt-wcas-details-wrapp .dgwt-wcas-pd-title{margin-bottom:8px}.dgwt-wcas-tpd-image{width:60px;margin-right:15px}.dgwt-wcas-pd-rest .product-title{display:block;line-height:100%;font-weight:500;margin-bottom:5px}.dgwt-wcas-tpd-rest{max-width:200px}.dgwt-wcas-tpd-rest-title{display:block;line-height:125%;font-size:14px;font-weight:500;letter-spacing:0;margin:0 0 8px;overflow:hidden;color:#000}.dgwt-wcas-suggestion-nores{pointer-events:none;opacity:.45}.dgwt-wcas-pd-price,.dgwt-wcas-tpd-price{font-size:14px;line-height:120%;overflow:hidden;color:#000;margin-top:15px;font-weight:700;font-size:18px}.dgwt-wcas-tpd-price{font-size:12px;color:#777}.dgwt-wcas-pd-price .woocommerce-price-suffix,.dgwt-wcas-tpd-price .woocommerce-price-suffix{font-size:12px;font-weight:lighter;color:#999;margin-left:4px;display:inline-block}.dgwt-wcas-pd-price del .amount,.dgwt-wcas-tpd-price del .amount{font-weight:lighter;background:0 0;font-size:90%;opacity:.6}.dgwt-wcas-pd-price ins,.dgwt-wcas-tpd-price ins{background:0 0;text-decoration:none}.dgwt-wcas-pd-rating{font-size:13px;line-height:13px}.dgwt-wcas-pd-rating:after{content:'';clear:both;display:block}.dgwt-wcas-pd-review{color:#777;font-size:11px;line-height:11px}.dgwt-wcas-datails-title{border-bottom:1px dashed #eee;display:block;margin:5px 0 15px 0;padding-bottom:5px}.dgwt-wcas-pd-title{border-bottom:1px dashed #eee;margin-bottom:15px;padding-bottom:5px;display:block;text-decoration:none}.dgwt-wcas-pd-title .product-title{font-weight:900;text-transform:uppercase;letter-spacing:-1px}.dgwt-wcas-details-title-tax{text-transform:uppercase;font-weight:900;letter-spacing:-1px;margin-right:3px}.rtl .dgwt-wcas-details-title-tax{margin:0 0 0 3px;float:right}.dgwt-wcas-tpd-image{width:70px;padding:4px;background-color:#fff;border:1px solid #e8e8e8;border-radius:4px;display:flex;flex-direction:column;justify-content:center}.dgwt-wcas-details-space{padding:0 15px 15px 15px}.dgwt-wcas-details-main-image{border-bottom:1px solid #eee;min-height:200px;display:flex}.dgwt-wcas-details-main-image img{width:auto;height:auto;display:block;max-height:250px;max-width:100%;margin:0 auto;padding:0;border:none;align-self:center}.dgwt-wcas-details-right .dgwt-wcas-details-main-image img{border-radius:0 3px 0 0}.dgwt-wcas-details-left .dgwt-wcas-details-main-image img{border-radius:3px 0 0 0}a.dgwt-wcas-details-post-title,a.dgwt-wcas-details-product-title{color:#333;display:block;line-height:120%;margin:10px 0 0 0;font-size:21px;font-weight:400;text-decoration:none;text-transform:none}a.dgwt-wcas-details-post-title:hover,a.dgwt-wcas-details-product-title:hover{text-decoration:underline}a.dgwt-wcas-details-post-title{margin-bottom:15px}.dgwt-wcas-details-product-sku{display:block;font-size:12px;line-height:110%;color:#999}.dgwt-wcas-tpd-image img{display:block;max-width:100%;width:100%;height:auto}.dgwt-wcas-details-hr{height:1px;width:100%;border-bottom:1px solid #eee;margin:15px 0}.rtl .dgwt-wcas-tpd-image{float:right;margin-right:0;margin-left:15px}.rtl .dgwt-wcas-tpd-rest{float:right;max-width:190px}.rtl input[type=search].dgwt-wcas-search-input{text-align:right}input[type=search].dgwt-wcas-search-input,input[type=text].dgwt-cas-search-input{-webkit-transition:none;-moz-transition:none;-ms-transition:none;-o-transition:none;transition:none;-webkit-box-shadow:none;box-shadow:none;margin:0;-webkit-appearance:textfield;text-align:left}[type=search].dgwt-wcas-search-input::-ms-clear{display:none}[type=search].dgwt-wcas-search-input::-webkit-search-decoration{-webkit-appearance:none}[type=search].dgwt-wcas-search-input::-webkit-search-cancel-button{display:none}.dgwt-wcas-details-desc{font-size:13px;line-height:157%}.dgwt-wcas-details-desc b,.dgwt-wcas-details-desc strong{font-weight:400;color:#000;margin:0;padding:0}.dgwt-wcas-pd-addtc-form{margin:10px 0;display:flex;align-items:center;justify-content:flex-end}.dgwt-wcas-pd-addtc-form>.quantity{margin-right:10px}.dgwt-wcas-pd-addtc-form .add_to_cart_inline,.dgwt-wcas-pd-addtc-form .quantity input.qty{margin-bottom:0;margin-top:0}.dgwt-wcas-stock{display:block;text-align:right;font-size:14px;line-height:14px;margin-bottom:14px}.dgwt-wcas-stock.in-stock{color:#0f834d}.dgwt-wcas-stock.out-of-stock{color:#e2401c}.dgwt-wcas-pd-addtc .add_to_cart_button,.dgwt-wcas-pd-addtc .add_to_cart_inline{margin:0}.dgwt-wcas-pd-addtc .add_to_cart_button.added{display:none}button.dgwt-wcas-search-submit,input[type=submit].dgwt-wcas-search-submit{position:relative}.dgwt-wcas-ico-magnifier{bottom:0;left:0;margin:auto;position:absolute;right:0;top:0;height:65%;display:block}.dgwt-wcas-preloader{height:100%;position:absolute;right:0;top:0;width:40px;z-index:1;background-repeat:no-repeat;background-position:right 15px center;background-size:auto 44%}.rtl .dgwt-wcas-preloader{right:auto;left:5px}.dgwt-wcas-inner-preloader{background-repeat:no-repeat;background-position:right 8px center;background-size:auto 22px;display:flex;align-items:center;justify-content:center}@media all and (-ms-high-contrast:none),(-ms-high-contrast:active){.dgwt-wcas-inner-preloader{background-image:url(../img/preloader.gif)}}.dgwt-wcas-loader-circular{height:24px;width:24px;-webkit-animation:2s linear infinite rotate;-moz-animation:2s linear infinite rotate;animation:2s linear infinite rotate}.dgwt-wcas-loader-circular-path{fill:transparent;stroke-linecap:round;stroke-width:4px;stroke-dasharray:1,200;stroke-dashoffset:0;-webkit-transform-origin:50% 50%;-moz-transform-origin:50% 50%;-ms-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-animation:1s ease-in-out infinite dash;-moz-animation:1s ease-in-out infinite dash;animation:1s ease-in-out infinite dash}@-webkit-keyframes rotate{100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@-moz-keyframes rotate{100%{-moz-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes rotate{100%{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);transform:rotate(360deg)}}@-webkit-keyframes dash{0%{stroke-dasharray:1,200;stroke-dashoffset:0}50%{stroke-dasharray:89,200;stroke-dashoffset:-35px}100%{stroke-dasharray:89,200;stroke-dashoffset:-124px}}@-moz-keyframes dash{0%{stroke-dasharray:1,200;stroke-dashoffset:0}50%{stroke-dasharray:89,200;stroke-dashoffset:-35px}100%{stroke-dasharray:89,200;stroke-dashoffset:-124px}}@keyframes dash{0%{stroke-dasharray:1,200;stroke-dashoffset:0}50%{stroke-dasharray:89,200;stroke-dashoffset:-35px}100%{stroke-dasharray:89,200;stroke-dashoffset:-124px}}.dgwt-wcas-close:not(.dgwt-wcas-inner-preloader){cursor:pointer;display:flex;align-items:center;justify-content:center;-webkit-transition:all 160ms ease-in-out;-moz-transition:all 160ms ease-in-out;-ms-transition:all 160ms ease-in-out;-o-transition:all 160ms ease-in-out;transition:all 160ms ease-in-out}.dgwt-wcas-close:hover{opacity:.3}@media screen and (max-width:992px){.dgwt-wcas-is-detail-box .dgwt-wcas-suggestions-wrapp{max-width:none}}.dgwt-wcas-suggestion strong{font-weight:700}.screen-reader-text{clip:rect(1px,1px,1px,1px);height:1px;overflow:hidden;position:absolute!important;width:1px}.dgwt-wcas-sf-wrapp:after,.dgwt-wcas-sf-wrapp:before{content:"";display:table}.dgwt-wcas-sf-wrapp:after{clear:both}.dgwt-wcas-sf-wrapp{zoom:1;width:100%;margin:0;position:relative;background:0 0}.dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input{width:100%;height:40px;font-size:14px;line-height:100%;padding:10px 15px;margin:0;background:#fff;border:1px solid #ddd;border-radius:3px;-webkit-border-radius:3px;-webkit-appearance:none;box-sizing:border-box}.dgwt-wcas-open .dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input{border-radius:3px 3px 0 0}.dgwt-wcas-open.dgwt-wcas-nores.dgwt-wcas-details-outside .dgwt-wcas-details-wrapp{display:none!important}.dgwt-wcas-open.dgwt-wcas-nores.dgwt-wcas-details-outside .dgwt-wcas-suggestions-wrapp{min-height:0!important;border-radius:0 0 5px 5px;border-right-color:#ddd}.dgwt-wcas-open.dgwt-wcas-nores.dgwt-wcas-full-width .dgwt-wcas-details-wrapp,.dgwt-wcas-open.dgwt-wcas-nores.dgwt-wcas-full-width .dgwt-wcas-suggestions-wrapp{min-height:41px!important}.dgwt-wcas-open.dgwt-wcas-nores.dgwt-wcas-full-width:not(.rtl):not(.dgwt-wcas-details-outside) .dgwt-wcas-suggestions-wrapp{border-right-color:transparent}.dgwt-wcas-open.dgwt-wcas-nores .dgwt-wcas-details-wrapp .dgwt-wcas-preloader-wrapp{display:none!important}.dgwt-wcas-open.dgwt-wcas-nores.dgwt-wcas-is-details:not(.dgwt-wcas-details-outside) .dgwt-wcas-suggestion-nores{margin-top:5px}.rtl.dgwt-wcas-open.dgwt-wcas-nores.dgwt-wcas-full-width:not(.dgwt-wcas-details-outside) .dgwt-wcas-suggestions-wrapp{border-left-color:transparent}.dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input:focus{outline:0;background:#fff;box-shadow:0 0 9px 1px rgba(0,0,0,.06);-webkit-transition:all 150ms ease-in;-moz-transition:all 150ms ease-in;-ms-transition:all 150ms ease-in;-o-transition:all 150ms ease-in;transition:all 150ms ease-in}.dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input::placeholder{color:#999;font-weight:400;font-style:italic;line-height:normal}.dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input::-webkit-input-placeholder{color:#999;font-weight:400;font-style:italic;line-height:normal}.dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input:-moz-placeholder{color:#999;font-weight:400;font-style:italic;line-height:normal}.dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input::-moz-placeholder{color:#999;font-weight:400;font-style:italic;line-height:normal}.dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input:-ms-input-placeholder{color:#999;font-weight:400;font-style:italic;line-height:normal}.dgwt-wcas-sf-wrapp button.dgwt-wcas-search-submit{overflow:visible;position:absolute;border:0;padding:0;margin:0;cursor:pointer;height:40px;min-width:50px;line-height:100%;min-height:100%;right:0;left:auto;top:0;bottom:auto;padding:0 15px;color:#fff;-webkit-transition:all 250ms ease-in-out;-moz-transition:all 250ms ease-in-out;-ms-transition:all 250ms ease-in-out;-o-transition:all 250ms ease-in-out;transition:all 250ms ease-in-out;text-transform:uppercase;background-color:#333;border-radius:0 2px 2px 0;-webkit-border-radius:0 2px 2px 0;text-shadow:0 -1px 0 rgba(0,0,0,.3);-webkit-box-shadow:none;box-shadow:none;-webkit-appearance:none}.rtl .dgwt-wcas-sf-wrapp button.dgwt-wcas-search-submit{left:0;right:auto}.dgwt-wcas-open .dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit{border-radius:0 2px 0 0}.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:hover{opacity:.7}.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:active,.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:focus{opacity:.7;outline:0}.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:before{content:'';position:absolute;border-width:8px 8px 8px 0;border-style:solid solid solid none;border-color:transparent #333 transparent;top:12px;left:-6px;-webkit-transition:all 250ms ease-in-out;-moz-transition:all 250ms ease-in-out;-ms-transition:all 250ms ease-in-out;-o-transition:all 250ms ease-in-out;transition:all 250ms ease-in-out}.rtl .dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:before{left:auto;right:-6px;border-width:8px 0 8px 8px;border-style:solid none solid solid}.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:hover:before{border-right-color:#333}.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:active:before,.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:focus:before{border-right-color:#333}.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit::-moz-focus-inner{border:0;padding:0}.dgwt-wcas-ico-magnifier{fill:#fff}.dgwt-wcas-details-wrapp .added_to_cart{display:block}.dgwt-wcas-has-desc .dgwt-wcas-sp>*,.dgwt-wcas-has-img .dgwt-wcas-sp>*{display:block}.dgwt-wcas-is-details .dgwt-wcas-suggestions-wrapp{min-height:340px}body:not(.dgwt-wcas-is-details) .dgwt-wcas-suggestion:last-child{border-bottom:none}.dgwt-wcas-is-details .dgwt-wcas-has-img .dgwt-wcas-suggestion.dgwt-wcas-suggestion-product{min-height:40px}.dgwt-wcas-is-details .dgwt-wcas-suggestions-wrapp{overflow:visible}.dgwt-wcas-is-details .dgwt-wcas-si{width:30px;max-width:100%;box-sizing:border-box}.dgwt-wcas-is-details .dgwt-wcas-sp{display:flex;top:0;flex-direction:column;height:100%;justify-content:center;resize:vertical}.dgwt-wcas-is-details .dgwt-wcas-sd{font-size:11px;line-height:100%}.dgwt-wcas-has-img .dgwt-wcas-suggestion[data-taxonomy=product_cat],.dgwt-wcas-has-img .dgwt-wcas-suggestion[data-taxonomy=product_tag]{padding-left:15px;min-height:0}.dgwt-wcas-has-img .dgwt-wcas-suggestion[data-taxonomy=product_cat] .dgwt-wcas-st,.dgwt-wcas-has-img .dgwt-wcas-suggestion[data-taxonomy=product_tag] .dgwt-wcas-st{padding-left:0}.dgwt-wcas-no-submit .dgwt-wcas-ico-magnifier{height:50%;margin:auto;max-height:20px;width:100%;max-width:20px;left:12px;right:auto;opacity:.5;fill:#000}.rtl .dgwt-wcas-no-submit .dgwt-wcas-ico-magnifier{left:auto;right:12px}.dgwt-wcas-no-submit .dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input{padding:10px 15px 10px 40px}.rtl .dgwt-wcas-no-submit .dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input{padding:10px 40px 10px 15px}.dgwt-wcas-overlay-mobile-on,.dgwt-wcas-overlay-mobile-on body{overflow:hidden}.dgwt-wcas-om-bar{display:flex;height:45px;width:100%}.dgwt-wcas-om-bar .dgwt-wcas-om-return{width:45px;height:100%;display:block;background:#ccc;cursor:pointer;position:relative}.dgwt-wcas-om-bar .dgwt-wcas-om-return svg{width:23px;height:23px;position:absolute;left:12px;top:12px}.rtl .dgwt-wcas-om-bar .dgwt-wcas-om-return svg{left:11px;top:9px;-moz-transform:rotate(180deg);-webkit-transform:rotate(180deg);-o-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.dgwt-wcas-om-bar .dgwt-wcas-has-submit-off .dgwt-wcas-preloader{right:0!important}.rtl .dgwt-wcas-om-bar .dgwt-wcas-has-submit-off .dgwt-wcas-preloader{left:4px!important;right:auto!important}@keyframes dgwt-wcas-preloader-price-anim{0%{background:rgba(128,128,128,.03)}50%{background:rgba(128,128,128,.1)}100%{background:rgba(128,128,128,.03)}}.dgwt-wcas-preloader-price-inner div:nth-child(1){left:0;animation-delay:-.1s}.dgwt-wcas-preloader-price-inner div:nth-child(2){left:13px;animation-delay:-.2s}.dgwt-wcas-preloader-price-inner div:nth-child(3){left:26px;animation-delay:-.3s}.dgwt-wcas-preloader-price{width:34px;height:10px;display:inline-block;overflow:hidden;background:0 0}.dgwt-wcas-preloader-price-inner{width:100%;height:100%;position:relative;transform:translateZ(0) scale(1);backface-visibility:hidden;transform-origin:0 0}.dgwt-wcas-preloader-price-inner div{position:absolute;width:8px;height:8px;background:rgba(128,128,128,.05);animation:dgwt-wcas-preloader-price-anim .8s cubic-bezier(0,.5,.5,1) infinite;-webkit-transition:all .2s ease-in-out;-moz-transition:all .2s ease-in-out;-ms-transition:all .2s ease-in-out;-o-transition:all .2s ease-in-out;transition:all .2s ease-in-out}.dgwt-wcas-om-bar .dgwt-wcas-sf-wrapp button.dgwt-wcas-search-submit{display:none}.dgwt-wcas-om-bar .dgwt-wcas-search-wrapp-mobile{width:calc(100% - 45px);max-width:none;margin:0}.dgwt-wcas-overlay-mobile .dgwt-wcas-search-form{width:100%}.dgwt-wcas-overlay-mobile{position:absolute;left:0;right:0;top:0;bottom:0;width:100%;background:#fff}.dgwt-wcas-overlay-mobile *{box-sizing:border-box}.dgwt-wcas-search-wrapp-mobile input[type=search].dgwt-wcas-search-input{height:45px!important;border-top:none;border-right:none;border-left:none;border-radius:0;font-size:16px!important}.dgwt-wcas-search-wrapp-mobile input[type=search].dgwt-wcas-search-input:focus{font-size:16px!important}.dgwt-wcas-overlay-mobile-on .dgwt-wcas-suggestions-wrapp{left:0!important;top:45px!important;width:100%!important;height:calc(100% - 45px)!important;position:absolute;overflow-y:auto;border:none;margin:0;display:block}.dgwt-wcas-overlay-mobile-on .dgwt-wcas-suggestion{width:100%}.dgwt-wcas-overlay-mobile-on .dgwt-wcas-enable-mobile-form{display:none}.dgwt-wcas-enable-mobile-form{position:absolute;z-index:100;left:0;top:0;width:100%;height:100%;cursor:pointer}html:not(.dgwt-wcas-overlay-mobile-on) .dgwt-wcas-icon-mobile .dgwt-wcas-search-form{display:none;position:relative}html:not(.dgwt-wcas-overlay-mobile-on) .dgwt-wcas-search-wrapp.dgwt-wcas-icon-mobile{min-width:0;display:inline-block;width:28px;height:28px}html:not(.dgwt-wcas-overlay-mobile-on) .dgwt-wcas-icon-handler{height:100%;width:100%}html:not(.dgwt-wcas-overlay-mobile-on) .dgwt-wcas-icon-handler .dgwt-wcas-ico-magnifier{opacity:1;position:static;max-width:none;max-height:none}.dgwt-wcas-overlay-mobile-on .dgwt-wcas-icon-handler{display:none}.dgwt-wcas-overlay-mobile-on body.dgwt-wcas-is-ios .dgwt-wcas-suggestions-wrapp{height:calc(100% - 45px)!important}.dgwt-wcas-overlay-mobile-on body.dgwt-wcas-is-ios{overflow:visible;overflow-x:hidden}.dgwt-wcas-overlay-mobile-on body.dgwt-wcas-is-ios .dgwt-wcas-suggestions-wrapp{max-height:none!important;height:auto!important}.dgwt-wcas-overlay-mobile-on body.dgwt-wcas-is-ios:not(.dgwt-wcas-theme-flatsome)>:not(.dgwt-wcas-overlay-mobile){display:none}body .dgwt-wcas-content-wrapp .rood,body .dgwt-wcas-content-wrapp .zwave{display:none}.dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon{min-width:unset}.dgwt-wcas-layout-icon-flexible .dgwt-wcas-search-form{opacity:0}.dgwt-wcas-layout-icon-flexible-loaded .dgwt-wcas-search-form{opacity:1}.dgwt-wcas-search-icon-arrow{display:none}html:not(.dgwt-wcas-overlay-mobile-on) .dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon .dgwt-wcas-search-form{opacity:0;display:none;position:absolute;left:0;top:calc(100% + 8px);min-width:500px;z-index:1000}.dgwt-wcas-overlay-mobile .dgwt-wcas-search-icon,.dgwt-wcas-overlay-mobile .dgwt-wcas-search-icon-arrow{display:none}html:not(.dgwt-wcas-overlay-mobile-on) .dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon.dgwt-wcas-layout-icon-open .dgwt-wcas-search-form{display:block;opacity:1}.dgwt-wcas-search-icon{width:20px;height:auto;cursor:pointer}.dgwt-wcas-ico-magnifier-handler{margin-bottom:-.2em;width:100%}.dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon.dgwt-wcas-layout-icon-open .dgwt-wcas-search-icon{opacity:.6}.dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon.dgwt-wcas-layout-icon-open .dgwt-wcas-sf-wrapp .dgwt-wcas-ico-magnifier{display:none}.dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon.dgwt-wcas-layout-icon-open.dgwt-wcas-no-submit .dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input{padding-left:15px}.dgwt-wcas-layout-icon-open .dgwt-wcas-search-icon-arrow{display:block;position:absolute;top:calc(100% + 2px);left:0;z-index:5;width:15px;height:15px;background:#fff;border:1px solid #ddd;-webkit-transform:rotate(45deg);-moz-transform:rotate(45deg);-o-transform:rotate(45deg);-ms-transform:rotate(45deg);transform:rotate(45deg)}.dgwt-wcas-layout-icon-flexible:not(.dgwt-wcas-layout-icon) .dgwt-wcas-search-icon,.dgwt-wcas-layout-icon-flexible:not(.dgwt-wcas-layout-icon) .dgwt-wcas-search-icon-arrow{display:none}.dgwt-wcas-has-headings .dgwt-wcas-suggestion{border-bottom:none}.dgwt-wcas-has-headings .dgwt-wcas-st>span.dgwt-wcas-st--direct-headline{display:none}.dgwt-wcas-has-headings .dgwt-wcas-suggestion-headline{pointer-events:none;display:block;font-weight:500;white-space:nowrap}.dgwt-wcas-has-headings .dgwt-wcas-suggestion-headline .dgwt-wcas-st{border-bottom:1px solid #ddd;padding-bottom:3px;text-transform:uppercase;margin-top:16px;font-size:12px}.dgwt-wcas-has-headings .dgwt-wcas-suggestion.dgwt-wcas-suggestion-headline,.dgwt-wcas-has-headings .dgwt-wcas-suggestion.dgwt-wcas-suggestion-tax{border-bottom:none}.dgwt-wcas-has-headings .dgwt-wcas-suggestion-tax .dgwt-wcas-st{padding:0}.dgwt-wcas-has-headings .dgwt-wcas-suggestion.dgwt-wcas-suggestion-tax.dgwt-wcas-suggestion-selected,.dgwt-wcas-has-headings .dgwt-wcas-suggestion.dgwt-wcas-suggestion-tax:hover{background:0 0;text-decoration:underline}.dgwt-wcas-is-details .dgwt-wcas-has-headings .dgwt-wcas-suggestion.dgwt-wcas-suggestion-tax{min-height:30px}
|
1 |
+
.dgwt-wcas-block-scroll{overflow:hidden}.dgwt-wcas-search-wrapp{position:relative;line-height:100%;display:block;color:#444;min-width:230px;width:100%;text-align:left;margin:0 auto;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.dgwt-wcas-tpd-image img{margin:0 15px 0 0!important;display:block}.rtl .dgwt-wcas-tpd-image img{margin:0 0 0 15px!important}.dgwt-wcas-preloader-wrapp img{margin:10px auto 0 auto;display:block;max-width:200px}.dgwt-wcas-preloader-wrapp img.dgwt-wcas-placeholder-preloader{display:block;width:100%;height:auto;max-width:300px;margin:0}.dgwt-wcas-suggestions-wrapp{background:#fff none repeat scroll 0 0;border:1px solid #ddd;border-top:none;padding:0;margin:0;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;overflow-y:auto}.dgwt-wcas-details-wrapp *,.dgwt-wcas-search-wrapp *,.dgwt-wcas-suggestions-wrapp *{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.dgwt-wcas-details-wrapp a:focus,.dgwt-wcas-suggestions-wrapp a:focus{outline:0}.dgwt-wcas-suggestions-wrapp.dgwt-wcas-suggestions-wrapp--top{border:1px solid #ddd;border-bottom:none}.dgwt-wcas-is-detail-box .dgwt-wcas-suggestions-wrapp{max-width:550px}.dgwt-wcas-full-width.dgwt-wcas-is-detail-box .dgwt-wcas-suggestion{padding:8px 15px}.dgwt-wcas-details-left .dgwt-wcas-suggestions-wrapp{border-radius:0 0 5px 0;border-left-color:#eee}.dgwt-wcas-details-right .dgwt-wcas-suggestions-wrapp{border-radius:0 0 0 5px;border-right-color:#eee}.dgwt-wcas-suggestion{cursor:pointer;font-size:12px;line-height:110%;text-align:left;padding:7px 10px;position:relative;border-bottom:1px solid #dfdfdf;display:flex;flex-direction:row;justify-content:space-between;align-items:center;resize:vertical;width:100%}.dgwt-wcas-suggestion.dgwt-wcas-suggestion-more{justify-content:center;color:#6d6d6d}a.dgwt-wcas-details-more-products{padding:15px 0 10px 0;display:block;border-top:1px solid #eee;text-align:center;font-size:12px;text-transform:uppercase;color:#6d6d6d;transition:all .2s ease-in-out}a.dgwt-wcas-details-more-products:hover{text-decoration:underline}a.dgwt-wcas-product-details-readmore{display:block;text-align:right;margin-top:15px;color:#6d6d6d;text-transform:uppercase;letter-spacing:1px;font-weight:400;font-size:12px}a.dgwt-wcas-product-details-readmore:hover{text-decoration:underline}.dgwt-wcas-suggestion.dgwt-wcas-suggestion-no-border-bottom{border-bottom:none}.dgwt-wcas-suggestion:after{clear:both;display:block;content:''}.dgwt-wcas-suggestion.dgwt-wcas-nores{cursor:default;opacity:.5}.dgwt-wcas-has-img .dgwt-wcas-suggestion.dgwt-wcas-suggestion-product{padding-top:8px;padding-bottom:8px;min-height:60px}.dgwt-wcas-is-details .dgwt-wcas-has-img .dgwt-wcas-suggestion.dgwt-wcas-suggestion-more,.dgwt-wcas-suggestion.dgwt-wcas-suggestion-more{min-height:30px;text-transform:uppercase}.dgwt-wcas-suggestion.dgwt-wcas-suggestion-more .dgwt-wcas-st-more{padding:0 10px;text-align:center}.dgwt-wcas-st{display:block;color:#444;font-size:15px;width:100%;line-height:110%}.dgwt-wcas-st>span{display:inline-block;vertical-align:middle}.dgwt-wcas-has-sku .dgwt-wcas-st-title{margin-right:6px}.dgwt-wcas-st>span.dgwt-wcas-st--direct-headline{display:block;font-style:italic;font-size:10px;text-transform:uppercase;opacity:.4;line-height:10px;margin-bottom:1px;letter-spacing:2px}.dgwt-wcas-st-breadcrumbs{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:80%;text-align:left;opacity:.6;width:100%;padding-right:10px}.rtl .dgwt-wcas-st-breadcrumbs{padding-right:0;padding-left:10px;text-align:right}.dgwt-wcas-sku{font-size:80%}.dgwt-wcas-si{width:50px;display:block;height:100%}.dgwt-wcas-si img{background:#fff none repeat scroll 0 0;border:1px solid #e8e8e8;border-radius:3px;display:block;margin:auto;padding:2px;height:auto;width:auto;max-height:90%;max-width:100%}.dgwt-wcas-content-wrapp{display:flex;height:100%;width:100%;justify-content:space-between;align-items:center;resize:vertical;padding-left:10px}.rtl .dgwt-wcas-content-wrapp{padding-left:0;padding-right:10px}.dgwt-wcas-sp{color:#555;font-size:14px;line-height:120%;text-align:right;line-height:4px;padding-left:10px}.dgwt-wcas-sp *{line-height:130%}.dgwt-wcas-search-form{margin:0;padding:0;width:100%}.dgwt-wcas-sp del{opacity:.5;font-size:12px}.dgwt-wcas-sd{color:#777;display:block;line-height:14px;width:100%;margin-top:5px;font-size:.8em}.dgwt-wcas-suggestion-selected{background-color:#eee}.dgwt-wcas-suggestion-selected:first-child{border-top:none}.rtl .dgwt-wcas-suggestion{padding-left:0;padding-right:15px;text-align:right}.dgwt-wcas-details-wrapp{background:#fff none repeat scroll 0 0;border:1px solid #ddd;border-top:none;border-left:none;padding:0;width:300px;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;z-index:100;min-height:340px}.rtl .dgwt-wcas-details-wrapp{border-left:1px solid #ddd;border-right:none}.dgwt-wcas-details-outside .dgwt-wcas-details-wrapp{margin-top:-1px;border-top:1px solid #ddd}.dgwt-wcas-details-outside.dgwt-wcas-is-details .dgwt-wcas-suggestions-wrapp{margin-top:-1px;border-top:1px solid #ddd}.dgwt-wcas-details-right .dgwt-wcas-details-wrapp{border-left:none;border-right:1px solid #ddd;border-radius:0 5px 5px 0}.dgwt-wcas-details-left .dgwt-wcas-details-wrapp{border-right:none;border-left:1px solid #ddd;border-radius:5px 0 0 5px}.dgwt-wcas-details-notfit .dgwt-wcas-details-wrapp{display:none}.dgwt-wcas-full-width .dgwt-wcas-suggestions-wrapp{border-radius:0 0 0 5px}.dgwt-wcas-full-width .dgwt-wcas-details-wrapp{border-radius:0 0 5px 0}.rtl.dgwt-wcas-full-width .dgwt-wcas-suggestions-wrapp{border-radius:0 0 5px 0}.rtl.dgwt-wcas-full-width .dgwt-wcas-details-wrapp{border-radius:0 0 0 5px}.dgwt-wcas-details-inner-taxonomy{margin-top:11px}.woocommerce .dgwt-wcas-pd-rating .star-rating{float:left;margin-right:5px;font-size:12px;color:#ccae72}.rtl .dgwt-wcas-pd-rating .star-rating{float:right;margin-left:5px;margin-right:0}.dgwt-wcas-datails-title{border-bottom:1px dashed #eee;display:block;margin-bottom:15px;padding-bottom:5px;font-size:14px}.dgwt-wcas-pd-title{border-bottom:1px dashed #eee;margin-bottom:15px;padding-bottom:5px;display:block;color:#202020;text-decoration:none}.dgwt-wcas-pd-title .product-title{font-weight:900;color:#202020;text-transform:uppercase;letter-spacing:-1px;margin:0}.dgwt-wcas-details-title-tax{text-transform:uppercase;font-weight:900;letter-spacing:-1px;margin-right:3px}.dgwt-wcas-tax-product-details{text-decoration:none;display:flex;align-items:center;justify-content:left;transition:all .2s ease-in-out;padding:5px;margin:0 -5px 15px -5px}.dgwt-wcas-tax-product-details:after{content:'';clear:both;display:block}.dgwt-wcas-tax-product-details:hover{box-shadow:0 0 11px 2px rgba(0,0,0,.05)}.dgwt-wcas-details-wrapp .dgwt-wcas-pd-title{margin-bottom:8px}.dgwt-wcas-tpd-image{width:60px;margin-right:15px}.dgwt-wcas-pd-rest .product-title{display:block;line-height:100%;font-weight:500;margin-bottom:5px}.dgwt-wcas-tpd-rest{max-width:200px}.dgwt-wcas-tpd-rest-title{display:block;line-height:125%;font-size:14px;font-weight:500;letter-spacing:0;margin:0 0 8px;overflow:hidden;color:#000}.dgwt-wcas-suggestion-nores{pointer-events:none;opacity:.45}.dgwt-wcas-pd-price,.dgwt-wcas-tpd-price{font-size:14px;line-height:120%;overflow:hidden;color:#000;margin-top:15px;font-weight:700;font-size:18px}.dgwt-wcas-tpd-price{font-size:12px;color:#777}.dgwt-wcas-pd-price .woocommerce-price-suffix,.dgwt-wcas-tpd-price .woocommerce-price-suffix{font-size:12px;font-weight:lighter;color:#999;margin-left:4px;display:inline-block}.dgwt-wcas-pd-price del .amount,.dgwt-wcas-tpd-price del .amount{font-weight:lighter;background:0 0;font-size:90%;opacity:.6}.dgwt-wcas-pd-price ins,.dgwt-wcas-tpd-price ins{background:0 0;text-decoration:none}.dgwt-wcas-pd-rating{font-size:13px;line-height:13px}.dgwt-wcas-pd-rating:after{content:'';clear:both;display:block}.dgwt-wcas-pd-review{color:#777;font-size:11px;line-height:11px}.dgwt-wcas-datails-title{border-bottom:1px dashed #eee;display:block;margin:5px 0 15px 0;padding-bottom:5px}.dgwt-wcas-pd-title{border-bottom:1px dashed #eee;margin-bottom:15px;padding-bottom:5px;display:block;text-decoration:none}.dgwt-wcas-pd-title .product-title{font-weight:900;text-transform:uppercase;letter-spacing:-1px}.dgwt-wcas-details-title-tax{text-transform:uppercase;font-weight:900;letter-spacing:-1px;margin-right:3px}.rtl .dgwt-wcas-details-title-tax{margin:0 0 0 3px;float:right}.dgwt-wcas-tpd-image{width:70px;padding:4px;background-color:#fff;border:1px solid #e8e8e8;border-radius:4px;display:flex;flex-direction:column;justify-content:center}.dgwt-wcas-details-space{padding:0 15px 15px 15px}.dgwt-wcas-details-main-image{border-bottom:1px solid #eee;min-height:200px;display:flex}.dgwt-wcas-details-main-image img{width:auto;height:auto;display:block;max-height:250px;max-width:100%;margin:0 auto;padding:0;border:none;align-self:center}.dgwt-wcas-details-right .dgwt-wcas-details-main-image img{border-radius:0 3px 0 0}.dgwt-wcas-details-left .dgwt-wcas-details-main-image img{border-radius:3px 0 0 0}a.dgwt-wcas-details-post-title,a.dgwt-wcas-details-product-title{color:#333;display:block;line-height:120%;margin:10px 0 0 0;font-size:21px;font-weight:400;text-decoration:none;text-transform:none}a.dgwt-wcas-details-post-title:hover,a.dgwt-wcas-details-product-title:hover{text-decoration:underline}a.dgwt-wcas-details-post-title{margin-bottom:15px}.dgwt-wcas-details-product-sku{display:block;font-size:12px;line-height:110%;color:#999}.dgwt-wcas-tpd-image img{display:block;max-width:100%;width:100%;height:auto}.dgwt-wcas-details-hr{height:1px;width:100%;border-bottom:1px solid #eee;margin:15px 0}.rtl .dgwt-wcas-tpd-image{float:right;margin-right:0;margin-left:15px}.rtl .dgwt-wcas-tpd-rest{float:right;max-width:190px}.rtl input[type=search].dgwt-wcas-search-input{text-align:right}input[type=search].dgwt-wcas-search-input,input[type=text].dgwt-cas-search-input{-webkit-transition:none;-moz-transition:none;-ms-transition:none;-o-transition:none;transition:none;-webkit-box-shadow:none;box-shadow:none;margin:0;-webkit-appearance:textfield;text-align:left}[type=search].dgwt-wcas-search-input::-ms-clear{display:none}[type=search].dgwt-wcas-search-input::-webkit-search-decoration{-webkit-appearance:none}[type=search].dgwt-wcas-search-input::-webkit-search-cancel-button{display:none}.dgwt-wcas-details-desc{font-size:13px;line-height:157%}.dgwt-wcas-details-desc b,.dgwt-wcas-details-desc strong{font-weight:400;color:#000;margin:0;padding:0}.dgwt-wcas-pd-addtc-form{margin:10px 0;display:flex;align-items:center;justify-content:flex-end}.dgwt-wcas-pd-addtc-form>.quantity{margin-right:10px}.dgwt-wcas-pd-addtc-form .add_to_cart_inline,.dgwt-wcas-pd-addtc-form .quantity input.qty{margin-bottom:0;margin-top:0}.dgwt-wcas-stock{display:block;text-align:right;font-size:14px;line-height:14px;margin-bottom:14px}.dgwt-wcas-stock.in-stock{color:#0f834d}.dgwt-wcas-stock.out-of-stock{color:#e2401c}.dgwt-wcas-pd-addtc .add_to_cart_button,.dgwt-wcas-pd-addtc .add_to_cart_inline{margin:0}.dgwt-wcas-pd-addtc .add_to_cart_button.added{display:none}button.dgwt-wcas-search-submit,input[type=submit].dgwt-wcas-search-submit{position:relative}.dgwt-wcas-ico-magnifier{bottom:0;left:0;margin:auto;position:absolute;right:0;top:0;height:65%;display:block}.dgwt-wcas-preloader{height:100%;position:absolute;right:0;top:0;width:40px;z-index:1;background-repeat:no-repeat;background-position:right 15px center;background-size:auto 44%}.rtl .dgwt-wcas-preloader{right:auto;left:5px}.dgwt-wcas-inner-preloader{background-repeat:no-repeat;background-position:right 8px center;background-size:auto 22px;display:flex;align-items:center;justify-content:center}@media all and (-ms-high-contrast:none),(-ms-high-contrast:active){.dgwt-wcas-inner-preloader{background-image:url(../img/preloader.gif)}}.dgwt-wcas-loader-circular{height:24px;width:24px;-webkit-animation:2s linear infinite rotate;-moz-animation:2s linear infinite rotate;animation:2s linear infinite rotate}.dgwt-wcas-loader-circular-path{fill:transparent;stroke-linecap:round;stroke-width:4px;stroke-dasharray:1,200;stroke-dashoffset:0;-webkit-transform-origin:50% 50%;-moz-transform-origin:50% 50%;-ms-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-animation:1s ease-in-out infinite dash;-moz-animation:1s ease-in-out infinite dash;animation:1s ease-in-out infinite dash}@-webkit-keyframes rotate{100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@-moz-keyframes rotate{100%{-moz-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes rotate{100%{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);transform:rotate(360deg)}}@-webkit-keyframes dash{0%{stroke-dasharray:1,200;stroke-dashoffset:0}50%{stroke-dasharray:89,200;stroke-dashoffset:-35px}100%{stroke-dasharray:89,200;stroke-dashoffset:-124px}}@-moz-keyframes dash{0%{stroke-dasharray:1,200;stroke-dashoffset:0}50%{stroke-dasharray:89,200;stroke-dashoffset:-35px}100%{stroke-dasharray:89,200;stroke-dashoffset:-124px}}@keyframes dash{0%{stroke-dasharray:1,200;stroke-dashoffset:0}50%{stroke-dasharray:89,200;stroke-dashoffset:-35px}100%{stroke-dasharray:89,200;stroke-dashoffset:-124px}}.dgwt-wcas-close:not(.dgwt-wcas-inner-preloader){cursor:pointer;display:flex;align-items:center;justify-content:center;-webkit-transition:all 160ms ease-in-out;-moz-transition:all 160ms ease-in-out;-ms-transition:all 160ms ease-in-out;-o-transition:all 160ms ease-in-out;transition:all 160ms ease-in-out}.dgwt-wcas-close:hover{opacity:.3}@media screen and (max-width:992px){.dgwt-wcas-is-detail-box .dgwt-wcas-suggestions-wrapp{max-width:none}}.dgwt-wcas-suggestion strong{font-weight:700}.screen-reader-text{clip:rect(1px,1px,1px,1px);height:1px;overflow:hidden;position:absolute!important;width:1px}.dgwt-wcas-sf-wrapp:after,.dgwt-wcas-sf-wrapp:before{content:"";display:table}.dgwt-wcas-sf-wrapp:after{clear:both}.dgwt-wcas-sf-wrapp{zoom:1;width:100%;margin:0;position:relative;background:0 0}.dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input{width:100%;height:40px;font-size:14px;line-height:100%;padding:10px 15px;margin:0;background:#fff;border:1px solid #ddd;border-radius:3px;-webkit-border-radius:3px;-webkit-appearance:none;box-sizing:border-box}.dgwt-wcas-open .dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input{border-radius:3px 3px 0 0}.dgwt-wcas-open.dgwt-wcas-nores.dgwt-wcas-details-outside .dgwt-wcas-details-wrapp{display:none!important}.dgwt-wcas-open.dgwt-wcas-nores.dgwt-wcas-details-outside .dgwt-wcas-suggestions-wrapp{min-height:0!important;border-radius:0 0 5px 5px;border-right-color:#ddd}.dgwt-wcas-open.dgwt-wcas-nores.dgwt-wcas-full-width .dgwt-wcas-details-wrapp,.dgwt-wcas-open.dgwt-wcas-nores.dgwt-wcas-full-width .dgwt-wcas-suggestions-wrapp{min-height:41px!important}.dgwt-wcas-open.dgwt-wcas-nores.dgwt-wcas-full-width:not(.rtl):not(.dgwt-wcas-details-outside) .dgwt-wcas-suggestions-wrapp{border-right-color:transparent}.dgwt-wcas-open.dgwt-wcas-nores .dgwt-wcas-details-wrapp .dgwt-wcas-preloader-wrapp{display:none!important}.dgwt-wcas-open.dgwt-wcas-nores.dgwt-wcas-is-details:not(.dgwt-wcas-details-outside) .dgwt-wcas-suggestion-nores{margin-top:5px}.rtl.dgwt-wcas-open.dgwt-wcas-nores.dgwt-wcas-full-width:not(.dgwt-wcas-details-outside) .dgwt-wcas-suggestions-wrapp{border-left-color:transparent}.dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input:focus{outline:0;background:#fff;box-shadow:0 0 9px 1px rgba(0,0,0,.06);-webkit-transition:all 150ms ease-in;-moz-transition:all 150ms ease-in;-ms-transition:all 150ms ease-in;-o-transition:all 150ms ease-in;transition:all 150ms ease-in}.dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input::placeholder{color:#999;font-weight:400;font-style:italic;line-height:normal}.dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input::-webkit-input-placeholder{color:#999;font-weight:400;font-style:italic;line-height:normal}.dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input:-moz-placeholder{color:#999;font-weight:400;font-style:italic;line-height:normal}.dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input::-moz-placeholder{color:#999;font-weight:400;font-style:italic;line-height:normal}.dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input:-ms-input-placeholder{color:#999;font-weight:400;font-style:italic;line-height:normal}.dgwt-wcas-sf-wrapp button.dgwt-wcas-search-submit{overflow:visible;position:absolute;border:0;padding:0;margin:0;cursor:pointer;height:40px;min-width:50px;width:auto;line-height:100%;min-height:100%;right:0;left:auto;top:0;bottom:auto;padding:0 15px;color:#fff;-webkit-transition:all 250ms ease-in-out;-moz-transition:all 250ms ease-in-out;-ms-transition:all 250ms ease-in-out;-o-transition:all 250ms ease-in-out;transition:all 250ms ease-in-out;text-transform:uppercase;background-color:#333;border-radius:0 2px 2px 0;-webkit-border-radius:0 2px 2px 0;text-shadow:0 -1px 0 rgba(0,0,0,.3);-webkit-box-shadow:none;box-shadow:none;-webkit-appearance:none}.rtl .dgwt-wcas-sf-wrapp button.dgwt-wcas-search-submit{left:0;right:auto}.dgwt-wcas-open .dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit{border-radius:0 2px 0 0}.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:hover{opacity:.7}.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:active,.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:focus{opacity:.7;outline:0}.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:before{content:'';position:absolute;border-width:8px 8px 8px 0;border-style:solid solid solid none;border-color:transparent #333 transparent;top:12px;left:-6px;-webkit-transition:all 250ms ease-in-out;-moz-transition:all 250ms ease-in-out;-ms-transition:all 250ms ease-in-out;-o-transition:all 250ms ease-in-out;transition:all 250ms ease-in-out}.rtl .dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:before{left:auto;right:-6px;border-width:8px 0 8px 8px;border-style:solid none solid solid}.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:hover:before{border-right-color:#333}.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:active:before,.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:focus:before{border-right-color:#333}.dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit::-moz-focus-inner{border:0;padding:0}.dgwt-wcas-details-wrapp .added_to_cart{display:block}.dgwt-wcas-has-desc .dgwt-wcas-sp>*,.dgwt-wcas-has-img .dgwt-wcas-sp>*{display:block}.dgwt-wcas-is-details .dgwt-wcas-suggestions-wrapp{min-height:340px}body:not(.dgwt-wcas-is-details) .dgwt-wcas-suggestion:last-child{border-bottom:none}.dgwt-wcas-is-details .dgwt-wcas-has-img .dgwt-wcas-suggestion.dgwt-wcas-suggestion-product{min-height:40px}.dgwt-wcas-is-details .dgwt-wcas-suggestions-wrapp{overflow:visible}.dgwt-wcas-is-details .dgwt-wcas-si{width:30px;max-width:100%;box-sizing:border-box}.dgwt-wcas-is-details .dgwt-wcas-sp{display:flex;top:0;flex-direction:column;height:100%;justify-content:center;resize:vertical}.dgwt-wcas-is-details .dgwt-wcas-sd{font-size:11px;line-height:100%}.dgwt-wcas-has-img .dgwt-wcas-suggestion[data-taxonomy=product_cat],.dgwt-wcas-has-img .dgwt-wcas-suggestion[data-taxonomy=product_tag]{padding-left:15px;min-height:0}.dgwt-wcas-has-img .dgwt-wcas-suggestion[data-taxonomy=product_cat] .dgwt-wcas-st,.dgwt-wcas-has-img .dgwt-wcas-suggestion[data-taxonomy=product_tag] .dgwt-wcas-st{padding-left:0}.dgwt-wcas-ico-magnifier,.dgwt-wcas-ico-magnifier-handler{max-width:20px}.dgwt-wcas-no-submit .dgwt-wcas-ico-magnifier{height:50%;margin:auto;max-height:20px;width:100%;max-width:20px;left:12px;right:auto;opacity:.5;fill:#000}.rtl .dgwt-wcas-no-submit .dgwt-wcas-ico-magnifier{left:auto;right:12px}.dgwt-wcas-no-submit .dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input{padding:10px 15px 10px 40px}.rtl .dgwt-wcas-no-submit .dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input{padding:10px 40px 10px 15px}.dgwt-wcas-overlay-mobile-on,.dgwt-wcas-overlay-mobile-on body{overflow:hidden;min-width:100vw;min-height:100vh}.dgwt-wcas-om-bar{display:flex;height:45px;width:100%}.dgwt-wcas-om-bar .dgwt-wcas-om-return{width:45px;height:100%;display:block;background:#ccc;cursor:pointer;position:relative}.dgwt-wcas-om-bar .dgwt-wcas-om-return svg{width:23px;height:23px;position:absolute;left:12px;top:12px}.rtl .dgwt-wcas-om-bar .dgwt-wcas-om-return svg{left:11px;top:9px;-moz-transform:rotate(180deg);-webkit-transform:rotate(180deg);-o-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.dgwt-wcas-has-submit .dgwt-wcas-search-submit svg path{fill:#fff}.dgwt-wcas-om-bar .dgwt-wcas-has-submit-off .dgwt-wcas-preloader{right:0!important}.rtl .dgwt-wcas-om-bar .dgwt-wcas-has-submit-off .dgwt-wcas-preloader{left:4px!important;right:auto!important}@keyframes dgwt-wcas-preloader-price-anim{0%{background:rgba(128,128,128,.03)}50%{background:rgba(128,128,128,.1)}100%{background:rgba(128,128,128,.03)}}.dgwt-wcas-preloader-price-inner div:nth-child(1){left:0;animation-delay:-.1s}.dgwt-wcas-preloader-price-inner div:nth-child(2){left:13px;animation-delay:-.2s}.dgwt-wcas-preloader-price-inner div:nth-child(3){left:26px;animation-delay:-.3s}.dgwt-wcas-preloader-price{width:34px;height:10px;display:inline-block;overflow:hidden;background:0 0}.dgwt-wcas-preloader-price-inner{width:100%;height:100%;position:relative;transform:translateZ(0) scale(1);backface-visibility:hidden;transform-origin:0 0}.dgwt-wcas-preloader-price-inner div{position:absolute;width:8px;height:8px;background:rgba(128,128,128,.05);animation:dgwt-wcas-preloader-price-anim .8s cubic-bezier(0,.5,.5,1) infinite;-webkit-transition:all .2s ease-in-out;-moz-transition:all .2s ease-in-out;-ms-transition:all .2s ease-in-out;-o-transition:all .2s ease-in-out;transition:all .2s ease-in-out}.dgwt-wcas-om-bar .dgwt-wcas-sf-wrapp button.dgwt-wcas-search-submit{display:none}.dgwt-wcas-om-bar .dgwt-wcas-search-wrapp-mobile{width:calc(100% - 45px);max-width:none;margin:0}.dgwt-wcas-overlay-mobile .dgwt-wcas-search-form{width:100%}.dgwt-wcas-overlay-mobile{position:absolute;left:0;right:0;top:0;bottom:0;width:100%;background:#fff}.dgwt-wcas-overlay-mobile *{box-sizing:border-box}.dgwt-wcas-search-wrapp-mobile input[type=search].dgwt-wcas-search-input{height:45px!important;border-top:none;border-right:none;border-left:none;border-radius:0;font-size:16px!important}.dgwt-wcas-search-wrapp-mobile input[type=search].dgwt-wcas-search-input:focus{font-size:16px!important}.dgwt-wcas-overlay-mobile-on .dgwt-wcas-suggestions-wrapp{left:0!important;top:45px!important;width:100%!important;height:calc(100% - 45px)!important;position:absolute;overflow-y:auto;border:none;margin:0;display:block}.dgwt-wcas-overlay-mobile-on .dgwt-wcas-suggestion{width:100%}.dgwt-wcas-overlay-mobile-on .dgwt-wcas-enable-mobile-form{display:none}.dgwt-wcas-enable-mobile-form{position:absolute;z-index:100;left:0;top:0;width:100%;height:100%;cursor:pointer}html:not(.dgwt-wcas-overlay-mobile-on) .dgwt-wcas-icon-mobile .dgwt-wcas-search-form{display:none;position:relative}html:not(.dgwt-wcas-overlay-mobile-on) .dgwt-wcas-search-wrapp.dgwt-wcas-icon-mobile{min-width:0;display:inline-block;width:28px;height:28px}html:not(.dgwt-wcas-overlay-mobile-on) .dgwt-wcas-icon-handler{height:100%;width:100%}html:not(.dgwt-wcas-overlay-mobile-on) .dgwt-wcas-icon-handler .dgwt-wcas-ico-magnifier{opacity:1;position:static;max-width:none;max-height:none}.dgwt-wcas-overlay-mobile-on .dgwt-wcas-icon-handler{display:none}.dgwt-wcas-overlay-mobile-on.dgwt-wcas-is-ios .dgwt-wcas-suggestions-wrapp{height:calc(100% - 45px)!important}.dgwt-wcas-overlay-mobile-on.dgwt-wcas-is-ios{overflow:visible}.dgwt-wcas-overlay-mobile-on.dgwt-wcas-is-ios .dgwt-wcas-suggestions-wrapp{max-height:none!important;height:auto!important}.dgwt-wcas-overlay-mobile-on.dgwt-wcas-is-ios body:not(.dgwt-wcas-theme-flatsome)>:not(.dgwt-wcas-overlay-mobile){display:none}body .dgwt-wcas-content-wrapp .rood,body .dgwt-wcas-content-wrapp .zwave{display:none}.dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon{min-width:unset}.dgwt-wcas-layout-icon-flexible .dgwt-wcas-search-form{opacity:0}.dgwt-wcas-layout-icon-flexible-loaded .dgwt-wcas-search-form{opacity:1}.dgwt-wcas-search-icon-arrow{display:none}html:not(.dgwt-wcas-overlay-mobile-on) .dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon .dgwt-wcas-search-form{opacity:0;display:none;position:absolute;left:0;top:calc(100% + 8px);min-width:500px;z-index:1000}.dgwt-wcas-overlay-mobile .dgwt-wcas-search-icon,.dgwt-wcas-overlay-mobile .dgwt-wcas-search-icon-arrow{display:none}html:not(.dgwt-wcas-overlay-mobile-on) .dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon.dgwt-wcas-layout-icon-open .dgwt-wcas-search-form{display:block;opacity:1}.dgwt-wcas-search-icon{width:20px;height:auto;cursor:pointer}.dgwt-wcas-ico-magnifier-handler{margin-bottom:-.2em;width:100%}.dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon.dgwt-wcas-layout-icon-open .dgwt-wcas-search-icon{opacity:.6}.dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon.dgwt-wcas-layout-icon-open:not(.dgwt-wcas-has-submit) .dgwt-wcas-sf-wrapp .dgwt-wcas-ico-magnifier{display:none}.dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon.dgwt-wcas-layout-icon-open.dgwt-wcas-no-submit .dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input{padding-left:15px}.dgwt-wcas-layout-icon-open .dgwt-wcas-search-icon-arrow{display:block;position:absolute;top:calc(100% + 2px);left:0;z-index:5;width:15px;height:15px;background:#fff;border:1px solid #ddd;-webkit-transform:rotate(45deg);-moz-transform:rotate(45deg);-o-transform:rotate(45deg);-ms-transform:rotate(45deg);transform:rotate(45deg)}.dgwt-wcas-layout-icon-flexible:not(.dgwt-wcas-layout-icon) .dgwt-wcas-search-icon,.dgwt-wcas-layout-icon-flexible:not(.dgwt-wcas-layout-icon) .dgwt-wcas-search-icon-arrow{display:none}.dgwt-wcas-has-headings .dgwt-wcas-suggestion{border-bottom:none}.dgwt-wcas-has-headings .dgwt-wcas-st>span.dgwt-wcas-st--direct-headline{display:none}.dgwt-wcas-has-headings .dgwt-wcas-suggestion-headline{pointer-events:none;display:block;font-weight:500;white-space:nowrap}.dgwt-wcas-has-headings .dgwt-wcas-suggestion-headline .dgwt-wcas-st{border-bottom:1px solid #ddd;padding-bottom:3px;text-transform:uppercase;margin-top:16px;font-size:12px}.dgwt-wcas-has-headings .dgwt-wcas-suggestion.dgwt-wcas-suggestion-headline,.dgwt-wcas-has-headings .dgwt-wcas-suggestion.dgwt-wcas-suggestion-tax{border-bottom:none}.dgwt-wcas-has-headings .dgwt-wcas-suggestion-tax .dgwt-wcas-st{padding:0}.dgwt-wcas-has-headings .dgwt-wcas-suggestion.dgwt-wcas-suggestion-tax.dgwt-wcas-suggestion-selected,.dgwt-wcas-has-headings .dgwt-wcas-suggestion.dgwt-wcas-suggestion-tax:hover{background:0 0;text-decoration:underline}.dgwt-wcas-is-details .dgwt-wcas-has-headings .dgwt-wcas-suggestion.dgwt-wcas-suggestion-tax{min-height:30px}
|
assets/img/admin-troubleshooting-woof.png
ADDED
Binary file
|
assets/js/admin.js
CHANGED
@@ -1199,13 +1199,13 @@
|
|
1199 |
if (submitEnabled && _this.isColor(value)) {
|
1200 |
|
1201 |
$('.js-dgwt-wcas-search-submit').css('color', value);
|
1202 |
-
$('.dgwt-wcas-ico-magnifier').css('fill', value);
|
1203 |
|
1204 |
} else {
|
1205 |
_this.searchInput.css('background-color', '');
|
1206 |
|
1207 |
$('.js-dgwt-wcas-search-submit').css('color', '');
|
1208 |
-
$('.dgwt-wcas-ico-magnifier').css('fill', '');
|
1209 |
}
|
1210 |
},
|
1211 |
onColorSugBgColor: function ($el, value) {
|
1199 |
if (submitEnabled && _this.isColor(value)) {
|
1200 |
|
1201 |
$('.js-dgwt-wcas-search-submit').css('color', value);
|
1202 |
+
$('.dgwt-wcas-search-submit .dgwt-wcas-ico-magnifier path').css('fill', value);
|
1203 |
|
1204 |
} else {
|
1205 |
_this.searchInput.css('background-color', '');
|
1206 |
|
1207 |
$('.js-dgwt-wcas-search-submit').css('color', '');
|
1208 |
+
$('.dgwt-wcas-search-submit .dgwt-wcas-ico-magnifier path').css('fill', '');
|
1209 |
}
|
1210 |
},
|
1211 |
onColorSugBgColor: function ($el, value) {
|
assets/js/admin.min.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
!function(s){var t={inputSel:"dgwt-wcas-options-toggle input[type=radio]",groupSel:"dgwt_wcas_settings-group",reloadChoices:function(t){var e=s('[name="'+t+'"]').closest("."+this.groupSel),a=s('[name="'+t+'"]:checked').val(),i="";this.hideAll(e),(a=a.replace("_","-")).length>0&&(i="wcas-opt-"+a),s("."+i).length>0&&s("."+i).fadeIn()},hideAll:function(s){s.find('tr[class*="wcas-opt-"]').hide()},registerListeners:function(){var t=this;s("."+t.inputSel).on("change",function(){t.reloadChoices(s(this).attr("name"))})},init:function(){var t=this,e=s("."+t.inputSel+":checked");e.length>0&&(t.registerListeners(),e.each(function(){t.reloadChoices(s(this).attr("name"))}))}},e={inputSel:"dgwt-wcas-options-cb-toggle input[type=checkbox]",groupSel:"dgwt_wcas_settings-group",reloadChoices:function(t){var e=t.is(":checked"),a=this.getGroupSelector(t);s("."+a+":not(.dgwt-wcas-options-cb-toggle)").hide(),e&&s("."+a).each(function(){s(this).hasClass("js-dgwt-wcas-adv-settings")&&s(".js-dgwt-wcas-adv-settings-toggle").hasClass("woocommerce-input-toggle--disabled")||s(this).fadeIn()})},getGroupSelector(t){var e=t.closest(".dgwt-wcas-options-cb-toggle"),a="",i=e.attr("class").split(/\s+/);return s.each(i,function(s,t){-1!==t.indexOf("js-dgwt-wcas-cbtgroup-")&&(a=t)}),a},registerListeners:function(){var t=this;s(document).on("change","."+t.inputSel,function(){t.reloadChoices(s(this))})},refresh:function(){var t=this,e=s("."+t.inputSel);e.length>0&&e.each(function(){var e=s(this).is(":checked"),a=t.getGroupSelector(s(this));e?s("."+a).fadeIn():s("."+a+":not(.dgwt-wcas-options-cb-toggle)").hide()})},init:function(){var t=this,e=s("."+t.inputSel);e.length>0&&(t.registerListeners(),e.each(function(){t.reloadChoices(s(this))}))}},a={layoutSelect:"select[id*='search_layout']",overlayMobile:"input[id*='enable_mobile_overlay']",mobileBreakpoint:"input[id*='mobile_breakpoint']",searchIconColor:"input[id*='search_icon_color']",$select:null,$overlayMobileEl:null,$mobileBreakpointEl:null,$searchIconColorEl:null,setConditions:function(){var t=this.$select.find("option:selected").val(),e=s(".js-dgwt-wcas-adv-settings-toggle").hasClass("woocommerce-input-toggle--enabled");switch(this.hideOption(this.$overlayMobileEl),this.hideOption(this.$mobileBreakpointEl),this.hideOption(this.$searchIconColorEl),s("input[id*='bg_search_icon_color']").closest("tr").show(),t){case"icon":e&&this.showOption(this.$searchIconColorEl);break;case"icon-flexible":e&&(this.showOption(this.$mobileBreakpointEl),this.showOption(this.$searchIconColorEl));break;default:e&&(this.showOption(this.$overlayMobileEl),s("input[id*='bg_search_icon_color']").closest("tr").hide(),this.$overlayMobileEl.is(":checked")&&this.showOption(this.$mobileBreakpointEl))}},hideOption:function(s){s.closest("tr").hide()},showOption:function(s){s.closest("tr").show()},registerListeners:function(){var s=this;s.$select.on("change",function(){s.setConditions()}),s.$overlayMobileEl.on("change",function(){s.setConditions()})},init:function(){var t=this,e=s(t.layoutSelect);e.length>0&&(t.$select=e,t.$overlayMobileEl=s(t.overlayMobile),t.$mobileBreakpointEl=s(t.mobileBreakpoint),t.$searchIconColorEl=s(t.searchIconColor),t.registerListeners(),setTimeout(function(){t.setConditions()},400))}},i={actionTriggerClass:"js-ajax-build-index",actionStopTriggerClass:"js-ajax-stop-build-index",indexingWrappoerClass:"js-dgwt-wcas-indexing-wrapper",getWrapper:function(){return s("."+this.indexingWrappoerClass).closest(".dgwt-wcas-settings-info")},registerListeners:function(){var t=this;s(document).on("click","."+t.actionTriggerClass,function(e){e.preventDefault();var a=s(this);a.attr("disabled","disabled"),s(".dgwt-wcas-settings-info").addClass("wcas-ajax-build-index-wait");var i=!!a.hasClass("js-ajax-build-index-emergency");i&&(s(".dgwt-wcas-indexing-header__title").text("[Emergency mode] Wait... Indexing in progress"),s(".dgwt-wcas-indexing-header__troubleshooting, .dgwt-wcas-indexing-header__actions, .js-dgwt-wcas-indexer-details").hide()),s.ajax({url:ajaxurl,type:"post",data:{action:"dgwt_wcas_build_index",emergency:i},success:function(s){void 0!==s&&s.success&&(t.getWrapper().html(s.data.html),t.heartbeat())},complete:function(){a.removeAttr("disabled"),s(".dgwt-wcas-settings-info").removeClass("wcas-ajax-build-index-wait"),i&&window.location.reload()}})}),s(document).on("click","."+t.actionStopTriggerClass,function(e){e.preventDefault();var a=s(this);a.attr("disabled","disabled"),s.ajax({url:ajaxurl,type:"post",data:{action:"dgwt_wcas_stop_build_index"},success:function(s){void 0!==s&&s.success&&(t.getWrapper().html(s.data.html),t.heartbeat())},complete:function(){a.removeAttr("disabled")}})})},heartbeat:function(){var t=this;setTimeout(function(){s.ajax({url:ajaxurl,type:"post",data:{action:"dgwt_wcas_build_index_heartbeat"},success:function(s){void 0!==s&&s.success&&(t.getWrapper().html(s.data.html),s.data.loop&&t.heartbeat())}})},1e3)},detailsToggle:function(){var t;s(document).on("click",".js-dgwt-wcas-indexing-details-trigger",function(e){e.preventDefault();var a=s(".js-dgwt-wcas-indexer-details");a.hasClass("show")?(a.removeClass("show"),a.addClass("hide"),s(".js-dgwt-wcas-indexing__showd").addClass("show").removeClass("hide"),s(".js-dgwt-wcas-indexing__hided").addClass("hide").removeClass("show"),t=!1):(a.addClass("show"),a.removeClass("hide"),s(".js-dgwt-wcas-indexing__showd").addClass("hide").removeClass("show"),s(".js-dgwt-wcas-indexing__hided").addClass("show").removeClass("hide"),t=!0),s.ajax({url:ajaxurl,type:"post",data:{action:"dgwt_wcas_index_details_toggle",display:t}})})},init:function(){this.registerListeners(),s("."+this.indexingWrappoerClass).length>0&&this.heartbeat(),this.detailsToggle()}},o={init:function(){var t=this;s(".dgwt-wcas-selectize").length>0&&s.ajax({url:ajaxurl,data:{action:"dgwt_wcas_settings_list_custom_fields",_wpnonce:s(".dgwt-wcas-selectize").data("security")},success:function(s){void 0!==s&&void 0!==s.data&&t.initSelectize(s.data)}})},initSelectize:function(t){var e=s(".dgwt-wcas-selectize");e.length>0&&e.each(function(){var e=s(this),a=e.data("options"),i=t;if(a.length>0){a=JSON.parse('["'+decodeURI(a.replace(/&/g,'","').replace(/=/g,'","'))+'"]');var o="";a.forEach(function(s,t){if((t+1)%2==0){var e={value:s,label:o};i.push(e),o=""}o=s})}s(this).selectize({persist:!1,maxItems:null,valueField:"key",labelField:"label",searchField:["value","label"],options:i,create:function(s){return{value:s.key,label:s.label}},load:function(t,a){if(!t.length)return a();s.ajax({url:ajaxurl,data:{action:"dgwt_wcas_settings_list_custom_fields",_wpnonce:e.data("security")},error:function(){a()},success:function(s){a(s.data)}})}})})}},n={init:function(){var t=s(".js-dgwt-wcas-tooltip");t.length>0&&t.each(function(){var t=s(this)[0],e=s(this).data("tooltip-html-el");if(e){new DgwtWcasTooltip(t,{title:s("."+e+" > .dgwt-wcas-tooltip-wrapper")[0],placement:"top",trigger:"hover",html:!0})}})}},c={advClass:"js-dgwt-wcas-adv-settings",highlightClass:"dgwt-wcas-opt-highlight",transClass:"dgwt-wcas-opt-transition",init:function(){this.clickListener(),this.setStartingState()},clickListener:function(){var t=this;s(document).on("click",".js-dgwt-wcas-settings__advanced",function(){var e;e=s(".js-dgwt-wcas-adv-settings-toggle").hasClass("woocommerce-input-toggle--disabled")?"show":"hide",t.saveChoice(e)})},setStartingState:function(){var t=s("."+this.advClass);t.length>0&&(s(".js-dgwt-wcas-adv-settings-toggle").hasClass("woocommerce-input-toggle--enabled")?(t.show(),e.refresh()):t.hide())},saveChoice:function(t){s(".js-dgwt-wcas-settings__advanced").append('<span class="dgwt-wcas-adv-settings-saving">saving...</span>'),s.ajax({url:ajaxurl,data:{action:"dgwt_wcas_adv_settings",adv_settings_value:t}}).done(function(t){s(".dgwt-wcas-adv-settings-saving").remove()});var e=s(".js-dgwt-wcas-adv-settings-toggle");"show"===t&&(e.removeClass("woocommerce-input-toggle--disabled"),e.addClass("woocommerce-input-toggle--enabled")),"hide"===t&&(e.removeClass("woocommerce-input-toggle--enabled"),e.addClass("woocommerce-input-toggle--disabled")),this.toggleAdvancedOpt(t)},toggleAdvancedOpt:function(t){var i=this,o=s("."+i.advClass);o.length>0&&(o.addClass(i.highlightClass),o.addClass(i.transClass),"show"===t&&o.fadeIn(500,function(){setTimeout(function(){o.removeClass(i.highlightClass),setTimeout(function(){o.removeClass(i.transClass),e.refresh(),a.setConditions()},500)},500)}),"hide"===t&&setTimeout(function(){o.removeClass(i.transClass),o.fadeOut(500,function(){o.removeClass(i.highlightClass)})},500))}};window.DGWT_WCAS_SEARCH_PREVIEW={previewWrapper:{},searchWrapp:{},suggestionWrapp:{},searchInput:{},init:function(){this.previewWrapper=s(".js-dgwt-wcas-preview"),this.searchWrapp=s(".js-dgwt-wcas-search-wrapp"),this.suggestionWrapp=s(".js-dgwt-wcas-suggestions-wrapp"),this.detailsWrapp=s(".js-dgwt-wcas-details-wrapp"),this.searchInput=s(".js-dgwt-wcas-search-input"),this.onChangeHandler(),this.onColorHandler(),this.onTypeHandler(),this.disableSubmit(),this.noResultsHandler(),this.fixSizesInit()},isChecked:function(s){return!!(s.length>0&&s.is(":checked"))},isColor:function(s){return"string"==typeof s&&7===s.length&&"#"===s.charAt(0)},camelCase:function(s){for(var t=s.split("_"),e="",a=0;a<t.length;a++)e+=t[a].charAt(0).toUpperCase()+t[a].slice(1);return e},disableSubmit:function(){var t,e;s(".js-dgwt-wcas-preview-source").on("click",function(a){a.preventDefault();var i=a.pageX-100,o=a.pageY+10;void 0!==t&&(clearTimeout(t),e&&e.remove()),s("body").append('<div class="dgwt-wcas-click-alert">No interaction! This is only a preview.</div>'),(e=s(".dgwt-wcas-click-alert")).css({left:i,top:o}),s(".dgwt-wcas-preview-source").addClass("dgwt-wcas-preview-source-no-click"),t=setTimeout(function(){e.fadeOut(500,function(){s(this).remove(),s(".dgwt-wcas-preview-source").removeClass("dgwt-wcas-preview-source-no-click")})},2e3)})},noResultsHandler:function(){var t=this,e=".js-dgwt-wcas-preview .dgwt-wcas-suggestion:not(.js-dgwt-wcas-suggestion-nores)",a="input[id*='search_no_results_text']";s(document).on("focus",a,function(){s(e).addClass("dgwt-wcas-hide"),s(".js-dgwt-wcas-suggestion-nores").removeClass("dgwt-wcas-hide"),t.detailsWrapp.addClass("dgwt-wcas-hide"),t.suggestionWrapp.addClass("dgwt-wcas-preview-nores")}),s(document).on("blur",a,function(){s(e).removeClass("dgwt-wcas-hide"),s(".js-dgwt-wcas-suggestion-nores").addClass("dgwt-wcas-hide"),t.detailsWrapp.removeClass("dgwt-wcas-hide"),t.suggestionWrapp.removeClass("dgwt-wcas-preview-nores")})},onChangeHandler:function(){for(var t=this,e=["show_submit_button","max_form_width","show_product_image","show_product_sku","show_product_desc","show_product_price","show_matching_categories","show_matching_tags","show_matching_brands","show_matching_posts","show_matching_pages","show_grouped_results","suggestions_limit","show_details_box"],a=0;a<e.length;a++){var i="input[id*='"+e[a]+"']",o=s(i),n="onChange"+t.camelCase(e[a]);"function"==typeof t[n]&&t[n](o,o.val()),s(document).on("change",i,function(){n=s(this).attr("id").replace("]","").replace("dgwt_wcas_settings[",""),n="onChange"+t.camelCase(n),t[n](s(this),this.value)})}},onColorHandler:function(){for(var t=this,e=["search_icon_color","bg_input_color","text_input_color","border_input_color","bg_submit_color","text_submit_color","sug_bg_color","sug_hover_color","sug_text_color","sug_highlight_color","sug_border_color"],a=0;a<e.length;a++){var i="input[id*='"+e[a]+"']",o=s(i),n="onColor"+t.camelCase(e[a]);t[n](o,o.val()),s(document).on("change",i,function(e){n=s(this).attr("id").replace("]","").replace("dgwt_wcas_settings[",""),n="onColor"+t.camelCase(n),t[n](s(this),this.value)})}},onColorChangeHandler:function(s,t){var e=s.attr("id").replace("]","").replace("dgwt_wcas_settings[","");this[e="onColor"+this.camelCase(e)](s,t)},onTypeHandler:function(){for(var t=this,e=["search_submit_text","search_placeholder","search_no_results_text","search_see_all_results_text"],a=0;a<e.length;a++){var i="input[id*='"+e[a]+"']",o=s(i),n="onType"+t.camelCase(e[a]);t[n](o,o.val()),s(document).on("input",i,function(e){n=s(e.target).attr("id").replace("]","").replace("dgwt_wcas_settings[",""),n="onType"+t.camelCase(n),t[n](s(e.target),this.value)})}},onChangeMaxFormWidth:function(t,e){e.length>0&&"0"!=e?(this.searchWrapp.css("max-width",e+"px"),this.suggestionWrapp.css("max-width",e+"px")):(this.searchWrapp.css("max-width","100%"),this.suggestionWrapp.css("max-width","100%")),this.onChangeShowDetailsBox(s("input[id*='show_details_box']"))},onChangeShowSubmitButton:function(t,e){var a=s(".js-dgwt-wcas-search-submit");if(this.isChecked(t)){this.searchWrapp.addClass("dgwt-wcas-has-submit"),this.searchWrapp.removeClass("dgwt-wcas-no-submit"),a.show(),s(".dgwt-wcas-sf-wrapp > .dgwt-wcas-ico-magnifier").hide();var i=s("input[id*='bg_submit_color']"),o=s("input[id*='text_submit_color']");this.onColorBgSubmitColor(i,i.val()),this.onColorTextSubmitColor(o,o.val())}else this.searchWrapp.addClass("dgwt-wcas-no-submit"),this.searchWrapp.removeClass("dgwt-wcas-has-submit"),a.hide(),s(".dgwt-wcas-sf-wrapp > .dgwt-wcas-ico-magnifier").show()},onChangeShowProductImage:function(t,e){var a=s(".js-dgwt-wcas-si"),i=s(".js-dgwt-wcas-content-wrapp");this.isChecked(t)?(this.suggestionWrapp.addClass("dgwt-wcas-has-img"),s(".dgwt-wcas-suggestion-product > .dgwt-wcas-st").remove(),s(".dgwt-wcas-suggestion-product > .dgwt-wcas-sp").remove(),i.show(),a.show()):(this.suggestionWrapp.removeClass("dgwt-wcas-has-img"),i.each(function(){s(this).closest(".dgwt-wcas-suggestion-product").append(s(this).html())}),i.hide(),a.hide())},onChangeShowProductSku:function(t,e){var a=s(".js-dgwt-wcas-sku");this.isChecked(t)?(this.suggestionWrapp.addClass("dgwt-wcas-has-sku"),a.show()):(this.suggestionWrapp.removeClass("dgwt-wcas-has-sku"),a.hide())},onChangeShowProductDesc:function(t,e){var a=s(".js-dgwt-wcas-sd");this.isChecked(t)?(this.suggestionWrapp.addClass("dgwt-wcas-has-desc"),a.show()):(this.suggestionWrapp.removeClass("dgwt-wcas-has-desc"),a.hide())},onChangeShowProductPrice:function(t,e){var a=s(".js-dgwt-wcas-sp");this.isChecked(t)?(this.suggestionWrapp.addClass("dgwt-wcas-has-price"),a.show()):(this.suggestionWrapp.removeClass("dgwt-wcas-has-price"),a.hide())},onChangeShowMatchingCategories:function(t,e){var a=s(".dgwt-wcas-suggestion-headline-cat"),i=s(".dgwt-wcas-suggestion-cat");this.isChecked(t)?(a.show(),i.show(),i.removeClass("js-dgwt-wcas-suggestion-hidden"),this.onChangeShowGroupedResults(s("input[id*='show_grouped_results']"))):(a.hide(),i.hide(),i.addClass("js-dgwt-wcas-suggestion-hidden"));var o=s("input[id*='suggestions_limit']");this.onChangeSuggestionsLimit(o,o.val())},onChangeShowMatchingTags:function(t,e){var a=s(".dgwt-wcas-suggestion-headline-tag"),i=s(".dgwt-wcas-suggestion-tag");this.isChecked(t)?(a.show(),i.show(),i.removeClass("js-dgwt-wcas-suggestion-hidden"),this.onChangeShowGroupedResults(s("input[id*='show_grouped_results']"))):(a.hide(),i.hide(),i.addClass("js-dgwt-wcas-suggestion-hidden"));var o=s("input[id*='suggestions_limit']");this.onChangeSuggestionsLimit(o,o.val())},onChangeShowMatchingBrands:function(t,e){var a=s(".dgwt-wcas-suggestion-headline-brand"),i=s(".dgwt-wcas-suggestion-brand");this.isChecked(t)?(a.show(),i.show(),i.removeClass("js-dgwt-wcas-suggestion-hidden"),this.onChangeShowGroupedResults(s("input[id*='show_grouped_results']"))):(a.hide(),i.hide(),i.addClass("js-dgwt-wcas-suggestion-hidden"));var o=s("input[id*='suggestions_limit']");this.onChangeSuggestionsLimit(o,o.val())},onChangeShowMatchingPosts:function(t,e){var a=s(".dgwt-wcas-suggestion-headline-post"),i=s(".dgwt-wcas-suggestion-post");this.isChecked(t)?(a.show(),i.show(),i.removeClass("js-dgwt-wcas-suggestion-hidden"),this.onChangeShowGroupedResults(s("input[id*='show_grouped_results']"))):(a.hide(),i.hide(),i.addClass("js-dgwt-wcas-suggestion-hidden"));var o=s("input[id*='suggestions_limit']");this.onChangeSuggestionsLimit(o,o.val())},onChangeShowMatchingPages:function(t,e){var a=s(".dgwt-wcas-suggestion-headline-page"),i=s(".dgwt-wcas-suggestion-page");this.isChecked(t)?(a.show(),i.show(),i.removeClass("js-dgwt-wcas-suggestion-hidden"),this.onChangeShowGroupedResults(s("input[id*='show_grouped_results']"))):(a.hide(),i.hide(),i.addClass("js-dgwt-wcas-suggestion-hidden"));var o=s("input[id*='suggestions_limit']");this.onChangeSuggestionsLimit(o,o.val())},onChangeShowGroupedResults:function(t,e){var a=s(".dgwt-wcas-st--direct-headline"),i=s(".dgwt-wcas-suggestion-headline");this.isChecked(t)?(a.addClass("dgwt-wcas-hidden"),this.suggestionWrapp.addClass("dgwt-wcas-has-headings"),s(".dgwt-wcas-suggestion-headline").show(),this.isChecked(s("input[id*='show_matching_categories']"))||s(".dgwt-wcas-suggestion-headline-cat").hide(),this.isChecked(s("input[id*='show_matching_tags']"))||s(".dgwt-wcas-suggestion-headline-tag").hide(),this.isChecked(s("input[id*='show_matching_brands']"))||s(".dgwt-wcas-suggestion-headline-brand").hide(),this.isChecked(s("input[id*='show_matching_posts']"))||s(".dgwt-wcas-suggestion-headline-post").hide(),this.isChecked(s("input[id*='show_matching_pages']"))||s(".dgwt-wcas-suggestion-headline-page").hide()):(a.removeClass("dgwt-wcas-hidden"),i.hide(),this.suggestionWrapp.removeClass("dgwt-wcas-has-headings"))},onChangeSuggestionsLimit:function(t,e){setTimeout(function(){var a=0,i=7,o=s(".dgwt-wcas-suggestion-duplicated"),n=["brand","cat","tag","post","page","product"];e.length>0&&"0"!=e&&(i=Math.abs(e)),o.length>0&&o.remove();var c=[];for(a=0;a<n.length;a++){var r=s(".dgwt-wcas-suggestion-"+n[a]+":not(.js-dgwt-wcas-suggestion-hidden)");r.length>0&&c.push(r)}var d=c.length;if(c.length>0)for(var g=i-c.length,l=c.length-1;g>0;){var h=c[l].clone();h.addClass("dgwt-wcas-suggestion-duplicated"),h.removeClass("dgwt-wcas-suggestion-selected"),c[l].after(h),d++,--l<0&&(l=c.length-1),g--}d>i&&t.val(d)},10)},onChangeShowDetailsBox:function(t,e){var a=this;a.isChecked(t)?(a.detailsWrapp.show(),a.searchWrapp.addClass("dgwt-wcas-is-detail-box"),a.previewWrapper.addClass("dgwt-wcas-is-details"),a.previewWrapper.addClass("dgwt-wcas-details-right"),setTimeout(function(){if(s(".dgwt-wcas-suggestion-product:not(.dgwt-wcas-suggestion-duplicated)").addClass("dgwt-wcas-suggestion-selected"),a.searchWrapp.width()>=550){a.previewWrapper.addClass("dgwt-wcas-full-width");var t=getComputedStyle(a.searchWrapp[0]).width;(t=Math.round(parseFloat(t.replace("px",""))))%2==0?(a.suggestionWrapp.css("width",Math.round(t/2)),a.detailsWrapp.css("width",Math.round(t/2))):(a.suggestionWrapp.css("width",Math.floor(t/2)),a.detailsWrapp.css("width",Math.ceil(t/2)))}else a.suggestionWrapp.width(a.searchWrapp.width())},10)):(a.detailsWrapp.hide(),a.searchWrapp.removeClass("dgwt-wcas-is-detail-box"),a.previewWrapper.removeClass("dgwt-wcas-is-details"),a.previewWrapper.removeClass("dgwt-wcas-details-right"),a.previewWrapper.removeClass("dgwt-wcas-full-width"),s(".dgwt-wcas-suggestion-product").removeClass("dgwt-wcas-suggestion-selected"),a.suggestionWrapp.css("width",""),a.detailsWrapp.css("width",""))},onColorSearchIconColor:function(s,t){},onColorBgInputColor:function(s,t){this.isColor(t)?this.searchInput.css("background-color",t):this.searchInput.css("background-color","")},onColorTextInputColor:function(t,e){var a="dgwt-wcas-preview-placeholder-style";if(this.isColor(e)){var i='<style class="'+a+'">';i+=".dgwt-wcas-search-input::placeholder{opacity: 0.3; color:"+e+"!important;}",i+=".dgwt-wcas-search-input::-webkit-input-placeholder{opacity: 0.3; color:"+e+"!important;}",i+=".dgwt-wcas-search-input:-moz-placeholder{opacity: 0.3; color:"+e+"!important;}",i+=".dgwt-wcas-search-input::-moz-placeholder{opacity: 0.3; color:"+e+"!important;}",i+=".dgwt-wcas-search-input:-ms-input-placeholder{opacity: 0.3; color:"+e+"!important;}",i+=".dgwt-wcas-ico-magnifier path {fill:"+e+"}",i+="</style>",s("head").append(i),this.searchInput.css("color",e)}else{this.searchInput.css("color","");var o=s("."+a);o.length>0&&o.remove()}},onColorBorderInputColor:function(s,t){this.isColor(t)?this.searchInput.css("border-color",t):this.searchInput.css("border-color","")},onColorBgSubmitColor:function(t,e){if(this.isChecked(s("input[id*='show_submit_button']"))&&this.isColor(e)){var a='<style class="dgwt-wcas-preview-submit-style">';a+=".dgwt-wcas-search-submit::before{border-color: transparent "+e+"!important;}",a+=".dgwt-wcas-search-submit:hover::before{border-right-color: "+e+"!important;}",a+=".dgwt-wcas-search-submit:focus::before{border-right-color: "+e+"!important;}",a+=".dgwt-wcas-search-submit{background-color: "+e+"!important;}",a+=".dgwt-wcas-om-bar .dgwt-wcas-om-return{background-color: "+e+"!important;}",a+="</style>",s("head").append(a)}else{var i=s(".dgwt-wcas-preview-submit-style");i.length>0&&i.remove()}},onColorTextSubmitColor:function(t,e){this.isChecked(s("input[id*='show_submit_button']"))&&this.isColor(e)?(s(".js-dgwt-wcas-search-submit").css("color",e),s(".dgwt-wcas-ico-magnifier").css("fill",e)):(this.searchInput.css("background-color",""),s(".js-dgwt-wcas-search-submit").css("color",""),s(".dgwt-wcas-ico-magnifier").css("fill",""))},onColorSugBgColor:function(t,e){var a="dgwt-wcas-preview-sugbgcol-style";if(this.isColor(e)){var i='<style class="'+a+'">';i+=".dgwt-wcas-suggestions-wrapp,",i+=".dgwt-wcas-details-wrapp",i+="{background-color: "+e+"!important;}",i+="</style>",s("head").append(i)}else{var o=s("."+a);o.length>0&&o.remove()}},onColorSugHoverColor:function(t,e){this.isColor(e)?setTimeout(function(){s(".dgwt-wcas-suggestion-selected").css("background-color",e)},50):s(".dgwt-wcas-suggestion-selected").css("background-color","")},onColorSugTextColor:function(t,e){var a="dgwt-wcas-preview-sugtextcol-style";if(this.isColor(e)){var i='<style class="'+a+'">';i+=".dgwt-wcas-suggestions-wrapp *,",i+=".dgwt-wcas-details-wrapp *,",i+=".dgwt-wcas-sd,",i+=".dgwt-wcas-suggestion *",i+="{color: "+e+"!important;}",i+="</style>",s("head").append(i)}else{var o=s("."+a);o.length>0&&o.remove()}},onColorSugHighlightColor:function(t,e){var a="dgwt-wcas-preview-sughighlight-style";if(this.isColor(e)){var i='<style class="'+a+'">';i+=".dgwt-wcas-st strong,",i+=".dgwt-wcas-sd strong",i+="{color: "+e+"!important;}",i+="</style>",s("head").append(i)}else{var o=s("."+a);o.length>0&&o.remove()}},onColorSugBorderColor:function(t,e){var a="dgwt-wcas-preview-sugborder-style";if(this.isColor(e)){var i='<style class="'+a+'">';i+=".dgwt-wcas-suggestions-wrapp,",i+=".dgwt-wcas-details-wrapp,",i+=".dgwt-wcas-suggestion,",i+=".dgwt-wcas-datails-title,",i+=".dgwt-wcas-details-more-products",i+="{border-color: "+e+"!important;}",i+="</style>",s("head").append(i)}else{var o=s("."+a);o.length>0&&o.remove()}},onTypeSearchSubmitText:function(t,e){var a=s(".js-dgwt-wcas-search-submit-l"),i=s(".js-dgwt-wcas-search-submit-m");e.length>0?(a.text(e),a.show(),i.hide()):(a.text(""),a.hide(),i.show())},onTypeSearchPlaceholder:function(s,t){0==t.length&&(t=dgwt_wcas.labels.search_placeholder),this.searchInput.attr("placeholder",t)},onTypeSearchNoResultsText:function(t,e){0==e.length&&(e=dgwt_wcas.labels.no_results),s(".js-dgwt-wcas-suggestion-nores span").text(e)},onTypeSearchSeeAllResultsText:function(t,e){0==e.length&&(e=dgwt_wcas.labels.show_more),s(".js-dgwt-wcas-st-more-label").text(e)},fixSizesInit:function(){var t=this;s(document).on("click","#dgwt_wcas_autocomplete-tab",function(){t.onChangeShowDetailsBox(s("input[id*='show_details_box']"))})}};var r={settingsTab:"#dgwt_wcas_troubleshooting-tab",noIssuesClass:".js-dgwt-wcas-troubleshooting-no-issues",counterClass:".js-dgwt-wcas-troubleshooting-count",issuesListClass:".js-dgwt-wcas-troubleshooting-issues",progressBar:".dgwt-wcas-troubleshooting-wrapper .progress_bar",progressBarInner:".dgwt-wcas-troubleshooting-wrapper .progress-bar-inner",resetButtonName:"dgwt-wcas-reset-async-tests",init:function(){var t=this;if(void 0===dgwt_wcas.troubleshooting)return;const e=dgwt_wcas.troubleshooting.tests.issues.critical+dgwt_wcas.troubleshooting.tests.issues.recommended;e>0&&(s(t.counterClass).text(e),s(t.settingsTab).addClass("enabled")),dgwt_wcas.troubleshooting.tests.results_async.length>0&&s.each(dgwt_wcas.troubleshooting.tests.results_async,function(){t.appendIssue(this,!1)}),dgwt_wcas.troubleshooting.tests.direct.length>0&&s.each(dgwt_wcas.troubleshooting.tests.direct,function(){t.appendIssue(this,!1)}),dgwt_wcas.troubleshooting.tests.async.length>0&&t.maybeRunNextAsyncTest(),s(document).on("click",'input[name="'+t.resetButtonName+'"]',function(e){s('input[name="'+t.resetButtonName+'"]').attr("disabled","disabled");var a={action:"dgwt_wcas_troubleshooting_reset_async_tests",_wpnonce:dgwt_wcas.troubleshooting.nonce.troubleshooting_reset_async_tests};return s.post(ajaxurl,a,function(){location.reload()}),!1})},appendIssue:function(t,e){var a,i=wp.template("dgwt-wcas-troubleshooting-issue"),o=s(this.issuesListClass+"-"+t.status);"good"!==t.status&&(s(this.noIssuesClass).hide(),e&&dgwt_wcas.troubleshooting.tests.issues[t.status]++,(a=dgwt_wcas.troubleshooting.tests.issues.critical+dgwt_wcas.troubleshooting.tests.issues.recommended)>0&&(s(this.counterClass).text(a),s(this.settingsTab).addClass("enabled")),s(o).append(i(t)))},maybeRunNextAsyncTest:function(){var t=this;dgwt_wcas.troubleshooting.tests.async.length>0&&s.each(dgwt_wcas.troubleshooting.tests.async,function(){var e={action:"dgwt_wcas_troubleshooting_test",test:this.test,_wpnonce:dgwt_wcas.troubleshooting.nonce.troubleshooting_async_test};return!!this.completed||(this.completed=!0,s(t.progressBar).show(),s.post(ajaxurl,e,function(s){s.success&&t.appendIssue(s.data,!0),t.maybeRunNextAsyncTest()}),!1)}),t.recalculateProgression()},recalculateProgression:function(){var t=this,e=dgwt_wcas.troubleshooting.tests.async.length,a=0;s.each(dgwt_wcas.troubleshooting.tests.async,function(){this.completed&&a++});var i=Math.ceil(a/e*100);s(t.progressBarInner).css("width",i+"%"),100===i&&setTimeout(function(){s(t.progressBar).slideUp()},2e3)}};s(document).ready(function(){var d,g;(d=s(".js-dgwt-wcas-settings-margin-nob")).length>0&&d.each(function(){var t=s(this).find("td .dgwt-wcas-fieldset");if(t.length>0){var e=s(this).prev(".js-dgwt-wcas-settings-margin");if(e.length>0){var a=s(this).attr("class").split(/\s+/),i="";s.each(a,function(s,t){-1!==t.indexOf("js-dgwt-wcas-cbtgroup-")&&(i=t)});var o=t.clone(!0,!0);o.addClass("dgwt-wcas-settings-margin-nob"),i&&o.addClass(i),o.appendTo(e.find("td")),s(this).remove()}}}),t.init(),e.init(),a.init(),(g=s(".js-dgwt-wcas-sgs-autocolspan")).length>0&&g.find("td").attr("colspan",2),i.init(),o.init(),n.init(),c.init(),r.init(),window.DGWT_WCAS_SEARCH_PREVIEW.init()})}(jQuery);
|
1 |
+
!function(s){var t={inputSel:"dgwt-wcas-options-toggle input[type=radio]",groupSel:"dgwt_wcas_settings-group",reloadChoices:function(t){var e=s('[name="'+t+'"]').closest("."+this.groupSel),a=s('[name="'+t+'"]:checked').val(),i="";this.hideAll(e),(a=a.replace("_","-")).length>0&&(i="wcas-opt-"+a),s("."+i).length>0&&s("."+i).fadeIn()},hideAll:function(s){s.find('tr[class*="wcas-opt-"]').hide()},registerListeners:function(){var t=this;s("."+t.inputSel).on("change",function(){t.reloadChoices(s(this).attr("name"))})},init:function(){var t=this,e=s("."+t.inputSel+":checked");e.length>0&&(t.registerListeners(),e.each(function(){t.reloadChoices(s(this).attr("name"))}))}},e={inputSel:"dgwt-wcas-options-cb-toggle input[type=checkbox]",groupSel:"dgwt_wcas_settings-group",reloadChoices:function(t){var e=t.is(":checked"),a=this.getGroupSelector(t);s("."+a+":not(.dgwt-wcas-options-cb-toggle)").hide(),e&&s("."+a).each(function(){s(this).hasClass("js-dgwt-wcas-adv-settings")&&s(".js-dgwt-wcas-adv-settings-toggle").hasClass("woocommerce-input-toggle--disabled")||s(this).fadeIn()})},getGroupSelector(t){var e=t.closest(".dgwt-wcas-options-cb-toggle"),a="",i=e.attr("class").split(/\s+/);return s.each(i,function(s,t){-1!==t.indexOf("js-dgwt-wcas-cbtgroup-")&&(a=t)}),a},registerListeners:function(){var t=this;s(document).on("change","."+t.inputSel,function(){t.reloadChoices(s(this))})},refresh:function(){var t=this,e=s("."+t.inputSel);e.length>0&&e.each(function(){var e=s(this).is(":checked"),a=t.getGroupSelector(s(this));e?s("."+a).fadeIn():s("."+a+":not(.dgwt-wcas-options-cb-toggle)").hide()})},init:function(){var t=this,e=s("."+t.inputSel);e.length>0&&(t.registerListeners(),e.each(function(){t.reloadChoices(s(this))}))}},a={layoutSelect:"select[id*='search_layout']",overlayMobile:"input[id*='enable_mobile_overlay']",mobileBreakpoint:"input[id*='mobile_breakpoint']",searchIconColor:"input[id*='search_icon_color']",$select:null,$overlayMobileEl:null,$mobileBreakpointEl:null,$searchIconColorEl:null,setConditions:function(){var t=this.$select.find("option:selected").val(),e=s(".js-dgwt-wcas-adv-settings-toggle").hasClass("woocommerce-input-toggle--enabled");switch(this.hideOption(this.$overlayMobileEl),this.hideOption(this.$mobileBreakpointEl),this.hideOption(this.$searchIconColorEl),s("input[id*='bg_search_icon_color']").closest("tr").show(),t){case"icon":e&&this.showOption(this.$searchIconColorEl);break;case"icon-flexible":e&&(this.showOption(this.$mobileBreakpointEl),this.showOption(this.$searchIconColorEl));break;default:e&&(this.showOption(this.$overlayMobileEl),s("input[id*='bg_search_icon_color']").closest("tr").hide(),this.$overlayMobileEl.is(":checked")&&this.showOption(this.$mobileBreakpointEl))}},hideOption:function(s){s.closest("tr").hide()},showOption:function(s){s.closest("tr").show()},registerListeners:function(){var s=this;s.$select.on("change",function(){s.setConditions()}),s.$overlayMobileEl.on("change",function(){s.setConditions()})},init:function(){var t=this,e=s(t.layoutSelect);e.length>0&&(t.$select=e,t.$overlayMobileEl=s(t.overlayMobile),t.$mobileBreakpointEl=s(t.mobileBreakpoint),t.$searchIconColorEl=s(t.searchIconColor),t.registerListeners(),setTimeout(function(){t.setConditions()},400))}},i={actionTriggerClass:"js-ajax-build-index",actionStopTriggerClass:"js-ajax-stop-build-index",indexingWrappoerClass:"js-dgwt-wcas-indexing-wrapper",getWrapper:function(){return s("."+this.indexingWrappoerClass).closest(".dgwt-wcas-settings-info")},registerListeners:function(){var t=this;s(document).on("click","."+t.actionTriggerClass,function(e){e.preventDefault();var a=s(this);a.attr("disabled","disabled"),s(".dgwt-wcas-settings-info").addClass("wcas-ajax-build-index-wait");var i=!!a.hasClass("js-ajax-build-index-emergency");i&&(s(".dgwt-wcas-indexing-header__title").text("[Emergency mode] Wait... Indexing in progress"),s(".dgwt-wcas-indexing-header__troubleshooting, .dgwt-wcas-indexing-header__actions, .js-dgwt-wcas-indexer-details").hide()),s.ajax({url:ajaxurl,type:"post",data:{action:"dgwt_wcas_build_index",emergency:i},success:function(s){void 0!==s&&s.success&&(t.getWrapper().html(s.data.html),t.heartbeat())},complete:function(){a.removeAttr("disabled"),s(".dgwt-wcas-settings-info").removeClass("wcas-ajax-build-index-wait"),i&&window.location.reload()}})}),s(document).on("click","."+t.actionStopTriggerClass,function(e){e.preventDefault();var a=s(this);a.attr("disabled","disabled"),s.ajax({url:ajaxurl,type:"post",data:{action:"dgwt_wcas_stop_build_index"},success:function(s){void 0!==s&&s.success&&(t.getWrapper().html(s.data.html),t.heartbeat())},complete:function(){a.removeAttr("disabled")}})})},heartbeat:function(){var t=this;setTimeout(function(){s.ajax({url:ajaxurl,type:"post",data:{action:"dgwt_wcas_build_index_heartbeat"},success:function(s){void 0!==s&&s.success&&(t.getWrapper().html(s.data.html),s.data.loop&&t.heartbeat())}})},1e3)},detailsToggle:function(){var t;s(document).on("click",".js-dgwt-wcas-indexing-details-trigger",function(e){e.preventDefault();var a=s(".js-dgwt-wcas-indexer-details");a.hasClass("show")?(a.removeClass("show"),a.addClass("hide"),s(".js-dgwt-wcas-indexing__showd").addClass("show").removeClass("hide"),s(".js-dgwt-wcas-indexing__hided").addClass("hide").removeClass("show"),t=!1):(a.addClass("show"),a.removeClass("hide"),s(".js-dgwt-wcas-indexing__showd").addClass("hide").removeClass("show"),s(".js-dgwt-wcas-indexing__hided").addClass("show").removeClass("hide"),t=!0),s.ajax({url:ajaxurl,type:"post",data:{action:"dgwt_wcas_index_details_toggle",display:t}})})},init:function(){this.registerListeners(),s("."+this.indexingWrappoerClass).length>0&&this.heartbeat(),this.detailsToggle()}},o={init:function(){var t=this;s(".dgwt-wcas-selectize").length>0&&s.ajax({url:ajaxurl,data:{action:"dgwt_wcas_settings_list_custom_fields",_wpnonce:s(".dgwt-wcas-selectize").data("security")},success:function(s){void 0!==s&&void 0!==s.data&&t.initSelectize(s.data)}})},initSelectize:function(t){var e=s(".dgwt-wcas-selectize");e.length>0&&e.each(function(){var e=s(this),a=e.data("options"),i=t;if(a.length>0){a=JSON.parse('["'+decodeURI(a.replace(/&/g,'","').replace(/=/g,'","'))+'"]');var o="";a.forEach(function(s,t){if((t+1)%2==0){var e={value:s,label:o};i.push(e),o=""}o=s})}s(this).selectize({persist:!1,maxItems:null,valueField:"key",labelField:"label",searchField:["value","label"],options:i,create:function(s){return{value:s.key,label:s.label}},load:function(t,a){if(!t.length)return a();s.ajax({url:ajaxurl,data:{action:"dgwt_wcas_settings_list_custom_fields",_wpnonce:e.data("security")},error:function(){a()},success:function(s){a(s.data)}})}})})}},n={init:function(){var t=s(".js-dgwt-wcas-tooltip");t.length>0&&t.each(function(){var t=s(this)[0],e=s(this).data("tooltip-html-el");if(e){new DgwtWcasTooltip(t,{title:s("."+e+" > .dgwt-wcas-tooltip-wrapper")[0],placement:"top",trigger:"hover",html:!0})}})}},c={advClass:"js-dgwt-wcas-adv-settings",highlightClass:"dgwt-wcas-opt-highlight",transClass:"dgwt-wcas-opt-transition",init:function(){this.clickListener(),this.setStartingState()},clickListener:function(){var t=this;s(document).on("click",".js-dgwt-wcas-settings__advanced",function(){var e;e=s(".js-dgwt-wcas-adv-settings-toggle").hasClass("woocommerce-input-toggle--disabled")?"show":"hide",t.saveChoice(e)})},setStartingState:function(){var t=s("."+this.advClass);t.length>0&&(s(".js-dgwt-wcas-adv-settings-toggle").hasClass("woocommerce-input-toggle--enabled")?(t.show(),e.refresh()):t.hide())},saveChoice:function(t){s(".js-dgwt-wcas-settings__advanced").append('<span class="dgwt-wcas-adv-settings-saving">saving...</span>'),s.ajax({url:ajaxurl,data:{action:"dgwt_wcas_adv_settings",adv_settings_value:t}}).done(function(t){s(".dgwt-wcas-adv-settings-saving").remove()});var e=s(".js-dgwt-wcas-adv-settings-toggle");"show"===t&&(e.removeClass("woocommerce-input-toggle--disabled"),e.addClass("woocommerce-input-toggle--enabled")),"hide"===t&&(e.removeClass("woocommerce-input-toggle--enabled"),e.addClass("woocommerce-input-toggle--disabled")),this.toggleAdvancedOpt(t)},toggleAdvancedOpt:function(t){var i=this,o=s("."+i.advClass);o.length>0&&(o.addClass(i.highlightClass),o.addClass(i.transClass),"show"===t&&o.fadeIn(500,function(){setTimeout(function(){o.removeClass(i.highlightClass),setTimeout(function(){o.removeClass(i.transClass),e.refresh(),a.setConditions()},500)},500)}),"hide"===t&&setTimeout(function(){o.removeClass(i.transClass),o.fadeOut(500,function(){o.removeClass(i.highlightClass)})},500))}};window.DGWT_WCAS_SEARCH_PREVIEW={previewWrapper:{},searchWrapp:{},suggestionWrapp:{},searchInput:{},init:function(){this.previewWrapper=s(".js-dgwt-wcas-preview"),this.searchWrapp=s(".js-dgwt-wcas-search-wrapp"),this.suggestionWrapp=s(".js-dgwt-wcas-suggestions-wrapp"),this.detailsWrapp=s(".js-dgwt-wcas-details-wrapp"),this.searchInput=s(".js-dgwt-wcas-search-input"),this.onChangeHandler(),this.onColorHandler(),this.onTypeHandler(),this.disableSubmit(),this.noResultsHandler(),this.fixSizesInit()},isChecked:function(s){return!!(s.length>0&&s.is(":checked"))},isColor:function(s){return"string"==typeof s&&7===s.length&&"#"===s.charAt(0)},camelCase:function(s){for(var t=s.split("_"),e="",a=0;a<t.length;a++)e+=t[a].charAt(0).toUpperCase()+t[a].slice(1);return e},disableSubmit:function(){var t,e;s(".js-dgwt-wcas-preview-source").on("click",function(a){a.preventDefault();var i=a.pageX-100,o=a.pageY+10;void 0!==t&&(clearTimeout(t),e&&e.remove()),s("body").append('<div class="dgwt-wcas-click-alert">No interaction! This is only a preview.</div>'),(e=s(".dgwt-wcas-click-alert")).css({left:i,top:o}),s(".dgwt-wcas-preview-source").addClass("dgwt-wcas-preview-source-no-click"),t=setTimeout(function(){e.fadeOut(500,function(){s(this).remove(),s(".dgwt-wcas-preview-source").removeClass("dgwt-wcas-preview-source-no-click")})},2e3)})},noResultsHandler:function(){var t=this,e=".js-dgwt-wcas-preview .dgwt-wcas-suggestion:not(.js-dgwt-wcas-suggestion-nores)",a="input[id*='search_no_results_text']";s(document).on("focus",a,function(){s(e).addClass("dgwt-wcas-hide"),s(".js-dgwt-wcas-suggestion-nores").removeClass("dgwt-wcas-hide"),t.detailsWrapp.addClass("dgwt-wcas-hide"),t.suggestionWrapp.addClass("dgwt-wcas-preview-nores")}),s(document).on("blur",a,function(){s(e).removeClass("dgwt-wcas-hide"),s(".js-dgwt-wcas-suggestion-nores").addClass("dgwt-wcas-hide"),t.detailsWrapp.removeClass("dgwt-wcas-hide"),t.suggestionWrapp.removeClass("dgwt-wcas-preview-nores")})},onChangeHandler:function(){for(var t=this,e=["show_submit_button","max_form_width","show_product_image","show_product_sku","show_product_desc","show_product_price","show_matching_categories","show_matching_tags","show_matching_brands","show_matching_posts","show_matching_pages","show_grouped_results","suggestions_limit","show_details_box"],a=0;a<e.length;a++){var i="input[id*='"+e[a]+"']",o=s(i),n="onChange"+t.camelCase(e[a]);"function"==typeof t[n]&&t[n](o,o.val()),s(document).on("change",i,function(){n=s(this).attr("id").replace("]","").replace("dgwt_wcas_settings[",""),n="onChange"+t.camelCase(n),t[n](s(this),this.value)})}},onColorHandler:function(){for(var t=this,e=["search_icon_color","bg_input_color","text_input_color","border_input_color","bg_submit_color","text_submit_color","sug_bg_color","sug_hover_color","sug_text_color","sug_highlight_color","sug_border_color"],a=0;a<e.length;a++){var i="input[id*='"+e[a]+"']",o=s(i),n="onColor"+t.camelCase(e[a]);t[n](o,o.val()),s(document).on("change",i,function(e){n=s(this).attr("id").replace("]","").replace("dgwt_wcas_settings[",""),n="onColor"+t.camelCase(n),t[n](s(this),this.value)})}},onColorChangeHandler:function(s,t){var e=s.attr("id").replace("]","").replace("dgwt_wcas_settings[","");this[e="onColor"+this.camelCase(e)](s,t)},onTypeHandler:function(){for(var t=this,e=["search_submit_text","search_placeholder","search_no_results_text","search_see_all_results_text"],a=0;a<e.length;a++){var i="input[id*='"+e[a]+"']",o=s(i),n="onType"+t.camelCase(e[a]);t[n](o,o.val()),s(document).on("input",i,function(e){n=s(e.target).attr("id").replace("]","").replace("dgwt_wcas_settings[",""),n="onType"+t.camelCase(n),t[n](s(e.target),this.value)})}},onChangeMaxFormWidth:function(t,e){e.length>0&&"0"!=e?(this.searchWrapp.css("max-width",e+"px"),this.suggestionWrapp.css("max-width",e+"px")):(this.searchWrapp.css("max-width","100%"),this.suggestionWrapp.css("max-width","100%")),this.onChangeShowDetailsBox(s("input[id*='show_details_box']"))},onChangeShowSubmitButton:function(t,e){var a=s(".js-dgwt-wcas-search-submit");if(this.isChecked(t)){this.searchWrapp.addClass("dgwt-wcas-has-submit"),this.searchWrapp.removeClass("dgwt-wcas-no-submit"),a.show(),s(".dgwt-wcas-sf-wrapp > .dgwt-wcas-ico-magnifier").hide();var i=s("input[id*='bg_submit_color']"),o=s("input[id*='text_submit_color']");this.onColorBgSubmitColor(i,i.val()),this.onColorTextSubmitColor(o,o.val())}else this.searchWrapp.addClass("dgwt-wcas-no-submit"),this.searchWrapp.removeClass("dgwt-wcas-has-submit"),a.hide(),s(".dgwt-wcas-sf-wrapp > .dgwt-wcas-ico-magnifier").show()},onChangeShowProductImage:function(t,e){var a=s(".js-dgwt-wcas-si"),i=s(".js-dgwt-wcas-content-wrapp");this.isChecked(t)?(this.suggestionWrapp.addClass("dgwt-wcas-has-img"),s(".dgwt-wcas-suggestion-product > .dgwt-wcas-st").remove(),s(".dgwt-wcas-suggestion-product > .dgwt-wcas-sp").remove(),i.show(),a.show()):(this.suggestionWrapp.removeClass("dgwt-wcas-has-img"),i.each(function(){s(this).closest(".dgwt-wcas-suggestion-product").append(s(this).html())}),i.hide(),a.hide())},onChangeShowProductSku:function(t,e){var a=s(".js-dgwt-wcas-sku");this.isChecked(t)?(this.suggestionWrapp.addClass("dgwt-wcas-has-sku"),a.show()):(this.suggestionWrapp.removeClass("dgwt-wcas-has-sku"),a.hide())},onChangeShowProductDesc:function(t,e){var a=s(".js-dgwt-wcas-sd");this.isChecked(t)?(this.suggestionWrapp.addClass("dgwt-wcas-has-desc"),a.show()):(this.suggestionWrapp.removeClass("dgwt-wcas-has-desc"),a.hide())},onChangeShowProductPrice:function(t,e){var a=s(".js-dgwt-wcas-sp");this.isChecked(t)?(this.suggestionWrapp.addClass("dgwt-wcas-has-price"),a.show()):(this.suggestionWrapp.removeClass("dgwt-wcas-has-price"),a.hide())},onChangeShowMatchingCategories:function(t,e){var a=s(".dgwt-wcas-suggestion-headline-cat"),i=s(".dgwt-wcas-suggestion-cat");this.isChecked(t)?(a.show(),i.show(),i.removeClass("js-dgwt-wcas-suggestion-hidden"),this.onChangeShowGroupedResults(s("input[id*='show_grouped_results']"))):(a.hide(),i.hide(),i.addClass("js-dgwt-wcas-suggestion-hidden"));var o=s("input[id*='suggestions_limit']");this.onChangeSuggestionsLimit(o,o.val())},onChangeShowMatchingTags:function(t,e){var a=s(".dgwt-wcas-suggestion-headline-tag"),i=s(".dgwt-wcas-suggestion-tag");this.isChecked(t)?(a.show(),i.show(),i.removeClass("js-dgwt-wcas-suggestion-hidden"),this.onChangeShowGroupedResults(s("input[id*='show_grouped_results']"))):(a.hide(),i.hide(),i.addClass("js-dgwt-wcas-suggestion-hidden"));var o=s("input[id*='suggestions_limit']");this.onChangeSuggestionsLimit(o,o.val())},onChangeShowMatchingBrands:function(t,e){var a=s(".dgwt-wcas-suggestion-headline-brand"),i=s(".dgwt-wcas-suggestion-brand");this.isChecked(t)?(a.show(),i.show(),i.removeClass("js-dgwt-wcas-suggestion-hidden"),this.onChangeShowGroupedResults(s("input[id*='show_grouped_results']"))):(a.hide(),i.hide(),i.addClass("js-dgwt-wcas-suggestion-hidden"));var o=s("input[id*='suggestions_limit']");this.onChangeSuggestionsLimit(o,o.val())},onChangeShowMatchingPosts:function(t,e){var a=s(".dgwt-wcas-suggestion-headline-post"),i=s(".dgwt-wcas-suggestion-post");this.isChecked(t)?(a.show(),i.show(),i.removeClass("js-dgwt-wcas-suggestion-hidden"),this.onChangeShowGroupedResults(s("input[id*='show_grouped_results']"))):(a.hide(),i.hide(),i.addClass("js-dgwt-wcas-suggestion-hidden"));var o=s("input[id*='suggestions_limit']");this.onChangeSuggestionsLimit(o,o.val())},onChangeShowMatchingPages:function(t,e){var a=s(".dgwt-wcas-suggestion-headline-page"),i=s(".dgwt-wcas-suggestion-page");this.isChecked(t)?(a.show(),i.show(),i.removeClass("js-dgwt-wcas-suggestion-hidden"),this.onChangeShowGroupedResults(s("input[id*='show_grouped_results']"))):(a.hide(),i.hide(),i.addClass("js-dgwt-wcas-suggestion-hidden"));var o=s("input[id*='suggestions_limit']");this.onChangeSuggestionsLimit(o,o.val())},onChangeShowGroupedResults:function(t,e){var a=s(".dgwt-wcas-st--direct-headline"),i=s(".dgwt-wcas-suggestion-headline");this.isChecked(t)?(a.addClass("dgwt-wcas-hidden"),this.suggestionWrapp.addClass("dgwt-wcas-has-headings"),s(".dgwt-wcas-suggestion-headline").show(),this.isChecked(s("input[id*='show_matching_categories']"))||s(".dgwt-wcas-suggestion-headline-cat").hide(),this.isChecked(s("input[id*='show_matching_tags']"))||s(".dgwt-wcas-suggestion-headline-tag").hide(),this.isChecked(s("input[id*='show_matching_brands']"))||s(".dgwt-wcas-suggestion-headline-brand").hide(),this.isChecked(s("input[id*='show_matching_posts']"))||s(".dgwt-wcas-suggestion-headline-post").hide(),this.isChecked(s("input[id*='show_matching_pages']"))||s(".dgwt-wcas-suggestion-headline-page").hide()):(a.removeClass("dgwt-wcas-hidden"),i.hide(),this.suggestionWrapp.removeClass("dgwt-wcas-has-headings"))},onChangeSuggestionsLimit:function(t,e){setTimeout(function(){var a=0,i=7,o=s(".dgwt-wcas-suggestion-duplicated"),n=["brand","cat","tag","post","page","product"];e.length>0&&"0"!=e&&(i=Math.abs(e)),o.length>0&&o.remove();var c=[];for(a=0;a<n.length;a++){var r=s(".dgwt-wcas-suggestion-"+n[a]+":not(.js-dgwt-wcas-suggestion-hidden)");r.length>0&&c.push(r)}var d=c.length;if(c.length>0)for(var g=i-c.length,l=c.length-1;g>0;){var h=c[l].clone();h.addClass("dgwt-wcas-suggestion-duplicated"),h.removeClass("dgwt-wcas-suggestion-selected"),c[l].after(h),d++,--l<0&&(l=c.length-1),g--}d>i&&t.val(d)},10)},onChangeShowDetailsBox:function(t,e){var a=this;a.isChecked(t)?(a.detailsWrapp.show(),a.searchWrapp.addClass("dgwt-wcas-is-detail-box"),a.previewWrapper.addClass("dgwt-wcas-is-details"),a.previewWrapper.addClass("dgwt-wcas-details-right"),setTimeout(function(){if(s(".dgwt-wcas-suggestion-product:not(.dgwt-wcas-suggestion-duplicated)").addClass("dgwt-wcas-suggestion-selected"),a.searchWrapp.width()>=550){a.previewWrapper.addClass("dgwt-wcas-full-width");var t=getComputedStyle(a.searchWrapp[0]).width;(t=Math.round(parseFloat(t.replace("px",""))))%2==0?(a.suggestionWrapp.css("width",Math.round(t/2)),a.detailsWrapp.css("width",Math.round(t/2))):(a.suggestionWrapp.css("width",Math.floor(t/2)),a.detailsWrapp.css("width",Math.ceil(t/2)))}else a.suggestionWrapp.width(a.searchWrapp.width())},10)):(a.detailsWrapp.hide(),a.searchWrapp.removeClass("dgwt-wcas-is-detail-box"),a.previewWrapper.removeClass("dgwt-wcas-is-details"),a.previewWrapper.removeClass("dgwt-wcas-details-right"),a.previewWrapper.removeClass("dgwt-wcas-full-width"),s(".dgwt-wcas-suggestion-product").removeClass("dgwt-wcas-suggestion-selected"),a.suggestionWrapp.css("width",""),a.detailsWrapp.css("width",""))},onColorSearchIconColor:function(s,t){},onColorBgInputColor:function(s,t){this.isColor(t)?this.searchInput.css("background-color",t):this.searchInput.css("background-color","")},onColorTextInputColor:function(t,e){var a="dgwt-wcas-preview-placeholder-style";if(this.isColor(e)){var i='<style class="'+a+'">';i+=".dgwt-wcas-search-input::placeholder{opacity: 0.3; color:"+e+"!important;}",i+=".dgwt-wcas-search-input::-webkit-input-placeholder{opacity: 0.3; color:"+e+"!important;}",i+=".dgwt-wcas-search-input:-moz-placeholder{opacity: 0.3; color:"+e+"!important;}",i+=".dgwt-wcas-search-input::-moz-placeholder{opacity: 0.3; color:"+e+"!important;}",i+=".dgwt-wcas-search-input:-ms-input-placeholder{opacity: 0.3; color:"+e+"!important;}",i+=".dgwt-wcas-ico-magnifier path {fill:"+e+"}",i+="</style>",s("head").append(i),this.searchInput.css("color",e)}else{this.searchInput.css("color","");var o=s("."+a);o.length>0&&o.remove()}},onColorBorderInputColor:function(s,t){this.isColor(t)?this.searchInput.css("border-color",t):this.searchInput.css("border-color","")},onColorBgSubmitColor:function(t,e){if(this.isChecked(s("input[id*='show_submit_button']"))&&this.isColor(e)){var a='<style class="dgwt-wcas-preview-submit-style">';a+=".dgwt-wcas-search-submit::before{border-color: transparent "+e+"!important;}",a+=".dgwt-wcas-search-submit:hover::before{border-right-color: "+e+"!important;}",a+=".dgwt-wcas-search-submit:focus::before{border-right-color: "+e+"!important;}",a+=".dgwt-wcas-search-submit{background-color: "+e+"!important;}",a+=".dgwt-wcas-om-bar .dgwt-wcas-om-return{background-color: "+e+"!important;}",a+="</style>",s("head").append(a)}else{var i=s(".dgwt-wcas-preview-submit-style");i.length>0&&i.remove()}},onColorTextSubmitColor:function(t,e){this.isChecked(s("input[id*='show_submit_button']"))&&this.isColor(e)?(s(".js-dgwt-wcas-search-submit").css("color",e),s(".dgwt-wcas-search-submit .dgwt-wcas-ico-magnifier path").css("fill",e)):(this.searchInput.css("background-color",""),s(".js-dgwt-wcas-search-submit").css("color",""),s(".dgwt-wcas-search-submit .dgwt-wcas-ico-magnifier path").css("fill",""))},onColorSugBgColor:function(t,e){var a="dgwt-wcas-preview-sugbgcol-style";if(this.isColor(e)){var i='<style class="'+a+'">';i+=".dgwt-wcas-suggestions-wrapp,",i+=".dgwt-wcas-details-wrapp",i+="{background-color: "+e+"!important;}",i+="</style>",s("head").append(i)}else{var o=s("."+a);o.length>0&&o.remove()}},onColorSugHoverColor:function(t,e){this.isColor(e)?setTimeout(function(){s(".dgwt-wcas-suggestion-selected").css("background-color",e)},50):s(".dgwt-wcas-suggestion-selected").css("background-color","")},onColorSugTextColor:function(t,e){var a="dgwt-wcas-preview-sugtextcol-style";if(this.isColor(e)){var i='<style class="'+a+'">';i+=".dgwt-wcas-suggestions-wrapp *,",i+=".dgwt-wcas-details-wrapp *,",i+=".dgwt-wcas-sd,",i+=".dgwt-wcas-suggestion *",i+="{color: "+e+"!important;}",i+="</style>",s("head").append(i)}else{var o=s("."+a);o.length>0&&o.remove()}},onColorSugHighlightColor:function(t,e){var a="dgwt-wcas-preview-sughighlight-style";if(this.isColor(e)){var i='<style class="'+a+'">';i+=".dgwt-wcas-st strong,",i+=".dgwt-wcas-sd strong",i+="{color: "+e+"!important;}",i+="</style>",s("head").append(i)}else{var o=s("."+a);o.length>0&&o.remove()}},onColorSugBorderColor:function(t,e){var a="dgwt-wcas-preview-sugborder-style";if(this.isColor(e)){var i='<style class="'+a+'">';i+=".dgwt-wcas-suggestions-wrapp,",i+=".dgwt-wcas-details-wrapp,",i+=".dgwt-wcas-suggestion,",i+=".dgwt-wcas-datails-title,",i+=".dgwt-wcas-details-more-products",i+="{border-color: "+e+"!important;}",i+="</style>",s("head").append(i)}else{var o=s("."+a);o.length>0&&o.remove()}},onTypeSearchSubmitText:function(t,e){var a=s(".js-dgwt-wcas-search-submit-l"),i=s(".js-dgwt-wcas-search-submit-m");e.length>0?(a.text(e),a.show(),i.hide()):(a.text(""),a.hide(),i.show())},onTypeSearchPlaceholder:function(s,t){0==t.length&&(t=dgwt_wcas.labels.search_placeholder),this.searchInput.attr("placeholder",t)},onTypeSearchNoResultsText:function(t,e){0==e.length&&(e=dgwt_wcas.labels.no_results),s(".js-dgwt-wcas-suggestion-nores span").text(e)},onTypeSearchSeeAllResultsText:function(t,e){0==e.length&&(e=dgwt_wcas.labels.show_more),s(".js-dgwt-wcas-st-more-label").text(e)},fixSizesInit:function(){var t=this;s(document).on("click","#dgwt_wcas_autocomplete-tab",function(){t.onChangeShowDetailsBox(s("input[id*='show_details_box']"))})}};var r={settingsTab:"#dgwt_wcas_troubleshooting-tab",noIssuesClass:".js-dgwt-wcas-troubleshooting-no-issues",counterClass:".js-dgwt-wcas-troubleshooting-count",issuesListClass:".js-dgwt-wcas-troubleshooting-issues",progressBar:".dgwt-wcas-troubleshooting-wrapper .progress_bar",progressBarInner:".dgwt-wcas-troubleshooting-wrapper .progress-bar-inner",resetButtonName:"dgwt-wcas-reset-async-tests",init:function(){var t=this;if(void 0===dgwt_wcas.troubleshooting)return;const e=dgwt_wcas.troubleshooting.tests.issues.critical+dgwt_wcas.troubleshooting.tests.issues.recommended;e>0&&(s(t.counterClass).text(e),s(t.settingsTab).addClass("enabled")),dgwt_wcas.troubleshooting.tests.results_async.length>0&&s.each(dgwt_wcas.troubleshooting.tests.results_async,function(){t.appendIssue(this,!1)}),dgwt_wcas.troubleshooting.tests.direct.length>0&&s.each(dgwt_wcas.troubleshooting.tests.direct,function(){t.appendIssue(this,!1)}),dgwt_wcas.troubleshooting.tests.async.length>0&&t.maybeRunNextAsyncTest(),s(document).on("click",'input[name="'+t.resetButtonName+'"]',function(e){s('input[name="'+t.resetButtonName+'"]').attr("disabled","disabled");var a={action:"dgwt_wcas_troubleshooting_reset_async_tests",_wpnonce:dgwt_wcas.troubleshooting.nonce.troubleshooting_reset_async_tests};return s.post(ajaxurl,a,function(){location.reload()}),!1})},appendIssue:function(t,e){var a,i=wp.template("dgwt-wcas-troubleshooting-issue"),o=s(this.issuesListClass+"-"+t.status);"good"!==t.status&&(s(this.noIssuesClass).hide(),e&&dgwt_wcas.troubleshooting.tests.issues[t.status]++,(a=dgwt_wcas.troubleshooting.tests.issues.critical+dgwt_wcas.troubleshooting.tests.issues.recommended)>0&&(s(this.counterClass).text(a),s(this.settingsTab).addClass("enabled")),s(o).append(i(t)))},maybeRunNextAsyncTest:function(){var t=this;dgwt_wcas.troubleshooting.tests.async.length>0&&s.each(dgwt_wcas.troubleshooting.tests.async,function(){var e={action:"dgwt_wcas_troubleshooting_test",test:this.test,_wpnonce:dgwt_wcas.troubleshooting.nonce.troubleshooting_async_test};return!!this.completed||(this.completed=!0,s(t.progressBar).show(),s.post(ajaxurl,e,function(s){s.success&&t.appendIssue(s.data,!0),t.maybeRunNextAsyncTest()}),!1)}),t.recalculateProgression()},recalculateProgression:function(){var t=this,e=dgwt_wcas.troubleshooting.tests.async.length,a=0;s.each(dgwt_wcas.troubleshooting.tests.async,function(){this.completed&&a++});var i=Math.ceil(a/e*100);s(t.progressBarInner).css("width",i+"%"),100===i&&setTimeout(function(){s(t.progressBar).slideUp()},2e3)}};s(document).ready(function(){var d,g;(d=s(".js-dgwt-wcas-settings-margin-nob")).length>0&&d.each(function(){var t=s(this).find("td .dgwt-wcas-fieldset");if(t.length>0){var e=s(this).prev(".js-dgwt-wcas-settings-margin");if(e.length>0){var a=s(this).attr("class").split(/\s+/),i="";s.each(a,function(s,t){-1!==t.indexOf("js-dgwt-wcas-cbtgroup-")&&(i=t)});var o=t.clone(!0,!0);o.addClass("dgwt-wcas-settings-margin-nob"),i&&o.addClass(i),o.appendTo(e.find("td")),s(this).remove()}}}),t.init(),e.init(),a.init(),(g=s(".js-dgwt-wcas-sgs-autocolspan")).length>0&&g.find("td").attr("colspan",2),i.init(),o.init(),n.init(),c.init(),r.init(),window.DGWT_WCAS_SEARCH_PREVIEW.init()})}(jQuery);
|
assets/js/search.js
CHANGED
@@ -315,7 +315,12 @@
|
|
315 |
}
|
316 |
};
|
317 |
|
318 |
-
$(window).on('resize.autocomplete',
|
|
|
|
|
|
|
|
|
|
|
319 |
|
320 |
that.initMobileMode();
|
321 |
|
@@ -1862,11 +1867,12 @@
|
|
1862 |
is_img = true;
|
1863 |
}
|
1864 |
|
|
|
1865 |
// One suggestion HTML
|
1866 |
dataAttrs += typeof suggestion.post_id != 'undefined' ? 'data-post-id="' + suggestion.post_id + '" ' : '';
|
1867 |
dataAttrs += typeof suggestion.taxonomy != 'undefined' ? 'data-taxonomy="' + suggestion.taxonomy + '" ' : '';
|
1868 |
dataAttrs += typeof suggestion.term_id != 'undefined' ? 'data-term-id="' + suggestion.term_id + '" ' : '';
|
1869 |
-
html += '<div class="' + className + ' dgwt-wcas-suggestion-product" data-index="' + i + '" ' + dataAttrs + '>';
|
1870 |
|
1871 |
// Image
|
1872 |
if (is_img) {
|
@@ -2346,7 +2352,7 @@
|
|
2346 |
|
2347 |
that.overlayMobileState = 'on';
|
2348 |
|
2349 |
-
var zIndex =
|
2350 |
$wrapper = that.getFormWrapper(),
|
2351 |
$suggestionsWrapp = that.getSuggestionsContainer(),
|
2352 |
$overlayWrap,
|
@@ -2531,13 +2537,33 @@
|
|
2531 |
|
2532 |
(function () {
|
2533 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2534 |
// RUN
|
2535 |
$(document).ready(function () {
|
2536 |
"use strict";
|
2537 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2538 |
/*-----------------------------------------------------------------
|
2539 |
-
|
2540 |
-
|
2541 |
var showDetailsPanel = dgwt_wcas.show_details_box == 1 ? true : false;
|
2542 |
var mobileBreakpoint = dgwt_wcas.mobile_breakpoint;
|
2543 |
|
315 |
}
|
316 |
};
|
317 |
|
318 |
+
$(window).on('resize.autocomplete', function(){
|
319 |
+
var that = utils.getActiveInstance();
|
320 |
+
if(typeof that != 'undefined') {
|
321 |
+
that.fixPositionCapture();
|
322 |
+
}
|
323 |
+
});
|
324 |
|
325 |
that.initMobileMode();
|
326 |
|
1867 |
is_img = true;
|
1868 |
}
|
1869 |
|
1870 |
+
var sugVarClass = suggestion.type === 'product_variation' ? ' dgwt-wcas-suggestion-product-var' : '';
|
1871 |
// One suggestion HTML
|
1872 |
dataAttrs += typeof suggestion.post_id != 'undefined' ? 'data-post-id="' + suggestion.post_id + '" ' : '';
|
1873 |
dataAttrs += typeof suggestion.taxonomy != 'undefined' ? 'data-taxonomy="' + suggestion.taxonomy + '" ' : '';
|
1874 |
dataAttrs += typeof suggestion.term_id != 'undefined' ? 'data-term-id="' + suggestion.term_id + '" ' : '';
|
1875 |
+
html += '<div class="' + className + ' dgwt-wcas-suggestion-product' + sugVarClass + '" data-index="' + i + '" ' + dataAttrs + '>';
|
1876 |
|
1877 |
// Image
|
1878 |
if (is_img) {
|
2352 |
|
2353 |
that.overlayMobileState = 'on';
|
2354 |
|
2355 |
+
var zIndex = 99999999999,
|
2356 |
$wrapper = that.getFormWrapper(),
|
2357 |
$suggestionsWrapp = that.getSuggestionsContainer(),
|
2358 |
$overlayWrap,
|
2537 |
|
2538 |
(function () {
|
2539 |
|
2540 |
+
function isIOS() {
|
2541 |
+
return [
|
2542 |
+
'iPad Simulator',
|
2543 |
+
'iPhone Simulator',
|
2544 |
+
'iPod Simulator',
|
2545 |
+
'iPad',
|
2546 |
+
'iPhone',
|
2547 |
+
'iPod'
|
2548 |
+
].includes(navigator.platform)
|
2549 |
+
// iPad on iOS 13 detection
|
2550 |
+
|| (navigator.userAgent.includes("Mac") && "ontouchend" in document)
|
2551 |
+
}
|
2552 |
+
|
2553 |
// RUN
|
2554 |
$(document).ready(function () {
|
2555 |
"use strict";
|
2556 |
|
2557 |
+
/*-----------------------------------------------------------------
|
2558 |
+
/* Mobile detection
|
2559 |
+
/*-----------------------------------------------------------------*/
|
2560 |
+
if(isIOS()){
|
2561 |
+
$('html').addClass('dgwt-wcas-is-ios');
|
2562 |
+
}
|
2563 |
+
|
2564 |
/*-----------------------------------------------------------------
|
2565 |
+
/* Fire autocomplete
|
2566 |
+
/*-----------------------------------------------------------------*/
|
2567 |
var showDetailsPanel = dgwt_wcas.show_details_box == 1 ? true : false;
|
2568 |
var mobileBreakpoint = dgwt_wcas.mobile_breakpoint;
|
2569 |
|
assets/js/search.min.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
!function(t){"use strict";"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof exports&&"function"==typeof require?t(require("jquery")):t(jQuery)}(function(t){"use strict";var e={escapeRegExChars:function(t){return t.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&")},createNode:function(t){var e=document.createElement("div");return e.className=t,e.style.position="absolute",e.style.display="none",e.setAttribute("unselectable","on"),e},highlight:function(t,s){if(dgwt_wcas.is_premium){var i,o=s.split(/ /),a=!1;if(o)for(o=o.sort(function(t,e){return e.length-t.length}),i=0;i<o.length;i++)if(o[i]&&o[i].length>1){var n=o[i].replace(/[\^\@]/g,"");if(n.length>0){var r="("+e.escapeRegExChars(n.trim())+")";t=t.replace(new RegExp(r,"gi"),"^^$1@@"),a=!0}}a&&(t=(t=t.replace(/\^\^/g,"<strong>")).replace(/@@/g,"</strong>"))}else r="("+e.escapeRegExChars(s)+")",t=t.replace(new RegExp(r,"gi"),"<strong>$1</strong>");return t},debounce:function(t,e){var i,o=(new Date).getUTCMilliseconds();if(0===s.id.length)return s.id=o,void t();s.id=o,i=setTimeout(function(){o===s.id?(t(),s.id=""):clearTimeout(i)},e)},mouseHoverDebounce:function(e,s,i){var o;o=setTimeout(function(){t(s+":hover").length>0?e():clearTimeout(o)},i)},getActiveInstance:function(){var e,s=t(".dgwt-wcas-search-wrapp.dgwt-wcas-active");return s.length>0&&s.each(function(){var s=t(this).find(".dgwt-wcas-search-input");if("object"==typeof s.data("autocomplete"))return e=s.data("autocomplete"),!1}),e}},s={id:"",callback:null,ajaxSettings:null,object:null},i=27,o=9,a=13,n=38,r=39,l=40,c=t.noop;function d(e,s){this.element=e,this.el=t(e),this.suggestions=[],this.badQueries=[],this.selectedIndex=-1,this.currentValue=this.element.value,this.timeoutId=null,this.cachedResponse={},this.cachedDetails={},this.cachedPrices={},this.detailsRequestsSent=[],this.onChangeTimeout=null,this.onChange=null,this.isLocal=!1,this.suggestionsContainer=null,this.detailsContainer=null,this.autoAligmentprocess=null,this.noSuggestionsContainer=null,this.latestActivateSource="",this.actionTriggerSource="",this.options=t.extend(!0,{},d.defaults,s),this.classes={selected:"dgwt-wcas-suggestion-selected",suggestion:"dgwt-wcas-suggestion",suggestionsContainerOrientTop:"dgwt-wcas-suggestions-wrapp--top"},this.hint=null,this.hintValue="",this.selection=null,this.overlayMobileState="off",this.initialize(),this.setOptions(s)}d.utils=e,t.DgwtWcasAutocompleteSearch=d,d.defaults={ajaxSettings:{},autoSelectFirst:!1,appendTo:"body",serviceUrl:null,lookup:null,onSelect:null,width:"auto",containerDetailsWidth:"auto",showDetailsPanel:!1,showImage:!1,showPrice:!1,showSKU:!1,showDescription:!1,showSaleBadge:!1,showFeaturedBadge:!1,dynamicPrices:!1,saleBadgeText:"sale",featuredBadgeText:"featured",minChars:3,maxHeight:600,deferRequestBy:0,params:{},formatResult:function(t,s,i,o){if(!s)return t;i&&(t=e.highlight(t,s));if(!o.convertHtml)return t;return t.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/<sup/g,"<sup").replace(/<\/sup/g,"</sup").replace(/sup>/g,"sup>").replace(/<(\/?(strong|b|br))>/g,"<$1>")},delimiter:null,zIndex:999999999,type:"GET",noCache:!1,isRtl:!1,onSearchStart:c,onSearchComplete:c,onSearchError:c,preserveInput:!1,searchFormClass:"dgwt-wcas-search-wrapp",containerClass:"dgwt-wcas-suggestions-wrapp",containerDetailsClass:"dgwt-wcas-details-wrapp",searchInputClass:"dgwt-wcas-search-input",preloaderClass:"dgwt-wcas-preloader",closeTrigger:"dgwt-wcas-close",formClass:"dgwt-wcas-search-form",tabDisabled:!1,dataType:"text",currentRequest:null,triggerSelectOnValidInput:!0,isPremium:!1,overlayMobile:!1,preventBadQueries:!0,lookupFilter:function(t,e,s){return-1!==t.value.toLowerCase().indexOf(s)},paramName:"query",transformResult:function(e){return"string"==typeof e?t.parseJSON(e):e},noSuggestionNotice:"No results",orientation:"bottom",forceFixPosition:!1,positionFixed:!1,debounceWaitMs:400,sendGAEvents:!0,enableGASiteSearchModule:!1},d.prototype={initialize:function(){var e=this;e.element.setAttribute("autocomplete","off"),e.createContainers(),e.registerEventsSearchBar(),e.registerEventsSuggestions(),e.registerEventsDetailsPanel(),e.registerIconHandler(),e.registerEventsFixedMenu(),e.fixPositionCapture=function(){e.adjustContainerWidth(),e.visible&&e.fixPosition()},t(window).on("resize.autocomplete",e.fixPositionCapture),e.initMobileMode(),e.hideAfterClickOutsideListener(),e.suggestionsContainer.addClass("js-dgwt-wcas-initialized"),e.detailsContainer&&e.detailsContainer.length>0&&e.detailsContainer.addClass("js-dgwt-wcas-initialized")},createContainers:function(e){var s=this.options;0==t("."+s.containerClass).length?(this.suggestionsContainer=t(d.utils.createNode(s.containerClass)),this.suggestionsContainer.appendTo(s.appendTo||"body"),this.suggestionsContainer.addClass("woocommerce"),!0===s.showImage&&this.suggestionsContainer.addClass("dgwt-wcas-has-img"),!0===s.showPrice&&this.suggestionsContainer.addClass("dgwt-wcas-has-price"),!0===s.showDescription&&this.suggestionsContainer.addClass("dgwt-wcas-has-desc"),!0===s.showSKU&&this.suggestionsContainer.addClass("dgwt-wcas-has-sku"),!0===s.showHeadings&&this.suggestionsContainer.addClass("dgwt-wcas-has-headings"),"auto"!==s.width&&this.suggestionsContainer.width(s.width)):this.suggestionsContainer=t("."+this.options.containerClass),this.canShowDetailsBox()&&(0==t("."+s.containerDetailsClass).length?(this.detailsContainer=t(d.utils.createNode(s.containerDetailsClass)),this.detailsContainer.appendTo(s.appendTo||"body"),this.detailsContainer.addClass("woocommerce")):this.detailsContainer=t("."+s.containerDetailsClass))},registerEventsSearchBar:function(){var s=this;t(document).on("click.autocomplete","."+s.options.closeTrigger,function(){var s=e.getActiveInstance();s.hide(),s.clear(!1),s.hideCloseButton(),t(this).closest("."+s.options.searchFormClass).find("."+s.options.searchInputClass).val("").focus()}),s.el.closest("."+s.options.formClass).on("submit.autocomplete",function(e){s.suggestions.length>0&&t.each(s.suggestions,function(t,i){if(void 0!==i.type&&"product_variation"==i.type)return s.select(t),e.preventDefault(),!1})}),t(window).on("load",function(){s.positionPreloader()}),s.el.on("keydown.autocomplete",function(t){s.onKeyPress(t)}),s.el.on("keyup.autocomplete",function(t){s.onKeyUp(t)}),s.el.on("blur.autocomplete",function(){s.onBlur()}),s.el.on("focus.autocomplete",function(){s.onFocus()}),s.el.on("change.autocomplete",function(t){s.onKeyUp(t)}),s.el.on("input.autocomplete",function(t){s.onKeyUp(t)})},registerEventsSuggestions:function(){var s="."+this.classes.suggestion;if(!this.getSuggestionsContainer().hasClass("js-dgwt-wcas-initialized")){t(document).on("mouseenter.autocomplete",s,function(){var s=e.getActiveInstance();if(void 0!==s){var i=t(this).data("index"),o='.dgwt-wcas-suggestion[data-index="'+i+'"]',a=s.canShowDetailsBox()?100:1;s.selectedIndex!=i&&e.mouseHoverDebounce(function(){s.selectedIndex!==i&&(s.latestActivateSource="mouse",s.getDetails(s.suggestions[i]),s.activate(i))},o,a)}});var i=!1;t(document).on("click.autocomplete",s,function(){if(!i){var s=e.getActiveInstance();s.actionTriggerSource="click",i=!0,s.select(t(this).data("index"))}}),t(document).on("mousedown.autocomplete",s,function(e){"number"==typeof e.which&&1===e.which&&t(e.target)[0].click()}),t(document).on("click.autocomplete","."+this.options.containerClass,function(){var t=e.getActiveInstance();clearTimeout(t.blurTimeoutId)})}},registerEventsDetailsPanel:function(){var s=this.getDetailsContainer();this.canShowDetailsBox()&&!s.hasClass("js-dgwt-wcas-initialized")&&(t(document).on("click.autocomplete","."+this.options.containerDetailsClass,function(){var t=e.getActiveInstance();clearTimeout(t.blurTimeoutId)}),t(document).on("change",'[name="js-dgwt-wcas-quantity"]',function(e){t(this).closest(".js-dgwt-wcas-pd-addtc").find("[data-quantity]").attr("data-quantity",t(this).val())}))},registerIconHandler:function(){var s=this,i=s.getFormWrapper(),o=i.find("."+s.options.formClass);i.on("click",".js-dgwt-wcas-search-icon-handler",function(t){var e=i.find("."+s.options.searchInputClass);if(i.hasClass("dgwt-wcas-layout-icon-open"))s.hide(),o.hide(!0),i.removeClass("dgwt-wcas-layout-icon-open");else{var a=i.find(".dgwt-wcas-search-icon-arrow");o.hide(),a.hide(),i.addClass("dgwt-wcas-layout-icon-open"),s.positionIconSearchMode(i),o.fadeIn(200,function(){a.show(),s.positionPreloader(i),e.focus()})}}),0==t(".js-dgwt-wcas-initialized").length&&t(".js-dgwt-wcas-search-icon-handler").length>0&&t(document).click(function(i){if(t(".dgwt-wcas-layout-icon-open").length){var o=t(i.target);if(!(o.closest("."+s.options.searchFormClass).length>0||o.closest("."+s.options.containerClass).length>0||o.closest("."+s.options.containerDetailsClass).length>0)){var a=e.getActiveInstance();if(void 0!==a){var n=a.getFormWrapper().find("."+s.options.formClass);n.hide(),a.hide(!0),n.css({left:"0"})}s.hideIconModeSearch()}}}),t(window).on("resize.autocomplete",function(){s.applyFlexibleMode()}),t(window).on("load",function(){s.applyFlexibleMode()})},registerEventsFixedMenu:function(){var e=this;t(window).on("scroll",function(){if(e.suggestions.length>0&&e.elementOrParentIsFixed(e.getFormWrapper()))if(0===t(window).scrollTop()){[1,10,20,30,40,50,60,70,80,90,120,140,170,200,250,400,700,1e3,2e3].forEach(function(t){setTimeout(function(){e.fixHeight(),e.fixPositionCapture()},t)})}else e.fixHeight(),e.fixPositionCapture()})},initMobileMode:function(){var t=this,e=t.getFormWrapper();e.hasClass("js-dgwt-wcas-mobile-overlay-enabled")&&t.isMobileMode()&&(e.prepend('<div class="js-dgwt-wcas-enable-mobile-form dgwt-wcas-enable-mobile-form"></div>'),e.find(".js-dgwt-wcas-enable-mobile-form").on("click",function(e){t.enableOverlayMobile()}))},applyFlexibleMode:function(){var e=t(".js-dgwt-wcas-layout-icon-flexible");e.length&&(this.isMobileMode()?(e.addClass("js-dgwt-wcas-layout-icon"),e.addClass("dgwt-wcas-layout-icon")):(e.removeClass("js-dgwt-wcas-layout-icon"),e.removeClass("dgwt-wcas-layout-icon")),e.addClass("dgwt-wcas-layout-icon-flexible-loaded"))},onFocus:function(){t("."+this.options.searchFormClass).removeClass("dgwt-wcas-active"),this.getFormWrapper().addClass("dgwt-wcas-active"),this.fixPositionCapture(),this.el.val().length>=this.options.minChars&&this.onValueChange()},onBlur:function(){var e=this,s=e.options,i=e.el.val(),o=e.getQuery(i);e.isMobileMode()||(e.blurTimeoutId=setTimeout(function(){e.hide(),e.selection&&e.currentValue!==o&&(s.onInvalidateSelection||t.noop).call(e.element)},200))},abortAjax:function(){this.currentRequest&&(this.currentRequest.abort(),this.currentRequest=null)},setOptions:function(e){var s=this,i=s.getSuggestionsContainer(),o=t.extend({},s.options,e);(s.isLocal=Array.isArray(o.lookup),s.isLocal&&(o.lookup=s.verifySuggestionsFormat(o.lookup)),o.orientation=s.validateOrientation(o.orientation,"bottom"),i.css({"max-height":s.canShowDetailsBox()?"none":o.maxHeight+"px",width:o.width+"px","z-index":o.zIndex}),!0===o.showDetailsPanel)&&s.getDetailsContainer().css({"z-index":o.zIndex-1});o.onSearchComplete=function(){s.getFormWrapper().removeClass("dgwt-wcas-processing"),s.preloader("hide","form","dgwt-wcas-inner-preloader"),s.showCloseButton()},this.options=o},clearCache:function(){this.cachedResponse={},this.cachedDetails={},this.cachedPrices={},this.badQueries=[]},clear:function(t){t&&this.clearCache(),this.currentValue="",this.suggestions=[]},disable:function(){this.disabled=!0,clearTimeout(this.onChangeTimeout),this.abortAjax()},enable:function(){this.disabled=!1},fixPosition:function(){var t=this.getFormOffset();this.getSuggestionsContainer().css(t),this.canShowDetailsBox()&&this.fixPositionDetailsBox()},fixPositionDetailsBox:function(){var e=this.getFormWrapper(),s=this.getSuggestionsContainer(),i=this.getDetailsContainer(),o=this.getFormOffset(),a=o.left;if(0==i.length)return!1;var n=!0===this.options.isRtl?1:2,r=Math.round(o.left);if(o.left=r+Math.round(s.width()+n),i.css(o),e.width()>=550)return t("body").removeClass("dgwt-wcas-details-outside"),t("body").removeClass("dgwt-wcas-details-right"),t("body").removeClass("dgwt-wcas-details-left"),void(!0===this.options.isRtl&&(s.css("left",r+Math.round(i.width()+n)+"px"),i.css("left",a+"px")));var l=t(window).width(),c=i.width(),d=i.offset();t("body").addClass("dgwt-wcas-details-outside"),!0===this.options.isRtl&&(o.left=o.left+1);var g=!1,u=!1;l<d.left+c&&(g=!0,t("body").removeClass("dgwt-wcas-details-right"),t("body").addClass("dgwt-wcas-details-left"),i.css("left",Math.round(parseFloat(s.css("left").replace("px","")))-i.outerWidth()+"px")),(d=i.offset()).left<1&&(u=!0,t("body").removeClass("dgwt-wcas-details-left"),t("body").addClass("dgwt-wcas-details-right")),u&&g?(t("body").removeClass("dgwt-wcas-details-left"),t("body").removeClass("dgwt-wcas-details-right"),t("body").addClass("dgwt-wcas-details-notfit")):t("body").removeClass("dgwt-wcas-details-notfit")},fixHeight:function(){if(1!=this.options.showDetailsPanel)return!1;var t=this.getSuggestionsContainer(),e=this.getDetailsContainer();t.css("height","auto"),e.css("height","auto");var s=t.outerHeight(),i=e.outerHeight();return t.find(".dgwt-wcas-suggestion:last-child").removeClass("dgwt-wcas-suggestion-no-border-bottom"),!(s<=340&&i<=340)&&(t.find(".dgwt-wcas-suggestion:last-child").addClass("dgwt-wcas-suggestion-no-border-bottom"),i<s&&e.css("height",s+"px"),s<i&&t.css("height",i+"px"),!1)},automaticAlignment:function(){var t=this,e=t.getFormWrapper().find(".dgwt-wcas-search-input"),s=t.getSuggestionsContainer(),i=t.getDetailsContainer();if(null==t.autoAligmentprocess){var o=[e.width(),s.height()];t.options.showDetailsPanel&&(o[2]=i.height()),t.autoAligmentprocess=setInterval(function(){var a=[e.width(),s.height()];t.options.showDetailsPanel&&(a[2]=i.height());for(var n=0;n<o.length;n++)if(o[n]!=a[n]){t.fixHeight(),t.fixPositionCapture(),o=a;break}t.options.showDetailsPanel&&(i.find(".dgwt-wcas-details-inner").height()-i.height()>2&&t.fixHeight())},10)}},getFormOffset:function(){var e=this.getFormWrapper(),s=this.getSuggestionsContainer(),i=this.options.orientation,o=e.outerHeight(),a=this.el.outerHeight(),n=this.el.offset(),r={top:n.top,left:n.left};if("auto"===i){var l=t(window).height(),c=t(window).scrollTop(),d=-c+n.top-o,g=c+l-(n.top+a+o);i=Math.max(d,g)===d?"top":"bottom"}if("top"===i){s[0].getBoundingClientRect().top;var u=e[0].getBoundingClientRect().top;s.css("height","auto"),u<s.height()&&s.height(u-10),r.top+=-s.outerHeight()}else r.top+=a;return r},getFormWrapper:function(){return this.el.closest("."+this.options.searchFormClass)},getSuggestionsContainer:function(){return t("."+this.options.containerClass)},getDetailsContainer:function(){return t("."+this.options.containerDetailsClass)},scrollDownSuggestions:function(){var t=this.getSuggestionsContainer();t[0].scrollTop=t[0].scrollHeight},isCursorAtEnd:function(){var t,e=this.el.val().length,s=this.element.selectionStart;return"number"==typeof s?s===e:!document.selection||((t=document.selection.createRange()).moveStart("character",-e),e===t.text.length)},onKeyPress:function(t){if(this.disabled||this.visible||t.which!==l||!this.currentValue){if(!this.disabled&&this.visible){switch(t.which){case i:this.el.val(this.currentValue),this.hide();break;case r:if(this.hint&&this.options.onHint&&this.isCursorAtEnd()){this.selectHint();break}return;case o:if(this.hint&&this.options.onHint)return void this.selectHint();if(-1===this.selectedIndex)return void this.hide();if(this.select(this.selectedIndex),!1===this.options.tabDisabled)return;break;case a:if(-1===this.selectedIndex)return void this.hide();this.actionTriggerSource="enter",this.select(this.selectedIndex);break;case n:this.moveUp();break;case l:this.moveDown();break;default:return}t.stopImmediatePropagation(),t.preventDefault()}}else this.suggest()},onKeyUp:function(t){var e=this;if(!e.disabled){switch(t.which){case n:case l:return}clearTimeout(e.onChangeTimeout),e.currentValue!==e.el.val()&&(e.findBestHint(),e.options.deferRequestBy>0?e.onChangeTimeout=setTimeout(function(){e.onValueChange()},e.options.deferRequestBy):e.onValueChange())}},onValueChange:function(){if(this.ignoreValueChange)this.ignoreValueChange=!1;else{var e=this.options,s=this.el.val(),i=this.getQuery(s);this.selection&&this.currentValue!==i&&(this.selection=null,(e.onInvalidateSelection||t.noop).call(this.element)),clearTimeout(this.onChangeTimeout),this.currentValue=s,this.selectedIndex=-1,e.triggerSelectOnValidInput&&this.isExactMatch(i)?this.select(0):i.length<e.minChars?(this.hideCloseButton(),this.hide()):this.getSuggestions(i)}},isExactMatch:function(t){var e=this.suggestions;return 1===e.length&&e[0].value.toLowerCase()===t.toLowerCase()},canShowDetailsBox:function(){return 1==this.options.showDetailsPanel&&!this.isMobileMode()},isMobileMode:function(){return t(window).width()<this.options.mobileBreakpoint},getQuery:function(e){var s,i=this.options.delimiter;return i?(s=e.split(i),t.trim(s[s.length-1])):e},getSuggestionsLocal:function(e){var s,i=this.options,o=e.toLowerCase(),a=i.lookupFilter,n=parseInt(i.lookupLimit,10);return s={suggestions:t.grep(i.lookup,function(t){return a(t,e,o)})},n&&s.suggestions.length>n&&(s.suggestions=s.suggestions.slice(0,n)),s},getSuggestions:function(i){var o,a,n,r,l=this,c=l.options,d=c.serviceUrl,g=l.getFormWrapper();c.params[c.paramName]=i,void 0!==dgwt_wcas.current_lang&&(c.params.l=dgwt_wcas.current_lang),c.params=l.applyCustomParams(c.params),l.preloader("show","form","dgwt-wcas-inner-preloader"),g.addClass("dgwt-wcas-processing"),!1!==c.onSearchStart.call(l.element,c.params)&&(a=c.ignoreParams?null:c.params,t.isFunction(c.lookup)?c.lookup(i,function(t){l.suggestions=t.suggestions,l.suggest(),l.selectFirstSuggestion(t.suggestions),c.onSearchComplete.call(l.element,i,t.suggestions)}):(l.isLocal?o=l.getSuggestionsLocal(i):(t.isFunction(d)&&(d=d.call(l.element,i)),n=d+"?"+t.param(a||{}),o=l.cachedResponse[n]),o&&Array.isArray(o.suggestions)?(l.suggestions=o.suggestions,l.suggest(),l.selectFirstSuggestion(o.suggestions),c.onSearchComplete.call(l.element,i,o.suggestions)):l.isBadQuery(i)?c.onSearchComplete.call(l.element,i,[]):(l.abortAjax(),r={url:d,data:a,type:c.type,dataType:c.dataType},t.extend(r,c.ajaxSettings),s.object=l,s.ajaxSettings=r,e.debounce(function(){var e=s.object,o=s.ajaxSettings;e.currentRequest=t.ajax(o).done(function(t){var s;e.currentRequest=null,void 0!==(s=e.options.transformResult(t,i)).suggestions&&(e.processResponse(s,i,n),e.selectFirstSuggestion(s.suggestions),1===s.suggestions.length&&void 0!==s.suggestions[0].type&&"no-results"===s.suggestions[0].type?e.gaEvent(i,"Autocomplete Search without results"):e.gaEvent(i,"Autocomplete Search with results")),e.fixPositionCapture(),e.options.onSearchComplete.call(e.element,i,s.suggestions),e.updatePrices()}).fail(function(t,s,o){e.options.onSearchError.call(e.element,i,t,s,o)})},c.debounceWaitMs))))},getDetails:function(e){var s=this;if(!s.canShowDetailsBox())return!1;if(null!=e&&void 0!==e.type&&("string"!=typeof e.more_products||"more_products"!==e.more_products)){s.fixHeight();var i,o=s.getDetailsContainer(),a=s.prepareSuggestionObjectID(e);if(null!=(i=s.cachedDetails[a]))o.html(i.html),s.fixHeight(),s.fixPositionCapture();else{var n={action:dgwt_wcas.action_result_details,items:[]};if(t.each(s.suggestions,function(t,e){if(void 0!==e.type&&"more_products"!=e.type&&"headline"!=e.type){var i={objectID:s.prepareSuggestionObjectID(e),value:null!=e.value?e.value:""};n.items.push(i)}}),o.html(""),s.preloader("show","details","",!0),-1!=t.inArray(a,s.detailsRequestsSent))return;s.detailsRequestsSent.push(a),t.ajax({data:n,type:"post",url:dgwt_wcas.ajax_details_endpoint,success:function(t){var e="string"==typeof t?jQuery.parseJSON(t):t;if(void 0!==e.items)for(var i=0;i<e.items.length;i++){var a=e.items[i].objectID;if(s.cachedDetails[a]={html:e.items[i].html},void 0!==e.items[i].price&&e.items[i].price.length>0&&(s.cachedPrices[a]=e.items[i].price),void 0!==e.items[i].imageSrc&&e.items[i].imageSrc.length>0)(new Image).src=e.items[i].imageSrc}s.preloader("hide","details","",!0);var n=s.prepareSuggestionObjectID(s.suggestions[s.selectedIndex]);null!=s.cachedDetails[n]?o.html(s.cachedDetails[n].html):o.html(""),s.fixPositionCapture(),s.fixHeight(),s.updatePrices(!0)},error:function(t,e){s.preloader("hide","details","",!0),o.html(t),s.fixPositionCapture(),s.fixHeight()}})}t(document).trigger("dgwtWcasDetailsPanelLoaded",s)}},updatePrices:function(e){var s,i,o=this,a=[];if(o.options.showPrice&&o.options.dynamicPrices&&0!=o.suggestions.length){for(s=0;s<o.suggestions.length;s++)if(void 0!==o.suggestions[s].type&&("product"==o.suggestions[s].type||"product_variation"==o.suggestions[s].type)){var n="product__"+o.suggestions[s].post_id;void 0!==o.cachedPrices[n]?o.updatePrice(s,o.cachedPrices[n]):(o.applyPreloaderForPrice(s),a.push(o.suggestions[s].post_id))}if(!e&&a.length>0){var r={action:void 0===dgwt_wcas.action_get_prices?"dgwt_wcas_get_prices":dgwt_wcas.action_get_prices,items:a};t.ajax({data:r,type:"post",url:dgwt_wcas.ajax_prices_endpoint,success:function(t){if(void 0!==t.success&&t.success&&t.data.length>0)for(s=0;s<t.data.length;s++){var e=t.data[s].id,a=t.data[s].price;if(o.suggestions.length>0)for(i=0;i<o.suggestions.length;i++)if(void 0!==o.suggestions[i].type&&("product"==o.suggestions[i].type||"product_variation"==o.suggestions[i].type)&&o.suggestions[i].post_id==e){var n="product__"+e;o.cachedPrices[n]=a,o.updatePrice(i,a)}}},error:function(t,e){}})}}},updatePrice:function(e,s){if(void 0!==this.suggestions[e]){this.suggestions[e].price=s;var i=t(".dgwt-wcas-suggestions-wrapp").find('[data-index="'+e+'"] .dgwt-wcas-sp');i.length&&i.html(s)}},applyCustomParams:function(t){if("object"==typeof dgwt_wcas.custom_params){var e=dgwt_wcas.custom_params;for(var s in e)t[s]=e[s]}var i=this.el.data("custom-params");if("object"==typeof i)for(var s in i)t[s]=i[s];return t},applyPreloaderForPrice:function(e){if(void 0!==this.suggestions[e]){var s=t(".dgwt-wcas-suggestions-wrapp").find('[data-index="'+e+'"] .dgwt-wcas-sp');s.length&&s.html('<div class="dgwt-wcas-preloader-price"><div class="dgwt-wcas-preloader-price-inner"> <div></div><div></div><div></div></div></div>')}},prepareSuggestionObjectID:function(t){var e="";return void 0!==t&&void 0!==t.type&&(null!=t.post_id&&(e=t.type+"__"+t.post_id,"product_variation"===t.type&&(e+="__"+t.variation_id),void 0!==t.post_type&&(e=t.type+"__"+t.post_id+"__"+t.post_type)),null!=t.term_id&&null!=t.taxonomy&&(e=t.type+"__"+t.term_id+"__"+t.taxonomy)),e},selectFirstSuggestion:function(e){var s=0,i=!1;this.canShowDetailsBox()&&("undefined"!=e&&e.length>0&&t.each(this.suggestions,function(t,e){if(void 0!==e.type&&"more_products"!=e.type&&"headline"!=e.type&&"no-results"!=e.type)return s=t,!1;void 0!==e.type&&"no-results"!==e.type||(i=!0)}),i||(this.latestActivateSource="system",this.getDetails(e[s]),this.activate(s)))},isBadQuery:function(t){if(!this.options.preventBadQueries)return!1;for(var e=this.badQueries,s=e.length;s--;)if(0===t.indexOf(e[s]))return!0;return!1},hide:function(e){this.getFormWrapper();var s=this.getSuggestionsContainer(),i=this.getDetailsContainer();t.isFunction(this.options.onHide)&&this.visible&&this.options.onHide.call(this.element,container),this.visible=!1,this.selectedIndex=-1,clearTimeout(this.onChangeTimeout),s.hide(),s.removeClass(this.classes.suggestionsContainerOrientTop),i.hide(),t("body").removeClass("dgwt-wcas-open"),t("body").removeClass("dgwt-wcas-block-scroll"),t("body").removeClass("dgwt-wcas-is-details"),t("body").removeClass("dgwt-wcas-full-width"),t("body").removeClass("dgwt-wcas-nores"),t("body").removeClass("dgwt-wcas-details-outside"),t("body").removeClass("dgwt-wcas-details-right"),t("body").removeClass("dgwt-wcas-details-left"),null!=this.autoAligmentprocess&&(clearInterval(this.autoAligmentprocess),this.autoAligmentprocess=null),"boolean"==typeof e&&e&&(this.hideCloseButton(),this.currentValue="",this.suggestions=[]),this.signalHint(null)},positionIconSearchMode:function(e){var s,i=e.find("."+this.options.formClass),o=i.width(),a=t(window).width(),n=e[0].getBoundingClientRect().left;i[0].getBoundingClientRect().left;var r=(n+10)/a;s=Math.floor(o*r*-1),i.css({left:s+"px"})},hideIconModeSearch:function(){var e=t(".dgwt-wcas-layout-icon-open");e.length>0&&e.removeClass("dgwt-wcas-layout-icon-open")},hideAfterClickOutsideListener:function(){var e=this;e.isMobileMode()||t(document).mouseup(function(s){if(e.visible){e.getSuggestionsContainer(),e.getDetailsContainer();var i=!(t(s.target).closest("."+e.options.searchFormClass).length>0||t(s.target).hasClass(e.options.searchFormClass)),o=!(t(s.target).closest("."+e.options.containerClass).length>0||t(s.target).hasClass(e.options.containerClass));if(e.canShowDetailsBox()){var a=!(t(s.target).closest("."+e.options.containerDetailsClass).length>0||t(s.target).hasClass(e.options.containerDetailsClass));i&&o&&a&&e.hide()}else i&&o&&e.hide()}})},suggest:function(){if(this.suggestions.length){var e,s=this,i=s.options,o=i.groupBy,a=i.formatResult,n=s.getQuery(s.currentValue),r=s.classes.suggestion,l=s.classes.selected,c=s.getSuggestionsContainer(),d=s.getDetailsContainer(),g=t(s.noSuggestionsContainer),u=i.beforeRender,h="";i.triggerSelectOnValidInput&&s.isExactMatch(n)?s.select(0):(t("body").removeClass("dgwt-wcas-nores"),t.each(s.suggestions,function(s,l){var c="",g=!1;if(o&&(h+=function(t,s){var i=t.data[o];return e===i?"":'<div class="autocomplete-group"><strong>'+(e=i)+"</strong></div>"}(l,0)),void 0===l.type||"product"!=l.type&&"product_variation"!=l.type){var u=r,p="dgwt-wcas-st",w="",f="",m="",v=!0;"product_cat"===l.taxonomy?(u+=" dgwt-wcas-suggestion-tax dgwt-wcas-suggestion-cat",i.showHeadings||(w+='<span class="dgwt-wcas-st--direct-headline">'+dgwt_wcas.labels.category+"</span>"),void 0!==l.breadcrumbs&&l.breadcrumbs&&(m=l.breadcrumbs+" > "+l.value,f+='<span class="dgwt-wcas-st-breadcrumbs">'+dgwt_wcas.labels.in+" "+l.breadcrumbs+"</span>")):"product_tag"===l.taxonomy?(u+=" dgwt-wcas-suggestion-tax dgwt-wcas-suggestion-tag",i.showHeadings||(w+='<span class="dgwt-wcas-st--direct-headline">'+dgwt_wcas.labels.tag+"</span>")):i.isPremium&&l.taxonomy===i.taxonomyBrands?(u+=" dgwt-wcas-suggestion-tax dgwt-wcas-suggestion-brand",i.showHeadings||(w+='<span class="dgwt-wcas-st--direct-headline">'+dgwt_wcas.labels.brand+"</span>")):i.isPremium&&"post"===l.type?(u+=" dgwt-wcas-suggestion-pt dgwt-wcas-suggestion-tp-post",i.showHeadings||(w+='<span class="dgwt-wcas-st--direct-headline">'+dgwt_wcas.labels.post+"</span>")):i.isPremium&&"page"===l.type?(u+=" dgwt-wcas-suggestion-pt dgwt-wcas-suggestion-pt-page",i.showHeadings||(w+='<span class="dgwt-wcas-st--direct-headline">'+dgwt_wcas.labels.page+"</span>")):"more_products"===l.type?(u+=" js-dgwt-wcas-suggestion-more dgwt-wcas-suggestion-more",p="dgwt-wcas-st-more",l.value=dgwt_wcas.labels.show_more+" ("+l.total+")",v=!1):i.showHeadings&&"headline"===l.type?(u+=" js-dgwt-wcas-suggestion-headline dgwt-wcas-suggestion-headline",void 0!==dgwt_wcas.labels[l.value+"_plu"]&&(l.value=dgwt_wcas.labels[l.value+"_plu"]),v=!1):(u+=" dgwt-wcas-suggestion-nores",l.value=dgwt_wcas.labels.no_results,v=!1,!0===i.showDetailsPanel&&d.html(""),t("body").addClass("dgwt-wcas-nores")),m=m.length>0?' title="'+m+'"':"",h+='<div class="'+u+'" data-index="'+s+'">',h+="<span"+m+' class="'+p+'">'+w+a(l.value,n,v,i)+f+"</span>",h+="</div>"}else!0===i.showImage&&void 0!==l.thumb_html&&(g=!0),c+=void 0!==l.post_id?'data-post-id="'+l.post_id+'" ':"",c+=void 0!==l.taxonomy?'data-taxonomy="'+l.taxonomy+'" ':"",c+=void 0!==l.term_id?'data-term-id="'+l.term_id+'" ':"",h+='<div class="'+r+' dgwt-wcas-suggestion-product" data-index="'+s+'" '+c+">",g&&(h+='<span class="dgwt-wcas-si">'+l.thumb_html+"</span>"),h+=g?'<div class="dgwt-wcas-content-wrapp">':"",h+='<span class="dgwt-wcas-st">',h+='<span class="dgwt-wcas-st-title">'+a(l.value,n,!0,i)+"</span>",!0===i.showSKU&&void 0!==l.sku&&l.sku.length>0&&(h+='<span class="dgwt-wcas-sku">('+dgwt_wcas.labels.sku_label+" "+a(l.sku,n,!0,i)+")</span>"),!0===i.showDescription&&void 0!==l.desc&&l.desc&&(h+='<span class="dgwt-wcas-sd">'+a(l.desc,n,!0,i)+"</span>"),h+="</span>",!0===i.showPrice&&void 0!==l.price&&(h+='<span class="dgwt-wcas-sp">'+l.price+"</span>"),!0===i.showFeaturedBadge&&!0===l.on_sale&&(h+='<span class="dgwt-wcas-badge dgwt-wcas-badge-os">'+i.saleBadgeText+"</span>"),!0===i.showFeaturedBadge&&!0===l.featured&&(h+='<span class="dgwt-wcas-badge dgwt-wcas-badge-f">'+i.featuredBadgeText+"</span>"),h+=g?"</div>":"",h+="</div>"}),this.adjustContainerWidth(),g.detach(),c.html(h),t.isFunction(u)&&u.call(s.element,c,s.suggestions),c.show(),t("body").addClass("dgwt-wcas-open"),s.automaticAlignment(),!0===i.showDetailsPanel&&(t("body").addClass("dgwt-wcas-is-details"),d.show(),s.fixHeight()),i.autoSelectFirst&&(s.selectedIndex=0,c.scrollTop(0),c.children("."+r).first().addClass(l)),s.visible=!0,s.fixPositionCapture(),"top"===s.options.orientation&&(s.getSuggestionsContainer().addClass(s.classes.suggestionsContainerOrientTop),t("body").addClass("dgwt-wcas-block-scroll"),setTimeout(function(){s.scrollDownSuggestions()},300)),s.findBestHint())}else this.hide()},adjustContainerWidth:function(){var e,s=this.options,i=t("body"),o=this.getFormWrapper(),a=this.getSuggestionsContainer(),n=this.getDetailsContainer(),r=this.getFormOffset();if(o.length){var l=getComputedStyle(o[0]).width;if(l=Math.round(parseFloat(l.replace("px",""))),"auto"===s.width&&(e=this.el.outerWidth(),a.css("width",e+"px")),this.canShowDetailsBox()){if(o.width()>=550)return i.addClass("dgwt-wcas-full-width"),l%2==0?(a.css("width",Math.round(l/2)),n.css("width",Math.round(l/2))):(a.css("width",Math.floor(l/2)),n.css("width",Math.ceil(l/2))),i.removeClass("dgwt-wcas-details-left"),i.removeClass("dgwt-wcas-details-right"),void(!0===s.isRtl?n.css("left","0"):a.css("left",l/2+r.left+"px"));i.addClass("dgwt-wcas-details-right")}}},positionPreloader:function(e){var s="object"==typeof e?e.find(".dgwt-wcas-search-submit"):t(".dgwt-wcas-search-submit");s.length>0&&s.each(function(){var e=t(this).closest(".dgwt-wcas-search-wrapp").find(".dgwt-wcas-preloader");1==dgwt_wcas.is_rtl?e.css("left",6+t(this).outerWidth()+"px"):e.css("right",t(this).outerWidth()+"px")})},findBestHint:function(){var e=this.el.val().toLowerCase(),s=null;e&&(t.each(this.suggestions,function(t,i){var o=0===i.value.toLowerCase().indexOf(e);return o&&(s=i),!o}),this.signalHint(s))},signalHint:function(e){var s="";e&&(s=this.currentValue+e.value.substr(this.currentValue.length)),this.hintValue!==s&&(this.hintValue=s,this.hint=e,(this.options.onHint||t.noop)(s))},preloader:function(e,s,i,o){var a,n,r="dgwt-wcas-preloader-wrapp",l=null==i?r:r+" "+i;if("form"===s?n=this.getFormWrapper().find(".dgwt-wcas-preloader"):"details"===s&&(n=this.getDetailsContainer()),1==dgwt_wcas.show_preloader&&0!=n.length)if(!0===o)if("hide"!==e){if("show"===e){var c=this.options.isRtl?"-rtl":"";a='<div class="'+l+'"><img class="dgwt-wcas-placeholder-preloader" src="'+dgwt_wcas.img_url+"placeholder"+c+'.png" /></div>',n.html(a)}}else t(r).remove();else"hide"===e?(n.removeClass(i),n.html("")):(n.addClass(i),"string"==typeof dgwt_wcas.preloader_icon&&n.html(dgwt_wcas.preloader_icon))},verifySuggestionsFormat:function(e){return e.length&&"string"==typeof e[0]?t.map(e,function(t){return{value:t,data:null}}):e},validateOrientation:function(e,s){return e=t.trim(e||"").toLowerCase(),-1===t.inArray(e,["auto","bottom","top"])&&(e=s),e},processResponse:function(t,e,s){var i=this.options;t.suggestions=this.verifySuggestionsFormat(t.suggestions),i.noCache||(this.cachedResponse[s]=t,i.preventBadQueries&&!t.suggestions.length&&this.badQueries.push(e)),e===this.getQuery(this.currentValue)&&("top"===this.options.orientation&&t.suggestions.reverse(),this.suggestions=t.suggestions,this.suggest())},activate:function(e){var s,i=this.classes.selected,o=this.getSuggestionsContainer(),a=o.find("."+this.classes.suggestion);return o.find("."+i).removeClass(i),this.selectedIndex=e,-1!==this.selectedIndex&&a.length>this.selectedIndex?(s=a.get(this.selectedIndex),t(s).addClass(i),s):null},selectHint:function(){var e=t.inArray(this.hint,this.suggestions);this.select(e)},select:function(t){this.hide(),this.onSelect(t)},moveUp:function(){if(-1!==this.selectedIndex){if(this.latestActivateSource="key",0===this.selectedIndex)return this.getSuggestionsContainer().children("."+this.classes.suggestion).first().removeClass(this.classes.selected),this.selectedIndex=-1,this.ignoreValueChange=!1,this.el.val(this.currentValue),void this.findBestHint();this.adjustScroll(this.selectedIndex-1,"up")}},moveDown:function(){this.selectedIndex!==this.suggestions.length-1&&(this.latestActivateSource="key",this.adjustScroll(this.selectedIndex+1,"down"))},adjustScroll:function(e,s){if("headline"===this.suggestions[e].type&&(e="down"===s?e+1:e-1),void 0!==this.suggestions[e]){var i=this.activate(e);if(this.getDetails(this.suggestions[e]),"more_products"!==this.suggestions[e].type&&i&&!this.canShowDetailsBox()){var o,a,n,r=this.getSuggestionsContainer(),l=t(i).outerHeight();o=i.offsetTop,n=(a=r.scrollTop())+this.options.maxHeight-l,o<a?r.scrollTop(o):o>n&&r.scrollTop(o-this.options.maxHeight+l),this.options.preserveInput||(this.ignoreValueChange=!0),this.signalHint(null)}}},onSelect:function(e){var s=this.options.onSelect,i=this.suggestions[e];void 0===i.type||"more_products"!==i.type&&("enter"!==this.actionTriggerSource||"key"==this.latestActivateSource||"product_variation"==i.type)?(this.currentValue=this.getValue(i.value),this.currentValue===this.el.val()||this.options.preserveInput||this.el.val(this.currentValue),i.url.length>0&&(window.location.href=i.url),this.signalHint(null),this.suggestions=[],this.selection=i,t.isFunction(s)&&s.call(this.element,i)):this.el.closest("form").trigger("submit")},getValue:function(t){var e,s,i=this.options.delimiter;return i?1===(s=(e=this.currentValue).split(i)).length?t:e.substr(0,e.length-s[s.length-1].length)+t:t},dispose:function(){this.el.off(".autocomplete").removeData("autocomplete"),t(window).off("resize.autocomplete",this.fixPositionCapture),t("."+this.options.containerClass).remove(),t("."+this.options.containerDetailsClass).remove()},enableOverlayMobile:function(){var e=this;if("on"!==e.overlayMobileState){e.overlayMobileState="on";var s,i=e.getFormWrapper(),o=e.getSuggestionsContainer(),a="";t("html").addClass("dgwt-wcas-overlay-mobile-on"),a+='<div class="js-dgwt-wcas-overlay-mobile dgwt-wcas-overlay-mobile">',a+='<div class="dgwt-wcas-om-bar js-dgwt-wcas-om-bar">',a+='<span class="dgwt-wcas-om-return js-dgwt-wcas-om-return">',"string"==typeof dgwt_wcas.back_icon?a+=dgwt_wcas.back_icon:(a+='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" color="#FFF">',a+='<path fill="#FFF" d="M14 6.125H3.351l4.891-4.891L7 0 0 7l7 7 1.234-1.234L3.35 7.875H14z" fill-rule="evenodd"></path>',a+="</svg>"),a+="</span>",a+="</div>",a+="</div>",t(e.options.mobileOverlayWrapper).append(a),(s=t(".js-dgwt-wcas-overlay-mobile")).css("zIndex",999999),i.after('<span class="js-dgwt-wcas-om-hook"></span>'),i.appendTo(".js-dgwt-wcas-om-bar"),o.appendTo(".js-dgwt-wcas-om-bar"),i.addClass("dgwt-wcas-search-wrapp-mobile"),i.hasClass("dgwt-wcas-has-submit")&&(i.addClass("dgwt-wcas-has-submit-off"),i.removeClass("dgwt-wcas-has-submit")),i.find("."+e.options.searchInputClass).focus(),t(document).on("click",".js-dgwt-wcas-om-return",function(t){e.disableOverlayMobile(s)})}},disableOverlayMobile:function(e){var s=this,i=s.getSuggestionsContainer(),o=t(".js-dgwt-wcas-om-bar").find("."+s.options.searchFormClass);o.hasClass("dgwt-wcas-has-submit-off")&&(o.removeClass("dgwt-wcas-has-submit-off"),o.addClass("dgwt-wcas-has-submit")),o.removeClass("dgwt-wcas-search-wrapp-mobile"),t("html").removeClass("dgwt-wcas-overlay-mobile-on"),i.appendTo("body"),i.removeAttr("body-scroll-lock-ignore"),t(".js-dgwt-wcas-om-hook").after(o),t(".js-dgwt-wcas-overlay-mobile").remove(),t(".js-dgwt-wcas-om-hook").remove(),setTimeout(function(){o.find("."+s.options.searchInputClass).val("");var t=o.find(".dgwt-wcas-close");o.length>0&&t.removeClass("dgwt-wcas-close"),s.hide()},150),s.overlayMobileState="off"},showCloseButton:function(){var t=void 0!==dgwt_wcas.close_icon?dgwt_wcas.close_icon:"",e=this.getFormWrapper().find("."+this.options.preloaderClass);e.addClass(this.options.closeTrigger),e.html(t)},hideCloseButton:function(){var t=this.getFormWrapper().find("."+this.options.closeTrigger);t.length&&(t.removeClass(this.options.closeTrigger),t.html(""))},elementOrParentIsFixed:function(e){var s=e.add(e.parents()),i=!1;return s.each(function(){if("fixed"===t(this).css("position"))return i=!0,!1}),i},gaEvent:function(t,e){if(this.options.sendGAEvents)try{if("undefined"!=typeof gtag)gtag("event","autocomplete_search",{event_label:t,event_category:e});else if("undefined"!=typeof ga){var s=ga.getAll()[0];s&&s.send({hitType:"event",eventCategory:e,eventAction:"autocomplete_search",eventLabel:t})}}catch(t){}if(this.options.enableGASiteSearchModule)try{if("undefined"!=typeof gtag)gtag("event","page_view",{page_path:"/?s="+encodeURI(t)+"&post_type=product&dgwt_wcas=1"});else if("undefined"!=typeof ga){var i=ga.getAll()[0];i&&(i.set("page","/?s="+encodeURI(t)+"&post_type=product&dgwt_wcas=1"),i.send("pageview"))}}catch(t){}}},t.fn.dgwtWcasAutocomplete=function(e,s){return arguments.length?this.each(function(){var i=t(this),o=i.data("autocomplete");"string"==typeof e?o&&"function"==typeof o[e]&&o[e](s):(o&&o.dispose&&o.dispose(),o=new d(this,e),i.data("autocomplete",o))}):this.first().data("autocomplete")},t.fn.autocomplete||(t.fn.autocomplete=t.fn.dgwtWcasAutocomplete),function(){function e(){var e=t(".dgwt-wcas-search-input"),s=[];e.length>1&&e.each(function(){var e=t(this).attr("id");if(-1==t.inArray(e,s))s.push(e);else{var i=Math.random().toString(36).substring(2,6);i="dgwt-wcas-search-input-"+i,t(this).attr("id",i),t(this).closest("form").find("label").attr("for",i)}})}function s(){var e=t(".dgwt-wcas-search-input");e.length>0&&e.each(function(){"object"!=typeof t(this).data("autocomplete")&&t(this).dgwtWcasAutocomplete(window.dgwt_wcas.config)})}t(document).ready(function(){var e=1==dgwt_wcas.show_details_box,s=dgwt_wcas.mobile_breakpoint;(jQuery(window).width()<s||"ontouchend"in document)&&(e=!1),window.dgwt_wcas.config={minChars:dgwt_wcas.min_chars,width:dgwt_wcas.sug_width,autoSelectFirst:!1,triggerSelectOnValidInput:!1,serviceUrl:dgwt_wcas.ajax_search_endpoint,paramName:"s",showDetailsPanel:e,showImage:1==dgwt_wcas.show_images,showPrice:1==dgwt_wcas.show_price,showDescription:1==dgwt_wcas.show_desc,showSKU:1==dgwt_wcas.show_sku,showSaleBadge:1==dgwt_wcas.show_sale_badge,showFeaturedBadge:1==dgwt_wcas.show_featured_badge,dynamicPrices:!(void 0===dgwt_wcas.dynamic_prices||!dgwt_wcas.dynamic_prices),saleBadgeText:dgwt_wcas.labels.sale_badge,featuredBadgeText:dgwt_wcas.labels.featured_badge,isRtl:1==dgwt_wcas.is_rtl,showHeadings:1==dgwt_wcas.show_headings,isPremium:1==dgwt_wcas.is_premium,taxonomyBrands:dgwt_wcas.taxonomy_brands,mobileBreakpoint:s,mobileOverlayWrapper:dgwt_wcas.mobile_overlay_wrapper,debounceWaitMs:dgwt_wcas.debounce_wait_ms,sendGAEvents:dgwt_wcas.send_ga_events,convertHtml:dgwt_wcas.convert_html,enableGASiteSearchModule:dgwt_wcas.enable_ga_site_search_module},t(".dgwt-wcas-search-input").dgwtWcasAutocomplete(window.dgwt_wcas.config)}),t(document).ready(function(){setTimeout(function(){e(),s()},500)}),t(window).on("load",function(){setTimeout(function(){e(),s()},500),void 0!==window.elementorFrontend&&void 0!==window.elementorFrontend.documentsManager&&void 0!==window.elementorFrontend.documentsManager.documents&&t.each(elementorFrontend.documentsManager.documents,function(t,e){void 0!==e.getModal&&e.getModal&&e.getModal().on("show",function(){setTimeout(function(){s()},300)})})})}()});
|
1 |
+
!function(t){"use strict";"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof exports&&"function"==typeof require?t(require("jquery")):t(jQuery)}(function(t){"use strict";var e={escapeRegExChars:function(t){return t.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&")},createNode:function(t){var e=document.createElement("div");return e.className=t,e.style.position="absolute",e.style.display="none",e.setAttribute("unselectable","on"),e},highlight:function(t,s){if(dgwt_wcas.is_premium){var i,o=s.split(/ /),a=!1;if(o)for(o=o.sort(function(t,e){return e.length-t.length}),i=0;i<o.length;i++)if(o[i]&&o[i].length>1){var n=o[i].replace(/[\^\@]/g,"");if(n.length>0){var r="("+e.escapeRegExChars(n.trim())+")";t=t.replace(new RegExp(r,"gi"),"^^$1@@"),a=!0}}a&&(t=(t=t.replace(/\^\^/g,"<strong>")).replace(/@@/g,"</strong>"))}else r="("+e.escapeRegExChars(s)+")",t=t.replace(new RegExp(r,"gi"),"<strong>$1</strong>");return t},debounce:function(t,e){var i,o=(new Date).getUTCMilliseconds();if(0===s.id.length)return s.id=o,void t();s.id=o,i=setTimeout(function(){o===s.id?(t(),s.id=""):clearTimeout(i)},e)},mouseHoverDebounce:function(e,s,i){var o;o=setTimeout(function(){t(s+":hover").length>0?e():clearTimeout(o)},i)},getActiveInstance:function(){var e,s=t(".dgwt-wcas-search-wrapp.dgwt-wcas-active");return s.length>0&&s.each(function(){var s=t(this).find(".dgwt-wcas-search-input");if("object"==typeof s.data("autocomplete"))return e=s.data("autocomplete"),!1}),e}},s={id:"",callback:null,ajaxSettings:null,object:null},i=27,o=9,a=13,n=38,r=39,l=40,c=t.noop;function d(e,s){this.element=e,this.el=t(e),this.suggestions=[],this.badQueries=[],this.selectedIndex=-1,this.currentValue=this.element.value,this.timeoutId=null,this.cachedResponse={},this.cachedDetails={},this.cachedPrices={},this.detailsRequestsSent=[],this.onChangeTimeout=null,this.onChange=null,this.isLocal=!1,this.suggestionsContainer=null,this.detailsContainer=null,this.autoAligmentprocess=null,this.noSuggestionsContainer=null,this.latestActivateSource="",this.actionTriggerSource="",this.options=t.extend(!0,{},d.defaults,s),this.classes={selected:"dgwt-wcas-suggestion-selected",suggestion:"dgwt-wcas-suggestion",suggestionsContainerOrientTop:"dgwt-wcas-suggestions-wrapp--top"},this.hint=null,this.hintValue="",this.selection=null,this.overlayMobileState="off",this.initialize(),this.setOptions(s)}d.utils=e,t.DgwtWcasAutocompleteSearch=d,d.defaults={ajaxSettings:{},autoSelectFirst:!1,appendTo:"body",serviceUrl:null,lookup:null,onSelect:null,width:"auto",containerDetailsWidth:"auto",showDetailsPanel:!1,showImage:!1,showPrice:!1,showSKU:!1,showDescription:!1,showSaleBadge:!1,showFeaturedBadge:!1,dynamicPrices:!1,saleBadgeText:"sale",featuredBadgeText:"featured",minChars:3,maxHeight:600,deferRequestBy:0,params:{},formatResult:function(t,s,i,o){if(!s)return t;i&&(t=e.highlight(t,s));if(!o.convertHtml)return t;return t.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/<sup/g,"<sup").replace(/<\/sup/g,"</sup").replace(/sup>/g,"sup>").replace(/<(\/?(strong|b|br))>/g,"<$1>")},delimiter:null,zIndex:999999999,type:"GET",noCache:!1,isRtl:!1,onSearchStart:c,onSearchComplete:c,onSearchError:c,preserveInput:!1,searchFormClass:"dgwt-wcas-search-wrapp",containerClass:"dgwt-wcas-suggestions-wrapp",containerDetailsClass:"dgwt-wcas-details-wrapp",searchInputClass:"dgwt-wcas-search-input",preloaderClass:"dgwt-wcas-preloader",closeTrigger:"dgwt-wcas-close",formClass:"dgwt-wcas-search-form",tabDisabled:!1,dataType:"text",currentRequest:null,triggerSelectOnValidInput:!0,isPremium:!1,overlayMobile:!1,preventBadQueries:!0,lookupFilter:function(t,e,s){return-1!==t.value.toLowerCase().indexOf(s)},paramName:"query",transformResult:function(e){return"string"==typeof e?t.parseJSON(e):e},noSuggestionNotice:"No results",orientation:"bottom",forceFixPosition:!1,positionFixed:!1,debounceWaitMs:400,sendGAEvents:!0,enableGASiteSearchModule:!1},d.prototype={initialize:function(){var s=this;s.element.setAttribute("autocomplete","off"),s.createContainers(),s.registerEventsSearchBar(),s.registerEventsSuggestions(),s.registerEventsDetailsPanel(),s.registerIconHandler(),s.registerEventsFixedMenu(),s.fixPositionCapture=function(){s.adjustContainerWidth(),s.visible&&s.fixPosition()},t(window).on("resize.autocomplete",function(){var t=e.getActiveInstance();void 0!==t&&t.fixPositionCapture()}),s.initMobileMode(),s.hideAfterClickOutsideListener(),s.suggestionsContainer.addClass("js-dgwt-wcas-initialized"),s.detailsContainer&&s.detailsContainer.length>0&&s.detailsContainer.addClass("js-dgwt-wcas-initialized")},createContainers:function(e){var s=this.options;0==t("."+s.containerClass).length?(this.suggestionsContainer=t(d.utils.createNode(s.containerClass)),this.suggestionsContainer.appendTo(s.appendTo||"body"),this.suggestionsContainer.addClass("woocommerce"),!0===s.showImage&&this.suggestionsContainer.addClass("dgwt-wcas-has-img"),!0===s.showPrice&&this.suggestionsContainer.addClass("dgwt-wcas-has-price"),!0===s.showDescription&&this.suggestionsContainer.addClass("dgwt-wcas-has-desc"),!0===s.showSKU&&this.suggestionsContainer.addClass("dgwt-wcas-has-sku"),!0===s.showHeadings&&this.suggestionsContainer.addClass("dgwt-wcas-has-headings"),"auto"!==s.width&&this.suggestionsContainer.width(s.width)):this.suggestionsContainer=t("."+this.options.containerClass),this.canShowDetailsBox()&&(0==t("."+s.containerDetailsClass).length?(this.detailsContainer=t(d.utils.createNode(s.containerDetailsClass)),this.detailsContainer.appendTo(s.appendTo||"body"),this.detailsContainer.addClass("woocommerce")):this.detailsContainer=t("."+s.containerDetailsClass))},registerEventsSearchBar:function(){var s=this;t(document).on("click.autocomplete","."+s.options.closeTrigger,function(){var s=e.getActiveInstance();s.hide(),s.clear(!1),s.hideCloseButton(),t(this).closest("."+s.options.searchFormClass).find("."+s.options.searchInputClass).val("").focus()}),s.el.closest("."+s.options.formClass).on("submit.autocomplete",function(e){s.suggestions.length>0&&t.each(s.suggestions,function(t,i){if(void 0!==i.type&&"product_variation"==i.type)return s.select(t),e.preventDefault(),!1})}),t(window).on("load",function(){s.positionPreloader()}),s.el.on("keydown.autocomplete",function(t){s.onKeyPress(t)}),s.el.on("keyup.autocomplete",function(t){s.onKeyUp(t)}),s.el.on("blur.autocomplete",function(){s.onBlur()}),s.el.on("focus.autocomplete",function(){s.onFocus()}),s.el.on("change.autocomplete",function(t){s.onKeyUp(t)}),s.el.on("input.autocomplete",function(t){s.onKeyUp(t)})},registerEventsSuggestions:function(){var s="."+this.classes.suggestion;if(!this.getSuggestionsContainer().hasClass("js-dgwt-wcas-initialized")){t(document).on("mouseenter.autocomplete",s,function(){var s=e.getActiveInstance();if(void 0!==s){var i=t(this).data("index"),o='.dgwt-wcas-suggestion[data-index="'+i+'"]',a=s.canShowDetailsBox()?100:1;s.selectedIndex!=i&&e.mouseHoverDebounce(function(){s.selectedIndex!==i&&(s.latestActivateSource="mouse",s.getDetails(s.suggestions[i]),s.activate(i))},o,a)}});var i=!1;t(document).on("click.autocomplete",s,function(){if(!i){var s=e.getActiveInstance();s.actionTriggerSource="click",i=!0,s.select(t(this).data("index"))}}),t(document).on("mousedown.autocomplete",s,function(e){"number"==typeof e.which&&1===e.which&&t(e.target)[0].click()}),t(document).on("click.autocomplete","."+this.options.containerClass,function(){var t=e.getActiveInstance();clearTimeout(t.blurTimeoutId)})}},registerEventsDetailsPanel:function(){var s=this.getDetailsContainer();this.canShowDetailsBox()&&!s.hasClass("js-dgwt-wcas-initialized")&&(t(document).on("click.autocomplete","."+this.options.containerDetailsClass,function(){var t=e.getActiveInstance();clearTimeout(t.blurTimeoutId)}),t(document).on("change",'[name="js-dgwt-wcas-quantity"]',function(e){t(this).closest(".js-dgwt-wcas-pd-addtc").find("[data-quantity]").attr("data-quantity",t(this).val())}))},registerIconHandler:function(){var s=this,i=s.getFormWrapper(),o=i.find("."+s.options.formClass);i.on("click",".js-dgwt-wcas-search-icon-handler",function(t){var e=i.find("."+s.options.searchInputClass);if(i.hasClass("dgwt-wcas-layout-icon-open"))s.hide(),o.hide(!0),i.removeClass("dgwt-wcas-layout-icon-open");else{var a=i.find(".dgwt-wcas-search-icon-arrow");o.hide(),a.hide(),i.addClass("dgwt-wcas-layout-icon-open"),s.positionIconSearchMode(i),o.fadeIn(200,function(){a.show(),s.positionPreloader(i),e.focus()})}}),0==t(".js-dgwt-wcas-initialized").length&&t(".js-dgwt-wcas-search-icon-handler").length>0&&t(document).click(function(i){if(t(".dgwt-wcas-layout-icon-open").length){var o=t(i.target);if(!(o.closest("."+s.options.searchFormClass).length>0||o.closest("."+s.options.containerClass).length>0||o.closest("."+s.options.containerDetailsClass).length>0)){var a=e.getActiveInstance();if(void 0!==a){var n=a.getFormWrapper().find("."+s.options.formClass);n.hide(),a.hide(!0),n.css({left:"0"})}s.hideIconModeSearch()}}}),t(window).on("resize.autocomplete",function(){s.applyFlexibleMode()}),t(window).on("load",function(){s.applyFlexibleMode()})},registerEventsFixedMenu:function(){var e=this;t(window).on("scroll",function(){if(e.suggestions.length>0&&e.elementOrParentIsFixed(e.getFormWrapper()))if(0===t(window).scrollTop()){[1,10,20,30,40,50,60,70,80,90,120,140,170,200,250,400,700,1e3,2e3].forEach(function(t){setTimeout(function(){e.fixHeight(),e.fixPositionCapture()},t)})}else e.fixHeight(),e.fixPositionCapture()})},initMobileMode:function(){var t=this,e=t.getFormWrapper();e.hasClass("js-dgwt-wcas-mobile-overlay-enabled")&&t.isMobileMode()&&(e.prepend('<div class="js-dgwt-wcas-enable-mobile-form dgwt-wcas-enable-mobile-form"></div>'),e.find(".js-dgwt-wcas-enable-mobile-form").on("click",function(e){t.enableOverlayMobile()}))},applyFlexibleMode:function(){var e=t(".js-dgwt-wcas-layout-icon-flexible");e.length&&(this.isMobileMode()?(e.addClass("js-dgwt-wcas-layout-icon"),e.addClass("dgwt-wcas-layout-icon")):(e.removeClass("js-dgwt-wcas-layout-icon"),e.removeClass("dgwt-wcas-layout-icon")),e.addClass("dgwt-wcas-layout-icon-flexible-loaded"))},onFocus:function(){t("."+this.options.searchFormClass).removeClass("dgwt-wcas-active"),this.getFormWrapper().addClass("dgwt-wcas-active"),this.fixPositionCapture(),this.el.val().length>=this.options.minChars&&this.onValueChange()},onBlur:function(){var e=this,s=e.options,i=e.el.val(),o=e.getQuery(i);e.isMobileMode()||(e.blurTimeoutId=setTimeout(function(){e.hide(),e.selection&&e.currentValue!==o&&(s.onInvalidateSelection||t.noop).call(e.element)},200))},abortAjax:function(){this.currentRequest&&(this.currentRequest.abort(),this.currentRequest=null)},setOptions:function(e){var s=this,i=s.getSuggestionsContainer(),o=t.extend({},s.options,e);(s.isLocal=Array.isArray(o.lookup),s.isLocal&&(o.lookup=s.verifySuggestionsFormat(o.lookup)),o.orientation=s.validateOrientation(o.orientation,"bottom"),i.css({"max-height":s.canShowDetailsBox()?"none":o.maxHeight+"px",width:o.width+"px","z-index":o.zIndex}),!0===o.showDetailsPanel)&&s.getDetailsContainer().css({"z-index":o.zIndex-1});o.onSearchComplete=function(){s.getFormWrapper().removeClass("dgwt-wcas-processing"),s.preloader("hide","form","dgwt-wcas-inner-preloader"),s.showCloseButton()},this.options=o},clearCache:function(){this.cachedResponse={},this.cachedDetails={},this.cachedPrices={},this.badQueries=[]},clear:function(t){t&&this.clearCache(),this.currentValue="",this.suggestions=[]},disable:function(){this.disabled=!0,clearTimeout(this.onChangeTimeout),this.abortAjax()},enable:function(){this.disabled=!1},fixPosition:function(){var t=this.getFormOffset();this.getSuggestionsContainer().css(t),this.canShowDetailsBox()&&this.fixPositionDetailsBox()},fixPositionDetailsBox:function(){var e=this.getFormWrapper(),s=this.getSuggestionsContainer(),i=this.getDetailsContainer(),o=this.getFormOffset(),a=o.left;if(0==i.length)return!1;var n=!0===this.options.isRtl?1:2,r=Math.round(o.left);if(o.left=r+Math.round(s.width()+n),i.css(o),e.width()>=550)return t("body").removeClass("dgwt-wcas-details-outside"),t("body").removeClass("dgwt-wcas-details-right"),t("body").removeClass("dgwt-wcas-details-left"),void(!0===this.options.isRtl&&(s.css("left",r+Math.round(i.width()+n)+"px"),i.css("left",a+"px")));var l=t(window).width(),c=i.width(),d=i.offset();t("body").addClass("dgwt-wcas-details-outside"),!0===this.options.isRtl&&(o.left=o.left+1);var g=!1,u=!1;l<d.left+c&&(g=!0,t("body").removeClass("dgwt-wcas-details-right"),t("body").addClass("dgwt-wcas-details-left"),i.css("left",Math.round(parseFloat(s.css("left").replace("px","")))-i.outerWidth()+"px")),(d=i.offset()).left<1&&(u=!0,t("body").removeClass("dgwt-wcas-details-left"),t("body").addClass("dgwt-wcas-details-right")),u&&g?(t("body").removeClass("dgwt-wcas-details-left"),t("body").removeClass("dgwt-wcas-details-right"),t("body").addClass("dgwt-wcas-details-notfit")):t("body").removeClass("dgwt-wcas-details-notfit")},fixHeight:function(){if(1!=this.options.showDetailsPanel)return!1;var t=this.getSuggestionsContainer(),e=this.getDetailsContainer();t.css("height","auto"),e.css("height","auto");var s=t.outerHeight(),i=e.outerHeight();return t.find(".dgwt-wcas-suggestion:last-child").removeClass("dgwt-wcas-suggestion-no-border-bottom"),!(s<=340&&i<=340)&&(t.find(".dgwt-wcas-suggestion:last-child").addClass("dgwt-wcas-suggestion-no-border-bottom"),i<s&&e.css("height",s+"px"),s<i&&t.css("height",i+"px"),!1)},automaticAlignment:function(){var t=this,e=t.getFormWrapper().find(".dgwt-wcas-search-input"),s=t.getSuggestionsContainer(),i=t.getDetailsContainer();if(null==t.autoAligmentprocess){var o=[e.width(),s.height()];t.options.showDetailsPanel&&(o[2]=i.height()),t.autoAligmentprocess=setInterval(function(){var a=[e.width(),s.height()];t.options.showDetailsPanel&&(a[2]=i.height());for(var n=0;n<o.length;n++)if(o[n]!=a[n]){t.fixHeight(),t.fixPositionCapture(),o=a;break}t.options.showDetailsPanel&&(i.find(".dgwt-wcas-details-inner").height()-i.height()>2&&t.fixHeight())},10)}},getFormOffset:function(){var e=this.getFormWrapper(),s=this.getSuggestionsContainer(),i=this.options.orientation,o=e.outerHeight(),a=this.el.outerHeight(),n=this.el.offset(),r={top:n.top,left:n.left};if("auto"===i){var l=t(window).height(),c=t(window).scrollTop(),d=-c+n.top-o,g=c+l-(n.top+a+o);i=Math.max(d,g)===d?"top":"bottom"}if("top"===i){s[0].getBoundingClientRect().top;var u=e[0].getBoundingClientRect().top;s.css("height","auto"),u<s.height()&&s.height(u-10),r.top+=-s.outerHeight()}else r.top+=a;return r},getFormWrapper:function(){return this.el.closest("."+this.options.searchFormClass)},getSuggestionsContainer:function(){return t("."+this.options.containerClass)},getDetailsContainer:function(){return t("."+this.options.containerDetailsClass)},scrollDownSuggestions:function(){var t=this.getSuggestionsContainer();t[0].scrollTop=t[0].scrollHeight},isCursorAtEnd:function(){var t,e=this.el.val().length,s=this.element.selectionStart;return"number"==typeof s?s===e:!document.selection||((t=document.selection.createRange()).moveStart("character",-e),e===t.text.length)},onKeyPress:function(t){if(this.disabled||this.visible||t.which!==l||!this.currentValue){if(!this.disabled&&this.visible){switch(t.which){case i:this.el.val(this.currentValue),this.hide();break;case r:if(this.hint&&this.options.onHint&&this.isCursorAtEnd()){this.selectHint();break}return;case o:if(this.hint&&this.options.onHint)return void this.selectHint();if(-1===this.selectedIndex)return void this.hide();if(this.select(this.selectedIndex),!1===this.options.tabDisabled)return;break;case a:if(-1===this.selectedIndex)return void this.hide();this.actionTriggerSource="enter",this.select(this.selectedIndex);break;case n:this.moveUp();break;case l:this.moveDown();break;default:return}t.stopImmediatePropagation(),t.preventDefault()}}else this.suggest()},onKeyUp:function(t){var e=this;if(!e.disabled){switch(t.which){case n:case l:return}clearTimeout(e.onChangeTimeout),e.currentValue!==e.el.val()&&(e.findBestHint(),e.options.deferRequestBy>0?e.onChangeTimeout=setTimeout(function(){e.onValueChange()},e.options.deferRequestBy):e.onValueChange())}},onValueChange:function(){if(this.ignoreValueChange)this.ignoreValueChange=!1;else{var e=this.options,s=this.el.val(),i=this.getQuery(s);this.selection&&this.currentValue!==i&&(this.selection=null,(e.onInvalidateSelection||t.noop).call(this.element)),clearTimeout(this.onChangeTimeout),this.currentValue=s,this.selectedIndex=-1,e.triggerSelectOnValidInput&&this.isExactMatch(i)?this.select(0):i.length<e.minChars?(this.hideCloseButton(),this.hide()):this.getSuggestions(i)}},isExactMatch:function(t){var e=this.suggestions;return 1===e.length&&e[0].value.toLowerCase()===t.toLowerCase()},canShowDetailsBox:function(){return 1==this.options.showDetailsPanel&&!this.isMobileMode()},isMobileMode:function(){return t(window).width()<this.options.mobileBreakpoint},getQuery:function(e){var s,i=this.options.delimiter;return i?(s=e.split(i),t.trim(s[s.length-1])):e},getSuggestionsLocal:function(e){var s,i=this.options,o=e.toLowerCase(),a=i.lookupFilter,n=parseInt(i.lookupLimit,10);return s={suggestions:t.grep(i.lookup,function(t){return a(t,e,o)})},n&&s.suggestions.length>n&&(s.suggestions=s.suggestions.slice(0,n)),s},getSuggestions:function(i){var o,a,n,r,l=this,c=l.options,d=c.serviceUrl,g=l.getFormWrapper();c.params[c.paramName]=i,void 0!==dgwt_wcas.current_lang&&(c.params.l=dgwt_wcas.current_lang),c.params=l.applyCustomParams(c.params),l.preloader("show","form","dgwt-wcas-inner-preloader"),g.addClass("dgwt-wcas-processing"),!1!==c.onSearchStart.call(l.element,c.params)&&(a=c.ignoreParams?null:c.params,t.isFunction(c.lookup)?c.lookup(i,function(t){l.suggestions=t.suggestions,l.suggest(),l.selectFirstSuggestion(t.suggestions),c.onSearchComplete.call(l.element,i,t.suggestions)}):(l.isLocal?o=l.getSuggestionsLocal(i):(t.isFunction(d)&&(d=d.call(l.element,i)),n=d+"?"+t.param(a||{}),o=l.cachedResponse[n]),o&&Array.isArray(o.suggestions)?(l.suggestions=o.suggestions,l.suggest(),l.selectFirstSuggestion(o.suggestions),c.onSearchComplete.call(l.element,i,o.suggestions)):l.isBadQuery(i)?c.onSearchComplete.call(l.element,i,[]):(l.abortAjax(),r={url:d,data:a,type:c.type,dataType:c.dataType},t.extend(r,c.ajaxSettings),s.object=l,s.ajaxSettings=r,e.debounce(function(){var e=s.object,o=s.ajaxSettings;e.currentRequest=t.ajax(o).done(function(t){var s;e.currentRequest=null,void 0!==(s=e.options.transformResult(t,i)).suggestions&&(e.processResponse(s,i,n),e.selectFirstSuggestion(s.suggestions),1===s.suggestions.length&&void 0!==s.suggestions[0].type&&"no-results"===s.suggestions[0].type?e.gaEvent(i,"Autocomplete Search without results"):e.gaEvent(i,"Autocomplete Search with results")),e.fixPositionCapture(),e.options.onSearchComplete.call(e.element,i,s.suggestions),e.updatePrices()}).fail(function(t,s,o){e.options.onSearchError.call(e.element,i,t,s,o)})},c.debounceWaitMs))))},getDetails:function(e){var s=this;if(!s.canShowDetailsBox())return!1;if(null!=e&&void 0!==e.type&&("string"!=typeof e.more_products||"more_products"!==e.more_products)){s.fixHeight();var i,o=s.getDetailsContainer(),a=s.prepareSuggestionObjectID(e);if(null!=(i=s.cachedDetails[a]))o.html(i.html),s.fixHeight(),s.fixPositionCapture();else{var n={action:dgwt_wcas.action_result_details,items:[]};if(t.each(s.suggestions,function(t,e){if(void 0!==e.type&&"more_products"!=e.type&&"headline"!=e.type){var i={objectID:s.prepareSuggestionObjectID(e),value:null!=e.value?e.value:""};n.items.push(i)}}),o.html(""),s.preloader("show","details","",!0),-1!=t.inArray(a,s.detailsRequestsSent))return;s.detailsRequestsSent.push(a),t.ajax({data:n,type:"post",url:dgwt_wcas.ajax_details_endpoint,success:function(t){var e="string"==typeof t?jQuery.parseJSON(t):t;if(void 0!==e.items)for(var i=0;i<e.items.length;i++){var a=e.items[i].objectID;if(s.cachedDetails[a]={html:e.items[i].html},void 0!==e.items[i].price&&e.items[i].price.length>0&&(s.cachedPrices[a]=e.items[i].price),void 0!==e.items[i].imageSrc&&e.items[i].imageSrc.length>0)(new Image).src=e.items[i].imageSrc}s.preloader("hide","details","",!0);var n=s.prepareSuggestionObjectID(s.suggestions[s.selectedIndex]);null!=s.cachedDetails[n]?o.html(s.cachedDetails[n].html):o.html(""),s.fixPositionCapture(),s.fixHeight(),s.updatePrices(!0)},error:function(t,e){s.preloader("hide","details","",!0),o.html(t),s.fixPositionCapture(),s.fixHeight()}})}t(document).trigger("dgwtWcasDetailsPanelLoaded",s)}},updatePrices:function(e){var s,i,o=this,a=[];if(o.options.showPrice&&o.options.dynamicPrices&&0!=o.suggestions.length){for(s=0;s<o.suggestions.length;s++)if(void 0!==o.suggestions[s].type&&("product"==o.suggestions[s].type||"product_variation"==o.suggestions[s].type)){var n="product__"+o.suggestions[s].post_id;void 0!==o.cachedPrices[n]?o.updatePrice(s,o.cachedPrices[n]):(o.applyPreloaderForPrice(s),a.push(o.suggestions[s].post_id))}if(!e&&a.length>0){var r={action:void 0===dgwt_wcas.action_get_prices?"dgwt_wcas_get_prices":dgwt_wcas.action_get_prices,items:a};t.ajax({data:r,type:"post",url:dgwt_wcas.ajax_prices_endpoint,success:function(t){if(void 0!==t.success&&t.success&&t.data.length>0)for(s=0;s<t.data.length;s++){var e=t.data[s].id,a=t.data[s].price;if(o.suggestions.length>0)for(i=0;i<o.suggestions.length;i++)if(void 0!==o.suggestions[i].type&&("product"==o.suggestions[i].type||"product_variation"==o.suggestions[i].type)&&o.suggestions[i].post_id==e){var n="product__"+e;o.cachedPrices[n]=a,o.updatePrice(i,a)}}},error:function(t,e){}})}}},updatePrice:function(e,s){if(void 0!==this.suggestions[e]){this.suggestions[e].price=s;var i=t(".dgwt-wcas-suggestions-wrapp").find('[data-index="'+e+'"] .dgwt-wcas-sp');i.length&&i.html(s)}},applyCustomParams:function(t){if("object"==typeof dgwt_wcas.custom_params){var e=dgwt_wcas.custom_params;for(var s in e)t[s]=e[s]}var i=this.el.data("custom-params");if("object"==typeof i)for(var s in i)t[s]=i[s];return t},applyPreloaderForPrice:function(e){if(void 0!==this.suggestions[e]){var s=t(".dgwt-wcas-suggestions-wrapp").find('[data-index="'+e+'"] .dgwt-wcas-sp');s.length&&s.html('<div class="dgwt-wcas-preloader-price"><div class="dgwt-wcas-preloader-price-inner"> <div></div><div></div><div></div></div></div>')}},prepareSuggestionObjectID:function(t){var e="";return void 0!==t&&void 0!==t.type&&(null!=t.post_id&&(e=t.type+"__"+t.post_id,"product_variation"===t.type&&(e+="__"+t.variation_id),void 0!==t.post_type&&(e=t.type+"__"+t.post_id+"__"+t.post_type)),null!=t.term_id&&null!=t.taxonomy&&(e=t.type+"__"+t.term_id+"__"+t.taxonomy)),e},selectFirstSuggestion:function(e){var s=0,i=!1;this.canShowDetailsBox()&&("undefined"!=e&&e.length>0&&t.each(this.suggestions,function(t,e){if(void 0!==e.type&&"more_products"!=e.type&&"headline"!=e.type&&"no-results"!=e.type)return s=t,!1;void 0!==e.type&&"no-results"!==e.type||(i=!0)}),i||(this.latestActivateSource="system",this.getDetails(e[s]),this.activate(s)))},isBadQuery:function(t){if(!this.options.preventBadQueries)return!1;for(var e=this.badQueries,s=e.length;s--;)if(0===t.indexOf(e[s]))return!0;return!1},hide:function(e){this.getFormWrapper();var s=this.getSuggestionsContainer(),i=this.getDetailsContainer();t.isFunction(this.options.onHide)&&this.visible&&this.options.onHide.call(this.element,container),this.visible=!1,this.selectedIndex=-1,clearTimeout(this.onChangeTimeout),s.hide(),s.removeClass(this.classes.suggestionsContainerOrientTop),i.hide(),t("body").removeClass("dgwt-wcas-open"),t("body").removeClass("dgwt-wcas-block-scroll"),t("body").removeClass("dgwt-wcas-is-details"),t("body").removeClass("dgwt-wcas-full-width"),t("body").removeClass("dgwt-wcas-nores"),t("body").removeClass("dgwt-wcas-details-outside"),t("body").removeClass("dgwt-wcas-details-right"),t("body").removeClass("dgwt-wcas-details-left"),null!=this.autoAligmentprocess&&(clearInterval(this.autoAligmentprocess),this.autoAligmentprocess=null),"boolean"==typeof e&&e&&(this.hideCloseButton(),this.currentValue="",this.suggestions=[]),this.signalHint(null)},positionIconSearchMode:function(e){var s,i=e.find("."+this.options.formClass),o=i.width(),a=t(window).width(),n=e[0].getBoundingClientRect().left;i[0].getBoundingClientRect().left;var r=(n+10)/a;s=Math.floor(o*r*-1),i.css({left:s+"px"})},hideIconModeSearch:function(){var e=t(".dgwt-wcas-layout-icon-open");e.length>0&&e.removeClass("dgwt-wcas-layout-icon-open")},hideAfterClickOutsideListener:function(){var e=this;e.isMobileMode()||t(document).mouseup(function(s){if(e.visible){e.getSuggestionsContainer(),e.getDetailsContainer();var i=!(t(s.target).closest("."+e.options.searchFormClass).length>0||t(s.target).hasClass(e.options.searchFormClass)),o=!(t(s.target).closest("."+e.options.containerClass).length>0||t(s.target).hasClass(e.options.containerClass));if(e.canShowDetailsBox()){var a=!(t(s.target).closest("."+e.options.containerDetailsClass).length>0||t(s.target).hasClass(e.options.containerDetailsClass));i&&o&&a&&e.hide()}else i&&o&&e.hide()}})},suggest:function(){if(this.suggestions.length){var e,s=this,i=s.options,o=i.groupBy,a=i.formatResult,n=s.getQuery(s.currentValue),r=s.classes.suggestion,l=s.classes.selected,c=s.getSuggestionsContainer(),d=s.getDetailsContainer(),g=t(s.noSuggestionsContainer),u=i.beforeRender,h="";i.triggerSelectOnValidInput&&s.isExactMatch(n)?s.select(0):(t("body").removeClass("dgwt-wcas-nores"),t.each(s.suggestions,function(s,l){var c="",g=!1;if(o&&(h+=function(t,s){var i=t.data[o];return e===i?"":'<div class="autocomplete-group"><strong>'+(e=i)+"</strong></div>"}(l,0)),void 0===l.type||"product"!=l.type&&"product_variation"!=l.type){var u=r,p="dgwt-wcas-st",w="",f="",m="",v=!0;"product_cat"===l.taxonomy?(u+=" dgwt-wcas-suggestion-tax dgwt-wcas-suggestion-cat",i.showHeadings||(w+='<span class="dgwt-wcas-st--direct-headline">'+dgwt_wcas.labels.category+"</span>"),void 0!==l.breadcrumbs&&l.breadcrumbs&&(m=l.breadcrumbs+" > "+l.value,f+='<span class="dgwt-wcas-st-breadcrumbs">'+dgwt_wcas.labels.in+" "+l.breadcrumbs+"</span>")):"product_tag"===l.taxonomy?(u+=" dgwt-wcas-suggestion-tax dgwt-wcas-suggestion-tag",i.showHeadings||(w+='<span class="dgwt-wcas-st--direct-headline">'+dgwt_wcas.labels.tag+"</span>")):i.isPremium&&l.taxonomy===i.taxonomyBrands?(u+=" dgwt-wcas-suggestion-tax dgwt-wcas-suggestion-brand",i.showHeadings||(w+='<span class="dgwt-wcas-st--direct-headline">'+dgwt_wcas.labels.brand+"</span>")):i.isPremium&&"post"===l.type?(u+=" dgwt-wcas-suggestion-pt dgwt-wcas-suggestion-tp-post",i.showHeadings||(w+='<span class="dgwt-wcas-st--direct-headline">'+dgwt_wcas.labels.post+"</span>")):i.isPremium&&"page"===l.type?(u+=" dgwt-wcas-suggestion-pt dgwt-wcas-suggestion-pt-page",i.showHeadings||(w+='<span class="dgwt-wcas-st--direct-headline">'+dgwt_wcas.labels.page+"</span>")):"more_products"===l.type?(u+=" js-dgwt-wcas-suggestion-more dgwt-wcas-suggestion-more",p="dgwt-wcas-st-more",l.value=dgwt_wcas.labels.show_more+" ("+l.total+")",v=!1):i.showHeadings&&"headline"===l.type?(u+=" js-dgwt-wcas-suggestion-headline dgwt-wcas-suggestion-headline",void 0!==dgwt_wcas.labels[l.value+"_plu"]&&(l.value=dgwt_wcas.labels[l.value+"_plu"]),v=!1):(u+=" dgwt-wcas-suggestion-nores",l.value=dgwt_wcas.labels.no_results,v=!1,!0===i.showDetailsPanel&&d.html(""),t("body").addClass("dgwt-wcas-nores")),m=m.length>0?' title="'+m+'"':"",h+='<div class="'+u+'" data-index="'+s+'">',h+="<span"+m+' class="'+p+'">'+w+a(l.value,n,v,i)+f+"</span>",h+="</div>"}else{!0===i.showImage&&void 0!==l.thumb_html&&(g=!0);var C="product_variation"===l.type?" dgwt-wcas-suggestion-product-var":"";c+=void 0!==l.post_id?'data-post-id="'+l.post_id+'" ':"",c+=void 0!==l.taxonomy?'data-taxonomy="'+l.taxonomy+'" ':"",c+=void 0!==l.term_id?'data-term-id="'+l.term_id+'" ':"",h+='<div class="'+r+" dgwt-wcas-suggestion-product"+C+'" data-index="'+s+'" '+c+">",g&&(h+='<span class="dgwt-wcas-si">'+l.thumb_html+"</span>"),h+=g?'<div class="dgwt-wcas-content-wrapp">':"",h+='<span class="dgwt-wcas-st">',h+='<span class="dgwt-wcas-st-title">'+a(l.value,n,!0,i)+"</span>",!0===i.showSKU&&void 0!==l.sku&&l.sku.length>0&&(h+='<span class="dgwt-wcas-sku">('+dgwt_wcas.labels.sku_label+" "+a(l.sku,n,!0,i)+")</span>"),!0===i.showDescription&&void 0!==l.desc&&l.desc&&(h+='<span class="dgwt-wcas-sd">'+a(l.desc,n,!0,i)+"</span>"),h+="</span>",!0===i.showPrice&&void 0!==l.price&&(h+='<span class="dgwt-wcas-sp">'+l.price+"</span>"),!0===i.showFeaturedBadge&&!0===l.on_sale&&(h+='<span class="dgwt-wcas-badge dgwt-wcas-badge-os">'+i.saleBadgeText+"</span>"),!0===i.showFeaturedBadge&&!0===l.featured&&(h+='<span class="dgwt-wcas-badge dgwt-wcas-badge-f">'+i.featuredBadgeText+"</span>"),h+=g?"</div>":"",h+="</div>"}}),this.adjustContainerWidth(),g.detach(),c.html(h),t.isFunction(u)&&u.call(s.element,c,s.suggestions),c.show(),t("body").addClass("dgwt-wcas-open"),s.automaticAlignment(),!0===i.showDetailsPanel&&(t("body").addClass("dgwt-wcas-is-details"),d.show(),s.fixHeight()),i.autoSelectFirst&&(s.selectedIndex=0,c.scrollTop(0),c.children("."+r).first().addClass(l)),s.visible=!0,s.fixPositionCapture(),"top"===s.options.orientation&&(s.getSuggestionsContainer().addClass(s.classes.suggestionsContainerOrientTop),t("body").addClass("dgwt-wcas-block-scroll"),setTimeout(function(){s.scrollDownSuggestions()},300)),s.findBestHint())}else this.hide()},adjustContainerWidth:function(){var e,s=this.options,i=t("body"),o=this.getFormWrapper(),a=this.getSuggestionsContainer(),n=this.getDetailsContainer(),r=this.getFormOffset();if(o.length){var l=getComputedStyle(o[0]).width;if(l=Math.round(parseFloat(l.replace("px",""))),"auto"===s.width&&(e=this.el.outerWidth(),a.css("width",e+"px")),this.canShowDetailsBox()){if(o.width()>=550)return i.addClass("dgwt-wcas-full-width"),l%2==0?(a.css("width",Math.round(l/2)),n.css("width",Math.round(l/2))):(a.css("width",Math.floor(l/2)),n.css("width",Math.ceil(l/2))),i.removeClass("dgwt-wcas-details-left"),i.removeClass("dgwt-wcas-details-right"),void(!0===s.isRtl?n.css("left","0"):a.css("left",l/2+r.left+"px"));i.addClass("dgwt-wcas-details-right")}}},positionPreloader:function(e){var s="object"==typeof e?e.find(".dgwt-wcas-search-submit"):t(".dgwt-wcas-search-submit");s.length>0&&s.each(function(){var e=t(this).closest(".dgwt-wcas-search-wrapp").find(".dgwt-wcas-preloader");1==dgwt_wcas.is_rtl?e.css("left",6+t(this).outerWidth()+"px"):e.css("right",t(this).outerWidth()+"px")})},findBestHint:function(){var e=this.el.val().toLowerCase(),s=null;e&&(t.each(this.suggestions,function(t,i){var o=0===i.value.toLowerCase().indexOf(e);return o&&(s=i),!o}),this.signalHint(s))},signalHint:function(e){var s="";e&&(s=this.currentValue+e.value.substr(this.currentValue.length)),this.hintValue!==s&&(this.hintValue=s,this.hint=e,(this.options.onHint||t.noop)(s))},preloader:function(e,s,i,o){var a,n,r="dgwt-wcas-preloader-wrapp",l=null==i?r:r+" "+i;if("form"===s?n=this.getFormWrapper().find(".dgwt-wcas-preloader"):"details"===s&&(n=this.getDetailsContainer()),1==dgwt_wcas.show_preloader&&0!=n.length)if(!0===o)if("hide"!==e){if("show"===e){var c=this.options.isRtl?"-rtl":"";a='<div class="'+l+'"><img class="dgwt-wcas-placeholder-preloader" src="'+dgwt_wcas.img_url+"placeholder"+c+'.png" /></div>',n.html(a)}}else t(r).remove();else"hide"===e?(n.removeClass(i),n.html("")):(n.addClass(i),"string"==typeof dgwt_wcas.preloader_icon&&n.html(dgwt_wcas.preloader_icon))},verifySuggestionsFormat:function(e){return e.length&&"string"==typeof e[0]?t.map(e,function(t){return{value:t,data:null}}):e},validateOrientation:function(e,s){return e=t.trim(e||"").toLowerCase(),-1===t.inArray(e,["auto","bottom","top"])&&(e=s),e},processResponse:function(t,e,s){var i=this.options;t.suggestions=this.verifySuggestionsFormat(t.suggestions),i.noCache||(this.cachedResponse[s]=t,i.preventBadQueries&&!t.suggestions.length&&this.badQueries.push(e)),e===this.getQuery(this.currentValue)&&("top"===this.options.orientation&&t.suggestions.reverse(),this.suggestions=t.suggestions,this.suggest())},activate:function(e){var s,i=this.classes.selected,o=this.getSuggestionsContainer(),a=o.find("."+this.classes.suggestion);return o.find("."+i).removeClass(i),this.selectedIndex=e,-1!==this.selectedIndex&&a.length>this.selectedIndex?(s=a.get(this.selectedIndex),t(s).addClass(i),s):null},selectHint:function(){var e=t.inArray(this.hint,this.suggestions);this.select(e)},select:function(t){this.hide(),this.onSelect(t)},moveUp:function(){if(-1!==this.selectedIndex){if(this.latestActivateSource="key",0===this.selectedIndex)return this.getSuggestionsContainer().children("."+this.classes.suggestion).first().removeClass(this.classes.selected),this.selectedIndex=-1,this.ignoreValueChange=!1,this.el.val(this.currentValue),void this.findBestHint();this.adjustScroll(this.selectedIndex-1,"up")}},moveDown:function(){this.selectedIndex!==this.suggestions.length-1&&(this.latestActivateSource="key",this.adjustScroll(this.selectedIndex+1,"down"))},adjustScroll:function(e,s){if("headline"===this.suggestions[e].type&&(e="down"===s?e+1:e-1),void 0!==this.suggestions[e]){var i=this.activate(e);if(this.getDetails(this.suggestions[e]),"more_products"!==this.suggestions[e].type&&i&&!this.canShowDetailsBox()){var o,a,n,r=this.getSuggestionsContainer(),l=t(i).outerHeight();o=i.offsetTop,n=(a=r.scrollTop())+this.options.maxHeight-l,o<a?r.scrollTop(o):o>n&&r.scrollTop(o-this.options.maxHeight+l),this.options.preserveInput||(this.ignoreValueChange=!0),this.signalHint(null)}}},onSelect:function(e){var s=this.options.onSelect,i=this.suggestions[e];void 0===i.type||"more_products"!==i.type&&("enter"!==this.actionTriggerSource||"key"==this.latestActivateSource||"product_variation"==i.type)?(this.currentValue=this.getValue(i.value),this.currentValue===this.el.val()||this.options.preserveInput||this.el.val(this.currentValue),i.url.length>0&&(window.location.href=i.url),this.signalHint(null),this.suggestions=[],this.selection=i,t.isFunction(s)&&s.call(this.element,i)):this.el.closest("form").trigger("submit")},getValue:function(t){var e,s,i=this.options.delimiter;return i?1===(s=(e=this.currentValue).split(i)).length?t:e.substr(0,e.length-s[s.length-1].length)+t:t},dispose:function(){this.el.off(".autocomplete").removeData("autocomplete"),t(window).off("resize.autocomplete",this.fixPositionCapture),t("."+this.options.containerClass).remove(),t("."+this.options.containerDetailsClass).remove()},enableOverlayMobile:function(){var e=this;if("on"!==e.overlayMobileState){e.overlayMobileState="on";var s,i=e.getFormWrapper(),o=e.getSuggestionsContainer(),a="";t("html").addClass("dgwt-wcas-overlay-mobile-on"),a+='<div class="js-dgwt-wcas-overlay-mobile dgwt-wcas-overlay-mobile">',a+='<div class="dgwt-wcas-om-bar js-dgwt-wcas-om-bar">',a+='<span class="dgwt-wcas-om-return js-dgwt-wcas-om-return">',"string"==typeof dgwt_wcas.back_icon?a+=dgwt_wcas.back_icon:(a+='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" color="#FFF">',a+='<path fill="#FFF" d="M14 6.125H3.351l4.891-4.891L7 0 0 7l7 7 1.234-1.234L3.35 7.875H14z" fill-rule="evenodd"></path>',a+="</svg>"),a+="</span>",a+="</div>",a+="</div>",t(e.options.mobileOverlayWrapper).append(a),(s=t(".js-dgwt-wcas-overlay-mobile")).css("zIndex",99999999999),i.after('<span class="js-dgwt-wcas-om-hook"></span>'),i.appendTo(".js-dgwt-wcas-om-bar"),o.appendTo(".js-dgwt-wcas-om-bar"),i.addClass("dgwt-wcas-search-wrapp-mobile"),i.hasClass("dgwt-wcas-has-submit")&&(i.addClass("dgwt-wcas-has-submit-off"),i.removeClass("dgwt-wcas-has-submit")),i.find("."+e.options.searchInputClass).focus(),t(document).on("click",".js-dgwt-wcas-om-return",function(t){e.disableOverlayMobile(s)})}},disableOverlayMobile:function(e){var s=this,i=s.getSuggestionsContainer(),o=t(".js-dgwt-wcas-om-bar").find("."+s.options.searchFormClass);o.hasClass("dgwt-wcas-has-submit-off")&&(o.removeClass("dgwt-wcas-has-submit-off"),o.addClass("dgwt-wcas-has-submit")),o.removeClass("dgwt-wcas-search-wrapp-mobile"),t("html").removeClass("dgwt-wcas-overlay-mobile-on"),i.appendTo("body"),i.removeAttr("body-scroll-lock-ignore"),t(".js-dgwt-wcas-om-hook").after(o),t(".js-dgwt-wcas-overlay-mobile").remove(),t(".js-dgwt-wcas-om-hook").remove(),setTimeout(function(){o.find("."+s.options.searchInputClass).val("");var t=o.find(".dgwt-wcas-close");o.length>0&&t.removeClass("dgwt-wcas-close"),s.hide()},150),s.overlayMobileState="off"},showCloseButton:function(){var t=void 0!==dgwt_wcas.close_icon?dgwt_wcas.close_icon:"",e=this.getFormWrapper().find("."+this.options.preloaderClass);e.addClass(this.options.closeTrigger),e.html(t)},hideCloseButton:function(){var t=this.getFormWrapper().find("."+this.options.closeTrigger);t.length&&(t.removeClass(this.options.closeTrigger),t.html(""))},elementOrParentIsFixed:function(e){var s=e.add(e.parents()),i=!1;return s.each(function(){if("fixed"===t(this).css("position"))return i=!0,!1}),i},gaEvent:function(t,e){if(this.options.sendGAEvents)try{if("undefined"!=typeof gtag)gtag("event","autocomplete_search",{event_label:t,event_category:e});else if("undefined"!=typeof ga){var s=ga.getAll()[0];s&&s.send({hitType:"event",eventCategory:e,eventAction:"autocomplete_search",eventLabel:t})}}catch(t){}if(this.options.enableGASiteSearchModule)try{if("undefined"!=typeof gtag)gtag("event","page_view",{page_path:"/?s="+encodeURI(t)+"&post_type=product&dgwt_wcas=1"});else if("undefined"!=typeof ga){var i=ga.getAll()[0];i&&(i.set("page","/?s="+encodeURI(t)+"&post_type=product&dgwt_wcas=1"),i.send("pageview"))}}catch(t){}}},t.fn.dgwtWcasAutocomplete=function(e,s){return arguments.length?this.each(function(){var i=t(this),o=i.data("autocomplete");"string"==typeof e?o&&"function"==typeof o[e]&&o[e](s):(o&&o.dispose&&o.dispose(),o=new d(this,e),i.data("autocomplete",o))}):this.first().data("autocomplete")},t.fn.autocomplete||(t.fn.autocomplete=t.fn.dgwtWcasAutocomplete),function(){function e(){var e=t(".dgwt-wcas-search-input"),s=[];e.length>1&&e.each(function(){var e=t(this).attr("id");if(-1==t.inArray(e,s))s.push(e);else{var i=Math.random().toString(36).substring(2,6);i="dgwt-wcas-search-input-"+i,t(this).attr("id",i),t(this).closest("form").find("label").attr("for",i)}})}function s(){var e=t(".dgwt-wcas-search-input");e.length>0&&e.each(function(){"object"!=typeof t(this).data("autocomplete")&&t(this).dgwtWcasAutocomplete(window.dgwt_wcas.config)})}t(document).ready(function(){(["iPad Simulator","iPhone Simulator","iPod Simulator","iPad","iPhone","iPod"].includes(navigator.platform)||navigator.userAgent.includes("Mac")&&"ontouchend"in document)&&t("html").addClass("dgwt-wcas-is-ios");var e=1==dgwt_wcas.show_details_box,s=dgwt_wcas.mobile_breakpoint;(jQuery(window).width()<s||"ontouchend"in document)&&(e=!1),window.dgwt_wcas.config={minChars:dgwt_wcas.min_chars,width:dgwt_wcas.sug_width,autoSelectFirst:!1,triggerSelectOnValidInput:!1,serviceUrl:dgwt_wcas.ajax_search_endpoint,paramName:"s",showDetailsPanel:e,showImage:1==dgwt_wcas.show_images,showPrice:1==dgwt_wcas.show_price,showDescription:1==dgwt_wcas.show_desc,showSKU:1==dgwt_wcas.show_sku,showSaleBadge:1==dgwt_wcas.show_sale_badge,showFeaturedBadge:1==dgwt_wcas.show_featured_badge,dynamicPrices:!(void 0===dgwt_wcas.dynamic_prices||!dgwt_wcas.dynamic_prices),saleBadgeText:dgwt_wcas.labels.sale_badge,featuredBadgeText:dgwt_wcas.labels.featured_badge,isRtl:1==dgwt_wcas.is_rtl,showHeadings:1==dgwt_wcas.show_headings,isPremium:1==dgwt_wcas.is_premium,taxonomyBrands:dgwt_wcas.taxonomy_brands,mobileBreakpoint:s,mobileOverlayWrapper:dgwt_wcas.mobile_overlay_wrapper,debounceWaitMs:dgwt_wcas.debounce_wait_ms,sendGAEvents:dgwt_wcas.send_ga_events,convertHtml:dgwt_wcas.convert_html,enableGASiteSearchModule:dgwt_wcas.enable_ga_site_search_module},t(".dgwt-wcas-search-input").dgwtWcasAutocomplete(window.dgwt_wcas.config)}),t(document).ready(function(){setTimeout(function(){e(),s()},500)}),t(window).on("load",function(){setTimeout(function(){e(),s()},500),void 0!==window.elementorFrontend&&void 0!==window.elementorFrontend.documentsManager&&void 0!==window.elementorFrontend.documentsManager.documents&&t.each(elementorFrontend.documentsManager.documents,function(t,e){void 0!==e.getModal&&e.getModal&&e.getModal().on("show",function(){setTimeout(function(){s()},300)})})})}()});
|
composer/composer.json
CHANGED
@@ -6,10 +6,7 @@
|
|
6 |
"DgoraWcas\\": "../includes/"
|
7 |
}
|
8 |
},
|
9 |
-
"require": {
|
10 |
-
"mobiledetect/mobiledetectlib": "2.8.34"
|
11 |
-
},
|
12 |
"config": {
|
13 |
"vendor-dir": "../vendor"
|
14 |
}
|
15 |
-
}
|
6 |
"DgoraWcas\\": "../includes/"
|
7 |
}
|
8 |
},
|
|
|
|
|
|
|
9 |
"config": {
|
10 |
"vendor-dir": "../vendor"
|
11 |
}
|
12 |
+
}
|
composer/composer.lock
CHANGED
@@ -4,67 +4,17 @@
|
|
4 |
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
5 |
"This file is @generated automatically"
|
6 |
],
|
7 |
-
"content-hash": "
|
8 |
-
"packages": [
|
9 |
-
{
|
10 |
-
"name": "mobiledetect/mobiledetectlib",
|
11 |
-
"version": "2.8.34",
|
12 |
-
"source": {
|
13 |
-
"type": "git",
|
14 |
-
"url": "https://github.com/serbanghita/Mobile-Detect.git",
|
15 |
-
"reference": "6f8113f57a508494ca36acbcfa2dc2d923c7ed5b"
|
16 |
-
},
|
17 |
-
"dist": {
|
18 |
-
"type": "zip",
|
19 |
-
"url": "https://api.github.com/repos/serbanghita/Mobile-Detect/zipball/6f8113f57a508494ca36acbcfa2dc2d923c7ed5b",
|
20 |
-
"reference": "6f8113f57a508494ca36acbcfa2dc2d923c7ed5b",
|
21 |
-
"shasum": ""
|
22 |
-
},
|
23 |
-
"require": {
|
24 |
-
"php": ">=5.0.0"
|
25 |
-
},
|
26 |
-
"require-dev": {
|
27 |
-
"phpunit/phpunit": "~4.8.35||~5.7"
|
28 |
-
},
|
29 |
-
"type": "library",
|
30 |
-
"autoload": {
|
31 |
-
"classmap": [
|
32 |
-
"Mobile_Detect.php"
|
33 |
-
],
|
34 |
-
"psr-0": {
|
35 |
-
"Detection": "namespaced/"
|
36 |
-
}
|
37 |
-
},
|
38 |
-
"notification-url": "https://packagist.org/downloads/",
|
39 |
-
"license": [
|
40 |
-
"MIT"
|
41 |
-
],
|
42 |
-
"authors": [
|
43 |
-
{
|
44 |
-
"name": "Serban Ghita",
|
45 |
-
"email": "serbanghita@gmail.com",
|
46 |
-
"homepage": "http://mobiledetect.net",
|
47 |
-
"role": "Developer"
|
48 |
-
}
|
49 |
-
],
|
50 |
-
"description": "Mobile_Detect is a lightweight PHP class for detecting mobile devices. It uses the User-Agent string combined with specific HTTP headers to detect the mobile environment.",
|
51 |
-
"homepage": "https://github.com/serbanghita/Mobile-Detect",
|
52 |
-
"keywords": [
|
53 |
-
"detect mobile devices",
|
54 |
-
"mobile",
|
55 |
-
"mobile detect",
|
56 |
-
"mobile detector",
|
57 |
-
"php mobile detect"
|
58 |
-
],
|
59 |
-
"time": "2019-09-18T18:44:20+00:00"
|
60 |
-
}
|
61 |
-
],
|
62 |
"packages-dev": [],
|
63 |
"aliases": [],
|
64 |
"minimum-stability": "stable",
|
65 |
"stability-flags": [],
|
66 |
"prefer-stable": false,
|
67 |
"prefer-lowest": false,
|
68 |
-
"platform":
|
69 |
-
|
|
|
|
|
|
|
70 |
}
|
4 |
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
5 |
"This file is @generated automatically"
|
6 |
],
|
7 |
+
"content-hash": "5c9c989cf6593d916f8d8741c5ea0f43",
|
8 |
+
"packages": [],
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
9 |
"packages-dev": [],
|
10 |
"aliases": [],
|
11 |
"minimum-stability": "stable",
|
12 |
"stability-flags": [],
|
13 |
"prefer-stable": false,
|
14 |
"prefer-lowest": false,
|
15 |
+
"platform": {
|
16 |
+
"php": "~5.5|~7.0"
|
17 |
+
},
|
18 |
+
"platform-dev": [],
|
19 |
+
"plugin-api-version": "2.0.0"
|
20 |
}
|
includes/Admin/Troubleshooting.php
CHANGED
@@ -354,6 +354,52 @@ class Troubleshooting
|
|
354 |
return $result;
|
355 |
}
|
356 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
357 |
/**
|
358 |
* Return a set of tests
|
359 |
*
|
@@ -378,6 +424,10 @@ class Troubleshooting
|
|
378 |
array(
|
379 |
'label' => __( 'Incorrect "Add to cart" behaviour in WooCommerce settings', 'ajax-search-for-woocommerce' ),
|
380 |
'test' => 'AjaxAddToCart',
|
|
|
|
|
|
|
|
|
381 |
)
|
382 |
),
|
383 |
'async' => array( array(
|
@@ -395,14 +445,14 @@ class Troubleshooting
|
|
395 |
/**
|
396 |
* Check requirements
|
397 |
*
|
398 |
-
* We need WordPress 5.
|
399 |
*
|
400 |
* @return bool
|
401 |
*/
|
402 |
private function checkRequirements()
|
403 |
{
|
404 |
global $wp_version ;
|
405 |
-
return version_compare( $wp_version, '5.
|
406 |
}
|
407 |
|
408 |
/**
|
354 |
return $result;
|
355 |
}
|
356 |
|
357 |
+
/**
|
358 |
+
* Tests if "Searching by Text" extension from WOOF - WooCommerce Products Filter is enabled.
|
359 |
+
* It's incompatible with our plugin and should be disabled.
|
360 |
+
*
|
361 |
+
* @return array The test result.
|
362 |
+
*/
|
363 |
+
public function getTestWoofSearchTextExtension()
|
364 |
+
{
|
365 |
+
$result = array(
|
366 |
+
'label' => '',
|
367 |
+
'status' => 'good',
|
368 |
+
'description' => '',
|
369 |
+
'actions' => '',
|
370 |
+
'test' => 'WoofSearchTextExtension',
|
371 |
+
);
|
372 |
+
if ( !defined( 'WOOF_VERSION' ) || !isset( $GLOBALS['WOOF'] ) ) {
|
373 |
+
return $result;
|
374 |
+
}
|
375 |
+
if ( !method_exists( 'WOOF_EXT', 'is_ext_activated' ) ) {
|
376 |
+
return $result;
|
377 |
+
}
|
378 |
+
$extDirs = $GLOBALS['WOOF']->get_ext_directories();
|
379 |
+
if ( empty($extDirs['default']) ) {
|
380 |
+
return $result;
|
381 |
+
}
|
382 |
+
$extPaths = array_filter( $extDirs['default'], function ( $path ) {
|
383 |
+
return strpos( $path, 'ext/by_text' ) !== false;
|
384 |
+
} );
|
385 |
+
if ( empty($extPaths) ) {
|
386 |
+
return $result;
|
387 |
+
}
|
388 |
+
$extPath = array_shift( $extPaths );
|
389 |
+
|
390 |
+
if ( \WOOF_EXT::is_ext_activated( $extPath ) ) {
|
391 |
+
$settingsUrl = admin_url( 'admin.php?page=wc-settings&tab=woof' );
|
392 |
+
$result['label'] = __( 'Incompatible "Searching by Text" extension from WOOF - WooCommerce Products Filter plugin is active', 'ajax-search-for-woocommerce' );
|
393 |
+
$result['description'] = '<p><b>' . __( 'Solution', 'ajax-search-for-woocommerce' ) . '</b></p>';
|
394 |
+
$result['description'] .= '<p>' . sprintf( __( 'Go to <code>WooCommerce -> Settings -> <a href="%s" target="_blank">Products Filter (tab)</a> -> Extensions (tab)</code>, uncheck <code>Searching by Text</code> extension and save changes.', 'ajax-search-for-woocommerce' ), $settingsUrl ) . '</p>';
|
395 |
+
$result['description'] .= __( 'Extensions should looks like the picture below:', 'ajax-search-for-woocommerce' );
|
396 |
+
$result['description'] .= '<p><img style="max-width: 720px" src="' . DGWT_WCAS_URL . 'assets/img/admin-troubleshooting-woof.png" /></p>';
|
397 |
+
$result['status'] = 'critical';
|
398 |
+
}
|
399 |
+
|
400 |
+
return $result;
|
401 |
+
}
|
402 |
+
|
403 |
/**
|
404 |
* Return a set of tests
|
405 |
*
|
424 |
array(
|
425 |
'label' => __( 'Incorrect "Add to cart" behaviour in WooCommerce settings', 'ajax-search-for-woocommerce' ),
|
426 |
'test' => 'AjaxAddToCart',
|
427 |
+
),
|
428 |
+
array(
|
429 |
+
'label' => __( 'Incompatible "Searching by Text" extension in WOOF - WooCommerce Products Filter', 'ajax-search-for-woocommerce' ),
|
430 |
+
'test' => 'WoofSearchTextExtension',
|
431 |
)
|
432 |
),
|
433 |
'async' => array( array(
|
445 |
/**
|
446 |
* Check requirements
|
447 |
*
|
448 |
+
* We need WordPress 5.4 from which the Site Health module is available.
|
449 |
*
|
450 |
* @return bool
|
451 |
*/
|
452 |
private function checkRequirements()
|
453 |
{
|
454 |
global $wp_version ;
|
455 |
+
return version_compare( $wp_version, '5.4.0' ) >= 0;
|
456 |
}
|
457 |
|
458 |
/**
|
includes/Helpers.php
CHANGED
@@ -2,6 +2,7 @@
|
|
2 |
|
3 |
namespace DgoraWcas;
|
4 |
|
|
|
5 |
use DgoraWcas\Engines\TNTSearchMySQL\SearchQuery\SearchResultsPageQuery ;
|
6 |
// Exit if accessed directly
|
7 |
if ( !defined( 'ABSPATH' ) ) {
|
@@ -193,7 +194,13 @@ class Helpers
|
|
193 |
{
|
194 |
$url = esc_url( home_url( '/' ) );
|
195 |
if ( Multilingual::isPolylang() ) {
|
196 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
197 |
}
|
198 |
return apply_filters( 'dgwt/wcas/form/action', $url );
|
199 |
}
|
@@ -507,7 +514,7 @@ class Helpers
|
|
507 |
public static function calcScore( $searched, $string, $args = array() )
|
508 |
{
|
509 |
$score = 0;
|
510 |
-
if ( empty($searched) ) {
|
511 |
return $score;
|
512 |
}
|
513 |
$default = array(
|
@@ -516,8 +523,8 @@ class Helpers
|
|
516 |
'score_containing' => 50,
|
517 |
);
|
518 |
$args = array_merge( $default, $args );
|
519 |
-
$searched =
|
520 |
-
$string =
|
521 |
|
522 |
if ( $args['check_similarity'] ) {
|
523 |
$m = similar_text( $searched, $string, $percent );
|
@@ -714,7 +721,7 @@ class Helpers
|
|
714 |
{
|
715 |
global $wpdb ;
|
716 |
$customFields = array();
|
717 |
-
$
|
718 |
'_sku',
|
719 |
'_wp_old_date',
|
720 |
'_tax_status',
|
@@ -728,21 +735,21 @@ class Helpers
|
|
728 |
'pdf_download',
|
729 |
'slide_template',
|
730 |
'cad_iframe',
|
731 |
-
'
|
732 |
'edrawings_file',
|
733 |
'3d_pdf_download',
|
734 |
'3d_pdf_render',
|
735 |
'_original_id'
|
736 |
);
|
737 |
-
$
|
738 |
$sql = "SELECT DISTINCT meta_key\n FROM {$wpdb->postmeta} as pm\n INNER JOIN {$wpdb->posts} as p ON p.ID = pm.post_id\n WHERE p.post_type = 'product'\n AND pm.meta_value NOT LIKE 'field_%'\n AND pm.meta_value NOT LIKE 'a:%'\n AND pm.meta_value NOT LIKE '%\\%\\%%'\n AND pm.meta_value NOT LIKE '_oembed_%'\n AND pm.meta_value NOT REGEXP '^1[0-9]{9}'\n AND pm.meta_value NOT IN ('1','0','-1','no','yes','[]', '')\n ";
|
739 |
$metaKeys = $wpdb->get_col( $sql );
|
740 |
if ( !empty($metaKeys) ) {
|
741 |
foreach ( $metaKeys as $metaKey ) {
|
742 |
|
743 |
-
if ( !in_array( $metaKey, $
|
744 |
$label = $metaKey;
|
745 |
-
//@TODO Recognize labels based on meta key or
|
746 |
$customFields[] = array(
|
747 |
'label' => $label,
|
748 |
'key' => $label,
|
@@ -752,7 +759,7 @@ class Helpers
|
|
752 |
}
|
753 |
}
|
754 |
$customFields = array_reverse( $customFields );
|
755 |
-
return $customFields;
|
756 |
}
|
757 |
|
758 |
/**
|
@@ -764,7 +771,7 @@ class Helpers
|
|
764 |
*/
|
765 |
public static function keyIsValid( $key )
|
766 |
{
|
767 |
-
return !preg_match( '/[^\\p{L}\\p{N}
|
768 |
}
|
769 |
|
770 |
/**
|
2 |
|
3 |
namespace DgoraWcas;
|
4 |
|
5 |
+
use DgoraWcas\Engines\TNTSearchMySQL\Indexer\Utils ;
|
6 |
use DgoraWcas\Engines\TNTSearchMySQL\SearchQuery\SearchResultsPageQuery ;
|
7 |
// Exit if accessed directly
|
8 |
if ( !defined( 'ABSPATH' ) ) {
|
194 |
{
|
195 |
$url = esc_url( home_url( '/' ) );
|
196 |
if ( Multilingual::isPolylang() ) {
|
197 |
+
|
198 |
+
if ( PLL() instanceof \PLL_Frontend ) {
|
199 |
+
$lang = pll_current_language();
|
200 |
+
$url = ( empty($lang) ? home_url( '/' ) : PLL()->links->get_home_url( $lang, true ) );
|
201 |
+
$url = esc_url( $url );
|
202 |
+
}
|
203 |
+
|
204 |
}
|
205 |
return apply_filters( 'dgwt/wcas/form/action', $url );
|
206 |
}
|
514 |
public static function calcScore( $searched, $string, $args = array() )
|
515 |
{
|
516 |
$score = 0;
|
517 |
+
if ( empty($searched) || empty($string) ) {
|
518 |
return $score;
|
519 |
}
|
520 |
$default = array(
|
523 |
'score_containing' => 50,
|
524 |
);
|
525 |
$args = array_merge( $default, $args );
|
526 |
+
$searched = mb_strtolower( $searched );
|
527 |
+
$string = mb_strtolower( $string );
|
528 |
|
529 |
if ( $args['check_similarity'] ) {
|
530 |
$m = similar_text( $searched, $string, $percent );
|
721 |
{
|
722 |
global $wpdb ;
|
723 |
$customFields = array();
|
724 |
+
$excludedMetaKeys = array(
|
725 |
'_sku',
|
726 |
'_wp_old_date',
|
727 |
'_tax_status',
|
735 |
'pdf_download',
|
736 |
'slide_template',
|
737 |
'cad_iframe',
|
738 |
+
'downloads',
|
739 |
'edrawings_file',
|
740 |
'3d_pdf_download',
|
741 |
'3d_pdf_render',
|
742 |
'_original_id'
|
743 |
);
|
744 |
+
$excludedMetaKeys = apply_filters( 'dgwt/wcas/indexer/excluded_meta_keys', $excludedMetaKeys );
|
745 |
$sql = "SELECT DISTINCT meta_key\n FROM {$wpdb->postmeta} as pm\n INNER JOIN {$wpdb->posts} as p ON p.ID = pm.post_id\n WHERE p.post_type = 'product'\n AND pm.meta_value NOT LIKE 'field_%'\n AND pm.meta_value NOT LIKE 'a:%'\n AND pm.meta_value NOT LIKE '%\\%\\%%'\n AND pm.meta_value NOT LIKE '_oembed_%'\n AND pm.meta_value NOT REGEXP '^1[0-9]{9}'\n AND pm.meta_value NOT IN ('1','0','-1','no','yes','[]', '')\n ";
|
746 |
$metaKeys = $wpdb->get_col( $sql );
|
747 |
if ( !empty($metaKeys) ) {
|
748 |
foreach ( $metaKeys as $metaKey ) {
|
749 |
|
750 |
+
if ( !in_array( $metaKey, $excludedMetaKeys ) && self::keyIsValid( $metaKey ) ) {
|
751 |
$label = $metaKey;
|
752 |
+
//@TODO Recognize labels based on meta key or public known as Yoast SEO etc.
|
753 |
$customFields[] = array(
|
754 |
'label' => $label,
|
755 |
'key' => $label,
|
759 |
}
|
760 |
}
|
761 |
$customFields = array_reverse( $customFields );
|
762 |
+
return apply_filters( 'dgwt/wcas/indexer/searchable_custom_fields', $customFields );
|
763 |
}
|
764 |
|
765 |
/**
|
771 |
*/
|
772 |
public static function keyIsValid( $key )
|
773 |
{
|
774 |
+
return !preg_match( '/[^\\p{L}\\p{N}\\:\\.\\_\\s\\-]+/u', $key );
|
775 |
}
|
776 |
|
777 |
/**
|
includes/Integrations/Themes/Astra/Astra.php
CHANGED
@@ -2,34 +2,22 @@
|
|
2 |
|
3 |
namespace DgoraWcas\Integrations\Themes\Astra;
|
4 |
|
5 |
-
use DgoraWcas\
|
6 |
|
7 |
// Exit if accessed directly
|
8 |
if ( ! defined( 'ABSPATH' ) ) {
|
9 |
exit;
|
10 |
}
|
11 |
|
12 |
-
class Astra {
|
13 |
-
|
14 |
-
private $themeSlug = 'astra';
|
15 |
-
|
16 |
-
private $themeName = 'Astra';
|
17 |
-
|
18 |
public function __construct() {
|
|
|
|
|
|
|
19 |
if ( defined( 'ASTRA_EXT_VER' ) ) {
|
20 |
add_filter( 'dgwt/wcas/suggestion_details/show_quantity', '__return_false' );
|
21 |
}
|
22 |
|
23 |
-
|
24 |
-
?>
|
25 |
-
<style>
|
26 |
-
#dgwt_wcas_basic .submit {
|
27 |
-
display: none !important;
|
28 |
-
}
|
29 |
-
</style>
|
30 |
-
<?php
|
31 |
-
} );
|
32 |
-
|
33 |
}
|
34 |
-
|
35 |
}
|
2 |
|
3 |
namespace DgoraWcas\Integrations\Themes\Astra;
|
4 |
|
5 |
+
use DgoraWcas\Abstracts\ThemeIntegration;
|
6 |
|
7 |
// Exit if accessed directly
|
8 |
if ( ! defined( 'ABSPATH' ) ) {
|
9 |
exit;
|
10 |
}
|
11 |
|
12 |
+
class Astra extends ThemeIntegration {
|
|
|
|
|
|
|
|
|
|
|
13 |
public function __construct() {
|
14 |
+
$this->themeSlug = 'astra';
|
15 |
+
$this->themeName = 'Astra';
|
16 |
+
|
17 |
if ( defined( 'ASTRA_EXT_VER' ) ) {
|
18 |
add_filter( 'dgwt/wcas/suggestion_details/show_quantity', '__return_false' );
|
19 |
}
|
20 |
|
21 |
+
parent::__construct();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
22 |
}
|
|
|
23 |
}
|
includes/Integrations/Themes/Flatsome/Flatsome.php
CHANGED
@@ -113,6 +113,8 @@ class Flatsome {
|
|
113 |
} );
|
114 |
|
115 |
}
|
|
|
|
|
116 |
}
|
117 |
|
118 |
|
@@ -263,7 +265,7 @@ class Flatsome {
|
|
263 |
$(document).on('click', '.mobile-nav .header-search .icon-search', function () {
|
264 |
|
265 |
var $handler = $('.mobile-nav .header-search').find('.js-dgwt-wcas-enable-mobile-form');
|
266 |
-
if($handler.length){
|
267 |
$handler[0].click();
|
268 |
}
|
269 |
});
|
@@ -277,4 +279,34 @@ class Flatsome {
|
|
277 |
|
278 |
}
|
279 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
280 |
}
|
113 |
} );
|
114 |
|
115 |
}
|
116 |
+
|
117 |
+
$this->applyGeneralJS();
|
118 |
}
|
119 |
|
120 |
|
265 |
$(document).on('click', '.mobile-nav .header-search .icon-search', function () {
|
266 |
|
267 |
var $handler = $('.mobile-nav .header-search').find('.js-dgwt-wcas-enable-mobile-form');
|
268 |
+
if ($handler.length) {
|
269 |
$handler[0].click();
|
270 |
}
|
271 |
});
|
279 |
|
280 |
}
|
281 |
|
282 |
+
/**
|
283 |
+
* Apply general JS
|
284 |
+
*
|
285 |
+
* @return void
|
286 |
+
*/
|
287 |
+
private function applyGeneralJS() {
|
288 |
+
|
289 |
+
add_action( 'wp_footer', function () {
|
290 |
+
?>
|
291 |
+
<script>
|
292 |
+
(function ($) {
|
293 |
+
|
294 |
+
// Fix Quantity buttons
|
295 |
+
$(document).on('dgwtWcasDetailsPanelLoaded', function () {
|
296 |
+
var $quantityFields = $('.dgwt-wcas-details-wrapp .quantity');
|
297 |
+
|
298 |
+
if ($quantityFields.length) {
|
299 |
+
$quantityFields.addQty();
|
300 |
+
}
|
301 |
+
|
302 |
+
});
|
303 |
+
|
304 |
+
})(jQuery);
|
305 |
+
|
306 |
+
</script>
|
307 |
+
<?php
|
308 |
+
}, 1001 );
|
309 |
+
|
310 |
+
}
|
311 |
+
|
312 |
}
|
includes/Integrations/Themes/Rehub/Rehub.php
ADDED
@@ -0,0 +1,20 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
namespace DgoraWcas\Integrations\Themes\Rehub;
|
4 |
+
|
5 |
+
use DgoraWcas\Abstracts\ThemeIntegration;
|
6 |
+
|
7 |
+
// Exit if accessed directly
|
8 |
+
if ( ! defined( 'ABSPATH' ) ) {
|
9 |
+
exit;
|
10 |
+
}
|
11 |
+
|
12 |
+
class Rehub extends ThemeIntegration {
|
13 |
+
|
14 |
+
public function __construct() {
|
15 |
+
$this->themeSlug = 'rehub-theme';
|
16 |
+
$this->themeName = 'Rehub';
|
17 |
+
|
18 |
+
parent::__construct();
|
19 |
+
}
|
20 |
+
}
|
includes/Integrations/Themes/Supro/Supro.php
ADDED
@@ -0,0 +1,20 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
namespace DgoraWcas\Integrations\Themes\Supro;
|
4 |
+
|
5 |
+
use DgoraWcas\Abstracts\ThemeIntegration;
|
6 |
+
|
7 |
+
// Exit if accessed directly
|
8 |
+
if ( ! defined( 'ABSPATH' ) ) {
|
9 |
+
exit;
|
10 |
+
}
|
11 |
+
|
12 |
+
class Supro extends ThemeIntegration {
|
13 |
+
|
14 |
+
public function __construct() {
|
15 |
+
$this->themeSlug = 'supro';
|
16 |
+
$this->themeName = 'Supro';
|
17 |
+
|
18 |
+
parent::__construct();
|
19 |
+
}
|
20 |
+
}
|
includes/Integrations/Themes/ThemesCompatibility.php
CHANGED
@@ -140,6 +140,14 @@ class ThemesCompatibility {
|
|
140 |
'slug' => 'konte',
|
141 |
'name' => 'Konte',
|
142 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
143 |
);
|
144 |
}
|
145 |
|
140 |
'slug' => 'konte',
|
141 |
'name' => 'Konte',
|
142 |
),
|
143 |
+
'rehub-theme' => array(
|
144 |
+
'slug' => 'rehub-theme',
|
145 |
+
'name' => 'Rehub',
|
146 |
+
),
|
147 |
+
'supro' => array(
|
148 |
+
'slug' => 'supro',
|
149 |
+
'name' => 'Supro',
|
150 |
+
),
|
151 |
);
|
152 |
}
|
153 |
|
includes/Personalization.php
CHANGED
@@ -94,6 +94,7 @@ class Personalization {
|
|
94 |
.dgwt-wcas-loader-circular-path {
|
95 |
stroke: <?php echo sanitize_text_field( $text_input_color ); ?>;
|
96 |
}
|
|
|
97 |
.dgwt-wcas-preloader {
|
98 |
opacity: 0.6;
|
99 |
}
|
@@ -119,47 +120,23 @@ class Personalization {
|
|
119 |
}
|
120 |
|
121 |
.dgwt-wcas-search-wrapp .dgwt-wcas-ico-magnifier,
|
|
|
122 |
.dgwt-wcas-om-bar .dgwt-wcas-om-return svg path {
|
123 |
<?php echo!empty( $text_submit_color ) ? 'fill: ' . sanitize_text_field( $text_submit_color ) . ';' : ''; ?>
|
124 |
}
|
125 |
|
126 |
<?php endif; ?>
|
127 |
|
128 |
-
<?php
|
129 |
-
// Submit button
|
130 |
-
if ( $show_submit === 'on' && (!empty( $bg_submit_color ) || !empty( $text_submit_color )) ):
|
131 |
-
?>
|
132 |
-
.dgwt-wcas-search-wrapp .dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit::before {
|
133 |
-
<?php echo!empty( $bg_submit_color ) ? 'border-color: transparent ' . sanitize_text_field( $bg_submit_color ) . ';' : ''; ?>
|
134 |
-
}
|
135 |
-
|
136 |
-
.dgwt-wcas-search-wrapp .dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:hover::before,
|
137 |
-
.dgwt-wcas-search-wrapp .dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit:focus::before {
|
138 |
-
<?php echo!empty( $bg_submit_color ) ? 'border-right-color: ' . sanitize_text_field( $bg_submit_color ) . ';' : ''; ?>
|
139 |
-
}
|
140 |
-
|
141 |
-
.dgwt-wcas-search-wrapp .dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit {
|
142 |
-
<?php echo!empty( $bg_submit_color ) ? 'background-color: ' . sanitize_text_field( $bg_submit_color ) . ';' : ''; ?><?php echo!empty( $text_submit_color ) ? 'color: ' . sanitize_text_field( $text_submit_color ) . ';' : ''; ?>
|
143 |
-
}
|
144 |
-
|
145 |
-
.dgwt-wcas-search-wrapp .dgwt-wcas-ico-magnifier {
|
146 |
-
<?php echo!empty( $text_submit_color ) ? 'fill: ' . sanitize_text_field( $text_submit_color ) . ';' : ''; ?>
|
147 |
-
}
|
148 |
-
|
149 |
-
<?php endif; ?>
|
150 |
-
|
151 |
<?php if ( !empty( $sug_bg_color ) ): ?>
|
152 |
.dgwt-wcas-suggestions-wrapp,
|
153 |
-
.dgwt-wcas-details-wrapp
|
154 |
-
{
|
155 |
<?php echo!empty( $sug_bg_color ) ? 'background-color: ' . sanitize_text_field( $sug_bg_color ) . ';' : ''; ?>
|
156 |
}
|
157 |
|
158 |
<?php endif; ?>
|
159 |
|
160 |
<?php if ( !empty( $sug_hover_color ) ): ?>
|
161 |
-
.dgwt-wcas-suggestion-selected
|
162 |
-
{
|
163 |
<?php echo!empty( $sug_hover_color ) ? 'background-color: ' . sanitize_text_field( $sug_hover_color ) . ';' : ''; ?>
|
164 |
}
|
165 |
|
@@ -177,8 +154,7 @@ class Personalization {
|
|
177 |
|
178 |
<?php if ( !empty( $sug_highlight_color ) ): ?>
|
179 |
.dgwt-wcas-st strong,
|
180 |
-
.dgwt-wcas-sd strong
|
181 |
-
{
|
182 |
<?php echo 'color: ' . sanitize_text_field( $sug_highlight_color ) . ';'; ?>
|
183 |
}
|
184 |
|
@@ -199,6 +175,7 @@ class Personalization {
|
|
199 |
.dgwt-wcas-inner-preloader {
|
200 |
background-image: url('<?php echo esc_url( $preloader_url ); ?>');
|
201 |
}
|
|
|
202 |
.dgwt-wcas-inner-preloader * {
|
203 |
display: none;
|
204 |
}
|
94 |
.dgwt-wcas-loader-circular-path {
|
95 |
stroke: <?php echo sanitize_text_field( $text_input_color ); ?>;
|
96 |
}
|
97 |
+
|
98 |
.dgwt-wcas-preloader {
|
99 |
opacity: 0.6;
|
100 |
}
|
120 |
}
|
121 |
|
122 |
.dgwt-wcas-search-wrapp .dgwt-wcas-ico-magnifier,
|
123 |
+
.dgwt-wcas-search-wrapp .dgwt-wcas-sf-wrapp .dgwt-wcas-search-submit svg path,
|
124 |
.dgwt-wcas-om-bar .dgwt-wcas-om-return svg path {
|
125 |
<?php echo!empty( $text_submit_color ) ? 'fill: ' . sanitize_text_field( $text_submit_color ) . ';' : ''; ?>
|
126 |
}
|
127 |
|
128 |
<?php endif; ?>
|
129 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
130 |
<?php if ( !empty( $sug_bg_color ) ): ?>
|
131 |
.dgwt-wcas-suggestions-wrapp,
|
132 |
+
.dgwt-wcas-details-wrapp {
|
|
|
133 |
<?php echo!empty( $sug_bg_color ) ? 'background-color: ' . sanitize_text_field( $sug_bg_color ) . ';' : ''; ?>
|
134 |
}
|
135 |
|
136 |
<?php endif; ?>
|
137 |
|
138 |
<?php if ( !empty( $sug_hover_color ) ): ?>
|
139 |
+
.dgwt-wcas-suggestion-selected {
|
|
|
140 |
<?php echo!empty( $sug_hover_color ) ? 'background-color: ' . sanitize_text_field( $sug_hover_color ) . ';' : ''; ?>
|
141 |
}
|
142 |
|
154 |
|
155 |
<?php if ( !empty( $sug_highlight_color ) ): ?>
|
156 |
.dgwt-wcas-st strong,
|
157 |
+
.dgwt-wcas-sd strong {
|
|
|
158 |
<?php echo 'color: ' . sanitize_text_field( $sug_highlight_color ) . ';'; ?>
|
159 |
}
|
160 |
|
175 |
.dgwt-wcas-inner-preloader {
|
176 |
background-image: url('<?php echo esc_url( $preloader_url ); ?>');
|
177 |
}
|
178 |
+
|
179 |
.dgwt-wcas-inner-preloader * {
|
180 |
display: none;
|
181 |
}
|
includes/Setup.php
CHANGED
@@ -11,7 +11,6 @@ class Setup {
|
|
11 |
|
12 |
public function init() {
|
13 |
add_action( 'init', array( $this, 'setImageSize' ) );
|
14 |
-
add_filter( 'body_class', array( $this, 'addMobileDeviceInfo' ) );
|
15 |
}
|
16 |
|
17 |
/**
|
@@ -22,16 +21,4 @@ class Setup {
|
|
22 |
add_image_size( 'dgwt-wcas-product-suggestion', 64, 0, false );
|
23 |
}
|
24 |
|
25 |
-
public function addMobileDeviceInfo( $classes ) {
|
26 |
-
|
27 |
-
if ( DGWT_WCAS()->mobileDetect->isMobile() ) {
|
28 |
-
$classes[] = 'dgwt-wcas-is-mobile';
|
29 |
-
}
|
30 |
-
if ( DGWT_WCAS()->mobileDetect->isiOS() ) {
|
31 |
-
$classes[] = 'dgwt-wcas-is-ios';
|
32 |
-
}
|
33 |
-
|
34 |
-
return $classes;
|
35 |
-
|
36 |
-
}
|
37 |
}
|
11 |
|
12 |
public function init() {
|
13 |
add_action( 'init', array( $this, 'setImageSize' ) );
|
|
|
14 |
}
|
15 |
|
16 |
/**
|
21 |
add_image_size( 'dgwt-wcas-product-suggestion', 64, 0, false );
|
22 |
}
|
23 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
24 |
}
|
partials/themes/astra.php
ADDED
@@ -0,0 +1,183 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
// Exit if accessed directly
|
3 |
+
if ( ! defined( 'DGWT_WCAS_FILE' ) ) {
|
4 |
+
exit;
|
5 |
+
}
|
6 |
+
|
7 |
+
function dgwt_wcas_astra_header_break_point() {
|
8 |
+
$header_break_point = 921;
|
9 |
+
if ( function_exists( 'astra_header_break_point' ) ) {
|
10 |
+
$header_break_point = astra_header_break_point();
|
11 |
+
}
|
12 |
+
|
13 |
+
return $header_break_point;
|
14 |
+
}
|
15 |
+
|
16 |
+
function dgwt_wcas_astra_search_box() {
|
17 |
+
$search_box = '';
|
18 |
+
if ( function_exists( 'astra_get_option' ) ) {
|
19 |
+
$search_box = astra_get_option( 'header-main-rt-section' );
|
20 |
+
}
|
21 |
+
|
22 |
+
return $search_box;
|
23 |
+
}
|
24 |
+
|
25 |
+
function dgwt_wcas_astra_search_box_style() {
|
26 |
+
$search_box_style = '';
|
27 |
+
if ( function_exists( 'astra_get_option' ) ) {
|
28 |
+
$search_box_style = astra_get_option( 'header-main-rt-section-search-box-type' );
|
29 |
+
}
|
30 |
+
|
31 |
+
return $search_box_style;
|
32 |
+
}
|
33 |
+
|
34 |
+
// Change mobile breakpoint
|
35 |
+
add_filter( 'dgwt/wcas/scripts/mobile_breakpoint', function () {
|
36 |
+
return dgwt_wcas_astra_header_break_point();
|
37 |
+
} );
|
38 |
+
|
39 |
+
// Overwrite search in Slide Search and Search Box mode
|
40 |
+
add_filter( 'astra_get_search_form', function ( $form ) {
|
41 |
+
$header_break_point = dgwt_wcas_astra_header_break_point();
|
42 |
+
$form = '<div class="search-form"><span class="search-field"></span>';
|
43 |
+
$form .= do_shortcode( '[wcas-search-form layout="classic" mobile_overlay="1" mobile_breakpoint="' . $header_break_point . '"]' );
|
44 |
+
$form .= '</div>';
|
45 |
+
|
46 |
+
return $form;
|
47 |
+
} );
|
48 |
+
|
49 |
+
add_action( 'wp_footer', function () {
|
50 |
+
$header_break_point = dgwt_wcas_astra_header_break_point();
|
51 |
+
$search_box = dgwt_wcas_astra_search_box();
|
52 |
+
$search_box_style = dgwt_wcas_astra_search_box_style();
|
53 |
+
|
54 |
+
// Header Cover Search
|
55 |
+
if ( $search_box === 'search' && $search_box_style === 'header-cover' ) {
|
56 |
+
echo '<div id="wcas-search-instance" style="display: block;"><div class="search-form"><div class="search-text-wrap"><input class="search-field" type="text" style="display:none;">' . do_shortcode( '[wcas-search-form layout="classic" mobile_overlay="1" mobile_breakpoint="' . $header_break_point . '" ]' ) . '</div><span id="close" class="close"></span></div></div>';
|
57 |
+
}
|
58 |
+
// Full Screen Search
|
59 |
+
if ( $search_box === 'search' && $search_box_style === 'full-screen' ) {
|
60 |
+
echo '<div id="wcas-search-instance" style="display: block;"><div class="search-form"><input class="search-field" type="text" style="display:none;">' . do_shortcode( '[wcas-search-form layout="classic" mobile_overlay="1" mobile_breakpoint="' . $header_break_point . '" ]' ) . '</div>';
|
61 |
+
}
|
62 |
+
?>
|
63 |
+
<script>
|
64 |
+
(function ($) {
|
65 |
+
<?php if ( $search_box === 'search' && $search_box_style === 'header-cover' ) { ?>
|
66 |
+
// Replace search form (Header Cover Search)
|
67 |
+
$(window).on('load', function () {
|
68 |
+
var wcasSearch = $('#wcas-search-instance > div');
|
69 |
+
var themeSearch = $('.ast-search-box.header-cover .ast-container');
|
70 |
+
if (themeSearch.eq(0)) {
|
71 |
+
themeSearch.html(wcasSearch);
|
72 |
+
}
|
73 |
+
$('#wcas-search-instance').remove();
|
74 |
+
});
|
75 |
+
<?php } ?>
|
76 |
+
|
77 |
+
<?php if ( $search_box === 'search' && $search_box_style === 'full-screen' ) { ?>
|
78 |
+
// Replace search form (Full Screen Search)
|
79 |
+
$(window).on('load', function () {
|
80 |
+
var wcasSearch = $('#wcas-search-instance > div');
|
81 |
+
var themeSearchFull = $('.ast-search-box.full-screen .ast-container');
|
82 |
+
if (themeSearchFull.eq(0)) {
|
83 |
+
themeSearchFull.find('.search-form').remove();
|
84 |
+
themeSearchFull.append(wcasSearch)
|
85 |
+
}
|
86 |
+
$('#wcas-search-instance').remove();
|
87 |
+
});
|
88 |
+
<?php } ?>
|
89 |
+
|
90 |
+
// Autofocus
|
91 |
+
$('.astra-search-icon').on('click', function () {
|
92 |
+
setTimeout(function () {
|
93 |
+
// Slide Search, Search Box
|
94 |
+
var $input = $('.search-custom-menu-item .dgwt-wcas-search-input');
|
95 |
+
if ($input.length > 0) {
|
96 |
+
$input.focus();
|
97 |
+
}
|
98 |
+
|
99 |
+
// Header Cover Search
|
100 |
+
var $inputHeaderCover = $('.ast-search-box.header-cover .dgwt-wcas-search-input');
|
101 |
+
if ($inputHeaderCover.length > 0) {
|
102 |
+
$inputHeaderCover.focus();
|
103 |
+
}
|
104 |
+
|
105 |
+
// Full Screen Search
|
106 |
+
var $inputFullScreen = $('.ast-search-box.full-screen .dgwt-wcas-search-input');
|
107 |
+
if ($inputFullScreen.length > 0) {
|
108 |
+
$inputFullScreen.focus();
|
109 |
+
}
|
110 |
+
}, 100);
|
111 |
+
|
112 |
+
if ($(window).width() <= <?php echo $header_break_point ?>) {
|
113 |
+
// Slide Search, Search Box
|
114 |
+
var $mobile = $('.search-custom-menu-item .js-dgwt-wcas-enable-mobile-form');
|
115 |
+
if ($mobile.length > 0) {
|
116 |
+
$mobile.click();
|
117 |
+
}
|
118 |
+
|
119 |
+
// Header Cover Search / Full Screen Search
|
120 |
+
var $mobile2 = $('.ast-search-box.header-cover .js-dgwt-wcas-enable-mobile-form, .ast-search-box.full-screen .js-dgwt-wcas-enable-mobile-form');
|
121 |
+
if ($mobile2.length > 0) {
|
122 |
+
$mobile2.click();
|
123 |
+
}
|
124 |
+
}
|
125 |
+
});
|
126 |
+
|
127 |
+
// Header Cover / Full Screen Search - close cover when in mobile mode
|
128 |
+
$(document).on('click', '.js-dgwt-wcas-om-return', function (e) {
|
129 |
+
$('.ast-search-box.header-cover #close, .ast-search-box.full-screen #close').click();
|
130 |
+
});
|
131 |
+
}(jQuery));
|
132 |
+
</script>
|
133 |
+
<?php
|
134 |
+
} );
|
135 |
+
|
136 |
+
add_filter( 'wp_head', function () {
|
137 |
+
?>
|
138 |
+
<style>
|
139 |
+
/* Slide Search */
|
140 |
+
.ast-dropdown-active .search-form {
|
141 |
+
padding-left: 0 !important;
|
142 |
+
}
|
143 |
+
|
144 |
+
.ast-dropdown-active .ast-search-icon {
|
145 |
+
visibility: hidden;
|
146 |
+
}
|
147 |
+
|
148 |
+
.ast-search-menu-icon .search-form {
|
149 |
+
padding: 0;
|
150 |
+
}
|
151 |
+
|
152 |
+
.search-custom-menu-item .search-field {
|
153 |
+
display: none;
|
154 |
+
}
|
155 |
+
|
156 |
+
.search-custom-menu-item .search-form {
|
157 |
+
background-color: transparent !important;
|
158 |
+
border: 0;
|
159 |
+
}
|
160 |
+
|
161 |
+
/* Search Box */
|
162 |
+
.site-header .ast-inline-search.ast-search-menu-icon .search-form {
|
163 |
+
padding-right: 0;
|
164 |
+
}
|
165 |
+
|
166 |
+
/* Full Screen Search */
|
167 |
+
.ast-search-box.full-screen .ast-search-wrapper {
|
168 |
+
top: 25%;
|
169 |
+
transform: translate(-50%, -25%);
|
170 |
+
}
|
171 |
+
</style>
|
172 |
+
<?php
|
173 |
+
} );
|
174 |
+
|
175 |
+
add_action( 'admin_head', function () {
|
176 |
+
?>
|
177 |
+
<style>
|
178 |
+
#dgwt_wcas_basic .submit {
|
179 |
+
display: none !important;
|
180 |
+
}
|
181 |
+
</style>
|
182 |
+
<?php
|
183 |
+
} );
|
partials/themes/divi.php
CHANGED
@@ -10,6 +10,7 @@ add_action( 'wp_footer', function () {
|
|
10 |
?>
|
11 |
<script>
|
12 |
(function ($) {
|
|
|
13 |
$(window).on('load', function () {
|
14 |
var body = $('body');
|
15 |
var diviSearch = $('.et-search-form');
|
@@ -72,23 +73,21 @@ add_action( 'wp_footer', function () {
|
|
72 |
add_action( 'wp_head', function () {
|
73 |
?>
|
74 |
<style>
|
|
|
|
|
|
|
75 |
/* Header style: Default, Centered Inline Logo */
|
76 |
.et_header_style_split .et_search_form_container .dgwt-wcas-search-wrapp,
|
77 |
.et_header_style_left .et_search_form_container .dgwt-wcas-search-wrapp {
|
78 |
max-width: 400px;
|
79 |
top: 0;
|
80 |
bottom: 0;
|
81 |
-
right:
|
82 |
position: absolute;
|
83 |
z-index: 1000;
|
84 |
width: 100%;
|
85 |
}
|
86 |
|
87 |
-
.et_header_style_split .et_search_form_container .dgwt-wcas-preloader,
|
88 |
-
.et_header_style_left .et_search_form_container .dgwt-wcas-preloader {
|
89 |
-
right: 20px;
|
90 |
-
}
|
91 |
-
|
92 |
.et_header_style_split .et_search_form_container .dgwt-wcas-close:not(.dgwt-wcas-inner-preloader),
|
93 |
.et_header_style_left .et_search_form_container .dgwt-wcas-close:not(.dgwt-wcas-inner-preloader) {
|
94 |
background-image: none;
|
10 |
?>
|
11 |
<script>
|
12 |
(function ($) {
|
13 |
+
|
14 |
$(window).on('load', function () {
|
15 |
var body = $('body');
|
16 |
var diviSearch = $('.et-search-form');
|
73 |
add_action( 'wp_head', function () {
|
74 |
?>
|
75 |
<style>
|
76 |
+
#wcas-divi-search {
|
77 |
+
display: none!important;
|
78 |
+
}
|
79 |
/* Header style: Default, Centered Inline Logo */
|
80 |
.et_header_style_split .et_search_form_container .dgwt-wcas-search-wrapp,
|
81 |
.et_header_style_left .et_search_form_container .dgwt-wcas-search-wrapp {
|
82 |
max-width: 400px;
|
83 |
top: 0;
|
84 |
bottom: 0;
|
85 |
+
right: 45px;
|
86 |
position: absolute;
|
87 |
z-index: 1000;
|
88 |
width: 100%;
|
89 |
}
|
90 |
|
|
|
|
|
|
|
|
|
|
|
91 |
.et_header_style_split .et_search_form_container .dgwt-wcas-close:not(.dgwt-wcas-inner-preloader),
|
92 |
.et_header_style_left .et_search_form_container .dgwt-wcas-close:not(.dgwt-wcas-inner-preloader) {
|
93 |
background-image: none;
|
partials/themes/rehub-theme.php
ADDED
@@ -0,0 +1,53 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
// Exit if accessed directly
|
3 |
+
if ( ! defined( 'DGWT_WCAS_FILE' ) ) {
|
4 |
+
exit;
|
5 |
+
}
|
6 |
+
|
7 |
+
// Change mobile breakpoint
|
8 |
+
add_filter( 'dgwt/wcas/scripts/mobile_breakpoint', function () {
|
9 |
+
return 1024;
|
10 |
+
} );
|
11 |
+
|
12 |
+
add_action( 'wp_footer', function () {
|
13 |
+
echo '<div id="wcas-search-instance" style="display: block;">' . do_shortcode( '[wcas-search-form layout="classic" mobile_overlay="1" mobile_breakpoint="1024" ]' ) . '</div>';
|
14 |
+
echo '<div id="wcas-search-icon-instance" style="display: block;">' . do_shortcode( '[wcas-search-form layout="classic" mobile_overlay="1" mobile_breakpoint="1024" ]' ) . '</div>';
|
15 |
+
?>
|
16 |
+
<script>
|
17 |
+
var themeSearch = document.querySelector('#main_header .head_search');
|
18 |
+
if (themeSearch !== null) {
|
19 |
+
themeSearch.innerHTML = '';
|
20 |
+
themeSearch.append(document.querySelector('#wcas-search-instance > div'))
|
21 |
+
}
|
22 |
+
document.querySelector('#wcas-search-instance').remove();
|
23 |
+
|
24 |
+
var themeSearchPopup = document.querySelector('.search-header-contents');
|
25 |
+
if (themeSearchPopup !== null) {
|
26 |
+
themeSearchPopup.innerHTML = '';
|
27 |
+
themeSearchPopup.append(document.querySelector('#wcas-search-icon-instance > div'));
|
28 |
+
}
|
29 |
+
document.querySelector('#wcas-search-icon-instance').remove();
|
30 |
+
|
31 |
+
(function ($) {
|
32 |
+
$(window).on('load', function () {
|
33 |
+
$('.icon-search-onclick').on('click', function () {
|
34 |
+
// Autofocus
|
35 |
+
if ($(window).width() >= 1024) {
|
36 |
+
setTimeout(function () {
|
37 |
+
var $input = $('.search-header-contents .dgwt-wcas-search-input');
|
38 |
+
if ($input.length > 0) {
|
39 |
+
$input.focus();
|
40 |
+
}
|
41 |
+
}, 500);
|
42 |
+
} else {
|
43 |
+
var $mobile = $('.search-header-contents .js-dgwt-wcas-enable-mobile-form');
|
44 |
+
if ($mobile.length > 0) {
|
45 |
+
$mobile.click();
|
46 |
+
}
|
47 |
+
}
|
48 |
+
});
|
49 |
+
});
|
50 |
+
}(jQuery));
|
51 |
+
</script>
|
52 |
+
<?php
|
53 |
+
} );
|
partials/themes/supro.php
ADDED
@@ -0,0 +1,39 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
// Exit if accessed directly
|
3 |
+
if ( ! defined( 'DGWT_WCAS_FILE' ) ) {
|
4 |
+
exit;
|
5 |
+
}
|
6 |
+
|
7 |
+
if ( ! function_exists( 'supro_extra_search' ) ) {
|
8 |
+
function supro_extra_search() {
|
9 |
+
$extras = supro_get_menu_extras();
|
10 |
+
|
11 |
+
if ( empty( $extras ) ) {
|
12 |
+
return;
|
13 |
+
}
|
14 |
+
|
15 |
+
if ( ! in_array( 'search', $extras ) ) {
|
16 |
+
return;
|
17 |
+
}
|
18 |
+
|
19 |
+
$form = do_shortcode( '[wcas-search-form layout="icon" mobile_overlay="1"]' );
|
20 |
+
|
21 |
+
echo sprintf(
|
22 |
+
'<li class="extra-menu-item menu-item-search">%s</li>',
|
23 |
+
$form
|
24 |
+
);
|
25 |
+
}
|
26 |
+
}
|
27 |
+
|
28 |
+
add_action( 'wp_footer', function () {
|
29 |
+
?>
|
30 |
+
<style>
|
31 |
+
.header-layout-1 .site-header .menu-extra.menu-extra-au .menu-item-search {
|
32 |
+
display: none;
|
33 |
+
}
|
34 |
+
.site-header .menu-extra.s-right .menu-item-search .dgwt-wcas-search-wrapp {
|
35 |
+
margin-top: -3px;
|
36 |
+
}
|
37 |
+
</style>
|
38 |
+
<?php
|
39 |
+
} );
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Tags: woocommerce search, ajax search, search by sku, product search, woocommerc
|
|
4 |
Requires at least: 5.0
|
5 |
Tested up to: 5.6
|
6 |
Requires PHP: 5.5
|
7 |
-
Stable tag: 1.8.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -140,6 +140,20 @@ You can read more and compare Pro and Free features here: [feature comparison](h
|
|
140 |
|
141 |
== Changelog ==
|
142 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
143 |
= 1.8.0, October 23, 2020 =
|
144 |
* ADD: Support for Sober theme
|
145 |
* ADD: Support for Divi theme
|
4 |
Requires at least: 5.0
|
5 |
Tested up to: 5.6
|
6 |
Requires PHP: 5.5
|
7 |
+
Stable tag: 1.8.1
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
140 |
|
141 |
== Changelog ==
|
142 |
|
143 |
+
= 1.8.1, December 04, 2020 =
|
144 |
+
* ADD: Support for Rehub theme
|
145 |
+
* ADD: Support for Supro theme
|
146 |
+
* FIX: Troubleshooting module improvements
|
147 |
+
* FIX: Blinking suggestions
|
148 |
+
* FIX: Bug in icon colors
|
149 |
+
* FIX: Flatsome theme - quantity buttons issue
|
150 |
+
* FIX: Divi theme - hide extra search bar in footer
|
151 |
+
* FIX: Mobile overlay improvements for iPhones
|
152 |
+
* FIX: Better suggestion order for non latin letters
|
153 |
+
* FIX: Action URL in search form when Polylang is active
|
154 |
+
* REMOVE: Mobile Detect library
|
155 |
+
|
156 |
+
|
157 |
= 1.8.0, October 23, 2020 =
|
158 |
* ADD: Support for Sober theme
|
159 |
* ADD: Support for Divi theme
|
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 ComposerAutoloaderInit765647f7aee7e9065fbac560f20a7f60::getLoader();
|
vendor/composer/ClassLoader.php
CHANGED
@@ -37,8 +37,8 @@ namespace Composer\Autoload;
|
|
37 |
*
|
38 |
* @author Fabien Potencier <fabien@symfony.com>
|
39 |
* @author Jordi Boggiano <j.boggiano@seld.be>
|
40 |
-
* @see
|
41 |
-
* @see
|
42 |
*/
|
43 |
class ClassLoader
|
44 |
{
|
@@ -60,7 +60,7 @@ class ClassLoader
|
|
60 |
public function getPrefixes()
|
61 |
{
|
62 |
if (!empty($this->prefixesPsr0)) {
|
63 |
-
return call_user_func_array('array_merge', $this->prefixesPsr0);
|
64 |
}
|
65 |
|
66 |
return array();
|
37 |
*
|
38 |
* @author Fabien Potencier <fabien@symfony.com>
|
39 |
* @author Jordi Boggiano <j.boggiano@seld.be>
|
40 |
+
* @see https://www.php-fig.org/psr/psr-0/
|
41 |
+
* @see https://www.php-fig.org/psr/psr-4/
|
42 |
*/
|
43 |
class ClassLoader
|
44 |
{
|
60 |
public function getPrefixes()
|
61 |
{
|
62 |
if (!empty($this->prefixesPsr0)) {
|
63 |
+
return call_user_func_array('array_merge', array_values($this->prefixesPsr0));
|
64 |
}
|
65 |
|
66 |
return array();
|
vendor/composer/InstalledVersions.php
ADDED
@@ -0,0 +1,209 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
namespace Composer;
|
4 |
+
|
5 |
+
use Composer\Semver\VersionParser;
|
6 |
+
|
7 |
+
|
8 |
+
|
9 |
+
|
10 |
+
|
11 |
+
|
12 |
+
class InstalledVersions
|
13 |
+
{
|
14 |
+
private static $installed = array (
|
15 |
+
'root' =>
|
16 |
+
array (
|
17 |
+
'pretty_version' => '1.0.0+no-version-set',
|
18 |
+
'version' => '1.0.0.0',
|
19 |
+
'aliases' =>
|
20 |
+
array (
|
21 |
+
),
|
22 |
+
'reference' => NULL,
|
23 |
+
'name' => 'dgora/ajax-search-for-woocommerce',
|
24 |
+
),
|
25 |
+
'versions' =>
|
26 |
+
array (
|
27 |
+
'dgora/ajax-search-for-woocommerce' =>
|
28 |
+
array (
|
29 |
+
'pretty_version' => '1.0.0+no-version-set',
|
30 |
+
'version' => '1.0.0.0',
|
31 |
+
'aliases' =>
|
32 |
+
array (
|
33 |
+
),
|
34 |
+
'reference' => NULL,
|
35 |
+
),
|
36 |
+
),
|
37 |
+
);
|
38 |
+
|
39 |
+
|
40 |
+
|
41 |
+
|
42 |
+
|
43 |
+
|
44 |
+
|
45 |
+
public static function getInstalledPackages()
|
46 |
+
{
|
47 |
+
return array_keys(self::$installed['versions']);
|
48 |
+
}
|
49 |
+
|
50 |
+
|
51 |
+
|
52 |
+
|
53 |
+
|
54 |
+
|
55 |
+
|
56 |
+
|
57 |
+
|
58 |
+
public static function isInstalled($packageName)
|
59 |
+
{
|
60 |
+
return isset(self::$installed['versions'][$packageName]);
|
61 |
+
}
|
62 |
+
|
63 |
+
|
64 |
+
|
65 |
+
|
66 |
+
|
67 |
+
|
68 |
+
|
69 |
+
|
70 |
+
|
71 |
+
|
72 |
+
|
73 |
+
|
74 |
+
|
75 |
+
|
76 |
+
public static function satisfies(VersionParser $parser, $packageName, $constraint)
|
77 |
+
{
|
78 |
+
$constraint = $parser->parseConstraints($constraint);
|
79 |
+
$provided = $parser->parseConstraints(self::getVersionRanges($packageName));
|
80 |
+
|
81 |
+
return $provided->matches($constraint);
|
82 |
+
}
|
83 |
+
|
84 |
+
|
85 |
+
|
86 |
+
|
87 |
+
|
88 |
+
|
89 |
+
|
90 |
+
|
91 |
+
|
92 |
+
|
93 |
+
public static function getVersionRanges($packageName)
|
94 |
+
{
|
95 |
+
if (!isset(self::$installed['versions'][$packageName])) {
|
96 |
+
throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');
|
97 |
+
}
|
98 |
+
|
99 |
+
$ranges = array();
|
100 |
+
if (isset(self::$installed['versions'][$packageName]['pretty_version'])) {
|
101 |
+
$ranges[] = self::$installed['versions'][$packageName]['pretty_version'];
|
102 |
+
}
|
103 |
+
if (array_key_exists('aliases', self::$installed['versions'][$packageName])) {
|
104 |
+
$ranges = array_merge($ranges, self::$installed['versions'][$packageName]['aliases']);
|
105 |
+
}
|
106 |
+
if (array_key_exists('replaced', self::$installed['versions'][$packageName])) {
|
107 |
+
$ranges = array_merge($ranges, self::$installed['versions'][$packageName]['replaced']);
|
108 |
+
}
|
109 |
+
if (array_key_exists('provided', self::$installed['versions'][$packageName])) {
|
110 |
+
$ranges = array_merge($ranges, self::$installed['versions'][$packageName]['provided']);
|
111 |
+
}
|
112 |
+
|
113 |
+
return implode(' || ', $ranges);
|
114 |
+
}
|
115 |
+
|
116 |
+
|
117 |
+
|
118 |
+
|
119 |
+
|
120 |
+
public static function getVersion($packageName)
|
121 |
+
{
|
122 |
+
if (!isset(self::$installed['versions'][$packageName])) {
|
123 |
+
throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');
|
124 |
+
}
|
125 |
+
|
126 |
+
if (!isset(self::$installed['versions'][$packageName]['version'])) {
|
127 |
+
return null;
|
128 |
+
}
|
129 |
+
|
130 |
+
return self::$installed['versions'][$packageName]['version'];
|
131 |
+
}
|
132 |
+
|
133 |
+
|
134 |
+
|
135 |
+
|
136 |
+
|
137 |
+
public static function getPrettyVersion($packageName)
|
138 |
+
{
|
139 |
+
if (!isset(self::$installed['versions'][$packageName])) {
|
140 |
+
throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');
|
141 |
+
}
|
142 |
+
|
143 |
+
if (!isset(self::$installed['versions'][$packageName]['pretty_version'])) {
|
144 |
+
return null;
|
145 |
+
}
|
146 |
+
|
147 |
+
return self::$installed['versions'][$packageName]['pretty_version'];
|
148 |
+
}
|
149 |
+
|
150 |
+
|
151 |
+
|
152 |
+
|
153 |
+
|
154 |
+
public static function getReference($packageName)
|
155 |
+
{
|
156 |
+
if (!isset(self::$installed['versions'][$packageName])) {
|
157 |
+
throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');
|
158 |
+
}
|
159 |
+
|
160 |
+
if (!isset(self::$installed['versions'][$packageName]['reference'])) {
|
161 |
+
return null;
|
162 |
+
}
|
163 |
+
|
164 |
+
return self::$installed['versions'][$packageName]['reference'];
|
165 |
+
}
|
166 |
+
|
167 |
+
|
168 |
+
|
169 |
+
|
170 |
+
|
171 |
+
public static function getRootPackage()
|
172 |
+
{
|
173 |
+
return self::$installed['root'];
|
174 |
+
}
|
175 |
+
|
176 |
+
|
177 |
+
|
178 |
+
|
179 |
+
|
180 |
+
|
181 |
+
|
182 |
+
public static function getRawData()
|
183 |
+
{
|
184 |
+
return self::$installed;
|
185 |
+
}
|
186 |
+
|
187 |
+
|
188 |
+
|
189 |
+
|
190 |
+
|
191 |
+
|
192 |
+
|
193 |
+
|
194 |
+
|
195 |
+
|
196 |
+
|
197 |
+
|
198 |
+
|
199 |
+
|
200 |
+
|
201 |
+
|
202 |
+
|
203 |
+
|
204 |
+
|
205 |
+
public static function reload($data)
|
206 |
+
{
|
207 |
+
self::$installed = $data;
|
208 |
+
}
|
209 |
+
}
|
vendor/composer/autoload_classmap.php
CHANGED
@@ -6,5 +6,5 @@ $vendorDir = dirname(dirname(__FILE__));
|
|
6 |
$baseDir = dirname($vendorDir).'/composer';
|
7 |
|
8 |
return array(
|
9 |
-
'
|
10 |
);
|
6 |
$baseDir = dirname($vendorDir).'/composer';
|
7 |
|
8 |
return array(
|
9 |
+
'Composer\\InstalledVersions' => $vendorDir . '/composer/InstalledVersions.php',
|
10 |
);
|
vendor/composer/autoload_namespaces.php
CHANGED
@@ -6,5 +6,4 @@ $vendorDir = dirname(dirname(__FILE__));
|
|
6 |
$baseDir = dirname($vendorDir).'/composer';
|
7 |
|
8 |
return array(
|
9 |
-
'Detection' => array($vendorDir . '/mobiledetect/mobiledetectlib/namespaced'),
|
10 |
);
|
6 |
$baseDir = dirname($vendorDir).'/composer';
|
7 |
|
8 |
return array(
|
|
|
9 |
);
|
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 |
|
@@ -13,21 +13,24 @@ class ComposerAutoloaderInitca6b3ab2a3db9f21bb7ad9197b22b2fe
|
|
13 |
}
|
14 |
}
|
15 |
|
|
|
|
|
|
|
16 |
public static function getLoader()
|
17 |
{
|
18 |
if (null !== self::$loader) {
|
19 |
return self::$loader;
|
20 |
}
|
21 |
|
22 |
-
spl_autoload_register(array('
|
23 |
self::$loader = $loader = new \Composer\Autoload\ClassLoader();
|
24 |
-
spl_autoload_unregister(array('
|
25 |
|
26 |
$useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
|
27 |
if ($useStaticLoader) {
|
28 |
-
|
29 |
|
30 |
-
call_user_func(\Composer\Autoload\
|
31 |
} else {
|
32 |
$map = require __DIR__ . '/autoload_namespaces.php';
|
33 |
foreach ($map as $namespace => $path) {
|
2 |
|
3 |
// autoload_real.php @generated by Composer
|
4 |
|
5 |
+
class ComposerAutoloaderInit765647f7aee7e9065fbac560f20a7f60
|
6 |
{
|
7 |
private static $loader;
|
8 |
|
13 |
}
|
14 |
}
|
15 |
|
16 |
+
/**
|
17 |
+
* @return \Composer\Autoload\ClassLoader
|
18 |
+
*/
|
19 |
public static function getLoader()
|
20 |
{
|
21 |
if (null !== self::$loader) {
|
22 |
return self::$loader;
|
23 |
}
|
24 |
|
25 |
+
spl_autoload_register(array('ComposerAutoloaderInit765647f7aee7e9065fbac560f20a7f60', 'loadClassLoader'), true, true);
|
26 |
self::$loader = $loader = new \Composer\Autoload\ClassLoader();
|
27 |
+
spl_autoload_unregister(array('ComposerAutoloaderInit765647f7aee7e9065fbac560f20a7f60', '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\ComposerStaticInit765647f7aee7e9065fbac560f20a7f60::getInitializer($loader));
|
34 |
} else {
|
35 |
$map = require __DIR__ . '/autoload_namespaces.php';
|
36 |
foreach ($map as $namespace => $path) {
|
vendor/composer/autoload_static.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
|
5 |
namespace Composer\Autoload;
|
6 |
|
7 |
-
class
|
8 |
{
|
9 |
public static $prefixLengthsPsr4 = array (
|
10 |
'D' =>
|
@@ -20,27 +20,16 @@ class ComposerStaticInitca6b3ab2a3db9f21bb7ad9197b22b2fe
|
|
20 |
),
|
21 |
);
|
22 |
|
23 |
-
public static $prefixesPsr0 = array (
|
24 |
-
'D' =>
|
25 |
-
array (
|
26 |
-
'Detection' =>
|
27 |
-
array (
|
28 |
-
0 => __DIR__ . '/..' . '/mobiledetect/mobiledetectlib/namespaced',
|
29 |
-
),
|
30 |
-
),
|
31 |
-
);
|
32 |
-
|
33 |
public static $classMap = array (
|
34 |
-
'
|
35 |
);
|
36 |
|
37 |
public static function getInitializer(ClassLoader $loader)
|
38 |
{
|
39 |
return \Closure::bind(function () use ($loader) {
|
40 |
-
$loader->prefixLengthsPsr4 =
|
41 |
-
$loader->prefixDirsPsr4 =
|
42 |
-
$loader->
|
43 |
-
$loader->classMap = ComposerStaticInitca6b3ab2a3db9f21bb7ad9197b22b2fe::$classMap;
|
44 |
|
45 |
}, null, ClassLoader::class);
|
46 |
}
|
4 |
|
5 |
namespace Composer\Autoload;
|
6 |
|
7 |
+
class ComposerStaticInit765647f7aee7e9065fbac560f20a7f60
|
8 |
{
|
9 |
public static $prefixLengthsPsr4 = array (
|
10 |
'D' =>
|
20 |
),
|
21 |
);
|
22 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
23 |
public static $classMap = array (
|
24 |
+
'Composer\\InstalledVersions' => __DIR__ . '/..' . '/composer/InstalledVersions.php',
|
25 |
);
|
26 |
|
27 |
public static function getInitializer(ClassLoader $loader)
|
28 |
{
|
29 |
return \Closure::bind(function () use ($loader) {
|
30 |
+
$loader->prefixLengthsPsr4 = ComposerStaticInit765647f7aee7e9065fbac560f20a7f60::$prefixLengthsPsr4;
|
31 |
+
$loader->prefixDirsPsr4 = ComposerStaticInit765647f7aee7e9065fbac560f20a7f60::$prefixDirsPsr4;
|
32 |
+
$loader->classMap = ComposerStaticInit765647f7aee7e9065fbac560f20a7f60::$classMap;
|
|
|
33 |
|
34 |
}, null, ClassLoader::class);
|
35 |
}
|
vendor/composer/installed.json
CHANGED
@@ -1,56 +1,5 @@
|
|
1 |
-
|
2 |
-
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
"source": {
|
7 |
-
"type": "git",
|
8 |
-
"url": "https://github.com/serbanghita/Mobile-Detect.git",
|
9 |
-
"reference": "6f8113f57a508494ca36acbcfa2dc2d923c7ed5b"
|
10 |
-
},
|
11 |
-
"dist": {
|
12 |
-
"type": "zip",
|
13 |
-
"url": "https://api.github.com/repos/serbanghita/Mobile-Detect/zipball/6f8113f57a508494ca36acbcfa2dc2d923c7ed5b",
|
14 |
-
"reference": "6f8113f57a508494ca36acbcfa2dc2d923c7ed5b",
|
15 |
-
"shasum": ""
|
16 |
-
},
|
17 |
-
"require": {
|
18 |
-
"php": ">=5.0.0"
|
19 |
-
},
|
20 |
-
"require-dev": {
|
21 |
-
"phpunit/phpunit": "~4.8.35||~5.7"
|
22 |
-
},
|
23 |
-
"time": "2019-09-18T18:44:20+00:00",
|
24 |
-
"type": "library",
|
25 |
-
"installation-source": "dist",
|
26 |
-
"autoload": {
|
27 |
-
"classmap": [
|
28 |
-
"Mobile_Detect.php"
|
29 |
-
],
|
30 |
-
"psr-0": {
|
31 |
-
"Detection": "namespaced/"
|
32 |
-
}
|
33 |
-
},
|
34 |
-
"notification-url": "https://packagist.org/downloads/",
|
35 |
-
"license": [
|
36 |
-
"MIT"
|
37 |
-
],
|
38 |
-
"authors": [
|
39 |
-
{
|
40 |
-
"name": "Serban Ghita",
|
41 |
-
"email": "serbanghita@gmail.com",
|
42 |
-
"homepage": "http://mobiledetect.net",
|
43 |
-
"role": "Developer"
|
44 |
-
}
|
45 |
-
],
|
46 |
-
"description": "Mobile_Detect is a lightweight PHP class for detecting mobile devices. It uses the User-Agent string combined with specific HTTP headers to detect the mobile environment.",
|
47 |
-
"homepage": "https://github.com/serbanghita/Mobile-Detect",
|
48 |
-
"keywords": [
|
49 |
-
"detect mobile devices",
|
50 |
-
"mobile",
|
51 |
-
"mobile detect",
|
52 |
-
"mobile detector",
|
53 |
-
"php mobile detect"
|
54 |
-
]
|
55 |
-
}
|
56 |
-
]
|
1 |
+
{
|
2 |
+
"packages": [],
|
3 |
+
"dev": true,
|
4 |
+
"dev-package-names": []
|
5 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
vendor/composer/installed.php
ADDED
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php return array (
|
2 |
+
'root' =>
|
3 |
+
array (
|
4 |
+
'pretty_version' => '1.0.0+no-version-set',
|
5 |
+
'version' => '1.0.0.0',
|
6 |
+
'aliases' =>
|
7 |
+
array (
|
8 |
+
),
|
9 |
+
'reference' => NULL,
|
10 |
+
'name' => 'dgora/ajax-search-for-woocommerce',
|
11 |
+
),
|
12 |
+
'versions' =>
|
13 |
+
array (
|
14 |
+
'dgora/ajax-search-for-woocommerce' =>
|
15 |
+
array (
|
16 |
+
'pretty_version' => '1.0.0+no-version-set',
|
17 |
+
'version' => '1.0.0.0',
|
18 |
+
'aliases' =>
|
19 |
+
array (
|
20 |
+
),
|
21 |
+
'reference' => NULL,
|
22 |
+
),
|
23 |
+
),
|
24 |
+
);
|
vendor/mobiledetect/mobiledetectlib/LICENSE.txt
DELETED
@@ -1,48 +0,0 @@
|
|
1 |
-
MIT License
|
2 |
-
|
3 |
-
Copyright (c) <2011-2015> Serban Ghita, Nick Ilyin and contributors.
|
4 |
-
|
5 |
-
Permission is hereby granted, free of charge, to any person obtaining
|
6 |
-
a copy of this software and associated documentation files (the
|
7 |
-
"Software"), to deal in the Software without restriction, including
|
8 |
-
without limitation the rights to use, copy, modify, merge, publish,
|
9 |
-
distribute, sublicense, and/or sell copies of the Software, and to
|
10 |
-
permit persons to whom the Software is furnished to do so, subject to
|
11 |
-
the following conditions:
|
12 |
-
|
13 |
-
The above copyright notice and this permission notice shall be included
|
14 |
-
in all copies or substantial portions of the Software.
|
15 |
-
|
16 |
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
17 |
-
OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
18 |
-
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
19 |
-
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
20 |
-
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
21 |
-
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
22 |
-
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
23 |
-
|
24 |
-
Developer’s Certificate of Origin 1.1
|
25 |
-
|
26 |
-
By making a contribution to this project, I certify that:
|
27 |
-
|
28 |
-
(a) The contribution was created in whole or in part by me and I
|
29 |
-
have the right to submit it under the open source license
|
30 |
-
indicated in the file; or
|
31 |
-
|
32 |
-
(b) The contribution is based upon previous work that, to the best
|
33 |
-
of my knowledge, is covered under an appropriate open source
|
34 |
-
license and I have the right under that license to submit that
|
35 |
-
work with modifications, whether created in whole or in part
|
36 |
-
by me, under the same open source license (unless I am
|
37 |
-
permitted to submit under a different license), as indicated
|
38 |
-
in the file; or
|
39 |
-
|
40 |
-
(c) The contribution was provided directly to me by some other
|
41 |
-
person who certified (a), (b) or (c) and I have not modified
|
42 |
-
it.
|
43 |
-
|
44 |
-
(d) I understand and agree that this project and the contribution
|
45 |
-
are public and that a record of the contribution (including all
|
46 |
-
personal information I submit with it, including my sign-off) is
|
47 |
-
maintained indefinitely and may be redistributed consistent with
|
48 |
-
this project or the open source license(s) involved.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
vendor/mobiledetect/mobiledetectlib/Mobile_Detect.json
DELETED
@@ -1 +0,0 @@
|
|
1 |
-
{"version":"2.8.34","headerMatch":{"HTTP_ACCEPT":{"matches":["application\/x-obml2d","application\/vnd.rim.html","text\/vnd.wap.wml","application\/vnd.wap.xhtml+xml"]},"HTTP_X_WAP_PROFILE":null,"HTTP_X_WAP_CLIENTID":null,"HTTP_WAP_CONNECTION":null,"HTTP_PROFILE":null,"HTTP_X_OPERAMINI_PHONE_UA":null,"HTTP_X_NOKIA_GATEWAY_ID":null,"HTTP_X_ORANGE_ID":null,"HTTP_X_VODAFONE_3GPDPCONTEXT":null,"HTTP_X_HUAWEI_USERID":null,"HTTP_UA_OS":null,"HTTP_X_MOBILE_GATEWAY":null,"HTTP_X_ATT_DEVICEID":null,"HTTP_UA_CPU":{"matches":["ARM"]}},"uaHttpHeaders":["HTTP_USER_AGENT","HTTP_X_OPERAMINI_PHONE_UA","HTTP_X_DEVICE_USER_AGENT","HTTP_X_ORIGINAL_USER_AGENT","HTTP_X_SKYFIRE_PHONE","HTTP_X_BOLT_PHONE_UA","HTTP_DEVICE_STOCK_UA","HTTP_X_UCBROWSER_DEVICE_UA"],"uaMatch":{"phones":{"iPhone":"\\biPhone\\b|\\biPod\\b","BlackBerry":"BlackBerry|\\bBB10\\b|rim[0-9]+|\\b(BBA100|BBB100|BBD100|BBE100|BBF100|STH100)\\b-[0-9]+","HTC":"HTC|HTC.*(Sensation|Evo|Vision|Explorer|6800|8100|8900|A7272|S510e|C110e|Legend|Desire|T8282)|APX515CKT|Qtek9090|APA9292KT|HD_mini|Sensation.*Z710e|PG86100|Z715e|Desire.*(A8181|HD)|ADR6200|ADR6400L|ADR6425|001HT|Inspire 4G|Android.*\\bEVO\\b|T-Mobile G1|Z520m|Android [0-9.]+; Pixel","Nexus":"Nexus One|Nexus S|Galaxy.*Nexus|Android.*Nexus.*Mobile|Nexus 4|Nexus 5|Nexus 6","Dell":"Dell[;]? (Streak|Aero|Venue|Venue Pro|Flash|Smoke|Mini 3iX)|XCD28|XCD35|\\b001DL\\b|\\b101DL\\b|\\bGS01\\b","Motorola":"Motorola|DROIDX|DROID BIONIC|\\bDroid\\b.*Build|Android.*Xoom|HRI39|MOT-|A1260|A1680|A555|A853|A855|A953|A955|A956|Motorola.*ELECTRIFY|Motorola.*i1|i867|i940|MB200|MB300|MB501|MB502|MB508|MB511|MB520|MB525|MB526|MB611|MB612|MB632|MB810|MB855|MB860|MB861|MB865|MB870|ME501|ME502|ME511|ME525|ME600|ME632|ME722|ME811|ME860|ME863|ME865|MT620|MT710|MT716|MT720|MT810|MT870|MT917|Motorola.*TITANIUM|WX435|WX445|XT300|XT301|XT311|XT316|XT317|XT319|XT320|XT390|XT502|XT530|XT531|XT532|XT535|XT603|XT610|XT611|XT615|XT681|XT701|XT702|XT711|XT720|XT800|XT806|XT860|XT862|XT875|XT882|XT883|XT894|XT901|XT907|XT909|XT910|XT912|XT928|XT926|XT915|XT919|XT925|XT1021|\\bMoto E\\b|XT1068|XT1092|XT1052","Samsung":"\\bSamsung\\b|SM-G950F|SM-G955F|SM-G9250|GT-19300|SGH-I337|BGT-S5230|GT-B2100|GT-B2700|GT-B2710|GT-B3210|GT-B3310|GT-B3410|GT-B3730|GT-B3740|GT-B5510|GT-B5512|GT-B5722|GT-B6520|GT-B7300|GT-B7320|GT-B7330|GT-B7350|GT-B7510|GT-B7722|GT-B7800|GT-C3010|GT-C3011|GT-C3060|GT-C3200|GT-C3212|GT-C3212I|GT-C3262|GT-C3222|GT-C3300|GT-C3300K|GT-C3303|GT-C3303K|GT-C3310|GT-C3322|GT-C3330|GT-C3350|GT-C3500|GT-C3510|GT-C3530|GT-C3630|GT-C3780|GT-C5010|GT-C5212|GT-C6620|GT-C6625|GT-C6712|GT-E1050|GT-E1070|GT-E1075|GT-E1080|GT-E1081|GT-E1085|GT-E1087|GT-E1100|GT-E1107|GT-E1110|GT-E1120|GT-E1125|GT-E1130|GT-E1160|GT-E1170|GT-E1175|GT-E1180|GT-E1182|GT-E1200|GT-E1210|GT-E1225|GT-E1230|GT-E1390|GT-E2100|GT-E2120|GT-E2121|GT-E2152|GT-E2220|GT-E2222|GT-E2230|GT-E2232|GT-E2250|GT-E2370|GT-E2550|GT-E2652|GT-E3210|GT-E3213|GT-I5500|GT-I5503|GT-I5700|GT-I5800|GT-I5801|GT-I6410|GT-I6420|GT-I7110|GT-I7410|GT-I7500|GT-I8000|GT-I8150|GT-I8160|GT-I8190|GT-I8320|GT-I8330|GT-I8350|GT-I8530|GT-I8700|GT-I8703|GT-I8910|GT-I9000|GT-I9001|GT-I9003|GT-I9010|GT-I9020|GT-I9023|GT-I9070|GT-I9082|GT-I9100|GT-I9103|GT-I9220|GT-I9250|GT-I9300|GT-I9305|GT-I9500|GT-I9505|GT-M3510|GT-M5650|GT-M7500|GT-M7600|GT-M7603|GT-M8800|GT-M8910|GT-N7000|GT-S3110|GT-S3310|GT-S3350|GT-S3353|GT-S3370|GT-S3650|GT-S3653|GT-S3770|GT-S3850|GT-S5210|GT-S5220|GT-S5229|GT-S5230|GT-S5233|GT-S5250|GT-S5253|GT-S5260|GT-S5263|GT-S5270|GT-S5300|GT-S5330|GT-S5350|GT-S5360|GT-S5363|GT-S5369|GT-S5380|GT-S5380D|GT-S5560|GT-S5570|GT-S5600|GT-S5603|GT-S5610|GT-S5620|GT-S5660|GT-S5670|GT-S5690|GT-S5750|GT-S5780|GT-S5830|GT-S5839|GT-S6102|GT-S6500|GT-S7070|GT-S7200|GT-S7220|GT-S7230|GT-S7233|GT-S7250|GT-S7500|GT-S7530|GT-S7550|GT-S7562|GT-S7710|GT-S8000|GT-S8003|GT-S8500|GT-S8530|GT-S8600|SCH-A310|SCH-A530|SCH-A570|SCH-A610|SCH-A630|SCH-A650|SCH-A790|SCH-A795|SCH-A850|SCH-A870|SCH-A890|SCH-A930|SCH-A950|SCH-A970|SCH-A990|SCH-I100|SCH-I110|SCH-I400|SCH-I405|SCH-I500|SCH-I510|SCH-I515|SCH-I600|SCH-I730|SCH-I760|SCH-I770|SCH-I830|SCH-I910|SCH-I920|SCH-I959|SCH-LC11|SCH-N150|SCH-N300|SCH-R100|SCH-R300|SCH-R351|SCH-R400|SCH-R410|SCH-T300|SCH-U310|SCH-U320|SCH-U350|SCH-U360|SCH-U365|SCH-U370|SCH-U380|SCH-U410|SCH-U430|SCH-U450|SCH-U460|SCH-U470|SCH-U490|SCH-U540|SCH-U550|SCH-U620|SCH-U640|SCH-U650|SCH-U660|SCH-U700|SCH-U740|SCH-U750|SCH-U810|SCH-U820|SCH-U900|SCH-U940|SCH-U960|SCS-26UC|SGH-A107|SGH-A117|SGH-A127|SGH-A137|SGH-A157|SGH-A167|SGH-A177|SGH-A187|SGH-A197|SGH-A227|SGH-A237|SGH-A257|SGH-A437|SGH-A517|SGH-A597|SGH-A637|SGH-A657|SGH-A667|SGH-A687|SGH-A697|SGH-A707|SGH-A717|SGH-A727|SGH-A737|SGH-A747|SGH-A767|SGH-A777|SGH-A797|SGH-A817|SGH-A827|SGH-A837|SGH-A847|SGH-A867|SGH-A877|SGH-A887|SGH-A897|SGH-A927|SGH-B100|SGH-B130|SGH-B200|SGH-B220|SGH-C100|SGH-C110|SGH-C120|SGH-C130|SGH-C140|SGH-C160|SGH-C170|SGH-C180|SGH-C200|SGH-C207|SGH-C210|SGH-C225|SGH-C230|SGH-C417|SGH-C450|SGH-D307|SGH-D347|SGH-D357|SGH-D407|SGH-D415|SGH-D780|SGH-D807|SGH-D980|SGH-E105|SGH-E200|SGH-E315|SGH-E316|SGH-E317|SGH-E335|SGH-E590|SGH-E635|SGH-E715|SGH-E890|SGH-F300|SGH-F480|SGH-I200|SGH-I300|SGH-I320|SGH-I550|SGH-I577|SGH-I600|SGH-I607|SGH-I617|SGH-I627|SGH-I637|SGH-I677|SGH-I700|SGH-I717|SGH-I727|SGH-i747M|SGH-I777|SGH-I780|SGH-I827|SGH-I847|SGH-I857|SGH-I896|SGH-I897|SGH-I900|SGH-I907|SGH-I917|SGH-I927|SGH-I937|SGH-I997|SGH-J150|SGH-J200|SGH-L170|SGH-L700|SGH-M110|SGH-M150|SGH-M200|SGH-N105|SGH-N500|SGH-N600|SGH-N620|SGH-N625|SGH-N700|SGH-N710|SGH-P107|SGH-P207|SGH-P300|SGH-P310|SGH-P520|SGH-P735|SGH-P777|SGH-Q105|SGH-R210|SGH-R220|SGH-R225|SGH-S105|SGH-S307|SGH-T109|SGH-T119|SGH-T139|SGH-T209|SGH-T219|SGH-T229|SGH-T239|SGH-T249|SGH-T259|SGH-T309|SGH-T319|SGH-T329|SGH-T339|SGH-T349|SGH-T359|SGH-T369|SGH-T379|SGH-T409|SGH-T429|SGH-T439|SGH-T459|SGH-T469|SGH-T479|SGH-T499|SGH-T509|SGH-T519|SGH-T539|SGH-T559|SGH-T589|SGH-T609|SGH-T619|SGH-T629|SGH-T639|SGH-T659|SGH-T669|SGH-T679|SGH-T709|SGH-T719|SGH-T729|SGH-T739|SGH-T746|SGH-T749|SGH-T759|SGH-T769|SGH-T809|SGH-T819|SGH-T839|SGH-T919|SGH-T929|SGH-T939|SGH-T959|SGH-T989|SGH-U100|SGH-U200|SGH-U800|SGH-V205|SGH-V206|SGH-X100|SGH-X105|SGH-X120|SGH-X140|SGH-X426|SGH-X427|SGH-X475|SGH-X495|SGH-X497|SGH-X507|SGH-X600|SGH-X610|SGH-X620|SGH-X630|SGH-X700|SGH-X820|SGH-X890|SGH-Z130|SGH-Z150|SGH-Z170|SGH-ZX10|SGH-ZX20|SHW-M110|SPH-A120|SPH-A400|SPH-A420|SPH-A460|SPH-A500|SPH-A560|SPH-A600|SPH-A620|SPH-A660|SPH-A700|SPH-A740|SPH-A760|SPH-A790|SPH-A800|SPH-A820|SPH-A840|SPH-A880|SPH-A900|SPH-A940|SPH-A960|SPH-D600|SPH-D700|SPH-D710|SPH-D720|SPH-I300|SPH-I325|SPH-I330|SPH-I350|SPH-I500|SPH-I600|SPH-I700|SPH-L700|SPH-M100|SPH-M220|SPH-M240|SPH-M300|SPH-M305|SPH-M320|SPH-M330|SPH-M350|SPH-M360|SPH-M370|SPH-M380|SPH-M510|SPH-M540|SPH-M550|SPH-M560|SPH-M570|SPH-M580|SPH-M610|SPH-M620|SPH-M630|SPH-M800|SPH-M810|SPH-M850|SPH-M900|SPH-M910|SPH-M920|SPH-M930|SPH-N100|SPH-N200|SPH-N240|SPH-N300|SPH-N400|SPH-Z400|SWC-E100|SCH-i909|GT-N7100|GT-N7105|SCH-I535|SM-N900A|SGH-I317|SGH-T999L|GT-S5360B|GT-I8262|GT-S6802|GT-S6312|GT-S6310|GT-S5312|GT-S5310|GT-I9105|GT-I8510|GT-S6790N|SM-G7105|SM-N9005|GT-S5301|GT-I9295|GT-I9195|SM-C101|GT-S7392|GT-S7560|GT-B7610|GT-I5510|GT-S7582|GT-S7530E|GT-I8750|SM-G9006V|SM-G9008V|SM-G9009D|SM-G900A|SM-G900D|SM-G900F|SM-G900H|SM-G900I|SM-G900J|SM-G900K|SM-G900L|SM-G900M|SM-G900P|SM-G900R4|SM-G900S|SM-G900T|SM-G900V|SM-G900W8|SHV-E160K|SCH-P709|SCH-P729|SM-T2558|GT-I9205|SM-G9350|SM-J120F|SM-G920F|SM-G920V|SM-G930F|SM-N910C|SM-A310F|GT-I9190|SM-J500FN|SM-G903F|SM-J330F","LG":"\\bLG\\b;|LG[- ]?(C800|C900|E400|E610|E900|E-900|F160|F180K|F180L|F180S|730|855|L160|LS740|LS840|LS970|LU6200|MS690|MS695|MS770|MS840|MS870|MS910|P500|P700|P705|VM696|AS680|AS695|AX840|C729|E970|GS505|272|C395|E739BK|E960|L55C|L75C|LS696|LS860|P769BK|P350|P500|P509|P870|UN272|US730|VS840|VS950|LN272|LN510|LS670|LS855|LW690|MN270|MN510|P509|P769|P930|UN200|UN270|UN510|UN610|US670|US740|US760|UX265|UX840|VN271|VN530|VS660|VS700|VS740|VS750|VS910|VS920|VS930|VX9200|VX11000|AX840A|LW770|P506|P925|P999|E612|D955|D802|MS323|M257)|LM-G710","Sony":"SonyST|SonyLT|SonyEricsson|SonyEricssonLT15iv|LT18i|E10i|LT28h|LT26w|SonyEricssonMT27i|C5303|C6902|C6903|C6906|C6943|D2533","Asus":"Asus.*Galaxy|PadFone.*Mobile","NokiaLumia":"Lumia [0-9]{3,4}","Micromax":"Micromax.*\\b(A210|A92|A88|A72|A111|A110Q|A115|A116|A110|A90S|A26|A51|A35|A54|A25|A27|A89|A68|A65|A57|A90)\\b","Palm":"PalmSource|Palm","Vertu":"Vertu|Vertu.*Ltd|Vertu.*Ascent|Vertu.*Ayxta|Vertu.*Constellation(F|Quest)?|Vertu.*Monika|Vertu.*Signature","Pantech":"PANTECH|IM-A850S|IM-A840S|IM-A830L|IM-A830K|IM-A830S|IM-A820L|IM-A810K|IM-A810S|IM-A800S|IM-T100K|IM-A725L|IM-A780L|IM-A775C|IM-A770K|IM-A760S|IM-A750K|IM-A740S|IM-A730S|IM-A720L|IM-A710K|IM-A690L|IM-A690S|IM-A650S|IM-A630K|IM-A600S|VEGA PTL21|PT003|P8010|ADR910L|P6030|P6020|P9070|P4100|P9060|P5000|CDM8992|TXT8045|ADR8995|IS11PT|P2030|P6010|P8000|PT002|IS06|CDM8999|P9050|PT001|TXT8040|P2020|P9020|P2000|P7040|P7000|C790","Fly":"IQ230|IQ444|IQ450|IQ440|IQ442|IQ441|IQ245|IQ256|IQ236|IQ255|IQ235|IQ245|IQ275|IQ240|IQ285|IQ280|IQ270|IQ260|IQ250","Wiko":"KITE 4G|HIGHWAY|GETAWAY|STAIRWAY|DARKSIDE|DARKFULL|DARKNIGHT|DARKMOON|SLIDE|WAX 4G|RAINBOW|BLOOM|SUNSET|GOA(?!nna)|LENNY|BARRY|IGGY|OZZY|CINK FIVE|CINK PEAX|CINK PEAX 2|CINK SLIM|CINK SLIM 2|CINK +|CINK KING|CINK PEAX|CINK SLIM|SUBLIM","iMobile":"i-mobile (IQ|i-STYLE|idea|ZAA|Hitz)","SimValley":"\\b(SP-80|XT-930|SX-340|XT-930|SX-310|SP-360|SP60|SPT-800|SP-120|SPT-800|SP-140|SPX-5|SPX-8|SP-100|SPX-8|SPX-12)\\b","Wolfgang":"AT-B24D|AT-AS50HD|AT-AS40W|AT-AS55HD|AT-AS45q2|AT-B26D|AT-AS50Q","Alcatel":"Alcatel","Nintendo":"Nintendo (3DS|Switch)","Amoi":"Amoi","INQ":"INQ","OnePlus":"ONEPLUS","GenericPhone":"Tapatalk|PDA;|SAGEM|\\bmmp\\b|pocket|\\bpsp\\b|symbian|Smartphone|smartfon|treo|up.browser|up.link|vodafone|\\bwap\\b|nokia|Series40|Series60|S60|SonyEricsson|N900|MAUI.*WAP.*Browser"},"tablets":{"iPad":"iPad|iPad.*Mobile","NexusTablet":"Android.*Nexus[\\s]+(7|9|10)","GoogleTablet":"Android.*Pixel C","SamsungTablet":"SAMSUNG.*Tablet|Galaxy.*Tab|SC-01C|GT-P1000|GT-P1003|GT-P1010|GT-P3105|GT-P6210|GT-P6800|GT-P6810|GT-P7100|GT-P7300|GT-P7310|GT-P7500|GT-P7510|SCH-I800|SCH-I815|SCH-I905|SGH-I957|SGH-I987|SGH-T849|SGH-T859|SGH-T869|SPH-P100|GT-P3100|GT-P3108|GT-P3110|GT-P5100|GT-P5110|GT-P6200|GT-P7320|GT-P7511|GT-N8000|GT-P8510|SGH-I497|SPH-P500|SGH-T779|SCH-I705|SCH-I915|GT-N8013|GT-P3113|GT-P5113|GT-P8110|GT-N8010|GT-N8005|GT-N8020|GT-P1013|GT-P6201|GT-P7501|GT-N5100|GT-N5105|GT-N5110|SHV-E140K|SHV-E140L|SHV-E140S|SHV-E150S|SHV-E230K|SHV-E230L|SHV-E230S|SHW-M180K|SHW-M180L|SHW-M180S|SHW-M180W|SHW-M300W|SHW-M305W|SHW-M380K|SHW-M380S|SHW-M380W|SHW-M430W|SHW-M480K|SHW-M480S|SHW-M480W|SHW-M485W|SHW-M486W|SHW-M500W|GT-I9228|SCH-P739|SCH-I925|GT-I9200|GT-P5200|GT-P5210|GT-P5210X|SM-T311|SM-T310|SM-T310X|SM-T210|SM-T210R|SM-T211|SM-P600|SM-P601|SM-P605|SM-P900|SM-P901|SM-T217|SM-T217A|SM-T217S|SM-P6000|SM-T3100|SGH-I467|XE500|SM-T110|GT-P5220|GT-I9200X|GT-N5110X|GT-N5120|SM-P905|SM-T111|SM-T2105|SM-T315|SM-T320|SM-T320X|SM-T321|SM-T520|SM-T525|SM-T530NU|SM-T230NU|SM-T330NU|SM-T900|XE500T1C|SM-P605V|SM-P905V|SM-T337V|SM-T537V|SM-T707V|SM-T807V|SM-P600X|SM-P900X|SM-T210X|SM-T230|SM-T230X|SM-T325|GT-P7503|SM-T531|SM-T330|SM-T530|SM-T705|SM-T705C|SM-T535|SM-T331|SM-T800|SM-T700|SM-T537|SM-T807|SM-P907A|SM-T337A|SM-T537A|SM-T707A|SM-T807A|SM-T237|SM-T807P|SM-P607T|SM-T217T|SM-T337T|SM-T807T|SM-T116NQ|SM-T116BU|SM-P550|SM-T350|SM-T550|SM-T9000|SM-P9000|SM-T705Y|SM-T805|GT-P3113|SM-T710|SM-T810|SM-T815|SM-T360|SM-T533|SM-T113|SM-T335|SM-T715|SM-T560|SM-T670|SM-T677|SM-T377|SM-T567|SM-T357T|SM-T555|SM-T561|SM-T713|SM-T719|SM-T813|SM-T819|SM-T580|SM-T355Y?|SM-T280|SM-T817A|SM-T820|SM-W700|SM-P580|SM-T587|SM-P350|SM-P555M|SM-P355M|SM-T113NU|SM-T815Y|SM-T585|SM-T285|SM-T825|SM-W708|SM-T835|SM-T830|SM-T837V|SM-T720|SM-T510|SM-T387V","Kindle":"Kindle|Silk.*Accelerated|Android.*\\b(KFOT|KFTT|KFJWI|KFJWA|KFOTE|KFSOWI|KFTHWI|KFTHWA|KFAPWI|KFAPWA|WFJWAE|KFSAWA|KFSAWI|KFASWI|KFARWI|KFFOWI|KFGIWI|KFMEWI)\\b|Android.*Silk\/[0-9.]+ like Chrome\/[0-9.]+ (?!Mobile)","SurfaceTablet":"Windows NT [0-9.]+; ARM;.*(Tablet|ARMBJS)","HPTablet":"HP Slate (7|8|10)|HP ElitePad 900|hp-tablet|EliteBook.*Touch|HP 8|Slate 21|HP SlateBook 10","AsusTablet":"^.*PadFone((?!Mobile).)*$|Transformer|TF101|TF101G|TF300T|TF300TG|TF300TL|TF700T|TF700KL|TF701T|TF810C|ME171|ME301T|ME302C|ME371MG|ME370T|ME372MG|ME172V|ME173X|ME400C|Slider SL101|\\bK00F\\b|\\bK00C\\b|\\bK00E\\b|\\bK00L\\b|TX201LA|ME176C|ME102A|\\bM80TA\\b|ME372CL|ME560CG|ME372CG|ME302KL| K010 | K011 | K017 | K01E |ME572C|ME103K|ME170C|ME171C|\\bME70C\\b|ME581C|ME581CL|ME8510C|ME181C|P01Y|PO1MA|P01Z|\\bP027\\b|\\bP024\\b|\\bP00C\\b","BlackBerryTablet":"PlayBook|RIM Tablet","HTCtablet":"HTC_Flyer_P512|HTC Flyer|HTC Jetstream|HTC-P715a|HTC EVO View 4G|PG41200|PG09410","MotorolaTablet":"xoom|sholest|MZ615|MZ605|MZ505|MZ601|MZ602|MZ603|MZ604|MZ606|MZ607|MZ608|MZ609|MZ615|MZ616|MZ617","NookTablet":"Android.*Nook|NookColor|nook browser|BNRV200|BNRV200A|BNTV250|BNTV250A|BNTV400|BNTV600|LogicPD Zoom2","AcerTablet":"Android.*; \\b(A100|A101|A110|A200|A210|A211|A500|A501|A510|A511|A700|A701|W500|W500P|W501|W501P|W510|W511|W700|G100|G100W|B1-A71|B1-710|B1-711|A1-810|A1-811|A1-830)\\b|W3-810|\\bA3-A10\\b|\\bA3-A11\\b|\\bA3-A20\\b|\\bA3-A30","ToshibaTablet":"Android.*(AT100|AT105|AT200|AT205|AT270|AT275|AT300|AT305|AT1S5|AT500|AT570|AT700|AT830)|TOSHIBA.*FOLIO","LGTablet":"\\bL-06C|LG-V909|LG-V900|LG-V700|LG-V510|LG-V500|LG-V410|LG-V400|LG-VK810\\b","FujitsuTablet":"Android.*\\b(F-01D|F-02F|F-05E|F-10D|M532|Q572)\\b","PrestigioTablet":"PMP3170B|PMP3270B|PMP3470B|PMP7170B|PMP3370B|PMP3570C|PMP5870C|PMP3670B|PMP5570C|PMP5770D|PMP3970B|PMP3870C|PMP5580C|PMP5880D|PMP5780D|PMP5588C|PMP7280C|PMP7280C3G|PMP7280|PMP7880D|PMP5597D|PMP5597|PMP7100D|PER3464|PER3274|PER3574|PER3884|PER5274|PER5474|PMP5097CPRO|PMP5097|PMP7380D|PMP5297C|PMP5297C_QUAD|PMP812E|PMP812E3G|PMP812F|PMP810E|PMP880TD|PMT3017|PMT3037|PMT3047|PMT3057|PMT7008|PMT5887|PMT5001|PMT5002","LenovoTablet":"Lenovo TAB|Idea(Tab|Pad)( A1|A10| K1|)|ThinkPad([ ]+)?Tablet|YT3-850M|YT3-X90L|YT3-X90F|YT3-X90X|Lenovo.*(S2109|S2110|S5000|S6000|K3011|A3000|A3500|A1000|A2107|A2109|A1107|A5500|A7600|B6000|B8000|B8080)(-|)(FL|F|HV|H|)|TB-X103F|TB-X304X|TB-X304F|TB-X304L|TB-X505F|TB-X505L|TB-X505X|TB-X605F|TB-X605L|TB-8703F|TB-8703X|TB-8703N|TB-8704N|TB-8704F|TB-8704X|TB-8704V|TB-7304F|TB-7304I|TB-7304X|Tab2A7-10F|Tab2A7-20F|TB2-X30L|YT3-X50L|YT3-X50F|YT3-X50M|YT-X705F|YT-X703F|YT-X703L|YT-X705L|YT-X705X|TB2-X30F|TB2-X30L|TB2-X30M|A2107A-F|A2107A-H|TB3-730F|TB3-730M|TB3-730X|TB-7504F|TB-7504X","DellTablet":"Venue 11|Venue 8|Venue 7|Dell Streak 10|Dell Streak 7","YarvikTablet":"Android.*\\b(TAB210|TAB211|TAB224|TAB250|TAB260|TAB264|TAB310|TAB360|TAB364|TAB410|TAB411|TAB420|TAB424|TAB450|TAB460|TAB461|TAB464|TAB465|TAB467|TAB468|TAB07-100|TAB07-101|TAB07-150|TAB07-151|TAB07-152|TAB07-200|TAB07-201-3G|TAB07-210|TAB07-211|TAB07-212|TAB07-214|TAB07-220|TAB07-400|TAB07-485|TAB08-150|TAB08-200|TAB08-201-3G|TAB08-201-30|TAB09-100|TAB09-211|TAB09-410|TAB10-150|TAB10-201|TAB10-211|TAB10-400|TAB10-410|TAB13-201|TAB274EUK|TAB275EUK|TAB374EUK|TAB462EUK|TAB474EUK|TAB9-200)\\b","MedionTablet":"Android.*\\bOYO\\b|LIFE.*(P9212|P9514|P9516|S9512)|LIFETAB","ArnovaTablet":"97G4|AN10G2|AN7bG3|AN7fG3|AN8G3|AN8cG3|AN7G3|AN9G3|AN7dG3|AN7dG3ST|AN7dG3ChildPad|AN10bG3|AN10bG3DT|AN9G2","IntensoTablet":"INM8002KP|INM1010FP|INM805ND|Intenso Tab|TAB1004","IRUTablet":"M702pro","MegafonTablet":"MegaFon V9|\\bZTE V9\\b|Android.*\\bMT7A\\b","EbodaTablet":"E-Boda (Supreme|Impresspeed|Izzycomm|Essential)","AllViewTablet":"Allview.*(Viva|Alldro|City|Speed|All TV|Frenzy|Quasar|Shine|TX1|AX1|AX2)","ArchosTablet":"\\b(101G9|80G9|A101IT)\\b|Qilive 97R|Archos5|\\bARCHOS (70|79|80|90|97|101|FAMILYPAD|)(b|c|)(G10| Cobalt| TITANIUM(HD|)| Xenon| Neon|XSK| 2| XS 2| PLATINUM| CARBON|GAMEPAD)\\b","AinolTablet":"NOVO7|NOVO8|NOVO10|Novo7Aurora|Novo7Basic|NOVO7PALADIN|novo9-Spark","NokiaLumiaTablet":"Lumia 2520","SonyTablet":"Sony.*Tablet|Xperia Tablet|Sony Tablet S|SO-03E|SGPT12|SGPT13|SGPT114|SGPT121|SGPT122|SGPT123|SGPT111|SGPT112|SGPT113|SGPT131|SGPT132|SGPT133|SGPT211|SGPT212|SGPT213|SGP311|SGP312|SGP321|EBRD1101|EBRD1102|EBRD1201|SGP351|SGP341|SGP511|SGP512|SGP521|SGP541|SGP551|SGP621|SGP641|SGP612|SOT31|SGP771|SGP611|SGP612|SGP712","PhilipsTablet":"\\b(PI2010|PI3000|PI3100|PI3105|PI3110|PI3205|PI3210|PI3900|PI4010|PI7000|PI7100)\\b","CubeTablet":"Android.*(K8GT|U9GT|U10GT|U16GT|U17GT|U18GT|U19GT|U20GT|U23GT|U30GT)|CUBE U8GT","CobyTablet":"MID1042|MID1045|MID1125|MID1126|MID7012|MID7014|MID7015|MID7034|MID7035|MID7036|MID7042|MID7048|MID7127|MID8042|MID8048|MID8127|MID9042|MID9740|MID9742|MID7022|MID7010","MIDTablet":"M9701|M9000|M9100|M806|M1052|M806|T703|MID701|MID713|MID710|MID727|MID760|MID830|MID728|MID933|MID125|MID810|MID732|MID120|MID930|MID800|MID731|MID900|MID100|MID820|MID735|MID980|MID130|MID833|MID737|MID960|MID135|MID860|MID736|MID140|MID930|MID835|MID733|MID4X10","MSITablet":"MSI \\b(Primo 73K|Primo 73L|Primo 81L|Primo 77|Primo 93|Primo 75|Primo 76|Primo 73|Primo 81|Primo 91|Primo 90|Enjoy 71|Enjoy 7|Enjoy 10)\\b","SMiTTablet":"Android.*(\\bMID\\b|MID-560|MTV-T1200|MTV-PND531|MTV-P1101|MTV-PND530)","RockChipTablet":"Android.*(RK2818|RK2808A|RK2918|RK3066)|RK2738|RK2808A","FlyTablet":"IQ310|Fly Vision","bqTablet":"Android.*(bq)?.*\\b(Elcano|Curie|Edison|Maxwell|Kepler|Pascal|Tesla|Hypatia|Platon|Newton|Livingstone|Cervantes|Avant|Aquaris ([E|M]10|M8))\\b|Maxwell.*Lite|Maxwell.*Plus","HuaweiTablet":"MediaPad|MediaPad 7 Youth|IDEOS S7|S7-201c|S7-202u|S7-101|S7-103|S7-104|S7-105|S7-106|S7-201|S7-Slim|M2-A01L|BAH-L09|BAH-W09|AGS-L09|CMR-AL19","NecTablet":"\\bN-06D|\\bN-08D","PantechTablet":"Pantech.*P4100","BronchoTablet":"Broncho.*(N701|N708|N802|a710)","VersusTablet":"TOUCHPAD.*[78910]|\\bTOUCHTAB\\b","ZyncTablet":"z1000|Z99 2G|z930|z990|z909|Z919|z900","PositivoTablet":"TB07STA|TB10STA|TB07FTA|TB10FTA","NabiTablet":"Android.*\\bNabi","KoboTablet":"Kobo Touch|\\bK080\\b|\\bVox\\b Build|\\bArc\\b Build","DanewTablet":"DSlide.*\\b(700|701R|702|703R|704|802|970|971|972|973|974|1010|1012)\\b","TexetTablet":"NaviPad|TB-772A|TM-7045|TM-7055|TM-9750|TM-7016|TM-7024|TM-7026|TM-7041|TM-7043|TM-7047|TM-8041|TM-9741|TM-9747|TM-9748|TM-9751|TM-7022|TM-7021|TM-7020|TM-7011|TM-7010|TM-7023|TM-7025|TM-7037W|TM-7038W|TM-7027W|TM-9720|TM-9725|TM-9737W|TM-1020|TM-9738W|TM-9740|TM-9743W|TB-807A|TB-771A|TB-727A|TB-725A|TB-719A|TB-823A|TB-805A|TB-723A|TB-715A|TB-707A|TB-705A|TB-709A|TB-711A|TB-890HD|TB-880HD|TB-790HD|TB-780HD|TB-770HD|TB-721HD|TB-710HD|TB-434HD|TB-860HD|TB-840HD|TB-760HD|TB-750HD|TB-740HD|TB-730HD|TB-722HD|TB-720HD|TB-700HD|TB-500HD|TB-470HD|TB-431HD|TB-430HD|TB-506|TB-504|TB-446|TB-436|TB-416|TB-146SE|TB-126SE","PlaystationTablet":"Playstation.*(Portable|Vita)","TrekstorTablet":"ST10416-1|VT10416-1|ST70408-1|ST702xx-1|ST702xx-2|ST80208|ST97216|ST70104-2|VT10416-2|ST10216-2A|SurfTab","PyleAudioTablet":"\\b(PTBL10CEU|PTBL10C|PTBL72BC|PTBL72BCEU|PTBL7CEU|PTBL7C|PTBL92BC|PTBL92BCEU|PTBL9CEU|PTBL9CUK|PTBL9C)\\b","AdvanTablet":"Android.* \\b(E3A|T3X|T5C|T5B|T3E|T3C|T3B|T1J|T1F|T2A|T1H|T1i|E1C|T1-E|T5-A|T4|E1-B|T2Ci|T1-B|T1-D|O1-A|E1-A|T1-A|T3A|T4i)\\b ","DanyTechTablet":"Genius Tab G3|Genius Tab S2|Genius Tab Q3|Genius Tab G4|Genius Tab Q4|Genius Tab G-II|Genius TAB GII|Genius TAB GIII|Genius Tab S1","GalapadTablet":"Android.*\\bG1\\b(?!\\))","MicromaxTablet":"Funbook|Micromax.*\\b(P250|P560|P360|P362|P600|P300|P350|P500|P275)\\b","KarbonnTablet":"Android.*\\b(A39|A37|A34|ST8|ST10|ST7|Smart Tab3|Smart Tab2)\\b","AllFineTablet":"Fine7 Genius|Fine7 Shine|Fine7 Air|Fine8 Style|Fine9 More|Fine10 Joy|Fine11 Wide","PROSCANTablet":"\\b(PEM63|PLT1023G|PLT1041|PLT1044|PLT1044G|PLT1091|PLT4311|PLT4311PL|PLT4315|PLT7030|PLT7033|PLT7033D|PLT7035|PLT7035D|PLT7044K|PLT7045K|PLT7045KB|PLT7071KG|PLT7072|PLT7223G|PLT7225G|PLT7777G|PLT7810K|PLT7849G|PLT7851G|PLT7852G|PLT8015|PLT8031|PLT8034|PLT8036|PLT8080K|PLT8082|PLT8088|PLT8223G|PLT8234G|PLT8235G|PLT8816K|PLT9011|PLT9045K|PLT9233G|PLT9735|PLT9760G|PLT9770G)\\b","YONESTablet":"BQ1078|BC1003|BC1077|RK9702|BC9730|BC9001|IT9001|BC7008|BC7010|BC708|BC728|BC7012|BC7030|BC7027|BC7026","ChangJiaTablet":"TPC7102|TPC7103|TPC7105|TPC7106|TPC7107|TPC7201|TPC7203|TPC7205|TPC7210|TPC7708|TPC7709|TPC7712|TPC7110|TPC8101|TPC8103|TPC8105|TPC8106|TPC8203|TPC8205|TPC8503|TPC9106|TPC9701|TPC97101|TPC97103|TPC97105|TPC97106|TPC97111|TPC97113|TPC97203|TPC97603|TPC97809|TPC97205|TPC10101|TPC10103|TPC10106|TPC10111|TPC10203|TPC10205|TPC10503","GUTablet":"TX-A1301|TX-M9002|Q702|kf026","PointOfViewTablet":"TAB-P506|TAB-navi-7-3G-M|TAB-P517|TAB-P-527|TAB-P701|TAB-P703|TAB-P721|TAB-P731N|TAB-P741|TAB-P825|TAB-P905|TAB-P925|TAB-PR945|TAB-PL1015|TAB-P1025|TAB-PI1045|TAB-P1325|TAB-PROTAB[0-9]+|TAB-PROTAB25|TAB-PROTAB26|TAB-PROTAB27|TAB-PROTAB26XL|TAB-PROTAB2-IPS9|TAB-PROTAB30-IPS9|TAB-PROTAB25XXL|TAB-PROTAB26-IPS10|TAB-PROTAB30-IPS10","OvermaxTablet":"OV-(SteelCore|NewBase|Basecore|Baseone|Exellen|Quattor|EduTab|Solution|ACTION|BasicTab|TeddyTab|MagicTab|Stream|TB-08|TB-09)|Qualcore 1027","HCLTablet":"HCL.*Tablet|Connect-3G-2.0|Connect-2G-2.0|ME Tablet U1|ME Tablet U2|ME Tablet G1|ME Tablet X1|ME Tablet Y2|ME Tablet Sync","DPSTablet":"DPS Dream 9|DPS Dual 7","VistureTablet":"V97 HD|i75 3G|Visture V4( HD)?|Visture V5( HD)?|Visture V10","CrestaTablet":"CTP(-)?810|CTP(-)?818|CTP(-)?828|CTP(-)?838|CTP(-)?888|CTP(-)?978|CTP(-)?980|CTP(-)?987|CTP(-)?988|CTP(-)?989","MediatekTablet":"\\bMT8125|MT8389|MT8135|MT8377\\b","ConcordeTablet":"Concorde([ ]+)?Tab|ConCorde ReadMan","GoCleverTablet":"GOCLEVER TAB|A7GOCLEVER|M1042|M7841|M742|R1042BK|R1041|TAB A975|TAB A7842|TAB A741|TAB A741L|TAB M723G|TAB M721|TAB A1021|TAB I921|TAB R721|TAB I720|TAB T76|TAB R70|TAB R76.2|TAB R106|TAB R83.2|TAB M813G|TAB I721|GCTA722|TAB I70|TAB I71|TAB S73|TAB R73|TAB R74|TAB R93|TAB R75|TAB R76.1|TAB A73|TAB A93|TAB A93.2|TAB T72|TAB R83|TAB R974|TAB R973|TAB A101|TAB A103|TAB A104|TAB A104.2|R105BK|M713G|A972BK|TAB A971|TAB R974.2|TAB R104|TAB R83.3|TAB A1042","ModecomTablet":"FreeTAB 9000|FreeTAB 7.4|FreeTAB 7004|FreeTAB 7800|FreeTAB 2096|FreeTAB 7.5|FreeTAB 1014|FreeTAB 1001 |FreeTAB 8001|FreeTAB 9706|FreeTAB 9702|FreeTAB 7003|FreeTAB 7002|FreeTAB 1002|FreeTAB 7801|FreeTAB 1331|FreeTAB 1004|FreeTAB 8002|FreeTAB 8014|FreeTAB 9704|FreeTAB 1003","VoninoTablet":"\\b(Argus[ _]?S|Diamond[ _]?79HD|Emerald[ _]?78E|Luna[ _]?70C|Onyx[ _]?S|Onyx[ _]?Z|Orin[ _]?HD|Orin[ _]?S|Otis[ _]?S|SpeedStar[ _]?S|Magnet[ _]?M9|Primus[ _]?94[ _]?3G|Primus[ _]?94HD|Primus[ _]?QS|Android.*\\bQ8\\b|Sirius[ _]?EVO[ _]?QS|Sirius[ _]?QS|Spirit[ _]?S)\\b","ECSTablet":"V07OT2|TM105A|S10OT1|TR10CS1","StorexTablet":"eZee[_']?(Tab|Go)[0-9]+|TabLC7|Looney Tunes Tab","VodafoneTablet":"SmartTab([ ]+)?[0-9]+|SmartTabII10|SmartTabII7|VF-1497|VFD 1400","EssentielBTablet":"Smart[ ']?TAB[ ]+?[0-9]+|Family[ ']?TAB2","RossMoorTablet":"RM-790|RM-997|RMD-878G|RMD-974R|RMT-705A|RMT-701|RME-601|RMT-501|RMT-711","iMobileTablet":"i-mobile i-note","TolinoTablet":"tolino tab [0-9.]+|tolino shine","AudioSonicTablet":"\\bC-22Q|T7-QC|T-17B|T-17P\\b","AMPETablet":"Android.* A78 ","SkkTablet":"Android.* (SKYPAD|PHOENIX|CYCLOPS)","TecnoTablet":"TECNO P9|TECNO DP8D","JXDTablet":"Android.* \\b(F3000|A3300|JXD5000|JXD3000|JXD2000|JXD300B|JXD300|S5800|S7800|S602b|S5110b|S7300|S5300|S602|S603|S5100|S5110|S601|S7100a|P3000F|P3000s|P101|P200s|P1000m|P200m|P9100|P1000s|S6600b|S908|P1000|P300|S18|S6600|S9100)\\b","iJoyTablet":"Tablet (Spirit 7|Essentia|Galatea|Fusion|Onix 7|Landa|Titan|Scooby|Deox|Stella|Themis|Argon|Unique 7|Sygnus|Hexen|Finity 7|Cream|Cream X2|Jade|Neon 7|Neron 7|Kandy|Scape|Saphyr 7|Rebel|Biox|Rebel|Rebel 8GB|Myst|Draco 7|Myst|Tab7-004|Myst|Tadeo Jones|Tablet Boing|Arrow|Draco Dual Cam|Aurix|Mint|Amity|Revolution|Finity 9|Neon 9|T9w|Amity 4GB Dual Cam|Stone 4GB|Stone 8GB|Andromeda|Silken|X2|Andromeda II|Halley|Flame|Saphyr 9,7|Touch 8|Planet|Triton|Unique 10|Hexen 10|Memphis 4GB|Memphis 8GB|Onix 10)","FX2Tablet":"FX2 PAD7|FX2 PAD10","XoroTablet":"KidsPAD 701|PAD[ ]?712|PAD[ ]?714|PAD[ ]?716|PAD[ ]?717|PAD[ ]?718|PAD[ ]?720|PAD[ ]?721|PAD[ ]?722|PAD[ ]?790|PAD[ ]?792|PAD[ ]?900|PAD[ ]?9715D|PAD[ ]?9716DR|PAD[ ]?9718DR|PAD[ ]?9719QR|PAD[ ]?9720QR|TelePAD1030|Telepad1032|TelePAD730|TelePAD731|TelePAD732|TelePAD735Q|TelePAD830|TelePAD9730|TelePAD795|MegaPAD 1331|MegaPAD 1851|MegaPAD 2151","ViewsonicTablet":"ViewPad 10pi|ViewPad 10e|ViewPad 10s|ViewPad E72|ViewPad7|ViewPad E100|ViewPad 7e|ViewSonic VB733|VB100a","VerizonTablet":"QTAQZ3|QTAIR7|QTAQTZ3|QTASUN1|QTASUN2|QTAXIA1","OdysTablet":"LOOX|XENO10|ODYS[ -](Space|EVO|Xpress|NOON)|\\bXELIO\\b|Xelio10Pro|XELIO7PHONETAB|XELIO10EXTREME|XELIOPT2|NEO_QUAD10","CaptivaTablet":"CAPTIVA PAD","IconbitTablet":"NetTAB|NT-3702|NT-3702S|NT-3702S|NT-3603P|NT-3603P|NT-0704S|NT-0704S|NT-3805C|NT-3805C|NT-0806C|NT-0806C|NT-0909T|NT-0909T|NT-0907S|NT-0907S|NT-0902S|NT-0902S","TeclastTablet":"T98 4G|\\bP80\\b|\\bX90HD\\b|X98 Air|X98 Air 3G|\\bX89\\b|P80 3G|\\bX80h\\b|P98 Air|\\bX89HD\\b|P98 3G|\\bP90HD\\b|P89 3G|X98 3G|\\bP70h\\b|P79HD 3G|G18d 3G|\\bP79HD\\b|\\bP89s\\b|\\bA88\\b|\\bP10HD\\b|\\bP19HD\\b|G18 3G|\\bP78HD\\b|\\bA78\\b|\\bP75\\b|G17s 3G|G17h 3G|\\bP85t\\b|\\bP90\\b|\\bP11\\b|\\bP98t\\b|\\bP98HD\\b|\\bG18d\\b|\\bP85s\\b|\\bP11HD\\b|\\bP88s\\b|\\bA80HD\\b|\\bA80se\\b|\\bA10h\\b|\\bP89\\b|\\bP78s\\b|\\bG18\\b|\\bP85\\b|\\bA70h\\b|\\bA70\\b|\\bG17\\b|\\bP18\\b|\\bA80s\\b|\\bA11s\\b|\\bP88HD\\b|\\bA80h\\b|\\bP76s\\b|\\bP76h\\b|\\bP98\\b|\\bA10HD\\b|\\bP78\\b|\\bP88\\b|\\bA11\\b|\\bA10t\\b|\\bP76a\\b|\\bP76t\\b|\\bP76e\\b|\\bP85HD\\b|\\bP85a\\b|\\bP86\\b|\\bP75HD\\b|\\bP76v\\b|\\bA12\\b|\\bP75a\\b|\\bA15\\b|\\bP76Ti\\b|\\bP81HD\\b|\\bA10\\b|\\bT760VE\\b|\\bT720HD\\b|\\bP76\\b|\\bP73\\b|\\bP71\\b|\\bP72\\b|\\bT720SE\\b|\\bC520Ti\\b|\\bT760\\b|\\bT720VE\\b|T720-3GE|T720-WiFi","OndaTablet":"\\b(V975i|Vi30|VX530|V701|Vi60|V701s|Vi50|V801s|V719|Vx610w|VX610W|V819i|Vi10|VX580W|Vi10|V711s|V813|V811|V820w|V820|Vi20|V711|VI30W|V712|V891w|V972|V819w|V820w|Vi60|V820w|V711|V813s|V801|V819|V975s|V801|V819|V819|V818|V811|V712|V975m|V101w|V961w|V812|V818|V971|V971s|V919|V989|V116w|V102w|V973|Vi40)\\b[\\s]+|V10 \\b4G\\b","JaytechTablet":"TPC-PA762","BlaupunktTablet":"Endeavour 800NG|Endeavour 1010","DigmaTablet":"\\b(iDx10|iDx9|iDx8|iDx7|iDxD7|iDxD8|iDsQ8|iDsQ7|iDsQ8|iDsD10|iDnD7|3TS804H|iDsQ11|iDj7|iDs10)\\b","EvolioTablet":"ARIA_Mini_wifi|Aria[ _]Mini|Evolio X10|Evolio X7|Evolio X8|\\bEvotab\\b|\\bNeura\\b","LavaTablet":"QPAD E704|\\bIvoryS\\b|E-TAB IVORY|\\bE-TAB\\b","AocTablet":"MW0811|MW0812|MW0922|MTK8382|MW1031|MW0831|MW0821|MW0931|MW0712","MpmanTablet":"MP11 OCTA|MP10 OCTA|MPQC1114|MPQC1004|MPQC994|MPQC974|MPQC973|MPQC804|MPQC784|MPQC780|\\bMPG7\\b|MPDCG75|MPDCG71|MPDC1006|MP101DC|MPDC9000|MPDC905|MPDC706HD|MPDC706|MPDC705|MPDC110|MPDC100|MPDC99|MPDC97|MPDC88|MPDC8|MPDC77|MP709|MID701|MID711|MID170|MPDC703|MPQC1010","CelkonTablet":"CT695|CT888|CT[\\s]?910|CT7 Tab|CT9 Tab|CT3 Tab|CT2 Tab|CT1 Tab|C820|C720|\\bCT-1\\b","WolderTablet":"miTab \\b(DIAMOND|SPACE|BROOKLYN|NEO|FLY|MANHATTAN|FUNK|EVOLUTION|SKY|GOCAR|IRON|GENIUS|POP|MINT|EPSILON|BROADWAY|JUMP|HOP|LEGEND|NEW AGE|LINE|ADVANCE|FEEL|FOLLOW|LIKE|LINK|LIVE|THINK|FREEDOM|CHICAGO|CLEVELAND|BALTIMORE-GH|IOWA|BOSTON|SEATTLE|PHOENIX|DALLAS|IN 101|MasterChef)\\b","MediacomTablet":"M-MPI10C3G|M-SP10EG|M-SP10EGP|M-SP10HXAH|M-SP7HXAH|M-SP10HXBH|M-SP8HXAH|M-SP8MXA","MiTablet":"\\bMI PAD\\b|\\bHM NOTE 1W\\b","NibiruTablet":"Nibiru M1|Nibiru Jupiter One","NexoTablet":"NEXO NOVA|NEXO 10|NEXO AVIO|NEXO FREE|NEXO GO|NEXO EVO|NEXO 3G|NEXO SMART|NEXO KIDDO|NEXO MOBI","LeaderTablet":"TBLT10Q|TBLT10I|TBL-10WDKB|TBL-10WDKBO2013|TBL-W230V2|TBL-W450|TBL-W500|SV572|TBLT7I|TBA-AC7-8G|TBLT79|TBL-8W16|TBL-10W32|TBL-10WKB|TBL-W100","UbislateTablet":"UbiSlate[\\s]?7C","PocketBookTablet":"Pocketbook","KocasoTablet":"\\b(TB-1207)\\b","HisenseTablet":"\\b(F5281|E2371)\\b","Hudl":"Hudl HT7S3|Hudl 2","TelstraTablet":"T-Hub2","GenericTablet":"Android.*\\b97D\\b|Tablet(?!.*PC)|BNTV250A|MID-WCDMA|LogicPD Zoom2|\\bA7EB\\b|CatNova8|A1_07|CT704|CT1002|\\bM721\\b|rk30sdk|\\bEVOTAB\\b|M758A|ET904|ALUMIUM10|Smartfren Tab|Endeavour 1010|Tablet-PC-4|Tagi Tab|\\bM6pro\\b|CT1020W|arc 10HD|\\bTP750\\b|\\bQTAQZ3\\b|WVT101|TM1088|KT107"},"browsers":{"Chrome":"\\bCrMo\\b|CriOS|Android.*Chrome\/[.0-9]* (Mobile)?","Dolfin":"\\bDolfin\\b","Opera":"Opera.*Mini|Opera.*Mobi|Android.*Opera|Mobile.*OPR\/[0-9.]+$|Coast\/[0-9.]+","Skyfire":"Skyfire","Edge":"Mobile Safari\/[.0-9]* Edge","IE":"IEMobile|MSIEMobile","Firefox":"fennec|firefox.*maemo|(Mobile|Tablet).*Firefox|Firefox.*Mobile|FxiOS","Bolt":"bolt","TeaShark":"teashark","Blazer":"Blazer","Safari":"Version.*Mobile.*Safari|Safari.*Mobile|MobileSafari","WeChat":"\\bMicroMessenger\\b","UCBrowser":"UC.*Browser|UCWEB","baiduboxapp":"baiduboxapp","baidubrowser":"baidubrowser","DiigoBrowser":"DiigoBrowser","Mercury":"\\bMercury\\b","ObigoBrowser":"Obigo","NetFront":"NF-Browser","GenericBrowser":"NokiaBrowser|OviBrowser|OneBrowser|TwonkyBeamBrowser|SEMC.*Browser|FlyFlow|Minimo|NetFront|Novarra-Vision|MQQBrowser|MicroMessenger","PaleMoon":"Android.*PaleMoon|Mobile.*PaleMoon"},"os":{"AndroidOS":"Android","BlackBerryOS":"blackberry|\\bBB10\\b|rim tablet os","PalmOS":"PalmOS|avantgo|blazer|elaine|hiptop|palm|plucker|xiino","SymbianOS":"Symbian|SymbOS|Series60|Series40|SYB-[0-9]+|\\bS60\\b","WindowsMobileOS":"Windows CE.*(PPC|Smartphone|Mobile|[0-9]{3}x[0-9]{3})|Windows Mobile|Windows Phone [0-9.]+|WCE;","WindowsPhoneOS":"Windows Phone 10.0|Windows Phone 8.1|Windows Phone 8.0|Windows Phone OS|XBLWP7|ZuneWP7|Windows NT 6.[23]; ARM;","iOS":"\\biPhone.*Mobile|\\biPod|\\biPad|AppleCoreMedia","iPadOS":"CPU OS 13","MeeGoOS":"MeeGo","MaemoOS":"Maemo","JavaOS":"J2ME\/|\\bMIDP\\b|\\bCLDC\\b","webOS":"webOS|hpwOS","badaOS":"\\bBada\\b","BREWOS":"BREW"},"utilities":{"Bot":"Googlebot|facebookexternalhit|Google-AMPHTML|s~amp-validator|AdsBot-Google|Google Keyword Suggestion|Facebot|YandexBot|YandexMobileBot|bingbot|ia_archiver|AhrefsBot|Ezooms|GSLFbot|WBSearchBot|Twitterbot|TweetmemeBot|Twikle|PaperLiBot|Wotbox|UnwindFetchor|Exabot|MJ12bot|YandexImages|TurnitinBot|Pingdom|contentkingapp","MobileBot":"Googlebot-Mobile|AdsBot-Google-Mobile|YahooSeeker\/M1A1-R2D2","DesktopMode":"WPDesktop","TV":"SonyDTV|HbbTV","WebKit":"(webkit)[ \/]([\\w.]+)","Console":"\\b(Nintendo|Nintendo WiiU|Nintendo 3DS|Nintendo Switch|PLAYSTATION|Xbox)\\b","Watch":"SM-V700"}}}
|
|
vendor/mobiledetect/mobiledetectlib/Mobile_Detect.php
DELETED
@@ -1,1477 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* Mobile Detect Library
|
4 |
-
* Motto: "Every business should have a mobile detection script to detect mobile readers"
|
5 |
-
*
|
6 |
-
* Mobile_Detect is a lightweight PHP class for detecting mobile devices (including tablets).
|
7 |
-
* It uses the User-Agent string combined with specific HTTP headers to detect the mobile environment.
|
8 |
-
*
|
9 |
-
* Homepage: http://mobiledetect.net
|
10 |
-
* GitHub: https://github.com/serbanghita/Mobile-Detect
|
11 |
-
* README: https://github.com/serbanghita/Mobile-Detect/blob/master/README.md
|
12 |
-
* CONTRIBUTING: https://github.com/serbanghita/Mobile-Detect/blob/master/docs/CONTRIBUTING.md
|
13 |
-
* KNOWN LIMITATIONS: https://github.com/serbanghita/Mobile-Detect/blob/master/docs/KNOWN_LIMITATIONS.md
|
14 |
-
* EXAMPLES: https://github.com/serbanghita/Mobile-Detect/wiki/Code-examples
|
15 |
-
*
|
16 |
-
* @license https://github.com/serbanghita/Mobile-Detect/blob/master/LICENSE.txt MIT License
|
17 |
-
* @author Serban Ghita <serbanghita@gmail.com>
|
18 |
-
* @author Nick Ilyin <nick.ilyin@gmail.com>
|
19 |
-
* Original author: Victor Stanciu <vic.stanciu@gmail.com>
|
20 |
-
*
|
21 |
-
* @version 2.8.34
|
22 |
-
*/
|
23 |
-
class Mobile_Detect
|
24 |
-
{
|
25 |
-
/**
|
26 |
-
* Mobile detection type.
|
27 |
-
*
|
28 |
-
* @deprecated since version 2.6.9
|
29 |
-
*/
|
30 |
-
const DETECTION_TYPE_MOBILE = 'mobile';
|
31 |
-
|
32 |
-
/**
|
33 |
-
* Extended detection type.
|
34 |
-
*
|
35 |
-
* @deprecated since version 2.6.9
|
36 |
-
*/
|
37 |
-
const DETECTION_TYPE_EXTENDED = 'extended';
|
38 |
-
|
39 |
-
/**
|
40 |
-
* A frequently used regular expression to extract version #s.
|
41 |
-
*
|
42 |
-
* @deprecated since version 2.6.9
|
43 |
-
*/
|
44 |
-
const VER = '([\w._\+]+)';
|
45 |
-
|
46 |
-
/**
|
47 |
-
* Top-level device.
|
48 |
-
*/
|
49 |
-
const MOBILE_GRADE_A = 'A';
|
50 |
-
|
51 |
-
/**
|
52 |
-
* Mid-level device.
|
53 |
-
*/
|
54 |
-
const MOBILE_GRADE_B = 'B';
|
55 |
-
|
56 |
-
/**
|
57 |
-
* Low-level device.
|
58 |
-
*/
|
59 |
-
const MOBILE_GRADE_C = 'C';
|
60 |
-
|
61 |
-
/**
|
62 |
-
* Stores the version number of the current release.
|
63 |
-
*/
|
64 |
-
const VERSION = '2.8.34';
|
65 |
-
|
66 |
-
/**
|
67 |
-
* A type for the version() method indicating a string return value.
|
68 |
-
*/
|
69 |
-
const VERSION_TYPE_STRING = 'text';
|
70 |
-
|
71 |
-
/**
|
72 |
-
* A type for the version() method indicating a float return value.
|
73 |
-
*/
|
74 |
-
const VERSION_TYPE_FLOAT = 'float';
|
75 |
-
|
76 |
-
/**
|
77 |
-
* A cache for resolved matches
|
78 |
-
* @var array
|
79 |
-
*/
|
80 |
-
protected $cache = array();
|
81 |
-
|
82 |
-
/**
|
83 |
-
* The User-Agent HTTP header is stored in here.
|
84 |
-
* @var string
|
85 |
-
*/
|
86 |
-
protected $userAgent = null;
|
87 |
-
|
88 |
-
/**
|
89 |
-
* HTTP headers in the PHP-flavor. So HTTP_USER_AGENT and SERVER_SOFTWARE.
|
90 |
-
* @var array
|
91 |
-
*/
|
92 |
-
protected $httpHeaders = array();
|
93 |
-
|
94 |
-
/**
|
95 |
-
* CloudFront headers. E.g. CloudFront-Is-Desktop-Viewer, CloudFront-Is-Mobile-Viewer & CloudFront-Is-Tablet-Viewer.
|
96 |
-
* @var array
|
97 |
-
*/
|
98 |
-
protected $cloudfrontHeaders = array();
|
99 |
-
|
100 |
-
/**
|
101 |
-
* The matching Regex.
|
102 |
-
* This is good for debug.
|
103 |
-
* @var string
|
104 |
-
*/
|
105 |
-
protected $matchingRegex = null;
|
106 |
-
|
107 |
-
/**
|
108 |
-
* The matches extracted from the regex expression.
|
109 |
-
* This is good for debug.
|
110 |
-
*
|
111 |
-
* @var string
|
112 |
-
*/
|
113 |
-
protected $matchesArray = null;
|
114 |
-
|
115 |
-
/**
|
116 |
-
* The detection type, using self::DETECTION_TYPE_MOBILE or self::DETECTION_TYPE_EXTENDED.
|
117 |
-
*
|
118 |
-
* @deprecated since version 2.6.9
|
119 |
-
*
|
120 |
-
* @var string
|
121 |
-
*/
|
122 |
-
protected $detectionType = self::DETECTION_TYPE_MOBILE;
|
123 |
-
|
124 |
-
/**
|
125 |
-
* HTTP headers that trigger the 'isMobile' detection
|
126 |
-
* to be true.
|
127 |
-
*
|
128 |
-
* @var array
|
129 |
-
*/
|
130 |
-
protected static $mobileHeaders = array(
|
131 |
-
|
132 |
-
'HTTP_ACCEPT' => array('matches' => array(
|
133 |
-
// Opera Mini; @reference: http://dev.opera.com/articles/view/opera-binary-markup-language/
|
134 |
-
'application/x-obml2d',
|
135 |
-
// BlackBerry devices.
|
136 |
-
'application/vnd.rim.html',
|
137 |
-
'text/vnd.wap.wml',
|
138 |
-
'application/vnd.wap.xhtml+xml'
|
139 |
-
)),
|
140 |
-
'HTTP_X_WAP_PROFILE' => null,
|
141 |
-
'HTTP_X_WAP_CLIENTID' => null,
|
142 |
-
'HTTP_WAP_CONNECTION' => null,
|
143 |
-
'HTTP_PROFILE' => null,
|
144 |
-
// Reported by Opera on Nokia devices (eg. C3).
|
145 |
-
'HTTP_X_OPERAMINI_PHONE_UA' => null,
|
146 |
-
'HTTP_X_NOKIA_GATEWAY_ID' => null,
|
147 |
-
'HTTP_X_ORANGE_ID' => null,
|
148 |
-
'HTTP_X_VODAFONE_3GPDPCONTEXT' => null,
|
149 |
-
'HTTP_X_HUAWEI_USERID' => null,
|
150 |
-
// Reported by Windows Smartphones.
|
151 |
-
'HTTP_UA_OS' => null,
|
152 |
-
// Reported by Verizon, Vodafone proxy system.
|
153 |
-
'HTTP_X_MOBILE_GATEWAY' => null,
|
154 |
-
// Seen this on HTC Sensation. SensationXE_Beats_Z715e.
|
155 |
-
'HTTP_X_ATT_DEVICEID' => null,
|
156 |
-
// Seen this on a HTC.
|
157 |
-
'HTTP_UA_CPU' => array('matches' => array('ARM')),
|
158 |
-
);
|
159 |
-
|
160 |
-
/**
|
161 |
-
* List of mobile devices (phones).
|
162 |
-
*
|
163 |
-
* @var array
|
164 |
-
*/
|
165 |
-
protected static $phoneDevices = array(
|
166 |
-
'iPhone' => '\biPhone\b|\biPod\b', // |\biTunes
|
167 |
-
'BlackBerry' => 'BlackBerry|\bBB10\b|rim[0-9]+|\b(BBA100|BBB100|BBD100|BBE100|BBF100|STH100)\b-[0-9]+',
|
168 |
-
'HTC' => 'HTC|HTC.*(Sensation|Evo|Vision|Explorer|6800|8100|8900|A7272|S510e|C110e|Legend|Desire|T8282)|APX515CKT|Qtek9090|APA9292KT|HD_mini|Sensation.*Z710e|PG86100|Z715e|Desire.*(A8181|HD)|ADR6200|ADR6400L|ADR6425|001HT|Inspire 4G|Android.*\bEVO\b|T-Mobile G1|Z520m|Android [0-9.]+; Pixel',
|
169 |
-
'Nexus' => 'Nexus One|Nexus S|Galaxy.*Nexus|Android.*Nexus.*Mobile|Nexus 4|Nexus 5|Nexus 6',
|
170 |
-
// @todo: Is 'Dell Streak' a tablet or a phone? ;)
|
171 |
-
'Dell' => 'Dell[;]? (Streak|Aero|Venue|Venue Pro|Flash|Smoke|Mini 3iX)|XCD28|XCD35|\b001DL\b|\b101DL\b|\bGS01\b',
|
172 |
-
'Motorola' => 'Motorola|DROIDX|DROID BIONIC|\bDroid\b.*Build|Android.*Xoom|HRI39|MOT-|A1260|A1680|A555|A853|A855|A953|A955|A956|Motorola.*ELECTRIFY|Motorola.*i1|i867|i940|MB200|MB300|MB501|MB502|MB508|MB511|MB520|MB525|MB526|MB611|MB612|MB632|MB810|MB855|MB860|MB861|MB865|MB870|ME501|ME502|ME511|ME525|ME600|ME632|ME722|ME811|ME860|ME863|ME865|MT620|MT710|MT716|MT720|MT810|MT870|MT917|Motorola.*TITANIUM|WX435|WX445|XT300|XT301|XT311|XT316|XT317|XT319|XT320|XT390|XT502|XT530|XT531|XT532|XT535|XT603|XT610|XT611|XT615|XT681|XT701|XT702|XT711|XT720|XT800|XT806|XT860|XT862|XT875|XT882|XT883|XT894|XT901|XT907|XT909|XT910|XT912|XT928|XT926|XT915|XT919|XT925|XT1021|\bMoto E\b|XT1068|XT1092|XT1052',
|
173 |
-
'Samsung' => '\bSamsung\b|SM-G950F|SM-G955F|SM-G9250|GT-19300|SGH-I337|BGT-S5230|GT-B2100|GT-B2700|GT-B2710|GT-B3210|GT-B3310|GT-B3410|GT-B3730|GT-B3740|GT-B5510|GT-B5512|GT-B5722|GT-B6520|GT-B7300|GT-B7320|GT-B7330|GT-B7350|GT-B7510|GT-B7722|GT-B7800|GT-C3010|GT-C3011|GT-C3060|GT-C3200|GT-C3212|GT-C3212I|GT-C3262|GT-C3222|GT-C3300|GT-C3300K|GT-C3303|GT-C3303K|GT-C3310|GT-C3322|GT-C3330|GT-C3350|GT-C3500|GT-C3510|GT-C3530|GT-C3630|GT-C3780|GT-C5010|GT-C5212|GT-C6620|GT-C6625|GT-C6712|GT-E1050|GT-E1070|GT-E1075|GT-E1080|GT-E1081|GT-E1085|GT-E1087|GT-E1100|GT-E1107|GT-E1110|GT-E1120|GT-E1125|GT-E1130|GT-E1160|GT-E1170|GT-E1175|GT-E1180|GT-E1182|GT-E1200|GT-E1210|GT-E1225|GT-E1230|GT-E1390|GT-E2100|GT-E2120|GT-E2121|GT-E2152|GT-E2220|GT-E2222|GT-E2230|GT-E2232|GT-E2250|GT-E2370|GT-E2550|GT-E2652|GT-E3210|GT-E3213|GT-I5500|GT-I5503|GT-I5700|GT-I5800|GT-I5801|GT-I6410|GT-I6420|GT-I7110|GT-I7410|GT-I7500|GT-I8000|GT-I8150|GT-I8160|GT-I8190|GT-I8320|GT-I8330|GT-I8350|GT-I8530|GT-I8700|GT-I8703|GT-I8910|GT-I9000|GT-I9001|GT-I9003|GT-I9010|GT-I9020|GT-I9023|GT-I9070|GT-I9082|GT-I9100|GT-I9103|GT-I9220|GT-I9250|GT-I9300|GT-I9305|GT-I9500|GT-I9505|GT-M3510|GT-M5650|GT-M7500|GT-M7600|GT-M7603|GT-M8800|GT-M8910|GT-N7000|GT-S3110|GT-S3310|GT-S3350|GT-S3353|GT-S3370|GT-S3650|GT-S3653|GT-S3770|GT-S3850|GT-S5210|GT-S5220|GT-S5229|GT-S5230|GT-S5233|GT-S5250|GT-S5253|GT-S5260|GT-S5263|GT-S5270|GT-S5300|GT-S5330|GT-S5350|GT-S5360|GT-S5363|GT-S5369|GT-S5380|GT-S5380D|GT-S5560|GT-S5570|GT-S5600|GT-S5603|GT-S5610|GT-S5620|GT-S5660|GT-S5670|GT-S5690|GT-S5750|GT-S5780|GT-S5830|GT-S5839|GT-S6102|GT-S6500|GT-S7070|GT-S7200|GT-S7220|GT-S7230|GT-S7233|GT-S7250|GT-S7500|GT-S7530|GT-S7550|GT-S7562|GT-S7710|GT-S8000|GT-S8003|GT-S8500|GT-S8530|GT-S8600|SCH-A310|SCH-A530|SCH-A570|SCH-A610|SCH-A630|SCH-A650|SCH-A790|SCH-A795|SCH-A850|SCH-A870|SCH-A890|SCH-A930|SCH-A950|SCH-A970|SCH-A990|SCH-I100|SCH-I110|SCH-I400|SCH-I405|SCH-I500|SCH-I510|SCH-I515|SCH-I600|SCH-I730|SCH-I760|SCH-I770|SCH-I830|SCH-I910|SCH-I920|SCH-I959|SCH-LC11|SCH-N150|SCH-N300|SCH-R100|SCH-R300|SCH-R351|SCH-R400|SCH-R410|SCH-T300|SCH-U310|SCH-U320|SCH-U350|SCH-U360|SCH-U365|SCH-U370|SCH-U380|SCH-U410|SCH-U430|SCH-U450|SCH-U460|SCH-U470|SCH-U490|SCH-U540|SCH-U550|SCH-U620|SCH-U640|SCH-U650|SCH-U660|SCH-U700|SCH-U740|SCH-U750|SCH-U810|SCH-U820|SCH-U900|SCH-U940|SCH-U960|SCS-26UC|SGH-A107|SGH-A117|SGH-A127|SGH-A137|SGH-A157|SGH-A167|SGH-A177|SGH-A187|SGH-A197|SGH-A227|SGH-A237|SGH-A257|SGH-A437|SGH-A517|SGH-A597|SGH-A637|SGH-A657|SGH-A667|SGH-A687|SGH-A697|SGH-A707|SGH-A717|SGH-A727|SGH-A737|SGH-A747|SGH-A767|SGH-A777|SGH-A797|SGH-A817|SGH-A827|SGH-A837|SGH-A847|SGH-A867|SGH-A877|SGH-A887|SGH-A897|SGH-A927|SGH-B100|SGH-B130|SGH-B200|SGH-B220|SGH-C100|SGH-C110|SGH-C120|SGH-C130|SGH-C140|SGH-C160|SGH-C170|SGH-C180|SGH-C200|SGH-C207|SGH-C210|SGH-C225|SGH-C230|SGH-C417|SGH-C450|SGH-D307|SGH-D347|SGH-D357|SGH-D407|SGH-D415|SGH-D780|SGH-D807|SGH-D980|SGH-E105|SGH-E200|SGH-E315|SGH-E316|SGH-E317|SGH-E335|SGH-E590|SGH-E635|SGH-E715|SGH-E890|SGH-F300|SGH-F480|SGH-I200|SGH-I300|SGH-I320|SGH-I550|SGH-I577|SGH-I600|SGH-I607|SGH-I617|SGH-I627|SGH-I637|SGH-I677|SGH-I700|SGH-I717|SGH-I727|SGH-i747M|SGH-I777|SGH-I780|SGH-I827|SGH-I847|SGH-I857|SGH-I896|SGH-I897|SGH-I900|SGH-I907|SGH-I917|SGH-I927|SGH-I937|SGH-I997|SGH-J150|SGH-J200|SGH-L170|SGH-L700|SGH-M110|SGH-M150|SGH-M200|SGH-N105|SGH-N500|SGH-N600|SGH-N620|SGH-N625|SGH-N700|SGH-N710|SGH-P107|SGH-P207|SGH-P300|SGH-P310|SGH-P520|SGH-P735|SGH-P777|SGH-Q105|SGH-R210|SGH-R220|SGH-R225|SGH-S105|SGH-S307|SGH-T109|SGH-T119|SGH-T139|SGH-T209|SGH-T219|SGH-T229|SGH-T239|SGH-T249|SGH-T259|SGH-T309|SGH-T319|SGH-T329|SGH-T339|SGH-T349|SGH-T359|SGH-T369|SGH-T379|SGH-T409|SGH-T429|SGH-T439|SGH-T459|SGH-T469|SGH-T479|SGH-T499|SGH-T509|SGH-T519|SGH-T539|SGH-T559|SGH-T589|SGH-T609|SGH-T619|SGH-T629|SGH-T639|SGH-T659|SGH-T669|SGH-T679|SGH-T709|SGH-T719|SGH-T729|SGH-T739|SGH-T746|SGH-T749|SGH-T759|SGH-T769|SGH-T809|SGH-T819|SGH-T839|SGH-T919|SGH-T929|SGH-T939|SGH-T959|SGH-T989|SGH-U100|SGH-U200|SGH-U800|SGH-V205|SGH-V206|SGH-X100|SGH-X105|SGH-X120|SGH-X140|SGH-X426|SGH-X427|SGH-X475|SGH-X495|SGH-X497|SGH-X507|SGH-X600|SGH-X610|SGH-X620|SGH-X630|SGH-X700|SGH-X820|SGH-X890|SGH-Z130|SGH-Z150|SGH-Z170|SGH-ZX10|SGH-ZX20|SHW-M110|SPH-A120|SPH-A400|SPH-A420|SPH-A460|SPH-A500|SPH-A560|SPH-A600|SPH-A620|SPH-A660|SPH-A700|SPH-A740|SPH-A760|SPH-A790|SPH-A800|SPH-A820|SPH-A840|SPH-A880|SPH-A900|SPH-A940|SPH-A960|SPH-D600|SPH-D700|SPH-D710|SPH-D720|SPH-I300|SPH-I325|SPH-I330|SPH-I350|SPH-I500|SPH-I600|SPH-I700|SPH-L700|SPH-M100|SPH-M220|SPH-M240|SPH-M300|SPH-M305|SPH-M320|SPH-M330|SPH-M350|SPH-M360|SPH-M370|SPH-M380|SPH-M510|SPH-M540|SPH-M550|SPH-M560|SPH-M570|SPH-M580|SPH-M610|SPH-M620|SPH-M630|SPH-M800|SPH-M810|SPH-M850|SPH-M900|SPH-M910|SPH-M920|SPH-M930|SPH-N100|SPH-N200|SPH-N240|SPH-N300|SPH-N400|SPH-Z400|SWC-E100|SCH-i909|GT-N7100|GT-N7105|SCH-I535|SM-N900A|SGH-I317|SGH-T999L|GT-S5360B|GT-I8262|GT-S6802|GT-S6312|GT-S6310|GT-S5312|GT-S5310|GT-I9105|GT-I8510|GT-S6790N|SM-G7105|SM-N9005|GT-S5301|GT-I9295|GT-I9195|SM-C101|GT-S7392|GT-S7560|GT-B7610|GT-I5510|GT-S7582|GT-S7530E|GT-I8750|SM-G9006V|SM-G9008V|SM-G9009D|SM-G900A|SM-G900D|SM-G900F|SM-G900H|SM-G900I|SM-G900J|SM-G900K|SM-G900L|SM-G900M|SM-G900P|SM-G900R4|SM-G900S|SM-G900T|SM-G900V|SM-G900W8|SHV-E160K|SCH-P709|SCH-P729|SM-T2558|GT-I9205|SM-G9350|SM-J120F|SM-G920F|SM-G920V|SM-G930F|SM-N910C|SM-A310F|GT-I9190|SM-J500FN|SM-G903F|SM-J330F',
|
174 |
-
'LG' => '\bLG\b;|LG[- ]?(C800|C900|E400|E610|E900|E-900|F160|F180K|F180L|F180S|730|855|L160|LS740|LS840|LS970|LU6200|MS690|MS695|MS770|MS840|MS870|MS910|P500|P700|P705|VM696|AS680|AS695|AX840|C729|E970|GS505|272|C395|E739BK|E960|L55C|L75C|LS696|LS860|P769BK|P350|P500|P509|P870|UN272|US730|VS840|VS950|LN272|LN510|LS670|LS855|LW690|MN270|MN510|P509|P769|P930|UN200|UN270|UN510|UN610|US670|US740|US760|UX265|UX840|VN271|VN530|VS660|VS700|VS740|VS750|VS910|VS920|VS930|VX9200|VX11000|AX840A|LW770|P506|P925|P999|E612|D955|D802|MS323|M257)|LM-G710',
|
175 |
-
'Sony' => 'SonyST|SonyLT|SonyEricsson|SonyEricssonLT15iv|LT18i|E10i|LT28h|LT26w|SonyEricssonMT27i|C5303|C6902|C6903|C6906|C6943|D2533',
|
176 |
-
'Asus' => 'Asus.*Galaxy|PadFone.*Mobile',
|
177 |
-
'NokiaLumia' => 'Lumia [0-9]{3,4}',
|
178 |
-
// http://www.micromaxinfo.com/mobiles/smartphones
|
179 |
-
// Added because the codes might conflict with Acer Tablets.
|
180 |
-
'Micromax' => 'Micromax.*\b(A210|A92|A88|A72|A111|A110Q|A115|A116|A110|A90S|A26|A51|A35|A54|A25|A27|A89|A68|A65|A57|A90)\b',
|
181 |
-
// @todo Complete the regex.
|
182 |
-
'Palm' => 'PalmSource|Palm', // avantgo|blazer|elaine|hiptop|plucker|xiino ;
|
183 |
-
'Vertu' => 'Vertu|Vertu.*Ltd|Vertu.*Ascent|Vertu.*Ayxta|Vertu.*Constellation(F|Quest)?|Vertu.*Monika|Vertu.*Signature', // Just for fun ;)
|
184 |
-
// http://www.pantech.co.kr/en/prod/prodList.do?gbrand=VEGA (PANTECH)
|
185 |
-
// Most of the VEGA devices are legacy. PANTECH seem to be newer devices based on Android.
|
186 |
-
'Pantech' => 'PANTECH|IM-A850S|IM-A840S|IM-A830L|IM-A830K|IM-A830S|IM-A820L|IM-A810K|IM-A810S|IM-A800S|IM-T100K|IM-A725L|IM-A780L|IM-A775C|IM-A770K|IM-A760S|IM-A750K|IM-A740S|IM-A730S|IM-A720L|IM-A710K|IM-A690L|IM-A690S|IM-A650S|IM-A630K|IM-A600S|VEGA PTL21|PT003|P8010|ADR910L|P6030|P6020|P9070|P4100|P9060|P5000|CDM8992|TXT8045|ADR8995|IS11PT|P2030|P6010|P8000|PT002|IS06|CDM8999|P9050|PT001|TXT8040|P2020|P9020|P2000|P7040|P7000|C790',
|
187 |
-
// http://www.fly-phone.com/devices/smartphones/ ; Included only smartphones.
|
188 |
-
'Fly' => 'IQ230|IQ444|IQ450|IQ440|IQ442|IQ441|IQ245|IQ256|IQ236|IQ255|IQ235|IQ245|IQ275|IQ240|IQ285|IQ280|IQ270|IQ260|IQ250',
|
189 |
-
// http://fr.wikomobile.com
|
190 |
-
'Wiko' => 'KITE 4G|HIGHWAY|GETAWAY|STAIRWAY|DARKSIDE|DARKFULL|DARKNIGHT|DARKMOON|SLIDE|WAX 4G|RAINBOW|BLOOM|SUNSET|GOA(?!nna)|LENNY|BARRY|IGGY|OZZY|CINK FIVE|CINK PEAX|CINK PEAX 2|CINK SLIM|CINK SLIM 2|CINK +|CINK KING|CINK PEAX|CINK SLIM|SUBLIM',
|
191 |
-
'iMobile' => 'i-mobile (IQ|i-STYLE|idea|ZAA|Hitz)',
|
192 |
-
// Added simvalley mobile just for fun. They have some interesting devices.
|
193 |
-
// http://www.simvalley.fr/telephonie---gps-_22_telephonie-mobile_telephones_.html
|
194 |
-
'SimValley' => '\b(SP-80|XT-930|SX-340|XT-930|SX-310|SP-360|SP60|SPT-800|SP-120|SPT-800|SP-140|SPX-5|SPX-8|SP-100|SPX-8|SPX-12)\b',
|
195 |
-
// Wolfgang - a brand that is sold by Aldi supermarkets.
|
196 |
-
// http://www.wolfgangmobile.com/
|
197 |
-
'Wolfgang' => 'AT-B24D|AT-AS50HD|AT-AS40W|AT-AS55HD|AT-AS45q2|AT-B26D|AT-AS50Q',
|
198 |
-
'Alcatel' => 'Alcatel',
|
199 |
-
'Nintendo' => 'Nintendo (3DS|Switch)',
|
200 |
-
// http://en.wikipedia.org/wiki/Amoi
|
201 |
-
'Amoi' => 'Amoi',
|
202 |
-
// http://en.wikipedia.org/wiki/INQ
|
203 |
-
'INQ' => 'INQ',
|
204 |
-
'OnePlus' => 'ONEPLUS',
|
205 |
-
// @Tapatalk is a mobile app; http://support.tapatalk.com/threads/smf-2-0-2-os-and-browser-detection-plugin-and-tapatalk.15565/#post-79039
|
206 |
-
'GenericPhone' => 'Tapatalk|PDA;|SAGEM|\bmmp\b|pocket|\bpsp\b|symbian|Smartphone|smartfon|treo|up.browser|up.link|vodafone|\bwap\b|nokia|Series40|Series60|S60|SonyEricsson|N900|MAUI.*WAP.*Browser',
|
207 |
-
);
|
208 |
-
|
209 |
-
/**
|
210 |
-
* List of tablet devices.
|
211 |
-
*
|
212 |
-
* @var array
|
213 |
-
*/
|
214 |
-
protected static $tabletDevices = array(
|
215 |
-
// @todo: check for mobile friendly emails topic.
|
216 |
-
'iPad' => 'iPad|iPad.*Mobile',
|
217 |
-
// Removed |^.*Android.*Nexus(?!(?:Mobile).)*$
|
218 |
-
// @see #442
|
219 |
-
// @todo Merge NexusTablet into GoogleTablet.
|
220 |
-
'NexusTablet' => 'Android.*Nexus[\s]+(7|9|10)',
|
221 |
-
// https://en.wikipedia.org/wiki/Pixel_C
|
222 |
-
'GoogleTablet' => 'Android.*Pixel C',
|
223 |
-
'SamsungTablet' => 'SAMSUNG.*Tablet|Galaxy.*Tab|SC-01C|GT-P1000|GT-P1003|GT-P1010|GT-P3105|GT-P6210|GT-P6800|GT-P6810|GT-P7100|GT-P7300|GT-P7310|GT-P7500|GT-P7510|SCH-I800|SCH-I815|SCH-I905|SGH-I957|SGH-I987|SGH-T849|SGH-T859|SGH-T869|SPH-P100|GT-P3100|GT-P3108|GT-P3110|GT-P5100|GT-P5110|GT-P6200|GT-P7320|GT-P7511|GT-N8000|GT-P8510|SGH-I497|SPH-P500|SGH-T779|SCH-I705|SCH-I915|GT-N8013|GT-P3113|GT-P5113|GT-P8110|GT-N8010|GT-N8005|GT-N8020|GT-P1013|GT-P6201|GT-P7501|GT-N5100|GT-N5105|GT-N5110|SHV-E140K|SHV-E140L|SHV-E140S|SHV-E150S|SHV-E230K|SHV-E230L|SHV-E230S|SHW-M180K|SHW-M180L|SHW-M180S|SHW-M180W|SHW-M300W|SHW-M305W|SHW-M380K|SHW-M380S|SHW-M380W|SHW-M430W|SHW-M480K|SHW-M480S|SHW-M480W|SHW-M485W|SHW-M486W|SHW-M500W|GT-I9228|SCH-P739|SCH-I925|GT-I9200|GT-P5200|GT-P5210|GT-P5210X|SM-T311|SM-T310|SM-T310X|SM-T210|SM-T210R|SM-T211|SM-P600|SM-P601|SM-P605|SM-P900|SM-P901|SM-T217|SM-T217A|SM-T217S|SM-P6000|SM-T3100|SGH-I467|XE500|SM-T110|GT-P5220|GT-I9200X|GT-N5110X|GT-N5120|SM-P905|SM-T111|SM-T2105|SM-T315|SM-T320|SM-T320X|SM-T321|SM-T520|SM-T525|SM-T530NU|SM-T230NU|SM-T330NU|SM-T900|XE500T1C|SM-P605V|SM-P905V|SM-T337V|SM-T537V|SM-T707V|SM-T807V|SM-P600X|SM-P900X|SM-T210X|SM-T230|SM-T230X|SM-T325|GT-P7503|SM-T531|SM-T330|SM-T530|SM-T705|SM-T705C|SM-T535|SM-T331|SM-T800|SM-T700|SM-T537|SM-T807|SM-P907A|SM-T337A|SM-T537A|SM-T707A|SM-T807A|SM-T237|SM-T807P|SM-P607T|SM-T217T|SM-T337T|SM-T807T|SM-T116NQ|SM-T116BU|SM-P550|SM-T350|SM-T550|SM-T9000|SM-P9000|SM-T705Y|SM-T805|GT-P3113|SM-T710|SM-T810|SM-T815|SM-T360|SM-T533|SM-T113|SM-T335|SM-T715|SM-T560|SM-T670|SM-T677|SM-T377|SM-T567|SM-T357T|SM-T555|SM-T561|SM-T713|SM-T719|SM-T813|SM-T819|SM-T580|SM-T355Y?|SM-T280|SM-T817A|SM-T820|SM-W700|SM-P580|SM-T587|SM-P350|SM-P555M|SM-P355M|SM-T113NU|SM-T815Y|SM-T585|SM-T285|SM-T825|SM-W708|SM-T835|SM-T830|SM-T837V|SM-T720|SM-T510|SM-T387V', // SCH-P709|SCH-P729|SM-T2558|GT-I9205 - Samsung Mega - treat them like a regular phone.
|
224 |
-
// http://docs.aws.amazon.com/silk/latest/developerguide/user-agent.html
|
225 |
-
'Kindle' => 'Kindle|Silk.*Accelerated|Android.*\b(KFOT|KFTT|KFJWI|KFJWA|KFOTE|KFSOWI|KFTHWI|KFTHWA|KFAPWI|KFAPWA|WFJWAE|KFSAWA|KFSAWI|KFASWI|KFARWI|KFFOWI|KFGIWI|KFMEWI)\b|Android.*Silk/[0-9.]+ like Chrome/[0-9.]+ (?!Mobile)',
|
226 |
-
// Only the Surface tablets with Windows RT are considered mobile.
|
227 |
-
// http://msdn.microsoft.com/en-us/library/ie/hh920767(v=vs.85).aspx
|
228 |
-
'SurfaceTablet' => 'Windows NT [0-9.]+; ARM;.*(Tablet|ARMBJS)',
|
229 |
-
// http://shopping1.hp.com/is-bin/INTERSHOP.enfinity/WFS/WW-USSMBPublicStore-Site/en_US/-/USD/ViewStandardCatalog-Browse?CatalogCategoryID=JfIQ7EN5lqMAAAEyDcJUDwMT
|
230 |
-
'HPTablet' => 'HP Slate (7|8|10)|HP ElitePad 900|hp-tablet|EliteBook.*Touch|HP 8|Slate 21|HP SlateBook 10',
|
231 |
-
// Watch out for PadFone, see #132.
|
232 |
-
// http://www.asus.com/de/Tablets_Mobile/Memo_Pad_Products/
|
233 |
-
'AsusTablet' => '^.*PadFone((?!Mobile).)*$|Transformer|TF101|TF101G|TF300T|TF300TG|TF300TL|TF700T|TF700KL|TF701T|TF810C|ME171|ME301T|ME302C|ME371MG|ME370T|ME372MG|ME172V|ME173X|ME400C|Slider SL101|\bK00F\b|\bK00C\b|\bK00E\b|\bK00L\b|TX201LA|ME176C|ME102A|\bM80TA\b|ME372CL|ME560CG|ME372CG|ME302KL| K010 | K011 | K017 | K01E |ME572C|ME103K|ME170C|ME171C|\bME70C\b|ME581C|ME581CL|ME8510C|ME181C|P01Y|PO1MA|P01Z|\bP027\b|\bP024\b|\bP00C\b',
|
234 |
-
'BlackBerryTablet' => 'PlayBook|RIM Tablet',
|
235 |
-
'HTCtablet' => 'HTC_Flyer_P512|HTC Flyer|HTC Jetstream|HTC-P715a|HTC EVO View 4G|PG41200|PG09410',
|
236 |
-
'MotorolaTablet' => 'xoom|sholest|MZ615|MZ605|MZ505|MZ601|MZ602|MZ603|MZ604|MZ606|MZ607|MZ608|MZ609|MZ615|MZ616|MZ617',
|
237 |
-
'NookTablet' => 'Android.*Nook|NookColor|nook browser|BNRV200|BNRV200A|BNTV250|BNTV250A|BNTV400|BNTV600|LogicPD Zoom2',
|
238 |
-
// http://www.acer.ro/ac/ro/RO/content/drivers
|
239 |
-
// http://www.packardbell.co.uk/pb/en/GB/content/download (Packard Bell is part of Acer)
|
240 |
-
// http://us.acer.com/ac/en/US/content/group/tablets
|
241 |
-
// http://www.acer.de/ac/de/DE/content/models/tablets/
|
242 |
-
// Can conflict with Micromax and Motorola phones codes.
|
243 |
-
'AcerTablet' => 'Android.*; \b(A100|A101|A110|A200|A210|A211|A500|A501|A510|A511|A700|A701|W500|W500P|W501|W501P|W510|W511|W700|G100|G100W|B1-A71|B1-710|B1-711|A1-810|A1-811|A1-830)\b|W3-810|\bA3-A10\b|\bA3-A11\b|\bA3-A20\b|\bA3-A30',
|
244 |
-
// http://eu.computers.toshiba-europe.com/innovation/family/Tablets/1098744/banner_id/tablet_footerlink/
|
245 |
-
// http://us.toshiba.com/tablets/tablet-finder
|
246 |
-
// http://www.toshiba.co.jp/regza/tablet/
|
247 |
-
'ToshibaTablet' => 'Android.*(AT100|AT105|AT200|AT205|AT270|AT275|AT300|AT305|AT1S5|AT500|AT570|AT700|AT830)|TOSHIBA.*FOLIO',
|
248 |
-
// http://www.nttdocomo.co.jp/english/service/developer/smart_phone/technical_info/spec/index.html
|
249 |
-
// http://www.lg.com/us/tablets
|
250 |
-
'LGTablet' => '\bL-06C|LG-V909|LG-V900|LG-V700|LG-V510|LG-V500|LG-V410|LG-V400|LG-VK810\b',
|
251 |
-
'FujitsuTablet' => 'Android.*\b(F-01D|F-02F|F-05E|F-10D|M532|Q572)\b',
|
252 |
-
// Prestigio Tablets http://www.prestigio.com/support
|
253 |
-
'PrestigioTablet' => 'PMP3170B|PMP3270B|PMP3470B|PMP7170B|PMP3370B|PMP3570C|PMP5870C|PMP3670B|PMP5570C|PMP5770D|PMP3970B|PMP3870C|PMP5580C|PMP5880D|PMP5780D|PMP5588C|PMP7280C|PMP7280C3G|PMP7280|PMP7880D|PMP5597D|PMP5597|PMP7100D|PER3464|PER3274|PER3574|PER3884|PER5274|PER5474|PMP5097CPRO|PMP5097|PMP7380D|PMP5297C|PMP5297C_QUAD|PMP812E|PMP812E3G|PMP812F|PMP810E|PMP880TD|PMT3017|PMT3037|PMT3047|PMT3057|PMT7008|PMT5887|PMT5001|PMT5002',
|
254 |
-
// http://support.lenovo.com/en_GB/downloads/default.page?#
|
255 |
-
'LenovoTablet' => 'Lenovo TAB|Idea(Tab|Pad)( A1|A10| K1|)|ThinkPad([ ]+)?Tablet|YT3-850M|YT3-X90L|YT3-X90F|YT3-X90X|Lenovo.*(S2109|S2110|S5000|S6000|K3011|A3000|A3500|A1000|A2107|A2109|A1107|A5500|A7600|B6000|B8000|B8080)(-|)(FL|F|HV|H|)|TB-X103F|TB-X304X|TB-X304F|TB-X304L|TB-X505F|TB-X505L|TB-X505X|TB-X605F|TB-X605L|TB-8703F|TB-8703X|TB-8703N|TB-8704N|TB-8704F|TB-8704X|TB-8704V|TB-7304F|TB-7304I|TB-7304X|Tab2A7-10F|Tab2A7-20F|TB2-X30L|YT3-X50L|YT3-X50F|YT3-X50M|YT-X705F|YT-X703F|YT-X703L|YT-X705L|YT-X705X|TB2-X30F|TB2-X30L|TB2-X30M|A2107A-F|A2107A-H|TB3-730F|TB3-730M|TB3-730X|TB-7504F|TB-7504X',
|
256 |
-
// http://www.dell.com/support/home/us/en/04/Products/tab_mob/tablets
|
257 |
-
'DellTablet' => 'Venue 11|Venue 8|Venue 7|Dell Streak 10|Dell Streak 7',
|
258 |
-
// http://www.yarvik.com/en/matrix/tablets/
|
259 |
-
'YarvikTablet' => 'Android.*\b(TAB210|TAB211|TAB224|TAB250|TAB260|TAB264|TAB310|TAB360|TAB364|TAB410|TAB411|TAB420|TAB424|TAB450|TAB460|TAB461|TAB464|TAB465|TAB467|TAB468|TAB07-100|TAB07-101|TAB07-150|TAB07-151|TAB07-152|TAB07-200|TAB07-201-3G|TAB07-210|TAB07-211|TAB07-212|TAB07-214|TAB07-220|TAB07-400|TAB07-485|TAB08-150|TAB08-200|TAB08-201-3G|TAB08-201-30|TAB09-100|TAB09-211|TAB09-410|TAB10-150|TAB10-201|TAB10-211|TAB10-400|TAB10-410|TAB13-201|TAB274EUK|TAB275EUK|TAB374EUK|TAB462EUK|TAB474EUK|TAB9-200)\b',
|
260 |
-
'MedionTablet' => 'Android.*\bOYO\b|LIFE.*(P9212|P9514|P9516|S9512)|LIFETAB',
|
261 |
-
'ArnovaTablet' => '97G4|AN10G2|AN7bG3|AN7fG3|AN8G3|AN8cG3|AN7G3|AN9G3|AN7dG3|AN7dG3ST|AN7dG3ChildPad|AN10bG3|AN10bG3DT|AN9G2',
|
262 |
-
// http://www.intenso.de/kategorie_en.php?kategorie=33
|
263 |
-
// @todo: http://www.nbhkdz.com/read/b8e64202f92a2df129126bff.html - investigate
|
264 |
-
'IntensoTablet' => 'INM8002KP|INM1010FP|INM805ND|Intenso Tab|TAB1004',
|
265 |
-
// IRU.ru Tablets http://www.iru.ru/catalog/soho/planetable/
|
266 |
-
'IRUTablet' => 'M702pro',
|
267 |
-
'MegafonTablet' => 'MegaFon V9|\bZTE V9\b|Android.*\bMT7A\b',
|
268 |
-
// http://www.e-boda.ro/tablete-pc.html
|
269 |
-
'EbodaTablet' => 'E-Boda (Supreme|Impresspeed|Izzycomm|Essential)',
|
270 |
-
// http://www.allview.ro/produse/droseries/lista-tablete-pc/
|
271 |
-
'AllViewTablet' => 'Allview.*(Viva|Alldro|City|Speed|All TV|Frenzy|Quasar|Shine|TX1|AX1|AX2)',
|
272 |
-
// http://wiki.archosfans.com/index.php?title=Main_Page
|
273 |
-
// @note Rewrite the regex format after we add more UAs.
|
274 |
-
'ArchosTablet' => '\b(101G9|80G9|A101IT)\b|Qilive 97R|Archos5|\bARCHOS (70|79|80|90|97|101|FAMILYPAD|)(b|c|)(G10| Cobalt| TITANIUM(HD|)| Xenon| Neon|XSK| 2| XS 2| PLATINUM| CARBON|GAMEPAD)\b',
|
275 |
-
// http://www.ainol.com/plugin.php?identifier=ainol&module=product
|
276 |
-
'AinolTablet' => 'NOVO7|NOVO8|NOVO10|Novo7Aurora|Novo7Basic|NOVO7PALADIN|novo9-Spark',
|
277 |
-
'NokiaLumiaTablet' => 'Lumia 2520',
|
278 |
-
// @todo: inspect http://esupport.sony.com/US/p/select-system.pl?DIRECTOR=DRIVER
|
279 |
-
// Readers http://www.atsuhiro-me.net/ebook/sony-reader/sony-reader-web-browser
|
280 |
-
// http://www.sony.jp/support/tablet/
|
281 |
-
'SonyTablet' => 'Sony.*Tablet|Xperia Tablet|Sony Tablet S|SO-03E|SGPT12|SGPT13|SGPT114|SGPT121|SGPT122|SGPT123|SGPT111|SGPT112|SGPT113|SGPT131|SGPT132|SGPT133|SGPT211|SGPT212|SGPT213|SGP311|SGP312|SGP321|EBRD1101|EBRD1102|EBRD1201|SGP351|SGP341|SGP511|SGP512|SGP521|SGP541|SGP551|SGP621|SGP641|SGP612|SOT31|SGP771|SGP611|SGP612|SGP712',
|
282 |
-
// http://www.support.philips.com/support/catalog/worldproducts.jsp?userLanguage=en&userCountry=cn&categoryid=3G_LTE_TABLET_SU_CN_CARE&title=3G%20tablets%20/%20LTE%20range&_dyncharset=UTF-8
|
283 |
-
'PhilipsTablet' => '\b(PI2010|PI3000|PI3100|PI3105|PI3110|PI3205|PI3210|PI3900|PI4010|PI7000|PI7100)\b',
|
284 |
-
// db + http://www.cube-tablet.com/buy-products.html
|
285 |
-
'CubeTablet' => 'Android.*(K8GT|U9GT|U10GT|U16GT|U17GT|U18GT|U19GT|U20GT|U23GT|U30GT)|CUBE U8GT',
|
286 |
-
// http://www.cobyusa.com/?p=pcat&pcat_id=3001
|
287 |
-
'CobyTablet' => 'MID1042|MID1045|MID1125|MID1126|MID7012|MID7014|MID7015|MID7034|MID7035|MID7036|MID7042|MID7048|MID7127|MID8042|MID8048|MID8127|MID9042|MID9740|MID9742|MID7022|MID7010',
|
288 |
-
// http://www.match.net.cn/products.asp
|
289 |
-
'MIDTablet' => 'M9701|M9000|M9100|M806|M1052|M806|T703|MID701|MID713|MID710|MID727|MID760|MID830|MID728|MID933|MID125|MID810|MID732|MID120|MID930|MID800|MID731|MID900|MID100|MID820|MID735|MID980|MID130|MID833|MID737|MID960|MID135|MID860|MID736|MID140|MID930|MID835|MID733|MID4X10',
|
290 |
-
// http://www.msi.com/support
|
291 |
-
// @todo Research the Windows Tablets.
|
292 |
-
'MSITablet' => 'MSI \b(Primo 73K|Primo 73L|Primo 81L|Primo 77|Primo 93|Primo 75|Primo 76|Primo 73|Primo 81|Primo 91|Primo 90|Enjoy 71|Enjoy 7|Enjoy 10)\b',
|
293 |
-
// @todo http://www.kyoceramobile.com/support/drivers/
|
294 |
-
// 'KyoceraTablet' => null,
|
295 |
-
// @todo http://intexuae.com/index.php/category/mobile-devices/tablets-products/
|
296 |
-
// 'IntextTablet' => null,
|
297 |
-
// http://pdadb.net/index.php?m=pdalist&list=SMiT (NoName Chinese Tablets)
|
298 |
-
// http://www.imp3.net/14/show.php?itemid=20454
|
299 |
-
'SMiTTablet' => 'Android.*(\bMID\b|MID-560|MTV-T1200|MTV-PND531|MTV-P1101|MTV-PND530)',
|
300 |
-
// http://www.rock-chips.com/index.php?do=prod&pid=2
|
301 |
-
'RockChipTablet' => 'Android.*(RK2818|RK2808A|RK2918|RK3066)|RK2738|RK2808A',
|
302 |
-
// http://www.fly-phone.com/devices/tablets/ ; http://www.fly-phone.com/service/
|
303 |
-
'FlyTablet' => 'IQ310|Fly Vision',
|
304 |
-
// http://www.bqreaders.com/gb/tablets-prices-sale.html
|
305 |
-
'bqTablet' => 'Android.*(bq)?.*\b(Elcano|Curie|Edison|Maxwell|Kepler|Pascal|Tesla|Hypatia|Platon|Newton|Livingstone|Cervantes|Avant|Aquaris ([E|M]10|M8))\b|Maxwell.*Lite|Maxwell.*Plus',
|
306 |
-
// http://www.huaweidevice.com/worldwide/productFamily.do?method=index&directoryId=5011&treeId=3290
|
307 |
-
// http://www.huaweidevice.com/worldwide/downloadCenter.do?method=index&directoryId=3372&treeId=0&tb=1&type=software (including legacy tablets)
|
308 |
-
'HuaweiTablet' => 'MediaPad|MediaPad 7 Youth|IDEOS S7|S7-201c|S7-202u|S7-101|S7-103|S7-104|S7-105|S7-106|S7-201|S7-Slim|M2-A01L|BAH-L09|BAH-W09|AGS-L09|CMR-AL19',
|
309 |
-
// Nec or Medias Tab
|
310 |
-
'NecTablet' => '\bN-06D|\bN-08D',
|
311 |
-
// Pantech Tablets: http://www.pantechusa.com/phones/
|
312 |
-
'PantechTablet' => 'Pantech.*P4100',
|
313 |
-
// Broncho Tablets: http://www.broncho.cn/ (hard to find)
|
314 |
-
'BronchoTablet' => 'Broncho.*(N701|N708|N802|a710)',
|
315 |
-
// http://versusuk.com/support.html
|
316 |
-
'VersusTablet' => 'TOUCHPAD.*[78910]|\bTOUCHTAB\b',
|
317 |
-
// http://www.zync.in/index.php/our-products/tablet-phablets
|
318 |
-
'ZyncTablet' => 'z1000|Z99 2G|z930|z990|z909|Z919|z900', // Removed "z999" because of https://github.com/serbanghita/Mobile-Detect/issues/717
|
319 |
-
// http://www.positivoinformatica.com.br/www/pessoal/tablet-ypy/
|
320 |
-
'PositivoTablet' => 'TB07STA|TB10STA|TB07FTA|TB10FTA',
|
321 |
-
// https://www.nabitablet.com/
|
322 |
-
'NabiTablet' => 'Android.*\bNabi',
|
323 |
-
'KoboTablet' => 'Kobo Touch|\bK080\b|\bVox\b Build|\bArc\b Build',
|
324 |
-
// French Danew Tablets http://www.danew.com/produits-tablette.php
|
325 |
-
'DanewTablet' => 'DSlide.*\b(700|701R|702|703R|704|802|970|971|972|973|974|1010|1012)\b',
|
326 |
-
// Texet Tablets and Readers http://www.texet.ru/tablet/
|
327 |
-
'TexetTablet' => 'NaviPad|TB-772A|TM-7045|TM-7055|TM-9750|TM-7016|TM-7024|TM-7026|TM-7041|TM-7043|TM-7047|TM-8041|TM-9741|TM-9747|TM-9748|TM-9751|TM-7022|TM-7021|TM-7020|TM-7011|TM-7010|TM-7023|TM-7025|TM-7037W|TM-7038W|TM-7027W|TM-9720|TM-9725|TM-9737W|TM-1020|TM-9738W|TM-9740|TM-9743W|TB-807A|TB-771A|TB-727A|TB-725A|TB-719A|TB-823A|TB-805A|TB-723A|TB-715A|TB-707A|TB-705A|TB-709A|TB-711A|TB-890HD|TB-880HD|TB-790HD|TB-780HD|TB-770HD|TB-721HD|TB-710HD|TB-434HD|TB-860HD|TB-840HD|TB-760HD|TB-750HD|TB-740HD|TB-730HD|TB-722HD|TB-720HD|TB-700HD|TB-500HD|TB-470HD|TB-431HD|TB-430HD|TB-506|TB-504|TB-446|TB-436|TB-416|TB-146SE|TB-126SE',
|
328 |
-
// Avoid detecting 'PLAYSTATION 3' as mobile.
|
329 |
-
'PlaystationTablet' => 'Playstation.*(Portable|Vita)',
|
330 |
-
// http://www.trekstor.de/surftabs.html
|
331 |
-
'TrekstorTablet' => 'ST10416-1|VT10416-1|ST70408-1|ST702xx-1|ST702xx-2|ST80208|ST97216|ST70104-2|VT10416-2|ST10216-2A|SurfTab',
|
332 |
-
// http://www.pyleaudio.com/Products.aspx?%2fproducts%2fPersonal-Electronics%2fTablets
|
333 |
-
'PyleAudioTablet' => '\b(PTBL10CEU|PTBL10C|PTBL72BC|PTBL72BCEU|PTBL7CEU|PTBL7C|PTBL92BC|PTBL92BCEU|PTBL9CEU|PTBL9CUK|PTBL9C)\b',
|
334 |
-
// http://www.advandigital.com/index.php?link=content-product&jns=JP001
|
335 |
-
// because of the short codenames we have to include whitespaces to reduce the possible conflicts.
|
336 |
-
'AdvanTablet' => 'Android.* \b(E3A|T3X|T5C|T5B|T3E|T3C|T3B|T1J|T1F|T2A|T1H|T1i|E1C|T1-E|T5-A|T4|E1-B|T2Ci|T1-B|T1-D|O1-A|E1-A|T1-A|T3A|T4i)\b ',
|
337 |
-
// http://www.danytech.com/category/tablet-pc
|
338 |
-
'DanyTechTablet' => 'Genius Tab G3|Genius Tab S2|Genius Tab Q3|Genius Tab G4|Genius Tab Q4|Genius Tab G-II|Genius TAB GII|Genius TAB GIII|Genius Tab S1',
|
339 |
-
// http://www.galapad.net/product.html
|
340 |
-
'GalapadTablet' => 'Android.*\bG1\b(?!\))',
|
341 |
-
// http://www.micromaxinfo.com/tablet/funbook
|
342 |
-
'MicromaxTablet' => 'Funbook|Micromax.*\b(P250|P560|P360|P362|P600|P300|P350|P500|P275)\b',
|
343 |
-
// http://www.karbonnmobiles.com/products_tablet.php
|
344 |
-
'KarbonnTablet' => 'Android.*\b(A39|A37|A34|ST8|ST10|ST7|Smart Tab3|Smart Tab2)\b',
|
345 |
-
// http://www.myallfine.com/Products.asp
|
346 |
-
'AllFineTablet' => 'Fine7 Genius|Fine7 Shine|Fine7 Air|Fine8 Style|Fine9 More|Fine10 Joy|Fine11 Wide',
|
347 |
-
// http://www.proscanvideo.com/products-search.asp?itemClass=TABLET&itemnmbr=
|
348 |
-
'PROSCANTablet' => '\b(PEM63|PLT1023G|PLT1041|PLT1044|PLT1044G|PLT1091|PLT4311|PLT4311PL|PLT4315|PLT7030|PLT7033|PLT7033D|PLT7035|PLT7035D|PLT7044K|PLT7045K|PLT7045KB|PLT7071KG|PLT7072|PLT7223G|PLT7225G|PLT7777G|PLT7810K|PLT7849G|PLT7851G|PLT7852G|PLT8015|PLT8031|PLT8034|PLT8036|PLT8080K|PLT8082|PLT8088|PLT8223G|PLT8234G|PLT8235G|PLT8816K|PLT9011|PLT9045K|PLT9233G|PLT9735|PLT9760G|PLT9770G)\b',
|
349 |
-
// http://www.yonesnav.com/products/products.php
|
350 |
-
'YONESTablet' => 'BQ1078|BC1003|BC1077|RK9702|BC9730|BC9001|IT9001|BC7008|BC7010|BC708|BC728|BC7012|BC7030|BC7027|BC7026',
|
351 |
-
// http://www.cjshowroom.com/eproducts.aspx?classcode=004001001
|
352 |
-
// China manufacturer makes tablets for different small brands (eg. http://www.zeepad.net/index.html)
|
353 |
-
'ChangJiaTablet' => 'TPC7102|TPC7103|TPC7105|TPC7106|TPC7107|TPC7201|TPC7203|TPC7205|TPC7210|TPC7708|TPC7709|TPC7712|TPC7110|TPC8101|TPC8103|TPC8105|TPC8106|TPC8203|TPC8205|TPC8503|TPC9106|TPC9701|TPC97101|TPC97103|TPC97105|TPC97106|TPC97111|TPC97113|TPC97203|TPC97603|TPC97809|TPC97205|TPC10101|TPC10103|TPC10106|TPC10111|TPC10203|TPC10205|TPC10503',
|
354 |
-
// http://www.gloryunion.cn/products.asp
|
355 |
-
// http://www.allwinnertech.com/en/apply/mobile.html
|
356 |
-
// http://www.ptcl.com.pk/pd_content.php?pd_id=284 (EVOTAB)
|
357 |
-
// @todo: Softwiner tablets?
|
358 |
-
// aka. Cute or Cool tablets. Not sure yet, must research to avoid collisions.
|
359 |
-
'GUTablet' => 'TX-A1301|TX-M9002|Q702|kf026', // A12R|D75A|D77|D79|R83|A95|A106C|R15|A75|A76|D71|D72|R71|R73|R77|D82|R85|D92|A97|D92|R91|A10F|A77F|W71F|A78F|W78F|W81F|A97F|W91F|W97F|R16G|C72|C73E|K72|K73|R96G
|
360 |
-
// http://www.pointofview-online.com/showroom.php?shop_mode=product_listing&category_id=118
|
361 |
-
'PointOfViewTablet' => 'TAB-P506|TAB-navi-7-3G-M|TAB-P517|TAB-P-527|TAB-P701|TAB-P703|TAB-P721|TAB-P731N|TAB-P741|TAB-P825|TAB-P905|TAB-P925|TAB-PR945|TAB-PL1015|TAB-P1025|TAB-PI1045|TAB-P1325|TAB-PROTAB[0-9]+|TAB-PROTAB25|TAB-PROTAB26|TAB-PROTAB27|TAB-PROTAB26XL|TAB-PROTAB2-IPS9|TAB-PROTAB30-IPS9|TAB-PROTAB25XXL|TAB-PROTAB26-IPS10|TAB-PROTAB30-IPS10',
|
362 |
-
// http://www.overmax.pl/pl/katalog-produktow,p8/tablety,c14/
|
363 |
-
// @todo: add more tests.
|
364 |
-
'OvermaxTablet' => 'OV-(SteelCore|NewBase|Basecore|Baseone|Exellen|Quattor|EduTab|Solution|ACTION|BasicTab|TeddyTab|MagicTab|Stream|TB-08|TB-09)|Qualcore 1027',
|
365 |
-
// http://hclmetablet.com/India/index.php
|
366 |
-
'HCLTablet' => 'HCL.*Tablet|Connect-3G-2.0|Connect-2G-2.0|ME Tablet U1|ME Tablet U2|ME Tablet G1|ME Tablet X1|ME Tablet Y2|ME Tablet Sync',
|
367 |
-
// http://www.edigital.hu/Tablet_es_e-book_olvaso/Tablet-c18385.html
|
368 |
-
'DPSTablet' => 'DPS Dream 9|DPS Dual 7',
|
369 |
-
// http://www.visture.com/index.asp
|
370 |
-
'VistureTablet' => 'V97 HD|i75 3G|Visture V4( HD)?|Visture V5( HD)?|Visture V10',
|
371 |
-
// http://www.mijncresta.nl/tablet
|
372 |
-
'CrestaTablet' => 'CTP(-)?810|CTP(-)?818|CTP(-)?828|CTP(-)?838|CTP(-)?888|CTP(-)?978|CTP(-)?980|CTP(-)?987|CTP(-)?988|CTP(-)?989',
|
373 |
-
// MediaTek - http://www.mediatek.com/_en/01_products/02_proSys.php?cata_sn=1&cata1_sn=1&cata2_sn=309
|
374 |
-
'MediatekTablet' => '\bMT8125|MT8389|MT8135|MT8377\b',
|
375 |
-
// Concorde tab
|
376 |
-
'ConcordeTablet' => 'Concorde([ ]+)?Tab|ConCorde ReadMan',
|
377 |
-
// GoClever Tablets - http://www.goclever.com/uk/products,c1/tablet,c5/
|
378 |
-
'GoCleverTablet' => 'GOCLEVER TAB|A7GOCLEVER|M1042|M7841|M742|R1042BK|R1041|TAB A975|TAB A7842|TAB A741|TAB A741L|TAB M723G|TAB M721|TAB A1021|TAB I921|TAB R721|TAB I720|TAB T76|TAB R70|TAB R76.2|TAB R106|TAB R83.2|TAB M813G|TAB I721|GCTA722|TAB I70|TAB I71|TAB S73|TAB R73|TAB R74|TAB R93|TAB R75|TAB R76.1|TAB A73|TAB A93|TAB A93.2|TAB T72|TAB R83|TAB R974|TAB R973|TAB A101|TAB A103|TAB A104|TAB A104.2|R105BK|M713G|A972BK|TAB A971|TAB R974.2|TAB R104|TAB R83.3|TAB A1042',
|
379 |
-
// Modecom Tablets - http://www.modecom.eu/tablets/portal/
|
380 |
-
'ModecomTablet' => 'FreeTAB 9000|FreeTAB 7.4|FreeTAB 7004|FreeTAB 7800|FreeTAB 2096|FreeTAB 7.5|FreeTAB 1014|FreeTAB 1001 |FreeTAB 8001|FreeTAB 9706|FreeTAB 9702|FreeTAB 7003|FreeTAB 7002|FreeTAB 1002|FreeTAB 7801|FreeTAB 1331|FreeTAB 1004|FreeTAB 8002|FreeTAB 8014|FreeTAB 9704|FreeTAB 1003',
|
381 |
-
// Vonino Tablets
|
382 |
-
'VoninoTablet' => '\b(Argus[ _]?S|Diamond[ _]?79HD|Emerald[ _]?78E|Luna[ _]?70C|Onyx[ _]?S|Onyx[ _]?Z|Orin[ _]?HD|Orin[ _]?S|Otis[ _]?S|SpeedStar[ _]?S|Magnet[ _]?M9|Primus[ _]?94[ _]?3G|Primus[ _]?94HD|Primus[ _]?QS|Android.*\bQ8\b|Sirius[ _]?EVO[ _]?QS|Sirius[ _]?QS|Spirit[ _]?S)\b',
|
383 |
-
// ECS Tablets - http://www.ecs.com.tw/ECSWebSite/Product/Product_Tablet_List.aspx?CategoryID=14&MenuID=107&childid=M_107&LanID=0
|
384 |
-
'ECSTablet' => 'V07OT2|TM105A|S10OT1|TR10CS1',
|
385 |
-
// Storex Tablets - http://storex.fr/espace_client/support.html
|
386 |
-
// @note: no need to add all the tablet codes since they are guided by the first regex.
|
387 |
-
'StorexTablet' => 'eZee[_\']?(Tab|Go)[0-9]+|TabLC7|Looney Tunes Tab',
|
388 |
-
// Generic Vodafone tablets.
|
389 |
-
'VodafoneTablet' => 'SmartTab([ ]+)?[0-9]+|SmartTabII10|SmartTabII7|VF-1497|VFD 1400',
|
390 |
-
// French tablets - Essentiel B http://www.boulanger.fr/tablette_tactile_e-book/tablette_tactile_essentiel_b/cl_68908.htm?multiChoiceToDelete=brand&mc_brand=essentielb
|
391 |
-
// Aka: http://www.essentielb.fr/
|
392 |
-
'EssentielBTablet' => 'Smart[ \']?TAB[ ]+?[0-9]+|Family[ \']?TAB2',
|
393 |
-
// Ross & Moor - http://ross-moor.ru/
|
394 |
-
'RossMoorTablet' => 'RM-790|RM-997|RMD-878G|RMD-974R|RMT-705A|RMT-701|RME-601|RMT-501|RMT-711',
|
395 |
-
// i-mobile http://product.i-mobilephone.com/Mobile_Device
|
396 |
-
'iMobileTablet' => 'i-mobile i-note',
|
397 |
-
// http://www.tolino.de/de/vergleichen/
|
398 |
-
'TolinoTablet' => 'tolino tab [0-9.]+|tolino shine',
|
399 |
-
// AudioSonic - a Kmart brand
|
400 |
-
// http://www.kmart.com.au/webapp/wcs/stores/servlet/Search?langId=-1&storeId=10701&catalogId=10001&categoryId=193001&pageSize=72¤tPage=1&searchCategory=193001%2b4294965664&sortBy=p_MaxPrice%7c1
|
401 |
-
'AudioSonicTablet' => '\bC-22Q|T7-QC|T-17B|T-17P\b',
|
402 |
-
// AMPE Tablets - http://www.ampe.com.my/product-category/tablets/
|
403 |
-
// @todo: add them gradually to avoid conflicts.
|
404 |
-
'AMPETablet' => 'Android.* A78 ',
|
405 |
-
// Skk Mobile - http://skkmobile.com.ph/product_tablets.php
|
406 |
-
'SkkTablet' => 'Android.* (SKYPAD|PHOENIX|CYCLOPS)',
|
407 |
-
// Tecno Mobile (only tablet) - http://www.tecno-mobile.com/index.php/product?filterby=smart&list_order=all&page=1
|
408 |
-
'TecnoTablet' => 'TECNO P9|TECNO DP8D',
|
409 |
-
// JXD (consoles & tablets) - http://jxd.hk/products.asp?selectclassid=009008&clsid=3
|
410 |
-
'JXDTablet' => 'Android.* \b(F3000|A3300|JXD5000|JXD3000|JXD2000|JXD300B|JXD300|S5800|S7800|S602b|S5110b|S7300|S5300|S602|S603|S5100|S5110|S601|S7100a|P3000F|P3000s|P101|P200s|P1000m|P200m|P9100|P1000s|S6600b|S908|P1000|P300|S18|S6600|S9100)\b',
|
411 |
-
// i-Joy tablets - http://www.i-joy.es/en/cat/products/tablets/
|
412 |
-
'iJoyTablet' => 'Tablet (Spirit 7|Essentia|Galatea|Fusion|Onix 7|Landa|Titan|Scooby|Deox|Stella|Themis|Argon|Unique 7|Sygnus|Hexen|Finity 7|Cream|Cream X2|Jade|Neon 7|Neron 7|Kandy|Scape|Saphyr 7|Rebel|Biox|Rebel|Rebel 8GB|Myst|Draco 7|Myst|Tab7-004|Myst|Tadeo Jones|Tablet Boing|Arrow|Draco Dual Cam|Aurix|Mint|Amity|Revolution|Finity 9|Neon 9|T9w|Amity 4GB Dual Cam|Stone 4GB|Stone 8GB|Andromeda|Silken|X2|Andromeda II|Halley|Flame|Saphyr 9,7|Touch 8|Planet|Triton|Unique 10|Hexen 10|Memphis 4GB|Memphis 8GB|Onix 10)',
|
413 |
-
// http://www.intracon.eu/tablet
|
414 |
-
'FX2Tablet' => 'FX2 PAD7|FX2 PAD10',
|
415 |
-
// http://www.xoro.de/produkte/
|
416 |
-
// @note: Might be the same brand with 'Simply tablets'
|
417 |
-
'XoroTablet' => 'KidsPAD 701|PAD[ ]?712|PAD[ ]?714|PAD[ ]?716|PAD[ ]?717|PAD[ ]?718|PAD[ ]?720|PAD[ ]?721|PAD[ ]?722|PAD[ ]?790|PAD[ ]?792|PAD[ ]?900|PAD[ ]?9715D|PAD[ ]?9716DR|PAD[ ]?9718DR|PAD[ ]?9719QR|PAD[ ]?9720QR|TelePAD1030|Telepad1032|TelePAD730|TelePAD731|TelePAD732|TelePAD735Q|TelePAD830|TelePAD9730|TelePAD795|MegaPAD 1331|MegaPAD 1851|MegaPAD 2151',
|
418 |
-
// http://www1.viewsonic.com/products/computing/tablets/
|
419 |
-
'ViewsonicTablet' => 'ViewPad 10pi|ViewPad 10e|ViewPad 10s|ViewPad E72|ViewPad7|ViewPad E100|ViewPad 7e|ViewSonic VB733|VB100a',
|
420 |
-
// https://www.verizonwireless.com/tablets/verizon/
|
421 |
-
'VerizonTablet' => 'QTAQZ3|QTAIR7|QTAQTZ3|QTASUN1|QTASUN2|QTAXIA1',
|
422 |
-
// http://www.odys.de/web/internet-tablet_en.html
|
423 |
-
'OdysTablet' => 'LOOX|XENO10|ODYS[ -](Space|EVO|Xpress|NOON)|\bXELIO\b|Xelio10Pro|XELIO7PHONETAB|XELIO10EXTREME|XELIOPT2|NEO_QUAD10',
|
424 |
-
// http://www.captiva-power.de/products.html#tablets-en
|
425 |
-
'CaptivaTablet' => 'CAPTIVA PAD',
|
426 |
-
// IconBIT - http://www.iconbit.com/products/tablets/
|
427 |
-
'IconbitTablet' => 'NetTAB|NT-3702|NT-3702S|NT-3702S|NT-3603P|NT-3603P|NT-0704S|NT-0704S|NT-3805C|NT-3805C|NT-0806C|NT-0806C|NT-0909T|NT-0909T|NT-0907S|NT-0907S|NT-0902S|NT-0902S',
|
428 |
-
// http://www.teclast.com/topic.php?channelID=70&topicID=140&pid=63
|
429 |
-
'TeclastTablet' => 'T98 4G|\bP80\b|\bX90HD\b|X98 Air|X98 Air 3G|\bX89\b|P80 3G|\bX80h\b|P98 Air|\bX89HD\b|P98 3G|\bP90HD\b|P89 3G|X98 3G|\bP70h\b|P79HD 3G|G18d 3G|\bP79HD\b|\bP89s\b|\bA88\b|\bP10HD\b|\bP19HD\b|G18 3G|\bP78HD\b|\bA78\b|\bP75\b|G17s 3G|G17h 3G|\bP85t\b|\bP90\b|\bP11\b|\bP98t\b|\bP98HD\b|\bG18d\b|\bP85s\b|\bP11HD\b|\bP88s\b|\bA80HD\b|\bA80se\b|\bA10h\b|\bP89\b|\bP78s\b|\bG18\b|\bP85\b|\bA70h\b|\bA70\b|\bG17\b|\bP18\b|\bA80s\b|\bA11s\b|\bP88HD\b|\bA80h\b|\bP76s\b|\bP76h\b|\bP98\b|\bA10HD\b|\bP78\b|\bP88\b|\bA11\b|\bA10t\b|\bP76a\b|\bP76t\b|\bP76e\b|\bP85HD\b|\bP85a\b|\bP86\b|\bP75HD\b|\bP76v\b|\bA12\b|\bP75a\b|\bA15\b|\bP76Ti\b|\bP81HD\b|\bA10\b|\bT760VE\b|\bT720HD\b|\bP76\b|\bP73\b|\bP71\b|\bP72\b|\bT720SE\b|\bC520Ti\b|\bT760\b|\bT720VE\b|T720-3GE|T720-WiFi',
|
430 |
-
// Onda - http://www.onda-tablet.com/buy-android-onda.html?dir=desc&limit=all&order=price
|
431 |
-
'OndaTablet' => '\b(V975i|Vi30|VX530|V701|Vi60|V701s|Vi50|V801s|V719|Vx610w|VX610W|V819i|Vi10|VX580W|Vi10|V711s|V813|V811|V820w|V820|Vi20|V711|VI30W|V712|V891w|V972|V819w|V820w|Vi60|V820w|V711|V813s|V801|V819|V975s|V801|V819|V819|V818|V811|V712|V975m|V101w|V961w|V812|V818|V971|V971s|V919|V989|V116w|V102w|V973|Vi40)\b[\s]+|V10 \b4G\b',
|
432 |
-
'JaytechTablet' => 'TPC-PA762',
|
433 |
-
'BlaupunktTablet' => 'Endeavour 800NG|Endeavour 1010',
|
434 |
-
// http://www.digma.ru/support/download/
|
435 |
-
// @todo: Ebooks also (if requested)
|
436 |
-
'DigmaTablet' => '\b(iDx10|iDx9|iDx8|iDx7|iDxD7|iDxD8|iDsQ8|iDsQ7|iDsQ8|iDsD10|iDnD7|3TS804H|iDsQ11|iDj7|iDs10)\b',
|
437 |
-
// http://www.evolioshop.com/ro/tablete-pc.html
|
438 |
-
// http://www.evolio.ro/support/downloads_static.html?cat=2
|
439 |
-
// @todo: Research some more
|
440 |
-
'EvolioTablet' => 'ARIA_Mini_wifi|Aria[ _]Mini|Evolio X10|Evolio X7|Evolio X8|\bEvotab\b|\bNeura\b',
|
441 |
-
// @todo http://www.lavamobiles.com/tablets-data-cards
|
442 |
-
'LavaTablet' => 'QPAD E704|\bIvoryS\b|E-TAB IVORY|\bE-TAB\b',
|
443 |
-
// http://www.breezetablet.com/
|
444 |
-
'AocTablet' => 'MW0811|MW0812|MW0922|MTK8382|MW1031|MW0831|MW0821|MW0931|MW0712',
|
445 |
-
// http://www.mpmaneurope.com/en/products/internet-tablets-14/android-tablets-14/
|
446 |
-
'MpmanTablet' => 'MP11 OCTA|MP10 OCTA|MPQC1114|MPQC1004|MPQC994|MPQC974|MPQC973|MPQC804|MPQC784|MPQC780|\bMPG7\b|MPDCG75|MPDCG71|MPDC1006|MP101DC|MPDC9000|MPDC905|MPDC706HD|MPDC706|MPDC705|MPDC110|MPDC100|MPDC99|MPDC97|MPDC88|MPDC8|MPDC77|MP709|MID701|MID711|MID170|MPDC703|MPQC1010',
|
447 |
-
// https://www.celkonmobiles.com/?_a=categoryphones&sid=2
|
448 |
-
'CelkonTablet' => 'CT695|CT888|CT[\s]?910|CT7 Tab|CT9 Tab|CT3 Tab|CT2 Tab|CT1 Tab|C820|C720|\bCT-1\b',
|
449 |
-
// http://www.wolderelectronics.com/productos/manuales-y-guias-rapidas/categoria-2-miTab
|
450 |
-
'WolderTablet' => 'miTab \b(DIAMOND|SPACE|BROOKLYN|NEO|FLY|MANHATTAN|FUNK|EVOLUTION|SKY|GOCAR|IRON|GENIUS|POP|MINT|EPSILON|BROADWAY|JUMP|HOP|LEGEND|NEW AGE|LINE|ADVANCE|FEEL|FOLLOW|LIKE|LINK|LIVE|THINK|FREEDOM|CHICAGO|CLEVELAND|BALTIMORE-GH|IOWA|BOSTON|SEATTLE|PHOENIX|DALLAS|IN 101|MasterChef)\b',
|
451 |
-
'MediacomTablet' => 'M-MPI10C3G|M-SP10EG|M-SP10EGP|M-SP10HXAH|M-SP7HXAH|M-SP10HXBH|M-SP8HXAH|M-SP8MXA',
|
452 |
-
// http://www.mi.com/en
|
453 |
-
'MiTablet' => '\bMI PAD\b|\bHM NOTE 1W\b',
|
454 |
-
// http://www.nbru.cn/index.html
|
455 |
-
'NibiruTablet' => 'Nibiru M1|Nibiru Jupiter One',
|
456 |
-
// http://navroad.com/products/produkty/tablety/
|
457 |
-
// http://navroad.com/products/produkty/tablety/
|
458 |
-
'NexoTablet' => 'NEXO NOVA|NEXO 10|NEXO AVIO|NEXO FREE|NEXO GO|NEXO EVO|NEXO 3G|NEXO SMART|NEXO KIDDO|NEXO MOBI',
|
459 |
-
// http://leader-online.com/new_site/product-category/tablets/
|
460 |
-
// http://www.leader-online.net.au/List/Tablet
|
461 |
-
'LeaderTablet' => 'TBLT10Q|TBLT10I|TBL-10WDKB|TBL-10WDKBO2013|TBL-W230V2|TBL-W450|TBL-W500|SV572|TBLT7I|TBA-AC7-8G|TBLT79|TBL-8W16|TBL-10W32|TBL-10WKB|TBL-W100',
|
462 |
-
// http://www.datawind.com/ubislate/
|
463 |
-
'UbislateTablet' => 'UbiSlate[\s]?7C',
|
464 |
-
// http://www.pocketbook-int.com/ru/support
|
465 |
-
'PocketBookTablet' => 'Pocketbook',
|
466 |
-
// http://www.kocaso.com/product_tablet.html
|
467 |
-
'KocasoTablet' => '\b(TB-1207)\b',
|
468 |
-
// http://global.hisense.com/product/asia/tablet/Sero7/201412/t20141215_91832.htm
|
469 |
-
'HisenseTablet' => '\b(F5281|E2371)\b',
|
470 |
-
// http://www.tesco.com/direct/hudl/
|
471 |
-
'Hudl' => 'Hudl HT7S3|Hudl 2',
|
472 |
-
// http://www.telstra.com.au/home-phone/thub-2/
|
473 |
-
'TelstraTablet' => 'T-Hub2',
|
474 |
-
'GenericTablet' => 'Android.*\b97D\b|Tablet(?!.*PC)|BNTV250A|MID-WCDMA|LogicPD Zoom2|\bA7EB\b|CatNova8|A1_07|CT704|CT1002|\bM721\b|rk30sdk|\bEVOTAB\b|M758A|ET904|ALUMIUM10|Smartfren Tab|Endeavour 1010|Tablet-PC-4|Tagi Tab|\bM6pro\b|CT1020W|arc 10HD|\bTP750\b|\bQTAQZ3\b|WVT101|TM1088|KT107'
|
475 |
-
);
|
476 |
-
|
477 |
-
/**
|
478 |
-
* List of mobile Operating Systems.
|
479 |
-
*
|
480 |
-
* @var array
|
481 |
-
*/
|
482 |
-
protected static $operatingSystems = array(
|
483 |
-
'AndroidOS' => 'Android',
|
484 |
-
'BlackBerryOS' => 'blackberry|\bBB10\b|rim tablet os',
|
485 |
-
'PalmOS' => 'PalmOS|avantgo|blazer|elaine|hiptop|palm|plucker|xiino',
|
486 |
-
'SymbianOS' => 'Symbian|SymbOS|Series60|Series40|SYB-[0-9]+|\bS60\b',
|
487 |
-
// @reference: http://en.wikipedia.org/wiki/Windows_Mobile
|
488 |
-
'WindowsMobileOS' => 'Windows CE.*(PPC|Smartphone|Mobile|[0-9]{3}x[0-9]{3})|Windows Mobile|Windows Phone [0-9.]+|WCE;',
|
489 |
-
// @reference: http://en.wikipedia.org/wiki/Windows_Phone
|
490 |
-
// http://wifeng.cn/?r=blog&a=view&id=106
|
491 |
-
// http://nicksnettravels.builttoroam.com/post/2011/01/10/Bogus-Windows-Phone-7-User-Agent-String.aspx
|
492 |
-
// http://msdn.microsoft.com/library/ms537503.aspx
|
493 |
-
// https://msdn.microsoft.com/en-us/library/hh869301(v=vs.85).aspx
|
494 |
-
'WindowsPhoneOS' => 'Windows Phone 10.0|Windows Phone 8.1|Windows Phone 8.0|Windows Phone OS|XBLWP7|ZuneWP7|Windows NT 6.[23]; ARM;',
|
495 |
-
'iOS' => '\biPhone.*Mobile|\biPod|\biPad|AppleCoreMedia',
|
496 |
-
// https://en.wikipedia.org/wiki/IPadOS
|
497 |
-
'iPadOS' => 'CPU OS 13',
|
498 |
-
// http://en.wikipedia.org/wiki/MeeGo
|
499 |
-
// @todo: research MeeGo in UAs
|
500 |
-
'MeeGoOS' => 'MeeGo',
|
501 |
-
// http://en.wikipedia.org/wiki/Maemo
|
502 |
-
// @todo: research Maemo in UAs
|
503 |
-
'MaemoOS' => 'Maemo',
|
504 |
-
'JavaOS' => 'J2ME/|\bMIDP\b|\bCLDC\b', // '|Java/' produces bug #135
|
505 |
-
'webOS' => 'webOS|hpwOS',
|
506 |
-
'badaOS' => '\bBada\b',
|
507 |
-
'BREWOS' => 'BREW',
|
508 |
-
);
|
509 |
-
|
510 |
-
/**
|
511 |
-
* List of mobile User Agents.
|
512 |
-
*
|
513 |
-
* IMPORTANT: This is a list of only mobile browsers.
|
514 |
-
* Mobile Detect 2.x supports only mobile browsers,
|
515 |
-
* it was never designed to detect all browsers.
|
516 |
-
* The change will come in 2017 in the 3.x release for PHP7.
|
517 |
-
*
|
518 |
-
* @var array
|
519 |
-
*/
|
520 |
-
protected static $browsers = array(
|
521 |
-
//'Vivaldi' => 'Vivaldi',
|
522 |
-
// @reference: https://developers.google.com/chrome/mobile/docs/user-agent
|
523 |
-
'Chrome' => '\bCrMo\b|CriOS|Android.*Chrome/[.0-9]* (Mobile)?',
|
524 |
-
'Dolfin' => '\bDolfin\b',
|
525 |
-
'Opera' => 'Opera.*Mini|Opera.*Mobi|Android.*Opera|Mobile.*OPR/[0-9.]+$|Coast/[0-9.]+',
|
526 |
-
'Skyfire' => 'Skyfire',
|
527 |
-
'Edge' => 'Mobile Safari/[.0-9]* Edge',
|
528 |
-
'IE' => 'IEMobile|MSIEMobile', // |Trident/[.0-9]+
|
529 |
-
'Firefox' => 'fennec|firefox.*maemo|(Mobile|Tablet).*Firefox|Firefox.*Mobile|FxiOS',
|
530 |
-
'Bolt' => 'bolt',
|
531 |
-
'TeaShark' => 'teashark',
|
532 |
-
'Blazer' => 'Blazer',
|
533 |
-
// @reference: http://developer.apple.com/library/safari/#documentation/AppleApplications/Reference/SafariWebContent/OptimizingforSafarioniPhone/OptimizingforSafarioniPhone.html#//apple_ref/doc/uid/TP40006517-SW3
|
534 |
-
'Safari' => 'Version.*Mobile.*Safari|Safari.*Mobile|MobileSafari',
|
535 |
-
// http://en.wikipedia.org/wiki/Midori_(web_browser)
|
536 |
-
//'Midori' => 'midori',
|
537 |
-
//'Tizen' => 'Tizen',
|
538 |
-
'WeChat' => '\bMicroMessenger\b',
|
539 |
-
'UCBrowser' => 'UC.*Browser|UCWEB',
|
540 |
-
'baiduboxapp' => 'baiduboxapp',
|
541 |
-
'baidubrowser' => 'baidubrowser',
|
542 |
-
// https://github.com/serbanghita/Mobile-Detect/issues/7
|
543 |
-
'DiigoBrowser' => 'DiigoBrowser',
|
544 |
-
// http://www.puffinbrowser.com/index.php
|
545 |
-
// https://github.com/serbanghita/Mobile-Detect/issues/752
|
546 |
-
// 'Puffin' => 'Puffin',
|
547 |
-
// http://mercury-browser.com/index.html
|
548 |
-
'Mercury' => '\bMercury\b',
|
549 |
-
// http://en.wikipedia.org/wiki/Obigo_Browser
|
550 |
-
'ObigoBrowser' => 'Obigo',
|
551 |
-
// http://en.wikipedia.org/wiki/NetFront
|
552 |
-
'NetFront' => 'NF-Browser',
|
553 |
-
// @reference: http://en.wikipedia.org/wiki/Minimo
|
554 |
-
// http://en.wikipedia.org/wiki/Vision_Mobile_Browser
|
555 |
-
'GenericBrowser' => 'NokiaBrowser|OviBrowser|OneBrowser|TwonkyBeamBrowser|SEMC.*Browser|FlyFlow|Minimo|NetFront|Novarra-Vision|MQQBrowser|MicroMessenger',
|
556 |
-
// @reference: https://en.wikipedia.org/wiki/Pale_Moon_(web_browser)
|
557 |
-
'PaleMoon' => 'Android.*PaleMoon|Mobile.*PaleMoon',
|
558 |
-
);
|
559 |
-
|
560 |
-
/**
|
561 |
-
* Utilities.
|
562 |
-
*
|
563 |
-
* @var array
|
564 |
-
*/
|
565 |
-
protected static $utilities = array(
|
566 |
-
// Experimental. When a mobile device wants to switch to 'Desktop Mode'.
|
567 |
-
// http://scottcate.com/technology/windows-phone-8-ie10-desktop-or-mobile/
|
568 |
-
// https://github.com/serbanghita/Mobile-Detect/issues/57#issuecomment-15024011
|
569 |
-
// https://developers.facebook.com/docs/sharing/best-practices
|
570 |
-
'Bot' => 'Googlebot|facebookexternalhit|Google-AMPHTML|s~amp-validator|AdsBot-Google|Google Keyword Suggestion|Facebot|YandexBot|YandexMobileBot|bingbot|ia_archiver|AhrefsBot|Ezooms|GSLFbot|WBSearchBot|Twitterbot|TweetmemeBot|Twikle|PaperLiBot|Wotbox|UnwindFetchor|Exabot|MJ12bot|YandexImages|TurnitinBot|Pingdom|contentkingapp',
|
571 |
-
'MobileBot' => 'Googlebot-Mobile|AdsBot-Google-Mobile|YahooSeeker/M1A1-R2D2',
|
572 |
-
'DesktopMode' => 'WPDesktop',
|
573 |
-
'TV' => 'SonyDTV|HbbTV', // experimental
|
574 |
-
'WebKit' => '(webkit)[ /]([\w.]+)',
|
575 |
-
// @todo: Include JXD consoles.
|
576 |
-
'Console' => '\b(Nintendo|Nintendo WiiU|Nintendo 3DS|Nintendo Switch|PLAYSTATION|Xbox)\b',
|
577 |
-
'Watch' => 'SM-V700',
|
578 |
-
);
|
579 |
-
|
580 |
-
/**
|
581 |
-
* All possible HTTP headers that represent the
|
582 |
-
* User-Agent string.
|
583 |
-
*
|
584 |
-
* @var array
|
585 |
-
*/
|
586 |
-
protected static $uaHttpHeaders = array(
|
587 |
-
// The default User-Agent string.
|
588 |
-
'HTTP_USER_AGENT',
|
589 |
-
// Header can occur on devices using Opera Mini.
|
590 |
-
'HTTP_X_OPERAMINI_PHONE_UA',
|
591 |
-
// Vodafone specific header: http://www.seoprinciple.com/mobile-web-community-still-angry-at-vodafone/24/
|
592 |
-
'HTTP_X_DEVICE_USER_AGENT',
|
593 |
-
'HTTP_X_ORIGINAL_USER_AGENT',
|
594 |
-
'HTTP_X_SKYFIRE_PHONE',
|
595 |
-
'HTTP_X_BOLT_PHONE_UA',
|
596 |
-
'HTTP_DEVICE_STOCK_UA',
|
597 |
-
'HTTP_X_UCBROWSER_DEVICE_UA'
|
598 |
-
);
|
599 |
-
|
600 |
-
/**
|
601 |
-
* The individual segments that could exist in a User-Agent string. VER refers to the regular
|
602 |
-
* expression defined in the constant self::VER.
|
603 |
-
*
|
604 |
-
* @var array
|
605 |
-
*/
|
606 |
-
protected static $properties = array(
|
607 |
-
|
608 |
-
// Build
|
609 |
-
'Mobile' => 'Mobile/[VER]',
|
610 |
-
'Build' => 'Build/[VER]',
|
611 |
-
'Version' => 'Version/[VER]',
|
612 |
-
'VendorID' => 'VendorID/[VER]',
|
613 |
-
|
614 |
-
// Devices
|
615 |
-
'iPad' => 'iPad.*CPU[a-z ]+[VER]',
|
616 |
-
'iPhone' => 'iPhone.*CPU[a-z ]+[VER]',
|
617 |
-
'iPod' => 'iPod.*CPU[a-z ]+[VER]',
|
618 |
-
//'BlackBerry' => array('BlackBerry[VER]', 'BlackBerry [VER];'),
|
619 |
-
'Kindle' => 'Kindle/[VER]',
|
620 |
-
|
621 |
-
// Browser
|
622 |
-
'Chrome' => array('Chrome/[VER]', 'CriOS/[VER]', 'CrMo/[VER]'),
|
623 |
-
'Coast' => array('Coast/[VER]'),
|
624 |
-
'Dolfin' => 'Dolfin/[VER]',
|
625 |
-
// @reference: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/User-Agent/Firefox
|
626 |
-
'Firefox' => array('Firefox/[VER]', 'FxiOS/[VER]'),
|
627 |
-
'Fennec' => 'Fennec/[VER]',
|
628 |
-
// http://msdn.microsoft.com/en-us/library/ms537503(v=vs.85).aspx
|
629 |
-
// https://msdn.microsoft.com/en-us/library/ie/hh869301(v=vs.85).aspx
|
630 |
-
'Edge' => 'Edge/[VER]',
|
631 |
-
'IE' => array('IEMobile/[VER];', 'IEMobile [VER]', 'MSIE [VER];', 'Trident/[0-9.]+;.*rv:[VER]'),
|
632 |
-
// http://en.wikipedia.org/wiki/NetFront
|
633 |
-
'NetFront' => 'NetFront/[VER]',
|
634 |
-
'NokiaBrowser' => 'NokiaBrowser/[VER]',
|
635 |
-
'Opera' => array( ' OPR/[VER]', 'Opera Mini/[VER]', 'Version/[VER]' ),
|
636 |
-
'Opera Mini' => 'Opera Mini/[VER]',
|
637 |
-
'Opera Mobi' => 'Version/[VER]',
|
638 |
-
'UCBrowser' => array( 'UCWEB[VER]', 'UC.*Browser/[VER]' ),
|
639 |
-
'MQQBrowser' => 'MQQBrowser/[VER]',
|
640 |
-
'MicroMessenger' => 'MicroMessenger/[VER]',
|
641 |
-
'baiduboxapp' => 'baiduboxapp/[VER]',
|
642 |
-
'baidubrowser' => 'baidubrowser/[VER]',
|
643 |
-
'SamsungBrowser' => 'SamsungBrowser/[VER]',
|
644 |
-
'Iron' => 'Iron/[VER]',
|
645 |
-
// @note: Safari 7534.48.3 is actually Version 5.1.
|
646 |
-
// @note: On BlackBerry the Version is overwriten by the OS.
|
647 |
-
'Safari' => array( 'Version/[VER]', 'Safari/[VER]' ),
|
648 |
-
'Skyfire' => 'Skyfire/[VER]',
|
649 |
-
'Tizen' => 'Tizen/[VER]',
|
650 |
-
'Webkit' => 'webkit[ /][VER]',
|
651 |
-
'PaleMoon' => 'PaleMoon/[VER]',
|
652 |
-
|
653 |
-
// Engine
|
654 |
-
'Gecko' => 'Gecko/[VER]',
|
655 |
-
'Trident' => 'Trident/[VER]',
|
656 |
-
'Presto' => 'Presto/[VER]',
|
657 |
-
'Goanna' => 'Goanna/[VER]',
|
658 |
-
|
659 |
-
// OS
|
660 |
-
'iOS' => ' \bi?OS\b [VER][ ;]{1}',
|
661 |
-
'Android' => 'Android [VER]',
|
662 |
-
'BlackBerry' => array('BlackBerry[\w]+/[VER]', 'BlackBerry.*Version/[VER]', 'Version/[VER]'),
|
663 |
-
'BREW' => 'BREW [VER]',
|
664 |
-
'Java' => 'Java/[VER]',
|
665 |
-
// @reference: http://windowsteamblog.com/windows_phone/b/wpdev/archive/2011/08/29/introducing-the-ie9-on-windows-phone-mango-user-agent-string.aspx
|
666 |
-
// @reference: http://en.wikipedia.org/wiki/Windows_NT#Releases
|
667 |
-
'Windows Phone OS' => array( 'Windows Phone OS [VER]', 'Windows Phone [VER]'),
|
668 |
-
'Windows Phone' => 'Windows Phone [VER]',
|
669 |
-
'Windows CE' => 'Windows CE/[VER]',
|
670 |
-
// http://social.msdn.microsoft.com/Forums/en-US/windowsdeveloperpreviewgeneral/thread/6be392da-4d2f-41b4-8354-8dcee20c85cd
|
671 |
-
'Windows NT' => 'Windows NT [VER]',
|
672 |
-
'Symbian' => array('SymbianOS/[VER]', 'Symbian/[VER]'),
|
673 |
-
'webOS' => array('webOS/[VER]', 'hpwOS/[VER];'),
|
674 |
-
);
|
675 |
-
|
676 |
-
/**
|
677 |
-
* Construct an instance of this class.
|
678 |
-
*
|
679 |
-
* @param array $headers Specify the headers as injection. Should be PHP _SERVER flavored.
|
680 |
-
* If left empty, will use the global _SERVER['HTTP_*'] vars instead.
|
681 |
-
* @param string $userAgent Inject the User-Agent header. If null, will use HTTP_USER_AGENT
|
682 |
-
* from the $headers array instead.
|
683 |
-
*/
|
684 |
-
public function __construct(
|
685 |
-
array $headers = null,
|
686 |
-
$userAgent = null
|
687 |
-
) {
|
688 |
-
$this->setHttpHeaders($headers);
|
689 |
-
$this->setUserAgent($userAgent);
|
690 |
-
}
|
691 |
-
|
692 |
-
/**
|
693 |
-
* Get the current script version.
|
694 |
-
* This is useful for the demo.php file,
|
695 |
-
* so people can check on what version they are testing
|
696 |
-
* for mobile devices.
|
697 |
-
*
|
698 |
-
* @return string The version number in semantic version format.
|
699 |
-
*/
|
700 |
-
public static function getScriptVersion()
|
701 |
-
{
|
702 |
-
return self::VERSION;
|
703 |
-
}
|
704 |
-
|
705 |
-
/**
|
706 |
-
* Set the HTTP Headers. Must be PHP-flavored. This method will reset existing headers.
|
707 |
-
*
|
708 |
-
* @param array $httpHeaders The headers to set. If null, then using PHP's _SERVER to extract
|
709 |
-
* the headers. The default null is left for backwards compatibility.
|
710 |
-
*/
|
711 |
-
public function setHttpHeaders($httpHeaders = null)
|
712 |
-
{
|
713 |
-
// use global _SERVER if $httpHeaders aren't defined
|
714 |
-
if (!is_array($httpHeaders) || !count($httpHeaders)) {
|
715 |
-
$httpHeaders = $_SERVER;
|
716 |
-
}
|
717 |
-
|
718 |
-
// clear existing headers
|
719 |
-
$this->httpHeaders = array();
|
720 |
-
|
721 |
-
// Only save HTTP headers. In PHP land, that means only _SERVER vars that
|
722 |
-
// start with HTTP_.
|
723 |
-
foreach ($httpHeaders as $key => $value) {
|
724 |
-
if (substr($key, 0, 5) === 'HTTP_') {
|
725 |
-
$this->httpHeaders[$key] = $value;
|
726 |
-
}
|
727 |
-
}
|
728 |
-
|
729 |
-
// In case we're dealing with CloudFront, we need to know.
|
730 |
-
$this->setCfHeaders($httpHeaders);
|
731 |
-
}
|
732 |
-
|
733 |
-
/**
|
734 |
-
* Retrieves the HTTP headers.
|
735 |
-
*
|
736 |
-
* @return array
|
737 |
-
*/
|
738 |
-
public function getHttpHeaders()
|
739 |
-
{
|
740 |
-
return $this->httpHeaders;
|
741 |
-
}
|
742 |
-
|
743 |
-
/**
|
744 |
-
* Retrieves a particular header. If it doesn't exist, no exception/error is caused.
|
745 |
-
* Simply null is returned.
|
746 |
-
*
|
747 |
-
* @param string $header The name of the header to retrieve. Can be HTTP compliant such as
|
748 |
-
* "User-Agent" or "X-Device-User-Agent" or can be php-esque with the
|
749 |
-
* all-caps, HTTP_ prefixed, underscore seperated awesomeness.
|
750 |
-
*
|
751 |
-
* @return string|null The value of the header.
|
752 |
-
*/
|
753 |
-
public function getHttpHeader($header)
|
754 |
-
{
|
755 |
-
// are we using PHP-flavored headers?
|
756 |
-
if (strpos($header, '_') === false) {
|
757 |
-
$header = str_replace('-', '_', $header);
|
758 |
-
$header = strtoupper($header);
|
759 |
-
}
|
760 |
-
|
761 |
-
// test the alternate, too
|
762 |
-
$altHeader = 'HTTP_' . $header;
|
763 |
-
|
764 |
-
//Test both the regular and the HTTP_ prefix
|
765 |
-
if (isset($this->httpHeaders[$header])) {
|
766 |
-
return $this->httpHeaders[$header];
|
767 |
-
} elseif (isset($this->httpHeaders[$altHeader])) {
|
768 |
-
return $this->httpHeaders[$altHeader];
|
769 |
-
}
|
770 |
-
|
771 |
-
return null;
|
772 |
-
}
|
773 |
-
|
774 |
-
public function getMobileHeaders()
|
775 |
-
{
|
776 |
-
return self::$mobileHeaders;
|
777 |
-
}
|
778 |
-
|
779 |
-
/**
|
780 |
-
* Get all possible HTTP headers that
|
781 |
-
* can contain the User-Agent string.
|
782 |
-
*
|
783 |
-
* @return array List of HTTP headers.
|
784 |
-
*/
|
785 |
-
public function getUaHttpHeaders()
|
786 |
-
{
|
787 |
-
return self::$uaHttpHeaders;
|
788 |
-
}
|
789 |
-
|
790 |
-
|
791 |
-
/**
|
792 |
-
* Set CloudFront headers
|
793 |
-
* http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/header-caching.html#header-caching-web-device
|
794 |
-
*
|
795 |
-
* @param array $cfHeaders List of HTTP headers
|
796 |
-
*
|
797 |
-
* @return boolean If there were CloudFront headers to be set
|
798 |
-
*/
|
799 |
-
public function setCfHeaders($cfHeaders = null) {
|
800 |
-
// use global _SERVER if $cfHeaders aren't defined
|
801 |
-
if (!is_array($cfHeaders) || !count($cfHeaders)) {
|
802 |
-
$cfHeaders = $_SERVER;
|
803 |
-
}
|
804 |
-
|
805 |
-
// clear existing headers
|
806 |
-
$this->cloudfrontHeaders = array();
|
807 |
-
|
808 |
-
// Only save CLOUDFRONT headers. In PHP land, that means only _SERVER vars that
|
809 |
-
// start with cloudfront-.
|
810 |
-
$response = false;
|
811 |
-
foreach ($cfHeaders as $key => $value) {
|
812 |
-
if (substr(strtolower($key), 0, 16) === 'http_cloudfront_') {
|
813 |
-
$this->cloudfrontHeaders[strtoupper($key)] = $value;
|
814 |
-
$response = true;
|
815 |
-
}
|
816 |
-
}
|
817 |
-
|
818 |
-
return $response;
|
819 |
-
}
|
820 |
-
|
821 |
-
/**
|
822 |
-
* Retrieves the cloudfront headers.
|
823 |
-
*
|
824 |
-
* @return array
|
825 |
-
*/
|
826 |
-
public function getCfHeaders()
|
827 |
-
{
|
828 |
-
return $this->cloudfrontHeaders;
|
829 |
-
}
|
830 |
-
|
831 |
-
/**
|
832 |
-
* @param string $userAgent
|
833 |
-
* @return string
|
834 |
-
*/
|
835 |
-
private function prepareUserAgent($userAgent) {
|
836 |
-
$userAgent = trim($userAgent);
|
837 |
-
$userAgent = substr($userAgent, 0, 500);
|
838 |
-
return $userAgent;
|
839 |
-
}
|
840 |
-
|
841 |
-
/**
|
842 |
-
* Set the User-Agent to be used.
|
843 |
-
*
|
844 |
-
* @param string $userAgent The user agent string to set.
|
845 |
-
*
|
846 |
-
* @return string|null
|
847 |
-
*/
|
848 |
-
public function setUserAgent($userAgent = null)
|
849 |
-
{
|
850 |
-
// Invalidate cache due to #375
|
851 |
-
$this->cache = array();
|
852 |
-
|
853 |
-
if (false === empty($userAgent)) {
|
854 |
-
return $this->userAgent = $this->prepareUserAgent($userAgent);
|
855 |
-
} else {
|
856 |
-
$this->userAgent = null;
|
857 |
-
foreach ($this->getUaHttpHeaders() as $altHeader) {
|
858 |
-
if (false === empty($this->httpHeaders[$altHeader])) { // @todo: should use getHttpHeader(), but it would be slow. (Serban)
|
859 |
-
$this->userAgent .= $this->httpHeaders[$altHeader] . " ";
|
860 |
-
}
|
861 |
-
}
|
862 |
-
|
863 |
-
if (!empty($this->userAgent)) {
|
864 |
-
return $this->userAgent = $this->prepareUserAgent($this->userAgent);
|
865 |
-
}
|
866 |
-
}
|
867 |
-
|
868 |
-
if (count($this->getCfHeaders()) > 0) {
|
869 |
-
return $this->userAgent = 'Amazon CloudFront';
|
870 |
-
}
|
871 |
-
return $this->userAgent = null;
|
872 |
-
}
|
873 |
-
|
874 |
-
/**
|
875 |
-
* Retrieve the User-Agent.
|
876 |
-
*
|
877 |
-
* @return string|null The user agent if it's set.
|
878 |
-
*/
|
879 |
-
public function getUserAgent()
|
880 |
-
{
|
881 |
-
return $this->userAgent;
|
882 |
-
}
|
883 |
-
|
884 |
-
/**
|
885 |
-
* Set the detection type. Must be one of self::DETECTION_TYPE_MOBILE or
|
886 |
-
* self::DETECTION_TYPE_EXTENDED. Otherwise, nothing is set.
|
887 |
-
*
|
888 |
-
* @deprecated since version 2.6.9
|
889 |
-
*
|
890 |
-
* @param string $type The type. Must be a self::DETECTION_TYPE_* constant. The default
|
891 |
-
* parameter is null which will default to self::DETECTION_TYPE_MOBILE.
|
892 |
-
*/
|
893 |
-
public function setDetectionType($type = null)
|
894 |
-
{
|
895 |
-
if ($type === null) {
|
896 |
-
$type = self::DETECTION_TYPE_MOBILE;
|
897 |
-
}
|
898 |
-
|
899 |
-
if ($type !== self::DETECTION_TYPE_MOBILE && $type !== self::DETECTION_TYPE_EXTENDED) {
|
900 |
-
return;
|
901 |
-
}
|
902 |
-
|
903 |
-
$this->detectionType = $type;
|
904 |
-
}
|
905 |
-
|
906 |
-
public function getMatchingRegex()
|
907 |
-
{
|
908 |
-
return $this->matchingRegex;
|
909 |
-
}
|
910 |
-
|
911 |
-
public function getMatchesArray()
|
912 |
-
{
|
913 |
-
return $this->matchesArray;
|
914 |
-
}
|
915 |
-
|
916 |
-
/**
|
917 |
-
* Retrieve the list of known phone devices.
|
918 |
-
*
|
919 |
-
* @return array List of phone devices.
|
920 |
-
*/
|
921 |
-
public static function getPhoneDevices()
|
922 |
-
{
|
923 |
-
return self::$phoneDevices;
|
924 |
-
}
|
925 |
-
|
926 |
-
/**
|
927 |
-
* Retrieve the list of known tablet devices.
|
928 |
-
*
|
929 |
-
* @return array List of tablet devices.
|
930 |
-
*/
|
931 |
-
public static function getTabletDevices()
|
932 |
-
{
|
933 |
-
return self::$tabletDevices;
|
934 |
-
}
|
935 |
-
|
936 |
-
/**
|
937 |
-
* Alias for getBrowsers() method.
|
938 |
-
*
|
939 |
-
* @return array List of user agents.
|
940 |
-
*/
|
941 |
-
public static function getUserAgents()
|
942 |
-
{
|
943 |
-
return self::getBrowsers();
|
944 |
-
}
|
945 |
-
|
946 |
-
/**
|
947 |
-
* Retrieve the list of known browsers. Specifically, the user agents.
|
948 |
-
*
|
949 |
-
* @return array List of browsers / user agents.
|
950 |
-
*/
|
951 |
-
public static function getBrowsers()
|
952 |
-
{
|
953 |
-
return self::$browsers;
|
954 |
-
}
|
955 |
-
|
956 |
-
/**
|
957 |
-
* Retrieve the list of known utilities.
|
958 |
-
*
|
959 |
-
* @return array List of utilities.
|
960 |
-
*/
|
961 |
-
public static function getUtilities()
|
962 |
-
{
|
963 |
-
return self::$utilities;
|
964 |
-
}
|
965 |
-
|
966 |
-
/**
|
967 |
-
* Method gets the mobile detection rules. This method is used for the magic methods $detect->is*().
|
968 |
-
*
|
969 |
-
* @deprecated since version 2.6.9
|
970 |
-
*
|
971 |
-
* @return array All the rules (but not extended).
|
972 |
-
*/
|
973 |
-
public static function getMobileDetectionRules()
|
974 |
-
{
|
975 |
-
static $rules;
|
976 |
-
|
977 |
-
if (!$rules) {
|
978 |
-
$rules = array_merge(
|
979 |
-
self::$phoneDevices,
|
980 |
-
self::$tabletDevices,
|
981 |
-
self::$operatingSystems,
|
982 |
-
self::$browsers
|
983 |
-
);
|
984 |
-
}
|
985 |
-
|
986 |
-
return $rules;
|
987 |
-
|
988 |
-
}
|
989 |
-
|
990 |
-
/**
|
991 |
-
* Method gets the mobile detection rules + utilities.
|
992 |
-
* The reason this is separate is because utilities rules
|
993 |
-
* don't necessary imply mobile. This method is used inside
|
994 |
-
* the new $detect->is('stuff') method.
|
995 |
-
*
|
996 |
-
* @deprecated since version 2.6.9
|
997 |
-
*
|
998 |
-
* @return array All the rules + extended.
|
999 |
-
*/
|
1000 |
-
public function getMobileDetectionRulesExtended()
|
1001 |
-
{
|
1002 |
-
static $rules;
|
1003 |
-
|
1004 |
-
if (!$rules) {
|
1005 |
-
// Merge all rules together.
|
1006 |
-
$rules = array_merge(
|
1007 |
-
self::$phoneDevices,
|
1008 |
-
self::$tabletDevices,
|
1009 |
-
self::$operatingSystems,
|
1010 |
-
self::$browsers,
|
1011 |
-
self::$utilities
|
1012 |
-
);
|
1013 |
-
}
|
1014 |
-
|
1015 |
-
return $rules;
|
1016 |
-
}
|
1017 |
-
|
1018 |
-
/**
|
1019 |
-
* Retrieve the current set of rules.
|
1020 |
-
*
|
1021 |
-
* @deprecated since version 2.6.9
|
1022 |
-
*
|
1023 |
-
* @return array
|
1024 |
-
*/
|
1025 |
-
public function getRules()
|
1026 |
-
{
|
1027 |
-
if ($this->detectionType == self::DETECTION_TYPE_EXTENDED) {
|
1028 |
-
return self::getMobileDetectionRulesExtended();
|
1029 |
-
} else {
|
1030 |
-
return self::getMobileDetectionRules();
|
1031 |
-
}
|
1032 |
-
}
|
1033 |
-
|
1034 |
-
/**
|
1035 |
-
* Retrieve the list of mobile operating systems.
|
1036 |
-
*
|
1037 |
-
* @return array The list of mobile operating systems.
|
1038 |
-
*/
|
1039 |
-
public static function getOperatingSystems()
|
1040 |
-
{
|
1041 |
-
return self::$operatingSystems;
|
1042 |
-
}
|
1043 |
-
|
1044 |
-
/**
|
1045 |
-
* Check the HTTP headers for signs of mobile.
|
1046 |
-
* This is the fastest mobile check possible; it's used
|
1047 |
-
* inside isMobile() method.
|
1048 |
-
*
|
1049 |
-
* @return bool
|
1050 |
-
*/
|
1051 |
-
public function checkHttpHeadersForMobile()
|
1052 |
-
{
|
1053 |
-
|
1054 |
-
foreach ($this->getMobileHeaders() as $mobileHeader => $matchType) {
|
1055 |
-
if (isset($this->httpHeaders[$mobileHeader])) {
|
1056 |
-
if (is_array($matchType['matches'])) {
|
1057 |
-
foreach ($matchType['matches'] as $_match) {
|
1058 |
-
if (strpos($this->httpHeaders[$mobileHeader], $_match) !== false) {
|
1059 |
-
return true;
|
1060 |
-
}
|
1061 |
-
}
|
1062 |
-
|
1063 |
-
return false;
|
1064 |
-
} else {
|
1065 |
-
return true;
|
1066 |
-
}
|
1067 |
-
}
|
1068 |
-
}
|
1069 |
-
|
1070 |
-
return false;
|
1071 |
-
|
1072 |
-
}
|
1073 |
-
|
1074 |
-
/**
|
1075 |
-
* Magic overloading method.
|
1076 |
-
*
|
1077 |
-
* @method boolean is[...]()
|
1078 |
-
* @param string $name
|
1079 |
-
* @param array $arguments
|
1080 |
-
* @return mixed
|
1081 |
-
* @throws BadMethodCallException when the method doesn't exist and doesn't start with 'is'
|
1082 |
-
*/
|
1083 |
-
public function __call($name, $arguments)
|
1084 |
-
{
|
1085 |
-
// make sure the name starts with 'is', otherwise
|
1086 |
-
if (substr($name, 0, 2) !== 'is') {
|
1087 |
-
throw new BadMethodCallException("No such method exists: $name");
|
1088 |
-
}
|
1089 |
-
|
1090 |
-
$this->setDetectionType(self::DETECTION_TYPE_MOBILE);
|
1091 |
-
|
1092 |
-
$key = substr($name, 2);
|
1093 |
-
|
1094 |
-
return $this->matchUAAgainstKey($key);
|
1095 |
-
}
|
1096 |
-
|
1097 |
-
/**
|
1098 |
-
* Find a detection rule that matches the current User-agent.
|
1099 |
-
*
|
1100 |
-
* @param null $userAgent deprecated
|
1101 |
-
* @return boolean
|
1102 |
-
*/
|
1103 |
-
protected function matchDetectionRulesAgainstUA($userAgent = null)
|
1104 |
-
{
|
1105 |
-
// Begin general search.
|
1106 |
-
foreach ($this->getRules() as $_regex) {
|
1107 |
-
if (empty($_regex)) {
|
1108 |
-
continue;
|
1109 |
-
}
|
1110 |
-
|
1111 |
-
if ($this->match($_regex, $userAgent)) {
|
1112 |
-
return true;
|
1113 |
-
}
|
1114 |
-
}
|
1115 |
-
|
1116 |
-
return false;
|
1117 |
-
}
|
1118 |
-
|
1119 |
-
/**
|
1120 |
-
* Search for a certain key in the rules array.
|
1121 |
-
* If the key is found then try to match the corresponding
|
1122 |
-
* regex against the User-Agent.
|
1123 |
-
*
|
1124 |
-
* @param string $key
|
1125 |
-
*
|
1126 |
-
* @return boolean
|
1127 |
-
*/
|
1128 |
-
protected function matchUAAgainstKey($key)
|
1129 |
-
{
|
1130 |
-
// Make the keys lowercase so we can match: isIphone(), isiPhone(), isiphone(), etc.
|
1131 |
-
$key = strtolower($key);
|
1132 |
-
if (false === isset($this->cache[$key])) {
|
1133 |
-
|
1134 |
-
// change the keys to lower case
|
1135 |
-
$_rules = array_change_key_case($this->getRules());
|
1136 |
-
|
1137 |
-
if (false === empty($_rules[$key])) {
|
1138 |
-
$this->cache[$key] = $this->match($_rules[$key]);
|
1139 |
-
}
|
1140 |
-
|
1141 |
-
if (false === isset($this->cache[$key])) {
|
1142 |
-
$this->cache[$key] = false;
|
1143 |
-
}
|
1144 |
-
}
|
1145 |
-
|
1146 |
-
return $this->cache[$key];
|
1147 |
-
}
|
1148 |
-
|
1149 |
-
/**
|
1150 |
-
* Check if the device is mobile.
|
1151 |
-
* Returns true if any type of mobile device detected, including special ones
|
1152 |
-
* @param null $userAgent deprecated
|
1153 |
-
* @param null $httpHeaders deprecated
|
1154 |
-
* @return bool
|
1155 |
-
*/
|
1156 |
-
public function isMobile($userAgent = null, $httpHeaders = null)
|
1157 |
-
{
|
1158 |
-
|
1159 |
-
if ($httpHeaders) {
|
1160 |
-
$this->setHttpHeaders($httpHeaders);
|
1161 |
-
}
|
1162 |
-
|
1163 |
-
if ($userAgent) {
|
1164 |
-
$this->setUserAgent($userAgent);
|
1165 |
-
}
|
1166 |
-
|
1167 |
-
// Check specifically for cloudfront headers if the useragent === 'Amazon CloudFront'
|
1168 |
-
if ($this->getUserAgent() === 'Amazon CloudFront') {
|
1169 |
-
$cfHeaders = $this->getCfHeaders();
|
1170 |
-
if(array_key_exists('HTTP_CLOUDFRONT_IS_MOBILE_VIEWER', $cfHeaders) && $cfHeaders['HTTP_CLOUDFRONT_IS_MOBILE_VIEWER'] === 'true') {
|
1171 |
-
return true;
|
1172 |
-
}
|
1173 |
-
}
|
1174 |
-
|
1175 |
-
$this->setDetectionType(self::DETECTION_TYPE_MOBILE);
|
1176 |
-
|
1177 |
-
if ($this->checkHttpHeadersForMobile()) {
|
1178 |
-
return true;
|
1179 |
-
} else {
|
1180 |
-
return $this->matchDetectionRulesAgainstUA();
|
1181 |
-
}
|
1182 |
-
|
1183 |
-
}
|
1184 |
-
|
1185 |
-
/**
|
1186 |
-
* Check if the device is a tablet.
|
1187 |
-
* Return true if any type of tablet device is detected.
|
1188 |
-
*
|
1189 |
-
* @param string $userAgent deprecated
|
1190 |
-
* @param array $httpHeaders deprecated
|
1191 |
-
* @return bool
|
1192 |
-
*/
|
1193 |
-
public function isTablet($userAgent = null, $httpHeaders = null)
|
1194 |
-
{
|
1195 |
-
// Check specifically for cloudfront headers if the useragent === 'Amazon CloudFront'
|
1196 |
-
if ($this->getUserAgent() === 'Amazon CloudFront') {
|
1197 |
-
$cfHeaders = $this->getCfHeaders();
|
1198 |
-
if(array_key_exists('HTTP_CLOUDFRONT_IS_TABLET_VIEWER', $cfHeaders) && $cfHeaders['HTTP_CLOUDFRONT_IS_TABLET_VIEWER'] === 'true') {
|
1199 |
-
return true;
|
1200 |
-
}
|
1201 |
-
}
|
1202 |
-
|
1203 |
-
$this->setDetectionType(self::DETECTION_TYPE_MOBILE);
|
1204 |
-
|
1205 |
-
foreach (self::$tabletDevices as $_regex) {
|
1206 |
-
if ($this->match($_regex, $userAgent)) {
|
1207 |
-
return true;
|
1208 |
-
}
|
1209 |
-
}
|
1210 |
-
|
1211 |
-
return false;
|
1212 |
-
}
|
1213 |
-
|
1214 |
-
/**
|
1215 |
-
* This method checks for a certain property in the
|
1216 |
-
* userAgent.
|
1217 |
-
* @todo: The httpHeaders part is not yet used.
|
1218 |
-
*
|
1219 |
-
* @param string $key
|
1220 |
-
* @param string $userAgent deprecated
|
1221 |
-
* @param string $httpHeaders deprecated
|
1222 |
-
* @return bool|int|null
|
1223 |
-
*/
|
1224 |
-
public function is($key, $userAgent = null, $httpHeaders = null)
|
1225 |
-
{
|
1226 |
-
// Set the UA and HTTP headers only if needed (eg. batch mode).
|
1227 |
-
if ($httpHeaders) {
|
1228 |
-
$this->setHttpHeaders($httpHeaders);
|
1229 |
-
}
|
1230 |
-
|
1231 |
-
if ($userAgent) {
|
1232 |
-
$this->setUserAgent($userAgent);
|
1233 |
-
}
|
1234 |
-
|
1235 |
-
$this->setDetectionType(self::DETECTION_TYPE_EXTENDED);
|
1236 |
-
|
1237 |
-
return $this->matchUAAgainstKey($key);
|
1238 |
-
}
|
1239 |
-
|
1240 |
-
/**
|
1241 |
-
* Some detection rules are relative (not standard),
|
1242 |
-
* because of the diversity of devices, vendors and
|
1243 |
-
* their conventions in representing the User-Agent or
|
1244 |
-
* the HTTP headers.
|
1245 |
-
*
|
1246 |
-
* This method will be used to check custom regexes against
|
1247 |
-
* the User-Agent string.
|
1248 |
-
*
|
1249 |
-
* @param $regex
|
1250 |
-
* @param string $userAgent
|
1251 |
-
* @return bool
|
1252 |
-
*
|
1253 |
-
* @todo: search in the HTTP headers too.
|
1254 |
-
*/
|
1255 |
-
public function match($regex, $userAgent = null)
|
1256 |
-
{
|
1257 |
-
$match = (bool) preg_match(sprintf('#%s#is', $regex), (false === empty($userAgent) ? $userAgent : $this->userAgent), $matches);
|
1258 |
-
// If positive match is found, store the results for debug.
|
1259 |
-
if ($match) {
|
1260 |
-
$this->matchingRegex = $regex;
|
1261 |
-
$this->matchesArray = $matches;
|
1262 |
-
}
|
1263 |
-
|
1264 |
-
return $match;
|
1265 |
-
}
|
1266 |
-
|
1267 |
-
/**
|
1268 |
-
* Get the properties array.
|
1269 |
-
*
|
1270 |
-
* @return array
|
1271 |
-
*/
|
1272 |
-
public static function getProperties()
|
1273 |
-
{
|
1274 |
-
return self::$properties;
|
1275 |
-
}
|
1276 |
-
|
1277 |
-
/**
|
1278 |
-
* Prepare the version number.
|
1279 |
-
*
|
1280 |
-
* @todo Remove the error supression from str_replace() call.
|
1281 |
-
*
|
1282 |
-
* @param string $ver The string version, like "2.6.21.2152";
|
1283 |
-
*
|
1284 |
-
* @return float
|
1285 |
-
*/
|
1286 |
-
public function prepareVersionNo($ver)
|
1287 |
-
{
|
1288 |
-
$ver = str_replace(array('_', ' ', '/'), '.', $ver);
|
1289 |
-
$arrVer = explode('.', $ver, 2);
|
1290 |
-
|
1291 |
-
if (isset($arrVer[1])) {
|
1292 |
-
$arrVer[1] = @str_replace('.', '', $arrVer[1]); // @todo: treat strings versions.
|
1293 |
-
}
|
1294 |
-
|
1295 |
-
return (float) implode('.', $arrVer);
|
1296 |
-
}
|
1297 |
-
|
1298 |
-
/**
|
1299 |
-
* Check the version of the given property in the User-Agent.
|
1300 |
-
* Will return a float number. (eg. 2_0 will return 2.0, 4.3.1 will return 4.31)
|
1301 |
-
*
|
1302 |
-
* @param string $propertyName The name of the property. See self::getProperties() array
|
1303 |
-
* keys for all possible properties.
|
1304 |
-
* @param string $type Either self::VERSION_TYPE_STRING to get a string value or
|
1305 |
-
* self::VERSION_TYPE_FLOAT indicating a float value. This parameter
|
1306 |
-
* is optional and defaults to self::VERSION_TYPE_STRING. Passing an
|
1307 |
-
* invalid parameter will default to the this type as well.
|
1308 |
-
*
|
1309 |
-
* @return string|float The version of the property we are trying to extract.
|
1310 |
-
*/
|
1311 |
-
public function version($propertyName, $type = self::VERSION_TYPE_STRING)
|
1312 |
-
{
|
1313 |
-
if (empty($propertyName)) {
|
1314 |
-
return false;
|
1315 |
-
}
|
1316 |
-
|
1317 |
-
// set the $type to the default if we don't recognize the type
|
1318 |
-
if ($type !== self::VERSION_TYPE_STRING && $type !== self::VERSION_TYPE_FLOAT) {
|
1319 |
-
$type = self::VERSION_TYPE_STRING;
|
1320 |
-
}
|
1321 |
-
|
1322 |
-
$properties = self::getProperties();
|
1323 |
-
|
1324 |
-
// Check if the property exists in the properties array.
|
1325 |
-
if (true === isset($properties[$propertyName])) {
|
1326 |
-
|
1327 |
-
// Prepare the pattern to be matched.
|
1328 |
-
// Make sure we always deal with an array (string is converted).
|
1329 |
-
$properties[$propertyName] = (array) $properties[$propertyName];
|
1330 |
-
|
1331 |
-
foreach ($properties[$propertyName] as $propertyMatchString) {
|
1332 |
-
|
1333 |
-
$propertyPattern = str_replace('[VER]', self::VER, $propertyMatchString);
|
1334 |
-
|
1335 |
-
// Identify and extract the version.
|
1336 |
-
preg_match(sprintf('#%s#is', $propertyPattern), $this->userAgent, $match);
|
1337 |
-
|
1338 |
-
if (false === empty($match[1])) {
|
1339 |
-
$version = ($type == self::VERSION_TYPE_FLOAT ? $this->prepareVersionNo($match[1]) : $match[1]);
|
1340 |
-
|
1341 |
-
return $version;
|
1342 |
-
}
|
1343 |
-
|
1344 |
-
}
|
1345 |
-
|
1346 |
-
}
|
1347 |
-
|
1348 |
-
return false;
|
1349 |
-
}
|
1350 |
-
|
1351 |
-
/**
|
1352 |
-
* Retrieve the mobile grading, using self::MOBILE_GRADE_* constants.
|
1353 |
-
*
|
1354 |
-
* @return string One of the self::MOBILE_GRADE_* constants.
|
1355 |
-
*/
|
1356 |
-
public function mobileGrade()
|
1357 |
-
{
|
1358 |
-
$isMobile = $this->isMobile();
|
1359 |
-
|
1360 |
-
if (
|
1361 |
-
// Apple iOS 4-7.0 – Tested on the original iPad (4.3 / 5.0), iPad 2 (4.3 / 5.1 / 6.1), iPad 3 (5.1 / 6.0), iPad Mini (6.1), iPad Retina (7.0), iPhone 3GS (4.3), iPhone 4 (4.3 / 5.1), iPhone 4S (5.1 / 6.0), iPhone 5 (6.0), and iPhone 5S (7.0)
|
1362 |
-
$this->is('iOS') && $this->version('iPad', self::VERSION_TYPE_FLOAT) >= 4.3 ||
|
1363 |
-
$this->is('iOS') && $this->version('iPhone', self::VERSION_TYPE_FLOAT) >= 4.3 ||
|
1364 |
-
$this->is('iOS') && $this->version('iPod', self::VERSION_TYPE_FLOAT) >= 4.3 ||
|
1365 |
-
|
1366 |
-
// Android 2.1-2.3 - Tested on the HTC Incredible (2.2), original Droid (2.2), HTC Aria (2.1), Google Nexus S (2.3). Functional on 1.5 & 1.6 but performance may be sluggish, tested on Google G1 (1.5)
|
1367 |
-
// Android 3.1 (Honeycomb) - Tested on the Samsung Galaxy Tab 10.1 and Motorola XOOM
|
1368 |
-
// Android 4.0 (ICS) - Tested on a Galaxy Nexus. Note: transition performance can be poor on upgraded devices
|
1369 |
-
// Android 4.1 (Jelly Bean) - Tested on a Galaxy Nexus and Galaxy 7
|
1370 |
-
( $this->version('Android', self::VERSION_TYPE_FLOAT)>2.1 && $this->is('Webkit') ) ||
|
1371 |
-
|
1372 |
-
// Windows Phone 7.5-8 - Tested on the HTC Surround (7.5), HTC Trophy (7.5), LG-E900 (7.5), Nokia 800 (7.8), HTC Mazaa (7.8), Nokia Lumia 520 (8), Nokia Lumia 920 (8), HTC 8x (8)
|
1373 |
-
$this->version('Windows Phone OS', self::VERSION_TYPE_FLOAT) >= 7.5 ||
|
1374 |
-
|
1375 |
-
// Tested on the Torch 9800 (6) and Style 9670 (6), BlackBerry® Torch 9810 (7), BlackBerry Z10 (10)
|
1376 |
-
$this->is('BlackBerry') && $this->version('BlackBerry', self::VERSION_TYPE_FLOAT) >= 6.0 ||
|
1377 |
-
// Blackberry Playbook (1.0-2.0) - Tested on PlayBook
|
1378 |
-
$this->match('Playbook.*Tablet') ||
|
1379 |
-
|
1380 |
-
// Palm WebOS (1.4-3.0) - Tested on the Palm Pixi (1.4), Pre (1.4), Pre 2 (2.0), HP TouchPad (3.0)
|
1381 |
-
( $this->version('webOS', self::VERSION_TYPE_FLOAT) >= 1.4 && $this->match('Palm|Pre|Pixi') ) ||
|
1382 |
-
// Palm WebOS 3.0 - Tested on HP TouchPad
|
1383 |
-
$this->match('hp.*TouchPad') ||
|
1384 |
-
|
1385 |
-
// Firefox Mobile 18 - Tested on Android 2.3 and 4.1 devices
|
1386 |
-
( $this->is('Firefox') && $this->version('Firefox', self::VERSION_TYPE_FLOAT) >= 18 ) ||
|
1387 |
-
|
1388 |
-
// Chrome for Android - Tested on Android 4.0, 4.1 device
|
1389 |
-
( $this->is('Chrome') && $this->is('AndroidOS') && $this->version('Android', self::VERSION_TYPE_FLOAT) >= 4.0 ) ||
|
1390 |
-
|
1391 |
-
// Skyfire 4.1 - Tested on Android 2.3 device
|
1392 |
-
( $this->is('Skyfire') && $this->version('Skyfire', self::VERSION_TYPE_FLOAT) >= 4.1 && $this->is('AndroidOS') && $this->version('Android', self::VERSION_TYPE_FLOAT) >= 2.3 ) ||
|
1393 |
-
|
1394 |
-
// Opera Mobile 11.5-12: Tested on Android 2.3
|
1395 |
-
( $this->is('Opera') && $this->version('Opera Mobi', self::VERSION_TYPE_FLOAT) >= 11.5 && $this->is('AndroidOS') ) ||
|
1396 |
-
|
1397 |
-
// Meego 1.2 - Tested on Nokia 950 and N9
|
1398 |
-
$this->is('MeeGoOS') ||
|
1399 |
-
|
1400 |
-
// Tizen (pre-release) - Tested on early hardware
|
1401 |
-
$this->is('Tizen') ||
|
1402 |
-
|
1403 |
-
// Samsung Bada 2.0 - Tested on a Samsung Wave 3, Dolphin browser
|
1404 |
-
// @todo: more tests here!
|
1405 |
-
$this->is('Dolfin') && $this->version('Bada', self::VERSION_TYPE_FLOAT) >= 2.0 ||
|
1406 |
-
|
1407 |
-
// UC Browser - Tested on Android 2.3 device
|
1408 |
-
( ($this->is('UC Browser') || $this->is('Dolfin')) && $this->version('Android', self::VERSION_TYPE_FLOAT) >= 2.3 ) ||
|
1409 |
-
|
1410 |
-
// Kindle 3 and Fire - Tested on the built-in WebKit browser for each
|
1411 |
-
( $this->match('Kindle Fire') ||
|
1412 |
-
$this->is('Kindle') && $this->version('Kindle', self::VERSION_TYPE_FLOAT) >= 3.0 ) ||
|
1413 |
-
|
1414 |
-
// Nook Color 1.4.1 - Tested on original Nook Color, not Nook Tablet
|
1415 |
-
$this->is('AndroidOS') && $this->is('NookTablet') ||
|
1416 |
-
|
1417 |
-
// Chrome Desktop 16-24 - Tested on OS X 10.7 and Windows 7
|
1418 |
-
$this->version('Chrome', self::VERSION_TYPE_FLOAT) >= 16 && !$isMobile ||
|
1419 |
-
|
1420 |
-
// Safari Desktop 5-6 - Tested on OS X 10.7 and Windows 7
|
1421 |
-
$this->version('Safari', self::VERSION_TYPE_FLOAT) >= 5.0 && !$isMobile ||
|
1422 |
-
|
1423 |
-
// Firefox Desktop 10-18 - Tested on OS X 10.7 and Windows 7
|
1424 |
-
$this->version('Firefox', self::VERSION_TYPE_FLOAT) >= 10.0 && !$isMobile ||
|
1425 |
-
|
1426 |
-
// Internet Explorer 7-9 - Tested on Windows XP, Vista and 7
|
1427 |
-
$this->version('IE', self::VERSION_TYPE_FLOAT) >= 7.0 && !$isMobile ||
|
1428 |
-
|
1429 |
-
// Opera Desktop 10-12 - Tested on OS X 10.7 and Windows 7
|
1430 |
-
$this->version('Opera', self::VERSION_TYPE_FLOAT) >= 10 && !$isMobile
|
1431 |
-
){
|
1432 |
-
return self::MOBILE_GRADE_A;
|
1433 |
-
}
|
1434 |
-
|
1435 |
-
if (
|
1436 |
-
$this->is('iOS') && $this->version('iPad', self::VERSION_TYPE_FLOAT)<4.3 ||
|
1437 |
-
$this->is('iOS') && $this->version('iPhone', self::VERSION_TYPE_FLOAT)<4.3 ||
|
1438 |
-
$this->is('iOS') && $this->version('iPod', self::VERSION_TYPE_FLOAT)<4.3 ||
|
1439 |
-
|
1440 |
-
// Blackberry 5.0: Tested on the Storm 2 9550, Bold 9770
|
1441 |
-
$this->is('Blackberry') && $this->version('BlackBerry', self::VERSION_TYPE_FLOAT) >= 5 && $this->version('BlackBerry', self::VERSION_TYPE_FLOAT)<6 ||
|
1442 |
-
|
1443 |
-
//Opera Mini (5.0-6.5) - Tested on iOS 3.2/4.3 and Android 2.3
|
1444 |
-
($this->version('Opera Mini', self::VERSION_TYPE_FLOAT) >= 5.0 && $this->version('Opera Mini', self::VERSION_TYPE_FLOAT) <= 7.0 &&
|
1445 |
-
($this->version('Android', self::VERSION_TYPE_FLOAT) >= 2.3 || $this->is('iOS')) ) ||
|
1446 |
-
|
1447 |
-
// Nokia Symbian^3 - Tested on Nokia N8 (Symbian^3), C7 (Symbian^3), also works on N97 (Symbian^1)
|
1448 |
-
$this->match('NokiaN8|NokiaC7|N97.*Series60|Symbian/3') ||
|
1449 |
-
|
1450 |
-
// @todo: report this (tested on Nokia N71)
|
1451 |
-
$this->version('Opera Mobi', self::VERSION_TYPE_FLOAT) >= 11 && $this->is('SymbianOS')
|
1452 |
-
){
|
1453 |
-
return self::MOBILE_GRADE_B;
|
1454 |
-
}
|
1455 |
-
|
1456 |
-
if (
|
1457 |
-
// Blackberry 4.x - Tested on the Curve 8330
|
1458 |
-
$this->version('BlackBerry', self::VERSION_TYPE_FLOAT) <= 5.0 ||
|
1459 |
-
// Windows Mobile - Tested on the HTC Leo (WinMo 5.2)
|
1460 |
-
$this->match('MSIEMobile|Windows CE.*Mobile') || $this->version('Windows Mobile', self::VERSION_TYPE_FLOAT) <= 5.2 ||
|
1461 |
-
|
1462 |
-
// Tested on original iPhone (3.1), iPhone 3 (3.2)
|
1463 |
-
$this->is('iOS') && $this->version('iPad', self::VERSION_TYPE_FLOAT) <= 3.2 ||
|
1464 |
-
$this->is('iOS') && $this->version('iPhone', self::VERSION_TYPE_FLOAT) <= 3.2 ||
|
1465 |
-
$this->is('iOS') && $this->version('iPod', self::VERSION_TYPE_FLOAT) <= 3.2 ||
|
1466 |
-
|
1467 |
-
// Internet Explorer 7 and older - Tested on Windows XP
|
1468 |
-
$this->version('IE', self::VERSION_TYPE_FLOAT) <= 7.0 && !$isMobile
|
1469 |
-
){
|
1470 |
-
return self::MOBILE_GRADE_C;
|
1471 |
-
}
|
1472 |
-
|
1473 |
-
// All older smartphone platforms and featurephones - Any device that doesn't support media queries
|
1474 |
-
// will receive the basic, C grade experience.
|
1475 |
-
return self::MOBILE_GRADE_C;
|
1476 |
-
}
|
1477 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
vendor/mobiledetect/mobiledetectlib/README.md
DELETED
@@ -1,344 +0,0 @@
|
|
1 |
-
![Mobile Detect](http://demo.mobiledetect.net/logo-github.png)
|
2 |
-
|
3 |
-
> Motto: "Every business should have a detection script to detect mobile readers."
|
4 |
-
|
5 |
-
[![Build Status](https://travis-ci.org/serbanghita/Mobile-Detect.svg?branch=devel)](https://travis-ci.org/serbanghita/Mobile-Detect)
|
6 |
-
[![Latest Stable Version](https://poser.pugx.org/mobiledetect/mobiledetectlib/v/stable.svg)](https://packagist.org/packages/mobiledetect/mobiledetectlib)
|
7 |
-
[![Total Downloads](https://poser.pugx.org/mobiledetect/mobiledetectlib/downloads.svg)](https://packagist.org/packages/mobiledetect/mobiledetectlib)
|
8 |
-
[![Daily Downloads](https://poser.pugx.org/mobiledetect/mobiledetectlib/d/daily.png)](https://packagist.org/packages/mobiledetect/mobiledetectlib)
|
9 |
-
[![License](https://poser.pugx.org/mobiledetect/mobiledetectlib/license.svg)](https://packagist.org/packages/mobiledetect/mobiledetectlib)
|
10 |
-
[![Chat on Slack](https://img.shields.io/badge/Slack%20%23general-join-orange.svg)](https://join.slack.com/t/mobiledetect/shared_invite/enQtMjg1NDY0OTg5NzgzLTcwMzEzMWJjZjRlOWFkY2ZiNzE1ZmRmNzEwM2VhOGY5OGVkYWMxNjdkZDU5YjQ5MmM5MGUxYjhlZDQwOGVjZjE)
|
11 |
-
|
12 |
-
#### About
|
13 |
-
|
14 |
-
Mobile Detect is a lightweight PHP class for detecting mobile devices (including tablets).
|
15 |
-
It uses the User-Agent string combined with specific HTTP headers to detect the mobile environment.
|
16 |
-
|
17 |
-
*Why*
|
18 |
-
|
19 |
-
Your website's _content strategy_ is important! You need a complete toolkit to deliver an experience that is _optimized_,
|
20 |
-
_fast_ and _relevant_ to your users. Mobile Detect class is a
|
21 |
-
[server-side detection](http://www.w3.org/TR/mwabp/#bp-devcap-detection) tool that can help you with your RWD strategy,
|
22 |
-
it is not a replacement for CSS3 media queries or other forms of client-side feature detection.
|
23 |
-
|
24 |
-
*How*
|
25 |
-
|
26 |
-
We're committed to make Mobile_Detect the best open-source mobile detection resource and this is why before
|
27 |
-
each release we're running [unit tests](./tests) and research and update the detection rules on **monthly** basis.
|
28 |
-
|
29 |
-
*Who*
|
30 |
-
|
31 |
-
See [the history](./docs/HISTORY.md) of the project.
|
32 |
-
|
33 |
-
#### Announcements
|
34 |
-
|
35 |
-
* **JetBrains** is sponsoring the project by providing licenses for [PHPStorm](https://www.jetbrains.com/phpstorm/) and
|
36 |
-
[DataGrip](https://www.jetbrains.com/datagrip/).
|
37 |
-
* **Mobile_Detect `2.x.x`** is only integrating new regexes, User-Agents and tests. We are focusing on **new tablets only**.
|
38 |
-
The rest of the PRs about TVs, bots or optimizations will be closed and analyzed after `3.0.0-beta` is released.
|
39 |
-
* **Mobile_Detect `3.x.x`** is experimental and WIP.
|
40 |
-
|
41 |
-
|
42 |
-
#### Install
|
43 |
-
|
44 |
-
**Download and include manually**
|
45 |
-
> Use this to quickly test the demo.
|
46 |
-
|
47 |
-
* [Download latest release](../../tags)
|
48 |
-
* [Mobile_Detect.php](./Mobile_Detect.php)
|
49 |
-
|
50 |
-
```php
|
51 |
-
require_once "libs/Mobile_Detect.php";
|
52 |
-
```
|
53 |
-
|
54 |
-
**Install as a [composer package](https://packagist.org/packages/mobiledetect/mobiledetectlib)**
|
55 |
-
> Use this method to get continuous updates.
|
56 |
-
|
57 |
-
```
|
58 |
-
composer require mobiledetect/mobiledetectlib
|
59 |
-
```
|
60 |
-
or include the dependency in the `composer.json` file:
|
61 |
-
```json
|
62 |
-
{
|
63 |
-
"require": {
|
64 |
-
"mobiledetect/mobiledetectlib": "^2.8"
|
65 |
-
}
|
66 |
-
}
|
67 |
-
```
|
68 |
-
|
69 |
-
#### Demo
|
70 |
-
|
71 |
-
* [:iphone: Live demo!](http://demo.mobiledetect.net)
|
72 |
-
* [Code examples](../../wiki/Code-examples)
|
73 |
-
|
74 |
-
#### Contribute
|
75 |
-
|
76 |
-
*Submit a PR*
|
77 |
-
> Submit a pull request but before make sure you read [how to contribute](docs/CONTRIBUTING.md) guide.
|
78 |
-
|
79 |
-
*Donate*
|
80 |
-
|
81 |
-
|Paypal|
|
82 |
-
|------|
|
83 |
-
|[Donate :+1:](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=mobiledetectlib%40gmail%2ecom&lc=US&item_name=Mobile%20Detect¤cy_code=USD&bn=PP%2dDonationsBF%3abtn_donate_SM%2egif%3aNonHosted)|
|
84 |
-
|
85 |
-
|
86 |
-
I'm currently paying for hosting and spend a lot of my family time to maintain the project and planning the future releases.
|
87 |
-
I would highly appreciate any money donations that will keep the research going.
|
88 |
-
|
89 |
-
Special thanks to the community :+1: for donations, JetBrains team for the continuous support and [Dragos Gavrila](https://twitter.com/grafician) who contributed with the logo.
|
90 |
-
|
91 |
-
#### Modules, plugins, ports
|
92 |
-
> [Submit new module, plugin, port](../../issues/new?title=New%203rd%20party%20module&body=Name,%20Link%20and%20Description%20of%20the%20module.)
|
93 |
-
|
94 |
-
:point_right: Keep `Mobile_Detect.php` class in a separate `module` and do NOT include it in your script core because of the high frequency of updates.
|
95 |
-
:point_right: When including the class into your `web application` or `module` always use `include_once '../path/to/Mobile_Detect.php` to prevent conflicts.
|
96 |
-
|
97 |
-
**JavaScript**
|
98 |
-
|
99 |
-
* mobile-detect.js - A [JavaScript port](https://github.com/hgoebl/mobile-detect.js) of Mobile-Detect class. Made by [Heinrich Goebl](https://github.com/hgoebl).
|
100 |
-
|
101 |
-
**Varnish Cache**
|
102 |
-
|
103 |
-
* [Varnish Mobile Detect](https://github.com/willemk/varnish-mobiletranslate) - Drop-in varnish solution to mobile user
|
104 |
-
detection based on the Mobile-Detect library. Made by [willemk](https://github.com/willemk).
|
105 |
-
* [mobiledetect2vcl](https://github.com/carlosabalde/mobiledetect2vcl) - Python script to transform the Mobile
|
106 |
-
Detect JSON database into an UA-based mobile detection VCL subroutine easily integrable in any Varnish Cache
|
107 |
-
configuration. Made by [Carlos Abalde](https://github.com/carlosabalde).
|
108 |
-
|
109 |
-
**LUA**
|
110 |
-
|
111 |
-
* [mobile-detect.lua](https://github.com/yourpalmark/mobile-detect.lua) is a port of Mobile-Detect to Lua for
|
112 |
-
NGINX HTTP servers. Follows closely to mobile-detect.js. Supports all methods that server-side
|
113 |
-
mobile-detect.js supports. Fully unit-tested and synced with Travis CI (Build Passing badge included).
|
114 |
-
Made by [Mark Walters](https://github.com/yourpalmark).
|
115 |
-
|
116 |
-
**PHP**
|
117 |
-
|
118 |
-
**WordPress**
|
119 |
-
|
120 |
-
* [Mobile Detect for WordPress](https://wordpress.org/plugins/tinywp-mobile-detect/) - WordPress has a built-in function
|
121 |
-
(`wp_is_mobile()`) to detect mobile devices. There is (at least) one catch, though. It considers iPad (iPad pro,
|
122 |
-
and any tablet) as a mobile. So, this 3rd party module changes the way `wp_is_mobile()` works with the help of
|
123 |
-
Mobile Detect PHP library!
|
124 |
-
Made by [Pothi Kalimuthu](https://github.com/pothi)
|
125 |
-
|
126 |
-
* [WordPress Mobile Detect](https://wordpress.org/plugins/wp-mobile-detect/) - Gives you the ability to wrap that
|
127 |
-
infographic in a `[notdevice][/notdevice]` shortcode so at the server level WordPress will
|
128 |
-
decide to show that content only if the user is NOT on a phone or tablet.
|
129 |
-
Made by [Jesse Friedman](https://profiles.wordpress.org/professor44/).
|
130 |
-
|
131 |
-
* [mobble](https://wordpress.org/plugins/mobble/) - provides mobile related conditional functions for your site.
|
132 |
-
e.g. `is_iphone()`, `is_mobile()` and `is_tablet()`. Made by Scott Evans.
|
133 |
-
|
134 |
-
* [WordPress Responsage](https://github.com/iamspacehead/responsage) - A small WordPress theme plugin that allows
|
135 |
-
you to make your images responsive. Made by [Adrian Ciaschetti](https://github.com/iamspacehead).
|
136 |
-
|
137 |
-
* [WP247 Body Classes](https://wordpress.org/plugins/wp247-body-classes/) - Add unique classes to the `body` tag for
|
138 |
-
easy styling based on various attributes (archive, user, post, mobile) and various WordPress "is" functions.
|
139 |
-
Mobile attributes include type of device, Operating System, Browser, etc. Examples: .is-mobile, .is-not-mobile,
|
140 |
-
.is-tablet, .is-ios, .is-not-ios, .is-androidos, .is-chromebrowser.
|
141 |
-
Made by [wescleveland56](https://github.com/wescleveland56).
|
142 |
-
|
143 |
-
* [Adaptive Content](https://wordpress.org/plugins/addfunc-adaptive-content/) for WordPress provides the most
|
144 |
-
intuitive set of shortcodes for including/excluding content on mobile devices, tablets desktops and other
|
145 |
-
more specific device parameters. This lightweight plugin lets content writers and theme authors choose when
|
146 |
-
WordPress should or shouldn’t show any give content item using shortcodes and quicktags or theme elements using functions.
|
147 |
-
Made by [AddFunc](https://profiles.wordpress.org/addfunc).
|
148 |
-
|
149 |
-
* [AddFunc Mobile Detect](https://wordpress.org/plugins/addfunc-mobile-detect/) for WordPress redirects
|
150 |
-
mobile traffic to your mobile website and, basically, gives you loads of control over your mobile redirects.
|
151 |
-
Made by [AddFunc](https://profiles.wordpress.org/addfunc).
|
152 |
-
|
153 |
-
**Drupal**
|
154 |
-
|
155 |
-
* [Drupal Mobile Switch](https://www.drupal.org/project/mobile_switch) - The Mobile Switch Drupal module provides a
|
156 |
-
automatic theme switch functionality for mobile devices, detected by Browscap or Mobile Detect.
|
157 |
-
Made by [Siegfried Neumann](https://www.drupal.org/user/45267).
|
158 |
-
|
159 |
-
* [Drupal Context Mobile Detect](https://www.drupal.org/project/context_mobile_detect) - This is a Drupal context module
|
160 |
-
which integrates Context and PHP Mobile Detect library.
|
161 |
-
Created by [Artem Shymko](https://www.drupal.org/user/432492).
|
162 |
-
|
163 |
-
* [Drupal Mobile Detect](https://www.drupal.org/project/mobile_detect) - Lightweight mobile detect module for Drupal
|
164 |
-
created by [Matthew Donadio](https://www.drupal.org/user/325244).
|
165 |
-
|
166 |
-
**Joomla**
|
167 |
-
|
168 |
-
* [yagendoo Joomla! Mobile Detection Plugin](http://www.yagendoo.com/en/blog/free-mobile-detection-plugin-for-joomla.html) - Lightweight PHP plugin for Joomla!
|
169 |
-
that detects a mobile browser using the Mobile Detect class.
|
170 |
-
Made by yagendoo media.
|
171 |
-
|
172 |
-
* [User Agent Detector plugin](https://github.com/renekreijveld/UserAgentDetector) - This system plugin detects the user
|
173 |
-
agent of your website visitor and sets a session variable accordingly. Based on the user agent, the plugin detects if the
|
174 |
-
site is running on a desktop pc, tablet or smartphone. It can also detect if the visitor is a spider bot (search engine).
|
175 |
-
Session variable that is set: `ualayout`. Possible values: desktop, tablet, mobile, bot.
|
176 |
-
Made by @ReneKreijveld.
|
177 |
-
|
178 |
-
**Magento**
|
179 |
-
|
180 |
-
* [Magento helper](http://www.magentocommerce.com/magento-connect/catalog/product/view/id/16835/) from Optimise Web enables
|
181 |
-
the use of all functions provided by Mobile Detect. Made by [Kathir Vel](http://www.kathirvel.com).
|
182 |
-
|
183 |
-
* [Magento 2 Mobile Detect Theme Change](https://github.com/EaDesgin/magento2-mobiledetect) is an extension for Magento 2
|
184 |
-
that will change the theme or redirect to a different URL. Also containing a helper to check for the device type.
|
185 |
-
|
186 |
-
**PrestaShop**
|
187 |
-
|
188 |
-
* [PrestaShop](https://www.prestashop.com) is a free, secure and open source shopping cart platform. Mobile_Detect
|
189 |
-
is included in the default package since 1.5.x.
|
190 |
-
|
191 |
-
**Laravel**
|
192 |
-
|
193 |
-
* [Agent](https://github.com/jenssegers/agent) is a user agent class for Laravel based on Mobile Detect with some
|
194 |
-
additional functionality.
|
195 |
-
Made by [Jens Segers](https://github.com/jenssegers).
|
196 |
-
|
197 |
-
* [Laravel Mobile Detect](https://github.com/riverskies/laravel-mobile-detect) is a package that enables you to use device detection right in your Laravel Blade templates. (Utilises the well-known, constantly updated PHP mobile detection library.)
|
198 |
-
Made by [Barnabas Kecskes](https://github.com/barnabaskecskes).
|
199 |
-
|
200 |
-
* [BrowserDetect](https://github.com/hisorange/browser-detect) is a browser and mobile detection package, collects
|
201 |
-
and wrap together the best user-agent identifiers for Laravel.
|
202 |
-
Created by [Varga Zsolt](https://github.com/hisorange).
|
203 |
-
|
204 |
-
**Zend Framework**
|
205 |
-
|
206 |
-
* [ZF2 Mobile-Detect](https://github.com/neilime/zf2-mobile-detect.git) is a Zend Framework 2 module that provides
|
207 |
-
Mobile-Detect features (Mobile_Detect class as a service, helper for views and plugin controllers).
|
208 |
-
Made by [neilime](https://github.com/neilime).
|
209 |
-
|
210 |
-
* [ZF2 MobileDetectModule](https://github.com/nikolaposa/MobileDetectModule) facilitates integration of a PHP MobileDetect
|
211 |
-
class with some ZF2-based application. Has similar idea like the existing ZF2 Mobile-Detect module,
|
212 |
-
but differs in initialization and provision routine of the actual Mobile_Detect class.
|
213 |
-
Appropriate view helper and controller plugin also have different conceptions.
|
214 |
-
Made by [Nikola Posa](https://github.com/nikolaposa).
|
215 |
-
|
216 |
-
**Symfony**
|
217 |
-
|
218 |
-
* [Symfony2 Mobile Detect Bundle](https://github.com/suncat2000/MobileDetectBundle) is a bundle for detecting mobile devices,
|
219 |
-
manage mobile view and redirect to the mobile and tablet version.
|
220 |
-
Made by [Nikolay Ivlev](https://github.com/suncat2000).
|
221 |
-
|
222 |
-
* [Silex Mobile Detect Service Provider](https://github.com/jbinfo/MobileDetectServiceProvider) is a service provider to
|
223 |
-
interact with Mobile detect class methods.
|
224 |
-
Made by [Lhassan Baazzi](https://github.com/jbinfo).
|
225 |
-
|
226 |
-
**Slim Framework**
|
227 |
-
|
228 |
-
* [Slim_Mobile_Detect](https://github.com/zguillez/slim_mobile_detect) implements Mobile_Detect lib for different
|
229 |
-
responses write on Slim Framework App.
|
230 |
-
|
231 |
-
**ExpressionEngine**
|
232 |
-
|
233 |
-
* [EE2 Detect Mobile](https://github.com/garethtdavies/detect-mobile) is a lightweight PHP plugin for EE2 that detects
|
234 |
-
a mobile browser using the Mobile Detect class. Made by [Gareth Davies](https://github.com/garethtdavies).
|
235 |
-
|
236 |
-
**Yii Framework**
|
237 |
-
|
238 |
-
* [Yii Extension](https://github.com/iamsalnikov/MobileDetect) - Mobile detect plugin for Yii framework.
|
239 |
-
Made by [Alexey Salnikov](https://github.com/iamsalnikov).
|
240 |
-
|
241 |
-
* [Yii Extension](https://github.com/candasm/yii1-mobile-detect-component) - Mobile detect component for Yii framework
|
242 |
-
1.x version which supports composer package manager. Made by [Candas Minareci](https://github.com/candasm).
|
243 |
-
|
244 |
-
* [Yii2 Device Detect](https://github.com/alexandernst/yii2-device-detect/) - Yii2 extension for Mobile-Detect library.
|
245 |
-
Made by [Alexander Nestorov](https://github.com/alexandernst).
|
246 |
-
|
247 |
-
**CakePHP**
|
248 |
-
|
249 |
-
* [CakePHP MobileDetect](https://github.com/chronon/CakePHP-MobileDetectComponent-Plugin) is a plugin component for
|
250 |
-
CakePHP 2.x. Made by [Gregory Gaskill](https://github.com/chronon).
|
251 |
-
|
252 |
-
**FuelPHP**
|
253 |
-
|
254 |
-
* [Special Agent](https://github.com/rob-bar/special_agent) is a FuelPHP package which uses php-mobile-detect to
|
255 |
-
determine whether a device is mobile or not. It overrides the Fuelphp Agent class its methods.
|
256 |
-
Made by [Robbie Bardjin](https://github.com/rob-bar).
|
257 |
-
|
258 |
-
|
259 |
-
**TYPO3**
|
260 |
-
|
261 |
-
* [px_mobiledetect](https://typo3.org/extensions/repository/view/px_mobiledetect) is an extension that helps to detect
|
262 |
-
visitor's mobile device class (if that’s tablet or mobile device like smartphone). Made by Alexander Tretyak.
|
263 |
-
|
264 |
-
**Other**
|
265 |
-
|
266 |
-
* [PageCache](https://github.com/mmamedov/page-cache) is a lightweight PHP library for full page cache,
|
267 |
-
with built-in Mobile-Detect support. Made by [Muhammed Mamedov](https://github.com/mmamedov).
|
268 |
-
|
269 |
-
* [Statamic CMS Mobile Detect](https://github.com/haikulab/statamic-mobile-detect) is a plugin.
|
270 |
-
Made by [Sergei Filippov](https://github.com/haikulab/statamic-mobile-detect) of Haiku Lab.
|
271 |
-
|
272 |
-
* [Kohana Mobile Detect](https://github.com/madeinnordeste/kohana-mobile-detect) is an example of implementation of
|
273 |
-
Mobile_Detect class with Kohana framework.
|
274 |
-
Written by [Luiz Alberto S. Ribeiro](https://github.com/madeinnordeste).
|
275 |
-
|
276 |
-
* [MemHT](https://www.memht.com) is a Free PHP CMS and Blog that permit the creation and the management online
|
277 |
-
of websites with few and easy steps. Has the class included in the core.
|
278 |
-
|
279 |
-
* [concrete5](https://www.concrete5.org) is a CMS that is free and open source. The library is included in the core.
|
280 |
-
|
281 |
-
* [engine7](https://github.com/QOXCorp/exengine) is PHP Open Source Framework. The Mobile_Detect class is included in
|
282 |
-
the engine.
|
283 |
-
|
284 |
-
* [Zikula](http://zikula.org) is a free and open-source Content Management Framework, which allows you to run
|
285 |
-
impressive websites and build powerful online applications. The core uses Mobile-Detect to switch to a special
|
286 |
-
Mobile theme, using jQueryMobile.
|
287 |
-
|
288 |
-
* [UserAgentInfo](https://github.com/quentin389/UserAgentInfo) is a PHP class for parsing user agent strings
|
289 |
-
(HTTP_USER_AGENT). Includes mobile checks, bot checks, browser types/versions and more.
|
290 |
-
Based on browscap, Mobile_Detect and ua-parser. Created for high traffic websites and fast batch processing.
|
291 |
-
Made by [quentin389](https://github.com/quentin389).
|
292 |
-
|
293 |
-
* [LJ Mobile Detect](https://github.com/lewisjenkins/craft-lj-mobiledetect) is a simple implementation of Mobile Detect
|
294 |
-
for Craft CMS. Made by [Lewis Jenkins](https://github.com/lewisjenkins).
|
295 |
-
|
296 |
-
* [Detect Craft](https://github.com/mmikkel/Detect-Craft) is a Craft CMS wrapper for the Mobile_Detect library. Made by [Mikkel Rummelhoff](https://github.com/mmikkel).
|
297 |
-
|
298 |
-
* [Grav Plugin Mobile Detect](https://github.com/dimitrilongo/grav-plugin-mobile-detect/) is a simple implementation
|
299 |
-
of Mobile Detect for Grav CMS. Made by [Dimitri Longo](https://github.com/dimitrilongo).
|
300 |
-
|
301 |
-
* [Mobile_Detect module for UliCMS](https://github.com/derUli/ulicms-Mobile_Detect).
|
302 |
-
Made by [derUli](https://github.com/derUli).
|
303 |
-
|
304 |
-
**Perl**
|
305 |
-
|
306 |
-
* [MobileDetect.pm](https://www.buzzerstar.com/development/) is a Perl module for Mobile Detect.
|
307 |
-
Made by [Sebastian Enger](https://devop.tools/).
|
308 |
-
|
309 |
-
**Python**
|
310 |
-
|
311 |
-
* [pymobiledetect](https://pypi.python.org/pypi/pymobiledetect) - Mobile detect python package.
|
312 |
-
Made by Bas van Oostveen.
|
313 |
-
|
314 |
-
**Ruby**
|
315 |
-
|
316 |
-
* [mobile_detect.rb](https://github.com/ktaragorn/mobile_detect) is a Ruby gem using the JSON data exposed by the
|
317 |
-
php project and implementing a basic subset of the API (as much as can be done by the exposed data).
|
318 |
-
Made by [Karthik T](https://github.com/ktaragorn).
|
319 |
-
|
320 |
-
**Go**
|
321 |
-
|
322 |
-
* [GoMobileDetect](https://github.com/Shaked/gomobiledetect) is a Go port of Mobile Detect class.
|
323 |
-
Made by [https://github.com/Shaked](Shaked).
|
324 |
-
|
325 |
-
|
326 |
-
**LUA**
|
327 |
-
|
328 |
-
* [ua-lua](https://github.com/robinef/ua-lua) is a small lib written in LUA providing device type detection.
|
329 |
-
ua-lua is detecting mobile or tablet devices based on user-agent inside nginx daemon.
|
330 |
-
Made by [Frédéric Robinet](https://github.com/robinef).
|
331 |
-
|
332 |
-
**.Net**
|
333 |
-
|
334 |
-
* [mobile-detect](https://github.com/validide/mobile-detect) is a .Net partial port written in C#.
|
335 |
-
Made by [Valentin Dide](https://github.com/validide).
|
336 |
-
|
337 |
-
**ColdFusion**
|
338 |
-
|
339 |
-
* [MobileDetect](https://github.com/GiancarloGomez/ColdFusion-MobileDetect) is a CFC port of the
|
340 |
-
Mobile_Detect PHP Library. Made by [Giancarlo Gomez](https://github.com/GiancarloGomez).
|
341 |
-
|
342 |
-
**Experiments** :bulb:
|
343 |
-
|
344 |
-
* [Mobile Detect Fast](https://bitbucket.org/lanaguani/mobile-detect-fast/) (See: [#474](https://github.com/serbanghita/Mobile-Detect/issues/474)) is a class to increase the performance of Mobile Detect lib. Made by [LanaGuani](https://github.com/lanaguanifw).
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
vendor/mobiledetect/mobiledetectlib/composer.json
DELETED
@@ -1,31 +0,0 @@
|
|
1 |
-
{
|
2 |
-
"name": "mobiledetect/mobiledetectlib",
|
3 |
-
"type": "library",
|
4 |
-
"description": "Mobile_Detect is a lightweight PHP class for detecting mobile devices. It uses the User-Agent string combined with specific HTTP headers to detect the mobile environment.",
|
5 |
-
"keywords": ["mobile", "mobile detect", "mobile detector", "php mobile detect", "detect mobile devices"],
|
6 |
-
"homepage": "https://github.com/serbanghita/Mobile-Detect",
|
7 |
-
"license": "MIT",
|
8 |
-
"authors": [
|
9 |
-
{
|
10 |
-
"name": "Serban Ghita",
|
11 |
-
"email": "serbanghita@gmail.com",
|
12 |
-
"homepage": "http://mobiledetect.net",
|
13 |
-
"role": "Developer"
|
14 |
-
}
|
15 |
-
],
|
16 |
-
"require": {
|
17 |
-
"php": ">=5.0.0"
|
18 |
-
},
|
19 |
-
"require-dev": {
|
20 |
-
"phpunit/phpunit": "~4.8.35||~5.7"
|
21 |
-
},
|
22 |
-
"autoload": {
|
23 |
-
"classmap": ["Mobile_Detect.php"],
|
24 |
-
"psr-0": {
|
25 |
-
"Detection": "namespaced/"
|
26 |
-
}
|
27 |
-
},
|
28 |
-
"archive": {
|
29 |
-
"exclude": ["docs", "examples", "export"]
|
30 |
-
}
|
31 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
vendor/mobiledetect/mobiledetectlib/composer.lock
DELETED
@@ -1,983 +0,0 @@
|
|
1 |
-
{
|
2 |
-
"_readme": [
|
3 |
-
"This file locks the dependencies of your project to a known state",
|
4 |
-
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
|
5 |
-
"This file is @generated automatically"
|
6 |
-
],
|
7 |
-
"content-hash": "4a5fd4cd7cc7247a6df7411b031d4845",
|
8 |
-
"packages": [],
|
9 |
-
"packages-dev": [
|
10 |
-
{
|
11 |
-
"name": "doctrine/instantiator",
|
12 |
-
"version": "1.0.5",
|
13 |
-
"source": {
|
14 |
-
"type": "git",
|
15 |
-
"url": "https://github.com/doctrine/instantiator.git",
|
16 |
-
"reference": "8e884e78f9f0eb1329e445619e04456e64d8051d"
|
17 |
-
},
|
18 |
-
"dist": {
|
19 |
-
"type": "zip",
|
20 |
-
"url": "https://api.github.com/repos/doctrine/instantiator/zipball/8e884e78f9f0eb1329e445619e04456e64d8051d",
|
21 |
-
"reference": "8e884e78f9f0eb1329e445619e04456e64d8051d",
|
22 |
-
"shasum": ""
|
23 |
-
},
|
24 |
-
"require": {
|
25 |
-
"php": ">=5.3,<8.0-DEV"
|
26 |
-
},
|
27 |
-
"require-dev": {
|
28 |
-
"athletic/athletic": "~0.1.8",
|
29 |
-
"ext-pdo": "*",
|
30 |
-
"ext-phar": "*",
|
31 |
-
"phpunit/phpunit": "~4.0",
|
32 |
-
"squizlabs/php_codesniffer": "~2.0"
|
33 |
-
},
|
34 |
-
"type": "library",
|
35 |
-
"extra": {
|
36 |
-
"branch-alias": {
|
37 |
-
"dev-master": "1.0.x-dev"
|
38 |
-
}
|
39 |
-
},
|
40 |
-
"autoload": {
|
41 |
-
"psr-4": {
|
42 |
-
"Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/"
|
43 |
-
}
|
44 |
-
},
|
45 |
-
"notification-url": "https://packagist.org/downloads/",
|
46 |
-
"license": [
|
47 |
-
"MIT"
|
48 |
-
],
|
49 |
-
"authors": [
|
50 |
-
{
|
51 |
-
"name": "Marco Pivetta",
|
52 |
-
"email": "ocramius@gmail.com",
|
53 |
-
"homepage": "http://ocramius.github.com/"
|
54 |
-
}
|
55 |
-
],
|
56 |
-
"description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors",
|
57 |
-
"homepage": "https://github.com/doctrine/instantiator",
|
58 |
-
"keywords": [
|
59 |
-
"constructor",
|
60 |
-
"instantiate"
|
61 |
-
],
|
62 |
-
"time": "2015-06-14T21:17:01+00:00"
|
63 |
-
},
|
64 |
-
{
|
65 |
-
"name": "phpdocumentor/reflection-docblock",
|
66 |
-
"version": "2.0.5",
|
67 |
-
"source": {
|
68 |
-
"type": "git",
|
69 |
-
"url": "https://github.com/phpDocumentor/ReflectionDocBlock.git",
|
70 |
-
"reference": "e6a969a640b00d8daa3c66518b0405fb41ae0c4b"
|
71 |
-
},
|
72 |
-
"dist": {
|
73 |
-
"type": "zip",
|
74 |
-
"url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/e6a969a640b00d8daa3c66518b0405fb41ae0c4b",
|
75 |
-
"reference": "e6a969a640b00d8daa3c66518b0405fb41ae0c4b",
|
76 |
-
"shasum": ""
|
77 |
-
},
|
78 |
-
"require": {
|
79 |
-
"php": ">=5.3.3"
|
80 |
-
},
|
81 |
-
"require-dev": {
|
82 |
-
"phpunit/phpunit": "~4.0"
|
83 |
-
},
|
84 |
-
"suggest": {
|
85 |
-
"dflydev/markdown": "~1.0",
|
86 |
-
"erusev/parsedown": "~1.0"
|
87 |
-
},
|
88 |
-
"type": "library",
|
89 |
-
"extra": {
|
90 |
-
"branch-alias": {
|
91 |
-
"dev-master": "2.0.x-dev"
|
92 |
-
}
|
93 |
-
},
|
94 |
-
"autoload": {
|
95 |
-
"psr-0": {
|
96 |
-
"phpDocumentor": [
|
97 |
-
"src/"
|
98 |
-
]
|
99 |
-
}
|
100 |
-
},
|
101 |
-
"notification-url": "https://packagist.org/downloads/",
|
102 |
-
"license": [
|
103 |
-
"MIT"
|
104 |
-
],
|
105 |
-
"authors": [
|
106 |
-
{
|
107 |
-
"name": "Mike van Riel",
|
108 |
-
"email": "mike.vanriel@naenius.com"
|
109 |
-
}
|
110 |
-
],
|
111 |
-
"time": "2016-01-25T08:17:30+00:00"
|
112 |
-
},
|
113 |
-
{
|
114 |
-
"name": "phpspec/prophecy",
|
115 |
-
"version": "1.7.3",
|
116 |
-
"source": {
|
117 |
-
"type": "git",
|
118 |
-
"url": "https://github.com/phpspec/prophecy.git",
|
119 |
-
"reference": "e4ed002c67da8eceb0eb8ddb8b3847bb53c5c2bf"
|
120 |
-
},
|
121 |
-
"dist": {
|
122 |
-
"type": "zip",
|
123 |
-
"url": "https://api.github.com/repos/phpspec/prophecy/zipball/e4ed002c67da8eceb0eb8ddb8b3847bb53c5c2bf",
|
124 |
-
"reference": "e4ed002c67da8eceb0eb8ddb8b3847bb53c5c2bf",
|
125 |
-
"shasum": ""
|
126 |
-
},
|
127 |
-
"require": {
|
128 |
-
"doctrine/instantiator": "^1.0.2",
|
129 |
-
"php": "^5.3|^7.0",
|
130 |
-
"phpdocumentor/reflection-docblock": "^2.0|^3.0.2|^4.0",
|
131 |
-
"sebastian/comparator": "^1.1|^2.0",
|
132 |
-
"sebastian/recursion-context": "^1.0|^2.0|^3.0"
|
133 |
-
},
|
134 |
-
"require-dev": {
|
135 |
-
"phpspec/phpspec": "^2.5|^3.2",
|
136 |
-
"phpunit/phpunit": "^4.8.35 || ^5.7"
|
137 |
-
},
|
138 |
-
"type": "library",
|
139 |
-
"extra": {
|
140 |
-
"branch-alias": {
|
141 |
-
"dev-master": "1.7.x-dev"
|
142 |
-
}
|
143 |
-
},
|
144 |
-
"autoload": {
|
145 |
-
"psr-0": {
|
146 |
-
"Prophecy\\": "src/"
|
147 |
-
}
|
148 |
-
},
|
149 |
-
"notification-url": "https://packagist.org/downloads/",
|
150 |
-
"license": [
|
151 |
-
"MIT"
|
152 |
-
],
|
153 |
-
"authors": [
|
154 |
-
{
|
155 |
-
"name": "Konstantin Kudryashov",
|
156 |
-
"email": "ever.zet@gmail.com",
|
157 |
-
"homepage": "http://everzet.com"
|
158 |
-
},
|
159 |
-
{
|
160 |
-
"name": "Marcello Duarte",
|
161 |
-
"email": "marcello.duarte@gmail.com"
|
162 |
-
}
|
163 |
-
],
|
164 |
-
"description": "Highly opinionated mocking framework for PHP 5.3+",
|
165 |
-
"homepage": "https://github.com/phpspec/prophecy",
|
166 |
-
"keywords": [
|
167 |
-
"Double",
|
168 |
-
"Dummy",
|
169 |
-
"fake",
|
170 |
-
"mock",
|
171 |
-
"spy",
|
172 |
-
"stub"
|
173 |
-
],
|
174 |
-
"time": "2017-11-24T13:59:53+00:00"
|
175 |
-
},
|
176 |
-
{
|
177 |
-
"name": "phpunit/php-code-coverage",
|
178 |
-
"version": "2.2.4",
|
179 |
-
"source": {
|
180 |
-
"type": "git",
|
181 |
-
"url": "https://github.com/sebastianbergmann/php-code-coverage.git",
|
182 |
-
"reference": "eabf68b476ac7d0f73793aada060f1c1a9bf8979"
|
183 |
-
},
|
184 |
-
"dist": {
|
185 |
-
"type": "zip",
|
186 |
-
"url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/eabf68b476ac7d0f73793aada060f1c1a9bf8979",
|
187 |
-
"reference": "eabf68b476ac7d0f73793aada060f1c1a9bf8979",
|
188 |
-
"shasum": ""
|
189 |
-
},
|
190 |
-
"require": {
|
191 |
-
"php": ">=5.3.3",
|
192 |
-
"phpunit/php-file-iterator": "~1.3",
|
193 |
-
"phpunit/php-text-template": "~1.2",
|
194 |
-
"phpunit/php-token-stream": "~1.3",
|
195 |
-
"sebastian/environment": "^1.3.2",
|
196 |
-
"sebastian/version": "~1.0"
|
197 |
-
},
|
198 |
-
"require-dev": {
|
199 |
-
"ext-xdebug": ">=2.1.4",
|
200 |
-
"phpunit/phpunit": "~4"
|
201 |
-
},
|
202 |
-
"suggest": {
|
203 |
-
"ext-dom": "*",
|
204 |
-
"ext-xdebug": ">=2.2.1",
|
205 |
-
"ext-xmlwriter": "*"
|
206 |
-
},
|
207 |
-
"type": "library",
|
208 |
-
"extra": {
|
209 |
-
"branch-alias": {
|
210 |
-
"dev-master": "2.2.x-dev"
|
211 |
-
}
|
212 |
-
},
|
213 |
-
"autoload": {
|
214 |
-
"classmap": [
|
215 |
-
"src/"
|
216 |
-
]
|
217 |
-
},
|
218 |
-
"notification-url": "https://packagist.org/downloads/",
|
219 |
-
"license": [
|
220 |
-
"BSD-3-Clause"
|
221 |
-
],
|
222 |
-
"authors": [
|
223 |
-
{
|
224 |
-
"name": "Sebastian Bergmann",
|
225 |
-
"email": "sb@sebastian-bergmann.de",
|
226 |
-
"role": "lead"
|
227 |
-
}
|
228 |
-
],
|
229 |
-
"description": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.",
|
230 |
-
"homepage": "https://github.com/sebastianbergmann/php-code-coverage",
|
231 |
-
"keywords": [
|
232 |
-
"coverage",
|
233 |
-
"testing",
|
234 |
-
"xunit"
|
235 |
-
],
|
236 |
-
"time": "2015-10-06T15:47:00+00:00"
|
237 |
-
},
|
238 |
-
{
|
239 |
-
"name": "phpunit/php-file-iterator",
|
240 |
-
"version": "1.4.5",
|
241 |
-
"source": {
|
242 |
-
"type": "git",
|
243 |
-
"url": "https://github.com/sebastianbergmann/php-file-iterator.git",
|
244 |
-
"reference": "730b01bc3e867237eaac355e06a36b85dd93a8b4"
|
245 |
-
},
|
246 |
-
"dist": {
|
247 |
-
"type": "zip",
|
248 |
-
"url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/730b01bc3e867237eaac355e06a36b85dd93a8b4",
|
249 |
-
"reference": "730b01bc3e867237eaac355e06a36b85dd93a8b4",
|
250 |
-
"shasum": ""
|
251 |
-
},
|
252 |
-
"require": {
|
253 |
-
"php": ">=5.3.3"
|
254 |
-
},
|
255 |
-
"type": "library",
|
256 |
-
"extra": {
|
257 |
-
"branch-alias": {
|
258 |
-
"dev-master": "1.4.x-dev"
|
259 |
-
}
|
260 |
-
},
|
261 |
-
"autoload": {
|
262 |
-
"classmap": [
|
263 |
-
"src/"
|
264 |
-
]
|
265 |
-
},
|
266 |
-
"notification-url": "https://packagist.org/downloads/",
|
267 |
-
"license": [
|
268 |
-
"BSD-3-Clause"
|
269 |
-
],
|
270 |
-
"authors": [
|
271 |
-
{
|
272 |
-
"name": "Sebastian Bergmann",
|
273 |
-
"email": "sb@sebastian-bergmann.de",
|
274 |
-
"role": "lead"
|
275 |
-
}
|
276 |
-
],
|
277 |
-
"description": "FilterIterator implementation that filters files based on a list of suffixes.",
|
278 |
-
"homepage": "https://github.com/sebastianbergmann/php-file-iterator/",
|
279 |
-
"keywords": [
|
280 |
-
"filesystem",
|
281 |
-
"iterator"
|
282 |
-
],
|
283 |
-
"time": "2017-11-27T13:52:08+00:00"
|
284 |
-
},
|
285 |
-
{
|
286 |
-
"name": "phpunit/php-text-template",
|
287 |
-
"version": "1.2.1",
|
288 |
-
"source": {
|
289 |
-
"type": "git",
|
290 |
-
"url": "https://github.com/sebastianbergmann/php-text-template.git",
|
291 |
-
"reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686"
|
292 |
-
},
|
293 |
-
"dist": {
|
294 |
-
"type": "zip",
|
295 |
-
"url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/31f8b717e51d9a2afca6c9f046f5d69fc27c8686",
|
296 |
-
"reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686",
|
297 |
-
"shasum": ""
|
298 |
-
},
|
299 |
-
"require": {
|
300 |
-
"php": ">=5.3.3"
|
301 |
-
},
|
302 |
-
"type": "library",
|
303 |
-
"autoload": {
|
304 |
-
"classmap": [
|
305 |
-
"src/"
|
306 |
-
]
|
307 |
-
},
|
308 |
-
"notification-url": "https://packagist.org/downloads/",
|
309 |
-
"license": [
|
310 |
-
"BSD-3-Clause"
|
311 |
-
],
|
312 |
-
"authors": [
|
313 |
-
{
|
314 |
-
"name": "Sebastian Bergmann",
|
315 |
-
"email": "sebastian@phpunit.de",
|
316 |
-
"role": "lead"
|
317 |
-
}
|
318 |
-
],
|
319 |
-
"description": "Simple template engine.",
|
320 |
-
"homepage": "https://github.com/sebastianbergmann/php-text-template/",
|
321 |
-
"keywords": [
|
322 |
-
"template"
|
323 |
-
],
|
324 |
-
"time": "2015-06-21T13:50:34+00:00"
|
325 |
-
},
|
326 |
-
{
|
327 |
-
"name": "phpunit/php-timer",
|
328 |
-
"version": "1.0.9",
|
329 |
-
"source": {
|
330 |
-
"type": "git",
|
331 |
-
"url": "https://github.com/sebastianbergmann/php-timer.git",
|
332 |
-
"reference": "3dcf38ca72b158baf0bc245e9184d3fdffa9c46f"
|
333 |
-
},
|
334 |
-
"dist": {
|
335 |
-
"type": "zip",
|
336 |
-
"url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/3dcf38ca72b158baf0bc245e9184d3fdffa9c46f",
|
337 |
-
"reference": "3dcf38ca72b158baf0bc245e9184d3fdffa9c46f",
|
338 |
-
"shasum": ""
|
339 |
-
},
|
340 |
-
"require": {
|
341 |
-
"php": "^5.3.3 || ^7.0"
|
342 |
-
},
|
343 |
-
"require-dev": {
|
344 |
-
"phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.0"
|
345 |
-
},
|
346 |
-
"type": "library",
|
347 |
-
"extra": {
|
348 |
-
"branch-alias": {
|
349 |
-
"dev-master": "1.0-dev"
|
350 |
-
}
|
351 |
-
},
|
352 |
-
"autoload": {
|
353 |
-
"classmap": [
|
354 |
-
"src/"
|
355 |
-
]
|
356 |
-
},
|
357 |
-
"notification-url": "https://packagist.org/downloads/",
|
358 |
-
"license": [
|
359 |
-
"BSD-3-Clause"
|
360 |
-
],
|
361 |
-
"authors": [
|
362 |
-
{
|
363 |
-
"name": "Sebastian Bergmann",
|
364 |
-
"email": "sb@sebastian-bergmann.de",
|
365 |
-
"role": "lead"
|
366 |
-
}
|
367 |
-
],
|
368 |
-
"description": "Utility class for timing",
|
369 |
-
"homepage": "https://github.com/sebastianbergmann/php-timer/",
|
370 |
-
"keywords": [
|
371 |
-
"timer"
|
372 |
-
],
|
373 |
-
"time": "2017-02-26T11:10:40+00:00"
|
374 |
-
},
|
375 |
-
{
|
376 |
-
"name": "phpunit/php-token-stream",
|
377 |
-
"version": "1.4.12",
|
378 |
-
"source": {
|
379 |
-
"type": "git",
|
380 |
-
"url": "https://github.com/sebastianbergmann/php-token-stream.git",
|
381 |
-
"reference": "1ce90ba27c42e4e44e6d8458241466380b51fa16"
|
382 |
-
},
|
383 |
-
"dist": {
|
384 |
-
"type": "zip",
|
385 |
-
"url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/1ce90ba27c42e4e44e6d8458241466380b51fa16",
|
386 |
-
"reference": "1ce90ba27c42e4e44e6d8458241466380b51fa16",
|
387 |
-
"shasum": ""
|
388 |
-
},
|
389 |
-
"require": {
|
390 |
-
"ext-tokenizer": "*",
|
391 |
-
"php": ">=5.3.3"
|
392 |
-
},
|
393 |
-
"require-dev": {
|
394 |
-
"phpunit/phpunit": "~4.2"
|
395 |
-
},
|
396 |
-
"type": "library",
|
397 |
-
"extra": {
|
398 |
-
"branch-alias": {
|
399 |
-
"dev-master": "1.4-dev"
|
400 |
-
}
|
401 |
-
},
|
402 |
-
"autoload": {
|
403 |
-
"classmap": [
|
404 |
-
"src/"
|
405 |
-
]
|
406 |
-
},
|
407 |
-
"notification-url": "https://packagist.org/downloads/",
|
408 |
-
"license": [
|
409 |
-
"BSD-3-Clause"
|
410 |
-
],
|
411 |
-
"authors": [
|
412 |
-
{
|
413 |
-
"name": "Sebastian Bergmann",
|
414 |
-
"email": "sebastian@phpunit.de"
|
415 |
-
}
|
416 |
-
],
|
417 |
-
"description": "Wrapper around PHP's tokenizer extension.",
|
418 |
-
"homepage": "https://github.com/sebastianbergmann/php-token-stream/",
|
419 |
-
"keywords": [
|
420 |
-
"tokenizer"
|
421 |
-
],
|
422 |
-
"time": "2017-12-04T08:55:13+00:00"
|
423 |
-
},
|
424 |
-
{
|
425 |
-
"name": "phpunit/phpunit",
|
426 |
-
"version": "4.8.36",
|
427 |
-
"source": {
|
428 |
-
"type": "git",
|
429 |
-
"url": "https://github.com/sebastianbergmann/phpunit.git",
|
430 |
-
"reference": "46023de9a91eec7dfb06cc56cb4e260017298517"
|
431 |
-
},
|
432 |
-
"dist": {
|
433 |
-
"type": "zip",
|
434 |
-
"url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/46023de9a91eec7dfb06cc56cb4e260017298517",
|
435 |
-
"reference": "46023de9a91eec7dfb06cc56cb4e260017298517",
|
436 |
-
"shasum": ""
|
437 |
-
},
|
438 |
-
"require": {
|
439 |
-
"ext-dom": "*",
|
440 |
-
"ext-json": "*",
|
441 |
-
"ext-pcre": "*",
|
442 |
-
"ext-reflection": "*",
|
443 |
-
"ext-spl": "*",
|
444 |
-
"php": ">=5.3.3",
|
445 |
-
"phpspec/prophecy": "^1.3.1",
|
446 |
-
"phpunit/php-code-coverage": "~2.1",
|
447 |
-
"phpunit/php-file-iterator": "~1.4",
|
448 |
-
"phpunit/php-text-template": "~1.2",
|
449 |
-
"phpunit/php-timer": "^1.0.6",
|
450 |
-
"phpunit/phpunit-mock-objects": "~2.3",
|
451 |
-
"sebastian/comparator": "~1.2.2",
|
452 |
-
"sebastian/diff": "~1.2",
|
453 |
-
"sebastian/environment": "~1.3",
|
454 |
-
"sebastian/exporter": "~1.2",
|
455 |
-
"sebastian/global-state": "~1.0",
|
456 |
-
"sebastian/version": "~1.0",
|
457 |
-
"symfony/yaml": "~2.1|~3.0"
|
458 |
-
},
|
459 |
-
"suggest": {
|
460 |
-
"phpunit/php-invoker": "~1.1"
|
461 |
-
},
|
462 |
-
"bin": [
|
463 |
-
"phpunit"
|
464 |
-
],
|
465 |
-
"type": "library",
|
466 |
-
"extra": {
|
467 |
-
"branch-alias": {
|
468 |
-
"dev-master": "4.8.x-dev"
|
469 |
-
}
|
470 |
-
},
|
471 |
-
"autoload": {
|
472 |
-
"classmap": [
|
473 |
-
"src/"
|
474 |
-
]
|
475 |
-
},
|
476 |
-
"notification-url": "https://packagist.org/downloads/",
|
477 |
-
"license": [
|
478 |
-
"BSD-3-Clause"
|
479 |
-
],
|
480 |
-
"authors": [
|
481 |
-
{
|
482 |
-
"name": "Sebastian Bergmann",
|
483 |
-
"email": "sebastian@phpunit.de",
|
484 |
-
"role": "lead"
|
485 |
-
}
|
486 |
-
],
|
487 |
-
"description": "The PHP Unit Testing framework.",
|
488 |
-
"homepage": "https://phpunit.de/",
|
489 |
-
"keywords": [
|
490 |
-
"phpunit",
|
491 |
-
"testing",
|
492 |
-
"xunit"
|
493 |
-
],
|
494 |
-
"time": "2017-06-21T08:07:12+00:00"
|
495 |
-
},
|
496 |
-
{
|
497 |
-
"name": "phpunit/phpunit-mock-objects",
|
498 |
-
"version": "2.3.8",
|
499 |
-
"source": {
|
500 |
-
"type": "git",
|
501 |
-
"url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git",
|
502 |
-
"reference": "ac8e7a3db35738d56ee9a76e78a4e03d97628983"
|
503 |
-
},
|
504 |
-
"dist": {
|
505 |
-
"type": "zip",
|
506 |
-
"url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/ac8e7a3db35738d56ee9a76e78a4e03d97628983",
|
507 |
-
"reference": "ac8e7a3db35738d56ee9a76e78a4e03d97628983",
|
508 |
-
"shasum": ""
|
509 |
-
},
|
510 |
-
"require": {
|
511 |
-
"doctrine/instantiator": "^1.0.2",
|
512 |
-
"php": ">=5.3.3",
|
513 |
-
"phpunit/php-text-template": "~1.2",
|
514 |
-
"sebastian/exporter": "~1.2"
|
515 |
-
},
|
516 |
-
"require-dev": {
|
517 |
-
"phpunit/phpunit": "~4.4"
|
518 |
-
},
|
519 |
-
"suggest": {
|
520 |
-
"ext-soap": "*"
|
521 |
-
},
|
522 |
-
"type": "library",
|
523 |
-
"extra": {
|
524 |
-
"branch-alias": {
|
525 |
-
"dev-master": "2.3.x-dev"
|
526 |
-
}
|
527 |
-
},
|
528 |
-
"autoload": {
|
529 |
-
"classmap": [
|
530 |
-
"src/"
|
531 |
-
]
|
532 |
-
},
|
533 |
-
"notification-url": "https://packagist.org/downloads/",
|
534 |
-
"license": [
|
535 |
-
"BSD-3-Clause"
|
536 |
-
],
|
537 |
-
"authors": [
|
538 |
-
{
|
539 |
-
"name": "Sebastian Bergmann",
|
540 |
-
"email": "sb@sebastian-bergmann.de",
|
541 |
-
"role": "lead"
|
542 |
-
}
|
543 |
-
],
|
544 |
-
"description": "Mock Object library for PHPUnit",
|
545 |
-
"homepage": "https://github.com/sebastianbergmann/phpunit-mock-objects/",
|
546 |
-
"keywords": [
|
547 |
-
"mock",
|
548 |
-
"xunit"
|
549 |
-
],
|
550 |
-
"time": "2015-10-02T06:51:40+00:00"
|
551 |
-
},
|
552 |
-
{
|
553 |
-
"name": "sebastian/comparator",
|
554 |
-
"version": "1.2.4",
|
555 |
-
"source": {
|
556 |
-
"type": "git",
|
557 |
-
"url": "https://github.com/sebastianbergmann/comparator.git",
|
558 |
-
"reference": "2b7424b55f5047b47ac6e5ccb20b2aea4011d9be"
|
559 |
-
},
|
560 |
-
"dist": {
|
561 |
-
"type": "zip",
|
562 |
-
"url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/2b7424b55f5047b47ac6e5ccb20b2aea4011d9be",
|
563 |
-
"reference": "2b7424b55f5047b47ac6e5ccb20b2aea4011d9be",
|
564 |
-
"shasum": ""
|
565 |
-
},
|
566 |
-
"require": {
|
567 |
-
"php": ">=5.3.3",
|
568 |
-
"sebastian/diff": "~1.2",
|
569 |
-
"sebastian/exporter": "~1.2 || ~2.0"
|
570 |
-
},
|
571 |
-
"require-dev": {
|
572 |
-
"phpunit/phpunit": "~4.4"
|
573 |
-
},
|
574 |
-
"type": "library",
|
575 |
-
"extra": {
|
576 |
-
"branch-alias": {
|
577 |
-
"dev-master": "1.2.x-dev"
|
578 |
-
}
|
579 |
-
},
|
580 |
-
"autoload": {
|
581 |
-
"classmap": [
|
582 |
-
"src/"
|
583 |
-
]
|
584 |
-
},
|
585 |
-
"notification-url": "https://packagist.org/downloads/",
|
586 |
-
"license": [
|
587 |
-
"BSD-3-Clause"
|
588 |
-
],
|
589 |
-
"authors": [
|
590 |
-
{
|
591 |
-
"name": "Jeff Welch",
|
592 |
-
"email": "whatthejeff@gmail.com"
|
593 |
-
},
|
594 |
-
{
|
595 |
-
"name": "Volker Dusch",
|
596 |
-
"email": "github@wallbash.com"
|
597 |
-
},
|
598 |
-
{
|
599 |
-
"name": "Bernhard Schussek",
|
600 |
-
"email": "bschussek@2bepublished.at"
|
601 |
-
},
|
602 |
-
{
|
603 |
-
"name": "Sebastian Bergmann",
|
604 |
-
"email": "sebastian@phpunit.de"
|
605 |
-
}
|
606 |
-
],
|
607 |
-
"description": "Provides the functionality to compare PHP values for equality",
|
608 |
-
"homepage": "http://www.github.com/sebastianbergmann/comparator",
|
609 |
-
"keywords": [
|
610 |
-
"comparator",
|
611 |
-
"compare",
|
612 |
-
"equality"
|
613 |
-
],
|
614 |
-
"time": "2017-01-29T09:50:25+00:00"
|
615 |
-
},
|
616 |
-
{
|
617 |
-
"name": "sebastian/diff",
|
618 |
-
"version": "1.4.3",
|
619 |
-
"source": {
|
620 |
-
"type": "git",
|
621 |
-
"url": "https://github.com/sebastianbergmann/diff.git",
|
622 |
-
"reference": "7f066a26a962dbe58ddea9f72a4e82874a3975a4"
|
623 |
-
},
|
624 |
-
"dist": {
|
625 |
-
"type": "zip",
|
626 |
-
"url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/7f066a26a962dbe58ddea9f72a4e82874a3975a4",
|
627 |
-
"reference": "7f066a26a962dbe58ddea9f72a4e82874a3975a4",
|
628 |
-
"shasum": ""
|
629 |
-
},
|
630 |
-
"require": {
|
631 |
-
"php": "^5.3.3 || ^7.0"
|
632 |
-
},
|
633 |
-
"require-dev": {
|
634 |
-
"phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.0"
|
635 |
-
},
|
636 |
-
"type": "library",
|
637 |
-
"extra": {
|
638 |
-
"branch-alias": {
|
639 |
-
"dev-master": "1.4-dev"
|
640 |
-
}
|
641 |
-
},
|
642 |
-
"autoload": {
|
643 |
-
"classmap": [
|
644 |
-
"src/"
|
645 |
-
]
|
646 |
-
},
|
647 |
-
"notification-url": "https://packagist.org/downloads/",
|
648 |
-
"license": [
|
649 |
-
"BSD-3-Clause"
|
650 |
-
],
|
651 |
-
"authors": [
|
652 |
-
{
|
653 |
-
"name": "Kore Nordmann",
|
654 |
-
"email": "mail@kore-nordmann.de"
|
655 |
-
},
|
656 |
-
{
|
657 |
-
"name": "Sebastian Bergmann",
|
658 |
-
"email": "sebastian@phpunit.de"
|
659 |
-
}
|
660 |
-
],
|
661 |
-
"description": "Diff implementation",
|
662 |
-
"homepage": "https://github.com/sebastianbergmann/diff",
|
663 |
-
"keywords": [
|
664 |
-
"diff"
|
665 |
-
],
|
666 |
-
"time": "2017-05-22T07:24:03+00:00"
|
667 |
-
},
|
668 |
-
{
|
669 |
-
"name": "sebastian/environment",
|
670 |
-
"version": "1.3.8",
|
671 |
-
"source": {
|
672 |
-
"type": "git",
|
673 |
-
"url": "https://github.com/sebastianbergmann/environment.git",
|
674 |
-
"reference": "be2c607e43ce4c89ecd60e75c6a85c126e754aea"
|
675 |
-
},
|
676 |
-
"dist": {
|
677 |
-
"type": "zip",
|
678 |
-
"url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/be2c607e43ce4c89ecd60e75c6a85c126e754aea",
|
679 |
-
"reference": "be2c607e43ce4c89ecd60e75c6a85c126e754aea",
|
680 |
-
"shasum": ""
|
681 |
-
},
|
682 |
-
"require": {
|
683 |
-
"php": "^5.3.3 || ^7.0"
|
684 |
-
},
|
685 |
-
"require-dev": {
|
686 |
-
"phpunit/phpunit": "^4.8 || ^5.0"
|
687 |
-
},
|
688 |
-
"type": "library",
|
689 |
-
"extra": {
|
690 |
-
"branch-alias": {
|
691 |
-
"dev-master": "1.3.x-dev"
|
692 |
-
}
|
693 |
-
},
|
694 |
-
"autoload": {
|
695 |
-
"classmap": [
|
696 |
-
"src/"
|
697 |
-
]
|
698 |
-
},
|
699 |
-
"notification-url": "https://packagist.org/downloads/",
|
700 |
-
"license": [
|
701 |
-
"BSD-3-Clause"
|
702 |
-
],
|
703 |
-
"authors": [
|
704 |
-
{
|
705 |
-
"name": "Sebastian Bergmann",
|
706 |
-
"email": "sebastian@phpunit.de"
|
707 |
-
}
|
708 |
-
],
|
709 |
-
"description": "Provides functionality to handle HHVM/PHP environments",
|
710 |
-
"homepage": "http://www.github.com/sebastianbergmann/environment",
|
711 |
-
"keywords": [
|
712 |
-
"Xdebug",
|
713 |
-
"environment",
|
714 |
-
"hhvm"
|
715 |
-
],
|
716 |
-
"time": "2016-08-18T05:49:44+00:00"
|
717 |
-
},
|
718 |
-
{
|
719 |
-
"name": "sebastian/exporter",
|
720 |
-
"version": "1.2.2",
|
721 |
-
"source": {
|
722 |
-
"type": "git",
|
723 |
-
"url": "https://github.com/sebastianbergmann/exporter.git",
|
724 |
-
"reference": "42c4c2eec485ee3e159ec9884f95b431287edde4"
|
725 |
-
},
|
726 |
-
"dist": {
|
727 |
-
"type": "zip",
|
728 |
-
"url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/42c4c2eec485ee3e159ec9884f95b431287edde4",
|
729 |
-
"reference": "42c4c2eec485ee3e159ec9884f95b431287edde4",
|
730 |
-
"shasum": ""
|
731 |
-
},
|
732 |
-
"require": {
|
733 |
-
"php": ">=5.3.3",
|
734 |
-
"sebastian/recursion-context": "~1.0"
|
735 |
-
},
|
736 |
-
"require-dev": {
|
737 |
-
"ext-mbstring": "*",
|
738 |
-
"phpunit/phpunit": "~4.4"
|
739 |
-
},
|
740 |
-
"type": "library",
|
741 |
-
"extra": {
|
742 |
-
"branch-alias": {
|
743 |
-
"dev-master": "1.3.x-dev"
|
744 |
-
}
|
745 |
-
},
|
746 |
-
"autoload": {
|
747 |
-
"classmap": [
|
748 |
-
"src/"
|
749 |
-
]
|
750 |
-
},
|
751 |
-
"notification-url": "https://packagist.org/downloads/",
|
752 |
-
"license": [
|
753 |
-
"BSD-3-Clause"
|
754 |
-
],
|
755 |
-
"authors": [
|
756 |
-
{
|
757 |
-
"name": "Jeff Welch",
|
758 |
-
"email": "whatthejeff@gmail.com"
|
759 |
-
},
|
760 |
-
{
|
761 |
-
"name": "Volker Dusch",
|
762 |
-
"email": "github@wallbash.com"
|
763 |
-
},
|
764 |
-
{
|
765 |
-
"name": "Bernhard Schussek",
|
766 |
-
"email": "bschussek@2bepublished.at"
|
767 |
-
},
|
768 |
-
{
|
769 |
-
"name": "Sebastian Bergmann",
|
770 |
-
"email": "sebastian@phpunit.de"
|
771 |
-
},
|
772 |
-
{
|
773 |
-
"name": "Adam Harvey",
|
774 |
-
"email": "aharvey@php.net"
|
775 |
-
}
|
776 |
-
],
|
777 |
-
"description": "Provides the functionality to export PHP variables for visualization",
|
778 |
-
"homepage": "http://www.github.com/sebastianbergmann/exporter",
|
779 |
-
"keywords": [
|
780 |
-
"export",
|
781 |
-
"exporter"
|
782 |
-
],
|
783 |
-
"time": "2016-06-17T09:04:28+00:00"
|
784 |
-
},
|
785 |
-
{
|
786 |
-
"name": "sebastian/global-state",
|
787 |
-
"version": "1.1.1",
|
788 |
-
"source": {
|
789 |
-
"type": "git",
|
790 |
-
"url": "https://github.com/sebastianbergmann/global-state.git",
|
791 |
-
"reference": "bc37d50fea7d017d3d340f230811c9f1d7280af4"
|
792 |
-
},
|
793 |
-
"dist": {
|
794 |
-
"type": "zip",
|
795 |
-
"url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/bc37d50fea7d017d3d340f230811c9f1d7280af4",
|
796 |
-
"reference": "bc37d50fea7d017d3d340f230811c9f1d7280af4",
|
797 |
-
"shasum": ""
|
798 |
-
},
|
799 |
-
"require": {
|
800 |
-
"php": ">=5.3.3"
|
801 |
-
},
|
802 |
-
"require-dev": {
|
803 |
-
"phpunit/phpunit": "~4.2"
|
804 |
-
},
|
805 |
-
"suggest": {
|
806 |
-
"ext-uopz": "*"
|
807 |
-
},
|
808 |
-
"type": "library",
|
809 |
-
"extra": {
|
810 |
-
"branch-alias": {
|
811 |
-
"dev-master": "1.0-dev"
|
812 |
-
}
|
813 |
-
},
|
814 |
-
"autoload": {
|
815 |
-
"classmap": [
|
816 |
-
"src/"
|
817 |
-
]
|
818 |
-
},
|
819 |
-
"notification-url": "https://packagist.org/downloads/",
|
820 |
-
"license": [
|
821 |
-
"BSD-3-Clause"
|
822 |
-
],
|
823 |
-
"authors": [
|
824 |
-
{
|
825 |
-
"name": "Sebastian Bergmann",
|
826 |
-
"email": "sebastian@phpunit.de"
|
827 |
-
}
|
828 |
-
],
|
829 |
-
"description": "Snapshotting of global state",
|
830 |
-
"homepage": "http://www.github.com/sebastianbergmann/global-state",
|
831 |
-
"keywords": [
|
832 |
-
"global state"
|
833 |
-
],
|
834 |
-
"time": "2015-10-12T03:26:01+00:00"
|
835 |
-
},
|
836 |
-
{
|
837 |
-
"name": "sebastian/recursion-context",
|
838 |
-
"version": "1.0.5",
|
839 |
-
"source": {
|
840 |
-
"type": "git",
|
841 |
-
"url": "https://github.com/sebastianbergmann/recursion-context.git",
|
842 |
-
"reference": "b19cc3298482a335a95f3016d2f8a6950f0fbcd7"
|
843 |
-
},
|
844 |
-
"dist": {
|
845 |
-
"type": "zip",
|
846 |
-
"url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/b19cc3298482a335a95f3016d2f8a6950f0fbcd7",
|
847 |
-
"reference": "b19cc3298482a335a95f3016d2f8a6950f0fbcd7",
|
848 |
-
"shasum": ""
|
849 |
-
},
|
850 |
-
"require": {
|
851 |
-
"php": ">=5.3.3"
|
852 |
-
},
|
853 |
-
"require-dev": {
|
854 |
-
"phpunit/phpunit": "~4.4"
|
855 |
-
},
|
856 |
-
"type": "library",
|
857 |
-
"extra": {
|
858 |
-
"branch-alias": {
|
859 |
-
"dev-master": "1.0.x-dev"
|
860 |
-
}
|
861 |
-
},
|
862 |
-
"autoload": {
|
863 |
-
"classmap": [
|
864 |
-
"src/"
|
865 |
-
]
|
866 |
-
},
|
867 |
-
"notification-url": "https://packagist.org/downloads/",
|
868 |
-
"license": [
|
869 |
-
"BSD-3-Clause"
|
870 |
-
],
|
871 |
-
"authors": [
|
872 |
-
{
|
873 |
-
"name": "Jeff Welch",
|
874 |
-
"email": "whatthejeff@gmail.com"
|
875 |
-
},
|
876 |
-
{
|
877 |
-
"name": "Sebastian Bergmann",
|
878 |
-
"email": "sebastian@phpunit.de"
|
879 |
-
},
|
880 |
-
{
|
881 |
-
"name": "Adam Harvey",
|
882 |
-
"email": "aharvey@php.net"
|
883 |
-
}
|
884 |
-
],
|
885 |
-
"description": "Provides functionality to recursively process PHP variables",
|
886 |
-
"homepage": "http://www.github.com/sebastianbergmann/recursion-context",
|
887 |
-
"time": "2016-10-03T07:41:43+00:00"
|
888 |
-
},
|
889 |
-
{
|
890 |
-
"name": "sebastian/version",
|
891 |
-
"version": "1.0.6",
|
892 |
-
"source": {
|
893 |
-
"type": "git",
|
894 |
-
"url": "https://github.com/sebastianbergmann/version.git",
|
895 |
-
"reference": "58b3a85e7999757d6ad81c787a1fbf5ff6c628c6"
|
896 |
-
},
|
897 |
-
"dist": {
|
898 |
-
"type": "zip",
|
899 |
-
"url": "https://api.github.com/repos/sebastianbergmann/version/zipball/58b3a85e7999757d6ad81c787a1fbf5ff6c628c6",
|
900 |
-
"reference": "58b3a85e7999757d6ad81c787a1fbf5ff6c628c6",
|
901 |
-
"shasum": ""
|
902 |
-
},
|
903 |
-
"type": "library",
|
904 |
-
"autoload": {
|
905 |
-
"classmap": [
|
906 |
-
"src/"
|
907 |
-
]
|
908 |
-
},
|
909 |
-
"notification-url": "https://packagist.org/downloads/",
|
910 |
-
"license": [
|
911 |
-
"BSD-3-Clause"
|
912 |
-
],
|
913 |
-
"authors": [
|
914 |
-
{
|
915 |
-
"name": "Sebastian Bergmann",
|
916 |
-
"email": "sebastian@phpunit.de",
|
917 |
-
"role": "lead"
|
918 |
-
}
|
919 |
-
],
|
920 |
-
"description": "Library that helps with managing the version number of Git-hosted PHP projects",
|
921 |
-
"homepage": "https://github.com/sebastianbergmann/version",
|
922 |
-
"time": "2015-06-21T13:59:46+00:00"
|
923 |
-
},
|
924 |
-
{
|
925 |
-
"name": "symfony/yaml",
|
926 |
-
"version": "v2.8.32",
|
927 |
-
"source": {
|
928 |
-
"type": "git",
|
929 |
-
"url": "https://github.com/symfony/yaml.git",
|
930 |
-
"reference": "968ef42161e4bc04200119da473077f9e7015128"
|
931 |
-
},
|
932 |
-
"dist": {
|
933 |
-
"type": "zip",
|
934 |
-
"url": "https://api.github.com/repos/symfony/yaml/zipball/968ef42161e4bc04200119da473077f9e7015128",
|
935 |
-
"reference": "968ef42161e4bc04200119da473077f9e7015128",
|
936 |
-
"shasum": ""
|
937 |
-
},
|
938 |
-
"require": {
|
939 |
-
"php": ">=5.3.9"
|
940 |
-
},
|
941 |
-
"type": "library",
|
942 |
-
"extra": {
|
943 |
-
"branch-alias": {
|
944 |
-
"dev-master": "2.8-dev"
|
945 |
-
}
|
946 |
-
},
|
947 |
-
"autoload": {
|
948 |
-
"psr-4": {
|
949 |
-
"Symfony\\Component\\Yaml\\": ""
|
950 |
-
},
|
951 |
-
"exclude-from-classmap": [
|
952 |
-
"/Tests/"
|
953 |
-
]
|
954 |
-
},
|
955 |
-
"notification-url": "https://packagist.org/downloads/",
|
956 |
-
"license": [
|
957 |
-
"MIT"
|
958 |
-
],
|
959 |
-
"authors": [
|
960 |
-
{
|
961 |
-
"name": "Fabien Potencier",
|
962 |
-
"email": "fabien@symfony.com"
|
963 |
-
},
|
964 |
-
{
|
965 |
-
"name": "Symfony Community",
|
966 |
-
"homepage": "https://symfony.com/contributors"
|
967 |
-
}
|
968 |
-
],
|
969 |
-
"description": "Symfony Yaml Component",
|
970 |
-
"homepage": "https://symfony.com",
|
971 |
-
"time": "2017-11-29T09:33:18+00:00"
|
972 |
-
}
|
973 |
-
],
|
974 |
-
"aliases": [],
|
975 |
-
"minimum-stability": "stable",
|
976 |
-
"stability-flags": [],
|
977 |
-
"prefer-stable": false,
|
978 |
-
"prefer-lowest": false,
|
979 |
-
"platform": {
|
980 |
-
"php": ">=5.0.0"
|
981 |
-
},
|
982 |
-
"platform-dev": []
|
983 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
vendor/mobiledetect/mobiledetectlib/docker-compose.yml
DELETED
@@ -1,16 +0,0 @@
|
|
1 |
-
app:
|
2 |
-
restart: 'on-failure'
|
3 |
-
image: php:7
|
4 |
-
working_dir: /app
|
5 |
-
command: vendor/bin/phpunit -v -c tests/phpunit.xml --coverage-text --strict-coverage --stop-on-risky
|
6 |
-
ports:
|
7 |
-
- "8000:8000"
|
8 |
-
volumes:
|
9 |
-
- .:/app
|
10 |
-
|
11 |
-
composer:
|
12 |
-
restart: 'no'
|
13 |
-
image: composer/composer:php7
|
14 |
-
command: install
|
15 |
-
volumes:
|
16 |
-
- .:/app
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
vendor/mobiledetect/mobiledetectlib/docs/CONTRIBUTING.md
DELETED
@@ -1,48 +0,0 @@
|
|
1 |
-
**Reporting issues**
|
2 |
-
|
3 |
-
1. Specify the User-agent by visiting [http://demo.mobiledetect.net](http://demo.mobiledetect.net).
|
4 |
-
1. Specify the expected behaviour.
|
5 |
-
|
6 |
-
**Developing**
|
7 |
-
|
8 |
-
1. Fork Mobile Detect repository. See ["How to fork"](https://help.github.com/articles/fork-a-repo/#fork-an-example-repository) example.
|
9 |
-
1. `git clone https://github.com/[yourname]/Mobile-Detect.git`
|
10 |
-
1. `git add remote serbanghita https://github.com/serbanghita/Mobile-Detect.git`
|
11 |
-
1. `git remote -v` - You should see:
|
12 |
-
```
|
13 |
-
origin git@github.com:serbanghita/Mobile-Detect.git
|
14 |
-
serbanghita https://github.com/serbanghita/Mobile-Detect.git
|
15 |
-
```
|
16 |
-
1. `git checkout -b devel origin/devel`
|
17 |
-
1. `composer install`
|
18 |
-
1. Start working on your changes.
|
19 |
-
1. If you add new methods or make structural changes to the `Mobile_Detect.php` class
|
20 |
-
you need to add unit tests!
|
21 |
-
1. If you add new regexes make sure you commit the User-Agents in [`tests/providers/vendors`](https://github.com/serbanghita/Mobile-Detect/tree/master/tests/providers/vendors)
|
22 |
-
1. Run tests `vendor/bin/phpunit -v -c tests/phpunit.xml --coverage-text --strict-coverage --stop-on-risky`
|
23 |
-
1. `git status` or `git diff` - inspect your changes
|
24 |
-
1 `git stage .`
|
25 |
-
1. `git commit -m "[your commit message here]`
|
26 |
-
1. `git push origin devel`
|
27 |
-
1. Go to your repo on GitHub and ["Submit the PR"](https://help.github.com/articles/about-pull-requests/)
|
28 |
-
|
29 |
-
**New module, plugin, plugin or port**
|
30 |
-
|
31 |
-
[Submit new module, plugin, port](../../issues/new?title=New%203rd%20party%20module&body=Name,%20Link%20and%20Description%20of%20the%20module.)
|
32 |
-
including the following information:
|
33 |
-
* Module name
|
34 |
-
* Description
|
35 |
-
* Link
|
36 |
-
* Author
|
37 |
-
|
38 |
-
Or you can submit a PR against `README.md`.
|
39 |
-
|
40 |
-
**Website updates**
|
41 |
-
|
42 |
-
1. Our official website is hosted at [http://mobiledetect.net](http://mobiledetect.net).
|
43 |
-
1. The files are found on the `gh-pages` branch.
|
44 |
-
1. `git checkout gh-pages`
|
45 |
-
1. `npm install -g browser-sync`
|
46 |
-
1. `browser-sync start --s . --f . --port 3000 --reload-debounce 1500 --no-ui`
|
47 |
-
1. Go to `http://localhost:3000` and make changes.
|
48 |
-
1. Commit, push and submit the PR against `serbanghita:gh-pages`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
vendor/mobiledetect/mobiledetectlib/docs/HISTORY.md
DELETED
@@ -1,11 +0,0 @@
|
|
1 |
-
The first version of the script was developed in 2009 and it was hosted at https://code.google.com/p/php-mobile-detect/, it was a small project with around 30 stars. (Original blog post by Victor: http://victorstanciu.ro/detectarea-platformelor-mobile-in-php/)
|
2 |
-
|
3 |
-
In December 2011 it received a major update from the first version, an important number of issues were fixed, then 2.0 was launched. The new version marks a new mindset and also featuring tablet detection.
|
4 |
-
|
5 |
-
Throughout 2012 the script has been updated constantly and we have received tons of feedback and requests.
|
6 |
-
|
7 |
-
In July 2012 we moved the repository from Google Code to GitHub in order to quickly accommodate the frequent updates and to involve more people.
|
8 |
-
|
9 |
-
In August 2013 the library has 1800+ stargazers and support for: composer, PHPUnit tests, PSR standards and a new webpage http://mobiledetect.net
|
10 |
-
|
11 |
-
Mobile Detect library and user contributions are <a href="https://github.com/serbanghita/Mobile-Detect/blob/master/LICENSE.txt">MIT Licensed</a>.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
vendor/mobiledetect/mobiledetectlib/docs/ISSUE_TEMPLATE.md
DELETED
@@ -1,15 +0,0 @@
|
|
1 |
-
-------------delete this message-------------
|
2 |
-
* By submitting a new issue I acknowledge that I already read the README, CODE EXAMPLES and KNOWN LIMITATIONS.
|
3 |
-
* I understand that the current version `2.x` is only meant to detect `mobile` devices.
|
4 |
-
* Please post your User-Agent string! On a real device/s, the library is expected to work correctly.
|
5 |
-
-------------delete this message-------------
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
**Issue description**
|
10 |
-
|
11 |
-
|
12 |
-
**User-Agent(s)**
|
13 |
-
|
14 |
-
|
15 |
-
**Suggestions**
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
vendor/mobiledetect/mobiledetectlib/docs/KNOWN_LIMITATIONS.md
DELETED
@@ -1,12 +0,0 @@
|
|
1 |
-
**Known limitations**
|
2 |
-
|
3 |
-
* Mobile Detect script was designed to detect `mobile` devices. Implicitly other devices are considered to be `desktop`.
|
4 |
-
* User-Agent and HTTP headers sniffing is a non reliable method of detecting a mobile device.
|
5 |
-
* If the mobile browser is set on `Desktop mode`, the Mobile Detect script has no way of knowing that the device is `mobile`.
|
6 |
-
* Some touchscreen devices (eg. Microsoft Surface) are tough to detect as mobile since they can be used in a laptop mode. See: [#32](https://github.com/serbanghita/Mobile-Detect/issues/32), [#461](https://github.com/serbanghita/Mobile-Detect/issues/461), [#667](https://github.com/serbanghita/Mobile-Detect/issues/667)
|
7 |
-
* Some mobile devices (eg. IPadOS, Google Pixel Slate). See: [#795](https://github.com/serbanghita/Mobile-Detect/issues/795), [#788](https://github.com/serbanghita/Mobile-Detect/issues/788)
|
8 |
-
* Detecting the device brand (eg. Apple, Samsung, HTC) is not 100% reliable.
|
9 |
-
* We don't monitor the quality of the 3rd party tools based on Mobile Detect script.
|
10 |
-
We cannot guarantee that they are using the class properly or if they provide the latest version.
|
11 |
-
* Version `2.x` is made to be PHP 5.3 compatible because of the backward compatibility changes of PHP.
|
12 |
-
* There are hundreds of devices launched every month, we cannot keep a 100% up to date detection rate.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
vendor/mobiledetect/mobiledetectlib/export/exportToJSON.php
DELETED
@@ -1,67 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* Mobile Detect Library
|
4 |
-
* - export -
|
5 |
-
* =====================
|
6 |
-
*
|
7 |
-
* Use the resulting JSON export file in other languages
|
8 |
-
* other than PHP. Always check for 'version' key because
|
9 |
-
* new major versions can modify the structure of the JSON file.
|
10 |
-
*
|
11 |
-
* The result of running this script is the export.json file.
|
12 |
-
*
|
13 |
-
* @license Code and contributions have 'MIT License'
|
14 |
-
* More details: https://github.com/serbanghita/Mobile-Detect/blob/master/LICENSE.txt
|
15 |
-
*
|
16 |
-
*/
|
17 |
-
|
18 |
-
// Included nicejson function to beautify the result JSON file.
|
19 |
-
// This library is not mandatory.
|
20 |
-
if( file_exists(dirname(__FILE__).'/nicejson/nicejson.php') ) {
|
21 |
-
include_once dirname(__FILE__).'/nicejson/nicejson.php';
|
22 |
-
}
|
23 |
-
|
24 |
-
// Include Mobile Detect.
|
25 |
-
require_once dirname(__FILE__).'/../Mobile_Detect.php';
|
26 |
-
$detect = new Mobile_Detect;
|
27 |
-
|
28 |
-
$json = array(
|
29 |
-
// The current version of Mobile Detect class that
|
30 |
-
// is being exported.
|
31 |
-
'version' => $detect->getScriptVersion(),
|
32 |
-
|
33 |
-
// All headers that trigger 'isMobile' to be 'true',
|
34 |
-
// before reaching the User-Agent match detection.
|
35 |
-
'headerMatch' => $detect->getMobileHeaders(),
|
36 |
-
|
37 |
-
// All possible User-Agent headers.
|
38 |
-
'uaHttpHeaders' => $detect->getUaHttpHeaders(),
|
39 |
-
|
40 |
-
// All the regexes that trigger 'isMobile' or 'isTablet'
|
41 |
-
// to be true.
|
42 |
-
'uaMatch' => array(
|
43 |
-
// If match is found, triggers 'isMobile' to be true.
|
44 |
-
'phones' => $detect->getPhoneDevices(),
|
45 |
-
// Triggers 'isTablet' to be true.
|
46 |
-
'tablets' => $detect->getTabletDevices(),
|
47 |
-
// If match is found, triggers 'isMobile' to be true.
|
48 |
-
'browsers' => $detect->getBrowsers(),
|
49 |
-
// If match is found, triggers 'isMobile' to be true.
|
50 |
-
'os' => $detect->getOperatingSystems(),
|
51 |
-
// Various utilities. To be further discussed.
|
52 |
-
'utilities' => $detect->getUtilities()
|
53 |
-
)
|
54 |
-
);
|
55 |
-
|
56 |
-
$fileName = dirname(__FILE__).'/../Mobile_Detect.json';
|
57 |
-
// Write the JSON file to disk.11
|
58 |
-
// You can import this file in your app.
|
59 |
-
if (file_put_contents(
|
60 |
-
$fileName,
|
61 |
-
function_exists('json_format') ? json_format($json) : json_encode($json)
|
62 |
-
)) {
|
63 |
-
echo 'Done. Check '.realpath($fileName).' file.';
|
64 |
-
}
|
65 |
-
else {
|
66 |
-
echo 'Failed to write '.realpath($fileName).' to disk.';
|
67 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
vendor/mobiledetect/mobiledetectlib/namespaced/Detection/MobileDetect.php
DELETED
@@ -1,22 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
/**
|
3 |
-
* Little piece of PHP to make Mobile_Detect auto-loadable in PSR-0 compatible PHP autoloaders like
|
4 |
-
* the Symfony Universal ClassLoader by Fabien Potencier. Since PSR-0 handles an underscore in
|
5 |
-
* classnames (on the filesystem) as a slash, "Mobile_Detect.php" autoloaders will try to convert
|
6 |
-
* the classname and path to "Mobile\Detect.php". This script will ensure autoloading with:
|
7 |
-
* - Namespace: Detection
|
8 |
-
* - Classname: MobileDetect
|
9 |
-
* - Namespased: \Detection\MobileDetect
|
10 |
-
* - Autoload path: ./namespaced
|
11 |
-
* - Converted path: ./namespaced/Detection/MobileDetect.php
|
12 |
-
*
|
13 |
-
* Don't forget to use MobileDetect (instead of Mobile_Detect) as class in code when autoloading.
|
14 |
-
*
|
15 |
-
* Thanks to @WietseWind.
|
16 |
-
* For details please check: https://github.com/serbanghita/Mobile-Detect/pull/120
|
17 |
-
*/
|
18 |
-
|
19 |
-
namespace Detection;
|
20 |
-
require_once dirname(__FILE__) . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR . 'Mobile_Detect.php';
|
21 |
-
|
22 |
-
class MobileDetect extends \Mobile_Detect {}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
vendor/mobiledetect/mobiledetectlib/phpcs.xml
DELETED
@@ -1,20 +0,0 @@
|
|
1 |
-
<?xml version="1.0"?>
|
2 |
-
<ruleset name="PSR1">
|
3 |
-
<description>The PSR-2 coding standard extended.</description>
|
4 |
-
<rule ref="PSR1">
|
5 |
-
<exclude name="PSR1.Classes.ClassDeclaration.MissingNamespace"/>
|
6 |
-
</rule>
|
7 |
-
<rule ref="Squiz">
|
8 |
-
<exclude name="Squiz.Classes.ValidClassName.NotCamelCaps"/>
|
9 |
-
<exclude name="Squiz.Files.FileExtension.ClassFound"/>
|
10 |
-
<exclude name="Squiz.Commenting.ClassComment.TagNotAllowed"/>
|
11 |
-
</rule>
|
12 |
-
<rule ref="Squiz.Strings.DoubleQuoteUsage">
|
13 |
-
<type>error</type>
|
14 |
-
</rule>
|
15 |
-
<rule ref="Generic.Files.LineLength">
|
16 |
-
<properties>
|
17 |
-
<property name="lineLimit" value="140"/>
|
18 |
-
</properties>
|
19 |
-
</rule>
|
20 |
-
</ruleset>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|