Files
lan-manager/web/node_modules/@antv/g6-pc/es/util/browser.js
openclaw 0a5f6a8047 Initial commit: Lan-manager project code
- Go backend (server/)
- Frontend (web/, server/static/)
- Database and deployment files
- Scripts and docs

Co-Authored-By: 狸花猫/Claude-Qwen3.6-Plus 🐾
2026-04-20 00:52:58 +08:00

14 lines
526 B
JavaScript

/**
* Get current browser name.
* @returns browser name
*/
export var getBrowserName = function getBrowserName() {
var userAgent = navigator.userAgent.toLowerCase();
if (userAgent.indexOf('firefox') > -1) return 'firefox';
if (userAgent.indexOf('safari') > -1) return 'safari';
if (userAgent.indexOf('opr') > -1) return 'opera';
if (userAgent.indexOf('chrome') > -1) return 'chrome';
if (userAgent.indexOf('trident') > -1) return 'ie 11';
if (userAgent.indexOf('ie') > -1) return 'ie';
return 'unknown';
};