diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml
index 9a9eac2..6fd96aa 100644
--- a/.github/workflows/ci.yaml
+++ b/.github/workflows/ci.yaml
@@ -61,8 +61,60 @@ jobs:
- name: Run leptosfmt --check
run: leptosfmt --check src
+ rustfmt:
+ name: cargo fmt --check
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v4
+
+ - name: Install stable Rust
+ uses: dtolnay/rust-toolchain@stable
+ with:
+ components: rustfmt
+
+ - name: Run cargo fmt --check
+ run: cargo fmt --all -- --check
+
+ clippy:
+ name: cargo clippy
+ runs-on: ubuntu-latest
+ timeout-minutes: 15
+ steps:
+ - uses: actions/checkout@v4
+
+ - name: Install nightly Rust
+ uses: dtolnay/rust-toolchain@nightly
+ with:
+ targets: wasm32-unknown-unknown
+ components: clippy
+
+ - name: Cache cargo registry and target
+ uses: Swatinem/rust-cache@v2
+ with:
+ key: clippy
+
+ - name: Run cargo clippy
+ run: cargo clippy --target wasm32-unknown-unknown --all-targets --no-deps -- -D warnings
+
+ test:
+ name: cargo test
+ runs-on: ubuntu-latest
+ timeout-minutes: 15
+ steps:
+ - uses: actions/checkout@v4
+
+ - name: Install stable Rust
+ uses: dtolnay/rust-toolchain@stable
+
+ - name: Cache cargo registry and target
+ uses: Swatinem/rust-cache@v2
+ with:
+ key: test
+
+ - name: Run cargo test
+ run: cargo test --all-targets --no-fail-fast
+
build:
- name: Trunk build
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
diff --git a/Cargo.lock b/Cargo.lock
index 96d6379..95994bb 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -984,6 +984,7 @@ dependencies = [
"leptos",
"leptos_meta",
"leptos_router",
+ "serde_json",
"wasm-bindgen",
"web-sys",
]
diff --git a/Cargo.toml b/Cargo.toml
index da0833d..59b4cd9 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -11,5 +11,8 @@ leptos_router = "0.8.2"
wasm-bindgen = "0.2.100"
web-sys = { version = "0.3.77", features = ["Document", "Window", "console"] }
+[dev-dependencies]
+serde_json = "1"
+
[package.metadata.leptos]
assets-dir="public"
\ No newline at end of file
diff --git a/data/graphs/ec_links.json b/data/graphs/ec_links.json
new file mode 100644
index 0000000..67958da
--- /dev/null
+++ b/data/graphs/ec_links.json
@@ -0,0 +1,16 @@
+[
+ {"source": 0, "target": 2}, {"source": 0, "target": 4}, {"source": 0, "target": 5}, {"source": 0, "target": 6},
+ {"source": 0, "target": 11}, {"source": 0, "target": 12}, {"source": 0, "target": 13}, {"source": 0, "target": 19},
+ {"source": 0, "target": 20}, {"source": 0, "target": 23}, {"source": 1, "target": 4}, {"source": 2, "target": 43},
+ {"source": 3, "target": 17}, {"source": 3, "target": 18}, {"source": 4, "target": 3}, {"source": 4, "target": 26},
+ {"source": 4, "target": 36}, {"source": 5, "target": 3}, {"source": 5, "target": 26}, {"source": 5, "target": 36},
+ {"source": 6, "target": 4}, {"source": 7, "target": 4}, {"source": 8, "target": 4}, {"source": 9, "target": 4},
+ {"source": 11, "target": 8}, {"source": 11, "target": 39}, {"source": 12, "target": 4}, {"source": 12, "target": 19},
+ {"source": 13, "target": 14}, {"source": 13, "target": 15}, {"source": 13, "target": 21}, {"source": 13, "target": 28},
+ {"source": 13, "target": 29}, {"source": 13, "target": 40}, {"source": 13, "target": 42}, {"source": 14, "target": 4},
+ {"source": 15, "target": 4}, {"source": 16, "target": 22}, {"source": 20, "target": 4}, {"source": 21, "target": 4},
+ {"source": 23, "target": 9}, {"source": 25, "target": 0}, {"source": 26, "target": 10}, {"source": 28, "target": 4},
+ {"source": 29, "target": 4}, {"source": 30, "target": 5}, {"source": 31, "target": 5}, {"source": 33, "target": 4},
+ {"source": 36, "target": 32}, {"source": 36, "target": 37}, {"source": 39, "target": 4}, {"source": 40, "target": 4},
+ {"source": 41, "target": 4}, {"source": 42, "target": 4}, {"source": 43, "target": 30}, {"source": 43, "target": 31}
+]
diff --git a/data/graphs/ec_nodes.json b/data/graphs/ec_nodes.json
new file mode 100644
index 0000000..fcd17e8
--- /dev/null
+++ b/data/graphs/ec_nodes.json
@@ -0,0 +1,46 @@
+[
+ {"id": 0, "name": "embedded-services", "url": "https://github.com/OpenDevicePartnership/embedded-services", "classification": "EC Services", "order": 2},
+ {"id": 1, "name": "pcal6416a", "url": "https://github.com/OpenDevicePartnership/pcal6416a", "classification": "Driver", "order": 4},
+ {"id": 2, "name": "embedded-cfu", "url": "https://github.com/OpenDevicePartnership/embedded-cfu", "classification": "EC Subsystem", "order": 3},
+ {"id": 3, "name": "embassy-imxrt", "url": "https://github.com/OpenDevicePartnership/embassy-imxrt", "classification": "MCU HAL", "order": 6},
+ {"id": 4, "name": "embedded-hal", "url": "https://github.com/rust-embedded/embedded-hal", "classification": "HAL Abstractions", "order": 5},
+ {"id": 5, "name": "embedded-mcu", "url": "https://github.com/OpenDevicePartnership/embedded-mcu", "classification": "HAL Abstractions", "order": 5},
+ {"id": 6, "name": "embedded-fans", "url": "https://github.com/OpenDevicePartnership/embedded-fans", "classification": "EC Subsystem", "order": 3},
+ {"id": 7, "name": "lis2dw12-i2c", "url": "https://github.com/OpenDevicePartnership/lis2dw12-i2c", "classification": "Driver", "order": 4},
+ {"id": 8, "name": "tps6699x", "url": "https://github.com/OpenDevicePartnership/tps6699x", "classification": "Driver", "order": 4},
+ {"id": 9, "name": "tmp108", "url": "https://github.com/OpenDevicePartnership/tmp108", "classification": "Driver", "order": 4},
+ {"id": 10, "name": "npcx490m-pac", "url": "https://github.com/OpenDevicePartnership/npcx490m-pac", "classification": "MCU PAC", "order": 7},
+ {"id": 11, "name": "embedded-usb-pd", "url": "https://github.com/OpenDevicePartnership/embedded-usb-pd", "classification": "EC Subsystem", "order": 3},
+ {"id": 12, "name": "embedded-power-sequence", "url": "https://github.com/OpenDevicePartnership/embedded-power-sequence", "classification": "EC Subsystem", "order": 3},
+ {"id": 13, "name": "embedded-batteries", "url": "https://github.com/OpenDevicePartnership/embedded-batteries", "classification": "EC Subsystem", "order": 3},
+ {"id": 14, "name": "bq25773", "url": "https://github.com/OpenDevicePartnership/bq25773", "classification": "Driver", "order": 4},
+ {"id": 15, "name": "bq40z50", "url": "https://github.com/OpenDevicePartnership/bq40z50", "classification": "Driver", "order": 4},
+ {"id": 16, "name": "ec-slimloader", "url": "https://github.com/OpenDevicePartnership/ec-slimloader", "classification": "Bootloader", "order": 8},
+ {"id": 17, "name": "mimxrt633s-pac", "url": "https://github.com/OpenDevicePartnership/mimxrt633s-pac", "classification": "MCU PAC", "order": 7},
+ {"id": 18, "name": "mimxrt685s-pac", "url": "https://github.com/OpenDevicePartnership/mimxrt685s-pac", "classification": "MCU PAC", "order": 7},
+ {"id": 19, "name": "embedded-regulator", "url": "https://github.com/OpenDevicePartnership/embedded-regulator", "classification": "EC Subsystem", "order": 3},
+ {"id": 20, "name": "embedded-keyboard-rs", "url": "https://github.com/OpenDevicePartnership/embedded-keyboard-rs", "classification": "EC Subsystem", "order": 3},
+ {"id": 21, "name": "bq25770g", "url": "https://github.com/OpenDevicePartnership/bq25770g", "classification": "Driver", "order": 4},
+ {"id": 22, "name": "ec-slimloader-descriptors", "url": "https://github.com/OpenDevicePartnership/ec-slimloader-descriptors", "classification": "Bootloader", "order": 8},
+ {"id": 23, "name": "embedded-sensors", "url": "https://github.com/OpenDevicePartnership/embedded-sensors", "classification": "EC Subsystem", "order": 3},
+ {"id": 24, "name": "mimxrt600-fcb", "url": "https://github.com/OpenDevicePartnership/mimxrt600-fcb", "classification": "Tools", "order": 9},
+ {"id": 25, "name": "soc-embedded-controller", "url": "https://github.com/OpenDevicePartnership/soc-embedded-controller", "classification": "EC Platform", "order": 1},
+ {"id": 26, "name": "embassy-npcx", "url": "https://github.com/OpenDevicePartnership/embassy-npcx", "classification": "MCU HAL", "order": 6},
+ {"id": 27, "name": "systemview-tracing", "url": "https://github.com/OpenDevicePartnership/systemview-tracing", "classification": "Tools", "order": 9},
+ {"id": 28, "name": "bq25723", "url": "https://github.com/OpenDevicePartnership/bq25723", "classification": "Driver", "order": 4},
+ {"id": 29, "name": "bq25713", "url": "https://github.com/OpenDevicePartnership/bq25713", "classification": "Driver", "order": 4},
+ {"id": 30, "name": "MX25U1632FZUI02", "url": "https://github.com/OpenDevicePartnership/MX25U1632FZUI02", "classification": "Driver", "order": 4},
+ {"id": 31, "name": "W25Q16JWXHIM", "url": "https://github.com/OpenDevicePartnership/W25Q16JWXHIM", "classification": "Driver", "order": 4},
+ {"id": 32, "name": "mec17xx-pac", "url": "https://github.com/OpenDevicePartnership/mec17xx-pac", "classification": "MCU PAC", "order": 7},
+ {"id": 33, "name": "is31fl3743b", "url": "https://github.com/OpenDevicePartnership/is31fl3743b", "classification": "Driver", "order": 4},
+ {"id": 34, "name": "npcx490m-examples", "url": "https://github.com/OpenDevicePartnership/npcx490m-examples", "classification": "Tools", "order": 9},
+ {"id": 35, "name": "mimxrt685s-examples", "url": "https://github.com/OpenDevicePartnership/mimxrt685s-examples", "classification": "Tools", "order": 9},
+ {"id": 36, "name": "embassy-microchip", "url": "https://github.com/OpenDevicePartnership/embassy-microchip", "classification": "MCU HAL", "order": 6},
+ {"id": 37, "name": "cec17-data", "url": "https://github.com/OpenDevicePartnership/cec17-data", "classification": "MCU PAC", "order": 7},
+ {"id": 38, "name": "nxp-header", "url": "https://github.com/OpenDevicePartnership/nxp-header", "classification": "Tools", "order": 9},
+ {"id": 39, "name": "tps65994ae", "url": "https://github.com/OpenDevicePartnership/tps65994ae", "classification": "Driver", "order": 4},
+ {"id": 40, "name": "bq24773", "url": "https://github.com/OpenDevicePartnership/bq24773", "classification": "Driver", "order": 4},
+ {"id": 41, "name": "rt4531", "url": "https://github.com/OpenDevicePartnership/rt4531", "classification": "Driver", "order": 4},
+ {"id": 42, "name": "bq25730", "url": "https://github.com/OpenDevicePartnership/bq25730", "classification": "Driver", "order": 4},
+ {"id": 43, "name": "embedded-storage", "url": "https://github.com/rust-embedded-community/embedded-storage", "classification": " EC Subsystem", "order": 3}
+]
diff --git a/data/graphs/ec_services_links.json b/data/graphs/ec_services_links.json
new file mode 100644
index 0000000..6745478
--- /dev/null
+++ b/data/graphs/ec_services_links.json
@@ -0,0 +1,4 @@
+[
+ {"source": 0, "target": 1},
+ {"source": 1, "target": 2}
+]
diff --git a/data/graphs/ec_services_nodes.json b/data/graphs/ec_services_nodes.json
new file mode 100644
index 0000000..334c95a
--- /dev/null
+++ b/data/graphs/ec_services_nodes.json
@@ -0,0 +1,5 @@
+[
+ {"id": 0, "name": "ec-test-app", "url": "https://github.com/OpenDevicePartnership/ec-test-app", "classification": "app & driver", "order": 1},
+ {"id": 1, "name": "haf-ec-service", "url": "https://github.com/OpenDevicePartnership/haf-ec-service", "classification": "secure partition", "order": 2},
+ {"id": 2, "name": "ffa", "url": "https://github.com/OpenDevicePartnership/ffa", "classification": "ff-a", "order": 3}
+]
diff --git a/data/graphs/patina_links.json b/data/graphs/patina_links.json
new file mode 100644
index 0000000..253a48d
--- /dev/null
+++ b/data/graphs/patina_links.json
@@ -0,0 +1,17 @@
+[
+ {"source": 0, "target": 5},
+ {"source": 0, "target": 7},
+ {"source": 3, "target": 4},
+ {"source": 3, "target": 5},
+ {"source": 3, "target": 6},
+ {"source": 3, "target": 7},
+ {"source": 4, "target": 5},
+ {"source": 4, "target": 6},
+ {"source": 4, "target": 7},
+ {"source": 4, "target": 8},
+ {"source": 4, "target": 9},
+ {"source": 5, "target": 6},
+ {"source": 5, "target": 7},
+ {"source": 5, "target": 9},
+ {"source": 6, "target": 7}
+]
diff --git a/data/graphs/patina_nodes.json b/data/graphs/patina_nodes.json
new file mode 100644
index 0000000..1c6d166
--- /dev/null
+++ b/data/graphs/patina_nodes.json
@@ -0,0 +1,12 @@
+[
+ {"id": 0, "name": "patina-readiness-tool", "url": "https://github.com/OpenDevicePartnership/patina-readiness-tool", "classification": "tooling", "order": 1},
+ {"id": 1, "name": "patina-fw-patcher", "url": "https://github.com/OpenDevicePartnership/patina-fw-patcher", "classification": "tooling", "order": 1},
+ {"id": 2, "name": "patina-qemu", "url": "https://github.com/OpenDevicePartnership/patina-qemu", "classification": "platform firmware (uefi rom)", "order": 2},
+ {"id": 3, "name": "patina-dxe-core-qemu", "url": "https://github.com/OpenDevicePartnership/patina-dxe-core-qemu", "classification": "qemu patina dxe core (binary)", "order": 3},
+ {"id": 4, "name": "patina (patina_dxe_core)", "url": "https://github.com/OpenDevicePartnership/patina", "classification": "patina dxe core (library)", "order": 4},
+ {"id": 5, "name": "patina (core)", "url": "https://github.com/OpenDevicePartnership/patina", "classification": "core (library)", "order": 5},
+ {"id": 6, "name": "patina (components)", "url": "https://github.com/OpenDevicePartnership/patina", "classification": "components (library)", "order": 6},
+ {"id": 7, "name": "patina (sdk)", "url": "https://github.com/OpenDevicePartnership/patina", "classification": "sdk (library)", "order": 7},
+ {"id": 8, "name": "patina-mtrr", "url": "https://github.com/OpenDevicePartnership/patina-mtrr", "classification": "general purpose (library)", "order": 8},
+ {"id": 9, "name": "patina-paging", "url": "https://github.com/OpenDevicePartnership/patina-paging", "classification": "general purpose (library)", "order": 8}
+]
diff --git a/index.html b/index.html
index d7c7b7b..61562ff 100644
--- a/index.html
+++ b/index.html
@@ -5,8 +5,17 @@
-
+
+
+
+
+
+
+
+
diff --git a/public/repo_graph.js b/public/repo_graph.js
new file mode 100644
index 0000000..e69957b
--- /dev/null
+++ b/public/repo_graph.js
@@ -0,0 +1,226 @@
+// Repository graph rendered with D3 v7. The Rust component
+// `RepositoryGraph` (src/components/repo_view.rs) sets
+// `window.__odpGraphData = { nodes, links }` and then loads this file
+// once per session. Each call to `window.__odpRenderGraph()` clears
+// the existing