From 34f897d1ca3cabc2a137d8d552954195c299ee9f Mon Sep 17 00:00:00 2001 From: mektpoy Date: Thu, 3 Sep 2026 15:14:49 +0800 Subject: [PATCH] refactor(goal): share goal bar resume branch --- packages/client/ui-goal/src/client/GoalBar.tsx | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/packages/client/ui-goal/src/client/GoalBar.tsx b/packages/client/ui-goal/src/client/GoalBar.tsx index 1191448f05..f8fc66bb0d 100644 --- a/packages/client/ui-goal/src/client/GoalBar.tsx +++ b/packages/client/ui-goal/src/client/GoalBar.tsx @@ -133,6 +133,8 @@ export function GoalBar({ goal, activation, onEdit, onPause, onResume, onClear, const title = goal.phase === 'blocked' ? goal.blockedReason?.message : undefined const label = goal.phase === 'active' ? activeLabel(activation, t) : t(PHASE_LABELS[goal.phase]) + const showResume = goal.phase === 'paused' + || (goal.phase === 'active' && activation === 'disarmed') return (
@@ -148,14 +150,7 @@ export function GoalBar({ goal, activation, onEdit, onPause, onResume, onClear, )} - {goal.phase === 'active' && activation === 'disarmed' && ( - - - - )} - {goal.phase === 'paused' && ( + {showResume && (