mirror of
https://github.com/faisalman/ua-parser-js.git
synced 2025-09-27 16:08:47 +03:00
Merge pull request #383 from 8thwall/huaweiDevices
Detect Huawei P20, P20 Lite and P30 Pro
This commit is contained in:
commit
44d4ed5350
@ -481,7 +481,7 @@
|
||||
], [MODEL, [VENDOR, 'HTC'], [TYPE, TABLET]], [
|
||||
|
||||
/d\/huawei([\w\s-]+)[;\)]/i,
|
||||
/(nexus\s6p)/i // Huawei
|
||||
/(nexus\s6p|vog-l29|ane-lx1|eml-l29)/i // Huawei
|
||||
], [MODEL, [VENDOR, 'Huawei'], [TYPE, MOBILE]], [
|
||||
|
||||
/(microsoft);\s(lumia[\s\w]+)/i // Microsoft Lumia
|
||||
|
@ -1041,5 +1041,32 @@
|
||||
"model": "MI PAD 2",
|
||||
"type": "tablet"
|
||||
}
|
||||
},
|
||||
{
|
||||
"desc": "Huawei P30 Pro",
|
||||
"ua": "Mozilla/5.0 (Linux; Android 9; VOG-L29) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.143 Mobile Safari/537.36",
|
||||
"expect": {
|
||||
"vendor": "Huawei",
|
||||
"model": "VOG-L29",
|
||||
"type": "mobile"
|
||||
}
|
||||
},
|
||||
{
|
||||
"desc": "Huawei P20 Lite",
|
||||
"ua": "Mozilla/5.0 (Linux; Android 8.0.0; ANE-LX1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.143 Mobile Safari/537.36",
|
||||
"expect": {
|
||||
"vendor": "Huawei",
|
||||
"model": "ANE-LX1",
|
||||
"type": "mobile"
|
||||
}
|
||||
},
|
||||
{
|
||||
"desc": "Huawei P20",
|
||||
"ua": "Mozilla/5.0 (Linux; Android 8.1.0; EML-L29) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/74.0.3729.157 Mobile Safari/537.36",
|
||||
"expect": {
|
||||
"vendor": "Huawei",
|
||||
"model": "EML-L29",
|
||||
"type": "mobile"
|
||||
}
|
||||
}
|
||||
]
|
||||
|
Loading…
x
Reference in New Issue
Block a user