mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-03-01 19:20:10 +00:00
Fixed favicon some progress frames not found - by ComfyWaifu 🤍 (#4143)
This commit is contained in:
@@ -15,7 +15,10 @@ export const useProgressFavicon = () => {
|
||||
if (isIdle) {
|
||||
favicon.value = defaultFavicon
|
||||
} else {
|
||||
const frame = Math.floor(progress * totalFrames)
|
||||
const frame = Math.min(
|
||||
Math.max(0, Math.floor(progress * totalFrames)),
|
||||
totalFrames - 1
|
||||
)
|
||||
favicon.value = `/assets/images/favicon_progress_16x16/frame_${frame}.png`
|
||||
}
|
||||
}
|
||||
|
||||
@@ -88,7 +88,7 @@ export const useExecutionStore = defineStore('execution', () => {
|
||||
if (!activePrompt.value) return 0
|
||||
const total = totalNodesToExecute.value
|
||||
const done = nodesExecuted.value
|
||||
return done / total
|
||||
return total > 0 ? done / total : 0
|
||||
})
|
||||
|
||||
function bindExecutionEvents() {
|
||||
|
||||
Reference in New Issue
Block a user