refactor: remove query parameter from hud url

This commit is contained in:
ByteAtATime 2025-06-22 19:17:28 -07:00
parent 223f7960aa
commit 79b88ad5f6
No known key found for this signature in database

View file

@ -58,10 +58,9 @@ fn get_selected_text() -> String {
#[tauri::command] #[tauri::command]
async fn show_hud(app: tauri::AppHandle, title: String) -> Result<(), String> { async fn show_hud(app: tauri::AppHandle, title: String) -> Result<(), String> {
let url = format!("/hud?title={}", title);
let hud_window = match app.get_webview_window("hud") { let hud_window = match app.get_webview_window("hud") {
Some(window) => window, Some(window) => window,
None => tauri::WebviewWindowBuilder::new(&app, "hud", tauri::WebviewUrl::App(url.into())) None => tauri::WebviewWindowBuilder::new(&app, "hud", tauri::WebviewUrl::App("/hud".into()))
.decorations(false) .decorations(false)
.transparent(true) .transparent(true)
.always_on_top(true) .always_on_top(true)