Add rustfmt configuration and reformat code

- Document new Rust formatting standards in AGENTS, CODE_MAP, and
  PROGRESS.
- Add rustfmt.toml with style 2024, 2‑space indents, 100‑char width, LF
  endings.
- Apply consistent 2‑space indentation and ordering across source files.
- Minor clean‑up of imports and whitespace to match the new style.
This commit is contained in:
GarandPLG committed 2026-10-19 12:21:20 +02:00
1 parent 9e09aaf75e
commit c4313b4117
60 files changed
+3632 -3610

No files matched your search

+15 -15
View File
@@ -1,27 +1,27 @@
use crate::app::{
App,
views::{default_view, main_menu_view, skirmish_view},
App,
views::{default_view, main_menu_view, skirmish_view},
};
use clap::ValueEnum;
use ratatui::{buffer::Buffer, layout::Rect, widgets::Widget};
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, ValueEnum)]
pub enum View {
MainMenu,
Skirmish,
PerkDecks,
SkillsConfig,
MainMenu,
Skirmish,
PerkDecks,
SkillsConfig,
}
impl Widget for &mut App {
fn render(self, area: Rect, buf: &mut Buffer)
where
Self: Sized,
{
match self.view {
View::MainMenu => main_menu_view(self, area, buf),
View::Skirmish => skirmish_view(self, area, buf),
_ => default_view(area, buf),
}
fn render(self, area: Rect, buf: &mut Buffer)
where
Self: Sized,
{
match self.view {
View::MainMenu => main_menu_view(self, area, buf),
View::Skirmish => skirmish_view(self, area, buf),
_ => default_view(area, buf),
}
}
}