Skip to content

Commit 254c96c

Browse files
committed
docs: Update architecture diagram in README
- Add integrated GUI/CLI component visualization\n- Show SwiftUI view hierarchy and Objective-C bridge\n- Include status bar menu architecture details\n- Color-code component types for clarity\n- Remove outdated CLI tools section
1 parent 2a26468 commit 254c96c

File tree

1 file changed

+29
-12
lines changed

1 file changed

+29
-12
lines changed

README.md

Lines changed: 29 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -20,21 +20,38 @@ A comprehensive power monitoring solution for macOS featuring:
2020

2121
```mermaid
2222
graph TD
23-
A[Power Management Suite] --> B{GUI Application}
24-
A --> C{CLI Tools}
23+
Suite[Power Management Suite] --> GUI{GUI Application}
24+
Suite --> CLI{CLI Tools}
2525
26-
B --> D[PowerFlowView]
27-
B --> E[BatteryMonitor]
28-
B --> F[SystemStats]
26+
GUI --> App[appApp.swift]
27+
App --> CV[ContentView.swift]
28+
CV --> PFV[PowerFlowView.swift]
29+
CV --> BM[Battery.swift]
2930
30-
C --> G[power_info]
31-
C --> H[batt]
31+
BM --> OC[powerInfo.m Objective-C Bridge]
32+
OC --> SMC["SMC API (System Management Controller)"]
3233
33-
D --> I[SwiftUI Views]
34-
E --> J[IOKit Integration]
35-
F --> K[System Load Metrics]
36-
G --> L[SMC Access]
37-
H --> M[Battery Diagnostics]
34+
PFV --> SW["SwiftUI Graphics Pipeline"]
35+
App --> SM[StatusBar Menu]
36+
SM --> POP["Popover Window (NSHostingView)"]
37+
38+
CLI --> PI[power_info]
39+
CLI --> BAT[batt]
40+
PI --> SMC
41+
BAT --> UDS["Unix Domain Socket"]
42+
BM -.-> BAT
43+
44+
classDef swift fill:#F05138,color:white;
45+
classDef objc fill:#4381ff,color:white;
46+
classDef system fill:#666,color:white;
47+
classDef cli fill:#34a853,color:white;
48+
classDef suite fill:#8e44ad,color:white;
49+
50+
class Suite suite
51+
class App,CV,PFV,BM,SW,SM,POP swift
52+
class OC objc
53+
class SMC system
54+
class PI,BAT,CLI,UDS cli
3855
```
3956

4057
## Features

0 commit comments

Comments
 (0)