mirror of
https://github.com/openai/codex.git
synced 2026-11-07 20:30:33 +00:00
## What changed Replace `tui.whimsy` with `[tui.effects]` preferences for `starfield`, `shimmer`, `welcome`, `effort`, `progress`, and `title`. Each defaults to `true` and remains subordinate to the `tui.animations` master switch. Wire the preferences into composer effects, welcome artwork, status and loading text, progress indicators, and terminal-title animations. For example, disable shimmering text while keeping progress animations: ```toml [tui.effects] shimmer = false ``` Keep retired `tui.whimsy` entries loadable but ignore their value. Update the configuration schema to expose the new preferences. ## Testing Add and extend coverage for independent shimmer and progress effects, master-switch precedence, welcome and starfield controls, terminal-title blinking, and strict configuration loading with the retired setting. GitOrigin-RevId: 28b37ba52872133b8954543cabe9ff424147f1c5
38 lines
1.1 KiB
Rust
38 lines
1.1 KiB
Rust
//! Individual TUI effect preferences, subordinate to the animation master switch.
|
|
|
|
use schemars::JsonSchema;
|
|
use serde::Deserialize;
|
|
use serde::Serialize;
|
|
|
|
/// Optional visual effects. Disabling an effect preserves its underlying activity.
|
|
#[derive(Serialize, Deserialize, Debug, Copy, Clone, PartialEq, Eq, JsonSchema)]
|
|
#[serde(default)]
|
|
#[schemars(deny_unknown_fields)]
|
|
pub struct TuiEffects {
|
|
/// Animate the composer starfield.
|
|
pub starfield: bool,
|
|
/// Shimmer status and loading text.
|
|
pub shimmer: bool,
|
|
/// Animate the welcome artwork.
|
|
pub welcome: bool,
|
|
/// Animate reasoning-effort changes in the composer and footer.
|
|
pub effort: bool,
|
|
/// Animate activity bullets and loading spinners.
|
|
pub progress: bool,
|
|
/// Blink the terminal-title indicator when user action is required.
|
|
pub title: bool,
|
|
}
|
|
|
|
impl Default for TuiEffects {
|
|
fn default() -> Self {
|
|
Self {
|
|
starfield: true,
|
|
shimmer: true,
|
|
welcome: true,
|
|
effort: true,
|
|
progress: true,
|
|
title: true,
|
|
}
|
|
}
|
|
}
|