@hhfenpm/utils 1.0.4 → 1.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.js +6 -1
- package/dist/index.js +6 -1
- package/package.json +1 -1
package/dist/index.esm.js
CHANGED
|
@@ -3052,6 +3052,11 @@ function isTablet() {
|
|
|
3052
3052
|
}
|
|
3053
3053
|
|
|
3054
3054
|
const userAgent = navigator.userAgent.toLowerCase();
|
|
3055
|
+
const isIETabletPC =
|
|
3056
|
+
/trident|msie/i.test(userAgent) && /tablet pc/i.test(userAgent);
|
|
3057
|
+
if (isIETabletPC) {
|
|
3058
|
+
return false
|
|
3059
|
+
}
|
|
3055
3060
|
const tabletPatterns = [
|
|
3056
3061
|
/ipad/,
|
|
3057
3062
|
/android.*tablet/,
|
|
@@ -3061,7 +3066,7 @@ function isTablet() {
|
|
|
3061
3066
|
/bb10/,
|
|
3062
3067
|
/rim tablet/,
|
|
3063
3068
|
/windows.*touch/,
|
|
3064
|
-
/tablet/,
|
|
3069
|
+
/arm.*tablet/,
|
|
3065
3070
|
];
|
|
3066
3071
|
const isTabletByUserAgent = tabletPatterns.some(pattern =>
|
|
3067
3072
|
pattern.test(userAgent)
|
package/dist/index.js
CHANGED
|
@@ -3054,6 +3054,11 @@ function isTablet() {
|
|
|
3054
3054
|
}
|
|
3055
3055
|
|
|
3056
3056
|
const userAgent = navigator.userAgent.toLowerCase();
|
|
3057
|
+
const isIETabletPC =
|
|
3058
|
+
/trident|msie/i.test(userAgent) && /tablet pc/i.test(userAgent);
|
|
3059
|
+
if (isIETabletPC) {
|
|
3060
|
+
return false
|
|
3061
|
+
}
|
|
3057
3062
|
const tabletPatterns = [
|
|
3058
3063
|
/ipad/,
|
|
3059
3064
|
/android.*tablet/,
|
|
@@ -3063,7 +3068,7 @@ function isTablet() {
|
|
|
3063
3068
|
/bb10/,
|
|
3064
3069
|
/rim tablet/,
|
|
3065
3070
|
/windows.*touch/,
|
|
3066
|
-
/tablet/,
|
|
3071
|
+
/arm.*tablet/,
|
|
3067
3072
|
];
|
|
3068
3073
|
const isTabletByUserAgent = tabletPatterns.some(pattern =>
|
|
3069
3074
|
pattern.test(userAgent)
|