mirror of
https://github.com/gristlabs/grist-core.git
synced 2026-03-02 04:09:24 +00:00
(core) Add new Grist login page
Summary: Adds a new Grist login page to the login app, and replaces the server-side Cognito Google Sign-In flow with Google's own OAuth flow. Test Plan: Browser and server tests. Reviewers: jarek Reviewed By: jarek Differential Revision: https://phab.getgrist.com/D3332
This commit is contained in:
@@ -2,7 +2,6 @@ import {ApiError} from 'app/common/ApiError';
|
||||
import {BrowserSettings} from 'app/common/BrowserSettings';
|
||||
import {ErrorWithCode} from 'app/common/ErrorWithCode';
|
||||
import {UserProfile} from 'app/common/LoginSessionAPI';
|
||||
import {getLoginState, LoginState} from 'app/common/LoginState';
|
||||
import {ANONYMOUS_USER_EMAIL} from 'app/common/UserAPI';
|
||||
import {User} from 'app/gen-server/entity/User';
|
||||
import {HomeDBManager} from 'app/gen-server/lib/HomeDBManager';
|
||||
@@ -75,7 +74,6 @@ export class Client {
|
||||
private _destroyTimer: NodeJS.Timer|null = null;
|
||||
private _destroyed: boolean = false;
|
||||
private _websocket: any;
|
||||
private _loginState: LoginState|null = null;
|
||||
private _org: string|null = null;
|
||||
private _profile: UserProfile|null = null;
|
||||
private _userId: number|null = null;
|
||||
@@ -95,9 +93,6 @@ export class Client {
|
||||
|
||||
public toString() { return `Client ${this.clientId} #${this._counter}`; }
|
||||
|
||||
// Returns the LoginState object that's encoded and passed via login pages to login-connect.
|
||||
public getLoginState(): LoginState|null { return this._loginState; }
|
||||
|
||||
public setCounter(counter: string) {
|
||||
this._counter = counter;
|
||||
}
|
||||
@@ -112,8 +107,6 @@ export class Client {
|
||||
|
||||
public setConnection(websocket: any, reqHost: string, browserSettings: BrowserSettings) {
|
||||
this._websocket = websocket;
|
||||
// Set this._loginState, used by CognitoClient to construct login/logout URLs.
|
||||
this._loginState = getLoginState(reqHost);
|
||||
this.browserSettings = browserSettings;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user