mirror of
https://git.datalinker.icu/comfyanonymous/ComfyUI
synced 2026-11-20 16:07:12 +08:00
LoadAudio restores file value from workflow
This commit is contained in:
parent
281ad42df4
commit
b342654b5f
@ -150,6 +150,15 @@ app.registerExtension({
|
|||||||
}
|
}
|
||||||
audioWidget.callback = onAudioWidgetUpdate
|
audioWidget.callback = onAudioWidgetUpdate
|
||||||
|
|
||||||
|
// Load saved audio file widget values if restoring from workflow
|
||||||
|
const onGraphConfigured = node.onGraphConfigured;
|
||||||
|
node.onGraphConfigured = () => {
|
||||||
|
onGraphConfigured?.apply(this, arguments)
|
||||||
|
if (audioWidget.value) {
|
||||||
|
onAudioWidgetUpdate()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
const fileInput = document.createElement("input")
|
const fileInput = document.createElement("input")
|
||||||
fileInput.type = "file"
|
fileInput.type = "file"
|
||||||
fileInput.accept = "audio/*"
|
fileInput.accept = "audio/*"
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user