lastSeenOnline storage key is internal
Signed-off-by: Manuel Scurti <manuel.scurti@agilelab.it>
This commit is contained in:
@@ -68,10 +68,6 @@ export type AlertDisplayProps = {
|
||||
transientTimeoutMs?: number;
|
||||
};
|
||||
|
||||
// @public (undocumented)
|
||||
export const AUTOLOGOUT_LAST_SEEN_ONLINE_STORAGE_KEY =
|
||||
'@backstage/autologout:lastSeenOnline';
|
||||
|
||||
// @public
|
||||
export const AutoLogoutProvider: ({
|
||||
children,
|
||||
|
||||
@@ -18,7 +18,6 @@ import { useEffect } from 'react';
|
||||
|
||||
import { TimestampStore } from './timestampStore';
|
||||
|
||||
/** @public */
|
||||
export const LAST_SEEN_ONLINE_STORAGE_KEY =
|
||||
'@backstage/autologout:lastSeenOnline';
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
import { LAST_SEEN_ONLINE_STORAGE_KEY } from './disconnectedUsers';
|
||||
|
||||
/*
|
||||
* Copyright 2023 The Backstage Authors
|
||||
*
|
||||
@@ -18,6 +16,5 @@ import { LAST_SEEN_ONLINE_STORAGE_KEY } from './disconnectedUsers';
|
||||
export * from './AutoLogoutProvider';
|
||||
export * from './ConfigBasedAutoLogoutProvider';
|
||||
|
||||
/** @public */
|
||||
export const AUTOLOGOUT_LAST_SEEN_ONLINE_STORAGE_KEY =
|
||||
LAST_SEEN_ONLINE_STORAGE_KEY;
|
||||
/** @internal */
|
||||
export { LAST_SEEN_ONLINE_STORAGE_KEY } from './disconnectedUsers';
|
||||
|
||||
@@ -31,7 +31,7 @@ import { commonProvider } from './commonProvider';
|
||||
import { guestProvider } from './guestProvider';
|
||||
import { customProvider } from './customProvider';
|
||||
import { IdentityApiSignOutProxy } from './IdentityApiSignOutProxy';
|
||||
import { AUTOLOGOUT_LAST_SEEN_ONLINE_STORAGE_KEY } from '../../components';
|
||||
import { LAST_SEEN_ONLINE_STORAGE_KEY } from '../../components';
|
||||
|
||||
const PROVIDER_STORAGE_KEY = '@backstage/core:SignInPage:provider';
|
||||
|
||||
@@ -96,7 +96,7 @@ export const useSignInProviders = (
|
||||
IdentityApiSignOutProxy.from({
|
||||
identityApi,
|
||||
signOut: async () => {
|
||||
localStorage.removeItem(AUTOLOGOUT_LAST_SEEN_ONLINE_STORAGE_KEY);
|
||||
localStorage.removeItem(LAST_SEEN_ONLINE_STORAGE_KEY);
|
||||
localStorage.removeItem(PROVIDER_STORAGE_KEY);
|
||||
await identityApi.signOut?.();
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user