Skip to content

Commit

Permalink
Bump version 0.7.39
Browse files Browse the repository at this point in the history
  • Loading branch information
faisalman committed Sep 11, 2024
1 parent c25e22f commit 2ad60d4
Show file tree
Hide file tree
Showing 10 changed files with 58 additions and 41 deletions.
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ua-parser-js",
"version": "0.7.38",
"version": "0.7.39",
"authors": [
"Faisal Salman <f@faisalman.com>"
],
Expand Down
8 changes: 8 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,14 @@

Version 1.0.x is basically the equivalent of version 0.7.x. See [#536](https://github.com/faisalman/ua-parser-js/issues/536) for the reason behind this confusion.

## Version 0.7.39 / 1.0.39
- Add new feature: executable command using `npx ua-parser-js "[INSERT-UA-HERE]"`
- Add new browser: Helio, Pico Browser, Wolvic
- Add new device vendor: itel, Nothing, TCL
- Improve browser detection: ICEBrowser, Klar, QQBrowser, Quark, Rekonq, Sleipnir
- Improve device detection: Xiaomi Pro, Amazon Echo Show, Samsung Galaxy Watch
- Removed from browser: Viera

## Version 0.7.38 / 1.0.38
- Fix error on getOS() when userAgentData.platform is undefined
- Add new browser: Opera GX, Twitter
Expand Down
4 changes: 2 additions & 2 deletions dist/ua-parser.min.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dist/ua-parser.pack.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion license.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2012-2023 Faisal Salman <<f@faisalman.com>>
Copyright (c) 2012-2024 Faisal Salman <<f@faisalman.com>>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
2 changes: 1 addition & 1 deletion package.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package.describe({
name: 'faisalman:ua-parser-js',
version: '0.7.38',
version: '0.7.39',
summary: 'Lightweight JavaScript-based user-agent string parser',
git: 'https://github.com/faisalman/ua-parser-js.git',
documentation: 'readme.md'
Expand Down
26 changes: 12 additions & 14 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,29 +1,27 @@
{
"title": "UAParser.js",
"name": "ua-parser-js",
"version": "0.7.38",
"version": "0.7.39",
"author": "Faisal Salman <f@faisalman.com> (http://faisalman.com)",
"description": "Detect Browser, Engine, OS, CPU, and Device type/model from User-Agent data. Supports browser & node.js environment",
"keywords": [
"ua-parser-js",
"user-agent",
"parser",
"browser",
"engine",
"os",
"device",
"mobile",
"cpu",
"jquery-plugin",
"ecosystem:jquery",
"ua-parser-js",
"client-hints",
"user-agent-detection",
"device-detection",
"platform-detection",
"mobile-detection",
"browser-detection",
"architecture-detection"
"platform",
"detect",
"javascript",
"jquery",
"typescript",
"node-js",
"client-hints"
],
"homepage": "https://github.com/faisalman/ua-parser-js",
"homepage": "https://uaparser.dev",
"contributors": [
"Aamir Poonawalla <aamir@urx.com>",
"Admas <mollases@users.noreply.github.com>",
Expand Down Expand Up @@ -196,7 +194,7 @@
"test": "test"
},
"bugs": "https://github.com/faisalman/ua-parser-js/issues",
"demo": "https://faisalman.github.io/ua-parser-js",
"demo": "https://uaparser.dev",
"download": "https://raw.github.com/faisalman/ua-parser-js/master/dist/ua-parser.min.js",
"funding": [
{
Expand Down
38 changes: 24 additions & 14 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
JavaScript library to detect Browser, Engine, OS, CPU, and Device type/model from User-Agent data with relatively small footprint (~17KB minified, ~6KB gzipped) that can be used either in browser (client-side) or node.js (server-side).

* Author : Faisal Salman <<f@faisalman.com>>
* Demo : https://faisalman.github.io/ua-parser-js
* Demo : https://uaparser.dev
* Source : https://github.com/faisalman/ua-parser-js
* Documentation :
* v1 : https://github.com/faisalman/ua-parser-js/tree/1.0.35#documentation
* v2 : https://faisalman.github.io/ua-parser-js-docs/v2
* v1 : https://github.com/faisalman/ua-parser-js/tree/1.0.39#documentation
* v2 : https://docs.uaparser.dev

***

Expand All @@ -36,6 +36,8 @@ JavaScript library to detect Browser, Engine, OS, CPU, and Device type/model fro
</tbody>
</table>

<a href="https://uaparser.dev"><img src="https://raw.githubusercontent.com/faisalman/ua-parser-js/gh-pages/images/uap-header.png"></a>

---

# Documentation
Expand Down Expand Up @@ -102,19 +104,19 @@ The methods are self explanatory, here's a small overview on all the available m
AVG, Baidu, Basilisk, Blazer, Bolt, Brave, Bowser, Camino, Chimera,
Chrome Headless, Chrome WebView, Chrome, Chromium, Cobalt, Comodo Dragon, Dillo,
Dolphin, Doris, DuckDuckGo, Edge, Electron, Epiphany, Facebook, Falkon, Fennec,
Firebird, Firefox [Focus/Reality], Flock, Flow, GSA, GoBrowser, Heytap,
Firebird, Firefox [Focus/Reality], Flock, Flow, GSA, GoBrowser, Helio, Heytap,
Huawei Browser, iCab, ICE Browser, IE, IEMobile, IceApe, IceCat, IceDragon,
Iceweasel, Instagram, Iridium, Iron, Jasmine, Kakao[Story/Talk], K-Meleon,
Kindle, Klar, Klarna, Konqueror, LBBROWSER, Line, LinkedIn, Links, Lunascape,
Lynx, MIUI Browser, Maemo, Maxthon, Midori, Minimo, Mobile Safari, Mosaic,
Mozilla, NetFront, NetSurf, Netfront, Netscape, NokiaBrowser, Obigo,
Oculus Browser, OmniWeb, Opera Coast, Opera [GX/Mini/Mobi/Tablet], PaleMoon,
PhantomJS, Phoenix, Polaris, Puffin, QQ, QQBrowser, QQBrowserLite, Quark,
QupZilla, RockMelt, Safari, Sailfish Browser, Samsung Internet, SeaMonkey, Silk,
Skyfire, Sleipnir, Slim, SlimBrowser, Smart Lenovo Browser, Snapchat,
PhantomJS, Phoenix, Pico Browser, Polaris, Puffin, QQ, QQBrowser, QQBrowserLite,
Quark, QupZilla, RockMelt, Safari, Sailfish Browser, Samsung Internet, SeaMonkey,
Silk, Skyfire, Sleipnir, Slim, SlimBrowser, Smart Lenovo Browser, Snapchat,
Sogou [Explorer/Mobile], Swiftfox, Tesla, TikTok, Tizen Browser, Twitter,
UCBrowser, UP.Browser, Viera, Vivaldi, Vivo Browser, Waterfox, WeChat, Weibo,
Yandex, w3m, Whale Browser, ...
UCBrowser, UP.Browser, Vivaldi, Vivo Browser, w3m, Waterfox, WeChat, Weibo,
Whale Browser, Wolvic, Yandex, ...

# 'browser.version' determined dynamically
```
Expand All @@ -136,10 +138,10 @@ console, mobile, tablet, smarttv, wearable, embedded
# Possible 'device.vendor':
Acer, Alcatel, Amazon, Apple, Archos, ASUS, AT&T, BenQ, BlackBerry, Dell,
Essential, Facebook, Fairphone, GeeksPhone, Google, HP, HTC, Huawei, Infinix,
Jolla, Kobo, Lenovo, LG, Meizu, Microsoft, Motorola, Nexian, Nintendo, Nokia,
Nvidia, OnePlus, OPPO, Ouya, Palm, Panasonic, Pebble, Polytron, Realme, RIM,
Roku, Samsung, Sharp, Siemens, Sony[Ericsson], Sprint, Tecno, Tesla, Ulefone,
Vivo, Vodafone, Xbox, Xiaomi, Zebra, ZTE, ...
itel, Jolla, Kobo, Lenovo, LG, Meizu, Microsoft, Motorola, Nexian, Nintendo,
Nokia, Nothing, Nvidia, OnePlus, OPPO, Ouya, Palm, Panasonic, Pebble, Polytron,
Realme, RIM, Roku, Samsung, Sharp, Siemens, Sony[Ericsson], Sprint, TCL, Tecno,
Tesla, Ulefone, Vivo, Vodafone, Xbox, Xiaomi, Zebra, ZTE, ...

# 'device.model' determined dynamically
```
Expand Down Expand Up @@ -321,6 +323,14 @@ console.log(parseInt($.ua.browser.version.split('.')[0], 10)); // 4
$('body').addClass('ua-browser-' + $.ua.browser.name + ' ua-devicetype-' + $.ua.device.type);
```

## Using npx

UAParser.js can be executed as a command that returns the parsed data in JSON format:

```sh
$ npx ua-parser-js "[INSERT-UA-HERE]"
```

## Using Extension

* `UAParser([uastring,] extensions)`
Expand Down Expand Up @@ -364,7 +374,7 @@ Made with [contributors-img](https://contrib.rocks).

MIT License

Copyright (c) 2012-2021 Faisal Salman <<f@faisalman.com>>
Copyright (c) 2012-2024 Faisal Salman <<f@faisalman.com>>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
9 changes: 5 additions & 4 deletions src/ua-parser.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////////
/* UAParser.js v0.7.38
/* UAParser.js v0.7.39
Copyright © 2012-2021 Faisal Salman <f@faisalman.com>
MIT License *//*
Detect Browser, Engine, OS, CPU, and Device type/model from User-Agent data.
Expand All @@ -17,7 +17,7 @@
/////////////


var LIBVERSION = '0.7.38',
var LIBVERSION = '0.7.39',
EMPTY = '',
UNKNOWN = '?',
FUNC_TYPE = 'function',
Expand Down Expand Up @@ -60,7 +60,8 @@
ZEBRA = 'Zebra',
FACEBOOK = 'Facebook',
CHROMIUM_OS = 'Chromium OS',
MAC_OS = 'Mac OS';
MAC_OS = 'Mac OS',
SUFFIX_BROWSER = ' Browser';

///////////
// Helper
Expand Down Expand Up @@ -171,7 +172,7 @@
return (i === UNKNOWN) ? undefined : i;
}
}
return str;
return map.hasOwnProperty('*') ? map['*'] : str;
};

///////////////
Expand Down
4 changes: 2 additions & 2 deletions test/browser-test.json
Original file line number Diff line number Diff line change
Expand Up @@ -913,7 +913,7 @@
"ua" : "Mozilla/5.0 (X11; Linux x86_64; Pico Neo3 Link OS5.8.4.0 like Quest) AppleWebKit/537.36 (KHTML, like Gecko) PicoBrowser/3.3.22 Chrome/105.0.5195.68 VR Safari/537.36",
"expect" :
{
"name" : "PicoBrowser",
"name" : "Pico Browser",
"version" : "3.3.22",
"major" : "3"
}
Expand All @@ -923,7 +923,7 @@
"ua" : "Mozilla/5.0 (X11; Linux x86_64; PICO 4 OS5.4.0 like Quest) AppleWebKit/537.36 (KHTML, like Gecko) PicoBrowser/3.3.22 Chrome/105.0.5195.68 VR Safari/537.36 OculusBrowser/7.0",
"expect" :
{
"name" : "PicoBrowser",
"name" : "Pico Browser",
"version" : "3.3.22",
"major" : "3"
}
Expand Down

0 comments on commit 2ad60d4

Please sign in to comment.