Skip to content

Expose a custom statusline widget API for the CLI airline #14043

Closed

Description

@oxysoft

Summary

Codex CLI should expose a custom statusline widget API rather than only growing a fixed list of built-in statusline elements.

The current configurable statusline/airline direction is good, but it is still constrained if every new need requires another built-in field. The next step should be a high-performance widget system that can render richer statusline components cleanly.

Motivating example

One concrete widget would be an edited file stack:

  • display edited files in order from latest to oldest
  • show the last 5 files
  • render each file as a compact block/tag
  • separate blocks with a lightweight nerd-font / ASCII chevron (>-style) delimiter

This is a strong use of horizontal space because it gives spatial awareness about what the current Codex session is actually touching.

Why a widget API instead of more built-ins

A single custom widget API would subsume many future requests:

  • thread/context identity widgets
  • edited-file stacks
  • richer mode indicators
  • animated progress/status affordances
  • compact attribution/grouping surfaces

Instead of shipping one-off built-ins forever, Codex could expose a composable statusline surface with a high bar for extensibility.

Requested design direction

  • support custom statusline widgets, not just predefined statusline elements
  • widgets should receive enough structured session/state input to render useful context cleanly
  • widgets should be able to occupy the remaining horizontal space intelligently
  • animation support should be possible for richer widgets: scrolling gradients, smooth tag motion along the cell grid, and regular frame/tick updates

Performance / implementation preference

This should ideally be a Rust-native extension surface, not shell-script-based customization.

Reasoning:

  • keep Codex’s TUI performance bar extremely high
  • avoid encouraging fragile shell-driven rendering loops
  • make animation and frequent updates realistic without turning the statusline into a slow sidecar

High bar to entry is fine here if the reward is a clean, fast, powerful widget surface.

Success criteria

  • users can define a custom statusline widget without patching Codex itself
  • widgets can consume enough structured state to build meaningful layouts like edited-file stacks
  • widgets can use horizontal space flexibly rather than being locked to tiny fixed fields
  • the API is performant enough for smooth animated/status-rich widgets

Related context

Current element-level statusline requests:

A widget API would complement those requests and likely reduce future pressure to keep adding one more built-in statusline field.

Activity

  1. added
    enhancementNew feature or request
    CLIIssues related to the Codex CLI
    TUIIssues related to the terminal user interface: text input, menus and dialogs, and terminal display
    on Mar 9, 2026
  2. github-actions commented on Mar 9, 2026

    @github-actions
    Contributor

    Potential duplicates detected. Please review them and close your issue if it is a duplicate.

    Powered by Codex Action

  3. oxysoft commented on Mar 9, 2026

    @oxysoft
    Author

    Related companion proposal: #14046\n\nA custom widget API is much more powerful if the footer can support more than one bottom airline/statusline row. Otherwise richer widgets still get squeezed into a single cramped strip.

  4. oxysoft commented on Mar 9, 2026

    @oxysoft
    Author

    Correction: the companion multi-row airline/statusline proposal is #14047, not #14046.\n\n#14047 is the layout counterpart to this widget API request: richer widgets get much more useful once the footer can support more than one bottom row.

  5. etraut-openai commented on Apr 18, 2026

    @etraut-openai
    Contributor

    This feature request hasn't received enough upvotes, so I'm going to close it.

  6. sumtec commented on May 23, 2026

    @sumtec

    So sad to see it closed. This is a quite important feature to allow me analyzing whether the workflow actually save tokens or wasting more token than before.

  7. etraut-openai commented on May 23, 2026

    @etraut-openai
    Contributor

    @sumtec, this is a duplicate of #17827. Please upvote that if you'd like to see this feature.

  8. hongmd commented on May 27, 2026

    @hongmd

    Codex should add more features so users can track more easily.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    TUIIssues related to the terminal user interface: text input, menus and dialogs, and terminal displayenhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions