module RatatuiRuby::Terminal::Capabilities

Environment-based terminal capability detection.

TUI applications need to know what the terminal supports. Color depth varies. Some terminals lack escape sequence support entirely. Users set environment variables like NO_COLOR to express preferences.

This module detects terminal capabilities from environment variables. It checks TERM, COLORTERM, NO_COLOR, and FORCE_COLOR to determine what the terminal supports.

Use these methods before initializing a Terminal instance to decide whether TUI mode is appropriate for the current environment.

Example

if RatatuiRuby::Terminal.interactive?
  RatatuiRuby.run { |tui| ... }
else
  puts "TUI mode not available"
end