Implement chat and markdown views, enhance status bar, and add workflow panel
- Added `chat.rs` for rendering chat messages with timestamps and roles. - Introduced `markdown.rs` for rendering markdown content with styling. - Created `status.rs` to display the application status bar with session and message counts. - Developed `workflow.rs` to show the current workflow status, including tool calls and active jobs. - Established a `theme.rs` for centralized color management across the UI. - Updated `mod.rs` to include new modules and manage rendering logic.
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
use std::path::Path;
|
||||
use anyhow::Result;
|
||||
|
||||
pub fn install_security_sidecar(target_dir: &Path) -> Result<()> {
|
||||
let bin_path = target_dir.join("zesdex-security-daemon");
|
||||
let current_exe = std::env::current_exe()?;
|
||||
std::fs::create_dir_all(target_dir)?;
|
||||
std::fs::copy(¤t_exe, &bin_path)?;
|
||||
Ok(())
|
||||
}
|
||||
|
||||
pub fn verify_sidecar(path: &Path) -> Result<bool> {
|
||||
if !path.exists() {
|
||||
return Ok(false);
|
||||
}
|
||||
let metadata = std::fs::metadata(path)?;
|
||||
Ok(metadata.is_file())
|
||||
}
|
||||
|
||||
pub fn remove_sidecar(path: &Path) -> Result<()> {
|
||||
if path.exists() {
|
||||
std::fs::remove_file(path)?;
|
||||
}
|
||||
Ok(())
|
||||
}
|
||||
|
||||
pub fn get_sidecar_path() -> std::path::PathBuf {
|
||||
let store = crate::model::store::Store::new();
|
||||
store.base_dir.join("bin").join("zesdex-security-daemon")
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
pub mod install;
|
||||
Reference in New Issue
Block a user