Skip to content

Commit

Permalink
Increase timeout on prompt dialog dismiss
Browse files Browse the repository at this point in the history
  • Loading branch information
christian-byrne committed Aug 24, 2024
1 parent 3387e16 commit 2482845
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/litegraph.js
Original file line number Diff line number Diff line change
Expand Up @@ -11432,8 +11432,9 @@ LGraphNode.prototype.executeAction = function(action)

setTimeout(function() {
input.focus();
const clickTime = Date.now();
function handleOutsideClick(e) {
if (e.target === canvas) {
if (e.target === canvas && Date.now() - clickTime > 256) {
dialog.close();
canvas.parentNode.removeEventListener("click", handleOutsideClick);
canvas.parentNode.removeEventListener("touchend", handleOutsideClick);
Expand Down

0 comments on commit 2482845

Please sign in to comment.