mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-03-18 23:44:12 +01:00
14 lines
446 B
Rust
14 lines
446 B
Rust
use crate::error::Result;
|
|
use crate::sync::{apply_sync, calculate_sync, SyncOp};
|
|
use tauri::{command, Runtime, WebviewWindow};
|
|
|
|
#[command]
|
|
pub async fn apply<R: Runtime>(window: WebviewWindow<R>, workspace_id: &str) -> Result<()> {
|
|
apply_sync(&window, workspace_id).await
|
|
}
|
|
|
|
#[command]
|
|
pub async fn calculate<R: Runtime>(window: WebviewWindow<R>, workspace_id: &str) -> Result<Vec<SyncOp>> {
|
|
calculate_sync(&window, workspace_id).await
|
|
}
|