debian-mirror-gitlab/app/assets/javascripts/pages/sessions/new/index.js

25 lines
1 KiB
JavaScript
Raw Normal View History

2018-05-09 12:01:36 +05:30
import $ from 'jquery';
2021-09-30 23:02:18 +05:30
import initVueAlerts from '~/vue_alerts';
2019-07-07 11:18:12 +05:30
import NoEmojiValidator from '../../../emoji/no_emoji_validator';
2021-03-11 19:13:27 +05:30
import LengthValidator from './length_validator';
2018-03-17 18:26:18 +05:30
import OAuthRememberMe from './oauth_remember_me';
2019-03-02 22:35:43 +05:30
import preserveUrlFragment from './preserve_url_fragment';
2021-03-11 19:13:27 +05:30
import SigninTabsMemoizer from './signin_tabs_memoizer';
import UsernameValidator from './username_validator';
2018-03-17 18:26:18 +05:30
document.addEventListener('DOMContentLoaded', () => {
new UsernameValidator(); // eslint-disable-line no-new
2019-09-30 21:07:59 +05:30
new LengthValidator(); // eslint-disable-line no-new
2018-03-17 18:26:18 +05:30
new SigninTabsMemoizer(); // eslint-disable-line no-new
2019-07-07 11:18:12 +05:30
new NoEmojiValidator(); // eslint-disable-line no-new
2018-11-08 19:23:39 +05:30
new OAuthRememberMe({
2018-03-17 18:26:18 +05:30
container: $('.omniauth-container'),
}).bindEvents();
2019-03-02 22:35:43 +05:30
// Save the URL fragment from the current window location. This will be present if the user was
// redirected to sign-in after attempting to access a protected URL that included a fragment.
preserveUrlFragment(window.location.hash);
2021-09-30 23:02:18 +05:30
initVueAlerts();
2018-03-17 18:26:18 +05:30
});