| 1 | //! Color theme constants for HyprKVM GUI |
| 2 | |
| 3 | #![allow(dead_code)] |
| 4 | |
| 5 | use iced::Color; |
| 6 | |
| 7 | /// Warm off-white background |
| 8 | pub const BACKGROUND: Color = Color::from_rgb(0.961, 0.949, 0.941); // #F5F2F0 |
| 9 | |
| 10 | /// Rich purple for neighbor machines |
| 11 | pub const MACHINE_NEIGHBOR: Color = Color::from_rgb(0.549, 0.361, 0.820); // #8C5CD1 |
| 12 | |
| 13 | /// Darker purple for self machine |
| 14 | pub const MACHINE_SELF: Color = Color::from_rgb(0.439, 0.220, 0.722); // #7038B8 |
| 15 | |
| 16 | /// Green for connected status |
| 17 | pub const STATUS_CONNECTED: Color = Color::from_rgb(0.302, 0.690, 0.310); // #4DB04F |
| 18 | |
| 19 | /// Amber for connecting status |
| 20 | pub const STATUS_CONNECTING: Color = Color::from_rgb(1.0, 0.761, 0.031); // #FFC208 |
| 21 | |
| 22 | /// Red for disconnected status |
| 23 | pub const STATUS_DISCONNECTED: Color = Color::from_rgb(0.914, 0.302, 0.239); // #E94D3D |
| 24 | |
| 25 | /// Snap highlight (purple at 30% opacity) |
| 26 | pub const SNAP_HIGHLIGHT: Color = Color::from_rgba(0.549, 0.361, 0.820, 0.3); |
| 27 | |
| 28 | /// Text color (dark gray) |
| 29 | pub const TEXT_PRIMARY: Color = Color::from_rgb(0.2, 0.2, 0.2); |
| 30 | |
| 31 | /// Text color (light, for on purple backgrounds) |
| 32 | pub const TEXT_LIGHT: Color = Color::from_rgb(1.0, 1.0, 1.0); |
| 33 | |
| 34 | /// Grid line color (light gray) |
| 35 | pub const GRID_LINE: Color = Color::from_rgba(0.6, 0.6, 0.6, 0.3); |
| 36 | |
| 37 | /// Machine rectangle dimensions |
| 38 | pub const MACHINE_WIDTH: f32 = 160.0; |
| 39 | pub const MACHINE_HEIGHT: f32 = 100.0; |
| 40 | |
| 41 | /// Gap between machines (same in both directions for equidistant spacing) |
| 42 | pub const MACHINE_GAP: f32 = 24.0; |
| 43 | |
| 44 | /// Grid cell spacing (horizontal: width + gap, vertical: height + gap) |
| 45 | pub const GRID_SPACING_H: f32 = MACHINE_WIDTH + MACHINE_GAP; // 184 |
| 46 | pub const GRID_SPACING_V: f32 = MACHINE_HEIGHT + MACHINE_GAP; // 124 |
| 47 | |
| 48 | /// Snap radius for drag operations |
| 49 | pub const SNAP_RADIUS: f32 = 50.0; |
| 50 | |
| 51 | /// Connection dot radius |
| 52 | pub const CONNECTION_DOT_RADIUS: f32 = 4.0; |
| 53 | |
| 54 | /// Connection dot color (subtle gray) |
| 55 | pub const CONNECTION_DOT: Color = Color::from_rgba(0.5, 0.5, 0.5, 0.5); |
| 56 |