How to invoke pop-up windows tips and hide an option in node
Your question
Hello, author. Thanks for your works, when developing custom node, i met some problems. How to invoke ComfyUI pop-up windows to tip of user and hide an option in custom node. Wish your answer. Thanks
Logs
No response
Other
No response
Add pop-up windows to tip of user:
app.extensionManager.toast.add({
severity: 'info', // element of ['success', 'info', 'warn', 'error', 'secondary', 'contrast']
summary: 'Loaded!',
detail: 'Extension loaded!',
life: 3000
})
Source:
- https://github.com/Comfy-Org/ComfyUI_frontend/pull/491
Ok, thanks for you solution.
@christian-byrne Hi, how to invoke this code in python project. Thanks
This issue is being marked stale because it has not had any activity for 30 days. Reply below within 7 days if your issue still isn't solved, and it will be left open. Otherwise, the issue will be closed automatically.
@christian-byrne Hi, how to invoke this code in python project. Thanks
By default, ComfyUI's Python code does not provide such a method.
As an extension feature, Python needs to send an event to the front end, and the event listener in the front-end JavaScript code should execute the toast code.