JS
CSS
signInWidget = new OktaSignIn({ // Caution editing this section as you may break the demo. baseUrl: 'https://oktaprise.okta.com', clientId: '0oa1e1p5vi7Jm2nif1d8', redirectUri: 'https://widget.oktaprise.com:443/oauth2/callback', authParams: { issuer: 'https://oktaprise.okta.com/oauth2/aus1e1p1bmlFOMlLc1d8', responseType: ['id_token', 'token'], scopes: ['openid', 'email', 'profile'], }, // Enable or disable widget functionality with the following options. Some of these features require additional configuration in your Okta admin settings. Detailed information can be found here: https://github.com/okta/okta-signin-widget#okta-sign-in-widget features: { router: true, // Leave this set to true for the API demo registration: true, // Enable self-service registration flow rememberMe: true, // Setting to false will remove the checkbox to save username //multiOptionalFactorEnroll: true, // Allow users to enroll in multiple optional factors before finishing the authentication flow. //selfServiceUnlock: true, // Will enable unlock in addition to forgotten password //smsRecovery: true, // Enable SMS-based account recovery //callRecovery: true, // Enable voice call-based account recovery }, // Look and feel changes logo: 'static/img/gear_half.png', // This demo includes other logos. Try: [logo_widgico.png, gear_logo.png, gear_half.png] language: 'en', // Try: [fr, de, es, ja, zh-CN] Full list: https://github.com/okta/okta-signin-widget#language-and-text i18n: { //Overrides default text when using English. Override other languages by adding additional sections. 'en': { 'primaryauth.title': 'Sign In', // Changes the sign in text 'primaryauth.submit': 'Sign In', // Changes the sign in button //'primaryauth.username.tooltip': 'Enter your APIDemo ID', // Changes the tooltip for username //'primaryauth.password.tooltip': 'Your APIDemo Password', // Changes the tooltip for password // More e.g. [primaryauth.username.placeholder, primaryauth.password.placeholder, needhelp, etc.]. Full list here: https://github.com/okta/okta-signin-widget/blob/master/packages/@okta/i18n/dist/properties/login.properties } }, }); function widgetSuccessCallback(res) { var key = ''; if (res[0]) { key = Object.keys(res[0])[0]; oktaSignIn.tokenManager.add(key, res[0]); } if (res[1]) { key = Object.keys(res[1])[0]; oktaSignIn.tokenManager.add(key, res[1]); } if (res.status === 'SUCCESS') { get_profile(key, oktaSignIn.tokenManager.get(key)); } } function widgetErrorCallback (err) { } signInWidget.renderEl({el: '#widget-container'}, widgetSuccessCallback, widgetErrorCallback);
#okta-sign-in.auth-container.main-container { /* -- Fonts and Text Colors -- */ font-family: "montserrat", Arial, Helvetica, sans-serif; color: #777; } #okta-sign-in.auth-container h2, #okta-sign-in.auth-container h3 { /* -- Fonts and Text Colors -- */ font-weight: bold; color: #5e5e5e; }