How to use the bowser.name function in bowser

To help you get started, we’ve selected a few bowser examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github ali-sdk / ali-oss / lib / client.js View on Github external
proto.checkBrowserAndVersion = function checkBrowserAndVersion(name, version) {
  return ((bowser.name === name) && (bowser.version.split('.')[0] === version));
};
github ali-sdk / ali-oss / lib / browser / client.js View on Github external
proto.checkBrowserAndVersion = function checkBrowserAndVersion(name, version) {
  return ((bowser.name === name) && (bowser.version.split('.')[0] === version));
};
github flutter-webrtc / flutter-webrtc-server / src / Signaling.js View on Github external
this.socket.onopen = () => {
            console.log("wss connect success...");
            this.self_id = this.getRandomUserId();
            let message = {
                type: 'new',
                user_agent: browser.name + '/' + browser.version,
                name: this.name,
                id: this.self_id,
            }
            this.send(message);
            this.wsKeepaliveTimeoutId = setInterval(this.keepAlive, 12000);
        };
github OneSignal / OneSignal-Website-SDK / src / OneSignal.ts View on Github external
*/
    PERMISSION_PROMPT_DISPLAYED: 'permissionPromptDisplay',
    /**
     * For internal testing only. Used for all sorts of things.
     */
    TEST_INIT_OPTION_DISABLED: 'testInitOptionDisabled',
    TEST_WOULD_DISPLAY: 'testWouldDisplay',
    POPUP_WINDOW_TIMEOUT: 'popupWindowTimeout',
  };
}

LegacyManager.ensureBackwardsCompatibility(OneSignal);

Log.info(`%cOneSignal Web SDK loaded (version ${OneSignal._VERSION}, ${SdkEnvironment.getWindowEnv().toString()} environment).`, getConsoleStyle('bold'));
Log.debug(`Current Page URL: ${typeof location === "undefined" ? "NodeJS" : location.href}`);
Log.debug(`Browser Environment: ${bowser.name} ${bowser.version}`);
github opentripplanner / otp-react-redux / lib / components / narrative / trip-tools.js View on Github external
_onClick = () => {
    const { mailto, subject } = this.props

    const bodyLines = [
      '                       *** INSTRUCTIONS TO USER ***',
      'This feature allows you to email a report to site administrators for review.',
      `Please add any additional feedback for this trip under the 'Additional Comments'`,
      'section below and send using your regular email program.',
      '',
      'SEARCH DATA:',
      'Address: ' + window.location.href,
      'Browser: ' + bowser.name + ' ' + bowser.version,
      'OS: ' + bowser.osname + ' ' + bowser.osversion,
      '',
      'ADDITIONAL COMMENTS:',
      ''
    ]

    window.open(`mailto:${mailto}?subject=${subject}&body=${encodeURIComponent(bodyLines.join('\n'))}`, '_self')
  }
github micromaomao / schsrch / view / schsrch.jsx View on Github external
aState.view !==  'home' || aState.querying || aState.showHelp ? (
              
            ) : (
              
            )
          ) : null}
          {!this.state.server && !AppState.supportSspdfView && AppState.supportOverall ? (
            <div>
              Sorry, but your browser - {bowser.name} {bowser.version} is too old and paper preview won't work. You will get a PDF once you click on a paper.
              <div>
                You should really consider upgrading your browser.
              </div>
            </div>
          ) : null}
          <div>
            {view}
          </div>
        
        {this.state.server ? null : }
        {this.renderSidebar()}
        {this.renderV2ViewingPopup()}
      
    )
  }
  handleBlackCoverDown (evt) {
github likeastore / app / public / js / services / utils.js View on Github external
addGlobals: function () {
				$rootScope.browser = {
					name: bowser.name.toLowerCase(),
					version: bowser.version
				};

				$rootScope.extension = extension[bowser.name.toLowerCase()];

				$rootScope.switchMenu = function (url) {
					$location.url(url);
				};

				$rootScope.createFirstCollection = function () {
					$document.find('body').addClass('sidebar-active');
					$rootScope.showAddForm = true;
				};

				$rootScope.showConfigTab = true;
				$rootScope.toggleConfig = function () {
github OneSignal / OneSignal-Website-SDK / src / OneSignal.ts View on Github external
*/
    PERMISSION_PROMPT_DISPLAYED: 'permissionPromptDisplay',
    /**
     * For internal testing only. Used for all sorts of things.
     */
    TEST_INIT_OPTION_DISABLED: 'testInitOptionDisabled',
    TEST_WOULD_DISPLAY: 'testWouldDisplay',
    POPUP_WINDOW_TIMEOUT: 'popupWindowTimeout',
  };
}

LegacyManager.ensureBackwardsCompatibility(OneSignal);

Log.info(`%cOneSignal Web SDK loaded (version ${OneSignal._VERSION}, ${SdkEnvironment.getWindowEnv().toString()} environment).`, getConsoleStyle('bold'));
Log.debug(`Current Page URL: ${typeof location === "undefined" ? "NodeJS" : location.href}`);
Log.debug(`Browser Environment: ${bowser.name} ${bowser.version}`);
github eface2face / rtcninja.js / lib / Adapter.js View on Github external
return function () {
			throw new Error('rtcninja: WebRTC not supported, missing ' + item +
			' [browser: ' + browser.name + ' ' + browser.version + ']');
		};
	}
github AGProjects / sylkserver / resources / html / webrtcgateway / js / sylkrtc.js View on Github external
Adapter.getUserMedia = function (constraints, successCallback, errorCallback) {
			debugerror('getUserMedia() | WebRTC not supported');
			if (errorCallback) {
				errorCallback(new Error('rtcninja: WebRTC not supported, missing ' +
				'getUserMedia [browser: ' + browser.name + ' ' + browser.version + ']'));
			} else {
				throwNonSupported('getUserMedia');
			}
		};
	}