Fix workspace-owned Playwright flows
This commit is contained in:
@@ -77,6 +77,7 @@ function buildHistoricalAgentDetail(agent: AggregatedAgent): Agent {
|
||||
},
|
||||
title: agent.title,
|
||||
cwd: agent.cwd,
|
||||
workspaceId: agent.workspaceId,
|
||||
model: null,
|
||||
thinkingOptionId: null,
|
||||
requiresAttention: agent.requiresAttention,
|
||||
@@ -101,6 +102,7 @@ function rememberArchivedAgentDetail(agent: AggregatedAgent) {
|
||||
...existing,
|
||||
archivedAt: existing?.archivedAt ?? agent.archivedAt,
|
||||
cwd: existing?.cwd ?? agent.cwd,
|
||||
workspaceId: existing?.workspaceId ?? agent.workspaceId,
|
||||
});
|
||||
return next;
|
||||
});
|
||||
|
||||
@@ -60,6 +60,7 @@ export async function fetchAgentHistoryPage(input: {
|
||||
status: agent.status,
|
||||
lastActivityAt: agent.lastActivityAt,
|
||||
cwd: agent.cwd,
|
||||
workspaceId: agent.workspaceId,
|
||||
provider: agent.provider,
|
||||
pendingPermissionCount: agent.pendingPermissions.length,
|
||||
requiresAttention: agent.requiresAttention,
|
||||
|
||||
@@ -78,6 +78,7 @@ export function useAggregatedAgents(options?: {
|
||||
status: agent.status,
|
||||
lastActivityAt: agent.lastActivityAt,
|
||||
cwd: agent.cwd,
|
||||
workspaceId: agent.workspaceId,
|
||||
provider: agent.provider,
|
||||
pendingPermissionCount: agent.pendingPermissions.length,
|
||||
requiresAttention: agent.requiresAttention,
|
||||
|
||||
@@ -8,6 +8,7 @@ export type AgentDirectoryEntry = Pick<
|
||||
| "status"
|
||||
| "lastActivityAt"
|
||||
| "cwd"
|
||||
| "workspaceId"
|
||||
| "provider"
|
||||
| "requiresAttention"
|
||||
| "attentionReason"
|
||||
|
||||
@@ -31,6 +31,14 @@ export const usePinnedTargetsStore = create<PinnedTargetsState>()(
|
||||
{
|
||||
name: "pinned-tab-targets",
|
||||
version: 1,
|
||||
merge: (persistedState, currentState) => {
|
||||
const persisted = persistedState as Partial<PinnedTargetsState> | null;
|
||||
return {
|
||||
...currentState,
|
||||
...persisted,
|
||||
pinned: persisted?.pinned ?? applyDefaultPinnedTargets([]),
|
||||
};
|
||||
},
|
||||
storage: createJSONStorage(() => AsyncStorage),
|
||||
partialize: (state) => ({ pinned: state.pinned }),
|
||||
migrate: (persistedState, version) => {
|
||||
|
||||
Reference in New Issue
Block a user