MCPcopy
hub / github.com/agent0ai/agent-zero / beginCloseConfirmation

Function beginCloseConfirmation

plugins/_editor/webui/editor-store.js:1069–1083  ·  view source on GitHub ↗
(kind, tabIds = [])

Source from the content-addressed store, hash-verified

1067 },
1068
1069 beginCloseConfirmation(kind, tabIds = []) {
1070 const ids = tabIds.filter(Boolean);
1071 const tabs = ids.map((id) => this.tabs.find((tab) => tab.tab_id === id)).filter(Boolean);
1072 const dirtyCount = tabs.filter((tab) => this.isTabDirty(tab)).length;
1073 this.pendingClose = {
1074 kind,
1075 tabId: kind === "single" ? ids[0] || "" : "",
1076 tabIds: ids,
1077 totalCount: tabs.length,
1078 dirtyCount,
1079 };
1080 if (kind === "single" && ids[0] && this.activeTabId !== ids[0]) {
1081 this.selectTab(ids[0], { focus: false });
1082 }
1083 },
1084
1085 cancelPendingClose() {
1086 this.pendingClose = null;

Callers

nothing calls this directly

Calls 1

mapMethod · 0.80

Tested by

no test coverage detected