dashboard: remove the state-file endpoint, the file_refs path scan and the unused marked and dompurify deps
This commit is contained in:
parent
0f7b403803
commit
6d080ea28b
11 changed files with 12 additions and 419 deletions
|
|
@ -14,12 +14,6 @@ use chrono::{DateTime, Utc};
|
|||
#[serde(rename_all = "snake_case", tag = "kind")]
|
||||
pub enum DashboardEvent {
|
||||
/// Broker `Sent` event mirrored onto the dashboard channel.
|
||||
/// `file_refs` carries every path-shaped token in `body` that
|
||||
/// hive-c0re verified is a regular file under the allow-listed
|
||||
/// roots (per-agent `state/` + `shared/`). The forwarder
|
||||
/// pre-validates so the dashboard doesn't need a probe
|
||||
/// endpoint — the client renders anchors only for tokens that
|
||||
/// appear in this list, everything else stays plain text.
|
||||
Sent {
|
||||
seq: u64,
|
||||
/// Broker row id. Allows the dashboard to track reply threads.
|
||||
|
|
@ -30,11 +24,8 @@ pub enum DashboardEvent {
|
|||
at: DateTime<Utc>,
|
||||
#[serde(default, skip_serializing_if = "Option::is_none")]
|
||||
in_reply_to: Option<i64>,
|
||||
#[serde(default, skip_serializing_if = "Vec::is_empty")]
|
||||
file_refs: Vec<String>,
|
||||
},
|
||||
/// Broker `Delivered` event mirrored onto the dashboard channel.
|
||||
/// `file_refs` is the same shape as `Sent`.
|
||||
Delivered {
|
||||
seq: u64,
|
||||
/// Broker row id. Allows the dashboard to track reply threads.
|
||||
|
|
@ -45,8 +36,6 @@ pub enum DashboardEvent {
|
|||
at: DateTime<Utc>,
|
||||
#[serde(default, skip_serializing_if = "Option::is_none")]
|
||||
in_reply_to: Option<i64>,
|
||||
#[serde(default, skip_serializing_if = "Vec::is_empty")]
|
||||
file_refs: Vec<String>,
|
||||
},
|
||||
/// A lifecycle action started for an agent (spawn / start / stop
|
||||
/// / restart / rebuild / destroy). Clients render a spinner next
|
||||
|
|
@ -201,7 +190,6 @@ mod tests {
|
|||
body: String::new(),
|
||||
at: hive_sh4re::wire_time::from_secs(0),
|
||||
in_reply_to: None,
|
||||
file_refs: Vec::new(),
|
||||
},
|
||||
DashboardEvent::Delivered {
|
||||
seq: 1,
|
||||
|
|
@ -211,7 +199,6 @@ mod tests {
|
|||
body: String::new(),
|
||||
at: hive_sh4re::wire_time::from_secs(0),
|
||||
in_reply_to: None,
|
||||
file_refs: Vec::new(),
|
||||
},
|
||||
DashboardEvent::TransientSet {
|
||||
seq: 1,
|
||||
|
|
|
|||
Loading…
Reference in a new issue