mirror of
https://github.com/faisalman/ua-parser-js.git
synced 2025-09-27 16:08:47 +03:00
Backport - Improve browser detection: rename "Samsung Browser" to "Samsung Internet" (cherry picked from commit 5c10e2b1070abb48f4549827533877f88139df93)
https://developer.samsung.com/internet/user-agent-string-format.html
This commit is contained in:
parent
02af42fcf0
commit
e3d5f7649d
@ -273,8 +273,10 @@
|
||||
], [VERSION, [NAME, FIREFOX]], [
|
||||
/\bqihu|(qi?ho?o?|360)browser/i // 360
|
||||
], [[NAME, '360 ' + BROWSER]], [
|
||||
/(oculus|samsung|sailfish|huawei|vivo)browser\/([\w\.]+)/i
|
||||
], [[NAME, /(.+)/, '$1 ' + BROWSER], VERSION], [ // Oculus/Samsung/Sailfish/HuaweiBrowser/VivoBrowser
|
||||
/(oculus|sailfish|huawei|vivo)browser\/([\w\.]+)/i
|
||||
], [[NAME, /(.+)/, '$1 ' + BROWSER], VERSION], [ // Oculus/Sailfish/HuaweiBrowser/VivoBrowser
|
||||
/samsungbrowser\/([\w\.]+)/i // Samsung Internet
|
||||
], [VERSION, [NAME, SAMSUNG + ' Internet']], [
|
||||
/(comodo_dragon)\/([\w\.]+)/i // Comodo Dragon
|
||||
], [[NAME, /_/g, ' '], VERSION], [
|
||||
/metasr[\/ ]?([\d\.]+)/i // Sogou Explorer
|
||||
|
@ -84,7 +84,7 @@
|
||||
"ua" : "Mozilla/5.0 (Linux; Android 5.0.2; SAMSUNG SM-G925F Build/LRX22G) AppleWebKit/537.36 (KHTML, like Gecko) SamsungBrowser/3.0 Chrome/38.0.2125.102 Mobile Safari/537.36",
|
||||
"expect" :
|
||||
{
|
||||
"name" : "Samsung Browser",
|
||||
"name" : "Samsung Internet",
|
||||
"version" : "3.0",
|
||||
"major" : "3"
|
||||
}
|
||||
@ -1169,11 +1169,41 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"desc" : "Samsung Browser",
|
||||
"desc" : "Samsung Internet for Android",
|
||||
"ua" : "Mozilla/5.0 (Linux; Android 6.0.1; SAMSUNG-SM-G925A Build/MMB29K) AppleWebKit/537.36 (KHTML, like Gecko) SamsungBrowser/4.0 Chrome/44.0.2403.133 Mobile Safari/537.36",
|
||||
"expect" :
|
||||
{
|
||||
"name" : "Samsung Browser",
|
||||
"name" : "Samsung Internet",
|
||||
"version" : "4.0",
|
||||
"major" : "4"
|
||||
}
|
||||
},
|
||||
{
|
||||
"desc" : "Samsung Internet for Tizen Mobile",
|
||||
"ua" : "Mozilla/5.0 (Linux; Tizen 2.3; SAMSUNG SM-Z130H) AppleWebKit/537.3 (KHTML, like Gecko) SamsungBrowser/1.0 Mobile Safari/537.3",
|
||||
"expect" :
|
||||
{
|
||||
"name" : "Samsung Internet",
|
||||
"version" : "1.0",
|
||||
"major" : "1"
|
||||
}
|
||||
},
|
||||
{
|
||||
"desc" : "Samsung Internet for Smart-TV",
|
||||
"ua" : "Mozilla/5.0 (SMART-TV; Linux; Tizen 2.3) AppleWebkit/538.1 (KHTML, like Gecko) SamsungBrowser/1.0 TV Safari/538.1",
|
||||
"expect" :
|
||||
{
|
||||
"name" : "Samsung Internet",
|
||||
"version" : "1.0",
|
||||
"major" : "1"
|
||||
}
|
||||
},
|
||||
{
|
||||
"desc" : "Samsung Internet for Gear VR",
|
||||
"ua" : "Mozilla/5.0 (Linux; Android 5.0.2; SAMSUNG SM-G925K Build/LRX22G) AppleWebKit/537.36 (KHTML, like Gecko) SamsungBrowser/4.0 Chrome/44.0.2403.133 Mobile VR Safari/537.36",
|
||||
"expect" :
|
||||
{
|
||||
"name" : "Samsung Internet",
|
||||
"version" : "4.0",
|
||||
"major" : "4"
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user