History is off the Cowork screen, not folded on it

I read "chevron gập pane Lịch sử — giữ" as "keep it as a strip" and left an 18px
sliver down the side. The drawing has nothing there: the body row is two columns,
transcript and files, and the relocation table settles it — History (lịch sử
chat), was "pane giữa, chỉ ở tab Cowork", now "Sidebar ▸ RECENTS", verdict "giữ,
dễ tới hơn". The line about the chevron belongs to a tally of the app's eleven
collapsible spots, not to this screen's layout.

So the panel is not on Cowork at all. "Tất cả project…" in RECENTS brings it in
at full width — it has to stay reachable, because search, filters, pin, rename
and multi-select delete exist nowhere else — and its chevron puts it away again.
Either choice survives leaving the screen and coming back.

check_cowork_screen now requires it absent on arrival and present after the
request; showing it unconditionally fails.

23/23 checkers pass.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Nam Pham Dinh Thanh
2026-08-18 16:12:03 +09:00
co-authored by Claude Opus 5
parent b849cb6ea0
commit d434f7b095
2 changed files with 22 additions and 17 deletions
+5 -5
View File
@@ -91,13 +91,13 @@ def main() -> int:
# and its pane arrives folded to the strip the drawing keeps # and its pane arrives folded to the strip the drawing keeps
w = win.workspace w = win.workspace
sb = w._sidebar sb = w._sidebar
print(f"vao Cowork: History gap={sb.is_collapsed()} rong={sb.width()}px") print(f"vao Cowork: History hien={sb.isVisible()}")
if not sb.is_collapsed(): if sb.isVisible():
fails.append("pane Lich su mo san — man Cowork thanh 3 cot") fails.append("pane Lich su van o tren man Cowork — ban ve chi co 2 cot")
w.show_history_pane() w.show_history_pane()
app.processEvents() app.processEvents()
print(f"sau 'Tat ca project…': History gap={sb.is_collapsed()} rong={sb.width()}px") print(f"sau 'Tat ca project…': History hien={sb.isVisible()} rong={sb.width()}px")
if sb.is_collapsed(): if not sb.isVisible():
fails.append("'Tat ca project…' khong mo duoc pane Lich su") fails.append("'Tat ca project…' khong mo duoc pane Lich su")
w._on_history_fold(True) w._on_history_fold(True)
app.processEvents() app.processEvents()
+17 -12
View File
@@ -320,9 +320,13 @@ class WorkspaceTab(QWidget):
sb.history_changed.connect(self._reload_threads) sb.history_changed.connect(self._reload_threads)
def _on_history_fold(self, collapsed: bool) -> None: def _on_history_fold(self, collapsed: bool) -> None:
"""Remember what the user chose, so switching screens does not undo it.""" """Its chevron closes the panel away, back to the drawn layout."""
self._history_opened = not collapsed self._history_opened = not collapsed
self._set_sidebar_collapsed(collapsed) if collapsed:
self._sidebar.setVisible(False)
self._apply_pane_visibility()
else:
self._set_sidebar_collapsed(False)
def _set_sidebar_collapsed(self, collapsed: bool) -> None: def _set_sidebar_collapsed(self, collapsed: bool) -> None:
"""Collapse/expand History sidebar and redistribute splitter space so """Collapse/expand History sidebar and redistribute splitter space so
@@ -411,15 +415,15 @@ class WorkspaceTab(QWidget):
self._hint.setVisible(on_project and self.project_list.count() == 0) self._hint.setVisible(on_project and self.project_list.count() == 0)
narrow = getattr(self, "_is_narrow", False) narrow = getattr(self, "_is_narrow", False)
if self._sidebar is not None: if self._sidebar is not None:
self._sidebar.setVisible(on_cowork) # Cowork is two columns in the drawing — transcript and files — with
# The drawing gives Cowork two columns — the transcript and the # no history pane and no strip where one used to be. The relocation
# files panel — and moves history to the rail's RECENTS. Its own # table is explicit: History moves to Sidebar ▸ RECENTS, "giữ, dễ
# "Vấn đề" note is that three panes squeezed the conversation below # tới hơn". So the panel is not on this screen at all until asked
# 60% of the width. So History arrives folded to its strip: the # for: "Tất cả project…" in RECENTS brings it in, since search,
# chevron the drawing keeps, one click from the full panel, and # filters, pin, rename and multi-select delete live only there.
# "Tất cả project…" in RECENTS opens it outright. self._sidebar.setVisible(on_cowork and self._history_opened)
if on_cowork and not self._history_opened: if on_cowork and self._history_opened:
self._sidebar.set_collapsed(True) self._sidebar.set_collapsed(False)
# QSplitter ignores hidden panes, but the freed width isn't handed to # QSplitter ignores hidden panes, but the freed width isn't handed to
# the remaining panes deterministically — set explicit sizes after any # the remaining panes deterministically — set explicit sizes after any
# pane toggle (same lesson as _set_projects_collapsed). # pane toggle (same lesson as _set_projects_collapsed).
@@ -714,8 +718,9 @@ class WorkspaceTab(QWidget):
live in this panel. live in this panel.
""" """
self._history_opened = True self._history_opened = True
self._set_sidebar_collapsed(False)
self._show_cowork_tab() self._show_cowork_tab()
self._sidebar.setVisible(True)
self._set_sidebar_collapsed(False)
def start_new_chat(self) -> None: def start_new_chat(self) -> None:
"""Start a new thread in the current project and show it. """Start a new thread in the current project and show it.