Skip to content

fix: make workspace buttons less confusing when errors happen #10609

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 16 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
refactor: make restarting view logic more explicit
  • Loading branch information
Parkreiner committed Nov 8, 2023
commit a0b153f1ae376b4ca9bdf25cd7f8f0fadf498cb9
Original file line number Diff line number Diff line change
Expand Up @@ -109,12 +109,11 @@ export const WorkspaceActions: FC<WorkspaceActionsProps> = ({
{canBeUpdated &&
(isUpdating ? buttonMapping.updating : buttonMapping.update)}

{isRestarting && buttonMapping.restarting}

{!isRestarting &&
actionsByStatus.map((action) => (
<Fragment key={action}>{buttonMapping[action]}</Fragment>
))}
{isRestarting
? buttonMapping.restarting
: actionsByStatus.map((action) => (
<Fragment key={action}>{buttonMapping[action]}</Fragment>
))}

{canCancel && <CancelButton handleAction={handleCancel} />}

Expand Down