An eframe/egui page compiled to WebAssembly with trunk. It draws the one View the server sends: controls on top, three big figures, six cards, and the collapsible sections Problems, Where compiles went, Over time, Speed, Extras and Raw counters. The range, refresh interval and theme are remembered between visits with eframe storage. mise.toml names trunk 0.22.2 as the build tool.
44 lines
1.1 KiB
TOML
44 lines
1.1 KiB
TOML
[package]
|
|
name = "sccache-dash-ui"
|
|
description = "Dashboard page for sccache-dash"
|
|
version.workspace = true
|
|
edition.workspace = true
|
|
license.workspace = true
|
|
|
|
[dependencies]
|
|
sccache-dash-api = { path = "../api" }
|
|
|
|
egui_plot = "0.38"
|
|
ehttp = "0.7"
|
|
|
|
serde = { version = "1", features = ["derive"] }
|
|
serde_json = "1"
|
|
|
|
# The page is drawn with eframe, in the browser for now. A native window would open the same `Dashboard`.
|
|
[target.'cfg(target_arch = "wasm32")'.dependencies]
|
|
eframe = { version = "0.37", default-features = false, features = [
|
|
"default_fonts",
|
|
"glow",
|
|
"persistence",
|
|
] }
|
|
wasm-bindgen = "0.2"
|
|
wasm-bindgen-futures = "0.4"
|
|
js-sys = "0.3"
|
|
web-sys = { version = "0.3", features = [
|
|
"Document",
|
|
"Element",
|
|
"HtmlAnchorElement",
|
|
"HtmlCanvasElement",
|
|
"Window",
|
|
] }
|
|
|
|
# Native builds only run the tests so far; x11 and wayland are what lets eframe build there.
|
|
[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
|
|
eframe = { version = "0.37", default-features = false, features = [
|
|
"default_fonts",
|
|
"glow",
|
|
"persistence",
|
|
"wayland",
|
|
"x11",
|
|
] }
|