review(p9-fb-14): 회차 1 nit 반영
- ask.rs `push_turn_lines` Q label: `Role::Heading + add_modifier(BOLD)` 의 BOLD 가 중복 (Role::Heading 이 양 팔레트 모두 BOLD 포함). 제거 + 주석으로 \"Heading 은 이미 BOLD\" 명시. - run.rs `render_ingest_status` aborted 분기: `Role::Title` (= White + BOLD) 보다 `Role::Warning` (Yellow) 이 \"비정상 종료\" 의미와 정렬. BOLD 는 명시적으로 add_modifier 하여 라이브 진행 라인과의 대비 유지. - theme.rs `impl Default for Theme` 위에 doc comment 추가 — `default() == dark()` invariant 와 `default_palette_is_dark` 테스트가 묶여 있음을 명시. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -153,12 +153,10 @@ fn push_turn_lines(
|
||||
let q_label = format!("Q{}", idx + 1);
|
||||
let a_label = format!("A{}", idx + 1);
|
||||
out.push(Line::from(vec![
|
||||
Span::styled(
|
||||
q_label,
|
||||
theme
|
||||
.style(crate::theme::Role::Heading)
|
||||
.add_modifier(Modifier::BOLD),
|
||||
),
|
||||
// `Role::Heading` already includes BOLD in both palettes, so
|
||||
// no need to `add_modifier(BOLD)` here — the redundancy would
|
||||
// imply Heading lacks BOLD elsewhere.
|
||||
Span::styled(q_label, theme.style(crate::theme::Role::Heading)),
|
||||
Span::raw(": "),
|
||||
Span::raw(question.to_string()),
|
||||
]));
|
||||
|
||||
@@ -247,8 +247,14 @@ fn render_ingest_status(f: &mut Frame, area: Rect, app: &App) {
|
||||
return;
|
||||
};
|
||||
let line = crate::ingest_progress::status_line(state);
|
||||
// p9-fb-14: `aborted` is a non-fatal-but-noteworthy state (Ctrl-C
|
||||
// partial commit) — `Role::Warning` (yellow) is the right semantic
|
||||
// signal, plus an explicit BOLD so the abort line still stands
|
||||
// out from the live progress lines around it.
|
||||
let style = if state.aborted {
|
||||
app.theme.style(crate::theme::Role::Title)
|
||||
app.theme
|
||||
.style(crate::theme::Role::Warning)
|
||||
.add_modifier(ratatui::style::Modifier::BOLD)
|
||||
} else {
|
||||
app.theme.style(crate::theme::Role::Body)
|
||||
};
|
||||
|
||||
@@ -128,6 +128,10 @@ impl Theme {
|
||||
}
|
||||
}
|
||||
|
||||
/// `Theme::default() == Theme::dark()` — pinned by
|
||||
/// `default_palette_is_dark` test. If the default ever flips, both
|
||||
/// the test and downstream callers (e.g. integration smokes that
|
||||
/// rely on dark contrast) need a coordinated update.
|
||||
impl Default for Theme {
|
||||
fn default() -> Self {
|
||||
Self::dark()
|
||||
|
||||
Reference in New Issue
Block a user