fix(web): sync share metadata and active-turn availability (#1306)

* fix(web): align sharing with session state

* fix(web): keep share state in sync

* fix(web): fail closed for trimmed active turns

* fix(web): refresh prepared share images

* fix(web): preserve sharing during queued thinking

* fix: track a stable active turn boundary

* fix: anchor active turns to persisted messages

* fix(web): include Pi reasoning in share metadata

* fix(hub): refresh queued thinking grace on retry

* test(web): isolate mobile thread scroll setup

* fix(hub): advance queued turn boundaries

* fix(hub): guard queued boundary advancement

* perf(web): precompute running turn sharing

* fix(hub): use hub time for turn boundaries

* perf(web): pause closed share metadata timer
This commit is contained in:
Ananovo
2026-08-04 11:18:08 +08:00
committed by GitHub
parent c3bed919b8
commit a0c676818f
20 changed files with 565 additions and 57 deletions
+2
View File
@@ -295,6 +295,7 @@ export const SessionSchema = z.object({
agentStateVersion: z.number(),
thinking: z.boolean(),
thinkingAt: z.number(),
activeTurnStartedAt: z.number().nullable().optional(),
backgroundTaskCount: z.number().optional(),
todos: TodosSchema.optional(),
teamState: TeamStateSchema.optional(),
@@ -347,6 +348,7 @@ const VersionedTeamStatePatchSchema = z.object({
export const SessionPatchSchema = z.object({
active: z.boolean().optional(),
thinking: z.boolean().optional(),
activeTurnStartedAt: z.number().nullable().optional(),
activeAt: z.number().optional(),
updatedAt: z.number().optional(),
// Structured-patch fields for the second half of #884. Letting the four