Skip to content

Feature: Ability to detect when TUI's terminal window is out of focus #766

@IdrisGit

Description

@IdrisGit

Something similar to web's document.visibilityState to 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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions