mirror of
https://github.com/lancedikson/bowser
synced 2024-10-27 20:34:22 +00:00
Vivaldi pass tests.
This commit is contained in:
parent
3f42b985d0
commit
bef1c560d9
@ -32,6 +32,7 @@ if (bowser.msie && bowser.version <= 6) {
|
||||
* Bada browser as `bada`[`webkit`]
|
||||
* Tizen browser as `tizen`[`webkit`]
|
||||
* Sailfish browser as `sailfish`[`gecko`]
|
||||
* Vivaldi browser as `vivaldi`[`webkit`]
|
||||
|
||||
For all detected browsers the browser version is set in the `version` field.
|
||||
|
||||
|
@ -65,14 +65,23 @@
|
||||
, msie: t
|
||||
, version: getFirstMatch(/(?:msie |rv:)(\d+(\.\d+)?)/i)
|
||||
}
|
||||
} else if (chromeBook) {
|
||||
}
|
||||
else if (/vivaldi/i.test(ua)) {
|
||||
result = {
|
||||
name: 'Vivaldi'
|
||||
, vivaldi: t
|
||||
, version: getFirstMatch(/vivaldi\/(\d+(\.\d+)?)/i) || versionIdentifier
|
||||
}
|
||||
}
|
||||
else if (chromeBook) {
|
||||
result = {
|
||||
name: 'Chrome'
|
||||
, chromeBook: t
|
||||
, chrome: t
|
||||
, version: getFirstMatch(/(?:chrome|crios|crmo)\/(\d+(\.\d+)?)/i)
|
||||
}
|
||||
} else if (/chrome.+? edge/i.test(ua)) {
|
||||
}
|
||||
else if (/chrome.+? edge/i.test(ua)) {
|
||||
result = {
|
||||
name: 'Microsoft Edge'
|
||||
, msedge: t
|
||||
@ -175,13 +184,6 @@
|
||||
, version: versionIdentifier
|
||||
}
|
||||
}
|
||||
else if (/vivaldi/i.test(ua)) {
|
||||
result = {
|
||||
name: 'Vivaldi'
|
||||
, vivaldi: t
|
||||
, version: versionIdentifier
|
||||
}
|
||||
}
|
||||
else {
|
||||
result = {
|
||||
name: getFirstMatch(/^(.*)\/(.*) /),
|
||||
@ -248,6 +250,7 @@
|
||||
(result.chrome && result.version >= 20) ||
|
||||
(result.firefox && result.version >= 20.0) ||
|
||||
(result.safari && result.version >= 6) ||
|
||||
(result.vivaldi && result.version >= 1) ||
|
||||
(result.opera && result.version >= 10.0) ||
|
||||
(result.ios && result.osversion && result.osversion.split(".")[0] >= 6) ||
|
||||
(result.blackberry && result.version >= 10.1)
|
||||
|
@ -965,17 +965,17 @@ module.exports.useragents = {
|
||||
}
|
||||
}
|
||||
, Vivaldi: {
|
||||
'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.75 Safari/537.36 Vivaldi/1.0.219.53': {
|
||||
vivaldi: true
|
||||
, webkit: true
|
||||
, version: '1.0'
|
||||
, a: true
|
||||
'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2454.99 Safari/537.36 Vivaldi/1.0.303.52': {
|
||||
vivaldi: true,
|
||||
version: '1.0',
|
||||
webkit: true,
|
||||
a: true
|
||||
},
|
||||
'Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.75 Safari/537.36 Vivaldi/1.0.219.50': {
|
||||
vivaldi: true
|
||||
, webkit: true
|
||||
, version: '1.0'
|
||||
, a: true
|
||||
'Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2454.99 Safari/537.36 Vivaldi/1.0.303.52': {
|
||||
vivaldi: true,
|
||||
version: '1.0',
|
||||
webkit: true,
|
||||
a: true
|
||||
}
|
||||
}
|
||||
, Generic: {
|
||||
|
Loading…
Reference in New Issue
Block a user