feat: Support dark mode in login pages (#7420)

Co-authored-by: Sivin Varghese <64252451+iamsivin@users.noreply.github.com>
This commit is contained in:
Pranav Raj S
2023-07-01 07:49:52 +05:30
committed by GitHub
co-authored by Sivin Varghese
parent 022f4f899f
commit b57063a8b8
57 changed files with 1516 additions and 1483 deletions
+1 -24
View File
@@ -2,12 +2,7 @@ import Vue from 'vue';
import types from '../mutation-types';
import authAPI from '../../api/auth';
import {
setUser,
clearCookiesOnLogout,
clearLocalStorageOnLogout,
} from '../utils/api';
import { getLoginRedirectURL } from '../../helper/URLHelper';
import { setUser, clearCookiesOnLogout } from '../utils/api';
const initialState = {
currentUser: {
@@ -97,24 +92,6 @@ export const getters = {
// actions
export const actions = {
login(_, { ssoAccountId, ssoConversationId, ...credentials }) {
return new Promise((resolve, reject) => {
authAPI
.login(credentials)
.then(response => {
clearLocalStorageOnLogout();
window.location = getLoginRedirectURL({
ssoAccountId,
ssoConversationId,
user: response.data,
});
resolve();
})
.catch(error => {
reject(error);
});
});
},
async validityCheck(context) {
try {
const response = await authAPI.validityCheck();