mirror of
https://github.com/anomalyco/opentui.git
synced 2026-04-25 13:06:00 +03:00
[GH-ISSUE #766] Feature: Ability to detect when TUI's terminal window is out of focus #208
Labels
No labels
bug
core
documentation
feature
good first issue
help wanted
pull-request
question
react
solid
tmux
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/opentui#208
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @IdrisGit on GitHub (Mar 2, 2026).
Original GitHub issue: https://github.com/anomalyco/opentui/issues/766
Something similar to web's
document.visibilityStateto detect when the terminal pane/window comes or goes out of focus, this could be helpful to run some side effects for which we need to know if user is actively looking at the TUI or not, for example, to send OS native notifications if user is out of focus or refetch some data when user comes back to the TUI.Potential solution: maybe it can be detected using the FocusIn/FocusOut events emitted by most modern terminals