diff --git a/apps/studio/components/layouts/ProjectLayout/PausedState/PauseDisabledState.tsx b/apps/studio/components/layouts/ProjectLayout/PausedState/PauseDisabledState.tsx index 4929166d957..90b85ea5a45 100644 --- a/apps/studio/components/layouts/ProjectLayout/PausedState/PauseDisabledState.tsx +++ b/apps/studio/components/layouts/ProjectLayout/PausedState/PauseDisabledState.tsx @@ -19,7 +19,7 @@ import { DropdownMenuItem, DropdownMenuTrigger, } from 'ui' -import { Admonition } from 'ui-patterns' +import { Admonition, TimestampInfo } from 'ui-patterns' export const PauseDisabledState = () => { const { ref } = useParams() @@ -121,10 +121,10 @@ export const PauseDisabledState = () => { -

+

This project has been paused for over{' '} {pauseStatus?.max_days_till_restore_disabled ?? 90} days @@ -133,6 +133,17 @@ export const PauseDisabledState = () => { downloaded as a backup.

+ {!!pauseStatus?.last_paused_on && ( +

+ Project last paused on{' '} + +

+ )} +

Recovery options:

) } - -export default PausingState diff --git a/apps/studio/components/layouts/ProjectLayout/RestoringState.tsx b/apps/studio/components/layouts/ProjectLayout/RestoringState.tsx index 43ae5f80dd5..35944239661 100644 --- a/apps/studio/components/layouts/ProjectLayout/RestoringState.tsx +++ b/apps/studio/components/layouts/ProjectLayout/RestoringState.tsx @@ -41,10 +41,6 @@ const RestoringState = () => { if (!isProjectStatusSuccess) return if (projectStatusData.status === PROJECT_STATUS.ACTIVE_HEALTHY) { setIsCompleted(true) - } else { - if (ref) { - invalidateProjectDetailsQuery(ref) - } } }, [isProjectStatusSuccess, projectStatusData, ref, invalidateProjectDetailsQuery]) @@ -70,7 +66,6 @@ const RestoringState = () => { const onConfirm = async () => { if (!project) return console.error('Project is required') - setLoading(true) if (ref) await invalidateProjectDetailsQuery(ref) } diff --git a/apps/studio/components/layouts/ProjectLayout/index.tsx b/apps/studio/components/layouts/ProjectLayout/index.tsx index b987038cf74..3ffa96b4852 100644 --- a/apps/studio/components/layouts/ProjectLayout/index.tsx +++ b/apps/studio/components/layouts/ProjectLayout/index.tsx @@ -23,7 +23,7 @@ import ConnectingState from './ConnectingState' import { LoadingState } from './LoadingState' import { ProjectPausedState } from './PausedState/ProjectPausedState' import { PauseFailedState } from './PauseFailedState' -import PausingState from './PausingState' +import { PausingState } from './PausingState' import ProductMenuBar from './ProductMenuBar' import { ResizingState } from './ResizingState' import RestartingState from './RestartingState'