Skip to content

Commit 1e08b40

Browse files
style: Apply cargo fmt
🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent a45b98f commit 1e08b40

File tree

4 files changed

+37
-20
lines changed

4 files changed

+37
-20
lines changed

crates/charmer-monitor/src/components/job_detail.rs

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,11 @@ impl JobDetail {
3232
))],
3333
};
3434

35-
let paragraph = Paragraph::new(content)
36-
.block(Block::default().borders(Borders::ALL).title(" Job Details "));
35+
let paragraph = Paragraph::new(content).block(
36+
Block::default()
37+
.borders(Borders::ALL)
38+
.title(" Job Details "),
39+
);
3740

3841
frame.render_widget(paragraph, area);
3942
}
@@ -42,8 +45,11 @@ impl JobDetail {
4245
pub fn render_pipeline(frame: &mut Frame, area: Rect, state: &PipelineState) {
4346
let content = build_pipeline_lines(state);
4447

45-
let paragraph = Paragraph::new(content)
46-
.block(Block::default().borders(Borders::ALL).title(" Job Details "));
48+
let paragraph = Paragraph::new(content).block(
49+
Block::default()
50+
.borders(Borders::ALL)
51+
.title(" Job Details "),
52+
);
4753

4854
frame.render_widget(paragraph, area);
4955
}
@@ -249,7 +255,10 @@ fn build_detail_lines(job: &Job, command_expanded: bool) -> Vec<Line<'static>> {
249255

250256
// Wildcards / Sample info - colored to match job list
251257
if let Some(ref wildcards) = job.wildcards {
252-
let mut spans = vec![Span::styled("Wildcards: ", Style::default().fg(Color::Gray))];
258+
let mut spans = vec![Span::styled(
259+
"Wildcards: ",
260+
Style::default().fg(Color::Gray),
261+
)];
253262

254263
// Parse and color each wildcard: key in white, value in color
255264
let pairs: Vec<(&str, &str)> = wildcards

crates/charmer-monitor/src/components/job_list.rs

Lines changed: 18 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -283,7 +283,9 @@ impl JobList {
283283
display_row
284284
};
285285
let (relation, chain_pos) = deps[i];
286-
build_job_item(row_num, i, job_id, state, &counts, selected, &opts, relation, chain_pos)
286+
build_job_item(
287+
row_num, i, job_id, state, &counts, selected, &opts, relation, chain_pos,
288+
)
287289
})
288290
.collect();
289291

@@ -516,7 +518,9 @@ fn build_job_item(
516518
ChainPosition::First => {
517519
let dot_style = match dep_relation {
518520
DepRelation::Upstream => Style::default().fg(Color::Cyan),
519-
DepRelation::Selected => Style::default().fg(Color::White).add_modifier(Modifier::BOLD),
521+
DepRelation::Selected => Style::default()
522+
.fg(Color::White)
523+
.add_modifier(Modifier::BOLD),
520524
DepRelation::Downstream => Style::default().fg(Color::Magenta),
521525
DepRelation::None => tree_style,
522526
};
@@ -528,7 +532,9 @@ fn build_job_item(
528532
ChainPosition::Middle => {
529533
let dot_style = match dep_relation {
530534
DepRelation::Upstream => Style::default().fg(Color::Cyan),
531-
DepRelation::Selected => Style::default().fg(Color::White).add_modifier(Modifier::BOLD),
535+
DepRelation::Selected => Style::default()
536+
.fg(Color::White)
537+
.add_modifier(Modifier::BOLD),
532538
DepRelation::Downstream => Style::default().fg(Color::Magenta),
533539
DepRelation::None => tree_style,
534540
};
@@ -540,7 +546,9 @@ fn build_job_item(
540546
ChainPosition::Last => {
541547
let dot_style = match dep_relation {
542548
DepRelation::Upstream => Style::default().fg(Color::Cyan),
543-
DepRelation::Selected => Style::default().fg(Color::White).add_modifier(Modifier::BOLD),
549+
DepRelation::Selected => Style::default()
550+
.fg(Color::White)
551+
.add_modifier(Modifier::BOLD),
544552
DepRelation::Downstream => Style::default().fg(Color::Magenta),
545553
DepRelation::None => tree_style,
546554
};
@@ -808,8 +816,8 @@ fn render_progress_header(
808816
let chunks = Layout::default()
809817
.direction(Direction::Horizontal)
810818
.constraints([
811-
Constraint::Length(filter_sort_width as u16), // Filter/Sort with padding
812-
Constraint::Min(1), // Gauge fills remaining
819+
Constraint::Length(filter_sort_width as u16), // Filter/Sort with padding
820+
Constraint::Min(1), // Gauge fills remaining
813821
Constraint::Length(count_text.len() as u16 + 1), // +1 for padding
814822
])
815823
.split(inner);
@@ -819,7 +827,10 @@ fn render_progress_header(
819827
Span::styled(" Filter:", Style::default().fg(Color::DarkGray)),
820828
Span::styled(filter_label, Style::default().fg(Color::Cyan)),
821829
Span::styled(" Sort:", Style::default().fg(Color::DarkGray)),
822-
Span::styled(format!("{} ", sort_label), Style::default().fg(Color::Yellow)),
830+
Span::styled(
831+
format!("{} ", sort_label),
832+
Style::default().fg(Color::Yellow),
833+
),
823834
]));
824835
frame.render_widget(filter_sort, chunks[0]);
825836

crates/charmer-monitor/src/components/log_viewer.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -265,8 +265,7 @@ impl LogViewer {
265265
// Render scrollbar for panel if content exceeds viewport
266266
if state.lines.len() > content_height {
267267
let scroll_pos = state.lines.len().saturating_sub(content_height);
268-
let mut scrollbar_state =
269-
ScrollbarState::new(state.lines.len()).position(scroll_pos);
268+
let mut scrollbar_state = ScrollbarState::new(state.lines.len()).position(scroll_pos);
270269

271270
let scrollbar = Scrollbar::new(ScrollbarOrientation::VerticalRight)
272271
.begin_symbol(Some("↑"))

crates/charmer-monitor/src/components/rule_summary.rs

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@ use ratatui::{
77
layout::{Constraint, Rect},
88
style::{Color, Modifier, Style},
99
text::Span,
10-
widgets::{Block, Borders, Row, Scrollbar, ScrollbarOrientation, ScrollbarState, Table, TableState},
10+
widgets::{
11+
Block, Borders, Row, Scrollbar, ScrollbarOrientation, ScrollbarState, Table, TableState,
12+
},
1113
Frame,
1214
};
1315

@@ -197,11 +199,7 @@ impl RuleSummary {
197199
],
198200
)
199201
.header(header)
200-
.block(
201-
Block::default()
202-
.borders(Borders::ALL)
203-
.title(title),
204-
)
202+
.block(Block::default().borders(Borders::ALL).title(title))
205203
// Text emphasis only, no background - matches job list
206204
.row_highlight_style(Style::default().add_modifier(Modifier::BOLD));
207205

0 commit comments

Comments
 (0)