-
-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Update the frontend to support the new intermediate OAuth login…
… step
- Loading branch information
1 parent
a58b9f5
commit 09a4ac8
Showing
6 changed files
with
97 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
23 changes: 23 additions & 0 deletions
23
src/aux-server/aux-web/aux-auth/site/OAuthRedirect/OAuthRedirect.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import { EventBus } from '@casual-simulation/aux-components'; | ||
import Vue from 'vue'; | ||
import Component from 'vue-class-component'; | ||
import { Prop, Provide, Watch } from 'vue-property-decorator'; | ||
import { authManager } from '../../shared/index'; | ||
|
||
@Component({ | ||
components: {}, | ||
}) | ||
export default class OAuthRedirect extends Vue { | ||
async mounted() { | ||
const url = new URL(window.location.href); | ||
let params: any = {}; | ||
for (let [key, value] of url.searchParams.entries()) { | ||
params[key] = value; | ||
} | ||
|
||
if (params.code && params.state) { | ||
await authManager.processAuthCode(params); | ||
} | ||
// window.close(); | ||
} | ||
} |
9 changes: 9 additions & 0 deletions
9
src/aux-server/aux-web/aux-auth/site/OAuthRedirect/OAuthRedirect.vue
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
<template> | ||
<div> | ||
<md-progress-spinner md-mode="indeterminate" :md-diameter="20" :md-stroke="2" | ||
>Processing</md-progress-spinner | ||
> | ||
</div> | ||
</template> | ||
<script src="./OAuthRedirect.ts"></script> | ||
<style src="./OAuthRedirect.css" scoped></style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters