Merge pull request #2574 from cheahjs/feat/oauth

feat: experimental SSO support for Google, Microsoft, and OIDC
This commit is contained in:
Timothy Jaeryang Baek authored and GitHub committed 2024-06-24 19:05:58 -07:00
commit d17dc59246
52 files changed
+633 -13

No files matched your search

+6 -1
View File
@@ -18,6 +18,7 @@
USAGE_POOL
} from '$lib/stores';
import { goto } from '$app/navigation';
import { page } from '$app/stores';
import { Toaster, toast } from 'svelte-sonner';
import { getBackendConfig } from '$lib/apis';
@@ -141,7 +142,11 @@
await goto('/auth');
}
} else {
await goto('/auth');
// Don't redirect if we're already on the auth page
// Needed because we pass in tokens from OAuth logins via URL fragments
if ($page.url.pathname !== '/auth') {
await goto('/auth');
}
}
}
} else {