Return the ThemeColors for the active Textual theme.
For custom themes (LangChain-branded and user-defined), the pre-built
ThemeColors from the registry is returned directly. For Textual built-in
themes, colors are resolved dynamically from the actual theme properties so
Python-side styling stays in sync with CSS variables.
Textual widget code should call this instead of reading the module-level ANSI constants, which are intended for Rich console output only.
get_theme_colors(
widget_or_app: App | object | None = None,
) -> ThemeColors