mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-04-30 19:21:54 +00:00
Test: Fix templates Spec, scroll card into view (#7643)
## Summary - Scroll the target card into view before clicking - Hopefully stabilize the locale check by enqueuing the check earlier in the process ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-7643-Test-Fix-templates-Spec-scroll-card-into-view-2ce6d73d36508175a009f81502f0fe16) by [Unito](https://www.unito.io)
This commit is contained in:
@@ -26,10 +26,9 @@ export class ComfyTemplates {
|
||||
}
|
||||
|
||||
async loadTemplate(id: string) {
|
||||
await this.content
|
||||
.getByTestId(`template-workflow-${id}`)
|
||||
.getByRole('img')
|
||||
.click()
|
||||
const templateCard = this.content.getByTestId(`template-workflow-${id}`)
|
||||
await templateCard.scrollIntoViewIfNeeded()
|
||||
await templateCard.getByRole('img').click()
|
||||
}
|
||||
|
||||
async getAllTemplates(): Promise<TemplateInfo[]> {
|
||||
|
||||
Reference in New Issue
Block a user