Skip to content

Commit

Permalink
Disable suggestion button briefly after click (#691)
Browse files Browse the repository at this point in the history
  • Loading branch information
philippjfr authored Aug 22, 2024
1 parent 56bb843 commit 42700fc
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lumen/ai/assistant.py
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,9 @@ async def run_demo(event):
on_click=run_demo,
margin=5,
))
disable_js = "cb_obj.origin.disabled = true; setTimeout(() => cb_obj.origin.disabled = false, 3000)"
for b in suggestion_buttons:
b.js_on_click(code=disable_js)

message = self.interface.objects[-1]
if inplace:
Expand Down

0 comments on commit 42700fc

Please sign in to comment.