Skip to content

Commit 2657898

Browse files
benceruleanlupythongosssssgithub-actionsviva-jinyiclaude
authored
Remove queue sidebar tab (#6724)
## Summary - drop the queue sidebar entry, its component, and the supporting composable so only the overlay-based queue UI remains - clean up the related tests and keybindings so nothing references the removed tab - prune the unused queue task card components to keep the repo tidy - remove unused queue sidebar translations and command strings across all locales ## Testing - pnpm typecheck - pnpm lint:fix ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-6724-Remove-queue-sidebar-tab-2ae6d73d3650811db0d4c5ad4c5ffc8d) by [Unito](https://www.unito.io) --------- Co-authored-by: pythongosssss <[email protected]> Co-authored-by: github-actions <[email protected]> Co-authored-by: Jin Yi <[email protected]> Co-authored-by: Claude <[email protected]> Co-authored-by: GitHub Action <[email protected]> Co-authored-by: Alexander Brown <[email protected]> Co-authored-by: Johnpaul Chiwetelu <[email protected]> Co-authored-by: Christian Byrne <[email protected]> Co-authored-by: Comfy Org PR Bot <[email protected]> Co-authored-by: christian-byrne <[email protected]>
1 parent 38fb53d commit 2657898

File tree

53 files changed

+4
-1182
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+4
-1182
lines changed

browser_tests/fixtures/ComfyPage.ts

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ import { ComfyNodeSearchBox } from './components/ComfyNodeSearchBox'
1616
import { SettingDialog } from './components/SettingDialog'
1717
import {
1818
NodeLibrarySidebarTab,
19-
QueueSidebarTab,
2019
WorkflowsSidebarTab
2120
} from './components/SidebarTab'
2221
import { Topbar } from './components/Topbar'
@@ -31,7 +30,6 @@ type WorkspaceStore = ReturnType<typeof useWorkspaceStore>
3130
class ComfyMenu {
3231
private _nodeLibraryTab: NodeLibrarySidebarTab | null = null
3332
private _workflowsTab: WorkflowsSidebarTab | null = null
34-
private _queueTab: QueueSidebarTab | null = null
3533
private _topbar: Topbar | null = null
3634

3735
public readonly sideToolbar: Locator
@@ -60,11 +58,6 @@ class ComfyMenu {
6058
return this._workflowsTab
6159
}
6260

63-
get queueTab() {
64-
this._queueTab ??= new QueueSidebarTab(this.page)
65-
return this._queueTab
66-
}
67-
6861
get topbar() {
6962
this._topbar ??= new Topbar(this.page)
7063
return this._topbar

browser_tests/fixtures/components/SidebarTab.ts

Lines changed: 0 additions & 121 deletions
Original file line numberDiff line numberDiff line change
@@ -148,124 +148,3 @@ export class WorkflowsSidebarTab extends SidebarTab {
148148
.click()
149149
}
150150
}
151-
152-
export class QueueSidebarTab extends SidebarTab {
153-
constructor(public readonly page: Page) {
154-
super(page, 'queue')
155-
}
156-
157-
get root() {
158-
return this.page.locator('.sidebar-content-container', { hasText: 'Queue' })
159-
}
160-
161-
get tasks() {
162-
return this.root.locator('[data-virtual-grid-item]')
163-
}
164-
165-
get visibleTasks() {
166-
return this.tasks.locator('visible=true')
167-
}
168-
169-
get clearButton() {
170-
return this.root.locator('.clear-all-button')
171-
}
172-
173-
get collapseTasksButton() {
174-
return this.getToggleExpandButton(false)
175-
}
176-
177-
get expandTasksButton() {
178-
return this.getToggleExpandButton(true)
179-
}
180-
181-
get noResultsPlaceholder() {
182-
return this.root.locator('.no-results-placeholder')
183-
}
184-
185-
get galleryImage() {
186-
return this.page.locator('.galleria-image')
187-
}
188-
189-
private getToggleExpandButton(isExpanded: boolean) {
190-
const iconSelector = isExpanded ? '.pi-image' : '.pi-images'
191-
return this.root.locator(`.toggle-expanded-button ${iconSelector}`)
192-
}
193-
194-
async open() {
195-
await super.open()
196-
return this.root.waitFor({ state: 'visible' })
197-
}
198-
199-
async close() {
200-
await super.close()
201-
await this.root.waitFor({ state: 'hidden' })
202-
}
203-
204-
async expandTasks() {
205-
await this.expandTasksButton.click()
206-
await this.collapseTasksButton.waitFor({ state: 'visible' })
207-
}
208-
209-
async collapseTasks() {
210-
await this.collapseTasksButton.click()
211-
await this.expandTasksButton.waitFor({ state: 'visible' })
212-
}
213-
214-
async waitForTasks() {
215-
return Promise.all([
216-
this.tasks.first().waitFor({ state: 'visible' }),
217-
this.tasks.last().waitFor({ state: 'visible' })
218-
])
219-
}
220-
221-
async scrollTasks(direction: 'up' | 'down') {
222-
const scrollToEl =
223-
direction === 'up' ? this.tasks.last() : this.tasks.first()
224-
await scrollToEl.scrollIntoViewIfNeeded()
225-
await this.waitForTasks()
226-
}
227-
228-
async clearTasks() {
229-
await this.clearButton.click()
230-
const confirmButton = this.page.getByLabel('Delete')
231-
await confirmButton.click()
232-
await this.noResultsPlaceholder.waitFor({ state: 'visible' })
233-
}
234-
235-
/** Set the width of the tab (out of 100). Must call before opening the tab */
236-
async setTabWidth(width: number) {
237-
if (width < 0 || width > 100) {
238-
throw new Error('Width must be between 0 and 100')
239-
}
240-
return this.page.evaluate((width) => {
241-
localStorage.setItem('queue', JSON.stringify([width, 100 - width]))
242-
}, width)
243-
}
244-
245-
getTaskPreviewButton(taskIndex: number) {
246-
return this.tasks.nth(taskIndex).getByRole('button')
247-
}
248-
249-
async openTaskPreview(taskIndex: number) {
250-
const previewButton = this.getTaskPreviewButton(taskIndex)
251-
await previewButton.click()
252-
return this.galleryImage.waitFor({ state: 'visible' })
253-
}
254-
255-
getGalleryImage(imageFilename: string) {
256-
return this.galleryImage.and(this.page.getByAltText(imageFilename))
257-
}
258-
259-
getTaskImage(imageFilename: string) {
260-
return this.tasks.getByAltText(imageFilename)
261-
}
262-
263-
/** Trigger the queue store and tasks to update */
264-
async triggerTasksUpdate() {
265-
await this.page.evaluate(() => {
266-
window['app']['api'].dispatchCustomEvent('status', {
267-
exec_info: { queue_remaining: 0 }
268-
})
269-
})
270-
}
271-
}

browser_tests/tests/sidebar/queue.spec.ts

Lines changed: 0 additions & 210 deletions
This file was deleted.
-398 Bytes
Loading
-620 Bytes
Loading
-461 Bytes
Loading
-630 Bytes
Loading
-566 Bytes
Loading
-610 Bytes
Loading
-643 Bytes
Loading

0 commit comments

Comments
 (0)