Comparing version 0.8.47 to 0.8.48
@@ -101,5 +101,5 @@ 'use strict'; | ||
/** | ||
* @desc: 判断参数是否是null,undefined,NaN | ||
* @return: boolean | ||
*/ | ||
* @desc: 判断参数是否是null,undefined,NaN | ||
* @return: boolean | ||
*/ | ||
exports.isNull = utils.isNull; | ||
@@ -109,33 +109,49 @@ | ||
/** | ||
* @desc: 判断是否是ie. | ||
*/ | ||
exports.browserIsIE= | ||
function() { | ||
if (!!window.ActiveXObject || "ActiveXObject" in window) | ||
return true; | ||
else | ||
return false; | ||
} | ||
* @desc: 判断是否是ie. | ||
*/ | ||
exports.browserIsIE = | ||
function () { | ||
if (!!window.ActiveXObject || "ActiveXObject" in window) | ||
return true; | ||
else | ||
return false; | ||
} | ||
/** | ||
* @desc: 判断ie版本号. | ||
* @return number. 非ie返回Number.MAX_SAFE_INTEGER. | ||
*/ | ||
exports.browserIEVer= | ||
function() { | ||
if (!exports.browserIsIE()) return Number.MAX_SAFE_INTEGER; | ||
var b_version = navigator.appVersion | ||
var version = b_version.split(";"); | ||
var trim_Version = version[1].replace(/[ ]/g, ""); | ||
if (!trim_Version || trim_Version.length < 5) { | ||
var userAgent = navigator.userAgent; | ||
userAgent = userAgent.toLowerCase(); | ||
if (userAgent.indexOf('rv:11.') > 0) return 11; | ||
if (userAgent.indexOf('rv:12.') > 0) return 12; | ||
return Number.MAX_SAFE_INTEGER; | ||
* @desc: 判断ie版本号. | ||
* @return number. 非ie返回Number.MAX_SAFE_INTEGER. | ||
* 如果是 edge 返回 'edge' | ||
*/ | ||
exports.browserIEVer = | ||
function () { | ||
if (!exports.browserIsIE()) return Number.MAX_SAFE_INTEGER; | ||
var userAgent = navigator.userAgent; //取得浏览器的userAgent字符串 | ||
var isIE = userAgent.indexOf("compatible") > -1 && userAgent.indexOf("MSIE") > -1; //判断是否IE<11浏览器 | ||
var isEdge = userAgent.indexOf("Edge") > -1 && !isIE; //判断是否IE的Edge浏览器 | ||
var isIE11 = userAgent.indexOf('Trident') > -1 && userAgent.indexOf("rv:11.0") > -1; | ||
if (isIE) { | ||
var reIE = new RegExp("MSIE (\\d+\\.\\d+);"); | ||
reIE.test(userAgent); | ||
var fIEVersion = parseFloat(RegExp["$1"]); | ||
if (fIEVersion == 7) { | ||
return 7; | ||
} else if (fIEVersion == 8) { | ||
return 8; | ||
} else if (fIEVersion == 9) { | ||
return 9; | ||
} else if (fIEVersion == 10) { | ||
return 10; | ||
} else { | ||
return 6; //IE版本<=7 | ||
} | ||
} else if (isEdge) { | ||
return 'edge'; //edge | ||
} else if (isIE11) { | ||
return 11; //IE11 | ||
} else { | ||
Number.MAX_SAFE_INTEGER;; //不是ie浏览器 | ||
} | ||
} | ||
return parseInt(trim_Version[4]); | ||
} | ||
@@ -145,12 +161,9 @@ /** | ||
*/ | ||
exports.browserIsSupportHtml5= | ||
function () { | ||
if (typeof(Worker) !== "undefined") | ||
{ | ||
exports.browserIsSupportHtml5 = | ||
function () { | ||
if (typeof (Worker) !== "undefined") { | ||
return true; | ||
} | ||
else | ||
{ | ||
} else { | ||
return false; | ||
} | ||
} | ||
} | ||
} |
@@ -86,3 +86,3 @@ { | ||
"name": "febs", | ||
"version": "0.8.47" | ||
"version": "0.8.48" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
2484938
25561
4