Skip to content

Commit

Permalink
dump title label
Browse files Browse the repository at this point in the history
  • Loading branch information
Chleba committed Apr 22, 2024
1 parent afc3fc2 commit d657354
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 8 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "netscanner"
version = "0.4.3"
version = "0.4.4"
edition = "2021"
description = "Network Scanner"
license = "MIT"
Expand Down
21 changes: 15 additions & 6 deletions src/components/packetdump.rs
Original file line number Diff line number Diff line change
Expand Up @@ -762,11 +762,20 @@ impl PacketDump {
Paragraph::new(text).block(
Block::default()
.borders(Borders::ALL)
// .title("|WiFi Interface|")
.border_style(Style::default().fg(Color::Rgb(100, 100, 100)))
// .border_type(BorderType::Rounded)
// .title_style(Style::default().fg(Color::Yellow))
// .title_alignment(Alignment::Right),
.title(
ratatui::widgets::block::Title::from(Line::from(vec![
Span::raw("|"),
Span::styled(
"d",
Style::default().add_modifier(Modifier::BOLD).fg(Color::Red),
),
Span::styled("ump", Style::default().fg(Color::Yellow)),
Span::raw("|"),
]))
.alignment(Alignment::Right)
.position(ratatui::widgets::block::Position::Bottom),
)
)
}

Expand Down Expand Up @@ -946,9 +955,9 @@ impl Component for PacketDump {
// -- STATE TOAST
let toast = self.make_state_toast();
let toast_react = Rect::new(
table_rect.width - 13,
table_rect.width - 14,
table_rect.y + 1,
12,
13,
3,
);
f.render_widget(toast, toast_react);
Expand Down

0 comments on commit d657354

Please sign in to comment.