agent-loft 0.2.87 → 0.2.88

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agent-loft",
3
- "version": "0.2.87",
3
+ "version": "0.2.88",
4
4
  "type": "module",
5
5
  "description": "多个 agent 的工作台:把本机 Claude Code / Codex 放到一处统一管理,用飞书和 Web 页面随时驱动——会话、审批、模型切换都共用",
6
6
  "keywords": [
@@ -165,8 +165,8 @@ export async function boot() {
165
165
  else void loadQuota();
166
166
  if (srv && srv !== HOME) routeToServer(srv, decodeURIComponent(landing.hash.slice(1)));
167
167
  const fromHash = decodeURIComponent(location.hash.slice(1));
168
- // 地址里带了会话就打开它;否则打开「最近」里最近活跃的那个对话,一个都没有才进新对话页
169
- const latest = latestConversation();
168
+ // 地址里带了会话就打开它;否则打开最近活跃的 Web 对话,没有才进新对话页
169
+ const latest = latestConversation("web");
170
170
  if (fromHash === "tasks") openTasksView();
171
171
  else if (fromHash === "library") openLibraryView();
172
172
  else if (fromHash === "new") newDraft({ inheritLatest: true });
@@ -63,8 +63,8 @@ function leaveTasksView() {
63
63
  document.dispatchEvent(new Event("aim:leave-view"));
64
64
  }
65
65
 
66
- export function latestConversation() {
67
- return [...S.convs.values()].filter((c) => !c.hidden).sort((a, b) => b.activeAt - a.activeAt)[0];
66
+ export function latestConversation(channel) {
67
+ return [...S.convs.values()].filter((c) => !c.hidden && (!channel || c.channel === channel)).sort((a, b) => b.activeAt - a.activeAt)[0];
68
68
  }
69
69
 
70
70
  export function newDraft({ inheritLatest = false } = {}) {