Skip to content

hide empty subagent container to prevent white gap#539

Merged
limityan merged 4 commits intoGCWing:mainfrom
limityan:yanzhn/fix
Apr 26, 2026
Merged

hide empty subagent container to prevent white gap#539
limityan merged 4 commits intoGCWing:mainfrom
limityan:yanzhn/fix

Conversation

@limityan
Copy link
Copy Markdown
Collaborator

When a subagent task starts but has no items yet, the
subagent-items-container was still rendered with padding
and background, causing a white/empty area above the
content. Now returns null when items.length === 0.

@limityan limityan force-pushed the yanzhn/fix branch 2 times, most recently from b386324 to 8568282 Compare April 26, 2026 08:17
- Frontend (PersistenceModule.ts): When saving in-progress turns during app close,
  mark non-active sessions as having unread completion and persist to disk
- Backend (session_manager.rs): When restoring sessions, detect if previous state
  was not Idle (indicating abnormal close/crash) and automatically set
  unread_completion to 'completed'

This dual protection ensures sessions are marked as unread after IDE restart,
whether the close was normal or abnormal (crash, kill, power loss).
When the model stream is interrupted mid-way and recovers partially, the
session now shows a red unread dot instead of green, indicating that
the output is incomplete and user input is needed to continue.

- Add 'interrupted' to unreadCompletion type (red dot, same as 'error')
- Add is-interrupted CSS class with red styling
- Add i18n keys for interrupted state (en-US, zh-CN, zh-TW)
- Backend partial recovery retry logic (in previous commit)

Requires: PR #63fca72d (Rust side) for complete feature.
When a subagent task starts but has no items yet, the
subagent-items-container was still rendered with padding
and background, causing a white/empty area above the
content. Now returns null when items.length === 0.

Generated with BitFun

Co-Authored-By: BitFun
- Replace '__TAURI__' in window check with isTauriRuntime() from
  @/infrastructure/runtime for correct Tauri v2 detection
- Remove enabled: available condition from useShortcut registration;
  shortcuts are always registered but callbacks no-op when not in
  Tauri desktop environment. This avoids race conditions where
  Tauri runtime detection happens after component mount.

Generated with BitFun
Co-Authored-By: BitFun
@limityan limityan merged commit a1c9c5b into GCWing:main Apr 26, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant