diff --git a/.changes/remove-global-shortcut.md b/.changes/remove-global-shortcut.md new file mode 100644 index 00000000000..07fac9925a2 --- /dev/null +++ b/.changes/remove-global-shortcut.md @@ -0,0 +1,8 @@ +--- +"api": patch +"tauri": patch +"tauri-runtime": patch +"tauri-runtime-wry": patch +--- + +Moved the `global-shortcut` feature to its own plugin in the plugins-workspace repository. diff --git a/core/tauri-runtime-wry/Cargo.toml b/core/tauri-runtime-wry/Cargo.toml index 2cdcc2b6293..401be437567 100644 --- a/core/tauri-runtime-wry/Cargo.toml +++ b/core/tauri-runtime-wry/Cargo.toml @@ -48,5 +48,4 @@ macos-private-api = [ "tauri-runtime/macos-private-api" ] objc-exception = [ "wry/objc-exception" ] -global-shortcut = [ "tauri-runtime/global-shortcut" ] linux-headers = [ "wry/linux-headers", "webkit2gtk/v2_36" ] diff --git a/core/tauri-runtime-wry/src/global_shortcut.rs b/core/tauri-runtime-wry/src/global_shortcut.rs deleted file mode 100644 index 17d30d29d46..00000000000 --- a/core/tauri-runtime-wry/src/global_shortcut.rs +++ /dev/null @@ -1,164 +0,0 @@ -// Copyright 2019-2023 Tauri Programme within The Commons Conservancy -// SPDX-License-Identifier: Apache-2.0 -// SPDX-License-Identifier: MIT - -//! Global shortcut implementation. - -use std::{ - collections::HashMap, - fmt, - sync::{ - mpsc::{channel, Sender}, - Arc, Mutex, - }, -}; - -use crate::{getter, Context, Message}; - -use tauri_runtime::{Error, GlobalShortcutManager, Result, UserEvent}; -#[cfg(desktop)] -pub use wry::application::{ - accelerator::{Accelerator, AcceleratorId}, - global_shortcut::{GlobalShortcut, ShortcutManager as WryShortcutManager}, -}; - -pub type GlobalShortcutListeners = Arc>>>; - -#[derive(Debug, Clone)] -pub enum GlobalShortcutMessage { - IsRegistered(Accelerator, Sender), - Register(Accelerator, Sender>), - Unregister(GlobalShortcutWrapper, Sender>), - UnregisterAll(Sender>), -} - -#[derive(Debug, Clone)] -pub struct GlobalShortcutWrapper(GlobalShortcut); - -// SAFETY: usage outside of main thread is guarded, we use the event loop on such cases. -#[allow(clippy::non_send_fields_in_send_ty)] -unsafe impl Send for GlobalShortcutWrapper {} - -/// Wrapper around [`WryShortcutManager`]. -#[derive(Clone)] -pub struct GlobalShortcutManagerHandle { - pub context: Context, - pub shortcuts: Arc>>, - pub listeners: GlobalShortcutListeners, -} - -// SAFETY: this is safe since the `Context` usage is guarded on `send_user_message`. -#[allow(clippy::non_send_fields_in_send_ty)] -unsafe impl Sync for GlobalShortcutManagerHandle {} - -impl fmt::Debug for GlobalShortcutManagerHandle { - fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { - f.debug_struct("GlobalShortcutManagerHandle") - .field("context", &self.context) - .field("shortcuts", &self.shortcuts) - .finish() - } -} - -impl GlobalShortcutManager for GlobalShortcutManagerHandle { - fn is_registered(&self, accelerator: &str) -> Result { - let (tx, rx) = channel(); - getter!( - self, - rx, - Message::GlobalShortcut(GlobalShortcutMessage::IsRegistered( - accelerator.parse().expect("invalid accelerator"), - tx - )) - ) - } - - fn register(&mut self, accelerator: &str, handler: F) -> Result<()> { - let wry_accelerator: Accelerator = accelerator.parse().expect("invalid accelerator"); - let id = wry_accelerator.clone().id(); - let (tx, rx) = channel(); - let shortcut = getter!( - self, - rx, - Message::GlobalShortcut(GlobalShortcutMessage::Register(wry_accelerator, tx)) - )??; - - self.listeners.lock().unwrap().insert(id, Box::new(handler)); - self - .shortcuts - .lock() - .unwrap() - .insert(accelerator.into(), (id, shortcut)); - - Ok(()) - } - - fn unregister_all(&mut self) -> Result<()> { - let (tx, rx) = channel(); - getter!( - self, - rx, - Message::GlobalShortcut(GlobalShortcutMessage::UnregisterAll(tx)) - )??; - self.listeners.lock().unwrap().clear(); - self.shortcuts.lock().unwrap().clear(); - Ok(()) - } - - fn unregister(&mut self, accelerator: &str) -> Result<()> { - if let Some((accelerator_id, shortcut)) = self.shortcuts.lock().unwrap().remove(accelerator) { - let (tx, rx) = channel(); - getter!( - self, - rx, - Message::GlobalShortcut(GlobalShortcutMessage::Unregister(shortcut, tx)) - )??; - self.listeners.lock().unwrap().remove(&accelerator_id); - } - Ok(()) - } -} - -pub fn handle_global_shortcut_message( - message: GlobalShortcutMessage, - global_shortcut_manager: &Arc>, -) { - match message { - GlobalShortcutMessage::IsRegistered(accelerator, tx) => tx - .send( - global_shortcut_manager - .lock() - .unwrap() - .is_registered(&accelerator), - ) - .unwrap(), - GlobalShortcutMessage::Register(accelerator, tx) => tx - .send( - global_shortcut_manager - .lock() - .unwrap() - .register(accelerator) - .map(GlobalShortcutWrapper) - .map_err(|e| Error::GlobalShortcut(Box::new(e))), - ) - .unwrap(), - GlobalShortcutMessage::Unregister(shortcut, tx) => tx - .send( - global_shortcut_manager - .lock() - .unwrap() - .unregister(shortcut.0) - .map_err(|e| Error::GlobalShortcut(Box::new(e))), - ) - .unwrap(), - GlobalShortcutMessage::UnregisterAll(tx) => tx - .send( - global_shortcut_manager - .lock() - .unwrap() - .unregister_all() - .map_err(|e| Error::GlobalShortcut(Box::new(e))), - ) - .unwrap(), - } -} diff --git a/core/tauri-runtime-wry/src/lib.rs b/core/tauri-runtime-wry/src/lib.rs index a674bd13060..c80d6831bde 100644 --- a/core/tauri-runtime-wry/src/lib.rs +++ b/core/tauri-runtime-wry/src/lib.rs @@ -116,11 +116,6 @@ mod system_tray; #[cfg(all(desktop, feature = "system-tray"))] use system_tray::*; -#[cfg(all(desktop, feature = "global-shortcut"))] -mod global_shortcut; -#[cfg(all(desktop, feature = "global-shortcut"))] -use global_shortcut::*; - pub type WebContextStore = Arc, WebContext>>>; // window pub type WindowEventHandler = Box; @@ -169,8 +164,6 @@ pub(crate) fn send_user_message( message, UserMessageContext { webview_id_map: context.webview_id_map.clone(), - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager: context.main_thread.global_shortcut_manager.clone(), windows: context.main_thread.windows.clone(), #[cfg(all(desktop, feature = "system-tray"))] system_tray_manager: context.main_thread.system_tray_manager.clone(), @@ -243,8 +236,6 @@ impl Context { pub struct DispatcherMainThreadContext { pub window_target: EventLoopWindowTarget>, pub web_context: WebContextStore, - #[cfg(all(desktop, feature = "global-shortcut"))] - pub global_shortcut_manager: Arc>, pub windows: Arc>>, #[cfg(all(desktop, feature = "system-tray"))] system_tray_manager: SystemTrayManager, @@ -1166,8 +1157,6 @@ pub enum Message { Box (String, WryWindowBuilder) + Send>, Sender>>, ), - #[cfg(all(desktop, feature = "global-shortcut"))] - GlobalShortcut(GlobalShortcutMessage), UserEvent(T), } @@ -1177,8 +1166,6 @@ impl Clone for Message { Self::Webview(i, m) => Self::Webview(*i, m.clone()), #[cfg(all(desktop, feature = "system-tray"))] Self::Tray(i, m) => Self::Tray(*i, m.clone()), - #[cfg(all(desktop, feature = "global-shortcut"))] - Self::GlobalShortcut(m) => Self::GlobalShortcut(m.clone()), Self::UserEvent(t) => Self::UserEvent(t.clone()), _ => unimplemented!(), } @@ -1725,10 +1712,6 @@ pub trait Plugin { /// A Tauri [`Runtime`] wrapper around wry. pub struct Wry { context: Context, - - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager_handle: GlobalShortcutManagerHandle, - event_loop: EventLoop>, } @@ -1746,17 +1729,6 @@ impl fmt::Debug for Wry { &self.context.main_thread.system_tray_manager, ); - #[cfg(all(desktop, feature = "global-shortcut"))] - #[cfg(feature = "global-shortcut")] - d.field( - "global_shortcut_manager", - &self.context.main_thread.global_shortcut_manager, - ) - .field( - "global_shortcut_manager_handle", - &self.global_shortcut_manager_handle, - ); - d.finish() } } @@ -1905,9 +1877,6 @@ impl Wry { let main_thread_id = current_thread().id(); let web_context = WebContextStore::default(); - #[cfg(all(desktop, feature = "global-shortcut"))] - let global_shortcut_manager = Arc::new(Mutex::new(WryShortcutManager::new(&event_loop))); - let windows = Arc::new(RefCell::new(HashMap::default())); let webview_id_map = WebviewIdStore::default(); @@ -1921,8 +1890,6 @@ impl Wry { main_thread: DispatcherMainThreadContext { window_target: event_loop.deref().clone(), web_context, - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager, windows, #[cfg(all(desktop, feature = "system-tray"))] system_tray_manager, @@ -1930,19 +1897,8 @@ impl Wry { plugins: Default::default(), }; - #[cfg(all(desktop, feature = "global-shortcut"))] - let global_shortcut_manager_handle = GlobalShortcutManagerHandle { - context: context.clone(), - shortcuts: Default::default(), - listeners: Default::default(), - }; - Ok(Self { context, - - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager_handle, - event_loop, }) } @@ -1952,9 +1908,6 @@ impl Runtime for Wry { type Dispatcher = WryDispatcher; type Handle = WryHandle; - #[cfg(all(desktop, feature = "global-shortcut"))] - type GlobalShortcutManager = GlobalShortcutManagerHandle; - #[cfg(all(desktop, feature = "system-tray"))] type TrayHandler = SystemTrayHandle; @@ -1985,11 +1938,6 @@ impl Runtime for Wry { } } - #[cfg(all(desktop, feature = "global-shortcut"))] - fn global_shortcut_manager(&self) -> Self::GlobalShortcutManager { - self.global_shortcut_manager_handle.clone() - } - fn create_window(&self, pending: PendingWindow) -> Result> { let label = pending.label.clone(); let menu_ids = pending.menu_ids.clone(); @@ -2105,11 +2053,6 @@ impl Runtime for Wry { #[cfg(all(desktop, feature = "system-tray"))] let system_tray_manager = self.context.main_thread.system_tray_manager.clone(); - #[cfg(all(desktop, feature = "global-shortcut"))] - let global_shortcut_manager = self.context.main_thread.global_shortcut_manager.clone(); - #[cfg(all(desktop, feature = "global-shortcut"))] - let global_shortcut_manager_handle = self.global_shortcut_manager_handle.clone(); - let mut iteration = RunIteration::default(); let proxy = self.event_loop.create_proxy(); @@ -2132,10 +2075,6 @@ impl Runtime for Wry { callback: &mut callback, webview_id_map: webview_id_map.clone(), windows: windows.clone(), - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager: global_shortcut_manager.clone(), - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager_handle: &global_shortcut_manager_handle, #[cfg(all(desktop, feature = "system-tray"))] system_tray_manager: system_tray_manager.clone(), }, @@ -2154,10 +2093,6 @@ impl Runtime for Wry { callback: &mut callback, windows: windows.clone(), webview_id_map: webview_id_map.clone(), - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager: global_shortcut_manager.clone(), - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager_handle: &global_shortcut_manager_handle, #[cfg(all(desktop, feature = "system-tray"))] system_tray_manager: system_tray_manager.clone(), }, @@ -2177,11 +2112,6 @@ impl Runtime for Wry { #[cfg(all(desktop, feature = "system-tray"))] let system_tray_manager = self.context.main_thread.system_tray_manager; - #[cfg(all(desktop, feature = "global-shortcut"))] - let global_shortcut_manager = self.context.main_thread.global_shortcut_manager.clone(); - #[cfg(all(desktop, feature = "global-shortcut"))] - let global_shortcut_manager_handle = self.global_shortcut_manager_handle.clone(); - let proxy = self.event_loop.create_proxy(); self.event_loop.run(move |event, event_loop, control_flow| { @@ -2195,10 +2125,6 @@ impl Runtime for Wry { callback: &mut callback, webview_id_map: webview_id_map.clone(), windows: windows.clone(), - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager: global_shortcut_manager.clone(), - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager_handle: &global_shortcut_manager_handle, #[cfg(all(desktop, feature = "system-tray"))] system_tray_manager: system_tray_manager.clone(), }, @@ -2216,10 +2142,6 @@ impl Runtime for Wry { callback: &mut callback, webview_id_map: webview_id_map.clone(), windows: windows.clone(), - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager: global_shortcut_manager.clone(), - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager_handle: &global_shortcut_manager_handle, #[cfg(all(desktop, feature = "system-tray"))] system_tray_manager: system_tray_manager.clone(), }, @@ -2233,10 +2155,6 @@ pub struct EventLoopIterationContext<'a, T: UserEvent> { pub callback: &'a mut (dyn FnMut(RunEvent) + 'static), pub webview_id_map: WebviewIdStore, pub windows: Arc>>, - #[cfg(all(desktop, feature = "global-shortcut"))] - pub global_shortcut_manager: Arc>, - #[cfg(all(desktop, feature = "global-shortcut"))] - pub global_shortcut_manager_handle: &'a GlobalShortcutManagerHandle, #[cfg(all(desktop, feature = "system-tray"))] pub system_tray_manager: SystemTrayManager, } @@ -2244,8 +2162,6 @@ pub struct EventLoopIterationContext<'a, T: UserEvent> { struct UserMessageContext { windows: Arc>>, webview_id_map: WebviewIdStore, - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager: Arc>, #[cfg(all(desktop, feature = "system-tray"))] system_tray_manager: SystemTrayManager, } @@ -2258,8 +2174,6 @@ fn handle_user_message( ) -> RunIteration { let UserMessageContext { webview_id_map, - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager, windows, #[cfg(all(desktop, feature = "system-tray"))] system_tray_manager, @@ -2656,10 +2570,6 @@ fn handle_user_message( } } } - #[cfg(all(desktop, feature = "global-shortcut"))] - Message::GlobalShortcut(message) => { - handle_global_shortcut_message(message, &global_shortcut_manager) - } Message::UserEvent(_) => (), } @@ -2680,10 +2590,6 @@ fn handle_event_loop( callback, webview_id_map, windows, - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager, - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager_handle, #[cfg(all(desktop, feature = "system-tray"))] system_tray_manager, } = context; @@ -2708,14 +2614,6 @@ fn handle_event_loop( callback(RunEvent::Exit); } - #[cfg(all(desktop, feature = "global-shortcut"))] - Event::GlobalShortcutEvent(accelerator_id) => { - for (id, handler) in &*global_shortcut_manager_handle.listeners.lock().unwrap() { - if accelerator_id == *id { - handler(); - } - } - } Event::MenuEvent { window_id, menu_id, @@ -2921,8 +2819,6 @@ fn handle_event_loop( message, UserMessageContext { webview_id_map, - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager, windows, #[cfg(all(desktop, feature = "system-tray"))] system_tray_manager, diff --git a/core/tauri-runtime/Cargo.toml b/core/tauri-runtime/Cargo.toml index e68f87215f3..4e8fe445b42 100644 --- a/core/tauri-runtime/Cargo.toml +++ b/core/tauri-runtime/Cargo.toml @@ -51,4 +51,3 @@ jni = "0.20" devtools = [ ] system-tray = [ ] macos-private-api = [ ] -global-shortcut = [ ] diff --git a/core/tauri-runtime/src/lib.rs b/core/tauri-runtime/src/lib.rs index 170d5a03056..8631ea70b6f 100644 --- a/core/tauri-runtime/src/lib.rs +++ b/core/tauri-runtime/src/lib.rs @@ -248,10 +248,6 @@ pub enum Error { /// Failed to get monitor on window operation. #[error("failed to get monitor")] FailedToGetMonitor, - /// Global shortcut error. - #[cfg(all(desktop, feature = "global-shortcut"))] - #[error(transparent)] - GlobalShortcut(Box), #[error("Invalid header name: {0}")] InvalidHeaderName(#[from] InvalidHeaderName), #[error("Invalid header value: {0}")] @@ -415,22 +411,6 @@ pub trait RuntimeHandle: Debug + Clone + Send + Sync + Sized + 'st + 'static; } -/// A global shortcut manager. -#[cfg(all(desktop, feature = "global-shortcut"))] -pub trait GlobalShortcutManager: Debug + Clone + Send + Sync { - /// Whether the application has registered the given `accelerator`. - fn is_registered(&self, accelerator: &str) -> Result; - - /// Register a global shortcut of `accelerator`. - fn register(&mut self, accelerator: &str, handler: F) -> Result<()>; - - /// Unregister all accelerators registered by the manager instance. - fn unregister_all(&mut self) -> Result<()>; - - /// Unregister the provided `accelerator`. - fn unregister(&mut self, accelerator: &str) -> Result<()>; -} - pub trait EventLoopProxy: Debug + Clone + Send + Sync { fn send_event(&self, event: T) -> Result<()>; } @@ -441,9 +421,6 @@ pub trait Runtime: Debug + Sized + 'static { type Dispatcher: Dispatch; /// The runtime handle type. type Handle: RuntimeHandle; - /// The global shortcut manager type. - #[cfg(all(desktop, feature = "global-shortcut"))] - type GlobalShortcutManager: GlobalShortcutManager; /// The tray handler type. #[cfg(all(desktop, feature = "system-tray"))] type TrayHandler: menu::TrayHandle; @@ -464,10 +441,6 @@ pub trait Runtime: Debug + Sized + 'static { /// Gets a runtime handle. fn handle(&self) -> Self::Handle; - /// Gets the global shortcut manager. - #[cfg(all(desktop, feature = "global-shortcut"))] - fn global_shortcut_manager(&self) -> Self::GlobalShortcutManager; - /// Create a new webview window. fn create_window(&self, pending: PendingWindow) -> Result>; diff --git a/core/tauri/Cargo.toml b/core/tauri/Cargo.toml index 2f96014cda9..f8371d1f4cf 100644 --- a/core/tauri/Cargo.toml +++ b/core/tauri/Cargo.toml @@ -157,10 +157,6 @@ native-tls = [ "reqwest/native-tls" ] native-tls-vendored = [ "reqwest/native-tls-vendored" ] rustls-tls = [ "reqwest/rustls-tls" ] process-command-api = [ "shared_child", "os_pipe" ] -global-shortcut = [ - "tauri-runtime/global-shortcut", - "tauri-runtime-wry/global-shortcut" -] dialog = [ "rfd" ] notification = [ "notify-rust" ] system-tray = [ "tauri-runtime/system-tray", "tauri-runtime-wry/system-tray" ] @@ -216,7 +212,7 @@ fs-remove-dir = [ ] fs-remove-file = [ ] fs-rename-file = [ ] fs-write-file = [ ] -global-shortcut-all = [ "global-shortcut" ] +global-shortcut-all = [ ] http-all = [ "http-request" ] http-request = [ "http-api" ] notification-all = [ "notification", "dialog-ask" ] diff --git a/core/tauri/scripts/bundle.global.js b/core/tauri/scripts/bundle.global.js index 27e745a419c..57a8308e99a 100644 --- a/core/tauri/scripts/bundle.global.js +++ b/core/tauri/scripts/bundle.global.js @@ -1,7 +1,7 @@ -"use strict";var __TAURI_IIFE__=(()=>{var L=Object.defineProperty;var ae=Object.getOwnPropertyDescriptor;var oe=Object.getOwnPropertyNames;var le=Object.prototype.hasOwnProperty;var c=(n,e)=>{for(var t in e)L(n,t,{get:e[t],enumerable:!0})},ue=(n,e,t,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let s of oe(e))!le.call(n,s)&&s!==t&&L(n,s,{get:()=>e[s],enumerable:!(r=ae(e,s))||r.enumerable});return n};var de=n=>ue(L({},"__esModule",{value:!0}),n);var Ct={};c(Ct,{app:()=>k,dialog:()=>N,event:()=>F,globalShortcut:()=>z,http:()=>V,invoke:()=>Mt,notification:()=>q,os:()=>X,path:()=>G,process:()=>j,shell:()=>$,tauri:()=>R,updater:()=>K,window:()=>Z});var k={};c(k,{getName:()=>ge,getTauriVersion:()=>ye,getVersion:()=>pe,hide:()=>fe,show:()=>he});var R={};c(R,{convertFileSrc:()=>me,invoke:()=>l,transformCallback:()=>m});function ce(){return window.crypto.getRandomValues(new Uint32Array(1))[0]}function m(n,e=!1){let t=ce(),r=`_${t}`;return Object.defineProperty(window,r,{value:s=>(e&&Reflect.deleteProperty(window,r),n?.(s)),writable:!1,configurable:!0}),t}async function l(n,e={}){return new Promise((t,r)=>{let s=m(u=>{t(u),Reflect.deleteProperty(window,`_${a}`)},!0),a=m(u=>{r(u),Reflect.deleteProperty(window,`_${s}`)},!0);window.__TAURI_IPC__({cmd:n,callback:s,error:a,...e})})}function me(n,e="asset"){let t=encodeURIComponent(n);return navigator.userAgent.includes("Windows")?`https://${e}.localhost/${t}`:`${e}://localhost/${t}`}async function i(n){return l("tauri",n)}async function pe(){return i({__tauriModule:"App",message:{cmd:"getAppVersion"}})}async function ge(){return i({__tauriModule:"App",message:{cmd:"getAppName"}})}async function ye(){return i({__tauriModule:"App",message:{cmd:"getTauriVersion"}})}async function he(){return i({__tauriModule:"App",message:{cmd:"show"}})}async function fe(){return i({__tauriModule:"App",message:{cmd:"hide"}})}var N={};c(N,{ask:()=>we,confirm:()=>ve,message:()=>Pe,open:()=>be,save:()=>_e});async function be(n={}){return typeof n=="object"&&Object.freeze(n),i({__tauriModule:"Dialog",message:{cmd:"openDialog",options:n}})}async function _e(n={}){return typeof n=="object"&&Object.freeze(n),i({__tauriModule:"Dialog",message:{cmd:"saveDialog",options:n}})}async function Pe(n,e){let t=typeof e=="string"?{title:e}:e;return i({__tauriModule:"Dialog",message:{cmd:"messageDialog",message:n.toString(),title:t?.title?.toString(),type:t?.type,buttonLabel:t?.okLabel?.toString()}})}async function we(n,e){let t=typeof e=="string"?{title:e}:e;return i({__tauriModule:"Dialog",message:{cmd:"askDialog",message:n.toString(),title:t?.title?.toString(),type:t?.type,buttonLabels:[t?.okLabel?.toString()??"Yes",t?.cancelLabel?.toString()??"No"]}})}async function ve(n,e){let t=typeof e=="string"?{title:e}:e;return i({__tauriModule:"Dialog",message:{cmd:"confirmDialog",message:n.toString(),title:t?.title?.toString(),type:t?.type,buttonLabels:[t?.okLabel?.toString()??"Ok",t?.cancelLabel?.toString()??"Cancel"]}})}var F={};c(F,{TauriEvent:()=>O,emit:()=>T,listen:()=>U,once:()=>I});async function B(n,e){return i({__tauriModule:"Event",message:{cmd:"unlisten",event:n,eventId:e}})}async function w(n,e,t){await i({__tauriModule:"Event",message:{cmd:"emit",event:n,windowLabel:e,payload:t}})}async function _(n,e,t){return i({__tauriModule:"Event",message:{cmd:"listen",event:n,windowLabel:e,handler:m(t)}}).then(r=>async()=>B(n,r))}async function v(n,e,t){return _(n,e,r=>{t(r),B(n,r.id).catch(()=>{})})}var O=(d=>(d.WINDOW_RESIZED="tauri://resize",d.WINDOW_MOVED="tauri://move",d.WINDOW_CLOSE_REQUESTED="tauri://close-requested",d.WINDOW_CREATED="tauri://window-created",d.WINDOW_DESTROYED="tauri://destroyed",d.WINDOW_FOCUS="tauri://focus",d.WINDOW_BLUR="tauri://blur",d.WINDOW_SCALE_FACTOR_CHANGED="tauri://scale-change",d.WINDOW_THEME_CHANGED="tauri://theme-changed",d.WINDOW_FILE_DROP="tauri://file-drop",d.WINDOW_FILE_DROP_HOVER="tauri://file-drop-hover",d.WINDOW_FILE_DROP_CANCELLED="tauri://file-drop-cancelled",d.MENU="tauri://menu",d.CHECK_UPDATE="tauri://update",d.UPDATE_AVAILABLE="tauri://update-available",d.INSTALL_UPDATE="tauri://update-install",d.STATUS_UPDATE="tauri://update-status",d.DOWNLOAD_PROGRESS="tauri://update-download-progress",d))(O||{});async function U(n,e){return _(n,null,e)}async function I(n,e){return v(n,null,e)}async function T(n,e){return w(n,void 0,e)}var z={};c(z,{isRegistered:()=>De,register:()=>Te,registerAll:()=>Ee,unregister:()=>Me,unregisterAll:()=>Ce});async function Te(n,e){return i({__tauriModule:"GlobalShortcut",message:{cmd:"register",shortcut:n,handler:m(e)}})}async function Ee(n,e){return i({__tauriModule:"GlobalShortcut",message:{cmd:"registerAll",shortcuts:n,handler:m(e)}})}async function De(n){return i({__tauriModule:"GlobalShortcut",message:{cmd:"isRegistered",shortcut:n}})}async function Me(n){return i({__tauriModule:"GlobalShortcut",message:{cmd:"unregister",shortcut:n}})}async function Ce(){return i({__tauriModule:"GlobalShortcut",message:{cmd:"unregisterAll"}})}var V={};c(V,{Body:()=>g,Client:()=>D,Response:()=>E,ResponseType:()=>ee,fetch:()=>Ae,getClient:()=>te});var ee=(r=>(r[r.JSON=1]="JSON",r[r.Text=2]="Text",r[r.Binary=3]="Binary",r))(ee||{}),g=class{constructor(e,t){this.type=e,this.payload=t}static form(e){let t={},r=(s,a)=>{if(a!==null){let u;typeof a=="string"?u=a:a instanceof Uint8Array||Array.isArray(a)?u=Array.from(a):a instanceof File?u={file:a.name,mime:a.type,fileName:a.name}:typeof a.file=="string"?u={file:a.file,mime:a.mime,fileName:a.fileName}:u={file:Array.from(a.file),mime:a.mime,fileName:a.fileName},t[String(s)]=u}};if(e instanceof FormData)for(let[s,a]of e)r(s,a);else for(let[s,a]of Object.entries(e))r(s,a);return new g("Form",t)}static json(e){return new g("Json",e)}static text(e){return new g("Text",e)}static bytes(e){return new g("Bytes",Array.from(e instanceof ArrayBuffer?new Uint8Array(e):e))}},E=class{constructor(e){this.url=e.url,this.status=e.status,this.ok=this.status>=200&&this.status<300,this.headers=e.headers,this.rawHeaders=e.rawHeaders,this.data=e.data}},D=class{constructor(e){this.id=e}async drop(){return i({__tauriModule:"Http",message:{cmd:"dropClient",client:this.id}})}async request(e){let t=!e.responseType||e.responseType===1;return t&&(e.responseType=2),i({__tauriModule:"Http",message:{cmd:"httpRequest",client:this.id,options:e}}).then(r=>{let s=new E(r);if(t){try{s.data=JSON.parse(s.data)}catch(a){if(s.ok&&s.data==="")s.data={};else if(s.ok)throw Error(`Failed to parse response \`${s.data}\` as JSON: ${a}; - try setting the \`responseType\` option to \`ResponseType.Text\` or \`ResponseType.Binary\` if the API does not return a JSON response.`)}return s}return s})}async get(e,t){return this.request({method:"GET",url:e,...t})}async post(e,t,r){return this.request({method:"POST",url:e,body:t,...r})}async put(e,t,r){return this.request({method:"PUT",url:e,body:t,...r})}async patch(e,t){return this.request({method:"PATCH",url:e,...t})}async delete(e,t){return this.request({method:"DELETE",url:e,...t})}};async function te(n){return i({__tauriModule:"Http",message:{cmd:"createClient",options:n}}).then(e=>new D(e))}var H=null;async function Ae(n,e){return H===null&&(H=await te()),H.request({url:n,method:e?.method??"GET",...e})}var q={};c(q,{isPermissionGranted:()=>Se,requestPermission:()=>We,sendNotification:()=>xe});async function Se(){return window.Notification.permission!=="default"?Promise.resolve(window.Notification.permission==="granted"):i({__tauriModule:"Notification",message:{cmd:"isNotificationPermissionGranted"}})}async function We(){return window.Notification.requestPermission()}function xe(n){typeof n=="string"?new window.Notification(n):new window.Notification(n.title,n)}var G={};c(G,{BaseDirectory:()=>ne,appCacheDir:()=>Ne,appConfigDir:()=>Le,appDataDir:()=>Re,appLocalDataDir:()=>ke,appLogDir:()=>tt,audioDir:()=>Ue,basename:()=>ut,cacheDir:()=>Ie,configDir:()=>Fe,dataDir:()=>ze,delimiter:()=>it,desktopDir:()=>He,dirname:()=>ot,documentDir:()=>Ve,downloadDir:()=>qe,executableDir:()=>Ge,extname:()=>lt,fontDir:()=>je,homeDir:()=>$e,isAbsolute:()=>dt,join:()=>at,localDataDir:()=>Je,normalize:()=>st,pictureDir:()=>Ke,publicDir:()=>Qe,resolve:()=>rt,resolveResource:()=>Ze,resourceDir:()=>Ye,runtimeDir:()=>Xe,sep:()=>nt,templateDir:()=>Be,videoDir:()=>et});function P(){return navigator.appVersion.includes("Win")}var ne=(o=>(o[o.Audio=1]="Audio",o[o.Cache=2]="Cache",o[o.Config=3]="Config",o[o.Data=4]="Data",o[o.LocalData=5]="LocalData",o[o.Document=6]="Document",o[o.Download=7]="Download",o[o.Picture=8]="Picture",o[o.Public=9]="Public",o[o.Video=10]="Video",o[o.Resource=11]="Resource",o[o.Temp=12]="Temp",o[o.AppConfig=13]="AppConfig",o[o.AppData=14]="AppData",o[o.AppLocalData=15]="AppLocalData",o[o.AppCache=16]="AppCache",o[o.AppLog=17]="AppLog",o[o.Desktop=18]="Desktop",o[o.Executable=19]="Executable",o[o.Font=20]="Font",o[o.Home=21]="Home",o[o.Runtime=22]="Runtime",o[o.Template=23]="Template",o))(ne||{});async function Le(){return l("plugin:path|resolve_directory",{directory:13})}async function Re(){return l("plugin:path|resolve_directory",{directory:14})}async function ke(){return l("plugin:path|resolve_directory",{directory:15})}async function Ne(){return l("plugin:path|resolve_directory",{directory:16})}async function Ue(){return l("plugin:path|resolve_directory",{directory:1})}async function Ie(){return l("plugin:path|resolve_directory",{directory:2})}async function Fe(){return l("plugin:path|resolve_directory",{directory:3})}async function ze(){return l("plugin:path|resolve_directory",{directory:4})}async function He(){return l("plugin:path|resolve_directory",{directory:18})}async function Ve(){return l("plugin:path|resolve_directory",{directory:6})}async function qe(){return l("plugin:path|resolve_directory",{directory:7})}async function Ge(){return l("plugin:path|resolve_directory",{directory:19})}async function je(){return l("plugin:path|resolve_directory",{directory:20})}async function $e(){return l("plugin:path|resolve_directory",{directory:21})}async function Je(){return l("plugin:path|resolve_directory",{directory:5})}async function Ke(){return l("plugin:path|resolve_directory",{directory:8})}async function Qe(){return l("plugin:path|resolve_directory",{directory:9})}async function Ye(){return l("plugin:path|resolve_directory",{directory:11})}async function Ze(n){return l("plugin:path|resolve_directory",{directory:11,path:n})}async function Xe(){return l("plugin:path|resolve_directory",{directory:22})}async function Be(){return l("plugin:path|resolve_directory",{directory:23})}async function et(){return l("plugin:path|resolve_directory",{directory:10})}async function tt(){return l("plugin:path|resolve_directory",{directory:17})}var nt=P()?"\\":"/",it=P()?";":":";async function rt(...n){return l("plugin:path|resolve",{paths:n})}async function st(n){return l("plugin:path|normalize",{path:n})}async function at(...n){return l("plugin:path|join",{paths:n})}async function ot(n){return l("plugin:path|dirname",{path:n})}async function lt(n){return l("plugin:path|extname",{path:n})}async function ut(n,e){return l("plugin:path|basename",{path:n,ext:e})}async function dt(n){return l("plugin:path|isAbsolute",{path:n})}var j={};c(j,{exit:()=>ct,relaunch:()=>mt});async function ct(n=0){return i({__tauriModule:"Process",message:{cmd:"exit",exitCode:n}})}async function mt(){return i({__tauriModule:"Process",message:{cmd:"relaunch"}})}var $={};c($,{Child:()=>M,Command:()=>h,EventEmitter:()=>y,open:()=>gt});async function pt(n,e,t=[],r){return typeof t=="object"&&Object.freeze(t),i({__tauriModule:"Shell",message:{cmd:"execute",program:e,args:t,options:r,onEventFn:m(n)}})}var y=class{constructor(){this.eventListeners=Object.create(null)}addListener(e,t){return this.on(e,t)}removeListener(e,t){return this.off(e,t)}on(e,t){return e in this.eventListeners?this.eventListeners[e].push(t):this.eventListeners[e]=[t],this}once(e,t){let r=s=>{this.removeListener(e,r),t(s)};return this.addListener(e,r)}off(e,t){return e in this.eventListeners&&(this.eventListeners[e]=this.eventListeners[e].filter(r=>r!==t)),this}removeAllListeners(e){return e?delete this.eventListeners[e]:this.eventListeners=Object.create(null),this}emit(e,t){if(e in this.eventListeners){let r=this.eventListeners[e];for(let s of r)s(t);return!0}return!1}listenerCount(e){return e in this.eventListeners?this.eventListeners[e].length:0}prependListener(e,t){return e in this.eventListeners?this.eventListeners[e].unshift(t):this.eventListeners[e]=[t],this}prependOnceListener(e,t){let r=s=>{this.removeListener(e,r),t(s)};return this.prependListener(e,r)}},M=class{constructor(e){this.pid=e}async write(e){return i({__tauriModule:"Shell",message:{cmd:"stdinWrite",pid:this.pid,buffer:typeof e=="string"?e:Array.from(e)}})}async kill(){return i({__tauriModule:"Shell",message:{cmd:"killChild",pid:this.pid}})}},h=class extends y{constructor(t,r=[],s){super();this.stdout=new y;this.stderr=new y;this.program=t,this.args=typeof r=="string"?[r]:r,this.options=s??{}}static create(t,r=[],s){return new h(t,r,s)}static sidecar(t,r=[],s){let a=new h(t,r,s);return a.options.sidecar=!0,a}async spawn(){return pt(t=>{switch(t.event){case"Error":this.emit("error",t.payload);break;case"Terminated":this.emit("close",t.payload);break;case"Stdout":this.stdout.emit("data",t.payload);break;case"Stderr":this.stderr.emit("data",t.payload);break}},this.program,this.args,this.options).then(t=>new M(t))}async execute(){return new Promise((t,r)=>{this.on("error",r);let s=[],a=[];this.stdout.on("data",u=>{s.push(u)}),this.stderr.on("data",u=>{a.push(u)}),this.on("close",u=>{t({code:u.code,signal:u.signal,stdout:this.collectOutput(s),stderr:this.collectOutput(a)})}),this.spawn().catch(r)})}collectOutput(t){return this.options.encoding==="raw"?t.reduce((r,s)=>new Uint8Array([...r,...s,10]),new Uint8Array):t.join(` -`)}};async function gt(n,e){return i({__tauriModule:"Shell",message:{cmd:"open",path:n,with:e}})}var K={};c(K,{checkUpdate:()=>ht,installUpdate:()=>yt,onUpdaterEvent:()=>J});async function J(n){return U("tauri://update-status",e=>{n(e?.payload)})}async function yt(){let n;function e(){n&&n(),n=void 0}return new Promise((t,r)=>{function s(a){if(a.error){e(),r(a.error);return}a.status==="DONE"&&(e(),t())}J(s).then(a=>{n=a}).catch(a=>{throw e(),a}),T("tauri://update-install").catch(a=>{throw e(),a})})}async function ht(){let n;function e(){n&&n(),n=void 0}return new Promise((t,r)=>{function s(u){e(),t({manifest:u,shouldUpdate:!0})}function a(u){if(u.error){e(),r(u.error);return}u.status==="UPTODATE"&&(e(),t({shouldUpdate:!1}))}I("tauri://update-available",u=>{s(u?.payload)}).catch(u=>{throw e(),u}),J(a).then(u=>{n=u}).catch(u=>{throw e(),u}),T("tauri://update").catch(u=>{throw e(),u})})}var Z={};c(Z,{CloseRequestedEvent:()=>x,LogicalPosition:()=>A,LogicalSize:()=>C,PhysicalPosition:()=>b,PhysicalSize:()=>f,UserAttentionType:()=>re,WebviewWindow:()=>p,WebviewWindowHandle:()=>S,WindowManager:()=>W,appWindow:()=>Q,availableMonitors:()=>Pt,currentMonitor:()=>bt,getAll:()=>se,getCurrent:()=>ft,primaryMonitor:()=>_t});var C=class{constructor(e,t){this.type="Logical";this.width=e,this.height=t}},f=class{constructor(e,t){this.type="Physical";this.width=e,this.height=t}toLogical(e){return new C(this.width/e,this.height/e)}},A=class{constructor(e,t){this.type="Logical";this.x=e,this.y=t}},b=class{constructor(e,t){this.type="Physical";this.x=e,this.y=t}toLogical(e){return new A(this.x/e,this.y/e)}},re=(t=>(t[t.Critical=1]="Critical",t[t.Informational=2]="Informational",t))(re||{});function ft(){return new p(window.__TAURI_METADATA__.__currentWindow.label,{skip:!0})}function se(){return window.__TAURI_METADATA__.__windows.map(n=>new p(n.label,{skip:!0}))}var ie=["tauri://created","tauri://error"],S=class{constructor(e){this.label=e,this.listeners=Object.create(null)}async listen(e,t){return this._handleTauriEvent(e,t)?Promise.resolve(()=>{let r=this.listeners[e];r.splice(r.indexOf(t),1)}):_(e,this.label,t)}async once(e,t){return this._handleTauriEvent(e,t)?Promise.resolve(()=>{let r=this.listeners[e];r.splice(r.indexOf(t),1)}):v(e,this.label,t)}async emit(e,t){if(ie.includes(e)){for(let r of this.listeners[e]||[])r({event:e,id:-1,windowLabel:this.label,payload:t});return Promise.resolve()}return w(e,this.label,t)}_handleTauriEvent(e,t){return ie.includes(e)?(e in this.listeners?this.listeners[e].push(t):this.listeners[e]=[t],!0):!1}},W=class extends S{async scaleFactor(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"scaleFactor"}}}})}async innerPosition(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"innerPosition"}}}}).then(({x:e,y:t})=>new b(e,t))}async outerPosition(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"outerPosition"}}}}).then(({x:e,y:t})=>new b(e,t))}async innerSize(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"innerSize"}}}}).then(({width:e,height:t})=>new f(e,t))}async outerSize(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"outerSize"}}}}).then(({width:e,height:t})=>new f(e,t))}async isFullscreen(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"isFullscreen"}}}})}async isMinimized(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"isMinimized"}}}})}async isMaximized(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"isMaximized"}}}})}async isDecorated(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"isDecorated"}}}})}async isResizable(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"isResizable"}}}})}async isVisible(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"isVisible"}}}})}async title(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"title"}}}})}async theme(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"theme"}}}})}async center(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"center"}}}})}async requestUserAttention(e){let t=null;return e&&(e===1?t={type:"Critical"}:t={type:"Informational"}),i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"requestUserAttention",payload:t}}}})}async setResizable(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setResizable",payload:e}}}})}async setTitle(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setTitle",payload:e}}}})}async maximize(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"maximize"}}}})}async unmaximize(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"unmaximize"}}}})}async toggleMaximize(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"toggleMaximize"}}}})}async minimize(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"minimize"}}}})}async unminimize(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"unminimize"}}}})}async show(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"show"}}}})}async hide(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"hide"}}}})}async close(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"close"}}}})}async setDecorations(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setDecorations",payload:e}}}})}async setShadow(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setShadow",payload:e}}}})}async setAlwaysOnTop(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setAlwaysOnTop",payload:e}}}})}async setContentProtected(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setContentProtected",payload:e}}}})}async setSize(e){if(!e||e.type!=="Logical"&&e.type!=="Physical")throw new Error("the `size` argument must be either a LogicalSize or a PhysicalSize instance");return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setSize",payload:{type:e.type,data:{width:e.width,height:e.height}}}}}})}async setMinSize(e){if(e&&e.type!=="Logical"&&e.type!=="Physical")throw new Error("the `size` argument must be either a LogicalSize or a PhysicalSize instance");return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setMinSize",payload:e?{type:e.type,data:{width:e.width,height:e.height}}:null}}}})}async setMaxSize(e){if(e&&e.type!=="Logical"&&e.type!=="Physical")throw new Error("the `size` argument must be either a LogicalSize or a PhysicalSize instance");return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setMaxSize",payload:e?{type:e.type,data:{width:e.width,height:e.height}}:null}}}})}async setPosition(e){if(!e||e.type!=="Logical"&&e.type!=="Physical")throw new Error("the `position` argument must be either a LogicalPosition or a PhysicalPosition instance");return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setPosition",payload:{type:e.type,data:{x:e.x,y:e.y}}}}}})}async setFullscreen(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setFullscreen",payload:e}}}})}async setFocus(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setFocus"}}}})}async setIcon(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setIcon",payload:{icon:typeof e=="string"?e:Array.from(e)}}}}})}async setSkipTaskbar(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setSkipTaskbar",payload:e}}}})}async setCursorGrab(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setCursorGrab",payload:e}}}})}async setCursorVisible(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setCursorVisible",payload:e}}}})}async setCursorIcon(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setCursorIcon",payload:e}}}})}async setCursorPosition(e){if(!e||e.type!=="Logical"&&e.type!=="Physical")throw new Error("the `position` argument must be either a LogicalPosition or a PhysicalPosition instance");return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setCursorPosition",payload:{type:e.type,data:{x:e.x,y:e.y}}}}}})}async setIgnoreCursorEvents(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setIgnoreCursorEvents",payload:e}}}})}async startDragging(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"startDragging"}}}})}async onResized(e){return this.listen("tauri://resize",e)}async onMoved(e){return this.listen("tauri://move",e)}async onCloseRequested(e){return this.listen("tauri://close-requested",t=>{let r=new x(t);Promise.resolve(e(r)).then(()=>{if(!r.isPreventDefault())return this.close()})})}async onFocusChanged(e){let t=await this.listen("tauri://focus",s=>{e({...s,payload:!0})}),r=await this.listen("tauri://blur",s=>{e({...s,payload:!1})});return()=>{t(),r()}}async onScaleChanged(e){return this.listen("tauri://scale-change",e)}async onMenuClicked(e){return this.listen("tauri://menu",e)}async onFileDropEvent(e){let t=await this.listen("tauri://file-drop",a=>{e({...a,payload:{type:"drop",paths:a.payload}})}),r=await this.listen("tauri://file-drop-hover",a=>{e({...a,payload:{type:"hover",paths:a.payload}})}),s=await this.listen("tauri://file-drop-cancelled",a=>{e({...a,payload:{type:"cancel"}})});return()=>{t(),r(),s()}}async onThemeChanged(e){return this.listen("tauri://theme-changed",e)}},x=class{constructor(e){this._preventDefault=!1;this.event=e.event,this.windowLabel=e.windowLabel,this.id=e.id}preventDefault(){this._preventDefault=!0}isPreventDefault(){return this._preventDefault}},p=class extends W{constructor(e,t={}){super(e),t?.skip||i({__tauriModule:"Window",message:{cmd:"createWebview",data:{options:{label:e,...t}}}}).then(async()=>this.emit("tauri://created")).catch(async r=>this.emit("tauri://error",r))}static getByLabel(e){return se().some(t=>t.label===e)?new p(e,{skip:!0}):null}},Q;"__TAURI_METADATA__"in window?Q=new p(window.__TAURI_METADATA__.__currentWindow.label,{skip:!0}):(console.warn(`Could not find "window.__TAURI_METADATA__". The "appWindow" value will reference the "main" window label. -Note that this is not an issue if running this frontend on a browser instead of a Tauri window.`),Q=new p("main",{skip:!0}));function Y(n){return n===null?null:{name:n.name,scaleFactor:n.scaleFactor,position:new b(n.position.x,n.position.y),size:new f(n.size.width,n.size.height)}}async function bt(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{cmd:{type:"currentMonitor"}}}}).then(Y)}async function _t(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{cmd:{type:"primaryMonitor"}}}}).then(Y)}async function Pt(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{cmd:{type:"availableMonitors"}}}}).then(n=>n.map(Y))}var X={};c(X,{EOL:()=>wt,arch:()=>Et,platform:()=>vt,tempdir:()=>Dt,type:()=>Tt,version:()=>Ot});var wt=P()?`\r +"use strict";var __TAURI_IIFE__=(()=>{var L=Object.defineProperty;var se=Object.getOwnPropertyDescriptor;var ae=Object.getOwnPropertyNames;var oe=Object.prototype.hasOwnProperty;var c=(n,e)=>{for(var t in e)L(n,t,{get:e[t],enumerable:!0})},le=(n,e,t,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let s of ae(e))!oe.call(n,s)&&s!==t&&L(n,s,{get:()=>e[s],enumerable:!(r=se(e,s))||r.enumerable});return n};var ue=n=>le(L({},"__esModule",{value:!0}),n);var vt={};c(vt,{app:()=>k,dialog:()=>N,event:()=>F,http:()=>H,invoke:()=>wt,notification:()=>V,os:()=>Z,path:()=>q,process:()=>j,shell:()=>G,tauri:()=>R,updater:()=>J,window:()=>Y});var k={};c(k,{getName:()=>pe,getTauriVersion:()=>ge,getVersion:()=>me,hide:()=>he,show:()=>ye});var R={};c(R,{convertFileSrc:()=>ce,invoke:()=>l,transformCallback:()=>g});function de(){return window.crypto.getRandomValues(new Uint32Array(1))[0]}function g(n,e=!1){let t=de(),r=`_${t}`;return Object.defineProperty(window,r,{value:s=>(e&&Reflect.deleteProperty(window,r),n?.(s)),writable:!1,configurable:!0}),t}async function l(n,e={}){return new Promise((t,r)=>{let s=g(u=>{t(u),Reflect.deleteProperty(window,`_${a}`)},!0),a=g(u=>{r(u),Reflect.deleteProperty(window,`_${s}`)},!0);window.__TAURI_IPC__({cmd:n,callback:s,error:a,...e})})}function ce(n,e="asset"){let t=encodeURIComponent(n);return navigator.userAgent.includes("Windows")?`https://${e}.localhost/${t}`:`${e}://localhost/${t}`}async function i(n){return l("tauri",n)}async function me(){return i({__tauriModule:"App",message:{cmd:"getAppVersion"}})}async function pe(){return i({__tauriModule:"App",message:{cmd:"getAppName"}})}async function ge(){return i({__tauriModule:"App",message:{cmd:"getTauriVersion"}})}async function ye(){return i({__tauriModule:"App",message:{cmd:"show"}})}async function he(){return i({__tauriModule:"App",message:{cmd:"hide"}})}var N={};c(N,{ask:()=>_e,confirm:()=>we,message:()=>Pe,open:()=>fe,save:()=>be});async function fe(n={}){return typeof n=="object"&&Object.freeze(n),i({__tauriModule:"Dialog",message:{cmd:"openDialog",options:n}})}async function be(n={}){return typeof n=="object"&&Object.freeze(n),i({__tauriModule:"Dialog",message:{cmd:"saveDialog",options:n}})}async function Pe(n,e){let t=typeof e=="string"?{title:e}:e;return i({__tauriModule:"Dialog",message:{cmd:"messageDialog",message:n.toString(),title:t?.title?.toString(),type:t?.type,buttonLabel:t?.okLabel?.toString()}})}async function _e(n,e){let t=typeof e=="string"?{title:e}:e;return i({__tauriModule:"Dialog",message:{cmd:"askDialog",message:n.toString(),title:t?.title?.toString(),type:t?.type,buttonLabels:[t?.okLabel?.toString()??"Yes",t?.cancelLabel?.toString()??"No"]}})}async function we(n,e){let t=typeof e=="string"?{title:e}:e;return i({__tauriModule:"Dialog",message:{cmd:"confirmDialog",message:n.toString(),title:t?.title?.toString(),type:t?.type,buttonLabels:[t?.okLabel?.toString()??"Ok",t?.cancelLabel?.toString()??"Cancel"]}})}var F={};c(F,{TauriEvent:()=>O,emit:()=>T,listen:()=>U,once:()=>I});async function X(n,e){return i({__tauriModule:"Event",message:{cmd:"unlisten",event:n,eventId:e}})}async function w(n,e,t){await i({__tauriModule:"Event",message:{cmd:"emit",event:n,windowLabel:e,payload:t}})}async function P(n,e,t){return i({__tauriModule:"Event",message:{cmd:"listen",event:n,windowLabel:e,handler:g(t)}}).then(r=>async()=>X(n,r))}async function v(n,e,t){return P(n,e,r=>{t(r),X(n,r.id).catch(()=>{})})}var O=(d=>(d.WINDOW_RESIZED="tauri://resize",d.WINDOW_MOVED="tauri://move",d.WINDOW_CLOSE_REQUESTED="tauri://close-requested",d.WINDOW_CREATED="tauri://window-created",d.WINDOW_DESTROYED="tauri://destroyed",d.WINDOW_FOCUS="tauri://focus",d.WINDOW_BLUR="tauri://blur",d.WINDOW_SCALE_FACTOR_CHANGED="tauri://scale-change",d.WINDOW_THEME_CHANGED="tauri://theme-changed",d.WINDOW_FILE_DROP="tauri://file-drop",d.WINDOW_FILE_DROP_HOVER="tauri://file-drop-hover",d.WINDOW_FILE_DROP_CANCELLED="tauri://file-drop-cancelled",d.MENU="tauri://menu",d.CHECK_UPDATE="tauri://update",d.UPDATE_AVAILABLE="tauri://update-available",d.INSTALL_UPDATE="tauri://update-install",d.STATUS_UPDATE="tauri://update-status",d.DOWNLOAD_PROGRESS="tauri://update-download-progress",d))(O||{});async function U(n,e){return P(n,null,e)}async function I(n,e){return v(n,null,e)}async function T(n,e){return w(n,void 0,e)}var H={};c(H,{Body:()=>p,Client:()=>D,Response:()=>E,ResponseType:()=>B,fetch:()=>Oe,getClient:()=>ee});var B=(r=>(r[r.JSON=1]="JSON",r[r.Text=2]="Text",r[r.Binary=3]="Binary",r))(B||{}),p=class{constructor(e,t){this.type=e,this.payload=t}static form(e){let t={},r=(s,a)=>{if(a!==null){let u;typeof a=="string"?u=a:a instanceof Uint8Array||Array.isArray(a)?u=Array.from(a):a instanceof File?u={file:a.name,mime:a.type,fileName:a.name}:typeof a.file=="string"?u={file:a.file,mime:a.mime,fileName:a.fileName}:u={file:Array.from(a.file),mime:a.mime,fileName:a.fileName},t[String(s)]=u}};if(e instanceof FormData)for(let[s,a]of e)r(s,a);else for(let[s,a]of Object.entries(e))r(s,a);return new p("Form",t)}static json(e){return new p("Json",e)}static text(e){return new p("Text",e)}static bytes(e){return new p("Bytes",Array.from(e instanceof ArrayBuffer?new Uint8Array(e):e))}},E=class{constructor(e){this.url=e.url,this.status=e.status,this.ok=this.status>=200&&this.status<300,this.headers=e.headers,this.rawHeaders=e.rawHeaders,this.data=e.data}},D=class{constructor(e){this.id=e}async drop(){return i({__tauriModule:"Http",message:{cmd:"dropClient",client:this.id}})}async request(e){let t=!e.responseType||e.responseType===1;return t&&(e.responseType=2),i({__tauriModule:"Http",message:{cmd:"httpRequest",client:this.id,options:e}}).then(r=>{let s=new E(r);if(t){try{s.data=JSON.parse(s.data)}catch(a){if(s.ok&&s.data==="")s.data={};else if(s.ok)throw Error(`Failed to parse response \`${s.data}\` as JSON: ${a}; + try setting the \`responseType\` option to \`ResponseType.Text\` or \`ResponseType.Binary\` if the API does not return a JSON response.`)}return s}return s})}async get(e,t){return this.request({method:"GET",url:e,...t})}async post(e,t,r){return this.request({method:"POST",url:e,body:t,...r})}async put(e,t,r){return this.request({method:"PUT",url:e,body:t,...r})}async patch(e,t){return this.request({method:"PATCH",url:e,...t})}async delete(e,t){return this.request({method:"DELETE",url:e,...t})}};async function ee(n){return i({__tauriModule:"Http",message:{cmd:"createClient",options:n}}).then(e=>new D(e))}var z=null;async function Oe(n,e){return z===null&&(z=await ee()),z.request({url:n,method:e?.method??"GET",...e})}var V={};c(V,{isPermissionGranted:()=>Te,requestPermission:()=>Ee,sendNotification:()=>De});async function Te(){return window.Notification.permission!=="default"?Promise.resolve(window.Notification.permission==="granted"):i({__tauriModule:"Notification",message:{cmd:"isNotificationPermissionGranted"}})}async function Ee(){return window.Notification.requestPermission()}function De(n){typeof n=="string"?new window.Notification(n):new window.Notification(n.title,n)}var q={};c(q,{BaseDirectory:()=>te,appCacheDir:()=>We,appConfigDir:()=>Ce,appDataDir:()=>Me,appLocalDataDir:()=>Ae,appLogDir:()=>Qe,audioDir:()=>Se,basename:()=>it,cacheDir:()=>xe,configDir:()=>Le,dataDir:()=>Re,delimiter:()=>Ze,desktopDir:()=>ke,dirname:()=>tt,documentDir:()=>Ne,downloadDir:()=>Ue,executableDir:()=>Ie,extname:()=>nt,fontDir:()=>Fe,homeDir:()=>ze,isAbsolute:()=>rt,join:()=>et,localDataDir:()=>He,normalize:()=>Be,pictureDir:()=>Ve,publicDir:()=>qe,resolve:()=>Xe,resolveResource:()=>Ge,resourceDir:()=>je,runtimeDir:()=>$e,sep:()=>Ye,templateDir:()=>Je,videoDir:()=>Ke});function _(){return navigator.appVersion.includes("Win")}var te=(o=>(o[o.Audio=1]="Audio",o[o.Cache=2]="Cache",o[o.Config=3]="Config",o[o.Data=4]="Data",o[o.LocalData=5]="LocalData",o[o.Document=6]="Document",o[o.Download=7]="Download",o[o.Picture=8]="Picture",o[o.Public=9]="Public",o[o.Video=10]="Video",o[o.Resource=11]="Resource",o[o.Temp=12]="Temp",o[o.AppConfig=13]="AppConfig",o[o.AppData=14]="AppData",o[o.AppLocalData=15]="AppLocalData",o[o.AppCache=16]="AppCache",o[o.AppLog=17]="AppLog",o[o.Desktop=18]="Desktop",o[o.Executable=19]="Executable",o[o.Font=20]="Font",o[o.Home=21]="Home",o[o.Runtime=22]="Runtime",o[o.Template=23]="Template",o))(te||{});async function Ce(){return l("plugin:path|resolve_directory",{directory:13})}async function Me(){return l("plugin:path|resolve_directory",{directory:14})}async function Ae(){return l("plugin:path|resolve_directory",{directory:15})}async function We(){return l("plugin:path|resolve_directory",{directory:16})}async function Se(){return l("plugin:path|resolve_directory",{directory:1})}async function xe(){return l("plugin:path|resolve_directory",{directory:2})}async function Le(){return l("plugin:path|resolve_directory",{directory:3})}async function Re(){return l("plugin:path|resolve_directory",{directory:4})}async function ke(){return l("plugin:path|resolve_directory",{directory:18})}async function Ne(){return l("plugin:path|resolve_directory",{directory:6})}async function Ue(){return l("plugin:path|resolve_directory",{directory:7})}async function Ie(){return l("plugin:path|resolve_directory",{directory:19})}async function Fe(){return l("plugin:path|resolve_directory",{directory:20})}async function ze(){return l("plugin:path|resolve_directory",{directory:21})}async function He(){return l("plugin:path|resolve_directory",{directory:5})}async function Ve(){return l("plugin:path|resolve_directory",{directory:8})}async function qe(){return l("plugin:path|resolve_directory",{directory:9})}async function je(){return l("plugin:path|resolve_directory",{directory:11})}async function Ge(n){return l("plugin:path|resolve_directory",{directory:11,path:n})}async function $e(){return l("plugin:path|resolve_directory",{directory:22})}async function Je(){return l("plugin:path|resolve_directory",{directory:23})}async function Ke(){return l("plugin:path|resolve_directory",{directory:10})}async function Qe(){return l("plugin:path|resolve_directory",{directory:17})}var Ye=_()?"\\":"/",Ze=_()?";":":";async function Xe(...n){return l("plugin:path|resolve",{paths:n})}async function Be(n){return l("plugin:path|normalize",{path:n})}async function et(...n){return l("plugin:path|join",{paths:n})}async function tt(n){return l("plugin:path|dirname",{path:n})}async function nt(n){return l("plugin:path|extname",{path:n})}async function it(n,e){return l("plugin:path|basename",{path:n,ext:e})}async function rt(n){return l("plugin:path|isAbsolute",{path:n})}var j={};c(j,{exit:()=>st,relaunch:()=>at});async function st(n=0){return i({__tauriModule:"Process",message:{cmd:"exit",exitCode:n}})}async function at(){return i({__tauriModule:"Process",message:{cmd:"relaunch"}})}var G={};c(G,{Child:()=>C,Command:()=>h,EventEmitter:()=>y,open:()=>lt});async function ot(n,e,t=[],r){return typeof t=="object"&&Object.freeze(t),i({__tauriModule:"Shell",message:{cmd:"execute",program:e,args:t,options:r,onEventFn:g(n)}})}var y=class{constructor(){this.eventListeners=Object.create(null)}addListener(e,t){return this.on(e,t)}removeListener(e,t){return this.off(e,t)}on(e,t){return e in this.eventListeners?this.eventListeners[e].push(t):this.eventListeners[e]=[t],this}once(e,t){let r=s=>{this.removeListener(e,r),t(s)};return this.addListener(e,r)}off(e,t){return e in this.eventListeners&&(this.eventListeners[e]=this.eventListeners[e].filter(r=>r!==t)),this}removeAllListeners(e){return e?delete this.eventListeners[e]:this.eventListeners=Object.create(null),this}emit(e,t){if(e in this.eventListeners){let r=this.eventListeners[e];for(let s of r)s(t);return!0}return!1}listenerCount(e){return e in this.eventListeners?this.eventListeners[e].length:0}prependListener(e,t){return e in this.eventListeners?this.eventListeners[e].unshift(t):this.eventListeners[e]=[t],this}prependOnceListener(e,t){let r=s=>{this.removeListener(e,r),t(s)};return this.prependListener(e,r)}},C=class{constructor(e){this.pid=e}async write(e){return i({__tauriModule:"Shell",message:{cmd:"stdinWrite",pid:this.pid,buffer:typeof e=="string"?e:Array.from(e)}})}async kill(){return i({__tauriModule:"Shell",message:{cmd:"killChild",pid:this.pid}})}},h=class extends y{constructor(t,r=[],s){super();this.stdout=new y;this.stderr=new y;this.program=t,this.args=typeof r=="string"?[r]:r,this.options=s??{}}static create(t,r=[],s){return new h(t,r,s)}static sidecar(t,r=[],s){let a=new h(t,r,s);return a.options.sidecar=!0,a}async spawn(){return ot(t=>{switch(t.event){case"Error":this.emit("error",t.payload);break;case"Terminated":this.emit("close",t.payload);break;case"Stdout":this.stdout.emit("data",t.payload);break;case"Stderr":this.stderr.emit("data",t.payload);break}},this.program,this.args,this.options).then(t=>new C(t))}async execute(){return new Promise((t,r)=>{this.on("error",r);let s=[],a=[];this.stdout.on("data",u=>{s.push(u)}),this.stderr.on("data",u=>{a.push(u)}),this.on("close",u=>{t({code:u.code,signal:u.signal,stdout:this.collectOutput(s),stderr:this.collectOutput(a)})}),this.spawn().catch(r)})}collectOutput(t){return this.options.encoding==="raw"?t.reduce((r,s)=>new Uint8Array([...r,...s,10]),new Uint8Array):t.join(` +`)}};async function lt(n,e){return i({__tauriModule:"Shell",message:{cmd:"open",path:n,with:e}})}var J={};c(J,{checkUpdate:()=>dt,installUpdate:()=>ut,onUpdaterEvent:()=>$});async function $(n){return U("tauri://update-status",e=>{n(e?.payload)})}async function ut(){let n;function e(){n&&n(),n=void 0}return new Promise((t,r)=>{function s(a){if(a.error){e(),r(a.error);return}a.status==="DONE"&&(e(),t())}$(s).then(a=>{n=a}).catch(a=>{throw e(),a}),T("tauri://update-install").catch(a=>{throw e(),a})})}async function dt(){let n;function e(){n&&n(),n=void 0}return new Promise((t,r)=>{function s(u){e(),t({manifest:u,shouldUpdate:!0})}function a(u){if(u.error){e(),r(u.error);return}u.status==="UPTODATE"&&(e(),t({shouldUpdate:!1}))}I("tauri://update-available",u=>{s(u?.payload)}).catch(u=>{throw e(),u}),$(a).then(u=>{n=u}).catch(u=>{throw e(),u}),T("tauri://update").catch(u=>{throw e(),u})})}var Y={};c(Y,{CloseRequestedEvent:()=>x,LogicalPosition:()=>A,LogicalSize:()=>M,PhysicalPosition:()=>b,PhysicalSize:()=>f,UserAttentionType:()=>ie,WebviewWindow:()=>m,WebviewWindowHandle:()=>W,WindowManager:()=>S,appWindow:()=>K,availableMonitors:()=>gt,currentMonitor:()=>mt,getAll:()=>re,getCurrent:()=>ct,primaryMonitor:()=>pt});var M=class{constructor(e,t){this.type="Logical";this.width=e,this.height=t}},f=class{constructor(e,t){this.type="Physical";this.width=e,this.height=t}toLogical(e){return new M(this.width/e,this.height/e)}},A=class{constructor(e,t){this.type="Logical";this.x=e,this.y=t}},b=class{constructor(e,t){this.type="Physical";this.x=e,this.y=t}toLogical(e){return new A(this.x/e,this.y/e)}},ie=(t=>(t[t.Critical=1]="Critical",t[t.Informational=2]="Informational",t))(ie||{});function ct(){return new m(window.__TAURI_METADATA__.__currentWindow.label,{skip:!0})}function re(){return window.__TAURI_METADATA__.__windows.map(n=>new m(n.label,{skip:!0}))}var ne=["tauri://created","tauri://error"],W=class{constructor(e){this.label=e,this.listeners=Object.create(null)}async listen(e,t){return this._handleTauriEvent(e,t)?Promise.resolve(()=>{let r=this.listeners[e];r.splice(r.indexOf(t),1)}):P(e,this.label,t)}async once(e,t){return this._handleTauriEvent(e,t)?Promise.resolve(()=>{let r=this.listeners[e];r.splice(r.indexOf(t),1)}):v(e,this.label,t)}async emit(e,t){if(ne.includes(e)){for(let r of this.listeners[e]||[])r({event:e,id:-1,windowLabel:this.label,payload:t});return Promise.resolve()}return w(e,this.label,t)}_handleTauriEvent(e,t){return ne.includes(e)?(e in this.listeners?this.listeners[e].push(t):this.listeners[e]=[t],!0):!1}},S=class extends W{async scaleFactor(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"scaleFactor"}}}})}async innerPosition(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"innerPosition"}}}}).then(({x:e,y:t})=>new b(e,t))}async outerPosition(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"outerPosition"}}}}).then(({x:e,y:t})=>new b(e,t))}async innerSize(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"innerSize"}}}}).then(({width:e,height:t})=>new f(e,t))}async outerSize(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"outerSize"}}}}).then(({width:e,height:t})=>new f(e,t))}async isFullscreen(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"isFullscreen"}}}})}async isMinimized(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"isMinimized"}}}})}async isMaximized(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"isMaximized"}}}})}async isDecorated(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"isDecorated"}}}})}async isResizable(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"isResizable"}}}})}async isVisible(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"isVisible"}}}})}async title(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"title"}}}})}async theme(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"theme"}}}})}async center(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"center"}}}})}async requestUserAttention(e){let t=null;return e&&(e===1?t={type:"Critical"}:t={type:"Informational"}),i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"requestUserAttention",payload:t}}}})}async setResizable(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setResizable",payload:e}}}})}async setTitle(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setTitle",payload:e}}}})}async maximize(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"maximize"}}}})}async unmaximize(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"unmaximize"}}}})}async toggleMaximize(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"toggleMaximize"}}}})}async minimize(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"minimize"}}}})}async unminimize(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"unminimize"}}}})}async show(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"show"}}}})}async hide(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"hide"}}}})}async close(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"close"}}}})}async setDecorations(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setDecorations",payload:e}}}})}async setShadow(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setShadow",payload:e}}}})}async setAlwaysOnTop(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setAlwaysOnTop",payload:e}}}})}async setContentProtected(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setContentProtected",payload:e}}}})}async setSize(e){if(!e||e.type!=="Logical"&&e.type!=="Physical")throw new Error("the `size` argument must be either a LogicalSize or a PhysicalSize instance");return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setSize",payload:{type:e.type,data:{width:e.width,height:e.height}}}}}})}async setMinSize(e){if(e&&e.type!=="Logical"&&e.type!=="Physical")throw new Error("the `size` argument must be either a LogicalSize or a PhysicalSize instance");return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setMinSize",payload:e?{type:e.type,data:{width:e.width,height:e.height}}:null}}}})}async setMaxSize(e){if(e&&e.type!=="Logical"&&e.type!=="Physical")throw new Error("the `size` argument must be either a LogicalSize or a PhysicalSize instance");return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setMaxSize",payload:e?{type:e.type,data:{width:e.width,height:e.height}}:null}}}})}async setPosition(e){if(!e||e.type!=="Logical"&&e.type!=="Physical")throw new Error("the `position` argument must be either a LogicalPosition or a PhysicalPosition instance");return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setPosition",payload:{type:e.type,data:{x:e.x,y:e.y}}}}}})}async setFullscreen(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setFullscreen",payload:e}}}})}async setFocus(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setFocus"}}}})}async setIcon(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setIcon",payload:{icon:typeof e=="string"?e:Array.from(e)}}}}})}async setSkipTaskbar(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setSkipTaskbar",payload:e}}}})}async setCursorGrab(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setCursorGrab",payload:e}}}})}async setCursorVisible(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setCursorVisible",payload:e}}}})}async setCursorIcon(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setCursorIcon",payload:e}}}})}async setCursorPosition(e){if(!e||e.type!=="Logical"&&e.type!=="Physical")throw new Error("the `position` argument must be either a LogicalPosition or a PhysicalPosition instance");return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setCursorPosition",payload:{type:e.type,data:{x:e.x,y:e.y}}}}}})}async setIgnoreCursorEvents(e){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"setIgnoreCursorEvents",payload:e}}}})}async startDragging(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{label:this.label,cmd:{type:"startDragging"}}}})}async onResized(e){return this.listen("tauri://resize",e)}async onMoved(e){return this.listen("tauri://move",e)}async onCloseRequested(e){return this.listen("tauri://close-requested",t=>{let r=new x(t);Promise.resolve(e(r)).then(()=>{if(!r.isPreventDefault())return this.close()})})}async onFocusChanged(e){let t=await this.listen("tauri://focus",s=>{e({...s,payload:!0})}),r=await this.listen("tauri://blur",s=>{e({...s,payload:!1})});return()=>{t(),r()}}async onScaleChanged(e){return this.listen("tauri://scale-change",e)}async onMenuClicked(e){return this.listen("tauri://menu",e)}async onFileDropEvent(e){let t=await this.listen("tauri://file-drop",a=>{e({...a,payload:{type:"drop",paths:a.payload}})}),r=await this.listen("tauri://file-drop-hover",a=>{e({...a,payload:{type:"hover",paths:a.payload}})}),s=await this.listen("tauri://file-drop-cancelled",a=>{e({...a,payload:{type:"cancel"}})});return()=>{t(),r(),s()}}async onThemeChanged(e){return this.listen("tauri://theme-changed",e)}},x=class{constructor(e){this._preventDefault=!1;this.event=e.event,this.windowLabel=e.windowLabel,this.id=e.id}preventDefault(){this._preventDefault=!0}isPreventDefault(){return this._preventDefault}},m=class extends S{constructor(e,t={}){super(e),t?.skip||i({__tauriModule:"Window",message:{cmd:"createWebview",data:{options:{label:e,...t}}}}).then(async()=>this.emit("tauri://created")).catch(async r=>this.emit("tauri://error",r))}static getByLabel(e){return re().some(t=>t.label===e)?new m(e,{skip:!0}):null}},K;"__TAURI_METADATA__"in window?K=new m(window.__TAURI_METADATA__.__currentWindow.label,{skip:!0}):(console.warn(`Could not find "window.__TAURI_METADATA__". The "appWindow" value will reference the "main" window label. +Note that this is not an issue if running this frontend on a browser instead of a Tauri window.`),K=new m("main",{skip:!0}));function Q(n){return n===null?null:{name:n.name,scaleFactor:n.scaleFactor,position:new b(n.position.x,n.position.y),size:new f(n.size.width,n.size.height)}}async function mt(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{cmd:{type:"currentMonitor"}}}}).then(Q)}async function pt(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{cmd:{type:"primaryMonitor"}}}}).then(Q)}async function gt(){return i({__tauriModule:"Window",message:{cmd:"manage",data:{cmd:{type:"availableMonitors"}}}}).then(n=>n.map(Q))}var Z={};c(Z,{EOL:()=>yt,arch:()=>Pt,platform:()=>ht,tempdir:()=>_t,type:()=>bt,version:()=>ft});var yt=_()?`\r `:` -`;async function vt(){return i({__tauriModule:"Os",message:{cmd:"platform"}})}async function Ot(){return i({__tauriModule:"Os",message:{cmd:"version"}})}async function Tt(){return i({__tauriModule:"Os",message:{cmd:"osType"}})}async function Et(){return i({__tauriModule:"Os",message:{cmd:"arch"}})}async function Dt(){return i({__tauriModule:"Os",message:{cmd:"tempdir"}})}var Mt=l;return de(Ct);})(); +`;async function ht(){return i({__tauriModule:"Os",message:{cmd:"platform"}})}async function ft(){return i({__tauriModule:"Os",message:{cmd:"version"}})}async function bt(){return i({__tauriModule:"Os",message:{cmd:"osType"}})}async function Pt(){return i({__tauriModule:"Os",message:{cmd:"arch"}})}async function _t(){return i({__tauriModule:"Os",message:{cmd:"tempdir"}})}var wt=l;return ue(vt);})(); window.__TAURI__ = __TAURI_IIFE__ diff --git a/core/tauri/src/app.rs b/core/tauri/src/app.rs index f8258bb738d..d256fde2f91 100644 --- a/core/tauri/src/app.rs +++ b/core/tauri/src/app.rs @@ -262,8 +262,6 @@ impl AssetResolver { pub struct AppHandle { pub(crate) runtime_handle: R::Handle, pub(crate) manager: WindowManager, - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager: R::GlobalShortcutManager, /// The updater configuration. #[cfg(updater)] pub(crate) updater_settings: UpdaterSettings, @@ -311,8 +309,6 @@ impl Clone for AppHandle { Self { runtime_handle: self.runtime_handle.clone(), manager: self.manager.clone(), - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager: self.global_shortcut_manager.clone(), #[cfg(updater)] updater_settings: self.updater_settings.clone(), } @@ -469,22 +465,16 @@ pub struct App { pending_windows: Option>>, setup: Option>, manager: WindowManager, - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager: R::GlobalShortcutManager, handle: AppHandle, } impl fmt::Debug for App { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { - let mut d = f.debug_struct("App"); - d.field("runtime", &self.runtime) + f.debug_struct("App") + .field("runtime", &self.runtime) .field("manager", &self.manager) - .field("handle", &self.handle); - - #[cfg(all(desktop, feature = "global-shortcut"))] - d.field("global_shortcut_manager", &self.global_shortcut_manager); - - d.finish() + .field("handle", &self.handle) + .finish() } } @@ -619,13 +609,6 @@ macro_rules! shared_app_impl { .get_tray(id) } - /// Gets a copy of the global shortcut manager instance. - #[cfg(all(desktop, feature = "global-shortcut"))] - #[cfg_attr(doc_cfg, doc(cfg(feature = "global-shortcut")))] - pub fn global_shortcut_manager(&self) -> R::GlobalShortcutManager { - self.global_shortcut_manager.clone() - } - /// Gets the app's configuration, defined on the `tauri.conf.json` file. pub fn config(&self) -> Arc { self.manager.config() @@ -1490,22 +1473,15 @@ impl Builder { let runtime_handle = runtime.handle(); - #[cfg(all(desktop, feature = "global-shortcut"))] - let global_shortcut_manager = runtime.global_shortcut_manager(); - #[allow(unused_mut)] let mut app = App { runtime: Some(runtime), pending_windows: Some(self.pending_windows), setup: Some(self.setup), manager: manager.clone(), - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager: global_shortcut_manager.clone(), handle: AppHandle { runtime_handle, manager, - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager, #[cfg(updater)] updater_settings: self.updater_settings, }, diff --git a/core/tauri/src/endpoints.rs b/core/tauri/src/endpoints.rs index 6ef6c093e9f..3248ef96df6 100644 --- a/core/tauri/src/endpoints.rs +++ b/core/tauri/src/endpoints.rs @@ -16,8 +16,6 @@ mod app; #[cfg(dialog_any)] mod dialog; mod event; -#[cfg(global_shortcut_any)] -mod global_shortcut; #[cfg(http_any)] mod http; mod notification; @@ -77,8 +75,6 @@ enum Module { Notification(notification::Cmd), #[cfg(http_any)] Http(http::Cmd), - #[cfg(global_shortcut_any)] - GlobalShortcut(global_shortcut::Cmd), } impl Module { @@ -156,13 +152,6 @@ impl Module { .and_then(|r| r.json) .map_err(InvokeError::from_anyhow) }), - #[cfg(global_shortcut_any)] - Self::GlobalShortcut(cmd) => resolver.respond_async(async move { - cmd - .run(context) - .and_then(|r| r.json) - .map_err(InvokeError::from_anyhow) - }), } } } diff --git a/core/tauri/src/endpoints/global_shortcut.rs b/core/tauri/src/endpoints/global_shortcut.rs deleted file mode 100644 index eefb34f4dba..00000000000 --- a/core/tauri/src/endpoints/global_shortcut.rs +++ /dev/null @@ -1,174 +0,0 @@ -// Copyright 2019-2023 Tauri Programme within The Commons Conservancy -// SPDX-License-Identifier: Apache-2.0 -// SPDX-License-Identifier: MIT - -#![allow(unused_imports)] - -use super::InvokeContext; -use crate::{api::ipc::CallbackFn, Runtime}; -use serde::Deserialize; -use tauri_macros::{command_enum, module_command_handler, CommandModule}; - -#[cfg(global_shortcut_all)] -use crate::runtime::GlobalShortcutManager; - -/// The API descriptor. -#[command_enum] -#[derive(Deserialize, CommandModule)] -#[serde(tag = "cmd", rename_all = "camelCase")] -pub enum Cmd { - /// Register a global shortcut. - #[cmd(global_shortcut_all, "globalShortcut > all")] - Register { - shortcut: String, - handler: CallbackFn, - }, - /// Register a list of global shortcuts. - #[cmd(global_shortcut_all, "globalShortcut > all")] - RegisterAll { - shortcuts: Vec, - handler: CallbackFn, - }, - /// Unregister a global shortcut. - #[cmd(global_shortcut_all, "globalShortcut > all")] - Unregister { shortcut: String }, - /// Unregisters all registered shortcuts. - UnregisterAll, - /// Determines whether the given hotkey is registered or not. - #[cmd(global_shortcut_all, "globalShortcut > all")] - IsRegistered { shortcut: String }, -} - -impl Cmd { - #[module_command_handler(global_shortcut_all)] - fn register( - context: InvokeContext, - shortcut: String, - handler: CallbackFn, - ) -> super::Result<()> { - let mut manager = context.window.app_handle.global_shortcut_manager(); - register_shortcut(context.window, &mut manager, shortcut, handler)?; - Ok(()) - } - - #[module_command_handler(global_shortcut_all)] - fn register_all( - context: InvokeContext, - shortcuts: Vec, - handler: CallbackFn, - ) -> super::Result<()> { - let mut manager = context.window.app_handle.global_shortcut_manager(); - for shortcut in shortcuts { - register_shortcut(context.window.clone(), &mut manager, shortcut, handler)?; - } - Ok(()) - } - - #[module_command_handler(global_shortcut_all)] - fn unregister(context: InvokeContext, shortcut: String) -> super::Result<()> { - context - .window - .app_handle - .global_shortcut_manager() - .unregister(&shortcut) - .map_err(crate::error::into_anyhow)?; - Ok(()) - } - - #[module_command_handler(global_shortcut_all)] - fn unregister_all(context: InvokeContext) -> super::Result<()> { - context - .window - .app_handle - .global_shortcut_manager() - .unregister_all() - .map_err(crate::error::into_anyhow)?; - Ok(()) - } - - #[cfg(not(global_shortcut_all))] - fn unregister_all(_: InvokeContext) -> super::Result<()> { - Err(crate::Error::ApiNotAllowlisted("globalShortcut > all".into()).into_anyhow()) - } - - #[module_command_handler(global_shortcut_all)] - fn is_registered(context: InvokeContext, shortcut: String) -> super::Result { - context - .window - .app_handle - .global_shortcut_manager() - .is_registered(&shortcut) - .map_err(crate::error::into_anyhow) - } -} - -#[cfg(global_shortcut_all)] -fn register_shortcut( - window: crate::Window, - manager: &mut R::GlobalShortcutManager, - shortcut: String, - handler: CallbackFn, -) -> super::Result<()> { - let accelerator = shortcut.clone(); - manager - .register(&shortcut, move || { - let callback_string = crate::api::ipc::format_callback(handler, &accelerator) - .expect("unable to serialize shortcut string to json"); - let _ = window.eval(callback_string.as_str()); - }) - .map_err(crate::error::into_anyhow)?; - Ok(()) -} - -#[cfg(test)] -mod tests { - use crate::api::ipc::CallbackFn; - - #[tauri_macros::module_command_test(global_shortcut_all, "globalShortcut > all")] - #[quickcheck_macros::quickcheck] - fn register(shortcut: String, handler: CallbackFn) { - let ctx = crate::test::mock_invoke_context(); - super::Cmd::register(ctx.clone(), shortcut.clone(), handler).unwrap(); - assert!(super::Cmd::is_registered(ctx, shortcut).unwrap()); - } - - #[tauri_macros::module_command_test(global_shortcut_all, "globalShortcut > all")] - #[quickcheck_macros::quickcheck] - fn register_all(shortcuts: Vec, handler: CallbackFn) { - let ctx = crate::test::mock_invoke_context(); - super::Cmd::register_all(ctx.clone(), shortcuts.clone(), handler).unwrap(); - for shortcut in shortcuts { - assert!(super::Cmd::is_registered(ctx.clone(), shortcut).unwrap(),); - } - } - - #[tauri_macros::module_command_test(global_shortcut_all, "globalShortcut > all")] - #[quickcheck_macros::quickcheck] - fn unregister(shortcut: String) { - let ctx = crate::test::mock_invoke_context(); - super::Cmd::register(ctx.clone(), shortcut.clone(), CallbackFn(0)).unwrap(); - super::Cmd::unregister(ctx.clone(), shortcut.clone()).unwrap(); - assert!(!super::Cmd::is_registered(ctx, shortcut).unwrap()); - } - - #[tauri_macros::module_command_test(global_shortcut_all, "globalShortcut > all", runtime)] - #[quickcheck_macros::quickcheck] - fn unregister_all() { - let shortcuts = vec!["CTRL+X".to_string(), "SUPER+C".to_string(), "D".to_string()]; - let ctx = crate::test::mock_invoke_context(); - super::Cmd::register_all(ctx.clone(), shortcuts.clone(), CallbackFn(0)).unwrap(); - super::Cmd::unregister_all(ctx.clone()).unwrap(); - for shortcut in shortcuts { - assert!(!super::Cmd::is_registered(ctx.clone(), shortcut).unwrap(),); - } - } - - #[tauri_macros::module_command_test(global_shortcut_all, "globalShortcut > all")] - #[quickcheck_macros::quickcheck] - fn is_registered(shortcut: String) { - let ctx = crate::test::mock_invoke_context(); - assert!(!super::Cmd::is_registered(ctx.clone(), shortcut.clone()).unwrap(),); - super::Cmd::register(ctx.clone(), shortcut.clone(), CallbackFn(0)).unwrap(); - assert!(super::Cmd::is_registered(ctx, shortcut).unwrap()); - } -} diff --git a/core/tauri/src/lib.rs b/core/tauri/src/lib.rs index 39ebcf0e7e3..79ba8fa7b3f 100644 --- a/core/tauri/src/lib.rs +++ b/core/tauri/src/lib.rs @@ -26,7 +26,6 @@ //! - **native-tls-vendored**: Compile and statically link to a vendored copy of OpenSSL. //! - **rustls-tls**: Provides TLS support to connect over HTTPS using rustls. //! - **process-command-api**: Enables the [`api::process::Command`] APIs. -//! - **global-shortcut**: Enables the global shortcut APIs. //! - **process-relaunch-dangerous-allow-symlink-macos**: Allows the [`api::process::current_binary`] function to allow symlinks on macOS (this is dangerous, see the Security section in the documentation website). //! - **dialog**: Enables the [`api::dialog`] module. //! - **notification**: Enables the [`api::notification`] module. @@ -312,10 +311,6 @@ pub use { scope::*, }; -#[cfg(all(desktop, feature = "global-shortcut"))] -#[cfg_attr(doc_cfg, doc(cfg(feature = "global-shortcut")))] -pub use self::runtime::GlobalShortcutManager; - #[cfg(target_os = "ios")] #[doc(hidden)] pub fn log_stdout() { diff --git a/core/tauri/src/test/mock_runtime.rs b/core/tauri/src/test/mock_runtime.rs index 87fc0748627..7ff42913b1d 100644 --- a/core/tauri/src/test/mock_runtime.rs +++ b/core/tauri/src/test/mock_runtime.rs @@ -130,46 +130,6 @@ pub struct MockDispatcher { context: RuntimeContext, } -#[cfg(all(desktop, feature = "global-shortcut"))] -#[derive(Debug, Clone)] -pub struct MockGlobalShortcutManager { - context: RuntimeContext, -} - -#[cfg(all(desktop, feature = "global-shortcut"))] -impl tauri_runtime::GlobalShortcutManager for MockGlobalShortcutManager { - fn is_registered(&self, accelerator: &str) -> Result { - Ok( - self - .context - .shortcuts - .lock() - .unwrap() - .contains_key(accelerator), - ) - } - - fn register(&mut self, accelerator: &str, handler: F) -> Result<()> { - self - .context - .shortcuts - .lock() - .unwrap() - .insert(accelerator.into(), Box::new(handler)); - Ok(()) - } - - fn unregister_all(&mut self) -> Result<()> { - *self.context.shortcuts.lock().unwrap() = Default::default(); - Ok(()) - } - - fn unregister(&mut self, accelerator: &str) -> Result<()> { - self.context.shortcuts.lock().unwrap().remove(accelerator); - Ok(()) - } -} - #[derive(Debug, Clone)] pub struct MockWindowBuilder {} @@ -625,8 +585,6 @@ impl EventLoopProxy for EventProxy { #[derive(Debug)] pub struct MockRuntime { pub context: RuntimeContext, - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager: MockGlobalShortcutManager, #[cfg(all(desktop, feature = "system-tray"))] tray_handler: MockTrayHandler, } @@ -637,10 +595,6 @@ impl MockRuntime { shortcuts: Default::default(), }; Self { - #[cfg(all(desktop, feature = "global-shortcut"))] - global_shortcut_manager: MockGlobalShortcutManager { - context: context.clone(), - }, #[cfg(all(desktop, feature = "system-tray"))] tray_handler: MockTrayHandler { context: context.clone(), @@ -653,8 +607,6 @@ impl MockRuntime { impl Runtime for MockRuntime { type Dispatcher = MockDispatcher; type Handle = MockRuntimeHandle; - #[cfg(all(desktop, feature = "global-shortcut"))] - type GlobalShortcutManager = MockGlobalShortcutManager; #[cfg(all(desktop, feature = "system-tray"))] type TrayHandler = MockTrayHandler; type EventLoopProxy = EventProxy; @@ -678,11 +630,6 @@ impl Runtime for MockRuntime { } } - #[cfg(all(desktop, feature = "global-shortcut"))] - fn global_shortcut_manager(&self) -> Self::GlobalShortcutManager { - self.global_shortcut_manager.clone() - } - fn create_window(&self, pending: PendingWindow) -> Result> { Ok(DetachedWindow { label: pending.label, diff --git a/examples/api/src-tauri/Cargo.toml b/examples/api/src-tauri/Cargo.toml index bea89238fd3..01f29118896 100644 --- a/examples/api/src-tauri/Cargo.toml +++ b/examples/api/src-tauri/Cargo.toml @@ -35,7 +35,6 @@ tauri-build = { path = "../../../core/tauri-build" } path = "../../../core/tauri" features = [ "api-all", - "global-shortcut", "http-multipart", "icon-ico", "icon-png", diff --git a/tooling/api/docs/js-api.json b/tooling/api/docs/js-api.json index 05fe65134a4..4927a8546fd 100644 --- a/tooling/api/docs/js-api.json +++ b/tooling/api/docs/js-api.json @@ -1 +1 @@ -{"id":0,"name":"@tauri-apps/api","kind":1,"flags":{},"originalName":"","children":[{"id":1,"name":"app","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Get application metadata.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.app`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be added to ["},{"kind":"code","text":"`tauri.allowlist.app`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.app) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"app\": {\n \"all\": true, // enable all app APIs\n \"show\": true,\n \"hide\": true\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security."}]},"children":[{"id":2,"name":"getName","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"app.ts","line":60,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/app.ts#L60"}],"signatures":[{"id":3,"name":"getName","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the application name."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getName } from '@tauri-apps/api/app';\nconst appName = await getName();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":6,"name":"getTauriVersion","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"app.ts","line":80,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/app.ts#L80"}],"signatures":[{"id":7,"name":"getTauriVersion","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the Tauri version."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getTauriVersion } from '@tauri-apps/api/app';\nconst tauriVersion = await getTauriVersion();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":4,"name":"getVersion","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"app.ts","line":41,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/app.ts#L41"}],"signatures":[{"id":5,"name":"getVersion","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the application version."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getVersion } from '@tauri-apps/api/app';\nconst appVersion = await getVersion();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":10,"name":"hide","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"app.ts","line":120,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/app.ts#L120"}],"signatures":[{"id":11,"name":"hide","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Hides the application on macOS."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { hide } from '@tauri-apps/api/app';\nawait hide();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":8,"name":"show","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"app.ts","line":100,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/app.ts#L100"}],"signatures":[{"id":9,"name":"show","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Shows the application on macOS. This function does not automatically focus any specific app window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { show } from '@tauri-apps/api/app';\nawait show();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Functions","children":[2,6,4,10,8]}],"sources":[{"fileName":"app.ts","line":29,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/app.ts#L29"}]},{"id":12,"name":"dialog","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Native system dialogs for opening and saving files.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.dialog`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be added to ["},{"kind":"code","text":"`tauri.allowlist.dialog`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.dialog) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"dialog\": {\n \"all\": true, // enable all dialog APIs\n \"ask\": true, // enable dialog ask API\n \"confirm\": true, // enable dialog confirm API\n \"message\": true, // enable dialog message API\n \"open\": true, // enable file open API\n \"save\": true // enable file save API\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security."}]},"children":[{"id":31,"name":"ConfirmDialogOptions","kind":256,"kindString":"Interface","flags":{},"children":[{"id":35,"name":"cancelLabel","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The label of the cancel button."}]},"sources":[{"fileName":"dialog.ts","line":112,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L112"}],"type":{"type":"intrinsic","name":"string"}},{"id":34,"name":"okLabel","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The label of the confirm button."}]},"sources":[{"fileName":"dialog.ts","line":110,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L110"}],"type":{"type":"intrinsic","name":"string"}},{"id":32,"name":"title","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The title of the dialog. Defaults to the app name."}]},"sources":[{"fileName":"dialog.ts","line":106,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L106"}],"type":{"type":"intrinsic","name":"string"}},{"id":33,"name":"type","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The type of the dialog. Defaults to "},{"kind":"code","text":"`info`"},{"kind":"text","text":"."}]},"sources":[{"fileName":"dialog.ts","line":108,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L108"}],"type":{"type":"union","types":[{"type":"literal","value":"info"},{"type":"literal","value":"warning"},{"type":"literal","value":"error"}]}}],"groups":[{"title":"Properties","children":[35,34,32,33]}],"sources":[{"fileName":"dialog.ts","line":104,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L104"}]},{"id":13,"name":"DialogFilter","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Extension filters for the file dialog."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":15,"name":"extensions","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Extensions to filter, without a "},{"kind":"code","text":"`.`"},{"kind":"text","text":" prefix."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nextensions: ['svg', 'png']\n```"}]}]},"sources":[{"fileName":"dialog.ts","line":48,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L48"}],"type":{"type":"array","elementType":{"type":"intrinsic","name":"string"}}},{"id":14,"name":"name","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Filter name."}]},"sources":[{"fileName":"dialog.ts","line":40,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L40"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[15,14]}],"sources":[{"fileName":"dialog.ts","line":38,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L38"}]},{"id":27,"name":"MessageDialogOptions","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":30,"name":"okLabel","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The label of the confirm button."}]},"sources":[{"fileName":"dialog.ts","line":101,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L101"}],"type":{"type":"intrinsic","name":"string"}},{"id":28,"name":"title","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The title of the dialog. Defaults to the app name."}]},"sources":[{"fileName":"dialog.ts","line":97,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L97"}],"type":{"type":"intrinsic","name":"string"}},{"id":29,"name":"type","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The type of the dialog. Defaults to "},{"kind":"code","text":"`info`"},{"kind":"text","text":"."}]},"sources":[{"fileName":"dialog.ts","line":99,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L99"}],"type":{"type":"union","types":[{"type":"literal","value":"info"},{"type":"literal","value":"warning"},{"type":"literal","value":"error"}]}}],"groups":[{"title":"Properties","children":[30,28,29]}],"sources":[{"fileName":"dialog.ts","line":95,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L95"}]},{"id":16,"name":"OpenDialogOptions","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Options for the open dialog."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":19,"name":"defaultPath","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Initial directory or file path."}]},"sources":[{"fileName":"dialog.ts","line":62,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L62"}],"type":{"type":"intrinsic","name":"string"}},{"id":21,"name":"directory","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the dialog is a directory selection or not."}]},"sources":[{"fileName":"dialog.ts","line":66,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L66"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":18,"name":"filters","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The filters of the dialog."}]},"sources":[{"fileName":"dialog.ts","line":60,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L60"}],"type":{"type":"array","elementType":{"type":"reference","id":13,"name":"DialogFilter"}}},{"id":20,"name":"multiple","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the dialog allows multiple selection or not."}]},"sources":[{"fileName":"dialog.ts","line":64,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L64"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":22,"name":"recursive","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"If "},{"kind":"code","text":"`directory`"},{"kind":"text","text":" is true, indicates that it will be read recursively later.\nDefines whether subdirectories will be allowed on the scope or not."}]},"sources":[{"fileName":"dialog.ts","line":71,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L71"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":17,"name":"title","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The title of the dialog window."}]},"sources":[{"fileName":"dialog.ts","line":58,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L58"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[19,21,18,20,22,17]}],"sources":[{"fileName":"dialog.ts","line":56,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L56"}]},{"id":23,"name":"SaveDialogOptions","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Options for the save dialog."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":26,"name":"defaultPath","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Initial directory or file path.\nIf it's a directory path, the dialog interface will change to that folder.\nIf it's not an existing directory, the file name will be set to the dialog's file name input and the dialog will be set to the parent folder."}]},"sources":[{"fileName":"dialog.ts","line":89,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L89"}],"type":{"type":"intrinsic","name":"string"}},{"id":25,"name":"filters","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The filters of the dialog."}]},"sources":[{"fileName":"dialog.ts","line":83,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L83"}],"type":{"type":"array","elementType":{"type":"reference","id":13,"name":"DialogFilter"}}},{"id":24,"name":"title","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The title of the dialog window."}]},"sources":[{"fileName":"dialog.ts","line":81,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L81"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[26,25,24]}],"sources":[{"fileName":"dialog.ts","line":79,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L79"}]},{"id":54,"name":"ask","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"dialog.ts","line":257,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L257"}],"signatures":[{"id":55,"name":"ask","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Shows a question dialog with "},{"kind":"code","text":"`Yes`"},{"kind":"text","text":" and "},{"kind":"code","text":"`No`"},{"kind":"text","text":" buttons."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { ask } from '@tauri-apps/api/dialog';\nconst yes = await ask('Are you sure?', 'Tauri');\nconst yes2 = await ask('This action cannot be reverted. Are you sure?', { title: 'Tauri', type: 'warning' });\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a boolean indicating whether "},{"kind":"code","text":"`Yes`"},{"kind":"text","text":" was clicked or not."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":56,"name":"message","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The message to show."}]},"type":{"type":"intrinsic","name":"string"}},{"id":57,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The dialog's options. If a string, it represents the dialog title."}]},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","id":31,"name":"ConfirmDialogOptions"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":58,"name":"confirm","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"dialog.ts","line":293,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L293"}],"signatures":[{"id":59,"name":"confirm","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Shows a question dialog with "},{"kind":"code","text":"`Ok`"},{"kind":"text","text":" and "},{"kind":"code","text":"`Cancel`"},{"kind":"text","text":" buttons."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { confirm } from '@tauri-apps/api/dialog';\nconst confirmed = await confirm('Are you sure?', 'Tauri');\nconst confirmed2 = await confirm('This action cannot be reverted. Are you sure?', { title: 'Tauri', type: 'warning' });\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a boolean indicating whether "},{"kind":"code","text":"`Ok`"},{"kind":"text","text":" was clicked or not."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":60,"name":"message","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The message to show."}]},"type":{"type":"intrinsic","name":"string"}},{"id":61,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The dialog's options. If a string, it represents the dialog title."}]},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","id":31,"name":"ConfirmDialogOptions"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":50,"name":"message","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"dialog.ts","line":224,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L224"}],"signatures":[{"id":51,"name":"message","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Shows a message dialog with an "},{"kind":"code","text":"`Ok`"},{"kind":"text","text":" button."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { message } from '@tauri-apps/api/dialog';\nawait message('Tauri is awesome', 'Tauri');\nawait message('File not found', { title: 'Tauri', type: 'error' });\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":52,"name":"message","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The message to show."}]},"type":{"type":"intrinsic","name":"string"}},{"id":53,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The dialog's options. If a string, it represents the dialog title."}]},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","id":27,"name":"MessageDialogOptions"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":36,"name":"open","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"dialog.ts","line":144,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L144"},{"fileName":"dialog.ts","line":147,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L147"},{"fileName":"dialog.ts","line":150,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L150"},{"fileName":"dialog.ts","line":153,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L153"}],"signatures":[{"id":37,"name":"open","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Open a file/directory selection dialog.\n\nThe selected paths are added to the filesystem and asset protocol allowlist scopes.\nWhen security is more important than the easy of use of this API,\nprefer writing a dedicated command instead.\n\nNote that the allowlist scope change is not persisted, so the values are cleared when the application is restarted.\nYou can save it to the filesystem using [tauri-plugin-persisted-scope](https://github.com/tauri-apps/tauri-plugin-persisted-scope)."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { open } from '@tauri-apps/api/dialog';\n// Open a selection dialog for image files\nconst selected = await open({\n multiple: true,\n filters: [{\n name: 'Image',\n extensions: ['png', 'jpeg']\n }]\n});\n```"},{"kind":"text","text":"\nNote that the "},{"kind":"code","text":"`open`"},{"kind":"text","text":" function returns a conditional type depending on the "},{"kind":"code","text":"`multiple`"},{"kind":"text","text":" option:\n- false (default) -> "},{"kind":"code","text":"`Promise`"},{"kind":"text","text":"\n- true -> "},{"kind":"code","text":"`Promise`"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to the selected path(s)"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":38,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"intersection","types":[{"type":"reference","id":16,"name":"OpenDialogOptions"},{"type":"reflection","declaration":{"id":39,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"children":[{"id":40,"name":"multiple","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"dialog.ts","line":145,"character":34,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L145"}],"type":{"type":"literal","value":false}}],"groups":[{"title":"Properties","children":[40]}],"sources":[{"fileName":"dialog.ts","line":145,"character":32,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L145"}]}}]}}],"type":{"type":"reference","typeArguments":[{"type":"union","types":[{"type":"literal","value":null},{"type":"intrinsic","name":"string"}]}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}},{"id":41,"name":"open","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":42,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"intersection","types":[{"type":"reference","id":16,"name":"OpenDialogOptions"},{"type":"reflection","declaration":{"id":43,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"children":[{"id":44,"name":"multiple","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"dialog.ts","line":148,"character":34,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L148"}],"type":{"type":"literal","value":true}}],"groups":[{"title":"Properties","children":[44]}],"sources":[{"fileName":"dialog.ts","line":148,"character":32,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L148"}]}}]}}],"type":{"type":"reference","typeArguments":[{"type":"union","types":[{"type":"literal","value":null},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}]}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}},{"id":45,"name":"open","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":46,"name":"options","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":16,"name":"OpenDialogOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"union","types":[{"type":"literal","value":null},{"type":"array","elementType":{"type":"intrinsic","name":"string"}},{"type":"intrinsic","name":"string"}]}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":47,"name":"save","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"dialog.ts","line":193,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L193"}],"signatures":[{"id":48,"name":"save","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Open a file/directory save dialog.\n\nThe selected path is added to the filesystem and asset protocol allowlist scopes.\nWhen security is more important than the easy of use of this API,\nprefer writing a dedicated command instead.\n\nNote that the allowlist scope change is not persisted, so the values are cleared when the application is restarted.\nYou can save it to the filesystem using [tauri-plugin-persisted-scope](https://github.com/tauri-apps/tauri-plugin-persisted-scope)."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { save } from '@tauri-apps/api/dialog';\nconst filePath = await save({\n filters: [{\n name: 'Image',\n extensions: ['png', 'jpeg']\n }]\n});\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to the selected path."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":49,"name":"options","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":23,"name":"SaveDialogOptions"},"defaultValue":"{}"}],"type":{"type":"reference","typeArguments":[{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"literal","value":null}]}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Interfaces","children":[31,13,27,16,23]},{"title":"Functions","children":[54,58,50,36,47]}],"sources":[{"fileName":"dialog.ts","line":31,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/dialog.ts#L31"}]},{"id":62,"name":"event","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"The event system allows you to emit events to the backend and listen to events from it.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.event`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":"."}]},"children":[{"id":64,"name":"TauriEvent","kind":8,"kindString":"Enumeration","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"children":[{"id":78,"name":"CHECK_UPDATE","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":34,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L34"}],"type":{"type":"literal","value":"tauri://update"}},{"id":82,"name":"DOWNLOAD_PROGRESS","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":38,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L38"}],"type":{"type":"literal","value":"tauri://update-download-progress"}},{"id":80,"name":"INSTALL_UPDATE","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":36,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L36"}],"type":{"type":"literal","value":"tauri://update-install"}},{"id":77,"name":"MENU","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":33,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L33"}],"type":{"type":"literal","value":"tauri://menu"}},{"id":81,"name":"STATUS_UPDATE","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":37,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L37"}],"type":{"type":"literal","value":"tauri://update-status"}},{"id":79,"name":"UPDATE_AVAILABLE","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":35,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L35"}],"type":{"type":"literal","value":"tauri://update-available"}},{"id":71,"name":"WINDOW_BLUR","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":27,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L27"}],"type":{"type":"literal","value":"tauri://blur"}},{"id":67,"name":"WINDOW_CLOSE_REQUESTED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":23,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L23"}],"type":{"type":"literal","value":"tauri://close-requested"}},{"id":68,"name":"WINDOW_CREATED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":24,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L24"}],"type":{"type":"literal","value":"tauri://window-created"}},{"id":69,"name":"WINDOW_DESTROYED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":25,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L25"}],"type":{"type":"literal","value":"tauri://destroyed"}},{"id":74,"name":"WINDOW_FILE_DROP","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":30,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L30"}],"type":{"type":"literal","value":"tauri://file-drop"}},{"id":76,"name":"WINDOW_FILE_DROP_CANCELLED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":32,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L32"}],"type":{"type":"literal","value":"tauri://file-drop-cancelled"}},{"id":75,"name":"WINDOW_FILE_DROP_HOVER","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":31,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L31"}],"type":{"type":"literal","value":"tauri://file-drop-hover"}},{"id":70,"name":"WINDOW_FOCUS","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":26,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L26"}],"type":{"type":"literal","value":"tauri://focus"}},{"id":66,"name":"WINDOW_MOVED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":22,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L22"}],"type":{"type":"literal","value":"tauri://move"}},{"id":65,"name":"WINDOW_RESIZED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":21,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L21"}],"type":{"type":"literal","value":"tauri://resize"}},{"id":72,"name":"WINDOW_SCALE_FACTOR_CHANGED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":28,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L28"}],"type":{"type":"literal","value":"tauri://scale-change"}},{"id":73,"name":"WINDOW_THEME_CHANGED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":29,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L29"}],"type":{"type":"literal","value":"tauri://theme-changed"}}],"groups":[{"title":"Enumeration Members","children":[78,82,80,77,81,79,71,67,68,69,74,76,75,70,66,65,72,73]}],"sources":[{"fileName":"event.ts","line":20,"character":12,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L20"}]},{"id":1096,"name":"Event","kind":256,"kindString":"Interface","flags":{},"children":[{"id":1097,"name":"event","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name"}]},"sources":[{"fileName":"helpers/event.ts","line":12,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/helpers/event.ts#L12"}],"type":{"type":"reference","id":63,"name":"EventName"}},{"id":1099,"name":"id","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Event identifier used to unlisten"}]},"sources":[{"fileName":"helpers/event.ts","line":16,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/helpers/event.ts#L16"}],"type":{"type":"intrinsic","name":"number"}},{"id":1100,"name":"payload","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Event payload"}]},"sources":[{"fileName":"helpers/event.ts","line":18,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/helpers/event.ts#L18"}],"type":{"type":"reference","id":1101,"name":"T"}},{"id":1098,"name":"windowLabel","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The label of the window that emitted this event."}]},"sources":[{"fileName":"helpers/event.ts","line":14,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/helpers/event.ts#L14"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[1097,1099,1100,1098]}],"sources":[{"fileName":"helpers/event.ts","line":10,"character":17,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/helpers/event.ts#L10"}],"typeParameters":[{"id":1101,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}]},{"id":1102,"name":"EventCallback","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"helpers/event.ts","line":21,"character":12,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/helpers/event.ts#L21"}],"typeParameters":[{"id":1106,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"type":{"type":"reflection","declaration":{"id":1103,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"helpers/event.ts","line":21,"character":31,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/helpers/event.ts#L21"}],"signatures":[{"id":1104,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":1105,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1096,"typeArguments":[{"type":"reference","id":1106,"name":"T"}],"name":"Event"}}],"type":{"type":"intrinsic","name":"void"}}]}}},{"id":63,"name":"EventName","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"event.ts","line":15,"character":12,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L15"}],"type":{"type":"union","types":[{"type":"template-literal","head":"","tail":[[{"type":"reference","id":64,"name":"TauriEvent"},""]]},{"type":"intersection","types":[{"type":"intrinsic","name":"string"},{"type":"reference","typeArguments":[{"type":"intrinsic","name":"never"},{"type":"intrinsic","name":"never"}],"name":"Record","qualifiedName":"Record","package":"typescript"}]}]}},{"id":1107,"name":"UnlistenFn","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"helpers/event.ts","line":23,"character":12,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/helpers/event.ts#L23"}],"type":{"type":"reflection","declaration":{"id":1108,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"helpers/event.ts","line":23,"character":25,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/helpers/event.ts#L23"}],"signatures":[{"id":1109,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"intrinsic","name":"void"}}]}}},{"id":93,"name":"emit","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"event.ts","line":112,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L112"}],"signatures":[{"id":94,"name":"emit","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Emits an event to the backend."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { emit } from '@tauri-apps/api/event';\nawait emit('frontend-loaded', { loggedIn: true, token: 'authToken' });\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":95,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name. Must include only alphanumeric characters, "},{"kind":"code","text":"`-`"},{"kind":"text","text":", "},{"kind":"code","text":"`/`"},{"kind":"text","text":", "},{"kind":"code","text":"`:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`_`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":96,"name":"payload","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"intrinsic","name":"unknown"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":83,"name":"listen","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"event.ts","line":62,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L62"}],"signatures":[{"id":84,"name":"listen","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to an event from the backend."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { listen } from '@tauri-apps/api/event';\nconst unlisten = await listen('error', (event) => {\n console.log(`Got error in window ${event.windowLabel}, payload: ${event.payload}`);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"typeParameter":[{"id":85,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":86,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name. Must include only alphanumeric characters, "},{"kind":"code","text":"`-`"},{"kind":"text","text":", "},{"kind":"code","text":"`/`"},{"kind":"text","text":", "},{"kind":"code","text":"`:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`_`"},{"kind":"text","text":"."}]},"type":{"type":"reference","id":63,"name":"EventName"}},{"id":87,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event handler callback."}]},"type":{"type":"reference","id":1102,"typeArguments":[{"type":"reference","id":85,"name":"T"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1107,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":88,"name":"once","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"event.ts","line":93,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L93"}],"signatures":[{"id":89,"name":"once","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to an one-off event from the backend."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { once } from '@tauri-apps/api/event';\ninterface LoadedPayload {\n loggedIn: boolean,\n token: string\n}\nconst unlisten = await once('loaded', (event) => {\n console.log(`App is loaded, loggedIn: ${event.payload.loggedIn}, token: ${event.payload.token}`);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"typeParameter":[{"id":90,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":91,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name. Must include only alphanumeric characters, "},{"kind":"code","text":"`-`"},{"kind":"text","text":", "},{"kind":"code","text":"`/`"},{"kind":"text","text":", "},{"kind":"code","text":"`:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`_`"},{"kind":"text","text":"."}]},"type":{"type":"reference","id":63,"name":"EventName"}},{"id":92,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1102,"typeArguments":[{"type":"reference","id":90,"name":"T"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1107,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Enumerations","children":[64]},{"title":"Interfaces","children":[1096]},{"title":"Type Aliases","children":[1102,63,1107]},{"title":"Functions","children":[93,83,88]}],"sources":[{"fileName":"event.ts","line":12,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/event.ts#L12"}]},{"id":97,"name":"globalShortcut","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Register global shortcuts.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.globalShortcut`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be added to ["},{"kind":"code","text":"`tauri.allowlist.globalShortcut`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.globalshortcut) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"globalShortcut\": {\n \"all\": true // enable all global shortcut APIs\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security."}]},"children":[{"id":98,"name":"ShortcutHandler","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"globalShortcut.ts","line":29,"character":12,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/globalShortcut.ts#L29"}],"type":{"type":"reflection","declaration":{"id":99,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"globalShortcut.ts","line":29,"character":30,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/globalShortcut.ts#L29"}],"signatures":[{"id":100,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":101,"name":"shortcut","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"intrinsic","name":"void"}}]}}},{"id":110,"name":"isRegistered","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"globalShortcut.ts","line":101,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/globalShortcut.ts#L101"}],"signatures":[{"id":111,"name":"isRegistered","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Determines whether the given shortcut is registered by this application or not."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { isRegistered } from '@tauri-apps/api/globalShortcut';\nconst isRegistered = await isRegistered('CommandOrControl+P');\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":112,"name":"shortcut","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Array of shortcut definitions, modifiers and key separated by \"+\" e.g. CmdOrControl+Q"}]},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":102,"name":"register","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"globalShortcut.ts","line":46,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/globalShortcut.ts#L46"}],"signatures":[{"id":103,"name":"register","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Register a global shortcut."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { register } from '@tauri-apps/api/globalShortcut';\nawait register('CommandOrControl+Shift+C', () => {\n console.log('Shortcut triggered');\n});\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":104,"name":"shortcut","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Shortcut definition, modifiers and key separated by \"+\" e.g. CmdOrControl+Q"}]},"type":{"type":"intrinsic","name":"string"}},{"id":105,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Shortcut handler callback - takes the triggered shortcut as argument"}]},"type":{"type":"reference","id":98,"name":"ShortcutHandler"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":106,"name":"registerAll","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"globalShortcut.ts","line":75,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/globalShortcut.ts#L75"}],"signatures":[{"id":107,"name":"registerAll","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Register a collection of global shortcuts."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { registerAll } from '@tauri-apps/api/globalShortcut';\nawait registerAll(['CommandOrControl+Shift+C', 'Ctrl+Alt+F12'], (shortcut) => {\n console.log(`Shortcut ${shortcut} triggered`);\n});\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":108,"name":"shortcuts","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Array of shortcut definitions, modifiers and key separated by \"+\" e.g. CmdOrControl+Q"}]},"type":{"type":"array","elementType":{"type":"intrinsic","name":"string"}}},{"id":109,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Shortcut handler callback - takes the triggered shortcut as argument"}]},"type":{"type":"reference","id":98,"name":"ShortcutHandler"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":113,"name":"unregister","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"globalShortcut.ts","line":123,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/globalShortcut.ts#L123"}],"signatures":[{"id":114,"name":"unregister","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Unregister a global shortcut."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { unregister } from '@tauri-apps/api/globalShortcut';\nawait unregister('CmdOrControl+Space');\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":115,"name":"shortcut","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"shortcut definition, modifiers and key separated by \"+\" e.g. CmdOrControl+Q"}]},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":116,"name":"unregisterAll","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"globalShortcut.ts","line":143,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/globalShortcut.ts#L143"}],"signatures":[{"id":117,"name":"unregisterAll","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Unregisters all shortcuts registered by the application."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { unregisterAll } from '@tauri-apps/api/globalShortcut';\nawait unregisterAll();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Type Aliases","children":[98]},{"title":"Functions","children":[110,102,106,113,116]}],"sources":[{"fileName":"globalShortcut.ts","line":26,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/globalShortcut.ts#L26"}]},{"id":118,"name":"http","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Access the HTTP client written in Rust.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.http`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be allowlisted on "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"http\": {\n \"all\": true, // enable all http APIs\n \"request\": true // enable HTTP request API\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security.\n\n## Security\n\nThis API has a scope configuration that forces you to restrict the URLs and paths that can be accessed using glob patterns.\n\nFor instance, this scope configuration only allows making HTTP requests to the GitHub API for the "},{"kind":"code","text":"`tauri-apps`"},{"kind":"text","text":" organization:\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"http\": {\n \"scope\": [\"https://api.github.com/repos/tauri-apps/*\"]\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nTrying to execute any API with a URL not configured on the scope results in a promise rejection due to denied access."}]},"children":[{"id":214,"name":"ResponseType","kind":8,"kindString":"Enumeration","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":217,"name":"Binary","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"http.ts","line":74,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L74"}],"type":{"type":"literal","value":3}},{"id":215,"name":"JSON","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"http.ts","line":72,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L72"}],"type":{"type":"literal","value":1}},{"id":216,"name":"Text","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"http.ts","line":73,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L73"}],"type":{"type":"literal","value":2}}],"groups":[{"title":"Enumeration Members","children":[217,215,216]}],"sources":[{"fileName":"http.ts","line":71,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L71"}]},{"id":145,"name":"Body","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"The body object to be used on POST and PUT requests."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":163,"name":"payload","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":95,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L95"}],"type":{"type":"intrinsic","name":"unknown"}},{"id":162,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":94,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L94"}],"type":{"type":"intrinsic","name":"string"}},{"id":155,"name":"bytes","kind":2048,"kindString":"Method","flags":{"isStatic":true},"sources":[{"fileName":"http.ts","line":217,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L217"}],"signatures":[{"id":156,"name":"bytes","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a new byte array body."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Body } from \"@tauri-apps/api/http\"\nBody.bytes(new Uint8Array([1, 2, 3]));\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The body object ready to be used on the POST and PUT requests."}]}]},"parameters":[{"id":157,"name":"bytes","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The body byte array."}]},"type":{"type":"union","types":[{"type":"reference","typeArguments":[{"type":"intrinsic","name":"number"}],"name":"Iterable","qualifiedName":"Iterable","package":"typescript"},{"type":"reference","name":"ArrayBuffer","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer","qualifiedName":"ArrayBuffer","package":"typescript"},{"type":"reference","typeArguments":[{"type":"intrinsic","name":"number"}],"name":"ArrayLike","qualifiedName":"ArrayLike","package":"typescript"}]}}],"type":{"type":"reference","id":145,"name":"Body"}}]},{"id":146,"name":"form","kind":2048,"kindString":"Method","flags":{"isStatic":true},"sources":[{"fileName":"http.ts","line":134,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L134"}],"signatures":[{"id":147,"name":"form","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a new form data body. The form data is an object where each key is the entry name,\nand the value is either a string or a file object.\n\nBy default it sets the "},{"kind":"code","text":"`application/x-www-form-urlencoded`"},{"kind":"text","text":" Content-Type header,\nbut you can set it to "},{"kind":"code","text":"`multipart/form-data`"},{"kind":"text","text":" if the Cargo feature "},{"kind":"code","text":"`http-multipart`"},{"kind":"text","text":" is enabled.\n\nNote that a file path must be allowed in the "},{"kind":"code","text":"`fs`"},{"kind":"text","text":" allowlist scope."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Body } from \"@tauri-apps/api/http\"\nconst body = Body.form({\n key: 'value',\n image: {\n file: '/path/to/file', // either a path or an array buffer of the file contents\n mime: 'image/jpeg', // optional\n fileName: 'image.jpg' // optional\n }\n});\n\n// alternatively, use a FormData:\nconst form = new FormData();\nform.append('key', 'value');\nform.append('image', file, 'image.png');\nconst formBody = Body.form(form);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The body object ready to be used on the POST and PUT requests."}]}]},"parameters":[{"id":148,"name":"data","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The body data."}]},"type":{"type":"union","types":[{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"reference","id":125,"name":"Part"}],"name":"Record","qualifiedName":"Record","package":"typescript"},{"type":"reference","name":"FormData","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/API/FormData","qualifiedName":"FormData","package":"typescript"}]}}],"type":{"type":"reference","id":145,"name":"Body"}}]},{"id":149,"name":"json","kind":2048,"kindString":"Method","flags":{"isStatic":true},"sources":[{"fileName":"http.ts","line":185,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L185"}],"signatures":[{"id":150,"name":"json","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a new JSON body."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Body } from \"@tauri-apps/api/http\"\nBody.json({\n registered: true,\n name: 'tauri'\n});\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The body object ready to be used on the POST and PUT requests."}]}]},"parameters":[{"id":151,"name":"data","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The body JSON object."}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"any"},{"type":"intrinsic","name":"any"}],"name":"Record","qualifiedName":"Record","package":"typescript"}}],"type":{"type":"reference","id":145,"name":"Body"}}]},{"id":152,"name":"text","kind":2048,"kindString":"Method","flags":{"isStatic":true},"sources":[{"fileName":"http.ts","line":201,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L201"}],"signatures":[{"id":153,"name":"text","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a new UTF-8 string body."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Body } from \"@tauri-apps/api/http\"\nBody.text('The body content as a string');\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The body object ready to be used on the POST and PUT requests."}]}]},"parameters":[{"id":154,"name":"value","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The body string."}]},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","id":145,"name":"Body"}}]}],"groups":[{"title":"Properties","children":[163,162]},{"title":"Methods","children":[155,146,149,152]}],"sources":[{"fileName":"http.ts","line":93,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L93"}]},{"id":164,"name":"Client","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":168,"name":"id","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":303,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L303"}],"type":{"type":"intrinsic","name":"number"}},{"id":197,"name":"delete","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"http.ts","line":484,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L484"}],"signatures":[{"id":198,"name":"delete","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Makes a DELETE request."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient } from '@tauri-apps/api/http';\nconst client = await getClient();\nconst response = await client.delete('http://localhost:3003/users/1');\n```"}]}]},"typeParameter":[{"id":199,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":200,"name":"url","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":201,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":135,"name":"RequestOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":202,"typeArguments":[{"type":"reference","id":199,"name":"T"}],"name":"Response"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":169,"name":"drop","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"http.ts","line":318,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L318"}],"signatures":[{"id":170,"name":"drop","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Drops the client instance."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient } from '@tauri-apps/api/http';\nconst client = await getClient();\nawait client.drop();\n```"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":175,"name":"get","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"http.ts","line":389,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L389"}],"signatures":[{"id":176,"name":"get","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Makes a GET request."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient, ResponseType } from '@tauri-apps/api/http';\nconst client = await getClient();\nconst response = await client.get('http://localhost:3003/users', {\n timeout: 30,\n // the expected response type\n responseType: ResponseType.JSON\n});\n```"}]}]},"typeParameter":[{"id":177,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":178,"name":"url","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":179,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":135,"name":"RequestOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":202,"typeArguments":[{"type":"reference","id":177,"name":"T"}],"name":"Response"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":192,"name":"patch","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"http.ts","line":467,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L467"}],"signatures":[{"id":193,"name":"patch","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Makes a PATCH request."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient, Body } from '@tauri-apps/api/http';\nconst client = await getClient();\nconst response = await client.patch('http://localhost:3003/users/1', {\n body: Body.json({ email: 'contact@tauri.app' })\n});\n```"}]}]},"typeParameter":[{"id":194,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":195,"name":"url","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":196,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":135,"name":"RequestOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":202,"typeArguments":[{"type":"reference","id":194,"name":"T"}],"name":"Response"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":180,"name":"post","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"http.ts","line":413,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L413"}],"signatures":[{"id":181,"name":"post","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Makes a POST request."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient, Body, ResponseType } from '@tauri-apps/api/http';\nconst client = await getClient();\nconst response = await client.post('http://localhost:3003/users', {\n body: Body.json({\n name: 'tauri',\n password: 'awesome'\n }),\n // in this case the server returns a simple string\n responseType: ResponseType.Text,\n});\n```"}]}]},"typeParameter":[{"id":182,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":183,"name":"url","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":184,"name":"body","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":145,"name":"Body"}},{"id":185,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":135,"name":"RequestOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":202,"typeArguments":[{"type":"reference","id":182,"name":"T"}],"name":"Response"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":186,"name":"put","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"http.ts","line":443,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L443"}],"signatures":[{"id":187,"name":"put","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Makes a PUT request."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient, Body } from '@tauri-apps/api/http';\nconst client = await getClient();\nconst response = await client.put('http://localhost:3003/users/1', {\n body: Body.form({\n file: {\n file: '/home/tauri/avatar.png',\n mime: 'image/png',\n fileName: 'avatar.png'\n }\n })\n});\n```"}]}]},"typeParameter":[{"id":188,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":189,"name":"url","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":190,"name":"body","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":145,"name":"Body"}},{"id":191,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":135,"name":"RequestOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":202,"typeArguments":[{"type":"reference","id":188,"name":"T"}],"name":"Response"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":171,"name":"request","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"http.ts","line":340,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L340"}],"signatures":[{"id":172,"name":"request","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Makes an HTTP request."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient } from '@tauri-apps/api/http';\nconst client = await getClient();\nconst response = await client.request({\n method: 'GET',\n url: 'http://localhost:3003/users',\n});\n```"}]}]},"typeParameter":[{"id":173,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":174,"name":"options","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":127,"name":"HttpOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":202,"typeArguments":[{"type":"reference","id":173,"name":"T"}],"name":"Response"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Properties","children":[168]},{"title":"Methods","children":[197,169,175,192,180,186,171]}],"sources":[{"fileName":"http.ts","line":302,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L302"}]},{"id":202,"name":"Response","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"Response object."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":212,"name":"data","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The response data."}]},"sources":[{"fileName":"http.ts","line":286,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L286"}],"type":{"type":"reference","name":"T"}},{"id":210,"name":"headers","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The response headers."}]},"sources":[{"fileName":"http.ts","line":282,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L282"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"string"}],"name":"Record","qualifiedName":"Record","package":"typescript"}},{"id":209,"name":"ok","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"A boolean indicating whether the response was successful (status in the range 200–299) or not."}]},"sources":[{"fileName":"http.ts","line":280,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L280"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":211,"name":"rawHeaders","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The response raw headers."}]},"sources":[{"fileName":"http.ts","line":284,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L284"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}],"name":"Record","qualifiedName":"Record","package":"typescript"}},{"id":208,"name":"status","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The response status code."}]},"sources":[{"fileName":"http.ts","line":278,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L278"}],"type":{"type":"intrinsic","name":"number"}},{"id":207,"name":"url","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The request URL."}]},"sources":[{"fileName":"http.ts","line":276,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L276"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[212,210,209,211,208,207]}],"sources":[{"fileName":"http.ts","line":274,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L274"}],"typeParameters":[{"id":213,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}]},{"id":122,"name":"ClientOptions","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":124,"name":"connectTimeout","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":65,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L65"}],"type":{"type":"union","types":[{"type":"intrinsic","name":"number"},{"type":"reference","id":119,"name":"Duration"}]}},{"id":123,"name":"maxRedirections","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Defines the maximum number of redirects the client should follow.\nIf set to 0, no redirects will be followed."}]},"sources":[{"fileName":"http.ts","line":64,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L64"}],"type":{"type":"intrinsic","name":"number"}}],"groups":[{"title":"Properties","children":[124,123]}],"sources":[{"fileName":"http.ts","line":59,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L59"}]},{"id":119,"name":"Duration","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":121,"name":"nanos","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":53,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L53"}],"type":{"type":"intrinsic","name":"number"}},{"id":120,"name":"secs","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":52,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L52"}],"type":{"type":"intrinsic","name":"number"}}],"groups":[{"title":"Properties","children":[121,120]}],"sources":[{"fileName":"http.ts","line":51,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L51"}]},{"id":218,"name":"FilePart","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":219,"name":"file","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":81,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L81"}],"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","id":222,"name":"T"}]}},{"id":221,"name":"fileName","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":83,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L83"}],"type":{"type":"intrinsic","name":"string"}},{"id":220,"name":"mime","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":82,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L82"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[219,221,220]}],"sources":[{"fileName":"http.ts","line":80,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L80"}],"typeParameters":[{"id":222,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}]},{"id":127,"name":"HttpOptions","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Options object sent to the backend."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":132,"name":"body","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":250,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L250"}],"type":{"type":"reference","id":145,"name":"Body"}},{"id":130,"name":"headers","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":248,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L248"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"any"}],"name":"Record","qualifiedName":"Record","package":"typescript"}},{"id":128,"name":"method","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":246,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L246"}],"type":{"type":"reference","id":126,"name":"HttpVerb"}},{"id":131,"name":"query","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":249,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L249"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"any"}],"name":"Record","qualifiedName":"Record","package":"typescript"}},{"id":134,"name":"responseType","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":252,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L252"}],"type":{"type":"reference","id":214,"name":"ResponseType"}},{"id":133,"name":"timeout","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":251,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L251"}],"type":{"type":"union","types":[{"type":"intrinsic","name":"number"},{"type":"reference","id":119,"name":"Duration"}]}},{"id":129,"name":"url","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":247,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L247"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[132,130,128,131,134,133,129]}],"sources":[{"fileName":"http.ts","line":245,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L245"}]},{"id":136,"name":"FetchOptions","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[{"kind":"text","text":"Options for the "},{"kind":"code","text":"`fetch`"},{"kind":"text","text":" API."}]},"sources":[{"fileName":"http.ts","line":258,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L258"}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":127,"name":"HttpOptions"},{"type":"literal","value":"url"}],"name":"Omit","qualifiedName":"Omit","package":"typescript"}},{"id":126,"name":"HttpVerb","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[{"kind":"text","text":"The request HTTP verb."}]},"sources":[{"fileName":"http.ts","line":229,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L229"}],"type":{"type":"union","types":[{"type":"literal","value":"GET"},{"type":"literal","value":"POST"},{"type":"literal","value":"PUT"},{"type":"literal","value":"DELETE"},{"type":"literal","value":"PATCH"},{"type":"literal","value":"HEAD"},{"type":"literal","value":"OPTIONS"},{"type":"literal","value":"CONNECT"},{"type":"literal","value":"TRACE"}]}},{"id":125,"name":"Part","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"http.ts","line":86,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L86"}],"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","name":"Uint8Array","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array","qualifiedName":"Uint8Array","package":"typescript"},{"type":"reference","id":218,"typeArguments":[{"type":"reference","name":"Uint8Array","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array","qualifiedName":"Uint8Array","package":"typescript"}],"name":"FilePart"}]}},{"id":135,"name":"RequestOptions","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[{"kind":"text","text":"Request options."}]},"sources":[{"fileName":"http.ts","line":256,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L256"}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":127,"name":"HttpOptions"},{"type":"union","types":[{"type":"literal","value":"method"},{"type":"literal","value":"url"}]}],"name":"Omit","qualifiedName":"Omit","package":"typescript"}},{"id":140,"name":"fetch","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"http.ts","line":531,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L531"}],"signatures":[{"id":141,"name":"fetch","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Perform an HTTP request using the default client."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { fetch } from '@tauri-apps/api/http';\nconst response = await fetch('http://localhost:3003/users/2', {\n method: 'GET',\n timeout: 30,\n});\n```"}]}]},"typeParameter":[{"id":142,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":143,"name":"url","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":144,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":136,"name":"FetchOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":202,"typeArguments":[{"type":"reference","id":142,"name":"T"}],"name":"Response"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":137,"name":"getClient","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"http.ts","line":507,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L507"}],"signatures":[{"id":138,"name":"getClient","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a new client using the specified options."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient } from '@tauri-apps/api/http';\nconst client = await getClient();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to the client instance."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":139,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Client configuration."}]},"type":{"type":"reference","id":122,"name":"ClientOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":164,"name":"Client"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Enumerations","children":[214]},{"title":"Classes","children":[145,164,202]},{"title":"Interfaces","children":[122,119,218,127]},{"title":"Type Aliases","children":[136,126,125,135]},{"title":"Functions","children":[140,137]}],"sources":[{"fileName":"http.ts","line":46,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/http.ts#L46"}]},{"id":223,"name":"mocks","kind":2,"kindString":"Module","flags":{},"children":[{"id":235,"name":"clearMocks","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"mocks.ts","line":171,"character":16,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/mocks.ts#L171"}],"signatures":[{"id":236,"name":"clearMocks","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Clears mocked functions/data injected by the other functions in this module.\nWhen using a test runner that doesn't provide a fresh window object for each test, calling this function will reset tauri specific properties.\n\n# Example\n\n"},{"kind":"code","text":"```js\nimport { mockWindows, clearMocks } from \"@tauri-apps/api/mocks\"\n\nafterEach(() => {\n clearMocks()\n})\n\ntest(\"mocked windows\", () => {\n mockWindows(\"main\", \"second\", \"third\");\n\n expect(window).toHaveProperty(\"__TAURI_METADATA__\")\n})\n\ntest(\"no mocked windows\", () => {\n expect(window).not.toHaveProperty(\"__TAURI_METADATA__\")\n})\n```"}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"intrinsic","name":"void"}}]},{"id":224,"name":"mockIPC","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"mocks.ts","line":65,"character":16,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/mocks.ts#L65"}],"signatures":[{"id":225,"name":"mockIPC","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Intercepts all IPC requests with the given mock handler.\n\nThis function can be used when testing tauri frontend applications or when running the frontend in a Node.js context during static site generation.\n\n# Examples\n\nTesting setup using vitest:\n"},{"kind":"code","text":"```js\nimport { mockIPC, clearMocks } from \"@tauri-apps/api/mocks\"\nimport { invoke } from \"@tauri-apps/api/tauri\"\n\nafterEach(() => {\n clearMocks()\n})\n\ntest(\"mocked command\", () => {\n mockIPC((cmd, args) => {\n switch (cmd) {\n case \"add\":\n return (args.a as number) + (args.b as number);\n default:\n break;\n }\n });\n\n expect(invoke('add', { a: 12, b: 15 })).resolves.toBe(27);\n})\n```"},{"kind":"text","text":"\n\nThe callback function can also return a Promise:\n"},{"kind":"code","text":"```js\nimport { mockIPC, clearMocks } from \"@tauri-apps/api/mocks\"\nimport { invoke } from \"@tauri-apps/api/tauri\"\n\nafterEach(() => {\n clearMocks()\n})\n\ntest(\"mocked command\", () => {\n mockIPC((cmd, args) => {\n if(cmd === \"get_data\") {\n return fetch(\"https://example.com/data.json\")\n .then((response) => response.json())\n }\n });\n\n expect(invoke('get_data')).resolves.toBe({ foo: 'bar' });\n})\n```"}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":226,"name":"cb","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":227,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"mocks.ts","line":66,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/mocks.ts#L66"}],"signatures":[{"id":228,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":229,"name":"cmd","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":230,"name":"args","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"unknown"}],"name":"Record","qualifiedName":"Record","package":"typescript"}}],"type":{"type":"intrinsic","name":"any"}}]}}}],"type":{"type":"intrinsic","name":"void"}}]},{"id":231,"name":"mockWindows","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"mocks.ts","line":135,"character":16,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/mocks.ts#L135"}],"signatures":[{"id":232,"name":"mockWindows","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Mocks one or many window labels.\nIn non-tauri context it is required to call this function *before* using the "},{"kind":"code","text":"`@tauri-apps/api/window`"},{"kind":"text","text":" module.\n\nThis function only mocks the *presence* of windows,\nwindow properties (e.g. width and height) can be mocked like regular IPC calls using the "},{"kind":"code","text":"`mockIPC`"},{"kind":"text","text":" function.\n\n# Examples\n\n"},{"kind":"code","text":"```js\nimport { mockWindows } from \"@tauri-apps/api/mocks\";\nimport { getCurrent } from \"@tauri-apps/api/window\";\n\nmockWindows(\"main\", \"second\", \"third\");\n\nconst win = getCurrent();\n\nwin.label // \"main\"\n```"},{"kind":"text","text":"\n\n"},{"kind":"code","text":"```js\nimport { mockWindows } from \"@tauri-apps/api/mocks\";\n\nmockWindows(\"main\", \"second\", \"third\");\n\nmockIPC((cmd, args) => {\n if (cmd === \"tauri\") {\n if (\n args?.__tauriModule === \"Window\" &&\n args?.message?.cmd === \"manage\" &&\n args?.message?.data?.cmd?.type === \"close\"\n ) {\n console.log('closing window!');\n }\n }\n});\n\nconst { getCurrent } = await import(\"@tauri-apps/api/window\");\n\nconst win = getCurrent();\nawait win.close(); // this will cause the mocked IPC handler to log to the console.\n```"}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":233,"name":"current","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Label of window this JavaScript context is running in."}]},"type":{"type":"intrinsic","name":"string"}},{"id":234,"name":"additionalWindows","kind":32768,"kindString":"Parameter","flags":{"isRest":true},"comment":{"summary":[{"kind":"text","text":"Label of additional windows the app has."}]},"type":{"type":"array","elementType":{"type":"intrinsic","name":"string"}}}],"type":{"type":"intrinsic","name":"void"}}]}],"groups":[{"title":"Functions","children":[235,224,231]}],"sources":[{"fileName":"mocks.ts","line":5,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/mocks.ts#L5"}]},{"id":237,"name":"notification","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Send toast notifications (brief auto-expiring OS window element) to your user.\nCan also be used with the Notification Web API.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.notification`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be added to ["},{"kind":"code","text":"`tauri.allowlist.notification`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.notification) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"notification\": {\n \"all\": true // enable all notification APIs\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security."}]},"children":[{"id":238,"name":"Options","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Options to send a notification."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":240,"name":"body","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Optional notification body."}]},"sources":[{"fileName":"notification.ts","line":38,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/notification.ts#L38"}],"type":{"type":"intrinsic","name":"string"}},{"id":241,"name":"icon","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Optional notification icon."}]},"sources":[{"fileName":"notification.ts","line":40,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/notification.ts#L40"}],"type":{"type":"intrinsic","name":"string"}},{"id":239,"name":"title","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Notification title."}]},"sources":[{"fileName":"notification.ts","line":36,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/notification.ts#L36"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[240,241,239]}],"sources":[{"fileName":"notification.ts","line":34,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/notification.ts#L34"}]},{"id":242,"name":"Permission","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[{"kind":"text","text":"Possible permission values."}]},"sources":[{"fileName":"notification.ts","line":44,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/notification.ts#L44"}],"type":{"type":"union","types":[{"type":"literal","value":"granted"},{"type":"literal","value":"denied"},{"type":"literal","value":"default"}]}},{"id":248,"name":"isPermissionGranted","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"notification.ts","line":56,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/notification.ts#L56"}],"signatures":[{"id":249,"name":"isPermissionGranted","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Checks if the permission to send notifications is granted."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { isPermissionGranted } from '@tauri-apps/api/notification';\nconst permissionGranted = await isPermissionGranted();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":246,"name":"requestPermission","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"notification.ts","line":84,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/notification.ts#L84"}],"signatures":[{"id":247,"name":"requestPermission","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Requests the permission to send notifications."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { isPermissionGranted, requestPermission } from '@tauri-apps/api/notification';\nlet permissionGranted = await isPermissionGranted();\nif (!permissionGranted) {\n const permission = await requestPermission();\n permissionGranted = permission === 'granted';\n}\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to whether the user granted the permission or not."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":242,"name":"Permission"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":243,"name":"sendNotification","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"notification.ts","line":106,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/notification.ts#L106"}],"signatures":[{"id":244,"name":"sendNotification","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sends a notification to the user."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { isPermissionGranted, requestPermission, sendNotification } from '@tauri-apps/api/notification';\nlet permissionGranted = await isPermissionGranted();\nif (!permissionGranted) {\n const permission = await requestPermission();\n permissionGranted = permission === 'granted';\n}\nif (permissionGranted) {\n sendNotification('Tauri is awesome!');\n sendNotification({ title: 'TAURI', body: 'Tauri is awesome!' });\n}\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":245,"name":"options","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","id":238,"name":"Options"}]}}],"type":{"type":"intrinsic","name":"void"}}]}],"groups":[{"title":"Interfaces","children":[238]},{"title":"Type Aliases","children":[242]},{"title":"Functions","children":[248,246,243]}],"sources":[{"fileName":"notification.ts","line":27,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/notification.ts#L27"}]},{"id":250,"name":"os","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Provides operating system-related utility methods and properties.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.os`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be added to ["},{"kind":"code","text":"`tauri.allowlist.os`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.os) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"os\": {\n \"all\": true, // enable all Os APIs\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security."}]},"children":[{"id":264,"name":"Arch","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"os.ts","line":43,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/os.ts#L43"}],"type":{"type":"union","types":[{"type":"literal","value":"x86"},{"type":"literal","value":"x86_64"},{"type":"literal","value":"arm"},{"type":"literal","value":"aarch64"},{"type":"literal","value":"mips"},{"type":"literal","value":"mips64"},{"type":"literal","value":"powerpc"},{"type":"literal","value":"powerpc64"},{"type":"literal","value":"riscv64"},{"type":"literal","value":"s390x"},{"type":"literal","value":"sparc64"}]}},{"id":263,"name":"OsType","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"os.ts","line":41,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/os.ts#L41"}],"type":{"type":"union","types":[{"type":"literal","value":"Linux"},{"type":"literal","value":"Darwin"},{"type":"literal","value":"Windows_NT"}]}},{"id":262,"name":"Platform","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"os.ts","line":29,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/os.ts#L29"}],"type":{"type":"union","types":[{"type":"literal","value":"linux"},{"type":"literal","value":"darwin"},{"type":"literal","value":"ios"},{"type":"literal","value":"freebsd"},{"type":"literal","value":"dragonfly"},{"type":"literal","value":"netbsd"},{"type":"literal","value":"openbsd"},{"type":"literal","value":"solaris"},{"type":"literal","value":"android"},{"type":"literal","value":"win32"}]}},{"id":251,"name":"EOL","kind":32,"kindString":"Variable","flags":{"isConst":true},"comment":{"summary":[{"kind":"text","text":"The operating system-specific end-of-line marker.\n- "},{"kind":"code","text":"`\\n`"},{"kind":"text","text":" on POSIX\n- "},{"kind":"code","text":"`\\r\\n`"},{"kind":"text","text":" on Windows"}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"sources":[{"fileName":"os.ts","line":63,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/os.ts#L63"}],"type":{"type":"union","types":[{"type":"literal","value":"\n"},{"type":"literal","value":"\r\n"}]},"defaultValue":"..."},{"id":258,"name":"arch","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"os.ts","line":135,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/os.ts#L135"}],"signatures":[{"id":259,"name":"arch","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the operating system CPU architecture for which the tauri app was compiled.\nPossible values are "},{"kind":"code","text":"`'x86'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'x86_64'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'arm'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'aarch64'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'mips'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'mips64'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'powerpc'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'powerpc64'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'riscv64'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'s390x'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'sparc64'`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { arch } from '@tauri-apps/api/os';\nconst archName = await arch();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":264,"name":"Arch"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":252,"name":"platform","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"os.ts","line":77,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/os.ts#L77"}],"signatures":[{"id":253,"name":"platform","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns a string identifying the operating system platform.\nThe value is set at compile time. Possible values are "},{"kind":"code","text":"`'linux'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'darwin'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'ios'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'freebsd'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'dragonfly'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'netbsd'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'openbsd'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'solaris'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'android'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'win32'`"}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { platform } from '@tauri-apps/api/os';\nconst platformName = await platform();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":262,"name":"Platform"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":260,"name":"tempdir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"os.ts","line":154,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/os.ts#L154"}],"signatures":[{"id":261,"name":"tempdir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the operating system's default directory for temporary files as a string."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { tempdir } from '@tauri-apps/api/os';\nconst tempdirPath = await tempdir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":256,"name":"type","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"os.ts","line":115,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/os.ts#L115"}],"signatures":[{"id":257,"name":"type","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns "},{"kind":"code","text":"`'Linux'`"},{"kind":"text","text":" on Linux, "},{"kind":"code","text":"`'Darwin'`"},{"kind":"text","text":" on macOS, and "},{"kind":"code","text":"`'Windows_NT'`"},{"kind":"text","text":" on Windows."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { type } from '@tauri-apps/api/os';\nconst osType = await type();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":263,"name":"OsType"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":254,"name":"version","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"os.ts","line":96,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/os.ts#L96"}],"signatures":[{"id":255,"name":"version","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns a string identifying the kernel version."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { version } from '@tauri-apps/api/os';\nconst osVersion = await version();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Type Aliases","children":[264,263,262]},{"title":"Variables","children":[251]},{"title":"Functions","children":[258,252,260,256,254]}],"sources":[{"fileName":"os.ts","line":26,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/os.ts#L26"}]},{"id":265,"name":"path","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"The path module provides utilities for working with file and directory paths.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.path`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be added to ["},{"kind":"code","text":"`tauri.allowlist.path`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.path) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"path\": {\n \"all\": true, // enable all Path APIs\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security."}]},"children":[{"id":266,"name":"BaseDirectory","kind":8,"kindString":"Enumeration","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"2.0.0"}]}]},"children":[{"id":282,"name":"AppCache","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":48,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L48"}],"type":{"type":"literal","value":16}},{"id":279,"name":"AppConfig","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":45,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L45"}],"type":{"type":"literal","value":13}},{"id":280,"name":"AppData","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":46,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L46"}],"type":{"type":"literal","value":14}},{"id":281,"name":"AppLocalData","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":47,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L47"}],"type":{"type":"literal","value":15}},{"id":283,"name":"AppLog","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":49,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L49"}],"type":{"type":"literal","value":17}},{"id":267,"name":"Audio","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":33,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L33"}],"type":{"type":"literal","value":1}},{"id":268,"name":"Cache","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":34,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L34"}],"type":{"type":"literal","value":2}},{"id":269,"name":"Config","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":35,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L35"}],"type":{"type":"literal","value":3}},{"id":270,"name":"Data","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":36,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L36"}],"type":{"type":"literal","value":4}},{"id":284,"name":"Desktop","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":51,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L51"}],"type":{"type":"literal","value":18}},{"id":272,"name":"Document","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":38,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L38"}],"type":{"type":"literal","value":6}},{"id":273,"name":"Download","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":39,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L39"}],"type":{"type":"literal","value":7}},{"id":285,"name":"Executable","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":52,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L52"}],"type":{"type":"literal","value":19}},{"id":286,"name":"Font","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":53,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L53"}],"type":{"type":"literal","value":20}},{"id":287,"name":"Home","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":54,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L54"}],"type":{"type":"literal","value":21}},{"id":271,"name":"LocalData","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":37,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L37"}],"type":{"type":"literal","value":5}},{"id":274,"name":"Picture","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":40,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L40"}],"type":{"type":"literal","value":8}},{"id":275,"name":"Public","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":41,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L41"}],"type":{"type":"literal","value":9}},{"id":277,"name":"Resource","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":43,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L43"}],"type":{"type":"literal","value":11}},{"id":288,"name":"Runtime","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":55,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L55"}],"type":{"type":"literal","value":22}},{"id":278,"name":"Temp","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":44,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L44"}],"type":{"type":"literal","value":12}},{"id":289,"name":"Template","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":56,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L56"}],"type":{"type":"literal","value":23}},{"id":276,"name":"Video","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":42,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L42"}],"type":{"type":"literal","value":10}}],"groups":[{"title":"Enumeration Members","children":[282,279,280,281,283,267,268,269,270,284,272,273,285,286,287,271,274,275,277,288,278,289,276]}],"sources":[{"fileName":"path.ts","line":32,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L32"}]},{"id":338,"name":"delimiter","kind":32,"kindString":"Variable","flags":{"isConst":true},"comment":{"summary":[{"kind":"text","text":"Provides the platform-specific path segment delimiter:\n- "},{"kind":"code","text":"`;`"},{"kind":"text","text":" on Windows\n- "},{"kind":"code","text":"`:`"},{"kind":"text","text":" on POSIX"}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"sources":[{"fileName":"path.ts","line":555,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L555"}],"type":{"type":"union","types":[{"type":"literal","value":";"},{"type":"literal","value":":"}]},"defaultValue":"..."},{"id":337,"name":"sep","kind":32,"kindString":"Variable","flags":{"isConst":true},"comment":{"summary":[{"kind":"text","text":"Provides the platform-specific path segment separator:\n- "},{"kind":"code","text":"`\\` on Windows\n- `"},{"kind":"text","text":"/` on POSIX"}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"sources":[{"fileName":"path.ts","line":546,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L546"}],"type":{"type":"union","types":[{"type":"literal","value":"\\"},{"type":"literal","value":"/"}]},"defaultValue":"..."},{"id":296,"name":"appCacheDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":121,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L121"}],"signatures":[{"id":297,"name":"appCacheDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the suggested directory for your app's cache files.\nResolves to "},{"kind":"code","text":"`${cacheDir}/${bundleIdentifier}`"},{"kind":"text","text":", where "},{"kind":"code","text":"`bundleIdentifier`"},{"kind":"text","text":" is the value ["},{"kind":"code","text":"`tauri.bundle.identifier`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#bundleconfig.identifier) is configured in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appCacheDir } from '@tauri-apps/api/path';\nconst appCacheDirPath = await appCacheDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":290,"name":"appConfigDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":70,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L70"}],"signatures":[{"id":291,"name":"appConfigDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the suggested directory for your app's config files.\nResolves to "},{"kind":"code","text":"`${configDir}/${bundleIdentifier}`"},{"kind":"text","text":", where "},{"kind":"code","text":"`bundleIdentifier`"},{"kind":"text","text":" is the value ["},{"kind":"code","text":"`tauri.bundle.identifier`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#bundleconfig.identifier) is configured in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appConfigDir } from '@tauri-apps/api/path';\nconst appConfigDirPath = await appConfigDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":292,"name":"appDataDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":87,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L87"}],"signatures":[{"id":293,"name":"appDataDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the suggested directory for your app's data files.\nResolves to "},{"kind":"code","text":"`${dataDir}/${bundleIdentifier}`"},{"kind":"text","text":", where "},{"kind":"code","text":"`bundleIdentifier`"},{"kind":"text","text":" is the value ["},{"kind":"code","text":"`tauri.bundle.identifier`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#bundleconfig.identifier) is configured in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appDataDir } from '@tauri-apps/api/path';\nconst appDataDirPath = await appDataDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":294,"name":"appLocalDataDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":104,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L104"}],"signatures":[{"id":295,"name":"appLocalDataDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the suggested directory for your app's local data files.\nResolves to "},{"kind":"code","text":"`${localDataDir}/${bundleIdentifier}`"},{"kind":"text","text":", where "},{"kind":"code","text":"`bundleIdentifier`"},{"kind":"text","text":" is the value ["},{"kind":"code","text":"`tauri.bundle.identifier`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#bundleconfig.identifier) is configured in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appLocalDataDir } from '@tauri-apps/api/path';\nconst appLocalDataDirPath = await appLocalDataDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":298,"name":"appLogDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":533,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L533"}],"signatures":[{"id":299,"name":"appLogDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the suggested directory for your app's log files.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`${configDir}/${bundleIdentifier}/logs`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`${homeDir}/Library/Logs/{bundleIdentifier}`"},{"kind":"text","text":"\n- **Windows:** Resolves to "},{"kind":"code","text":"`${configDir}/${bundleIdentifier}/logs`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appLogDir } from '@tauri-apps/api/path';\nconst appLogDirPath = await appLogDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":300,"name":"audioDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":143,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L143"}],"signatures":[{"id":301,"name":"audioDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's audio directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_MUSIC_DIR`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Music`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Music}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { audioDir } from '@tauri-apps/api/path';\nconst audioDirPath = await audioDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":354,"name":"basename","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":647,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L647"}],"signatures":[{"id":355,"name":"basename","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the last portion of a "},{"kind":"code","text":"`path`"},{"kind":"text","text":". Trailing directory separators are ignored."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { basename, resolveResource } from '@tauri-apps/api/path';\nconst resourcePath = await resolveResource('app.conf');\nconst base = await basename(resourcePath);\nassert(base === 'app.conf');\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":356,"name":"path","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":357,"name":"ext","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"An optional file extension to be removed from the returned path."}]},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":302,"name":"cacheDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":165,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L165"}],"signatures":[{"id":303,"name":"cacheDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's cache directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$XDG_CACHE_HOME`"},{"kind":"text","text":" or "},{"kind":"code","text":"`$HOME/.cache`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Library/Caches`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_LocalAppData}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { cacheDir } from '@tauri-apps/api/path';\nconst cacheDirPath = await cacheDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":304,"name":"configDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":187,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L187"}],"signatures":[{"id":305,"name":"configDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's config directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$XDG_CONFIG_HOME`"},{"kind":"text","text":" or "},{"kind":"code","text":"`$HOME/.config`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Library/Application Support`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_RoamingAppData}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { configDir } from '@tauri-apps/api/path';\nconst configDirPath = await configDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":306,"name":"dataDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":209,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L209"}],"signatures":[{"id":307,"name":"dataDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's data directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$XDG_DATA_HOME`"},{"kind":"text","text":" or "},{"kind":"code","text":"`$HOME/.local/share`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Library/Application Support`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_RoamingAppData}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { dataDir } from '@tauri-apps/api/path';\nconst dataDirPath = await dataDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":308,"name":"desktopDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":231,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L231"}],"signatures":[{"id":309,"name":"desktopDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's desktop directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_DESKTOP_DIR`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Desktop`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Desktop}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { desktopDir } from '@tauri-apps/api/path';\nconst desktopPath = await desktopDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":348,"name":"dirname","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":613,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L613"}],"signatures":[{"id":349,"name":"dirname","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the directory name of a "},{"kind":"code","text":"`path`"},{"kind":"text","text":". Trailing directory separators are ignored."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { dirname, appDataDir } from '@tauri-apps/api/path';\nconst appDataDirPath = await appDataDir();\nconst dir = await dirname(appDataDirPath);\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":350,"name":"path","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":310,"name":"documentDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":253,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L253"}],"signatures":[{"id":311,"name":"documentDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's document directory."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { documentDir } from '@tauri-apps/api/path';\nconst documentDirPath = await documentDir();\n```"},{"kind":"text","text":"\n\n#### Platform-specific\n\n- **Linux:** Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_DOCUMENTS_DIR`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Documents`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Documents}`"},{"kind":"text","text":"."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":312,"name":"downloadDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":275,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L275"}],"signatures":[{"id":313,"name":"downloadDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's download directory.\n\n#### Platform-specific\n\n- **Linux**: Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_DOWNLOAD_DIR`"},{"kind":"text","text":".\n- **macOS**: Resolves to "},{"kind":"code","text":"`$HOME/Downloads`"},{"kind":"text","text":".\n- **Windows**: Resolves to "},{"kind":"code","text":"`{FOLDERID_Downloads}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { downloadDir } from '@tauri-apps/api/path';\nconst downloadDirPath = await downloadDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":314,"name":"executableDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":297,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L297"}],"signatures":[{"id":315,"name":"executableDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's executable directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$XDG_BIN_HOME/../bin`"},{"kind":"text","text":" or "},{"kind":"code","text":"`$XDG_DATA_HOME/../bin`"},{"kind":"text","text":" or "},{"kind":"code","text":"`$HOME/.local/bin`"},{"kind":"text","text":".\n- **macOS:** Not supported.\n- **Windows:** Not supported."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { executableDir } from '@tauri-apps/api/path';\nconst executableDirPath = await executableDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":351,"name":"extname","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":629,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L629"}],"signatures":[{"id":352,"name":"extname","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the extension of the "},{"kind":"code","text":"`path`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { extname, resolveResource } from '@tauri-apps/api/path';\nconst resourcePath = await resolveResource('app.conf');\nconst ext = await extname(resourcePath);\nassert(ext === 'conf');\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":353,"name":"path","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":316,"name":"fontDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":319,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L319"}],"signatures":[{"id":317,"name":"fontDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's font directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$XDG_DATA_HOME/fonts`"},{"kind":"text","text":" or "},{"kind":"code","text":"`$HOME/.local/share/fonts`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Library/Fonts`"},{"kind":"text","text":".\n- **Windows:** Not supported."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { fontDir } from '@tauri-apps/api/path';\nconst fontDirPath = await fontDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":318,"name":"homeDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":341,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L341"}],"signatures":[{"id":319,"name":"homeDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's home directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$HOME`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Profile}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { homeDir } from '@tauri-apps/api/path';\nconst homeDirPath = await homeDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":358,"name":"isAbsolute","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":661,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L661"}],"signatures":[{"id":359,"name":"isAbsolute","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns whether the path is absolute or not."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { isAbsolute } from '@tauri-apps/api/path';\nassert(await isAbsolute('/home/tauri'));\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":360,"name":"path","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":345,"name":"join","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":598,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L598"}],"signatures":[{"id":346,"name":"join","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Joins all given "},{"kind":"code","text":"`path`"},{"kind":"text","text":" segments together using the platform-specific separator as a delimiter, then normalizes the resulting path."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { join, appDataDir } from '@tauri-apps/api/path';\nconst appDataDirPath = await appDataDir();\nconst path = await join(appDataDirPath, 'users', 'tauri', 'avatar.png');\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":347,"name":"paths","kind":32768,"kindString":"Parameter","flags":{"isRest":true},"type":{"type":"array","elementType":{"type":"intrinsic","name":"string"}}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":320,"name":"localDataDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":363,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L363"}],"signatures":[{"id":321,"name":"localDataDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's local data directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$XDG_DATA_HOME`"},{"kind":"text","text":" or "},{"kind":"code","text":"`$HOME/.local/share`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Library/Application Support`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_LocalAppData}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { localDataDir } from '@tauri-apps/api/path';\nconst localDataDirPath = await localDataDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":342,"name":"normalize","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":583,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L583"}],"signatures":[{"id":343,"name":"normalize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Normalizes the given "},{"kind":"code","text":"`path`"},{"kind":"text","text":", resolving "},{"kind":"code","text":"`'..'`"},{"kind":"text","text":" and "},{"kind":"code","text":"`'.'`"},{"kind":"text","text":" segments and resolve symbolic links."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { normalize, appDataDir } from '@tauri-apps/api/path';\nconst appDataDirPath = await appDataDir();\nconst path = await normalize(appDataDirPath, '..', 'users', 'tauri', 'avatar.png');\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":344,"name":"path","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":322,"name":"pictureDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":385,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L385"}],"signatures":[{"id":323,"name":"pictureDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's picture directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_PICTURES_DIR`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Pictures`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Pictures}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { pictureDir } from '@tauri-apps/api/path';\nconst pictureDirPath = await pictureDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":324,"name":"publicDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":407,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L407"}],"signatures":[{"id":325,"name":"publicDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's public directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_PUBLICSHARE_DIR`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Public`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Public}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { publicDir } from '@tauri-apps/api/path';\nconst publicDirPath = await publicDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":339,"name":"resolve","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":568,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L568"}],"signatures":[{"id":340,"name":"resolve","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Resolves a sequence of "},{"kind":"code","text":"`paths`"},{"kind":"text","text":" or "},{"kind":"code","text":"`path`"},{"kind":"text","text":" segments into an absolute path."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { resolve, appDataDir } from '@tauri-apps/api/path';\nconst appDataDirPath = await appDataDir();\nconst path = await resolve(appDataDirPath, '..', 'users', 'tauri', 'avatar.png');\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":341,"name":"paths","kind":32768,"kindString":"Parameter","flags":{"isRest":true},"type":{"type":"array","elementType":{"type":"intrinsic","name":"string"}}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":328,"name":"resolveResource","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":444,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L444"}],"signatures":[{"id":329,"name":"resolveResource","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Resolve the path to a resource file."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { resolveResource } from '@tauri-apps/api/path';\nconst resourcePath = await resolveResource('script.sh');\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The full path to the resource."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":330,"name":"resourcePath","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The path to the resource.\nMust follow the same syntax as defined in "},{"kind":"code","text":"`tauri.conf.json > tauri > bundle > resources`"},{"kind":"text","text":", i.e. keeping subfolders and parent dir components ("},{"kind":"code","text":"`../`"},{"kind":"text","text":")."}]},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":326,"name":"resourceDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":424,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L424"}],"signatures":[{"id":327,"name":"resourceDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the application's resource directory.\nTo resolve a resource path, see the [[resolveResource | "},{"kind":"code","text":"`resolveResource API`"},{"kind":"text","text":"]]."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { resourceDir } from '@tauri-apps/api/path';\nconst resourceDirPath = await resourceDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":331,"name":"runtimeDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":467,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L467"}],"signatures":[{"id":332,"name":"runtimeDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's runtime directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$XDG_RUNTIME_DIR`"},{"kind":"text","text":".\n- **macOS:** Not supported.\n- **Windows:** Not supported."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { runtimeDir } from '@tauri-apps/api/path';\nconst runtimeDirPath = await runtimeDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":333,"name":"templateDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":489,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L489"}],"signatures":[{"id":334,"name":"templateDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's template directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_TEMPLATES_DIR`"},{"kind":"text","text":".\n- **macOS:** Not supported.\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Templates}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { templateDir } from '@tauri-apps/api/path';\nconst templateDirPath = await templateDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":335,"name":"videoDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":511,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L511"}],"signatures":[{"id":336,"name":"videoDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's video directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_VIDEOS_DIR`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Movies`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Videos}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { videoDir } from '@tauri-apps/api/path';\nconst videoDirPath = await videoDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Enumerations","children":[266]},{"title":"Variables","children":[338,337]},{"title":"Functions","children":[296,290,292,294,298,300,354,302,304,306,308,348,310,312,314,351,316,318,358,345,320,342,322,324,339,328,326,331,333,335]}],"sources":[{"fileName":"path.ts","line":26,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/path.ts#L26"}]},{"id":361,"name":"process","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Perform operations on the current process.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.process`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":"."}]},"children":[{"id":362,"name":"exit","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"process.ts","line":27,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/process.ts#L27"}],"signatures":[{"id":363,"name":"exit","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Exits immediately with the given "},{"kind":"code","text":"`exitCode`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { exit } from '@tauri-apps/api/process';\nawait exit(1);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":364,"name":"exitCode","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The exit code to use."}]},"type":{"type":"intrinsic","name":"number"},"defaultValue":"0"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":365,"name":"relaunch","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"process.ts","line":49,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/process.ts#L49"}],"signatures":[{"id":366,"name":"relaunch","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Exits the current instance of the app then relaunches it."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { relaunch } from '@tauri-apps/api/process';\nawait relaunch();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Functions","children":[362,365]}],"sources":[{"fileName":"process.ts","line":12,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/process.ts#L12"}]},{"id":367,"name":"shell","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Access the system shell.\nAllows you to spawn child processes and manage files and URLs using their default application.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.shell`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be added to ["},{"kind":"code","text":"`tauri.allowlist.shell`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.shell) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"shell\": {\n \"all\": true, // enable all shell APIs\n \"execute\": true, // enable process spawn APIs\n \"sidecar\": true, // enable spawning sidecars\n \"open\": true // enable opening files/URLs using the default program\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security.\n\n## Security\n\nThis API has a scope configuration that forces you to restrict the programs and arguments that can be used.\n\n### Restricting access to the "},{"kind":"inline-tag","tag":"@link","text":"`open`","target":573},{"kind":"text","text":" API\n\nOn the allowlist, "},{"kind":"code","text":"`open: true`"},{"kind":"text","text":" means that the "},{"kind":"inline-tag","tag":"@link","text":"open","target":573},{"kind":"text","text":" API can be used with any URL,\nas the argument is validated with the "},{"kind":"code","text":"`^((mailto:\\w+)|(tel:\\w+)|(https?://\\w+)).+`"},{"kind":"text","text":" regex.\nYou can change that regex by changing the boolean value to a string, e.g. "},{"kind":"code","text":"`open: ^https://github.com/`"},{"kind":"text","text":".\n\n### Restricting access to the "},{"kind":"inline-tag","tag":"@link","text":"`Command`","target":368},{"kind":"text","text":" APIs\n\nThe "},{"kind":"code","text":"`shell`"},{"kind":"text","text":" allowlist object has a "},{"kind":"code","text":"`scope`"},{"kind":"text","text":" field that defines an array of CLIs that can be used.\nEach CLI is a configuration object "},{"kind":"code","text":"`{ name: string, cmd: string, sidecar?: bool, args?: boolean | Arg[] }`"},{"kind":"text","text":".\n\n- "},{"kind":"code","text":"`name`"},{"kind":"text","text":": the unique identifier of the command, passed to the "},{"kind":"inline-tag","tag":"@link","text":"Command.create function","target":369},{"kind":"text","text":".\nIf it's a sidecar, this must be the value defined on "},{"kind":"code","text":"`tauri.conf.json > tauri > bundle > externalBin`"},{"kind":"text","text":".\n- "},{"kind":"code","text":"`cmd`"},{"kind":"text","text":": the program that is executed on this configuration. If it's a sidecar, this value is ignored.\n- "},{"kind":"code","text":"`sidecar`"},{"kind":"text","text":": whether the object configures a sidecar or a system program.\n- "},{"kind":"code","text":"`args`"},{"kind":"text","text":": the arguments that can be passed to the program. By default no arguments are allowed.\n - "},{"kind":"code","text":"`true`"},{"kind":"text","text":" means that any argument list is allowed.\n - "},{"kind":"code","text":"`false`"},{"kind":"text","text":" means that no arguments are allowed.\n - otherwise an array can be configured. Each item is either a string representing the fixed argument value\n or a "},{"kind":"code","text":"`{ validator: string }`"},{"kind":"text","text":" that defines a regex validating the argument value.\n\n#### Example scope configuration\n\nCLI: "},{"kind":"code","text":"`git commit -m \"the commit message\"`"},{"kind":"text","text":"\n\nConfiguration:\n"},{"kind":"code","text":"```json\n{\n \"scope\": [\n {\n \"name\": \"run-git-commit\",\n \"cmd\": \"git\",\n \"args\": [\"commit\", \"-m\", { \"validator\": \"\\\\S+\" }]\n }\n ]\n}\n```"},{"kind":"text","text":"\nUsage:\n"},{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell'\nCommand.create('run-git-commit', ['commit', '-m', 'the commit message'])\n```"},{"kind":"text","text":"\n\nTrying to execute any API with a program not configured on the scope results in a promise rejection due to denied access."}]},"children":[{"id":485,"name":"Child","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"children":[{"id":486,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"sources":[{"fileName":"shell.ts","line":346,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L346"}],"signatures":[{"id":487,"name":"new Child","kind":16384,"kindString":"Constructor signature","flags":{},"parameters":[{"id":488,"name":"pid","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}}],"type":{"type":"reference","id":485,"name":"Child"}}]},{"id":489,"name":"pid","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The child process "},{"kind":"code","text":"`pid`"},{"kind":"text","text":"."}]},"sources":[{"fileName":"shell.ts","line":344,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L344"}],"type":{"type":"intrinsic","name":"number"}},{"id":493,"name":"kill","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":382,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L382"}],"signatures":[{"id":494,"name":"kill","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Kills the child process."}],"blockTags":[{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":490,"name":"write","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":365,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L365"}],"signatures":[{"id":491,"name":"write","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Writes "},{"kind":"code","text":"`data`"},{"kind":"text","text":" to the "},{"kind":"code","text":"`stdin`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.create('node');\nconst child = await command.spawn();\nawait child.write('message');\nawait child.write([0, 1, 2, 3, 4, 5]);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":492,"name":"data","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The message to write, either a string or a byte array."}]},"type":{"type":"reference","id":577,"name":"IOPayload"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Constructors","children":[486]},{"title":"Properties","children":[489]},{"title":"Methods","children":[493,490]}],"sources":[{"fileName":"shell.ts","line":342,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L342"}]},{"id":368,"name":"Command","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"The entry point for spawning child processes.\nIt emits the "},{"kind":"code","text":"`close`"},{"kind":"text","text":" and "},{"kind":"code","text":"`error`"},{"kind":"text","text":" events."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.create('node');\ncommand.on('close', data => {\n console.log(`command finished with code ${data.code} and signal ${data.signal}`)\n});\ncommand.on('error', error => console.error(`command error: \"${error}\"`));\ncommand.stdout.on('data', line => console.log(`command stdout: \"${line}\"`));\ncommand.stderr.on('data', line => console.log(`command stderr: \"${line}\"`));\n\nconst child = await command.spawn();\nconsole.log('pid:', child.pid);\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"children":[{"id":407,"name":"stderr","kind":1024,"kindString":"Property","flags":{"isReadonly":true},"comment":{"summary":[{"kind":"text","text":"Event emitter for the "},{"kind":"code","text":"`stderr`"},{"kind":"text","text":". Emits the "},{"kind":"code","text":"`data`"},{"kind":"text","text":" event."}]},"sources":[{"fileName":"shell.ts","line":433,"character":11,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L433"}],"type":{"type":"reference","id":495,"typeArguments":[{"type":"reference","id":584,"typeArguments":[{"type":"reference","name":"O"}],"name":"OutputEvents"}],"name":"EventEmitter"},"defaultValue":"..."},{"id":406,"name":"stdout","kind":1024,"kindString":"Property","flags":{"isReadonly":true},"comment":{"summary":[{"kind":"text","text":"Event emitter for the "},{"kind":"code","text":"`stdout`"},{"kind":"text","text":". Emits the "},{"kind":"code","text":"`data`"},{"kind":"text","text":" event."}]},"sources":[{"fileName":"shell.ts","line":431,"character":11,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L431"}],"type":{"type":"reference","id":495,"typeArguments":[{"type":"reference","id":584,"typeArguments":[{"type":"reference","name":"O"}],"name":"OutputEvents"}],"name":"EventEmitter"},"defaultValue":"..."},{"id":415,"name":"addListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":164,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L164"}],"signatures":[{"id":416,"name":"addListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Alias for "},{"kind":"code","text":"`emitter.on(eventName, listener)`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":417,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":578,"name":"CommandEvents"}}}],"parameters":[{"id":418,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":417,"name":"N"}},{"id":419,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":420,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":166,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L166"}],"signatures":[{"id":421,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":422,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":417,"name":"N"},"objectType":{"type":"reference","id":578,"name":"CommandEvents"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":368,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":504,"name":"EventEmitter.addListener"}}],"inheritedFrom":{"type":"reference","id":503,"name":"EventEmitter.addListener"}},{"id":410,"name":"execute","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":564,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L564"}],"signatures":[{"id":411,"name":"execute","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Executes the command as a child process, waiting for it to finish and collecting all of its output."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst output = await Command.create('echo', 'message').execute();\nassert(output.code === 0);\nassert(output.signal === null);\nassert(output.stdout === 'message');\nassert(output.stderr === '');\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to the child process output."}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":587,"typeArguments":[{"type":"reference","name":"O"}],"name":"ChildProcess"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":464,"name":"listenerCount","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":287,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L287"}],"signatures":[{"id":465,"name":"listenerCount","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the number of listeners listening to the event named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":466,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":578,"name":"CommandEvents"}}}],"parameters":[{"id":467,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":466,"name":"N"}}],"type":{"type":"intrinsic","name":"number"},"inheritedFrom":{"type":"reference","id":553,"name":"EventEmitter.listenerCount"}}],"inheritedFrom":{"type":"reference","id":552,"name":"EventEmitter.listenerCount"}},{"id":447,"name":"off","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":233,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L233"}],"signatures":[{"id":448,"name":"off","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Removes the all specified listener from the listener array for the event eventName\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":449,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":578,"name":"CommandEvents"}}}],"parameters":[{"id":450,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":449,"name":"N"}},{"id":451,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":452,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":235,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L235"}],"signatures":[{"id":453,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":454,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":449,"name":"N"},"objectType":{"type":"reference","id":578,"name":"CommandEvents"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":368,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":536,"name":"EventEmitter.off"}}],"inheritedFrom":{"type":"reference","id":535,"name":"EventEmitter.off"}},{"id":431,"name":"on","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":193,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L193"}],"signatures":[{"id":432,"name":"on","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function to the end of the listeners array for the\nevent named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":". No checks are made to see if the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" has\nalready been added. Multiple calls passing the same combination of "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":"and "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" will result in the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" being added, and called, multiple\ntimes.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"typeParameter":[{"id":433,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":578,"name":"CommandEvents"}}}],"parameters":[{"id":434,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":433,"name":"N"}},{"id":435,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":436,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":195,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L195"}],"signatures":[{"id":437,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":438,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":433,"name":"N"},"objectType":{"type":"reference","id":578,"name":"CommandEvents"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":368,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":520,"name":"EventEmitter.on"}}],"inheritedFrom":{"type":"reference","id":519,"name":"EventEmitter.on"}},{"id":439,"name":"once","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":215,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L215"}],"signatures":[{"id":440,"name":"once","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds a **one-time**"},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function for the event named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":". The\nnext time "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":" is triggered, this listener is removed and then invoked.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":441,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":578,"name":"CommandEvents"}}}],"parameters":[{"id":442,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":441,"name":"N"}},{"id":443,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":444,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":217,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L217"}],"signatures":[{"id":445,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":446,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":441,"name":"N"},"objectType":{"type":"reference","id":578,"name":"CommandEvents"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":368,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":528,"name":"EventEmitter.once"}}],"inheritedFrom":{"type":"reference","id":527,"name":"EventEmitter.once"}},{"id":468,"name":"prependListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":304,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L304"}],"signatures":[{"id":469,"name":"prependListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function to the _beginning_ of the listeners array for the\nevent named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":". No checks are made to see if the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" has\nalready been added. Multiple calls passing the same combination of "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":"and "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" will result in the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" being added, and called, multiple\ntimes.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":470,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":578,"name":"CommandEvents"}}}],"parameters":[{"id":471,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":470,"name":"N"}},{"id":472,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":473,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":306,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L306"}],"signatures":[{"id":474,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":475,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":470,"name":"N"},"objectType":{"type":"reference","id":578,"name":"CommandEvents"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":368,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":557,"name":"EventEmitter.prependListener"}}],"inheritedFrom":{"type":"reference","id":556,"name":"EventEmitter.prependListener"}},{"id":476,"name":"prependOnceListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":326,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L326"}],"signatures":[{"id":477,"name":"prependOnceListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds a **one-time**"},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function for the event named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":" to the_beginning_ of the listeners array. The next time "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":" is triggered, this\nlistener is removed, and then invoked.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":478,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":578,"name":"CommandEvents"}}}],"parameters":[{"id":479,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":478,"name":"N"}},{"id":480,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":481,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":328,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L328"}],"signatures":[{"id":482,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":483,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":478,"name":"N"},"objectType":{"type":"reference","id":578,"name":"CommandEvents"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":368,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":565,"name":"EventEmitter.prependOnceListener"}}],"inheritedFrom":{"type":"reference","id":564,"name":"EventEmitter.prependOnceListener"}},{"id":455,"name":"removeAllListeners","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":253,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L253"}],"signatures":[{"id":456,"name":"removeAllListeners","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Removes all listeners, or those of the specified eventName.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":457,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":578,"name":"CommandEvents"}}}],"parameters":[{"id":458,"name":"event","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":457,"name":"N"}}],"type":{"type":"reference","id":368,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":544,"name":"EventEmitter.removeAllListeners"}}],"inheritedFrom":{"type":"reference","id":543,"name":"EventEmitter.removeAllListeners"}},{"id":423,"name":"removeListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":176,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L176"}],"signatures":[{"id":424,"name":"removeListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Alias for "},{"kind":"code","text":"`emitter.off(eventName, listener)`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":425,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":578,"name":"CommandEvents"}}}],"parameters":[{"id":426,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":425,"name":"N"}},{"id":427,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":428,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":178,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L178"}],"signatures":[{"id":429,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":430,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":425,"name":"N"},"objectType":{"type":"reference","id":578,"name":"CommandEvents"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":368,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":512,"name":"EventEmitter.removeListener"}}],"inheritedFrom":{"type":"reference","id":511,"name":"EventEmitter.removeListener"}},{"id":408,"name":"spawn","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":526,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L526"}],"signatures":[{"id":409,"name":"spawn","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Executes the command as a child process, returning a handle to it."}],"blockTags":[{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to the child process handle."}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":485,"name":"Child"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":369,"name":"create","kind":2048,"kindString":"Method","flags":{"isStatic":true},"sources":[{"fileName":"shell.ts","line":455,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L455"},{"fileName":"shell.ts","line":456,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L456"},{"fileName":"shell.ts","line":461,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L461"},{"fileName":"shell.ts","line":479,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L479"}],"signatures":[{"id":370,"name":"create","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a command to execute the given program."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.create('my-app', ['run', 'tauri']);\nconst output = await command.execute();\n```"}]}]},"parameters":[{"id":371,"name":"program","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The program to execute.\nIt must be configured on "},{"kind":"code","text":"`tauri.conf.json > tauri > allowlist > shell > scope`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":372,"name":"args","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}]}}],"type":{"type":"reference","id":368,"typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Command"}},{"id":373,"name":"create","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a command to execute the given program."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.create('my-app', ['run', 'tauri']);\nconst output = await command.execute();\n```"}]}]},"parameters":[{"id":374,"name":"program","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The program to execute.\nIt must be configured on "},{"kind":"code","text":"`tauri.conf.json > tauri > allowlist > shell > scope`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":375,"name":"args","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}]}},{"id":376,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"intersection","types":[{"type":"reference","id":593,"name":"SpawnOptions"},{"type":"reflection","declaration":{"id":377,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"children":[{"id":378,"name":"encoding","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"shell.ts","line":459,"character":31,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L459"}],"type":{"type":"literal","value":"raw"}}],"groups":[{"title":"Properties","children":[378]}],"sources":[{"fileName":"shell.ts","line":459,"character":29,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L459"}]}}]}}],"type":{"type":"reference","id":368,"typeArguments":[{"type":"reference","name":"Uint8Array","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array","qualifiedName":"Uint8Array","package":"typescript"}],"name":"Command"}},{"id":379,"name":"create","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a command to execute the given program."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.create('my-app', ['run', 'tauri']);\nconst output = await command.execute();\n```"}]}]},"parameters":[{"id":380,"name":"program","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The program to execute.\nIt must be configured on "},{"kind":"code","text":"`tauri.conf.json > tauri > allowlist > shell > scope`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":381,"name":"args","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}]}},{"id":382,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":593,"name":"SpawnOptions"}}],"type":{"type":"reference","id":368,"typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Command"}}]},{"id":383,"name":"sidecar","kind":2048,"kindString":"Method","flags":{"isStatic":true},"sources":[{"fileName":"shell.ts","line":487,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L487"},{"fileName":"shell.ts","line":488,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L488"},{"fileName":"shell.ts","line":493,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L493"},{"fileName":"shell.ts","line":511,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L511"}],"signatures":[{"id":384,"name":"sidecar","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a command to execute the given sidecar program."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.sidecar('my-sidecar');\nconst output = await command.execute();\n```"}]}]},"parameters":[{"id":385,"name":"program","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The program to execute.\nIt must be configured on "},{"kind":"code","text":"`tauri.conf.json > tauri > allowlist > shell > scope`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":386,"name":"args","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}]}}],"type":{"type":"reference","id":368,"typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Command"}},{"id":387,"name":"sidecar","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a command to execute the given sidecar program."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.sidecar('my-sidecar');\nconst output = await command.execute();\n```"}]}]},"parameters":[{"id":388,"name":"program","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The program to execute.\nIt must be configured on "},{"kind":"code","text":"`tauri.conf.json > tauri > allowlist > shell > scope`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":389,"name":"args","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}]}},{"id":390,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"intersection","types":[{"type":"reference","id":593,"name":"SpawnOptions"},{"type":"reflection","declaration":{"id":391,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"children":[{"id":392,"name":"encoding","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"shell.ts","line":491,"character":31,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L491"}],"type":{"type":"literal","value":"raw"}}],"groups":[{"title":"Properties","children":[392]}],"sources":[{"fileName":"shell.ts","line":491,"character":29,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L491"}]}}]}}],"type":{"type":"reference","id":368,"typeArguments":[{"type":"reference","name":"Uint8Array","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array","qualifiedName":"Uint8Array","package":"typescript"}],"name":"Command"}},{"id":393,"name":"sidecar","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a command to execute the given sidecar program."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.sidecar('my-sidecar');\nconst output = await command.execute();\n```"}]}]},"parameters":[{"id":394,"name":"program","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The program to execute.\nIt must be configured on "},{"kind":"code","text":"`tauri.conf.json > tauri > allowlist > shell > scope`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":395,"name":"args","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}]}},{"id":396,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":593,"name":"SpawnOptions"}}],"type":{"type":"reference","id":368,"typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Command"}}]}],"groups":[{"title":"Properties","children":[407,406]},{"title":"Methods","children":[415,410,464,447,431,439,468,476,455,423,408,369,383]}],"sources":[{"fileName":"shell.ts","line":423,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L423"}],"typeParameters":[{"id":484,"name":"O","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"reference","id":577,"name":"IOPayload"}}],"extendedTypes":[{"type":"reference","id":495,"typeArguments":[{"type":"reference","id":578,"name":"CommandEvents"}],"name":"EventEmitter"}]},{"id":495,"name":"EventEmitter","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":496,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"signatures":[{"id":497,"name":"new EventEmitter","kind":16384,"kindString":"Constructor signature","flags":{},"typeParameter":[{"id":498,"name":"E","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"any"}],"name":"Record","qualifiedName":"Record","package":"typescript"}}],"type":{"type":"reference","id":495,"typeArguments":[{"type":"reference","id":498,"name":"E"}],"name":"EventEmitter"}}]},{"id":503,"name":"addListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":164,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L164"}],"signatures":[{"id":504,"name":"addListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Alias for "},{"kind":"code","text":"`emitter.on(eventName, listener)`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":505,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":506,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":417,"name":"N"}},{"id":507,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":508,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":166,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L166"}],"signatures":[{"id":509,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":510,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":417,"name":"N"},"objectType":{"type":"reference","id":498,"name":"E"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":495,"typeArguments":[{"type":"reference","id":498,"name":"E"}],"name":"EventEmitter"}}]},{"id":552,"name":"listenerCount","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":287,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L287"}],"signatures":[{"id":553,"name":"listenerCount","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the number of listeners listening to the event named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":554,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":555,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":466,"name":"N"}}],"type":{"type":"intrinsic","name":"number"}}]},{"id":535,"name":"off","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":233,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L233"}],"signatures":[{"id":536,"name":"off","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Removes the all specified listener from the listener array for the event eventName\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":537,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":538,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":449,"name":"N"}},{"id":539,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":540,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":235,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L235"}],"signatures":[{"id":541,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":542,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":449,"name":"N"},"objectType":{"type":"reference","id":498,"name":"E"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":495,"typeArguments":[{"type":"reference","id":498,"name":"E"}],"name":"EventEmitter"}}]},{"id":519,"name":"on","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":193,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L193"}],"signatures":[{"id":520,"name":"on","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function to the end of the listeners array for the\nevent named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":". No checks are made to see if the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" has\nalready been added. Multiple calls passing the same combination of "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":"and "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" will result in the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" being added, and called, multiple\ntimes.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"typeParameter":[{"id":521,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":522,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":433,"name":"N"}},{"id":523,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":524,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":195,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L195"}],"signatures":[{"id":525,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":526,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":433,"name":"N"},"objectType":{"type":"reference","id":498,"name":"E"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":495,"typeArguments":[{"type":"reference","id":498,"name":"E"}],"name":"EventEmitter"}}]},{"id":527,"name":"once","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":215,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L215"}],"signatures":[{"id":528,"name":"once","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds a **one-time**"},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function for the event named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":". The\nnext time "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":" is triggered, this listener is removed and then invoked.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":529,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":530,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":441,"name":"N"}},{"id":531,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":532,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":217,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L217"}],"signatures":[{"id":533,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":534,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":441,"name":"N"},"objectType":{"type":"reference","id":498,"name":"E"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":495,"typeArguments":[{"type":"reference","id":498,"name":"E"}],"name":"EventEmitter"}}]},{"id":556,"name":"prependListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":304,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L304"}],"signatures":[{"id":557,"name":"prependListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function to the _beginning_ of the listeners array for the\nevent named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":". No checks are made to see if the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" has\nalready been added. Multiple calls passing the same combination of "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":"and "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" will result in the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" being added, and called, multiple\ntimes.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":558,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":559,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":470,"name":"N"}},{"id":560,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":561,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":306,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L306"}],"signatures":[{"id":562,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":563,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":470,"name":"N"},"objectType":{"type":"reference","id":498,"name":"E"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":495,"typeArguments":[{"type":"reference","id":498,"name":"E"}],"name":"EventEmitter"}}]},{"id":564,"name":"prependOnceListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":326,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L326"}],"signatures":[{"id":565,"name":"prependOnceListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds a **one-time**"},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function for the event named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":" to the_beginning_ of the listeners array. The next time "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":" is triggered, this\nlistener is removed, and then invoked.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":566,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":567,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":478,"name":"N"}},{"id":568,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":569,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":328,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L328"}],"signatures":[{"id":570,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":571,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":478,"name":"N"},"objectType":{"type":"reference","id":498,"name":"E"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":495,"typeArguments":[{"type":"reference","id":498,"name":"E"}],"name":"EventEmitter"}}]},{"id":543,"name":"removeAllListeners","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":253,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L253"}],"signatures":[{"id":544,"name":"removeAllListeners","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Removes all listeners, or those of the specified eventName.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":545,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":546,"name":"event","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":457,"name":"N"}}],"type":{"type":"reference","id":495,"typeArguments":[{"type":"reference","id":498,"name":"E"}],"name":"EventEmitter"}}]},{"id":511,"name":"removeListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":176,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L176"}],"signatures":[{"id":512,"name":"removeListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Alias for "},{"kind":"code","text":"`emitter.off(eventName, listener)`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":513,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":514,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":425,"name":"N"}},{"id":515,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":516,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":178,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L178"}],"signatures":[{"id":517,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":518,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":425,"name":"N"},"objectType":{"type":"reference","id":498,"name":"E"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":495,"typeArguments":[{"type":"reference","id":498,"name":"E"}],"name":"EventEmitter"}}]}],"groups":[{"title":"Constructors","children":[496]},{"title":"Methods","children":[503,552,535,519,527,556,564,543,511]}],"sources":[{"fileName":"shell.ts","line":153,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L153"}],"typeParameters":[{"id":572,"name":"E","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"any"}],"name":"Record","qualifiedName":"Record","package":"typescript"}}],"extendedBy":[{"type":"reference","id":368,"name":"Command"}]},{"id":587,"name":"ChildProcess","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":588,"name":"code","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Exit code of the process. "},{"kind":"code","text":"`null`"},{"kind":"text","text":" if the process was terminated by a signal on Unix."}]},"sources":[{"fileName":"shell.ts","line":109,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L109"}],"type":{"type":"union","types":[{"type":"literal","value":null},{"type":"intrinsic","name":"number"}]}},{"id":589,"name":"signal","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"If the process was terminated by a signal, represents that signal."}]},"sources":[{"fileName":"shell.ts","line":111,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L111"}],"type":{"type":"union","types":[{"type":"literal","value":null},{"type":"intrinsic","name":"number"}]}},{"id":591,"name":"stderr","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The data that the process wrote to "},{"kind":"code","text":"`stderr`"},{"kind":"text","text":"."}]},"sources":[{"fileName":"shell.ts","line":115,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L115"}],"type":{"type":"reference","id":592,"name":"O"}},{"id":590,"name":"stdout","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The data that the process wrote to "},{"kind":"code","text":"`stdout`"},{"kind":"text","text":"."}]},"sources":[{"fileName":"shell.ts","line":113,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L113"}],"type":{"type":"reference","id":592,"name":"O"}}],"groups":[{"title":"Properties","children":[588,589,591,590]}],"sources":[{"fileName":"shell.ts","line":107,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L107"}],"typeParameters":[{"id":592,"name":"O","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"reference","id":577,"name":"IOPayload"}}]},{"id":578,"name":"CommandEvents","kind":256,"kindString":"Interface","flags":{},"children":[{"id":579,"name":"close","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"shell.ts","line":394,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L394"}],"type":{"type":"reference","id":581,"name":"TerminatedPayload"}},{"id":580,"name":"error","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"shell.ts","line":395,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L395"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[579,580]}],"sources":[{"fileName":"shell.ts","line":393,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L393"}]},{"id":584,"name":"OutputEvents","kind":256,"kindString":"Interface","flags":{},"children":[{"id":585,"name":"data","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"shell.ts","line":399,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L399"}],"type":{"type":"reference","id":586,"name":"O"}}],"groups":[{"title":"Properties","children":[585]}],"sources":[{"fileName":"shell.ts","line":398,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L398"}],"typeParameters":[{"id":586,"name":"O","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"reference","id":577,"name":"IOPayload"}}]},{"id":593,"name":"SpawnOptions","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":594,"name":"cwd","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Current working directory."}]},"sources":[{"fileName":"shell.ts","line":88,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L88"}],"type":{"type":"intrinsic","name":"string"}},{"id":596,"name":"encoding","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Character encoding for stdout/stderr"}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"sources":[{"fileName":"shell.ts","line":96,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L96"}],"type":{"type":"intrinsic","name":"string"}},{"id":595,"name":"env","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Environment variables. set to "},{"kind":"code","text":"`null`"},{"kind":"text","text":" to clear the process env."}]},"sources":[{"fileName":"shell.ts","line":90,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L90"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"string"}],"name":"Record","qualifiedName":"Record","package":"typescript"}}],"groups":[{"title":"Properties","children":[594,596,595]}],"sources":[{"fileName":"shell.ts","line":86,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L86"}]},{"id":581,"name":"TerminatedPayload","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Payload for the "},{"kind":"code","text":"`Terminated`"},{"kind":"text","text":" command event."}]},"children":[{"id":582,"name":"code","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Exit code of the process. "},{"kind":"code","text":"`null`"},{"kind":"text","text":" if the process was terminated by a signal on Unix."}]},"sources":[{"fileName":"shell.ts","line":615,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L615"}],"type":{"type":"union","types":[{"type":"literal","value":null},{"type":"intrinsic","name":"number"}]}},{"id":583,"name":"signal","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"If the process was terminated by a signal, represents that signal."}]},"sources":[{"fileName":"shell.ts","line":617,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L617"}],"type":{"type":"union","types":[{"type":"literal","value":null},{"type":"intrinsic","name":"number"}]}}],"groups":[{"title":"Properties","children":[582,583]}],"sources":[{"fileName":"shell.ts","line":613,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L613"}]},{"id":577,"name":"IOPayload","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[{"kind":"text","text":"Event payload type"}]},"sources":[{"fileName":"shell.ts","line":621,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L621"}],"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","name":"Uint8Array","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array","qualifiedName":"Uint8Array","package":"typescript"}]}},{"id":573,"name":"open","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"shell.ts","line":656,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L656"}],"signatures":[{"id":574,"name":"open","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Opens a path or URL with the system's default app,\nor the one specified with "},{"kind":"code","text":"`openWith`"},{"kind":"text","text":".\n\nThe "},{"kind":"code","text":"`openWith`"},{"kind":"text","text":" value must be one of "},{"kind":"code","text":"`firefox`"},{"kind":"text","text":", "},{"kind":"code","text":"`google chrome`"},{"kind":"text","text":", "},{"kind":"code","text":"`chromium`"},{"kind":"text","text":" "},{"kind":"code","text":"`safari`"},{"kind":"text","text":",\n"},{"kind":"code","text":"`open`"},{"kind":"text","text":", "},{"kind":"code","text":"`start`"},{"kind":"text","text":", "},{"kind":"code","text":"`xdg-open`"},{"kind":"text","text":", "},{"kind":"code","text":"`gio`"},{"kind":"text","text":", "},{"kind":"code","text":"`gnome-open`"},{"kind":"text","text":", "},{"kind":"code","text":"`kde-open`"},{"kind":"text","text":" or "},{"kind":"code","text":"`wslview`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { open } from '@tauri-apps/api/shell';\n// opens the given URL on the default browser:\nawait open('https://github.com/tauri-apps/tauri');\n// opens the given URL using `firefox`:\nawait open('https://github.com/tauri-apps/tauri', 'firefox');\n// opens a file using the default program:\nawait open('/path/to/file');\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":575,"name":"path","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The path or URL to open.\nThis value is matched against the string regex defined on "},{"kind":"code","text":"`tauri.conf.json > tauri > allowlist > shell > open`"},{"kind":"text","text":",\nwhich defaults to "},{"kind":"code","text":"`^((mailto:\\w+)|(tel:\\w+)|(https?://\\w+)).+`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":576,"name":"openWith","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The app to open the file or URL with.\nDefaults to the system default application for the specified path type."}]},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Classes","children":[485,368,495]},{"title":"Interfaces","children":[587,578,584,593,581]},{"title":"Type Aliases","children":[577]},{"title":"Functions","children":[573]}],"sources":[{"fileName":"shell.ts","line":80,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/shell.ts#L80"}]},{"id":597,"name":"tauri","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Invoke your custom commands.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.tauri`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":"."}]},"children":[{"id":598,"name":"InvokeArgs","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[{"kind":"text","text":"Command arguments."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"sources":[{"fileName":"tauri.ts","line":63,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/tauri.ts#L63"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"unknown"}],"name":"Record","qualifiedName":"Record","package":"typescript"}},{"id":611,"name":"convertFileSrc","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"tauri.ts","line":129,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/tauri.ts#L129"}],"signatures":[{"id":612,"name":"convertFileSrc","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Convert a device file path to an URL that can be loaded by the webview.\nNote that "},{"kind":"code","text":"`asset:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`https://asset.localhost`"},{"kind":"text","text":" must be added to ["},{"kind":"code","text":"`tauri.security.csp`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#securityconfig.csp) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":".\nExample CSP value: "},{"kind":"code","text":"`\"csp\": \"default-src 'self'; img-src 'self' asset: https://asset.localhost\"`"},{"kind":"text","text":" to use the asset protocol on image sources.\n\nAdditionally, "},{"kind":"code","text":"`asset`"},{"kind":"text","text":" must be added to ["},{"kind":"code","text":"`tauri.allowlist.protocol`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.protocol)\nin "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" and its access scope must be defined on the "},{"kind":"code","text":"`assetScope`"},{"kind":"text","text":" array on the same "},{"kind":"code","text":"`protocol`"},{"kind":"text","text":" object."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appDataDir, join } from '@tauri-apps/api/path';\nimport { convertFileSrc } from '@tauri-apps/api/tauri';\nconst appDataDirPath = await appDataDir();\nconst filePath = await join(appDataDirPath, 'assets/video.mp4');\nconst assetUrl = convertFileSrc(filePath);\n\nconst video = document.getElementById('my-video');\nconst source = document.createElement('source');\nsource.type = 'video/mp4';\nsource.src = assetUrl;\nvideo.appendChild(source);\nvideo.load();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"the URL that can be used as source on the webview."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":613,"name":"filePath","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The file path."}]},"type":{"type":"intrinsic","name":"string"}},{"id":614,"name":"protocol","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The protocol to use. Defaults to "},{"kind":"code","text":"`asset`"},{"kind":"text","text":". You only need to set this when using a custom protocol."}]},"type":{"type":"intrinsic","name":"string"},"defaultValue":"'asset'"}],"type":{"type":"intrinsic","name":"string"}}]},{"id":606,"name":"invoke","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"tauri.ts","line":79,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/tauri.ts#L79"}],"signatures":[{"id":607,"name":"invoke","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sends a message to the backend."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { invoke } from '@tauri-apps/api/tauri';\nawait invoke('login', { user: 'tauri', password: 'poiwe3h4r5ip3yrhtew9ty' });\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving or rejecting to the backend response."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"typeParameter":[{"id":608,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":609,"name":"cmd","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The command name."}]},"type":{"type":"intrinsic","name":"string"}},{"id":610,"name":"args","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The optional arguments to pass to the command."}]},"type":{"type":"reference","id":598,"name":"InvokeArgs"},"defaultValue":"{}"}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":608,"name":"T"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":599,"name":"transformCallback","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"tauri.ts","line":36,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/tauri.ts#L36"}],"signatures":[{"id":600,"name":"transformCallback","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Transforms a callback function to a string identifier that can be passed to the backend.\nThe backend uses the identifier to "},{"kind":"code","text":"`eval()`"},{"kind":"text","text":" the callback."}],"blockTags":[{"tag":"@returns","content":[{"kind":"text","text":"A unique identifier associated with the callback function."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":601,"name":"callback","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reflection","declaration":{"id":602,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"tauri.ts","line":37,"character":13,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/tauri.ts#L37"}],"signatures":[{"id":603,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":604,"name":"response","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"any"}}],"type":{"type":"intrinsic","name":"void"}}]}}},{"id":605,"name":"once","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"boolean"},"defaultValue":"false"}],"type":{"type":"intrinsic","name":"number"}}]}],"groups":[{"title":"Type Aliases","children":[598]},{"title":"Functions","children":[611,606,599]}],"sources":[{"fileName":"tauri.ts","line":13,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/tauri.ts#L13"}]},{"id":615,"name":"updater","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Customize the auto updater flow.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.updater`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":"."}]},"children":[{"id":620,"name":"UpdateManifest","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":623,"name":"body","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"updater.ts","line":34,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L34"}],"type":{"type":"intrinsic","name":"string"}},{"id":622,"name":"date","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"updater.ts","line":33,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L33"}],"type":{"type":"intrinsic","name":"string"}},{"id":621,"name":"version","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"updater.ts","line":32,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L32"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[623,622,621]}],"sources":[{"fileName":"updater.ts","line":31,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L31"}]},{"id":624,"name":"UpdateResult","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":625,"name":"manifest","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"updater.ts","line":41,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L41"}],"type":{"type":"reference","id":620,"name":"UpdateManifest"}},{"id":626,"name":"shouldUpdate","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"updater.ts","line":42,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L42"}],"type":{"type":"intrinsic","name":"boolean"}}],"groups":[{"title":"Properties","children":[625,626]}],"sources":[{"fileName":"updater.ts","line":40,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L40"}]},{"id":617,"name":"UpdateStatusResult","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":618,"name":"error","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"updater.ts","line":24,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L24"}],"type":{"type":"intrinsic","name":"string"}},{"id":619,"name":"status","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"updater.ts","line":25,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L25"}],"type":{"type":"reference","id":616,"name":"UpdateStatus"}}],"groups":[{"title":"Properties","children":[618,619]}],"sources":[{"fileName":"updater.ts","line":23,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L23"}]},{"id":616,"name":"UpdateStatus","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"sources":[{"fileName":"updater.ts","line":18,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L18"}],"type":{"type":"union","types":[{"type":"literal","value":"PENDING"},{"type":"literal","value":"ERROR"},{"type":"literal","value":"DONE"},{"type":"literal","value":"UPTODATE"}]}},{"id":635,"name":"checkUpdate","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"updater.ts","line":146,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L146"}],"signatures":[{"id":636,"name":"checkUpdate","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Checks if an update is available."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { checkUpdate } from '@tauri-apps/api/updater';\nconst update = await checkUpdate();\n// now run installUpdate() if needed\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"Promise resolving to the update status."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":624,"name":"UpdateResult"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":633,"name":"installUpdate","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"updater.ts","line":87,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L87"}],"signatures":[{"id":634,"name":"installUpdate","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Install the update if there's one available."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { checkUpdate, installUpdate } from '@tauri-apps/api/updater';\nconst update = await checkUpdate();\nif (update.shouldUpdate) {\n console.log(`Installing update ${update.manifest?.version}, ${update.manifest?.date}, ${update.manifest.body}`);\n await installUpdate();\n}\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":627,"name":"onUpdaterEvent","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"updater.ts","line":63,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L63"}],"signatures":[{"id":628,"name":"onUpdaterEvent","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to an updater event."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { onUpdaterEvent } from \"@tauri-apps/api/updater\";\nconst unlisten = await onUpdaterEvent(({ error, status }) => {\n console.log('Updater event', error, status);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":629,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":630,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"updater.ts","line":64,"character":11,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L64"}],"signatures":[{"id":631,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":632,"name":"status","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":617,"name":"UpdateStatusResult"}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1107,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Interfaces","children":[620,624,617]},{"title":"Type Aliases","children":[616]},{"title":"Functions","children":[635,633,627]}],"sources":[{"fileName":"updater.ts","line":12,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/updater.ts#L12"}]},{"id":637,"name":"window","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Provides APIs to create windows, communicate with other windows and manipulate the current window.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.window`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be added to ["},{"kind":"code","text":"`tauri.allowlist.window`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.window) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"window\": {\n \"all\": true, // enable all window APIs\n \"create\": true, // enable window creation\n \"center\": true,\n \"requestUserAttention\": true,\n \"setResizable\": true,\n \"setTitle\": true,\n \"maximize\": true,\n \"unmaximize\": true,\n \"minimize\": true,\n \"unminimize\": true,\n \"show\": true,\n \"hide\": true,\n \"close\": true,\n \"setDecorations\": true,\n \"setShadow\": true,\n \"setAlwaysOnTop\": true,\n \"setContentProtected\": true,\n \"setSize\": true,\n \"setMinSize\": true,\n \"setMaxSize\": true,\n \"setPosition\": true,\n \"setFullscreen\": true,\n \"setFocus\": true,\n \"setIcon\": true,\n \"setSkipTaskbar\": true,\n \"setCursorGrab\": true,\n \"setCursorVisible\": true,\n \"setCursorIcon\": true,\n \"setCursorPosition\": true,\n \"setIgnoreCursorEvents\": true,\n \"startDragging\": true,\n \"print\": true\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security.\n\n## Window events\n\nEvents can be listened to using "},{"kind":"code","text":"`appWindow.listen`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nappWindow.listen(\"my-window-event\", ({ event, payload }) => { });\n```"}]},"children":[{"id":1038,"name":"UserAttentionType","kind":8,"kindString":"Enumeration","flags":{},"comment":{"summary":[{"kind":"text","text":"Attention type to request on a window."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":1039,"name":"Critical","kind":16,"kindString":"Enumeration Member","flags":{},"comment":{"summary":[{"kind":"text","text":"#### Platform-specific\n- **macOS:** Bounces the dock icon until the application is in focus.\n- **Windows:** Flashes both the window and the taskbar button until the application is in focus."}]},"sources":[{"fileName":"window.ts","line":226,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L226"}],"type":{"type":"literal","value":1}},{"id":1040,"name":"Informational","kind":16,"kindString":"Enumeration Member","flags":{},"comment":{"summary":[{"kind":"text","text":"#### Platform-specific\n- **macOS:** Bounces the dock icon once.\n- **Windows:** Flashes the taskbar button until the application is in focus."}]},"sources":[{"fileName":"window.ts","line":232,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L232"}],"type":{"type":"literal","value":2}}],"groups":[{"title":"Enumeration Members","children":[1039,1040]}],"sources":[{"fileName":"window.ts","line":220,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L220"}]},{"id":983,"name":"CloseRequestedEvent","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"children":[{"id":984,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"sources":[{"fileName":"window.ts","line":1963,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1963"}],"signatures":[{"id":985,"name":"new CloseRequestedEvent","kind":16384,"kindString":"Constructor signature","flags":{},"parameters":[{"id":986,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1096,"typeArguments":[{"type":"literal","value":null}],"name":"Event"}}],"type":{"type":"reference","id":983,"name":"CloseRequestedEvent"}}]},{"id":990,"name":"_preventDefault","kind":1024,"kindString":"Property","flags":{"isPrivate":true},"sources":[{"fileName":"window.ts","line":1961,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1961"}],"type":{"type":"intrinsic","name":"boolean"},"defaultValue":"false"},{"id":987,"name":"event","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name"}]},"sources":[{"fileName":"window.ts","line":1956,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1956"}],"type":{"type":"reference","id":63,"name":"EventName"}},{"id":989,"name":"id","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Event identifier used to unlisten"}]},"sources":[{"fileName":"window.ts","line":1960,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1960"}],"type":{"type":"intrinsic","name":"number"}},{"id":988,"name":"windowLabel","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The label of the window that emitted this event."}]},"sources":[{"fileName":"window.ts","line":1958,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1958"}],"type":{"type":"intrinsic","name":"string"}},{"id":993,"name":"isPreventDefault","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1973,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1973"}],"signatures":[{"id":994,"name":"isPreventDefault","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"intrinsic","name":"boolean"}}]},{"id":991,"name":"preventDefault","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1969,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1969"}],"signatures":[{"id":992,"name":"preventDefault","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"intrinsic","name":"void"}}]}],"groups":[{"title":"Constructors","children":[984]},{"title":"Properties","children":[990,987,989,988]},{"title":"Methods","children":[993,991]}],"sources":[{"fileName":"window.ts","line":1954,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1954"}]},{"id":1019,"name":"LogicalPosition","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"A position represented in logical pixels."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":1020,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"sources":[{"fileName":"window.ts","line":164,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L164"}],"signatures":[{"id":1021,"name":"new LogicalPosition","kind":16384,"kindString":"Constructor signature","flags":{},"parameters":[{"id":1022,"name":"x","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}},{"id":1023,"name":"y","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}}],"type":{"type":"reference","id":1019,"name":"LogicalPosition"}}]},{"id":1024,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":160,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L160"}],"type":{"type":"intrinsic","name":"string"},"defaultValue":"'Logical'"},{"id":1025,"name":"x","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":161,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L161"}],"type":{"type":"intrinsic","name":"number"}},{"id":1026,"name":"y","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":162,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L162"}],"type":{"type":"intrinsic","name":"number"}}],"groups":[{"title":"Constructors","children":[1020]},{"title":"Properties","children":[1024,1025,1026]}],"sources":[{"fileName":"window.ts","line":159,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L159"}]},{"id":1000,"name":"LogicalSize","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"A size represented in logical pixels."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":1001,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"sources":[{"fileName":"window.ts","line":118,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L118"}],"signatures":[{"id":1002,"name":"new LogicalSize","kind":16384,"kindString":"Constructor signature","flags":{},"parameters":[{"id":1003,"name":"width","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}},{"id":1004,"name":"height","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}}],"type":{"type":"reference","id":1000,"name":"LogicalSize"}}]},{"id":1007,"name":"height","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":116,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L116"}],"type":{"type":"intrinsic","name":"number"}},{"id":1005,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":114,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L114"}],"type":{"type":"intrinsic","name":"string"},"defaultValue":"'Logical'"},{"id":1006,"name":"width","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":115,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L115"}],"type":{"type":"intrinsic","name":"number"}}],"groups":[{"title":"Constructors","children":[1001]},{"title":"Properties","children":[1007,1005,1006]}],"sources":[{"fileName":"window.ts","line":113,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L113"}]},{"id":1027,"name":"PhysicalPosition","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"A position represented in physical pixels."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":1028,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"sources":[{"fileName":"window.ts","line":180,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L180"}],"signatures":[{"id":1029,"name":"new PhysicalPosition","kind":16384,"kindString":"Constructor signature","flags":{},"parameters":[{"id":1030,"name":"x","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}},{"id":1031,"name":"y","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}}],"type":{"type":"reference","id":1027,"name":"PhysicalPosition"}}]},{"id":1032,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":176,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L176"}],"type":{"type":"intrinsic","name":"string"},"defaultValue":"'Physical'"},{"id":1033,"name":"x","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":177,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L177"}],"type":{"type":"intrinsic","name":"number"}},{"id":1034,"name":"y","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":178,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L178"}],"type":{"type":"intrinsic","name":"number"}},{"id":1035,"name":"toLogical","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":195,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L195"}],"signatures":[{"id":1036,"name":"toLogical","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Converts the physical position to a logical one."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst factor = await appWindow.scaleFactor();\nconst position = await appWindow.innerPosition();\nconst logical = position.toLogical(factor);\n```"}]}]},"parameters":[{"id":1037,"name":"scaleFactor","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}}],"type":{"type":"reference","id":1019,"name":"LogicalPosition"}}]}],"groups":[{"title":"Constructors","children":[1028]},{"title":"Properties","children":[1032,1033,1034]},{"title":"Methods","children":[1035]}],"sources":[{"fileName":"window.ts","line":175,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L175"}]},{"id":1008,"name":"PhysicalSize","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"A size represented in physical pixels."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":1009,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"sources":[{"fileName":"window.ts","line":134,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L134"}],"signatures":[{"id":1010,"name":"new PhysicalSize","kind":16384,"kindString":"Constructor signature","flags":{},"parameters":[{"id":1011,"name":"width","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}},{"id":1012,"name":"height","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}}],"type":{"type":"reference","id":1008,"name":"PhysicalSize"}}]},{"id":1015,"name":"height","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":132,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L132"}],"type":{"type":"intrinsic","name":"number"}},{"id":1013,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":130,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L130"}],"type":{"type":"intrinsic","name":"string"},"defaultValue":"'Physical'"},{"id":1014,"name":"width","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":131,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L131"}],"type":{"type":"intrinsic","name":"number"}},{"id":1016,"name":"toLogical","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":149,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L149"}],"signatures":[{"id":1017,"name":"toLogical","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Converts the physical size to a logical one."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst factor = await appWindow.scaleFactor();\nconst size = await appWindow.innerSize();\nconst logical = size.toLogical(factor);\n```"}]}]},"parameters":[{"id":1018,"name":"scaleFactor","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}}],"type":{"type":"reference","id":1000,"name":"LogicalSize"}}]}],"groups":[{"title":"Constructors","children":[1009]},{"title":"Properties","children":[1015,1013,1014]},{"title":"Methods","children":[1016]}],"sources":[{"fileName":"window.ts","line":129,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L129"}]},{"id":640,"name":"WebviewWindow","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"Create new webview windows and get a handle to existing ones.\n\nWindows are identified by a *label* a unique identifier that can be used to reference it later.\nIt may only contain alphanumeric characters "},{"kind":"code","text":"`a-zA-Z`"},{"kind":"text","text":" plus the following special characters "},{"kind":"code","text":"`-`"},{"kind":"text","text":", "},{"kind":"code","text":"`/`"},{"kind":"text","text":", "},{"kind":"code","text":"`:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`_`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\n// loading embedded asset:\nconst webview = new WebviewWindow('theUniqueLabel', {\n url: 'path/to/page.html'\n});\n// alternatively, load a remote URL:\nconst webview = new WebviewWindow('theUniqueLabel', {\n url: 'https://github.com/tauri-apps/tauri'\n});\n\nwebview.once('tauri://created', function () {\n // webview window successfully created\n});\nwebview.once('tauri://error', function (e) {\n // an error happened creating the webview window\n});\n\n// emit an event to the backend\nawait webview.emit(\"some event\", \"data\");\n// listen to an event from the backend\nconst unlisten = await webview.listen(\"event name\", e => {});\nunlisten();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"children":[{"id":644,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"sources":[{"fileName":"window.ts","line":2031,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2031"}],"signatures":[{"id":645,"name":"new WebviewWindow","kind":16384,"kindString":"Constructor signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a new WebviewWindow."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { WebviewWindow } from '@tauri-apps/api/window';\nconst webview = new WebviewWindow('my-label', {\n url: 'https://github.com/tauri-apps/tauri'\n});\nwebview.once('tauri://created', function () {\n // webview window successfully created\n});\nwebview.once('tauri://error', function (e) {\n // an error happened creating the webview window\n});\n```"},{"kind":"text","text":"\n\n*"}]},{"tag":"@returns","content":[{"kind":"text","text":"The WebviewWindow instance to communicate with the webview."}]}]},"parameters":[{"id":646,"name":"label","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The unique webview window label. Must be alphanumeric: "},{"kind":"code","text":"`a-zA-Z-/:_`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":647,"name":"options","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1066,"name":"WindowOptions"},"defaultValue":"{}"}],"type":{"type":"reference","id":640,"name":"WebviewWindow"},"overwrites":{"type":"reference","name":"WindowManager.constructor"}}],"overwrites":{"type":"reference","name":"WindowManager.constructor"}},{"id":780,"name":"label","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The window label. It is a unique identifier for the window, can be used to reference it later."}]},"sources":[{"fileName":"window.ts","line":316,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L316"}],"type":{"type":"intrinsic","name":"string"},"inheritedFrom":{"type":"reference","name":"WindowManager.label"}},{"id":781,"name":"listeners","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Local event listeners."}]},"sources":[{"fileName":"window.ts","line":318,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L318"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"reference","id":1102,"typeArguments":[{"type":"intrinsic","name":"any"}],"name":"EventCallback"}}],"name":"Record","qualifiedName":"Record","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.listeners"}},{"id":674,"name":"center","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":780,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L780"}],"signatures":[{"id":675,"name":"center","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Centers the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.center();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.center"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.center"}},{"id":699,"name":"close","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1081,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1081"}],"signatures":[{"id":700,"name":"close","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Closes the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.close();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.close"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.close"}},{"id":792,"name":"emit","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":400,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L400"}],"signatures":[{"id":793,"name":"emit","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Emits an event to the backend, tied to the webview window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.emit('window-loaded', { loggedIn: true, token: 'authToken' });\n```"}]}]},"parameters":[{"id":794,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name. Must include only alphanumeric characters, "},{"kind":"code","text":"`-`"},{"kind":"text","text":", "},{"kind":"code","text":"`/`"},{"kind":"text","text":", "},{"kind":"code","text":"`:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`_`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":795,"name":"payload","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Event payload."}]},"type":{"type":"intrinsic","name":"unknown"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.emit"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.emit"}},{"id":697,"name":"hide","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1056,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1056"}],"signatures":[{"id":698,"name":"hide","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window visibility to false."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.hide();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.hide"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.hide"}},{"id":650,"name":"innerPosition","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":470,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L470"}],"signatures":[{"id":651,"name":"innerPosition","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"The position of the top-left hand corner of the window's client area relative to the top-left hand corner of the desktop."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst position = await appWindow.innerPosition();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The window's inner position."}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":1027,"name":"PhysicalPosition"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.innerPosition"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.innerPosition"}},{"id":654,"name":"innerSize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":521,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L521"}],"signatures":[{"id":655,"name":"innerSize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"The physical size of the window's client area.\nThe client area is the content of the window, excluding the title bar and borders."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst size = await appWindow.innerSize();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The window's inner size."}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":1008,"name":"PhysicalSize"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.innerSize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.innerSize"}},{"id":664,"name":"isDecorated","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":647,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L647"}],"signatures":[{"id":665,"name":"isDecorated","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current decorated state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst decorated = await appWindow.isDecorated();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"Whether the window is decorated or not."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.isDecorated"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.isDecorated"}},{"id":658,"name":"isFullscreen","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":572,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L572"}],"signatures":[{"id":659,"name":"isFullscreen","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current fullscreen state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst fullscreen = await appWindow.isFullscreen();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"Whether the window is in fullscreen mode or not."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.isFullscreen"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.isFullscreen"}},{"id":662,"name":"isMaximized","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":622,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L622"}],"signatures":[{"id":663,"name":"isMaximized","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current maximized state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst maximized = await appWindow.isMaximized();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"Whether the window is maximized or not."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.isMaximized"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.isMaximized"}},{"id":660,"name":"isMinimized","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":597,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L597"}],"signatures":[{"id":661,"name":"isMinimized","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current minimized state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst minimized = await appWindow.isMinimized();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.3.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.isMinimized"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.isMinimized"}},{"id":666,"name":"isResizable","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":672,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L672"}],"signatures":[{"id":667,"name":"isResizable","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current resizable state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst resizable = await appWindow.isResizable();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"Whether the window is resizable or not."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.isResizable"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.isResizable"}},{"id":668,"name":"isVisible","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":697,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L697"}],"signatures":[{"id":669,"name":"isVisible","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current visible state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst visible = await appWindow.isVisible();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"Whether the window is visible or not."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.isVisible"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.isVisible"}},{"id":782,"name":"listen","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":345,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L345"}],"signatures":[{"id":783,"name":"listen","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to an event emitted by the backend that is tied to the webview window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst unlisten = await appWindow.listen('state-changed', (event) => {\n console.log(`Got error: ${payload}`);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]}]},"typeParameter":[{"id":784,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":785,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name. Must include only alphanumeric characters, "},{"kind":"code","text":"`-`"},{"kind":"text","text":", "},{"kind":"code","text":"`/`"},{"kind":"text","text":", "},{"kind":"code","text":"`:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`_`"},{"kind":"text","text":"."}]},"type":{"type":"reference","id":63,"name":"EventName"}},{"id":786,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event handler."}]},"type":{"type":"reference","id":1102,"typeArguments":[{"type":"reference","id":784,"name":"T"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1107,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.listen"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.listen"}},{"id":685,"name":"maximize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":906,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L906"}],"signatures":[{"id":686,"name":"maximize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Maximizes the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.maximize();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.maximize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.maximize"}},{"id":691,"name":"minimize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":981,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L981"}],"signatures":[{"id":692,"name":"minimize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Minimizes the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.minimize();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.minimize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.minimize"}},{"id":759,"name":"onCloseRequested","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1763,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1763"}],"signatures":[{"id":760,"name":"onCloseRequested","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to window close requested. Emitted when the user requests to closes the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nimport { confirm } from '@tauri-apps/api/dialog';\nconst unlisten = await appWindow.onCloseRequested(async (event) => {\n const confirmed = await confirm('Are you sure?');\n if (!confirmed) {\n // user did not confirm closing the window; let's prevent it\n event.preventDefault();\n }\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":761,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":762,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"window.ts","line":1764,"character":13,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1764"}],"signatures":[{"id":763,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":764,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":983,"name":"CloseRequestedEvent"}}],"type":{"type":"union","types":[{"type":"intrinsic","name":"void"},{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}]}}]}}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1107,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onCloseRequested"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onCloseRequested"}},{"id":774,"name":"onFileDropEvent","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1896,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1896"}],"signatures":[{"id":775,"name":"onFileDropEvent","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to a file drop event.\nThe listener is triggered when the user hovers the selected files on the window,\ndrops the files or cancels the operation."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nconst unlisten = await appWindow.onFileDropEvent((event) => {\n if (event.payload.type === 'hover') {\n console.log('User hovering', event.payload.paths);\n } else if (event.payload.type === 'drop') {\n console.log('User dropped', event.payload.paths);\n } else {\n console.log('File drop cancelled');\n }\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":776,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1102,"typeArguments":[{"type":"reference","id":1057,"name":"FileDropEvent"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1107,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onFileDropEvent"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onFileDropEvent"}},{"id":765,"name":"onFocusChanged","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1795,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1795"}],"signatures":[{"id":766,"name":"onFocusChanged","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to window focus change."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nconst unlisten = await appWindow.onFocusChanged(({ payload: focused }) => {\n console.log('Focus changed, window is focused? ' + focused);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":767,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1102,"typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1107,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onFocusChanged"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onFocusChanged"}},{"id":771,"name":"onMenuClicked","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1865,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1865"}],"signatures":[{"id":772,"name":"onMenuClicked","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to the window menu item click. The payload is the item id."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nconst unlisten = await appWindow.onMenuClicked(({ payload: menuId }) => {\n console.log('Menu clicked: ' + menuId);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":773,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1102,"typeArguments":[{"type":"intrinsic","name":"string"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1107,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onMenuClicked"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onMenuClicked"}},{"id":756,"name":"onMoved","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1735,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1735"}],"signatures":[{"id":757,"name":"onMoved","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to window move."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nconst unlisten = await appWindow.onMoved(({ payload: position }) => {\n console.log('Window moved', position);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":758,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1102,"typeArguments":[{"type":"reference","id":1027,"name":"PhysicalPosition"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1107,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onMoved"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onMoved"}},{"id":753,"name":"onResized","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1712,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1712"}],"signatures":[{"id":754,"name":"onResized","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to window resize."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nconst unlisten = await appWindow.onResized(({ payload: size }) => {\n console.log('Window resized', size);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":755,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1102,"typeArguments":[{"type":"reference","id":1008,"name":"PhysicalSize"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1107,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onResized"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onResized"}},{"id":768,"name":"onScaleChanged","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1837,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1837"}],"signatures":[{"id":769,"name":"onScaleChanged","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to window scale change. Emitted when the window's scale factor has changed.\nThe following user actions can cause DPI changes:\n- Changing the display's resolution.\n- Changing the display's scale factor (e.g. in Control Panel on Windows).\n- Moving the window to a display with a different scale factor."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nconst unlisten = await appWindow.onScaleChanged(({ payload }) => {\n console.log('Scale changed', payload.scaleFactor, payload.size);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":770,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1102,"typeArguments":[{"type":"reference","id":1054,"name":"ScaleFactorChanged"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1107,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onScaleChanged"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onScaleChanged"}},{"id":777,"name":"onThemeChanged","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1946,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1946"}],"signatures":[{"id":778,"name":"onThemeChanged","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to the system theme change."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nconst unlisten = await appWindow.onThemeChanged(({ payload: theme }) => {\n console.log('New theme: ' + theme);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":779,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1102,"typeArguments":[{"type":"reference","id":1047,"name":"Theme"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1107,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onThemeChanged"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onThemeChanged"}},{"id":787,"name":"once","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":378,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L378"}],"signatures":[{"id":788,"name":"once","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to an one-off event emitted by the backend that is tied to the webview window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst unlisten = await appWindow.once('initialized', (event) => {\n console.log(`Window initialized!`);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]}]},"typeParameter":[{"id":789,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":790,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name. Must include only alphanumeric characters, "},{"kind":"code","text":"`-`"},{"kind":"text","text":", "},{"kind":"code","text":"`/`"},{"kind":"text","text":", "},{"kind":"code","text":"`:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`_`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":791,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event handler."}]},"type":{"type":"reference","id":1102,"typeArguments":[{"type":"reference","id":789,"name":"T"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1107,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.once"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.once"}},{"id":652,"name":"outerPosition","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":495,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L495"}],"signatures":[{"id":653,"name":"outerPosition","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"The position of the top-left hand corner of the window relative to the top-left hand corner of the desktop."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst position = await appWindow.outerPosition();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The window's outer position."}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":1027,"name":"PhysicalPosition"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.outerPosition"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.outerPosition"}},{"id":656,"name":"outerSize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":547,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L547"}],"signatures":[{"id":657,"name":"outerSize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"The physical size of the entire window.\nThese dimensions include the title bar and borders. If you don't want that (and you usually don't), use inner_size instead."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst size = await appWindow.outerSize();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The window's outer size."}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":1008,"name":"PhysicalSize"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.outerSize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.outerSize"}},{"id":676,"name":"requestUserAttention","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":816,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L816"}],"signatures":[{"id":677,"name":"requestUserAttention","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Requests user attention to the window, this has no effect if the application\nis already focused. How requesting for user attention manifests is platform dependent,\nsee "},{"kind":"code","text":"`UserAttentionType`"},{"kind":"text","text":" for details.\n\nProviding "},{"kind":"code","text":"`null`"},{"kind":"text","text":" will unset the request for user attention. Unsetting the request for\nuser attention might not be done automatically by the WM when the window receives input.\n\n#### Platform-specific\n\n- **macOS:** "},{"kind":"code","text":"`null`"},{"kind":"text","text":" has no effect.\n- **Linux:** Urgency levels have the same effect."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.requestUserAttention();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":678,"name":"requestType","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"union","types":[{"type":"literal","value":null},{"type":"reference","id":1038,"name":"UserAttentionType"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.requestUserAttention"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.requestUserAttention"}},{"id":648,"name":"scaleFactor","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":445,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L445"}],"signatures":[{"id":649,"name":"scaleFactor","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"The scale factor that can be used to map physical pixels to logical pixels."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst factor = await appWindow.scaleFactor();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The window's monitor scale factor."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"number"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.scaleFactor"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.scaleFactor"}},{"id":707,"name":"setAlwaysOnTop","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1171,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1171"}],"signatures":[{"id":708,"name":"setAlwaysOnTop","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Whether the window should always be on top of other windows."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setAlwaysOnTop(true);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":709,"name":"alwaysOnTop","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Whether the window should always be on top of other windows or not."}]},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setAlwaysOnTop"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setAlwaysOnTop"}},{"id":710,"name":"setContentProtected","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1199,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1199"}],"signatures":[{"id":711,"name":"setContentProtected","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Prevents the window contents from being captured by other apps."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setContentProtected(true);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"parameters":[{"id":712,"name":"protected_","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setContentProtected"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setContentProtected"}},{"id":736,"name":"setCursorGrab","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1519,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1519"}],"signatures":[{"id":737,"name":"setCursorGrab","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Grabs the cursor, preventing it from leaving the window.\n\nThere's no guarantee that the cursor will be hidden. You should\nhide it by yourself if you want so.\n\n#### Platform-specific\n\n- **Linux:** Unsupported.\n- **macOS:** This locks the cursor in a fixed location, which looks visually awkward."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setCursorGrab(true);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":738,"name":"grab","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"code","text":"`true`"},{"kind":"text","text":" to grab the cursor icon, "},{"kind":"code","text":"`false`"},{"kind":"text","text":" to release it."}]},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorGrab"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorGrab"}},{"id":742,"name":"setCursorIcon","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1579,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1579"}],"signatures":[{"id":743,"name":"setCursorIcon","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Modifies the cursor icon of the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setCursorIcon('help');\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":744,"name":"icon","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The new cursor icon."}]},"type":{"type":"reference","id":638,"name":"CursorIcon"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorIcon"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorIcon"}},{"id":745,"name":"setCursorPosition","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1606,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1606"}],"signatures":[{"id":746,"name":"setCursorPosition","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Changes the position of the cursor in window coordinates."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow, LogicalPosition } from '@tauri-apps/api/window';\nawait appWindow.setCursorPosition(new LogicalPosition(600, 300));\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":747,"name":"position","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The new cursor position."}]},"type":{"type":"union","types":[{"type":"reference","id":1027,"name":"PhysicalPosition"},{"type":"reference","id":1019,"name":"LogicalPosition"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorPosition"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorPosition"}},{"id":739,"name":"setCursorVisible","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1552,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1552"}],"signatures":[{"id":740,"name":"setCursorVisible","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Modifies the cursor's visibility.\n\n#### Platform-specific\n\n- **Windows:** The cursor is only hidden within the confines of the window.\n- **macOS:** The cursor is hidden as long as the window has input focus, even if the cursor is\n outside of the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setCursorVisible(false);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":741,"name":"visible","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"If "},{"kind":"code","text":"`false`"},{"kind":"text","text":", this will hide the cursor. If "},{"kind":"code","text":"`true`"},{"kind":"text","text":", this will show the cursor."}]},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorVisible"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorVisible"}},{"id":701,"name":"setDecorations","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1107,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1107"}],"signatures":[{"id":702,"name":"setDecorations","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Whether the window should have borders and bars."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setDecorations(false);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":703,"name":"decorations","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Whether the window should have borders and bars."}]},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setDecorations"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setDecorations"}},{"id":728,"name":"setFocus","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1417,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1417"}],"signatures":[{"id":729,"name":"setFocus","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Bring the window to front and focus."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setFocus();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setFocus"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setFocus"}},{"id":725,"name":"setFullscreen","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1391,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1391"}],"signatures":[{"id":726,"name":"setFullscreen","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window fullscreen state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setFullscreen(true);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":727,"name":"fullscreen","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Whether the window should go to fullscreen or not."}]},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setFullscreen"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setFullscreen"}},{"id":730,"name":"setIcon","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1450,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1450"}],"signatures":[{"id":731,"name":"setIcon","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window icon."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setIcon('/tauri/awesome.png');\n```"},{"kind":"text","text":"\n\nNote that you need the "},{"kind":"code","text":"`icon-ico`"},{"kind":"text","text":" or "},{"kind":"code","text":"`icon-png`"},{"kind":"text","text":" Cargo features to use this API.\nTo enable it, change your Cargo.toml file:\n"},{"kind":"code","text":"```toml\n[dependencies]\ntauri = { version = \"...\", features = [\"...\", \"icon-png\"] }\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":732,"name":"icon","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Icon bytes or path to the icon file."}]},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","name":"Uint8Array","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array","qualifiedName":"Uint8Array","package":"typescript"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setIcon"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setIcon"}},{"id":748,"name":"setIgnoreCursorEvents","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1650,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1650"}],"signatures":[{"id":749,"name":"setIgnoreCursorEvents","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Changes the cursor events behavior."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setIgnoreCursorEvents(true);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":750,"name":"ignore","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"code","text":"`true`"},{"kind":"text","text":" to ignore the cursor events; "},{"kind":"code","text":"`false`"},{"kind":"text","text":" to process them as usual."}]},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setIgnoreCursorEvents"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setIgnoreCursorEvents"}},{"id":719,"name":"setMaxSize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1306,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1306"}],"signatures":[{"id":720,"name":"setMaxSize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window maximum inner size. If the "},{"kind":"code","text":"`size`"},{"kind":"text","text":" argument is undefined, the constraint is unset."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow, LogicalSize } from '@tauri-apps/api/window';\nawait appWindow.setMaxSize(new LogicalSize(600, 500));\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":721,"name":"size","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The logical or physical inner size, or "},{"kind":"code","text":"`null`"},{"kind":"text","text":" to unset the constraint."}]},"type":{"type":"union","types":[{"type":"intrinsic","name":"undefined"},{"type":"literal","value":null},{"type":"reference","id":1008,"name":"PhysicalSize"},{"type":"reference","id":1000,"name":"LogicalSize"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setMaxSize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setMaxSize"}},{"id":716,"name":"setMinSize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1264,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1264"}],"signatures":[{"id":717,"name":"setMinSize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window minimum inner size. If the "},{"kind":"code","text":"`size`"},{"kind":"text","text":" argument is not provided, the constraint is unset."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow, PhysicalSize } from '@tauri-apps/api/window';\nawait appWindow.setMinSize(new PhysicalSize(600, 500));\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":718,"name":"size","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The logical or physical inner size, or "},{"kind":"code","text":"`null`"},{"kind":"text","text":" to unset the constraint."}]},"type":{"type":"union","types":[{"type":"intrinsic","name":"undefined"},{"type":"literal","value":null},{"type":"reference","id":1008,"name":"PhysicalSize"},{"type":"reference","id":1000,"name":"LogicalSize"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setMinSize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setMinSize"}},{"id":722,"name":"setPosition","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1348,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1348"}],"signatures":[{"id":723,"name":"setPosition","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window outer position."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow, LogicalPosition } from '@tauri-apps/api/window';\nawait appWindow.setPosition(new LogicalPosition(600, 500));\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":724,"name":"position","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The new position, in logical or physical pixels."}]},"type":{"type":"union","types":[{"type":"reference","id":1027,"name":"PhysicalPosition"},{"type":"reference","id":1019,"name":"LogicalPosition"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setPosition"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setPosition"}},{"id":679,"name":"setResizable","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":853,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L853"}],"signatures":[{"id":680,"name":"setResizable","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Updates the window resizable flag."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setResizable(false);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":681,"name":"resizable","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setResizable"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setResizable"}},{"id":704,"name":"setShadow","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1144,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1144"}],"signatures":[{"id":705,"name":"setShadow","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Whether or not the window should have shadow.\n\n#### Platform-specific\n\n- **Windows:**\n - "},{"kind":"code","text":"`false`"},{"kind":"text","text":" has no effect on decorated window, shadows are always ON.\n - "},{"kind":"code","text":"`true`"},{"kind":"text","text":" will make ndecorated window have a 1px white border,\nand on Windows 11, it will have a rounded corners.\n- **Linux:** Unsupported."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setShadow(false);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]},{"tag":"@since","content":[{"kind":"text","text":"2.0"}]}]},"parameters":[{"id":706,"name":"enable","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setShadow"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setShadow"}},{"id":713,"name":"setSize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1226,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1226"}],"signatures":[{"id":714,"name":"setSize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Resizes the window with a new inner size."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow, LogicalSize } from '@tauri-apps/api/window';\nawait appWindow.setSize(new LogicalSize(600, 500));\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":715,"name":"size","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The logical or physical inner size."}]},"type":{"type":"union","types":[{"type":"reference","id":1008,"name":"PhysicalSize"},{"type":"reference","id":1000,"name":"LogicalSize"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setSize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setSize"}},{"id":733,"name":"setSkipTaskbar","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1484,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1484"}],"signatures":[{"id":734,"name":"setSkipTaskbar","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Whether the window icon should be hidden from the taskbar or not.\n\n#### Platform-specific\n\n- **macOS:** Unsupported."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setSkipTaskbar(true);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":735,"name":"skip","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"true to hide window icon, false to show it."}]},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setSkipTaskbar"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setSkipTaskbar"}},{"id":682,"name":"setTitle","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":880,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L880"}],"signatures":[{"id":683,"name":"setTitle","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window title."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setTitle('Tauri');\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":684,"name":"title","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The new title"}]},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setTitle"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setTitle"}},{"id":695,"name":"show","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1031,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1031"}],"signatures":[{"id":696,"name":"show","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window visibility to true."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.show();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.show"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.show"}},{"id":751,"name":"startDragging","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1676,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1676"}],"signatures":[{"id":752,"name":"startDragging","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Starts dragging the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.startDragging();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.startDragging"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.startDragging"}},{"id":672,"name":"theme","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":752,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L752"}],"signatures":[{"id":673,"name":"theme","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current theme.\n\n#### Platform-specific\n\n- **macOS:** Theme was introduced on macOS 10.14. Returns "},{"kind":"code","text":"`light`"},{"kind":"text","text":" on macOS 10.13 and below."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst theme = await appWindow.theme();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The window theme."}]}]},"type":{"type":"reference","typeArguments":[{"type":"union","types":[{"type":"literal","value":null},{"type":"reference","id":1047,"name":"Theme"}]}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.theme"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.theme"}},{"id":670,"name":"title","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":722,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L722"}],"signatures":[{"id":671,"name":"title","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current title."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst title = await appWindow.title();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.3.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.title"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.title"}},{"id":689,"name":"toggleMaximize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":956,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L956"}],"signatures":[{"id":690,"name":"toggleMaximize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Toggles the window maximized state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.toggleMaximize();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.toggleMaximize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.toggleMaximize"}},{"id":687,"name":"unmaximize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":931,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L931"}],"signatures":[{"id":688,"name":"unmaximize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Unmaximizes the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.unmaximize();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.unmaximize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.unmaximize"}},{"id":693,"name":"unminimize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1006,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L1006"}],"signatures":[{"id":694,"name":"unminimize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Unminimizes the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.unminimize();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.unminimize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.unminimize"}},{"id":641,"name":"getByLabel","kind":2048,"kindString":"Method","flags":{"isStatic":true},"sources":[{"fileName":"window.ts","line":2063,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2063"}],"signatures":[{"id":642,"name":"getByLabel","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the WebviewWindow for the webview associated with the given label."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { WebviewWindow } from '@tauri-apps/api/window';\nconst mainWindow = WebviewWindow.getByLabel('main');\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The WebviewWindow instance to communicate with the webview or null if the webview doesn't exist."}]}]},"parameters":[{"id":643,"name":"label","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The webview window label."}]},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"union","types":[{"type":"literal","value":null},{"type":"reference","id":640,"name":"WebviewWindow"}]}}]}],"groups":[{"title":"Constructors","children":[644]},{"title":"Properties","children":[780,781]},{"title":"Methods","children":[674,699,792,697,650,654,664,658,662,660,666,668,782,685,691,759,774,765,771,756,753,768,777,787,652,656,676,648,707,710,736,742,745,739,701,728,725,730,748,719,716,722,679,704,713,733,682,695,751,672,670,689,687,693,641]}],"sources":[{"fileName":"window.ts","line":2011,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2011"}],"extendedTypes":[{"type":"reference","name":"WindowManager"}]},{"id":1049,"name":"Monitor","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Allows you to retrieve information about a given monitor."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":1050,"name":"name","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Human-readable name of the monitor"}]},"sources":[{"fileName":"window.ts","line":81,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L81"}],"type":{"type":"union","types":[{"type":"literal","value":null},{"type":"intrinsic","name":"string"}]}},{"id":1052,"name":"position","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"the Top-left corner position of the monitor relative to the larger full screen area."}]},"sources":[{"fileName":"window.ts","line":85,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L85"}],"type":{"type":"reference","id":1027,"name":"PhysicalPosition"}},{"id":1053,"name":"scaleFactor","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The scale factor that can be used to map physical pixels to logical pixels."}]},"sources":[{"fileName":"window.ts","line":87,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L87"}],"type":{"type":"intrinsic","name":"number"}},{"id":1051,"name":"size","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The monitor's resolution."}]},"sources":[{"fileName":"window.ts","line":83,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L83"}],"type":{"type":"reference","id":1008,"name":"PhysicalSize"}}],"groups":[{"title":"Properties","children":[1050,1052,1053,1051]}],"sources":[{"fileName":"window.ts","line":79,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L79"}]},{"id":1054,"name":"ScaleFactorChanged","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"The payload for the "},{"kind":"code","text":"`scaleChange`"},{"kind":"text","text":" event."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"children":[{"id":1055,"name":"scaleFactor","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The new window scale factor."}]},"sources":[{"fileName":"window.ts","line":97,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L97"}],"type":{"type":"intrinsic","name":"number"}},{"id":1056,"name":"size","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The new window size"}]},"sources":[{"fileName":"window.ts","line":99,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L99"}],"type":{"type":"reference","id":1008,"name":"PhysicalSize"}}],"groups":[{"title":"Properties","children":[1055,1056]}],"sources":[{"fileName":"window.ts","line":95,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L95"}]},{"id":1066,"name":"WindowOptions","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Configuration for the window to create."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":1093,"name":"acceptFirstMouse","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether clicking an inactive window also clicks through to the webview on macOS."}]},"sources":[{"fileName":"window.ts","line":2187,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2187"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1085,"name":"alwaysOnTop","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window should always be on top of other windows or not."}]},"sources":[{"fileName":"window.ts","line":2145,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2145"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1068,"name":"center","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Show window in the center of the screen.."}]},"sources":[{"fileName":"window.ts","line":2107,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2107"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1086,"name":"contentProtected","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Prevents the window contents from being captured by other apps."}]},"sources":[{"fileName":"window.ts","line":2147,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2147"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1084,"name":"decorations","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window should have borders and bars or not."}]},"sources":[{"fileName":"window.ts","line":2143,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2143"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1089,"name":"fileDropEnabled","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the file drop is enabled or not on the webview. By default it is enabled.\n\nDisabling it is required to use drag and drop on the frontend on Windows."}]},"sources":[{"fileName":"window.ts","line":2169,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2169"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1080,"name":"focus","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window will be initially focused or not."}]},"sources":[{"fileName":"window.ts","line":2131,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2131"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1079,"name":"fullscreen","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window is in fullscreen mode or not."}]},"sources":[{"fileName":"window.ts","line":2129,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2129"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1072,"name":"height","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The initial height."}]},"sources":[{"fileName":"window.ts","line":2115,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2115"}],"type":{"type":"intrinsic","name":"number"}},{"id":1092,"name":"hiddenTitle","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"If "},{"kind":"code","text":"`true`"},{"kind":"text","text":", sets the window title to be hidden on macOS."}]},"sources":[{"fileName":"window.ts","line":2183,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2183"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1076,"name":"maxHeight","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The maximum height. Only applies if "},{"kind":"code","text":"`maxWidth`"},{"kind":"text","text":" is also set."}]},"sources":[{"fileName":"window.ts","line":2123,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2123"}],"type":{"type":"intrinsic","name":"number"}},{"id":1075,"name":"maxWidth","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The maximum width. Only applies if "},{"kind":"code","text":"`maxHeight`"},{"kind":"text","text":" is also set."}]},"sources":[{"fileName":"window.ts","line":2121,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2121"}],"type":{"type":"intrinsic","name":"number"}},{"id":1082,"name":"maximized","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window should be maximized upon creation or not."}]},"sources":[{"fileName":"window.ts","line":2139,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2139"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1074,"name":"minHeight","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The minimum height. Only applies if "},{"kind":"code","text":"`minWidth`"},{"kind":"text","text":" is also set."}]},"sources":[{"fileName":"window.ts","line":2119,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2119"}],"type":{"type":"intrinsic","name":"number"}},{"id":1073,"name":"minWidth","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The minimum width. Only applies if "},{"kind":"code","text":"`minHeight`"},{"kind":"text","text":" is also set."}]},"sources":[{"fileName":"window.ts","line":2117,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2117"}],"type":{"type":"intrinsic","name":"number"}},{"id":1077,"name":"resizable","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window is resizable or not."}]},"sources":[{"fileName":"window.ts","line":2125,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2125"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1088,"name":"shadow","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether or not the window has shadow.\n\n#### Platform-specific\n\n- **Windows:**\n - "},{"kind":"code","text":"`false`"},{"kind":"text","text":" has no effect on decorated window, shadows are always ON.\n - "},{"kind":"code","text":"`true`"},{"kind":"text","text":" will make ndecorated window have a 1px white border,\nand on Windows 11, it will have a rounded corners.\n- **Linux:** Unsupported."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"2.0"}]}]},"sources":[{"fileName":"window.ts","line":2163,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2163"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1087,"name":"skipTaskbar","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether or not the window icon should be added to the taskbar."}]},"sources":[{"fileName":"window.ts","line":2149,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2149"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1094,"name":"tabbingIdentifier","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Defines the window [tabbing identifier](https://developer.apple.com/documentation/appkit/nswindow/1644704-tabbingidentifier) on macOS.\n\nWindows with the same tabbing identifier will be grouped together.\nIf the tabbing identifier is not set, automatic tabbing will be disabled."}]},"sources":[{"fileName":"window.ts","line":2194,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2194"}],"type":{"type":"intrinsic","name":"string"}},{"id":1090,"name":"theme","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The initial window theme. Defaults to the system theme.\n\nOnly implemented on Windows and macOS 10.14+."}]},"sources":[{"fileName":"window.ts","line":2175,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2175"}],"type":{"type":"reference","id":1047,"name":"Theme"}},{"id":1078,"name":"title","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Window title."}]},"sources":[{"fileName":"window.ts","line":2127,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2127"}],"type":{"type":"intrinsic","name":"string"}},{"id":1091,"name":"titleBarStyle","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The style of the macOS title bar."}]},"sources":[{"fileName":"window.ts","line":2179,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2179"}],"type":{"type":"reference","id":1048,"name":"TitleBarStyle"}},{"id":1081,"name":"transparent","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window is transparent or not.\nNote that on "},{"kind":"code","text":"`macOS`"},{"kind":"text","text":" this requires the "},{"kind":"code","text":"`macos-private-api`"},{"kind":"text","text":" feature flag, enabled under "},{"kind":"code","text":"`tauri.conf.json > tauri > macOSPrivateApi`"},{"kind":"text","text":".\nWARNING: Using private APIs on "},{"kind":"code","text":"`macOS`"},{"kind":"text","text":" prevents your application from being accepted to the "},{"kind":"code","text":"`App Store`"},{"kind":"text","text":"."}]},"sources":[{"fileName":"window.ts","line":2137,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2137"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1067,"name":"url","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Remote URL or local file path to open.\n\n- URL such as "},{"kind":"code","text":"`https://github.com/tauri-apps`"},{"kind":"text","text":" is opened directly on a Tauri window.\n- data: URL such as "},{"kind":"code","text":"`data:text/html,...`"},{"kind":"text","text":" is only supported with the "},{"kind":"code","text":"`window-data-url`"},{"kind":"text","text":" Cargo feature for the "},{"kind":"code","text":"`tauri`"},{"kind":"text","text":" dependency.\n- local file path or route such as "},{"kind":"code","text":"`/path/to/page.html`"},{"kind":"text","text":" or "},{"kind":"code","text":"`/users`"},{"kind":"text","text":" is appended to the application URL (the devServer URL on development, or "},{"kind":"code","text":"`tauri://localhost/`"},{"kind":"text","text":" and "},{"kind":"code","text":"`https://tauri.localhost/`"},{"kind":"text","text":" on production)."}]},"sources":[{"fileName":"window.ts","line":2105,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2105"}],"type":{"type":"intrinsic","name":"string"}},{"id":1095,"name":"userAgent","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The user agent for the webview."}]},"sources":[{"fileName":"window.ts","line":2198,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2198"}],"type":{"type":"intrinsic","name":"string"}},{"id":1083,"name":"visible","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window should be immediately visible upon creation or not."}]},"sources":[{"fileName":"window.ts","line":2141,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2141"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1071,"name":"width","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The initial width."}]},"sources":[{"fileName":"window.ts","line":2113,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2113"}],"type":{"type":"intrinsic","name":"number"}},{"id":1069,"name":"x","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The initial vertical position. Only applies if "},{"kind":"code","text":"`y`"},{"kind":"text","text":" is also set."}]},"sources":[{"fileName":"window.ts","line":2109,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2109"}],"type":{"type":"intrinsic","name":"number"}},{"id":1070,"name":"y","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The initial horizontal position. Only applies if "},{"kind":"code","text":"`x`"},{"kind":"text","text":" is also set."}]},"sources":[{"fileName":"window.ts","line":2111,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2111"}],"type":{"type":"intrinsic","name":"number"}}],"groups":[{"title":"Properties","children":[1093,1085,1068,1086,1084,1089,1080,1079,1072,1092,1076,1075,1082,1074,1073,1077,1088,1087,1094,1090,1078,1091,1081,1067,1095,1083,1071,1069,1070]}],"sources":[{"fileName":"window.ts","line":2097,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2097"}]},{"id":638,"name":"CursorIcon","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"window.ts","line":235,"character":12,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L235"}],"type":{"type":"union","types":[{"type":"literal","value":"default"},{"type":"literal","value":"crosshair"},{"type":"literal","value":"hand"},{"type":"literal","value":"arrow"},{"type":"literal","value":"move"},{"type":"literal","value":"text"},{"type":"literal","value":"wait"},{"type":"literal","value":"help"},{"type":"literal","value":"progress"},{"type":"literal","value":"notAllowed"},{"type":"literal","value":"contextMenu"},{"type":"literal","value":"cell"},{"type":"literal","value":"verticalText"},{"type":"literal","value":"alias"},{"type":"literal","value":"copy"},{"type":"literal","value":"noDrop"},{"type":"literal","value":"grab"},{"type":"literal","value":"grabbing"},{"type":"literal","value":"allScroll"},{"type":"literal","value":"zoomIn"},{"type":"literal","value":"zoomOut"},{"type":"literal","value":"eResize"},{"type":"literal","value":"nResize"},{"type":"literal","value":"neResize"},{"type":"literal","value":"nwResize"},{"type":"literal","value":"sResize"},{"type":"literal","value":"seResize"},{"type":"literal","value":"swResize"},{"type":"literal","value":"wResize"},{"type":"literal","value":"ewResize"},{"type":"literal","value":"nsResize"},{"type":"literal","value":"neswResize"},{"type":"literal","value":"nwseResize"},{"type":"literal","value":"colResize"},{"type":"literal","value":"rowResize"}]}},{"id":1057,"name":"FileDropEvent","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[{"kind":"text","text":"The file drop event types."}]},"sources":[{"fileName":"window.ts","line":103,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L103"}],"type":{"type":"union","types":[{"type":"reflection","declaration":{"id":1058,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"children":[{"id":1060,"name":"paths","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":104,"character":21,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L104"}],"type":{"type":"array","elementType":{"type":"intrinsic","name":"string"}}},{"id":1059,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":104,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L104"}],"type":{"type":"literal","value":"hover"}}],"groups":[{"title":"Properties","children":[1060,1059]}],"sources":[{"fileName":"window.ts","line":104,"character":4,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L104"}]}},{"type":"reflection","declaration":{"id":1061,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"children":[{"id":1063,"name":"paths","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":105,"character":20,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L105"}],"type":{"type":"array","elementType":{"type":"intrinsic","name":"string"}}},{"id":1062,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":105,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L105"}],"type":{"type":"literal","value":"drop"}}],"groups":[{"title":"Properties","children":[1063,1062]}],"sources":[{"fileName":"window.ts","line":105,"character":4,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L105"}]}},{"type":"reflection","declaration":{"id":1064,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"children":[{"id":1065,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":106,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L106"}],"type":{"type":"literal","value":"cancel"}}],"groups":[{"title":"Properties","children":[1065]}],"sources":[{"fileName":"window.ts","line":106,"character":4,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L106"}]}}]}},{"id":1047,"name":"Theme","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"window.ts","line":71,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L71"}],"type":{"type":"union","types":[{"type":"literal","value":"light"},{"type":"literal","value":"dark"}]}},{"id":1048,"name":"TitleBarStyle","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"window.ts","line":72,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L72"}],"type":{"type":"union","types":[{"type":"literal","value":"visible"},{"type":"literal","value":"transparent"},{"type":"literal","value":"overlay"}]}},{"id":999,"name":"appWindow","kind":32,"kindString":"Variable","flags":{},"comment":{"summary":[{"kind":"text","text":"The WebviewWindow for the current window."}]},"sources":[{"fileName":"window.ts","line":2073,"character":4,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2073"}],"type":{"type":"reference","id":640,"name":"WebviewWindow"}},{"id":1045,"name":"availableMonitors","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"window.ts","line":2272,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2272"}],"signatures":[{"id":1046,"name":"availableMonitors","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the list of all the monitors available on the system."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { availableMonitors } from '@tauri-apps/api/window';\nconst monitors = availableMonitors();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"array","elementType":{"type":"reference","id":1049,"name":"Monitor"}}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":1041,"name":"currentMonitor","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"window.ts","line":2223,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2223"}],"signatures":[{"id":1042,"name":"currentMonitor","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the monitor on which the window currently resides.\nReturns "},{"kind":"code","text":"`null`"},{"kind":"text","text":" if current monitor can't be detected."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { currentMonitor } from '@tauri-apps/api/window';\nconst monitor = currentMonitor();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"union","types":[{"type":"reference","id":1049,"name":"Monitor"},{"type":"literal","value":null}]}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":997,"name":"getAll","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"window.ts","line":293,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L293"}],"signatures":[{"id":998,"name":"getAll","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets a list of instances of "},{"kind":"code","text":"`WebviewWindow`"},{"kind":"text","text":" for all available webview windows."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"array","elementType":{"type":"reference","id":640,"name":"WebviewWindow"}}}]},{"id":995,"name":"getCurrent","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"window.ts","line":281,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L281"}],"signatures":[{"id":996,"name":"getCurrent","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Get an instance of "},{"kind":"code","text":"`WebviewWindow`"},{"kind":"text","text":" for the current webview window."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","id":640,"name":"WebviewWindow"}}]},{"id":1043,"name":"primaryMonitor","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"window.ts","line":2248,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L2248"}],"signatures":[{"id":1044,"name":"primaryMonitor","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the primary monitor of the system.\nReturns "},{"kind":"code","text":"`null`"},{"kind":"text","text":" if it can't identify any monitor as a primary one."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { primaryMonitor } from '@tauri-apps/api/window';\nconst monitor = primaryMonitor();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"union","types":[{"type":"reference","id":1049,"name":"Monitor"},{"type":"literal","value":null}]}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Enumerations","children":[1038]},{"title":"Classes","children":[983,1019,1000,1027,1008,640]},{"title":"Interfaces","children":[1049,1054,1066]},{"title":"Type Aliases","children":[638,1057,1047,1048]},{"title":"Variables","children":[999]},{"title":"Functions","children":[1045,1041,997,995,1043]}],"sources":[{"fileName":"window.ts","line":66,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/276e4a3fd/tooling/api/src/window.ts#L66"}]}],"groups":[{"title":"Modules","children":[1,12,62,97,118,223,237,250,265,361,367,597,615,637]}]} \ No newline at end of file +{"id":0,"name":"@tauri-apps/api","kind":1,"flags":{},"originalName":"","children":[{"id":1,"name":"app","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Get application metadata.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.app`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be added to ["},{"kind":"code","text":"`tauri.allowlist.app`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.app) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"app\": {\n \"all\": true, // enable all app APIs\n \"show\": true,\n \"hide\": true\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security."}]},"children":[{"id":2,"name":"getName","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"app.ts","line":60,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/app.ts#L60"}],"signatures":[{"id":3,"name":"getName","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the application name."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getName } from '@tauri-apps/api/app';\nconst appName = await getName();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":6,"name":"getTauriVersion","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"app.ts","line":80,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/app.ts#L80"}],"signatures":[{"id":7,"name":"getTauriVersion","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the Tauri version."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getTauriVersion } from '@tauri-apps/api/app';\nconst tauriVersion = await getTauriVersion();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":4,"name":"getVersion","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"app.ts","line":41,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/app.ts#L41"}],"signatures":[{"id":5,"name":"getVersion","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the application version."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getVersion } from '@tauri-apps/api/app';\nconst appVersion = await getVersion();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":10,"name":"hide","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"app.ts","line":120,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/app.ts#L120"}],"signatures":[{"id":11,"name":"hide","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Hides the application on macOS."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { hide } from '@tauri-apps/api/app';\nawait hide();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":8,"name":"show","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"app.ts","line":100,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/app.ts#L100"}],"signatures":[{"id":9,"name":"show","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Shows the application on macOS. This function does not automatically focus any specific app window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { show } from '@tauri-apps/api/app';\nawait show();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Functions","children":[2,6,4,10,8]}],"sources":[{"fileName":"app.ts","line":29,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/app.ts#L29"}]},{"id":12,"name":"dialog","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Native system dialogs for opening and saving files.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.dialog`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be added to ["},{"kind":"code","text":"`tauri.allowlist.dialog`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.dialog) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"dialog\": {\n \"all\": true, // enable all dialog APIs\n \"ask\": true, // enable dialog ask API\n \"confirm\": true, // enable dialog confirm API\n \"message\": true, // enable dialog message API\n \"open\": true, // enable file open API\n \"save\": true // enable file save API\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security."}]},"children":[{"id":31,"name":"ConfirmDialogOptions","kind":256,"kindString":"Interface","flags":{},"children":[{"id":35,"name":"cancelLabel","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The label of the cancel button."}]},"sources":[{"fileName":"dialog.ts","line":112,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L112"}],"type":{"type":"intrinsic","name":"string"}},{"id":34,"name":"okLabel","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The label of the confirm button."}]},"sources":[{"fileName":"dialog.ts","line":110,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L110"}],"type":{"type":"intrinsic","name":"string"}},{"id":32,"name":"title","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The title of the dialog. Defaults to the app name."}]},"sources":[{"fileName":"dialog.ts","line":106,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L106"}],"type":{"type":"intrinsic","name":"string"}},{"id":33,"name":"type","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The type of the dialog. Defaults to "},{"kind":"code","text":"`info`"},{"kind":"text","text":"."}]},"sources":[{"fileName":"dialog.ts","line":108,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L108"}],"type":{"type":"union","types":[{"type":"literal","value":"info"},{"type":"literal","value":"warning"},{"type":"literal","value":"error"}]}}],"groups":[{"title":"Properties","children":[35,34,32,33]}],"sources":[{"fileName":"dialog.ts","line":104,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L104"}]},{"id":13,"name":"DialogFilter","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Extension filters for the file dialog."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":15,"name":"extensions","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Extensions to filter, without a "},{"kind":"code","text":"`.`"},{"kind":"text","text":" prefix."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nextensions: ['svg', 'png']\n```"}]}]},"sources":[{"fileName":"dialog.ts","line":48,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L48"}],"type":{"type":"array","elementType":{"type":"intrinsic","name":"string"}}},{"id":14,"name":"name","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Filter name."}]},"sources":[{"fileName":"dialog.ts","line":40,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L40"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[15,14]}],"sources":[{"fileName":"dialog.ts","line":38,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L38"}]},{"id":27,"name":"MessageDialogOptions","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":30,"name":"okLabel","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The label of the confirm button."}]},"sources":[{"fileName":"dialog.ts","line":101,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L101"}],"type":{"type":"intrinsic","name":"string"}},{"id":28,"name":"title","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The title of the dialog. Defaults to the app name."}]},"sources":[{"fileName":"dialog.ts","line":97,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L97"}],"type":{"type":"intrinsic","name":"string"}},{"id":29,"name":"type","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The type of the dialog. Defaults to "},{"kind":"code","text":"`info`"},{"kind":"text","text":"."}]},"sources":[{"fileName":"dialog.ts","line":99,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L99"}],"type":{"type":"union","types":[{"type":"literal","value":"info"},{"type":"literal","value":"warning"},{"type":"literal","value":"error"}]}}],"groups":[{"title":"Properties","children":[30,28,29]}],"sources":[{"fileName":"dialog.ts","line":95,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L95"}]},{"id":16,"name":"OpenDialogOptions","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Options for the open dialog."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":19,"name":"defaultPath","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Initial directory or file path."}]},"sources":[{"fileName":"dialog.ts","line":62,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L62"}],"type":{"type":"intrinsic","name":"string"}},{"id":21,"name":"directory","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the dialog is a directory selection or not."}]},"sources":[{"fileName":"dialog.ts","line":66,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L66"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":18,"name":"filters","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The filters of the dialog."}]},"sources":[{"fileName":"dialog.ts","line":60,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L60"}],"type":{"type":"array","elementType":{"type":"reference","id":13,"name":"DialogFilter"}}},{"id":20,"name":"multiple","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the dialog allows multiple selection or not."}]},"sources":[{"fileName":"dialog.ts","line":64,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L64"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":22,"name":"recursive","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"If "},{"kind":"code","text":"`directory`"},{"kind":"text","text":" is true, indicates that it will be read recursively later.\nDefines whether subdirectories will be allowed on the scope or not."}]},"sources":[{"fileName":"dialog.ts","line":71,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L71"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":17,"name":"title","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The title of the dialog window."}]},"sources":[{"fileName":"dialog.ts","line":58,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L58"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[19,21,18,20,22,17]}],"sources":[{"fileName":"dialog.ts","line":56,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L56"}]},{"id":23,"name":"SaveDialogOptions","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Options for the save dialog."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":26,"name":"defaultPath","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Initial directory or file path.\nIf it's a directory path, the dialog interface will change to that folder.\nIf it's not an existing directory, the file name will be set to the dialog's file name input and the dialog will be set to the parent folder."}]},"sources":[{"fileName":"dialog.ts","line":89,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L89"}],"type":{"type":"intrinsic","name":"string"}},{"id":25,"name":"filters","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The filters of the dialog."}]},"sources":[{"fileName":"dialog.ts","line":83,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L83"}],"type":{"type":"array","elementType":{"type":"reference","id":13,"name":"DialogFilter"}}},{"id":24,"name":"title","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The title of the dialog window."}]},"sources":[{"fileName":"dialog.ts","line":81,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L81"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[26,25,24]}],"sources":[{"fileName":"dialog.ts","line":79,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L79"}]},{"id":54,"name":"ask","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"dialog.ts","line":257,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L257"}],"signatures":[{"id":55,"name":"ask","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Shows a question dialog with "},{"kind":"code","text":"`Yes`"},{"kind":"text","text":" and "},{"kind":"code","text":"`No`"},{"kind":"text","text":" buttons."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { ask } from '@tauri-apps/api/dialog';\nconst yes = await ask('Are you sure?', 'Tauri');\nconst yes2 = await ask('This action cannot be reverted. Are you sure?', { title: 'Tauri', type: 'warning' });\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a boolean indicating whether "},{"kind":"code","text":"`Yes`"},{"kind":"text","text":" was clicked or not."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":56,"name":"message","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The message to show."}]},"type":{"type":"intrinsic","name":"string"}},{"id":57,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The dialog's options. If a string, it represents the dialog title."}]},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","id":31,"name":"ConfirmDialogOptions"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":58,"name":"confirm","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"dialog.ts","line":293,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L293"}],"signatures":[{"id":59,"name":"confirm","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Shows a question dialog with "},{"kind":"code","text":"`Ok`"},{"kind":"text","text":" and "},{"kind":"code","text":"`Cancel`"},{"kind":"text","text":" buttons."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { confirm } from '@tauri-apps/api/dialog';\nconst confirmed = await confirm('Are you sure?', 'Tauri');\nconst confirmed2 = await confirm('This action cannot be reverted. Are you sure?', { title: 'Tauri', type: 'warning' });\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a boolean indicating whether "},{"kind":"code","text":"`Ok`"},{"kind":"text","text":" was clicked or not."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":60,"name":"message","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The message to show."}]},"type":{"type":"intrinsic","name":"string"}},{"id":61,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The dialog's options. If a string, it represents the dialog title."}]},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","id":31,"name":"ConfirmDialogOptions"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":50,"name":"message","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"dialog.ts","line":224,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L224"}],"signatures":[{"id":51,"name":"message","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Shows a message dialog with an "},{"kind":"code","text":"`Ok`"},{"kind":"text","text":" button."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { message } from '@tauri-apps/api/dialog';\nawait message('Tauri is awesome', 'Tauri');\nawait message('File not found', { title: 'Tauri', type: 'error' });\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":52,"name":"message","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The message to show."}]},"type":{"type":"intrinsic","name":"string"}},{"id":53,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The dialog's options. If a string, it represents the dialog title."}]},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","id":27,"name":"MessageDialogOptions"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":36,"name":"open","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"dialog.ts","line":144,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L144"},{"fileName":"dialog.ts","line":147,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L147"},{"fileName":"dialog.ts","line":150,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L150"},{"fileName":"dialog.ts","line":153,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L153"}],"signatures":[{"id":37,"name":"open","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Open a file/directory selection dialog.\n\nThe selected paths are added to the filesystem and asset protocol allowlist scopes.\nWhen security is more important than the easy of use of this API,\nprefer writing a dedicated command instead.\n\nNote that the allowlist scope change is not persisted, so the values are cleared when the application is restarted.\nYou can save it to the filesystem using [tauri-plugin-persisted-scope](https://github.com/tauri-apps/tauri-plugin-persisted-scope)."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { open } from '@tauri-apps/api/dialog';\n// Open a selection dialog for image files\nconst selected = await open({\n multiple: true,\n filters: [{\n name: 'Image',\n extensions: ['png', 'jpeg']\n }]\n});\n```"},{"kind":"text","text":"\nNote that the "},{"kind":"code","text":"`open`"},{"kind":"text","text":" function returns a conditional type depending on the "},{"kind":"code","text":"`multiple`"},{"kind":"text","text":" option:\n- false (default) -> "},{"kind":"code","text":"`Promise`"},{"kind":"text","text":"\n- true -> "},{"kind":"code","text":"`Promise`"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to the selected path(s)"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":38,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"intersection","types":[{"type":"reference","id":16,"name":"OpenDialogOptions"},{"type":"reflection","declaration":{"id":39,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"children":[{"id":40,"name":"multiple","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"dialog.ts","line":145,"character":34,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L145"}],"type":{"type":"literal","value":false}}],"groups":[{"title":"Properties","children":[40]}],"sources":[{"fileName":"dialog.ts","line":145,"character":32,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L145"}]}}]}}],"type":{"type":"reference","typeArguments":[{"type":"union","types":[{"type":"literal","value":null},{"type":"intrinsic","name":"string"}]}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}},{"id":41,"name":"open","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":42,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"intersection","types":[{"type":"reference","id":16,"name":"OpenDialogOptions"},{"type":"reflection","declaration":{"id":43,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"children":[{"id":44,"name":"multiple","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"dialog.ts","line":148,"character":34,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L148"}],"type":{"type":"literal","value":true}}],"groups":[{"title":"Properties","children":[44]}],"sources":[{"fileName":"dialog.ts","line":148,"character":32,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L148"}]}}]}}],"type":{"type":"reference","typeArguments":[{"type":"union","types":[{"type":"literal","value":null},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}]}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}},{"id":45,"name":"open","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":46,"name":"options","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":16,"name":"OpenDialogOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"union","types":[{"type":"literal","value":null},{"type":"array","elementType":{"type":"intrinsic","name":"string"}},{"type":"intrinsic","name":"string"}]}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":47,"name":"save","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"dialog.ts","line":193,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L193"}],"signatures":[{"id":48,"name":"save","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Open a file/directory save dialog.\n\nThe selected path is added to the filesystem and asset protocol allowlist scopes.\nWhen security is more important than the easy of use of this API,\nprefer writing a dedicated command instead.\n\nNote that the allowlist scope change is not persisted, so the values are cleared when the application is restarted.\nYou can save it to the filesystem using [tauri-plugin-persisted-scope](https://github.com/tauri-apps/tauri-plugin-persisted-scope)."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { save } from '@tauri-apps/api/dialog';\nconst filePath = await save({\n filters: [{\n name: 'Image',\n extensions: ['png', 'jpeg']\n }]\n});\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to the selected path."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":49,"name":"options","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":23,"name":"SaveDialogOptions"},"defaultValue":"{}"}],"type":{"type":"reference","typeArguments":[{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"literal","value":null}]}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Interfaces","children":[31,13,27,16,23]},{"title":"Functions","children":[54,58,50,36,47]}],"sources":[{"fileName":"dialog.ts","line":31,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/dialog.ts#L31"}]},{"id":62,"name":"event","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"The event system allows you to emit events to the backend and listen to events from it.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.event`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":"."}]},"children":[{"id":64,"name":"TauriEvent","kind":8,"kindString":"Enumeration","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"children":[{"id":78,"name":"CHECK_UPDATE","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":34,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L34"}],"type":{"type":"literal","value":"tauri://update"}},{"id":82,"name":"DOWNLOAD_PROGRESS","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":38,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L38"}],"type":{"type":"literal","value":"tauri://update-download-progress"}},{"id":80,"name":"INSTALL_UPDATE","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":36,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L36"}],"type":{"type":"literal","value":"tauri://update-install"}},{"id":77,"name":"MENU","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":33,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L33"}],"type":{"type":"literal","value":"tauri://menu"}},{"id":81,"name":"STATUS_UPDATE","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":37,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L37"}],"type":{"type":"literal","value":"tauri://update-status"}},{"id":79,"name":"UPDATE_AVAILABLE","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":35,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L35"}],"type":{"type":"literal","value":"tauri://update-available"}},{"id":71,"name":"WINDOW_BLUR","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":27,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L27"}],"type":{"type":"literal","value":"tauri://blur"}},{"id":67,"name":"WINDOW_CLOSE_REQUESTED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":23,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L23"}],"type":{"type":"literal","value":"tauri://close-requested"}},{"id":68,"name":"WINDOW_CREATED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":24,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L24"}],"type":{"type":"literal","value":"tauri://window-created"}},{"id":69,"name":"WINDOW_DESTROYED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":25,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L25"}],"type":{"type":"literal","value":"tauri://destroyed"}},{"id":74,"name":"WINDOW_FILE_DROP","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":30,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L30"}],"type":{"type":"literal","value":"tauri://file-drop"}},{"id":76,"name":"WINDOW_FILE_DROP_CANCELLED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":32,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L32"}],"type":{"type":"literal","value":"tauri://file-drop-cancelled"}},{"id":75,"name":"WINDOW_FILE_DROP_HOVER","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":31,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L31"}],"type":{"type":"literal","value":"tauri://file-drop-hover"}},{"id":70,"name":"WINDOW_FOCUS","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":26,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L26"}],"type":{"type":"literal","value":"tauri://focus"}},{"id":66,"name":"WINDOW_MOVED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":22,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L22"}],"type":{"type":"literal","value":"tauri://move"}},{"id":65,"name":"WINDOW_RESIZED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":21,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L21"}],"type":{"type":"literal","value":"tauri://resize"}},{"id":72,"name":"WINDOW_SCALE_FACTOR_CHANGED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":28,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L28"}],"type":{"type":"literal","value":"tauri://scale-change"}},{"id":73,"name":"WINDOW_THEME_CHANGED","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"event.ts","line":29,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L29"}],"type":{"type":"literal","value":"tauri://theme-changed"}}],"groups":[{"title":"Enumeration Members","children":[78,82,80,77,81,79,71,67,68,69,74,76,75,70,66,65,72,73]}],"sources":[{"fileName":"event.ts","line":20,"character":12,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L20"}]},{"id":1075,"name":"Event","kind":256,"kindString":"Interface","flags":{},"children":[{"id":1076,"name":"event","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name"}]},"sources":[{"fileName":"helpers/event.ts","line":12,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/helpers/event.ts#L12"}],"type":{"type":"reference","id":63,"name":"EventName"}},{"id":1078,"name":"id","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Event identifier used to unlisten"}]},"sources":[{"fileName":"helpers/event.ts","line":16,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/helpers/event.ts#L16"}],"type":{"type":"intrinsic","name":"number"}},{"id":1079,"name":"payload","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Event payload"}]},"sources":[{"fileName":"helpers/event.ts","line":18,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/helpers/event.ts#L18"}],"type":{"type":"reference","id":1080,"name":"T"}},{"id":1077,"name":"windowLabel","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The label of the window that emitted this event."}]},"sources":[{"fileName":"helpers/event.ts","line":14,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/helpers/event.ts#L14"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[1076,1078,1079,1077]}],"sources":[{"fileName":"helpers/event.ts","line":10,"character":17,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/helpers/event.ts#L10"}],"typeParameters":[{"id":1080,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}]},{"id":1081,"name":"EventCallback","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"helpers/event.ts","line":21,"character":12,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/helpers/event.ts#L21"}],"typeParameters":[{"id":1085,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"type":{"type":"reflection","declaration":{"id":1082,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"helpers/event.ts","line":21,"character":31,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/helpers/event.ts#L21"}],"signatures":[{"id":1083,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":1084,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1075,"typeArguments":[{"type":"reference","id":1085,"name":"T"}],"name":"Event"}}],"type":{"type":"intrinsic","name":"void"}}]}}},{"id":63,"name":"EventName","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"event.ts","line":15,"character":12,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L15"}],"type":{"type":"union","types":[{"type":"template-literal","head":"","tail":[[{"type":"reference","id":64,"name":"TauriEvent"},""]]},{"type":"intersection","types":[{"type":"intrinsic","name":"string"},{"type":"reference","typeArguments":[{"type":"intrinsic","name":"never"},{"type":"intrinsic","name":"never"}],"name":"Record","qualifiedName":"Record","package":"typescript"}]}]}},{"id":1086,"name":"UnlistenFn","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"helpers/event.ts","line":23,"character":12,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/helpers/event.ts#L23"}],"type":{"type":"reflection","declaration":{"id":1087,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"helpers/event.ts","line":23,"character":25,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/helpers/event.ts#L23"}],"signatures":[{"id":1088,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"intrinsic","name":"void"}}]}}},{"id":93,"name":"emit","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"event.ts","line":112,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L112"}],"signatures":[{"id":94,"name":"emit","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Emits an event to the backend."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { emit } from '@tauri-apps/api/event';\nawait emit('frontend-loaded', { loggedIn: true, token: 'authToken' });\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":95,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name. Must include only alphanumeric characters, "},{"kind":"code","text":"`-`"},{"kind":"text","text":", "},{"kind":"code","text":"`/`"},{"kind":"text","text":", "},{"kind":"code","text":"`:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`_`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":96,"name":"payload","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"intrinsic","name":"unknown"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":83,"name":"listen","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"event.ts","line":62,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L62"}],"signatures":[{"id":84,"name":"listen","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to an event from the backend."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { listen } from '@tauri-apps/api/event';\nconst unlisten = await listen('error', (event) => {\n console.log(`Got error in window ${event.windowLabel}, payload: ${event.payload}`);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"typeParameter":[{"id":85,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":86,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name. Must include only alphanumeric characters, "},{"kind":"code","text":"`-`"},{"kind":"text","text":", "},{"kind":"code","text":"`/`"},{"kind":"text","text":", "},{"kind":"code","text":"`:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`_`"},{"kind":"text","text":"."}]},"type":{"type":"reference","id":63,"name":"EventName"}},{"id":87,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event handler callback."}]},"type":{"type":"reference","id":1081,"typeArguments":[{"type":"reference","id":85,"name":"T"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1086,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":88,"name":"once","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"event.ts","line":93,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L93"}],"signatures":[{"id":89,"name":"once","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to an one-off event from the backend."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { once } from '@tauri-apps/api/event';\ninterface LoadedPayload {\n loggedIn: boolean,\n token: string\n}\nconst unlisten = await once('loaded', (event) => {\n console.log(`App is loaded, loggedIn: ${event.payload.loggedIn}, token: ${event.payload.token}`);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"typeParameter":[{"id":90,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":91,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name. Must include only alphanumeric characters, "},{"kind":"code","text":"`-`"},{"kind":"text","text":", "},{"kind":"code","text":"`/`"},{"kind":"text","text":", "},{"kind":"code","text":"`:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`_`"},{"kind":"text","text":"."}]},"type":{"type":"reference","id":63,"name":"EventName"}},{"id":92,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1081,"typeArguments":[{"type":"reference","id":90,"name":"T"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1086,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Enumerations","children":[64]},{"title":"Interfaces","children":[1075]},{"title":"Type Aliases","children":[1081,63,1086]},{"title":"Functions","children":[93,83,88]}],"sources":[{"fileName":"event.ts","line":12,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/event.ts#L12"}]},{"id":97,"name":"http","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Access the HTTP client written in Rust.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.http`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be allowlisted on "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"http\": {\n \"all\": true, // enable all http APIs\n \"request\": true // enable HTTP request API\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security.\n\n## Security\n\nThis API has a scope configuration that forces you to restrict the URLs and paths that can be accessed using glob patterns.\n\nFor instance, this scope configuration only allows making HTTP requests to the GitHub API for the "},{"kind":"code","text":"`tauri-apps`"},{"kind":"text","text":" organization:\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"http\": {\n \"scope\": [\"https://api.github.com/repos/tauri-apps/*\"]\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nTrying to execute any API with a URL not configured on the scope results in a promise rejection due to denied access."}]},"children":[{"id":193,"name":"ResponseType","kind":8,"kindString":"Enumeration","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":196,"name":"Binary","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"http.ts","line":74,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L74"}],"type":{"type":"literal","value":3}},{"id":194,"name":"JSON","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"http.ts","line":72,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L72"}],"type":{"type":"literal","value":1}},{"id":195,"name":"Text","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"http.ts","line":73,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L73"}],"type":{"type":"literal","value":2}}],"groups":[{"title":"Enumeration Members","children":[196,194,195]}],"sources":[{"fileName":"http.ts","line":71,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L71"}]},{"id":124,"name":"Body","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"The body object to be used on POST and PUT requests."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":142,"name":"payload","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":95,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L95"}],"type":{"type":"intrinsic","name":"unknown"}},{"id":141,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":94,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L94"}],"type":{"type":"intrinsic","name":"string"}},{"id":134,"name":"bytes","kind":2048,"kindString":"Method","flags":{"isStatic":true},"sources":[{"fileName":"http.ts","line":217,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L217"}],"signatures":[{"id":135,"name":"bytes","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a new byte array body."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Body } from \"@tauri-apps/api/http\"\nBody.bytes(new Uint8Array([1, 2, 3]));\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The body object ready to be used on the POST and PUT requests."}]}]},"parameters":[{"id":136,"name":"bytes","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The body byte array."}]},"type":{"type":"union","types":[{"type":"reference","typeArguments":[{"type":"intrinsic","name":"number"}],"name":"Iterable","qualifiedName":"Iterable","package":"typescript"},{"type":"reference","name":"ArrayBuffer","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer","qualifiedName":"ArrayBuffer","package":"typescript"},{"type":"reference","typeArguments":[{"type":"intrinsic","name":"number"}],"name":"ArrayLike","qualifiedName":"ArrayLike","package":"typescript"}]}}],"type":{"type":"reference","id":124,"name":"Body"}}]},{"id":125,"name":"form","kind":2048,"kindString":"Method","flags":{"isStatic":true},"sources":[{"fileName":"http.ts","line":134,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L134"}],"signatures":[{"id":126,"name":"form","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a new form data body. The form data is an object where each key is the entry name,\nand the value is either a string or a file object.\n\nBy default it sets the "},{"kind":"code","text":"`application/x-www-form-urlencoded`"},{"kind":"text","text":" Content-Type header,\nbut you can set it to "},{"kind":"code","text":"`multipart/form-data`"},{"kind":"text","text":" if the Cargo feature "},{"kind":"code","text":"`http-multipart`"},{"kind":"text","text":" is enabled.\n\nNote that a file path must be allowed in the "},{"kind":"code","text":"`fs`"},{"kind":"text","text":" allowlist scope."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Body } from \"@tauri-apps/api/http\"\nconst body = Body.form({\n key: 'value',\n image: {\n file: '/path/to/file', // either a path or an array buffer of the file contents\n mime: 'image/jpeg', // optional\n fileName: 'image.jpg' // optional\n }\n});\n\n// alternatively, use a FormData:\nconst form = new FormData();\nform.append('key', 'value');\nform.append('image', file, 'image.png');\nconst formBody = Body.form(form);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The body object ready to be used on the POST and PUT requests."}]}]},"parameters":[{"id":127,"name":"data","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The body data."}]},"type":{"type":"union","types":[{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"reference","id":104,"name":"Part"}],"name":"Record","qualifiedName":"Record","package":"typescript"},{"type":"reference","name":"FormData","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/API/FormData","qualifiedName":"FormData","package":"typescript"}]}}],"type":{"type":"reference","id":124,"name":"Body"}}]},{"id":128,"name":"json","kind":2048,"kindString":"Method","flags":{"isStatic":true},"sources":[{"fileName":"http.ts","line":185,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L185"}],"signatures":[{"id":129,"name":"json","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a new JSON body."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Body } from \"@tauri-apps/api/http\"\nBody.json({\n registered: true,\n name: 'tauri'\n});\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The body object ready to be used on the POST and PUT requests."}]}]},"parameters":[{"id":130,"name":"data","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The body JSON object."}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"any"},{"type":"intrinsic","name":"any"}],"name":"Record","qualifiedName":"Record","package":"typescript"}}],"type":{"type":"reference","id":124,"name":"Body"}}]},{"id":131,"name":"text","kind":2048,"kindString":"Method","flags":{"isStatic":true},"sources":[{"fileName":"http.ts","line":201,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L201"}],"signatures":[{"id":132,"name":"text","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a new UTF-8 string body."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Body } from \"@tauri-apps/api/http\"\nBody.text('The body content as a string');\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The body object ready to be used on the POST and PUT requests."}]}]},"parameters":[{"id":133,"name":"value","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The body string."}]},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","id":124,"name":"Body"}}]}],"groups":[{"title":"Properties","children":[142,141]},{"title":"Methods","children":[134,125,128,131]}],"sources":[{"fileName":"http.ts","line":93,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L93"}]},{"id":143,"name":"Client","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":147,"name":"id","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":303,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L303"}],"type":{"type":"intrinsic","name":"number"}},{"id":176,"name":"delete","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"http.ts","line":484,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L484"}],"signatures":[{"id":177,"name":"delete","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Makes a DELETE request."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient } from '@tauri-apps/api/http';\nconst client = await getClient();\nconst response = await client.delete('http://localhost:3003/users/1');\n```"}]}]},"typeParameter":[{"id":178,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":179,"name":"url","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":180,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":114,"name":"RequestOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":181,"typeArguments":[{"type":"reference","id":178,"name":"T"}],"name":"Response"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":148,"name":"drop","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"http.ts","line":318,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L318"}],"signatures":[{"id":149,"name":"drop","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Drops the client instance."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient } from '@tauri-apps/api/http';\nconst client = await getClient();\nawait client.drop();\n```"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":154,"name":"get","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"http.ts","line":389,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L389"}],"signatures":[{"id":155,"name":"get","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Makes a GET request."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient, ResponseType } from '@tauri-apps/api/http';\nconst client = await getClient();\nconst response = await client.get('http://localhost:3003/users', {\n timeout: 30,\n // the expected response type\n responseType: ResponseType.JSON\n});\n```"}]}]},"typeParameter":[{"id":156,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":157,"name":"url","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":158,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":114,"name":"RequestOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":181,"typeArguments":[{"type":"reference","id":156,"name":"T"}],"name":"Response"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":171,"name":"patch","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"http.ts","line":467,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L467"}],"signatures":[{"id":172,"name":"patch","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Makes a PATCH request."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient, Body } from '@tauri-apps/api/http';\nconst client = await getClient();\nconst response = await client.patch('http://localhost:3003/users/1', {\n body: Body.json({ email: 'contact@tauri.app' })\n});\n```"}]}]},"typeParameter":[{"id":173,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":174,"name":"url","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":175,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":114,"name":"RequestOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":181,"typeArguments":[{"type":"reference","id":173,"name":"T"}],"name":"Response"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":159,"name":"post","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"http.ts","line":413,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L413"}],"signatures":[{"id":160,"name":"post","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Makes a POST request."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient, Body, ResponseType } from '@tauri-apps/api/http';\nconst client = await getClient();\nconst response = await client.post('http://localhost:3003/users', {\n body: Body.json({\n name: 'tauri',\n password: 'awesome'\n }),\n // in this case the server returns a simple string\n responseType: ResponseType.Text,\n});\n```"}]}]},"typeParameter":[{"id":161,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":162,"name":"url","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":163,"name":"body","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":124,"name":"Body"}},{"id":164,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":114,"name":"RequestOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":181,"typeArguments":[{"type":"reference","id":161,"name":"T"}],"name":"Response"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":165,"name":"put","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"http.ts","line":443,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L443"}],"signatures":[{"id":166,"name":"put","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Makes a PUT request."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient, Body } from '@tauri-apps/api/http';\nconst client = await getClient();\nconst response = await client.put('http://localhost:3003/users/1', {\n body: Body.form({\n file: {\n file: '/home/tauri/avatar.png',\n mime: 'image/png',\n fileName: 'avatar.png'\n }\n })\n});\n```"}]}]},"typeParameter":[{"id":167,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":168,"name":"url","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":169,"name":"body","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":124,"name":"Body"}},{"id":170,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":114,"name":"RequestOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":181,"typeArguments":[{"type":"reference","id":167,"name":"T"}],"name":"Response"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":150,"name":"request","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"http.ts","line":340,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L340"}],"signatures":[{"id":151,"name":"request","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Makes an HTTP request."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient } from '@tauri-apps/api/http';\nconst client = await getClient();\nconst response = await client.request({\n method: 'GET',\n url: 'http://localhost:3003/users',\n});\n```"}]}]},"typeParameter":[{"id":152,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":153,"name":"options","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":106,"name":"HttpOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":181,"typeArguments":[{"type":"reference","id":152,"name":"T"}],"name":"Response"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Properties","children":[147]},{"title":"Methods","children":[176,148,154,171,159,165,150]}],"sources":[{"fileName":"http.ts","line":302,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L302"}]},{"id":181,"name":"Response","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"Response object."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":191,"name":"data","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The response data."}]},"sources":[{"fileName":"http.ts","line":286,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L286"}],"type":{"type":"reference","name":"T"}},{"id":189,"name":"headers","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The response headers."}]},"sources":[{"fileName":"http.ts","line":282,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L282"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"string"}],"name":"Record","qualifiedName":"Record","package":"typescript"}},{"id":188,"name":"ok","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"A boolean indicating whether the response was successful (status in the range 200–299) or not."}]},"sources":[{"fileName":"http.ts","line":280,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L280"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":190,"name":"rawHeaders","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The response raw headers."}]},"sources":[{"fileName":"http.ts","line":284,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L284"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}],"name":"Record","qualifiedName":"Record","package":"typescript"}},{"id":187,"name":"status","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The response status code."}]},"sources":[{"fileName":"http.ts","line":278,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L278"}],"type":{"type":"intrinsic","name":"number"}},{"id":186,"name":"url","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The request URL."}]},"sources":[{"fileName":"http.ts","line":276,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L276"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[191,189,188,190,187,186]}],"sources":[{"fileName":"http.ts","line":274,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L274"}],"typeParameters":[{"id":192,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}]},{"id":101,"name":"ClientOptions","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":103,"name":"connectTimeout","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":65,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L65"}],"type":{"type":"union","types":[{"type":"intrinsic","name":"number"},{"type":"reference","id":98,"name":"Duration"}]}},{"id":102,"name":"maxRedirections","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Defines the maximum number of redirects the client should follow.\nIf set to 0, no redirects will be followed."}]},"sources":[{"fileName":"http.ts","line":64,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L64"}],"type":{"type":"intrinsic","name":"number"}}],"groups":[{"title":"Properties","children":[103,102]}],"sources":[{"fileName":"http.ts","line":59,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L59"}]},{"id":98,"name":"Duration","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":100,"name":"nanos","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":53,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L53"}],"type":{"type":"intrinsic","name":"number"}},{"id":99,"name":"secs","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":52,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L52"}],"type":{"type":"intrinsic","name":"number"}}],"groups":[{"title":"Properties","children":[100,99]}],"sources":[{"fileName":"http.ts","line":51,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L51"}]},{"id":197,"name":"FilePart","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":198,"name":"file","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":81,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L81"}],"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","id":201,"name":"T"}]}},{"id":200,"name":"fileName","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":83,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L83"}],"type":{"type":"intrinsic","name":"string"}},{"id":199,"name":"mime","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":82,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L82"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[198,200,199]}],"sources":[{"fileName":"http.ts","line":80,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L80"}],"typeParameters":[{"id":201,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}]},{"id":106,"name":"HttpOptions","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Options object sent to the backend."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":111,"name":"body","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":250,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L250"}],"type":{"type":"reference","id":124,"name":"Body"}},{"id":109,"name":"headers","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":248,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L248"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"any"}],"name":"Record","qualifiedName":"Record","package":"typescript"}},{"id":107,"name":"method","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":246,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L246"}],"type":{"type":"reference","id":105,"name":"HttpVerb"}},{"id":110,"name":"query","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":249,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L249"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"any"}],"name":"Record","qualifiedName":"Record","package":"typescript"}},{"id":113,"name":"responseType","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":252,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L252"}],"type":{"type":"reference","id":193,"name":"ResponseType"}},{"id":112,"name":"timeout","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"http.ts","line":251,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L251"}],"type":{"type":"union","types":[{"type":"intrinsic","name":"number"},{"type":"reference","id":98,"name":"Duration"}]}},{"id":108,"name":"url","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"http.ts","line":247,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L247"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[111,109,107,110,113,112,108]}],"sources":[{"fileName":"http.ts","line":245,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L245"}]},{"id":115,"name":"FetchOptions","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[{"kind":"text","text":"Options for the "},{"kind":"code","text":"`fetch`"},{"kind":"text","text":" API."}]},"sources":[{"fileName":"http.ts","line":258,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L258"}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":106,"name":"HttpOptions"},{"type":"literal","value":"url"}],"name":"Omit","qualifiedName":"Omit","package":"typescript"}},{"id":105,"name":"HttpVerb","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[{"kind":"text","text":"The request HTTP verb."}]},"sources":[{"fileName":"http.ts","line":229,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L229"}],"type":{"type":"union","types":[{"type":"literal","value":"GET"},{"type":"literal","value":"POST"},{"type":"literal","value":"PUT"},{"type":"literal","value":"DELETE"},{"type":"literal","value":"PATCH"},{"type":"literal","value":"HEAD"},{"type":"literal","value":"OPTIONS"},{"type":"literal","value":"CONNECT"},{"type":"literal","value":"TRACE"}]}},{"id":104,"name":"Part","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"http.ts","line":86,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L86"}],"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","name":"Uint8Array","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array","qualifiedName":"Uint8Array","package":"typescript"},{"type":"reference","id":197,"typeArguments":[{"type":"reference","name":"Uint8Array","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array","qualifiedName":"Uint8Array","package":"typescript"}],"name":"FilePart"}]}},{"id":114,"name":"RequestOptions","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[{"kind":"text","text":"Request options."}]},"sources":[{"fileName":"http.ts","line":256,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L256"}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":106,"name":"HttpOptions"},{"type":"union","types":[{"type":"literal","value":"method"},{"type":"literal","value":"url"}]}],"name":"Omit","qualifiedName":"Omit","package":"typescript"}},{"id":119,"name":"fetch","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"http.ts","line":531,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L531"}],"signatures":[{"id":120,"name":"fetch","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Perform an HTTP request using the default client."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { fetch } from '@tauri-apps/api/http';\nconst response = await fetch('http://localhost:3003/users/2', {\n method: 'GET',\n timeout: 30,\n});\n```"}]}]},"typeParameter":[{"id":121,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":122,"name":"url","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":123,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":115,"name":"FetchOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":181,"typeArguments":[{"type":"reference","id":121,"name":"T"}],"name":"Response"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":116,"name":"getClient","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"http.ts","line":507,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L507"}],"signatures":[{"id":117,"name":"getClient","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a new client using the specified options."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { getClient } from '@tauri-apps/api/http';\nconst client = await getClient();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to the client instance."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":118,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Client configuration."}]},"type":{"type":"reference","id":101,"name":"ClientOptions"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":143,"name":"Client"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Enumerations","children":[193]},{"title":"Classes","children":[124,143,181]},{"title":"Interfaces","children":[101,98,197,106]},{"title":"Type Aliases","children":[115,105,104,114]},{"title":"Functions","children":[119,116]}],"sources":[{"fileName":"http.ts","line":46,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/http.ts#L46"}]},{"id":202,"name":"mocks","kind":2,"kindString":"Module","flags":{},"children":[{"id":214,"name":"clearMocks","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"mocks.ts","line":171,"character":16,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/mocks.ts#L171"}],"signatures":[{"id":215,"name":"clearMocks","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Clears mocked functions/data injected by the other functions in this module.\nWhen using a test runner that doesn't provide a fresh window object for each test, calling this function will reset tauri specific properties.\n\n# Example\n\n"},{"kind":"code","text":"```js\nimport { mockWindows, clearMocks } from \"@tauri-apps/api/mocks\"\n\nafterEach(() => {\n clearMocks()\n})\n\ntest(\"mocked windows\", () => {\n mockWindows(\"main\", \"second\", \"third\");\n\n expect(window).toHaveProperty(\"__TAURI_METADATA__\")\n})\n\ntest(\"no mocked windows\", () => {\n expect(window).not.toHaveProperty(\"__TAURI_METADATA__\")\n})\n```"}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"intrinsic","name":"void"}}]},{"id":203,"name":"mockIPC","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"mocks.ts","line":65,"character":16,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/mocks.ts#L65"}],"signatures":[{"id":204,"name":"mockIPC","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Intercepts all IPC requests with the given mock handler.\n\nThis function can be used when testing tauri frontend applications or when running the frontend in a Node.js context during static site generation.\n\n# Examples\n\nTesting setup using vitest:\n"},{"kind":"code","text":"```js\nimport { mockIPC, clearMocks } from \"@tauri-apps/api/mocks\"\nimport { invoke } from \"@tauri-apps/api/tauri\"\n\nafterEach(() => {\n clearMocks()\n})\n\ntest(\"mocked command\", () => {\n mockIPC((cmd, args) => {\n switch (cmd) {\n case \"add\":\n return (args.a as number) + (args.b as number);\n default:\n break;\n }\n });\n\n expect(invoke('add', { a: 12, b: 15 })).resolves.toBe(27);\n})\n```"},{"kind":"text","text":"\n\nThe callback function can also return a Promise:\n"},{"kind":"code","text":"```js\nimport { mockIPC, clearMocks } from \"@tauri-apps/api/mocks\"\nimport { invoke } from \"@tauri-apps/api/tauri\"\n\nafterEach(() => {\n clearMocks()\n})\n\ntest(\"mocked command\", () => {\n mockIPC((cmd, args) => {\n if(cmd === \"get_data\") {\n return fetch(\"https://example.com/data.json\")\n .then((response) => response.json())\n }\n });\n\n expect(invoke('get_data')).resolves.toBe({ foo: 'bar' });\n})\n```"}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":205,"name":"cb","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":206,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"mocks.ts","line":66,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/mocks.ts#L66"}],"signatures":[{"id":207,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":208,"name":"cmd","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":209,"name":"args","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"unknown"}],"name":"Record","qualifiedName":"Record","package":"typescript"}}],"type":{"type":"intrinsic","name":"any"}}]}}}],"type":{"type":"intrinsic","name":"void"}}]},{"id":210,"name":"mockWindows","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"mocks.ts","line":135,"character":16,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/mocks.ts#L135"}],"signatures":[{"id":211,"name":"mockWindows","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Mocks one or many window labels.\nIn non-tauri context it is required to call this function *before* using the "},{"kind":"code","text":"`@tauri-apps/api/window`"},{"kind":"text","text":" module.\n\nThis function only mocks the *presence* of windows,\nwindow properties (e.g. width and height) can be mocked like regular IPC calls using the "},{"kind":"code","text":"`mockIPC`"},{"kind":"text","text":" function.\n\n# Examples\n\n"},{"kind":"code","text":"```js\nimport { mockWindows } from \"@tauri-apps/api/mocks\";\nimport { getCurrent } from \"@tauri-apps/api/window\";\n\nmockWindows(\"main\", \"second\", \"third\");\n\nconst win = getCurrent();\n\nwin.label // \"main\"\n```"},{"kind":"text","text":"\n\n"},{"kind":"code","text":"```js\nimport { mockWindows } from \"@tauri-apps/api/mocks\";\n\nmockWindows(\"main\", \"second\", \"third\");\n\nmockIPC((cmd, args) => {\n if (cmd === \"tauri\") {\n if (\n args?.__tauriModule === \"Window\" &&\n args?.message?.cmd === \"manage\" &&\n args?.message?.data?.cmd?.type === \"close\"\n ) {\n console.log('closing window!');\n }\n }\n});\n\nconst { getCurrent } = await import(\"@tauri-apps/api/window\");\n\nconst win = getCurrent();\nawait win.close(); // this will cause the mocked IPC handler to log to the console.\n```"}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":212,"name":"current","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Label of window this JavaScript context is running in."}]},"type":{"type":"intrinsic","name":"string"}},{"id":213,"name":"additionalWindows","kind":32768,"kindString":"Parameter","flags":{"isRest":true},"comment":{"summary":[{"kind":"text","text":"Label of additional windows the app has."}]},"type":{"type":"array","elementType":{"type":"intrinsic","name":"string"}}}],"type":{"type":"intrinsic","name":"void"}}]}],"groups":[{"title":"Functions","children":[214,203,210]}],"sources":[{"fileName":"mocks.ts","line":5,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/mocks.ts#L5"}]},{"id":216,"name":"notification","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Send toast notifications (brief auto-expiring OS window element) to your user.\nCan also be used with the Notification Web API.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.notification`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be added to ["},{"kind":"code","text":"`tauri.allowlist.notification`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.notification) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"notification\": {\n \"all\": true // enable all notification APIs\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security."}]},"children":[{"id":217,"name":"Options","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Options to send a notification."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":219,"name":"body","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Optional notification body."}]},"sources":[{"fileName":"notification.ts","line":38,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/notification.ts#L38"}],"type":{"type":"intrinsic","name":"string"}},{"id":220,"name":"icon","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Optional notification icon."}]},"sources":[{"fileName":"notification.ts","line":40,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/notification.ts#L40"}],"type":{"type":"intrinsic","name":"string"}},{"id":218,"name":"title","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Notification title."}]},"sources":[{"fileName":"notification.ts","line":36,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/notification.ts#L36"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[219,220,218]}],"sources":[{"fileName":"notification.ts","line":34,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/notification.ts#L34"}]},{"id":221,"name":"Permission","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[{"kind":"text","text":"Possible permission values."}]},"sources":[{"fileName":"notification.ts","line":44,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/notification.ts#L44"}],"type":{"type":"union","types":[{"type":"literal","value":"granted"},{"type":"literal","value":"denied"},{"type":"literal","value":"default"}]}},{"id":227,"name":"isPermissionGranted","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"notification.ts","line":56,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/notification.ts#L56"}],"signatures":[{"id":228,"name":"isPermissionGranted","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Checks if the permission to send notifications is granted."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { isPermissionGranted } from '@tauri-apps/api/notification';\nconst permissionGranted = await isPermissionGranted();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":225,"name":"requestPermission","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"notification.ts","line":84,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/notification.ts#L84"}],"signatures":[{"id":226,"name":"requestPermission","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Requests the permission to send notifications."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { isPermissionGranted, requestPermission } from '@tauri-apps/api/notification';\nlet permissionGranted = await isPermissionGranted();\nif (!permissionGranted) {\n const permission = await requestPermission();\n permissionGranted = permission === 'granted';\n}\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to whether the user granted the permission or not."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":221,"name":"Permission"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":222,"name":"sendNotification","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"notification.ts","line":106,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/notification.ts#L106"}],"signatures":[{"id":223,"name":"sendNotification","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sends a notification to the user."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { isPermissionGranted, requestPermission, sendNotification } from '@tauri-apps/api/notification';\nlet permissionGranted = await isPermissionGranted();\nif (!permissionGranted) {\n const permission = await requestPermission();\n permissionGranted = permission === 'granted';\n}\nif (permissionGranted) {\n sendNotification('Tauri is awesome!');\n sendNotification({ title: 'TAURI', body: 'Tauri is awesome!' });\n}\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":224,"name":"options","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","id":217,"name":"Options"}]}}],"type":{"type":"intrinsic","name":"void"}}]}],"groups":[{"title":"Interfaces","children":[217]},{"title":"Type Aliases","children":[221]},{"title":"Functions","children":[227,225,222]}],"sources":[{"fileName":"notification.ts","line":27,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/notification.ts#L27"}]},{"id":229,"name":"os","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Provides operating system-related utility methods and properties.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.os`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be added to ["},{"kind":"code","text":"`tauri.allowlist.os`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.os) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"os\": {\n \"all\": true, // enable all Os APIs\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security."}]},"children":[{"id":243,"name":"Arch","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"os.ts","line":43,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/os.ts#L43"}],"type":{"type":"union","types":[{"type":"literal","value":"x86"},{"type":"literal","value":"x86_64"},{"type":"literal","value":"arm"},{"type":"literal","value":"aarch64"},{"type":"literal","value":"mips"},{"type":"literal","value":"mips64"},{"type":"literal","value":"powerpc"},{"type":"literal","value":"powerpc64"},{"type":"literal","value":"riscv64"},{"type":"literal","value":"s390x"},{"type":"literal","value":"sparc64"}]}},{"id":242,"name":"OsType","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"os.ts","line":41,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/os.ts#L41"}],"type":{"type":"union","types":[{"type":"literal","value":"Linux"},{"type":"literal","value":"Darwin"},{"type":"literal","value":"Windows_NT"}]}},{"id":241,"name":"Platform","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"os.ts","line":29,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/os.ts#L29"}],"type":{"type":"union","types":[{"type":"literal","value":"linux"},{"type":"literal","value":"darwin"},{"type":"literal","value":"ios"},{"type":"literal","value":"freebsd"},{"type":"literal","value":"dragonfly"},{"type":"literal","value":"netbsd"},{"type":"literal","value":"openbsd"},{"type":"literal","value":"solaris"},{"type":"literal","value":"android"},{"type":"literal","value":"win32"}]}},{"id":230,"name":"EOL","kind":32,"kindString":"Variable","flags":{"isConst":true},"comment":{"summary":[{"kind":"text","text":"The operating system-specific end-of-line marker.\n- "},{"kind":"code","text":"`\\n`"},{"kind":"text","text":" on POSIX\n- "},{"kind":"code","text":"`\\r\\n`"},{"kind":"text","text":" on Windows"}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"sources":[{"fileName":"os.ts","line":63,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/os.ts#L63"}],"type":{"type":"union","types":[{"type":"literal","value":"\n"},{"type":"literal","value":"\r\n"}]},"defaultValue":"..."},{"id":237,"name":"arch","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"os.ts","line":135,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/os.ts#L135"}],"signatures":[{"id":238,"name":"arch","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the operating system CPU architecture for which the tauri app was compiled.\nPossible values are "},{"kind":"code","text":"`'x86'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'x86_64'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'arm'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'aarch64'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'mips'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'mips64'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'powerpc'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'powerpc64'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'riscv64'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'s390x'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'sparc64'`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { arch } from '@tauri-apps/api/os';\nconst archName = await arch();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":243,"name":"Arch"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":231,"name":"platform","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"os.ts","line":77,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/os.ts#L77"}],"signatures":[{"id":232,"name":"platform","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns a string identifying the operating system platform.\nThe value is set at compile time. Possible values are "},{"kind":"code","text":"`'linux'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'darwin'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'ios'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'freebsd'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'dragonfly'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'netbsd'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'openbsd'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'solaris'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'android'`"},{"kind":"text","text":", "},{"kind":"code","text":"`'win32'`"}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { platform } from '@tauri-apps/api/os';\nconst platformName = await platform();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":241,"name":"Platform"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":239,"name":"tempdir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"os.ts","line":154,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/os.ts#L154"}],"signatures":[{"id":240,"name":"tempdir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the operating system's default directory for temporary files as a string."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { tempdir } from '@tauri-apps/api/os';\nconst tempdirPath = await tempdir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":235,"name":"type","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"os.ts","line":115,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/os.ts#L115"}],"signatures":[{"id":236,"name":"type","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns "},{"kind":"code","text":"`'Linux'`"},{"kind":"text","text":" on Linux, "},{"kind":"code","text":"`'Darwin'`"},{"kind":"text","text":" on macOS, and "},{"kind":"code","text":"`'Windows_NT'`"},{"kind":"text","text":" on Windows."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { type } from '@tauri-apps/api/os';\nconst osType = await type();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":242,"name":"OsType"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":233,"name":"version","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"os.ts","line":96,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/os.ts#L96"}],"signatures":[{"id":234,"name":"version","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns a string identifying the kernel version."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { version } from '@tauri-apps/api/os';\nconst osVersion = await version();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Type Aliases","children":[243,242,241]},{"title":"Variables","children":[230]},{"title":"Functions","children":[237,231,239,235,233]}],"sources":[{"fileName":"os.ts","line":26,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/os.ts#L26"}]},{"id":244,"name":"path","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"The path module provides utilities for working with file and directory paths.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.path`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be added to ["},{"kind":"code","text":"`tauri.allowlist.path`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.path) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"path\": {\n \"all\": true, // enable all Path APIs\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security."}]},"children":[{"id":245,"name":"BaseDirectory","kind":8,"kindString":"Enumeration","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"2.0.0"}]}]},"children":[{"id":261,"name":"AppCache","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":48,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L48"}],"type":{"type":"literal","value":16}},{"id":258,"name":"AppConfig","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":45,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L45"}],"type":{"type":"literal","value":13}},{"id":259,"name":"AppData","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":46,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L46"}],"type":{"type":"literal","value":14}},{"id":260,"name":"AppLocalData","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":47,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L47"}],"type":{"type":"literal","value":15}},{"id":262,"name":"AppLog","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":49,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L49"}],"type":{"type":"literal","value":17}},{"id":246,"name":"Audio","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":33,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L33"}],"type":{"type":"literal","value":1}},{"id":247,"name":"Cache","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":34,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L34"}],"type":{"type":"literal","value":2}},{"id":248,"name":"Config","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":35,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L35"}],"type":{"type":"literal","value":3}},{"id":249,"name":"Data","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":36,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L36"}],"type":{"type":"literal","value":4}},{"id":263,"name":"Desktop","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":51,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L51"}],"type":{"type":"literal","value":18}},{"id":251,"name":"Document","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":38,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L38"}],"type":{"type":"literal","value":6}},{"id":252,"name":"Download","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":39,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L39"}],"type":{"type":"literal","value":7}},{"id":264,"name":"Executable","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":52,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L52"}],"type":{"type":"literal","value":19}},{"id":265,"name":"Font","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":53,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L53"}],"type":{"type":"literal","value":20}},{"id":266,"name":"Home","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":54,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L54"}],"type":{"type":"literal","value":21}},{"id":250,"name":"LocalData","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":37,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L37"}],"type":{"type":"literal","value":5}},{"id":253,"name":"Picture","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":40,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L40"}],"type":{"type":"literal","value":8}},{"id":254,"name":"Public","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":41,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L41"}],"type":{"type":"literal","value":9}},{"id":256,"name":"Resource","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":43,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L43"}],"type":{"type":"literal","value":11}},{"id":267,"name":"Runtime","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":55,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L55"}],"type":{"type":"literal","value":22}},{"id":257,"name":"Temp","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":44,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L44"}],"type":{"type":"literal","value":12}},{"id":268,"name":"Template","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":56,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L56"}],"type":{"type":"literal","value":23}},{"id":255,"name":"Video","kind":16,"kindString":"Enumeration Member","flags":{},"sources":[{"fileName":"path.ts","line":42,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L42"}],"type":{"type":"literal","value":10}}],"groups":[{"title":"Enumeration Members","children":[261,258,259,260,262,246,247,248,249,263,251,252,264,265,266,250,253,254,256,267,257,268,255]}],"sources":[{"fileName":"path.ts","line":32,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L32"}]},{"id":317,"name":"delimiter","kind":32,"kindString":"Variable","flags":{"isConst":true},"comment":{"summary":[{"kind":"text","text":"Provides the platform-specific path segment delimiter:\n- "},{"kind":"code","text":"`;`"},{"kind":"text","text":" on Windows\n- "},{"kind":"code","text":"`:`"},{"kind":"text","text":" on POSIX"}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"sources":[{"fileName":"path.ts","line":555,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L555"}],"type":{"type":"union","types":[{"type":"literal","value":";"},{"type":"literal","value":":"}]},"defaultValue":"..."},{"id":316,"name":"sep","kind":32,"kindString":"Variable","flags":{"isConst":true},"comment":{"summary":[{"kind":"text","text":"Provides the platform-specific path segment separator:\n- "},{"kind":"code","text":"`\\` on Windows\n- `"},{"kind":"text","text":"/` on POSIX"}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"sources":[{"fileName":"path.ts","line":546,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L546"}],"type":{"type":"union","types":[{"type":"literal","value":"\\"},{"type":"literal","value":"/"}]},"defaultValue":"..."},{"id":275,"name":"appCacheDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":121,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L121"}],"signatures":[{"id":276,"name":"appCacheDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the suggested directory for your app's cache files.\nResolves to "},{"kind":"code","text":"`${cacheDir}/${bundleIdentifier}`"},{"kind":"text","text":", where "},{"kind":"code","text":"`bundleIdentifier`"},{"kind":"text","text":" is the value ["},{"kind":"code","text":"`tauri.bundle.identifier`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#bundleconfig.identifier) is configured in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appCacheDir } from '@tauri-apps/api/path';\nconst appCacheDirPath = await appCacheDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":269,"name":"appConfigDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":70,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L70"}],"signatures":[{"id":270,"name":"appConfigDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the suggested directory for your app's config files.\nResolves to "},{"kind":"code","text":"`${configDir}/${bundleIdentifier}`"},{"kind":"text","text":", where "},{"kind":"code","text":"`bundleIdentifier`"},{"kind":"text","text":" is the value ["},{"kind":"code","text":"`tauri.bundle.identifier`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#bundleconfig.identifier) is configured in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appConfigDir } from '@tauri-apps/api/path';\nconst appConfigDirPath = await appConfigDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":271,"name":"appDataDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":87,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L87"}],"signatures":[{"id":272,"name":"appDataDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the suggested directory for your app's data files.\nResolves to "},{"kind":"code","text":"`${dataDir}/${bundleIdentifier}`"},{"kind":"text","text":", where "},{"kind":"code","text":"`bundleIdentifier`"},{"kind":"text","text":" is the value ["},{"kind":"code","text":"`tauri.bundle.identifier`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#bundleconfig.identifier) is configured in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appDataDir } from '@tauri-apps/api/path';\nconst appDataDirPath = await appDataDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":273,"name":"appLocalDataDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":104,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L104"}],"signatures":[{"id":274,"name":"appLocalDataDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the suggested directory for your app's local data files.\nResolves to "},{"kind":"code","text":"`${localDataDir}/${bundleIdentifier}`"},{"kind":"text","text":", where "},{"kind":"code","text":"`bundleIdentifier`"},{"kind":"text","text":" is the value ["},{"kind":"code","text":"`tauri.bundle.identifier`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#bundleconfig.identifier) is configured in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appLocalDataDir } from '@tauri-apps/api/path';\nconst appLocalDataDirPath = await appLocalDataDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":277,"name":"appLogDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":533,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L533"}],"signatures":[{"id":278,"name":"appLogDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the suggested directory for your app's log files.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`${configDir}/${bundleIdentifier}/logs`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`${homeDir}/Library/Logs/{bundleIdentifier}`"},{"kind":"text","text":"\n- **Windows:** Resolves to "},{"kind":"code","text":"`${configDir}/${bundleIdentifier}/logs`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appLogDir } from '@tauri-apps/api/path';\nconst appLogDirPath = await appLogDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":279,"name":"audioDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":143,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L143"}],"signatures":[{"id":280,"name":"audioDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's audio directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_MUSIC_DIR`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Music`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Music}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { audioDir } from '@tauri-apps/api/path';\nconst audioDirPath = await audioDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":333,"name":"basename","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":647,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L647"}],"signatures":[{"id":334,"name":"basename","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the last portion of a "},{"kind":"code","text":"`path`"},{"kind":"text","text":". Trailing directory separators are ignored."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { basename, resolveResource } from '@tauri-apps/api/path';\nconst resourcePath = await resolveResource('app.conf');\nconst base = await basename(resourcePath);\nassert(base === 'app.conf');\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":335,"name":"path","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}},{"id":336,"name":"ext","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"An optional file extension to be removed from the returned path."}]},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":281,"name":"cacheDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":165,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L165"}],"signatures":[{"id":282,"name":"cacheDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's cache directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$XDG_CACHE_HOME`"},{"kind":"text","text":" or "},{"kind":"code","text":"`$HOME/.cache`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Library/Caches`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_LocalAppData}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { cacheDir } from '@tauri-apps/api/path';\nconst cacheDirPath = await cacheDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":283,"name":"configDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":187,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L187"}],"signatures":[{"id":284,"name":"configDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's config directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$XDG_CONFIG_HOME`"},{"kind":"text","text":" or "},{"kind":"code","text":"`$HOME/.config`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Library/Application Support`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_RoamingAppData}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { configDir } from '@tauri-apps/api/path';\nconst configDirPath = await configDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":285,"name":"dataDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":209,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L209"}],"signatures":[{"id":286,"name":"dataDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's data directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$XDG_DATA_HOME`"},{"kind":"text","text":" or "},{"kind":"code","text":"`$HOME/.local/share`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Library/Application Support`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_RoamingAppData}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { dataDir } from '@tauri-apps/api/path';\nconst dataDirPath = await dataDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":287,"name":"desktopDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":231,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L231"}],"signatures":[{"id":288,"name":"desktopDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's desktop directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_DESKTOP_DIR`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Desktop`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Desktop}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { desktopDir } from '@tauri-apps/api/path';\nconst desktopPath = await desktopDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":327,"name":"dirname","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":613,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L613"}],"signatures":[{"id":328,"name":"dirname","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the directory name of a "},{"kind":"code","text":"`path`"},{"kind":"text","text":". Trailing directory separators are ignored."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { dirname, appDataDir } from '@tauri-apps/api/path';\nconst appDataDirPath = await appDataDir();\nconst dir = await dirname(appDataDirPath);\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":329,"name":"path","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":289,"name":"documentDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":253,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L253"}],"signatures":[{"id":290,"name":"documentDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's document directory."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { documentDir } from '@tauri-apps/api/path';\nconst documentDirPath = await documentDir();\n```"},{"kind":"text","text":"\n\n#### Platform-specific\n\n- **Linux:** Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_DOCUMENTS_DIR`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Documents`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Documents}`"},{"kind":"text","text":"."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":291,"name":"downloadDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":275,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L275"}],"signatures":[{"id":292,"name":"downloadDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's download directory.\n\n#### Platform-specific\n\n- **Linux**: Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_DOWNLOAD_DIR`"},{"kind":"text","text":".\n- **macOS**: Resolves to "},{"kind":"code","text":"`$HOME/Downloads`"},{"kind":"text","text":".\n- **Windows**: Resolves to "},{"kind":"code","text":"`{FOLDERID_Downloads}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { downloadDir } from '@tauri-apps/api/path';\nconst downloadDirPath = await downloadDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":293,"name":"executableDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":297,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L297"}],"signatures":[{"id":294,"name":"executableDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's executable directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$XDG_BIN_HOME/../bin`"},{"kind":"text","text":" or "},{"kind":"code","text":"`$XDG_DATA_HOME/../bin`"},{"kind":"text","text":" or "},{"kind":"code","text":"`$HOME/.local/bin`"},{"kind":"text","text":".\n- **macOS:** Not supported.\n- **Windows:** Not supported."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { executableDir } from '@tauri-apps/api/path';\nconst executableDirPath = await executableDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":330,"name":"extname","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":629,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L629"}],"signatures":[{"id":331,"name":"extname","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the extension of the "},{"kind":"code","text":"`path`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { extname, resolveResource } from '@tauri-apps/api/path';\nconst resourcePath = await resolveResource('app.conf');\nconst ext = await extname(resourcePath);\nassert(ext === 'conf');\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":332,"name":"path","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":295,"name":"fontDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":319,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L319"}],"signatures":[{"id":296,"name":"fontDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's font directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$XDG_DATA_HOME/fonts`"},{"kind":"text","text":" or "},{"kind":"code","text":"`$HOME/.local/share/fonts`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Library/Fonts`"},{"kind":"text","text":".\n- **Windows:** Not supported."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { fontDir } from '@tauri-apps/api/path';\nconst fontDirPath = await fontDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":297,"name":"homeDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":341,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L341"}],"signatures":[{"id":298,"name":"homeDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's home directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$HOME`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Profile}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { homeDir } from '@tauri-apps/api/path';\nconst homeDirPath = await homeDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":337,"name":"isAbsolute","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":661,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L661"}],"signatures":[{"id":338,"name":"isAbsolute","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns whether the path is absolute or not."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { isAbsolute } from '@tauri-apps/api/path';\nassert(await isAbsolute('/home/tauri'));\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":339,"name":"path","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":324,"name":"join","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":598,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L598"}],"signatures":[{"id":325,"name":"join","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Joins all given "},{"kind":"code","text":"`path`"},{"kind":"text","text":" segments together using the platform-specific separator as a delimiter, then normalizes the resulting path."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { join, appDataDir } from '@tauri-apps/api/path';\nconst appDataDirPath = await appDataDir();\nconst path = await join(appDataDirPath, 'users', 'tauri', 'avatar.png');\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":326,"name":"paths","kind":32768,"kindString":"Parameter","flags":{"isRest":true},"type":{"type":"array","elementType":{"type":"intrinsic","name":"string"}}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":299,"name":"localDataDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":363,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L363"}],"signatures":[{"id":300,"name":"localDataDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's local data directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$XDG_DATA_HOME`"},{"kind":"text","text":" or "},{"kind":"code","text":"`$HOME/.local/share`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Library/Application Support`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_LocalAppData}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { localDataDir } from '@tauri-apps/api/path';\nconst localDataDirPath = await localDataDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":321,"name":"normalize","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":583,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L583"}],"signatures":[{"id":322,"name":"normalize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Normalizes the given "},{"kind":"code","text":"`path`"},{"kind":"text","text":", resolving "},{"kind":"code","text":"`'..'`"},{"kind":"text","text":" and "},{"kind":"code","text":"`'.'`"},{"kind":"text","text":" segments and resolve symbolic links."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { normalize, appDataDir } from '@tauri-apps/api/path';\nconst appDataDirPath = await appDataDir();\nconst path = await normalize(appDataDirPath, '..', 'users', 'tauri', 'avatar.png');\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":323,"name":"path","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":301,"name":"pictureDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":385,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L385"}],"signatures":[{"id":302,"name":"pictureDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's picture directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_PICTURES_DIR`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Pictures`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Pictures}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { pictureDir } from '@tauri-apps/api/path';\nconst pictureDirPath = await pictureDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":303,"name":"publicDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":407,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L407"}],"signatures":[{"id":304,"name":"publicDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's public directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_PUBLICSHARE_DIR`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Public`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Public}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { publicDir } from '@tauri-apps/api/path';\nconst publicDirPath = await publicDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":318,"name":"resolve","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":568,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L568"}],"signatures":[{"id":319,"name":"resolve","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Resolves a sequence of "},{"kind":"code","text":"`paths`"},{"kind":"text","text":" or "},{"kind":"code","text":"`path`"},{"kind":"text","text":" segments into an absolute path."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { resolve, appDataDir } from '@tauri-apps/api/path';\nconst appDataDirPath = await appDataDir();\nconst path = await resolve(appDataDirPath, '..', 'users', 'tauri', 'avatar.png');\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":320,"name":"paths","kind":32768,"kindString":"Parameter","flags":{"isRest":true},"type":{"type":"array","elementType":{"type":"intrinsic","name":"string"}}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":307,"name":"resolveResource","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":444,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L444"}],"signatures":[{"id":308,"name":"resolveResource","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Resolve the path to a resource file."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { resolveResource } from '@tauri-apps/api/path';\nconst resourcePath = await resolveResource('script.sh');\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The full path to the resource."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":309,"name":"resourcePath","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The path to the resource.\nMust follow the same syntax as defined in "},{"kind":"code","text":"`tauri.conf.json > tauri > bundle > resources`"},{"kind":"text","text":", i.e. keeping subfolders and parent dir components ("},{"kind":"code","text":"`../`"},{"kind":"text","text":")."}]},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":305,"name":"resourceDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":424,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L424"}],"signatures":[{"id":306,"name":"resourceDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the application's resource directory.\nTo resolve a resource path, see the [[resolveResource | "},{"kind":"code","text":"`resolveResource API`"},{"kind":"text","text":"]]."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { resourceDir } from '@tauri-apps/api/path';\nconst resourceDirPath = await resourceDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":310,"name":"runtimeDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":467,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L467"}],"signatures":[{"id":311,"name":"runtimeDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's runtime directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to "},{"kind":"code","text":"`$XDG_RUNTIME_DIR`"},{"kind":"text","text":".\n- **macOS:** Not supported.\n- **Windows:** Not supported."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { runtimeDir } from '@tauri-apps/api/path';\nconst runtimeDirPath = await runtimeDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":312,"name":"templateDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":489,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L489"}],"signatures":[{"id":313,"name":"templateDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's template directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_TEMPLATES_DIR`"},{"kind":"text","text":".\n- **macOS:** Not supported.\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Templates}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { templateDir } from '@tauri-apps/api/path';\nconst templateDirPath = await templateDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":314,"name":"videoDir","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"path.ts","line":511,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L511"}],"signatures":[{"id":315,"name":"videoDir","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the path to the user's video directory.\n\n#### Platform-specific\n\n- **Linux:** Resolves to ["},{"kind":"code","text":"`xdg-user-dirs`"},{"kind":"text","text":"](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/)' "},{"kind":"code","text":"`XDG_VIDEOS_DIR`"},{"kind":"text","text":".\n- **macOS:** Resolves to "},{"kind":"code","text":"`$HOME/Movies`"},{"kind":"text","text":".\n- **Windows:** Resolves to "},{"kind":"code","text":"`{FOLDERID_Videos}`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { videoDir } from '@tauri-apps/api/path';\nconst videoDirPath = await videoDir();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Enumerations","children":[245]},{"title":"Variables","children":[317,316]},{"title":"Functions","children":[275,269,271,273,277,279,333,281,283,285,287,327,289,291,293,330,295,297,337,324,299,321,301,303,318,307,305,310,312,314]}],"sources":[{"fileName":"path.ts","line":26,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/path.ts#L26"}]},{"id":340,"name":"process","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Perform operations on the current process.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.process`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":"."}]},"children":[{"id":341,"name":"exit","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"process.ts","line":27,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/process.ts#L27"}],"signatures":[{"id":342,"name":"exit","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Exits immediately with the given "},{"kind":"code","text":"`exitCode`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { exit } from '@tauri-apps/api/process';\nawait exit(1);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":343,"name":"exitCode","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The exit code to use."}]},"type":{"type":"intrinsic","name":"number"},"defaultValue":"0"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":344,"name":"relaunch","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"process.ts","line":49,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/process.ts#L49"}],"signatures":[{"id":345,"name":"relaunch","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Exits the current instance of the app then relaunches it."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { relaunch } from '@tauri-apps/api/process';\nawait relaunch();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Functions","children":[341,344]}],"sources":[{"fileName":"process.ts","line":12,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/process.ts#L12"}]},{"id":346,"name":"shell","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Access the system shell.\nAllows you to spawn child processes and manage files and URLs using their default application.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.shell`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be added to ["},{"kind":"code","text":"`tauri.allowlist.shell`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.shell) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"shell\": {\n \"all\": true, // enable all shell APIs\n \"execute\": true, // enable process spawn APIs\n \"sidecar\": true, // enable spawning sidecars\n \"open\": true // enable opening files/URLs using the default program\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security.\n\n## Security\n\nThis API has a scope configuration that forces you to restrict the programs and arguments that can be used.\n\n### Restricting access to the "},{"kind":"inline-tag","tag":"@link","text":"`open`","target":552},{"kind":"text","text":" API\n\nOn the allowlist, "},{"kind":"code","text":"`open: true`"},{"kind":"text","text":" means that the "},{"kind":"inline-tag","tag":"@link","text":"open","target":552},{"kind":"text","text":" API can be used with any URL,\nas the argument is validated with the "},{"kind":"code","text":"`^((mailto:\\w+)|(tel:\\w+)|(https?://\\w+)).+`"},{"kind":"text","text":" regex.\nYou can change that regex by changing the boolean value to a string, e.g. "},{"kind":"code","text":"`open: ^https://github.com/`"},{"kind":"text","text":".\n\n### Restricting access to the "},{"kind":"inline-tag","tag":"@link","text":"`Command`","target":347},{"kind":"text","text":" APIs\n\nThe "},{"kind":"code","text":"`shell`"},{"kind":"text","text":" allowlist object has a "},{"kind":"code","text":"`scope`"},{"kind":"text","text":" field that defines an array of CLIs that can be used.\nEach CLI is a configuration object "},{"kind":"code","text":"`{ name: string, cmd: string, sidecar?: bool, args?: boolean | Arg[] }`"},{"kind":"text","text":".\n\n- "},{"kind":"code","text":"`name`"},{"kind":"text","text":": the unique identifier of the command, passed to the "},{"kind":"inline-tag","tag":"@link","text":"Command.create function","target":348},{"kind":"text","text":".\nIf it's a sidecar, this must be the value defined on "},{"kind":"code","text":"`tauri.conf.json > tauri > bundle > externalBin`"},{"kind":"text","text":".\n- "},{"kind":"code","text":"`cmd`"},{"kind":"text","text":": the program that is executed on this configuration. If it's a sidecar, this value is ignored.\n- "},{"kind":"code","text":"`sidecar`"},{"kind":"text","text":": whether the object configures a sidecar or a system program.\n- "},{"kind":"code","text":"`args`"},{"kind":"text","text":": the arguments that can be passed to the program. By default no arguments are allowed.\n - "},{"kind":"code","text":"`true`"},{"kind":"text","text":" means that any argument list is allowed.\n - "},{"kind":"code","text":"`false`"},{"kind":"text","text":" means that no arguments are allowed.\n - otherwise an array can be configured. Each item is either a string representing the fixed argument value\n or a "},{"kind":"code","text":"`{ validator: string }`"},{"kind":"text","text":" that defines a regex validating the argument value.\n\n#### Example scope configuration\n\nCLI: "},{"kind":"code","text":"`git commit -m \"the commit message\"`"},{"kind":"text","text":"\n\nConfiguration:\n"},{"kind":"code","text":"```json\n{\n \"scope\": [\n {\n \"name\": \"run-git-commit\",\n \"cmd\": \"git\",\n \"args\": [\"commit\", \"-m\", { \"validator\": \"\\\\S+\" }]\n }\n ]\n}\n```"},{"kind":"text","text":"\nUsage:\n"},{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell'\nCommand.create('run-git-commit', ['commit', '-m', 'the commit message'])\n```"},{"kind":"text","text":"\n\nTrying to execute any API with a program not configured on the scope results in a promise rejection due to denied access."}]},"children":[{"id":464,"name":"Child","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"children":[{"id":465,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"sources":[{"fileName":"shell.ts","line":346,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L346"}],"signatures":[{"id":466,"name":"new Child","kind":16384,"kindString":"Constructor signature","flags":{},"parameters":[{"id":467,"name":"pid","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}}],"type":{"type":"reference","id":464,"name":"Child"}}]},{"id":468,"name":"pid","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The child process "},{"kind":"code","text":"`pid`"},{"kind":"text","text":"."}]},"sources":[{"fileName":"shell.ts","line":344,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L344"}],"type":{"type":"intrinsic","name":"number"}},{"id":472,"name":"kill","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":382,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L382"}],"signatures":[{"id":473,"name":"kill","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Kills the child process."}],"blockTags":[{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":469,"name":"write","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":365,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L365"}],"signatures":[{"id":470,"name":"write","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Writes "},{"kind":"code","text":"`data`"},{"kind":"text","text":" to the "},{"kind":"code","text":"`stdin`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.create('node');\nconst child = await command.spawn();\nawait child.write('message');\nawait child.write([0, 1, 2, 3, 4, 5]);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":471,"name":"data","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The message to write, either a string or a byte array."}]},"type":{"type":"reference","id":556,"name":"IOPayload"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Constructors","children":[465]},{"title":"Properties","children":[468]},{"title":"Methods","children":[472,469]}],"sources":[{"fileName":"shell.ts","line":342,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L342"}]},{"id":347,"name":"Command","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"The entry point for spawning child processes.\nIt emits the "},{"kind":"code","text":"`close`"},{"kind":"text","text":" and "},{"kind":"code","text":"`error`"},{"kind":"text","text":" events."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.create('node');\ncommand.on('close', data => {\n console.log(`command finished with code ${data.code} and signal ${data.signal}`)\n});\ncommand.on('error', error => console.error(`command error: \"${error}\"`));\ncommand.stdout.on('data', line => console.log(`command stdout: \"${line}\"`));\ncommand.stderr.on('data', line => console.log(`command stderr: \"${line}\"`));\n\nconst child = await command.spawn();\nconsole.log('pid:', child.pid);\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"children":[{"id":386,"name":"stderr","kind":1024,"kindString":"Property","flags":{"isReadonly":true},"comment":{"summary":[{"kind":"text","text":"Event emitter for the "},{"kind":"code","text":"`stderr`"},{"kind":"text","text":". Emits the "},{"kind":"code","text":"`data`"},{"kind":"text","text":" event."}]},"sources":[{"fileName":"shell.ts","line":433,"character":11,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L433"}],"type":{"type":"reference","id":474,"typeArguments":[{"type":"reference","id":563,"typeArguments":[{"type":"reference","name":"O"}],"name":"OutputEvents"}],"name":"EventEmitter"},"defaultValue":"..."},{"id":385,"name":"stdout","kind":1024,"kindString":"Property","flags":{"isReadonly":true},"comment":{"summary":[{"kind":"text","text":"Event emitter for the "},{"kind":"code","text":"`stdout`"},{"kind":"text","text":". Emits the "},{"kind":"code","text":"`data`"},{"kind":"text","text":" event."}]},"sources":[{"fileName":"shell.ts","line":431,"character":11,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L431"}],"type":{"type":"reference","id":474,"typeArguments":[{"type":"reference","id":563,"typeArguments":[{"type":"reference","name":"O"}],"name":"OutputEvents"}],"name":"EventEmitter"},"defaultValue":"..."},{"id":394,"name":"addListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":164,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L164"}],"signatures":[{"id":395,"name":"addListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Alias for "},{"kind":"code","text":"`emitter.on(eventName, listener)`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":396,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":557,"name":"CommandEvents"}}}],"parameters":[{"id":397,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":396,"name":"N"}},{"id":398,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":399,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":166,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L166"}],"signatures":[{"id":400,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":401,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":396,"name":"N"},"objectType":{"type":"reference","id":557,"name":"CommandEvents"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":347,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":483,"name":"EventEmitter.addListener"}}],"inheritedFrom":{"type":"reference","id":482,"name":"EventEmitter.addListener"}},{"id":389,"name":"execute","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":564,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L564"}],"signatures":[{"id":390,"name":"execute","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Executes the command as a child process, waiting for it to finish and collecting all of its output."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst output = await Command.create('echo', 'message').execute();\nassert(output.code === 0);\nassert(output.signal === null);\nassert(output.stdout === 'message');\nassert(output.stderr === '');\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to the child process output."}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":566,"typeArguments":[{"type":"reference","name":"O"}],"name":"ChildProcess"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":443,"name":"listenerCount","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":287,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L287"}],"signatures":[{"id":444,"name":"listenerCount","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the number of listeners listening to the event named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":445,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":557,"name":"CommandEvents"}}}],"parameters":[{"id":446,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":445,"name":"N"}}],"type":{"type":"intrinsic","name":"number"},"inheritedFrom":{"type":"reference","id":532,"name":"EventEmitter.listenerCount"}}],"inheritedFrom":{"type":"reference","id":531,"name":"EventEmitter.listenerCount"}},{"id":426,"name":"off","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":233,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L233"}],"signatures":[{"id":427,"name":"off","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Removes the all specified listener from the listener array for the event eventName\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":428,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":557,"name":"CommandEvents"}}}],"parameters":[{"id":429,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":428,"name":"N"}},{"id":430,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":431,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":235,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L235"}],"signatures":[{"id":432,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":433,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":428,"name":"N"},"objectType":{"type":"reference","id":557,"name":"CommandEvents"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":347,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":515,"name":"EventEmitter.off"}}],"inheritedFrom":{"type":"reference","id":514,"name":"EventEmitter.off"}},{"id":410,"name":"on","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":193,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L193"}],"signatures":[{"id":411,"name":"on","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function to the end of the listeners array for the\nevent named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":". No checks are made to see if the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" has\nalready been added. Multiple calls passing the same combination of "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":"and "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" will result in the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" being added, and called, multiple\ntimes.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"typeParameter":[{"id":412,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":557,"name":"CommandEvents"}}}],"parameters":[{"id":413,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":412,"name":"N"}},{"id":414,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":415,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":195,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L195"}],"signatures":[{"id":416,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":417,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":412,"name":"N"},"objectType":{"type":"reference","id":557,"name":"CommandEvents"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":347,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":499,"name":"EventEmitter.on"}}],"inheritedFrom":{"type":"reference","id":498,"name":"EventEmitter.on"}},{"id":418,"name":"once","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":215,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L215"}],"signatures":[{"id":419,"name":"once","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds a **one-time**"},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function for the event named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":". The\nnext time "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":" is triggered, this listener is removed and then invoked.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":420,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":557,"name":"CommandEvents"}}}],"parameters":[{"id":421,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":420,"name":"N"}},{"id":422,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":423,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":217,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L217"}],"signatures":[{"id":424,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":425,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":420,"name":"N"},"objectType":{"type":"reference","id":557,"name":"CommandEvents"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":347,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":507,"name":"EventEmitter.once"}}],"inheritedFrom":{"type":"reference","id":506,"name":"EventEmitter.once"}},{"id":447,"name":"prependListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":304,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L304"}],"signatures":[{"id":448,"name":"prependListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function to the _beginning_ of the listeners array for the\nevent named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":". No checks are made to see if the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" has\nalready been added. Multiple calls passing the same combination of "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":"and "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" will result in the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" being added, and called, multiple\ntimes.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":449,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":557,"name":"CommandEvents"}}}],"parameters":[{"id":450,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":449,"name":"N"}},{"id":451,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":452,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":306,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L306"}],"signatures":[{"id":453,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":454,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":449,"name":"N"},"objectType":{"type":"reference","id":557,"name":"CommandEvents"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":347,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":536,"name":"EventEmitter.prependListener"}}],"inheritedFrom":{"type":"reference","id":535,"name":"EventEmitter.prependListener"}},{"id":455,"name":"prependOnceListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":326,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L326"}],"signatures":[{"id":456,"name":"prependOnceListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds a **one-time**"},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function for the event named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":" to the_beginning_ of the listeners array. The next time "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":" is triggered, this\nlistener is removed, and then invoked.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":457,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":557,"name":"CommandEvents"}}}],"parameters":[{"id":458,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":457,"name":"N"}},{"id":459,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":460,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":328,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L328"}],"signatures":[{"id":461,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":462,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":457,"name":"N"},"objectType":{"type":"reference","id":557,"name":"CommandEvents"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":347,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":544,"name":"EventEmitter.prependOnceListener"}}],"inheritedFrom":{"type":"reference","id":543,"name":"EventEmitter.prependOnceListener"}},{"id":434,"name":"removeAllListeners","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":253,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L253"}],"signatures":[{"id":435,"name":"removeAllListeners","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Removes all listeners, or those of the specified eventName.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":436,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":557,"name":"CommandEvents"}}}],"parameters":[{"id":437,"name":"event","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":436,"name":"N"}}],"type":{"type":"reference","id":347,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":523,"name":"EventEmitter.removeAllListeners"}}],"inheritedFrom":{"type":"reference","id":522,"name":"EventEmitter.removeAllListeners"}},{"id":402,"name":"removeListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":176,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L176"}],"signatures":[{"id":403,"name":"removeListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Alias for "},{"kind":"code","text":"`emitter.off(eventName, listener)`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":404,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"typeOperator","operator":"keyof","target":{"type":"reference","id":557,"name":"CommandEvents"}}}],"parameters":[{"id":405,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":404,"name":"N"}},{"id":406,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":407,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":178,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L178"}],"signatures":[{"id":408,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":409,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":404,"name":"N"},"objectType":{"type":"reference","id":557,"name":"CommandEvents"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":347,"typeArguments":[{"type":"reference","name":"O"}],"name":"Command"},"inheritedFrom":{"type":"reference","id":491,"name":"EventEmitter.removeListener"}}],"inheritedFrom":{"type":"reference","id":490,"name":"EventEmitter.removeListener"}},{"id":387,"name":"spawn","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":526,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L526"}],"signatures":[{"id":388,"name":"spawn","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Executes the command as a child process, returning a handle to it."}],"blockTags":[{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to the child process handle."}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":464,"name":"Child"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":348,"name":"create","kind":2048,"kindString":"Method","flags":{"isStatic":true},"sources":[{"fileName":"shell.ts","line":455,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L455"},{"fileName":"shell.ts","line":456,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L456"},{"fileName":"shell.ts","line":461,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L461"},{"fileName":"shell.ts","line":479,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L479"}],"signatures":[{"id":349,"name":"create","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a command to execute the given program."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.create('my-app', ['run', 'tauri']);\nconst output = await command.execute();\n```"}]}]},"parameters":[{"id":350,"name":"program","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The program to execute.\nIt must be configured on "},{"kind":"code","text":"`tauri.conf.json > tauri > allowlist > shell > scope`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":351,"name":"args","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}]}}],"type":{"type":"reference","id":347,"typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Command"}},{"id":352,"name":"create","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a command to execute the given program."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.create('my-app', ['run', 'tauri']);\nconst output = await command.execute();\n```"}]}]},"parameters":[{"id":353,"name":"program","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The program to execute.\nIt must be configured on "},{"kind":"code","text":"`tauri.conf.json > tauri > allowlist > shell > scope`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":354,"name":"args","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}]}},{"id":355,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"intersection","types":[{"type":"reference","id":572,"name":"SpawnOptions"},{"type":"reflection","declaration":{"id":356,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"children":[{"id":357,"name":"encoding","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"shell.ts","line":459,"character":31,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L459"}],"type":{"type":"literal","value":"raw"}}],"groups":[{"title":"Properties","children":[357]}],"sources":[{"fileName":"shell.ts","line":459,"character":29,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L459"}]}}]}}],"type":{"type":"reference","id":347,"typeArguments":[{"type":"reference","name":"Uint8Array","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array","qualifiedName":"Uint8Array","package":"typescript"}],"name":"Command"}},{"id":358,"name":"create","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a command to execute the given program."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.create('my-app', ['run', 'tauri']);\nconst output = await command.execute();\n```"}]}]},"parameters":[{"id":359,"name":"program","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The program to execute.\nIt must be configured on "},{"kind":"code","text":"`tauri.conf.json > tauri > allowlist > shell > scope`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":360,"name":"args","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}]}},{"id":361,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":572,"name":"SpawnOptions"}}],"type":{"type":"reference","id":347,"typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Command"}}]},{"id":362,"name":"sidecar","kind":2048,"kindString":"Method","flags":{"isStatic":true},"sources":[{"fileName":"shell.ts","line":487,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L487"},{"fileName":"shell.ts","line":488,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L488"},{"fileName":"shell.ts","line":493,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L493"},{"fileName":"shell.ts","line":511,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L511"}],"signatures":[{"id":363,"name":"sidecar","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a command to execute the given sidecar program."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.sidecar('my-sidecar');\nconst output = await command.execute();\n```"}]}]},"parameters":[{"id":364,"name":"program","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The program to execute.\nIt must be configured on "},{"kind":"code","text":"`tauri.conf.json > tauri > allowlist > shell > scope`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":365,"name":"args","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}]}}],"type":{"type":"reference","id":347,"typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Command"}},{"id":366,"name":"sidecar","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a command to execute the given sidecar program."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.sidecar('my-sidecar');\nconst output = await command.execute();\n```"}]}]},"parameters":[{"id":367,"name":"program","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The program to execute.\nIt must be configured on "},{"kind":"code","text":"`tauri.conf.json > tauri > allowlist > shell > scope`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":368,"name":"args","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}]}},{"id":369,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"intersection","types":[{"type":"reference","id":572,"name":"SpawnOptions"},{"type":"reflection","declaration":{"id":370,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"children":[{"id":371,"name":"encoding","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"shell.ts","line":491,"character":31,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L491"}],"type":{"type":"literal","value":"raw"}}],"groups":[{"title":"Properties","children":[371]}],"sources":[{"fileName":"shell.ts","line":491,"character":29,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L491"}]}}]}}],"type":{"type":"reference","id":347,"typeArguments":[{"type":"reference","name":"Uint8Array","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array","qualifiedName":"Uint8Array","package":"typescript"}],"name":"Command"}},{"id":372,"name":"sidecar","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a command to execute the given sidecar program."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { Command } from '@tauri-apps/api/shell';\nconst command = Command.sidecar('my-sidecar');\nconst output = await command.execute();\n```"}]}]},"parameters":[{"id":373,"name":"program","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The program to execute.\nIt must be configured on "},{"kind":"code","text":"`tauri.conf.json > tauri > allowlist > shell > scope`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":374,"name":"args","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"intrinsic","name":"string"}}]}},{"id":375,"name":"options","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":572,"name":"SpawnOptions"}}],"type":{"type":"reference","id":347,"typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Command"}}]}],"groups":[{"title":"Properties","children":[386,385]},{"title":"Methods","children":[394,389,443,426,410,418,447,455,434,402,387,348,362]}],"sources":[{"fileName":"shell.ts","line":423,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L423"}],"typeParameters":[{"id":463,"name":"O","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"reference","id":556,"name":"IOPayload"}}],"extendedTypes":[{"type":"reference","id":474,"typeArguments":[{"type":"reference","id":557,"name":"CommandEvents"}],"name":"EventEmitter"}]},{"id":474,"name":"EventEmitter","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":475,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"signatures":[{"id":476,"name":"new EventEmitter","kind":16384,"kindString":"Constructor signature","flags":{},"typeParameter":[{"id":477,"name":"E","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"any"}],"name":"Record","qualifiedName":"Record","package":"typescript"}}],"type":{"type":"reference","id":474,"typeArguments":[{"type":"reference","id":477,"name":"E"}],"name":"EventEmitter"}}]},{"id":482,"name":"addListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":164,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L164"}],"signatures":[{"id":483,"name":"addListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Alias for "},{"kind":"code","text":"`emitter.on(eventName, listener)`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":484,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":485,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":396,"name":"N"}},{"id":486,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":487,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":166,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L166"}],"signatures":[{"id":488,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":489,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":396,"name":"N"},"objectType":{"type":"reference","id":477,"name":"E"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":474,"typeArguments":[{"type":"reference","id":477,"name":"E"}],"name":"EventEmitter"}}]},{"id":531,"name":"listenerCount","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":287,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L287"}],"signatures":[{"id":532,"name":"listenerCount","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the number of listeners listening to the event named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":533,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":534,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":445,"name":"N"}}],"type":{"type":"intrinsic","name":"number"}}]},{"id":514,"name":"off","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":233,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L233"}],"signatures":[{"id":515,"name":"off","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Removes the all specified listener from the listener array for the event eventName\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":516,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":517,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":428,"name":"N"}},{"id":518,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":519,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":235,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L235"}],"signatures":[{"id":520,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":521,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":428,"name":"N"},"objectType":{"type":"reference","id":477,"name":"E"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":474,"typeArguments":[{"type":"reference","id":477,"name":"E"}],"name":"EventEmitter"}}]},{"id":498,"name":"on","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":193,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L193"}],"signatures":[{"id":499,"name":"on","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function to the end of the listeners array for the\nevent named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":". No checks are made to see if the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" has\nalready been added. Multiple calls passing the same combination of "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":"and "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" will result in the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" being added, and called, multiple\ntimes.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"typeParameter":[{"id":500,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":501,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":412,"name":"N"}},{"id":502,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":503,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":195,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L195"}],"signatures":[{"id":504,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":505,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":412,"name":"N"},"objectType":{"type":"reference","id":477,"name":"E"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":474,"typeArguments":[{"type":"reference","id":477,"name":"E"}],"name":"EventEmitter"}}]},{"id":506,"name":"once","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":215,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L215"}],"signatures":[{"id":507,"name":"once","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds a **one-time**"},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function for the event named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":". The\nnext time "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":" is triggered, this listener is removed and then invoked.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":508,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":509,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":420,"name":"N"}},{"id":510,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":511,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":217,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L217"}],"signatures":[{"id":512,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":513,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":420,"name":"N"},"objectType":{"type":"reference","id":477,"name":"E"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":474,"typeArguments":[{"type":"reference","id":477,"name":"E"}],"name":"EventEmitter"}}]},{"id":535,"name":"prependListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":304,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L304"}],"signatures":[{"id":536,"name":"prependListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function to the _beginning_ of the listeners array for the\nevent named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":". No checks are made to see if the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" has\nalready been added. Multiple calls passing the same combination of "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":"and "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" will result in the "},{"kind":"code","text":"`listener`"},{"kind":"text","text":" being added, and called, multiple\ntimes.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":537,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":538,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":449,"name":"N"}},{"id":539,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":540,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":306,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L306"}],"signatures":[{"id":541,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":542,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":449,"name":"N"},"objectType":{"type":"reference","id":477,"name":"E"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":474,"typeArguments":[{"type":"reference","id":477,"name":"E"}],"name":"EventEmitter"}}]},{"id":543,"name":"prependOnceListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":326,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L326"}],"signatures":[{"id":544,"name":"prependOnceListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Adds a **one-time**"},{"kind":"code","text":"`listener`"},{"kind":"text","text":" function for the event named "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":" to the_beginning_ of the listeners array. The next time "},{"kind":"code","text":"`eventName`"},{"kind":"text","text":" is triggered, this\nlistener is removed, and then invoked.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":545,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":546,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":457,"name":"N"}},{"id":547,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":548,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":328,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L328"}],"signatures":[{"id":549,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":550,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":457,"name":"N"},"objectType":{"type":"reference","id":477,"name":"E"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":474,"typeArguments":[{"type":"reference","id":477,"name":"E"}],"name":"EventEmitter"}}]},{"id":522,"name":"removeAllListeners","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":253,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L253"}],"signatures":[{"id":523,"name":"removeAllListeners","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Removes all listeners, or those of the specified eventName.\n\nReturns a reference to the "},{"kind":"code","text":"`EventEmitter`"},{"kind":"text","text":", so that calls can be chained."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":524,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":525,"name":"event","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reference","id":436,"name":"N"}}],"type":{"type":"reference","id":474,"typeArguments":[{"type":"reference","id":477,"name":"E"}],"name":"EventEmitter"}}]},{"id":490,"name":"removeListener","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"shell.ts","line":176,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L176"}],"signatures":[{"id":491,"name":"removeListener","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Alias for "},{"kind":"code","text":"`emitter.off(eventName, listener)`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"typeParameter":[{"id":492,"name":"N","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"number"},{"type":"intrinsic","name":"symbol"}]}}],"parameters":[{"id":493,"name":"eventName","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":404,"name":"N"}},{"id":494,"name":"listener","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":495,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"shell.ts","line":178,"character":14,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L178"}],"signatures":[{"id":496,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":497,"name":"arg","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"indexedAccess","indexType":{"type":"reference","id":404,"name":"N"},"objectType":{"type":"reference","id":477,"name":"E"}}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","id":474,"typeArguments":[{"type":"reference","id":477,"name":"E"}],"name":"EventEmitter"}}]}],"groups":[{"title":"Constructors","children":[475]},{"title":"Methods","children":[482,531,514,498,506,535,543,522,490]}],"sources":[{"fileName":"shell.ts","line":153,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L153"}],"typeParameters":[{"id":551,"name":"E","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"any"}],"name":"Record","qualifiedName":"Record","package":"typescript"}}],"extendedBy":[{"type":"reference","id":347,"name":"Command"}]},{"id":566,"name":"ChildProcess","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":567,"name":"code","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Exit code of the process. "},{"kind":"code","text":"`null`"},{"kind":"text","text":" if the process was terminated by a signal on Unix."}]},"sources":[{"fileName":"shell.ts","line":109,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L109"}],"type":{"type":"union","types":[{"type":"literal","value":null},{"type":"intrinsic","name":"number"}]}},{"id":568,"name":"signal","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"If the process was terminated by a signal, represents that signal."}]},"sources":[{"fileName":"shell.ts","line":111,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L111"}],"type":{"type":"union","types":[{"type":"literal","value":null},{"type":"intrinsic","name":"number"}]}},{"id":570,"name":"stderr","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The data that the process wrote to "},{"kind":"code","text":"`stderr`"},{"kind":"text","text":"."}]},"sources":[{"fileName":"shell.ts","line":115,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L115"}],"type":{"type":"reference","id":571,"name":"O"}},{"id":569,"name":"stdout","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The data that the process wrote to "},{"kind":"code","text":"`stdout`"},{"kind":"text","text":"."}]},"sources":[{"fileName":"shell.ts","line":113,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L113"}],"type":{"type":"reference","id":571,"name":"O"}}],"groups":[{"title":"Properties","children":[567,568,570,569]}],"sources":[{"fileName":"shell.ts","line":107,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L107"}],"typeParameters":[{"id":571,"name":"O","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"reference","id":556,"name":"IOPayload"}}]},{"id":557,"name":"CommandEvents","kind":256,"kindString":"Interface","flags":{},"children":[{"id":558,"name":"close","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"shell.ts","line":394,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L394"}],"type":{"type":"reference","id":560,"name":"TerminatedPayload"}},{"id":559,"name":"error","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"shell.ts","line":395,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L395"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[558,559]}],"sources":[{"fileName":"shell.ts","line":393,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L393"}]},{"id":563,"name":"OutputEvents","kind":256,"kindString":"Interface","flags":{},"children":[{"id":564,"name":"data","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"shell.ts","line":399,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L399"}],"type":{"type":"reference","id":565,"name":"O"}}],"groups":[{"title":"Properties","children":[564]}],"sources":[{"fileName":"shell.ts","line":398,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L398"}],"typeParameters":[{"id":565,"name":"O","kind":131072,"kindString":"Type parameter","flags":{},"type":{"type":"reference","id":556,"name":"IOPayload"}}]},{"id":572,"name":"SpawnOptions","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":573,"name":"cwd","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Current working directory."}]},"sources":[{"fileName":"shell.ts","line":88,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L88"}],"type":{"type":"intrinsic","name":"string"}},{"id":575,"name":"encoding","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Character encoding for stdout/stderr"}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.1.0"}]}]},"sources":[{"fileName":"shell.ts","line":96,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L96"}],"type":{"type":"intrinsic","name":"string"}},{"id":574,"name":"env","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Environment variables. set to "},{"kind":"code","text":"`null`"},{"kind":"text","text":" to clear the process env."}]},"sources":[{"fileName":"shell.ts","line":90,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L90"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"string"}],"name":"Record","qualifiedName":"Record","package":"typescript"}}],"groups":[{"title":"Properties","children":[573,575,574]}],"sources":[{"fileName":"shell.ts","line":86,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L86"}]},{"id":560,"name":"TerminatedPayload","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Payload for the "},{"kind":"code","text":"`Terminated`"},{"kind":"text","text":" command event."}]},"children":[{"id":561,"name":"code","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Exit code of the process. "},{"kind":"code","text":"`null`"},{"kind":"text","text":" if the process was terminated by a signal on Unix."}]},"sources":[{"fileName":"shell.ts","line":615,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L615"}],"type":{"type":"union","types":[{"type":"literal","value":null},{"type":"intrinsic","name":"number"}]}},{"id":562,"name":"signal","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"If the process was terminated by a signal, represents that signal."}]},"sources":[{"fileName":"shell.ts","line":617,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L617"}],"type":{"type":"union","types":[{"type":"literal","value":null},{"type":"intrinsic","name":"number"}]}}],"groups":[{"title":"Properties","children":[561,562]}],"sources":[{"fileName":"shell.ts","line":613,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L613"}]},{"id":556,"name":"IOPayload","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[{"kind":"text","text":"Event payload type"}]},"sources":[{"fileName":"shell.ts","line":621,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L621"}],"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","name":"Uint8Array","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array","qualifiedName":"Uint8Array","package":"typescript"}]}},{"id":552,"name":"open","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"shell.ts","line":656,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L656"}],"signatures":[{"id":553,"name":"open","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Opens a path or URL with the system's default app,\nor the one specified with "},{"kind":"code","text":"`openWith`"},{"kind":"text","text":".\n\nThe "},{"kind":"code","text":"`openWith`"},{"kind":"text","text":" value must be one of "},{"kind":"code","text":"`firefox`"},{"kind":"text","text":", "},{"kind":"code","text":"`google chrome`"},{"kind":"text","text":", "},{"kind":"code","text":"`chromium`"},{"kind":"text","text":" "},{"kind":"code","text":"`safari`"},{"kind":"text","text":",\n"},{"kind":"code","text":"`open`"},{"kind":"text","text":", "},{"kind":"code","text":"`start`"},{"kind":"text","text":", "},{"kind":"code","text":"`xdg-open`"},{"kind":"text","text":", "},{"kind":"code","text":"`gio`"},{"kind":"text","text":", "},{"kind":"code","text":"`gnome-open`"},{"kind":"text","text":", "},{"kind":"code","text":"`kde-open`"},{"kind":"text","text":" or "},{"kind":"code","text":"`wslview`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { open } from '@tauri-apps/api/shell';\n// opens the given URL on the default browser:\nawait open('https://github.com/tauri-apps/tauri');\n// opens the given URL using `firefox`:\nawait open('https://github.com/tauri-apps/tauri', 'firefox');\n// opens a file using the default program:\nawait open('/path/to/file');\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":554,"name":"path","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The path or URL to open.\nThis value is matched against the string regex defined on "},{"kind":"code","text":"`tauri.conf.json > tauri > allowlist > shell > open`"},{"kind":"text","text":",\nwhich defaults to "},{"kind":"code","text":"`^((mailto:\\w+)|(tel:\\w+)|(https?://\\w+)).+`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":555,"name":"openWith","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The app to open the file or URL with.\nDefaults to the system default application for the specified path type."}]},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Classes","children":[464,347,474]},{"title":"Interfaces","children":[566,557,563,572,560]},{"title":"Type Aliases","children":[556]},{"title":"Functions","children":[552]}],"sources":[{"fileName":"shell.ts","line":80,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/shell.ts#L80"}]},{"id":576,"name":"tauri","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Invoke your custom commands.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.tauri`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":"."}]},"children":[{"id":577,"name":"InvokeArgs","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[{"kind":"text","text":"Command arguments."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"sources":[{"fileName":"tauri.ts","line":63,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/tauri.ts#L63"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"intrinsic","name":"unknown"}],"name":"Record","qualifiedName":"Record","package":"typescript"}},{"id":590,"name":"convertFileSrc","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"tauri.ts","line":129,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/tauri.ts#L129"}],"signatures":[{"id":591,"name":"convertFileSrc","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Convert a device file path to an URL that can be loaded by the webview.\nNote that "},{"kind":"code","text":"`asset:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`https://asset.localhost`"},{"kind":"text","text":" must be added to ["},{"kind":"code","text":"`tauri.security.csp`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#securityconfig.csp) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":".\nExample CSP value: "},{"kind":"code","text":"`\"csp\": \"default-src 'self'; img-src 'self' asset: https://asset.localhost\"`"},{"kind":"text","text":" to use the asset protocol on image sources.\n\nAdditionally, "},{"kind":"code","text":"`asset`"},{"kind":"text","text":" must be added to ["},{"kind":"code","text":"`tauri.allowlist.protocol`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.protocol)\nin "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" and its access scope must be defined on the "},{"kind":"code","text":"`assetScope`"},{"kind":"text","text":" array on the same "},{"kind":"code","text":"`protocol`"},{"kind":"text","text":" object."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appDataDir, join } from '@tauri-apps/api/path';\nimport { convertFileSrc } from '@tauri-apps/api/tauri';\nconst appDataDirPath = await appDataDir();\nconst filePath = await join(appDataDirPath, 'assets/video.mp4');\nconst assetUrl = convertFileSrc(filePath);\n\nconst video = document.getElementById('my-video');\nconst source = document.createElement('source');\nsource.type = 'video/mp4';\nsource.src = assetUrl;\nvideo.appendChild(source);\nvideo.load();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"the URL that can be used as source on the webview."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":592,"name":"filePath","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The file path."}]},"type":{"type":"intrinsic","name":"string"}},{"id":593,"name":"protocol","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The protocol to use. Defaults to "},{"kind":"code","text":"`asset`"},{"kind":"text","text":". You only need to set this when using a custom protocol."}]},"type":{"type":"intrinsic","name":"string"},"defaultValue":"'asset'"}],"type":{"type":"intrinsic","name":"string"}}]},{"id":585,"name":"invoke","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"tauri.ts","line":79,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/tauri.ts#L79"}],"signatures":[{"id":586,"name":"invoke","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sends a message to the backend."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { invoke } from '@tauri-apps/api/tauri';\nawait invoke('login', { user: 'tauri', password: 'poiwe3h4r5ip3yrhtew9ty' });\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving or rejecting to the backend response."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"typeParameter":[{"id":587,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":588,"name":"cmd","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The command name."}]},"type":{"type":"intrinsic","name":"string"}},{"id":589,"name":"args","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The optional arguments to pass to the command."}]},"type":{"type":"reference","id":577,"name":"InvokeArgs"},"defaultValue":"{}"}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":587,"name":"T"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":578,"name":"transformCallback","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"tauri.ts","line":36,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/tauri.ts#L36"}],"signatures":[{"id":579,"name":"transformCallback","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Transforms a callback function to a string identifier that can be passed to the backend.\nThe backend uses the identifier to "},{"kind":"code","text":"`eval()`"},{"kind":"text","text":" the callback."}],"blockTags":[{"tag":"@returns","content":[{"kind":"text","text":"A unique identifier associated with the callback function."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"parameters":[{"id":580,"name":"callback","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"type":{"type":"reflection","declaration":{"id":581,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"tauri.ts","line":37,"character":13,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/tauri.ts#L37"}],"signatures":[{"id":582,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":583,"name":"response","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"any"}}],"type":{"type":"intrinsic","name":"void"}}]}}},{"id":584,"name":"once","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"boolean"},"defaultValue":"false"}],"type":{"type":"intrinsic","name":"number"}}]}],"groups":[{"title":"Type Aliases","children":[577]},{"title":"Functions","children":[590,585,578]}],"sources":[{"fileName":"tauri.ts","line":13,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/tauri.ts#L13"}]},{"id":594,"name":"updater","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Customize the auto updater flow.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.updater`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":"."}]},"children":[{"id":599,"name":"UpdateManifest","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":602,"name":"body","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"updater.ts","line":34,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L34"}],"type":{"type":"intrinsic","name":"string"}},{"id":601,"name":"date","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"updater.ts","line":33,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L33"}],"type":{"type":"intrinsic","name":"string"}},{"id":600,"name":"version","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"updater.ts","line":32,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L32"}],"type":{"type":"intrinsic","name":"string"}}],"groups":[{"title":"Properties","children":[602,601,600]}],"sources":[{"fileName":"updater.ts","line":31,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L31"}]},{"id":603,"name":"UpdateResult","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":604,"name":"manifest","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"updater.ts","line":41,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L41"}],"type":{"type":"reference","id":599,"name":"UpdateManifest"}},{"id":605,"name":"shouldUpdate","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"updater.ts","line":42,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L42"}],"type":{"type":"intrinsic","name":"boolean"}}],"groups":[{"title":"Properties","children":[604,605]}],"sources":[{"fileName":"updater.ts","line":40,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L40"}]},{"id":596,"name":"UpdateStatusResult","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":597,"name":"error","kind":1024,"kindString":"Property","flags":{"isOptional":true},"sources":[{"fileName":"updater.ts","line":24,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L24"}],"type":{"type":"intrinsic","name":"string"}},{"id":598,"name":"status","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"updater.ts","line":25,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L25"}],"type":{"type":"reference","id":595,"name":"UpdateStatus"}}],"groups":[{"title":"Properties","children":[597,598]}],"sources":[{"fileName":"updater.ts","line":23,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L23"}]},{"id":595,"name":"UpdateStatus","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"sources":[{"fileName":"updater.ts","line":18,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L18"}],"type":{"type":"union","types":[{"type":"literal","value":"PENDING"},{"type":"literal","value":"ERROR"},{"type":"literal","value":"DONE"},{"type":"literal","value":"UPTODATE"}]}},{"id":614,"name":"checkUpdate","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"updater.ts","line":146,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L146"}],"signatures":[{"id":615,"name":"checkUpdate","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Checks if an update is available."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { checkUpdate } from '@tauri-apps/api/updater';\nconst update = await checkUpdate();\n// now run installUpdate() if needed\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"Promise resolving to the update status."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":603,"name":"UpdateResult"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":612,"name":"installUpdate","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"updater.ts","line":87,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L87"}],"signatures":[{"id":613,"name":"installUpdate","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Install the update if there's one available."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { checkUpdate, installUpdate } from '@tauri-apps/api/updater';\nconst update = await checkUpdate();\nif (update.shouldUpdate) {\n console.log(`Installing update ${update.manifest?.version}, ${update.manifest?.date}, ${update.manifest.body}`);\n await installUpdate();\n}\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":606,"name":"onUpdaterEvent","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"updater.ts","line":63,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L63"}],"signatures":[{"id":607,"name":"onUpdaterEvent","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to an updater event."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { onUpdaterEvent } from \"@tauri-apps/api/updater\";\nconst unlisten = await onUpdaterEvent(({ error, status }) => {\n console.log('Updater event', error, status);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":608,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":609,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"updater.ts","line":64,"character":11,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L64"}],"signatures":[{"id":610,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":611,"name":"status","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":596,"name":"UpdateStatusResult"}}],"type":{"type":"intrinsic","name":"void"}}]}}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1086,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Interfaces","children":[599,603,596]},{"title":"Type Aliases","children":[595]},{"title":"Functions","children":[614,612,606]}],"sources":[{"fileName":"updater.ts","line":12,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/updater.ts#L12"}]},{"id":616,"name":"window","kind":2,"kindString":"Module","flags":{},"comment":{"summary":[{"kind":"text","text":"Provides APIs to create windows, communicate with other windows and manipulate the current window.\n\nThis package is also accessible with "},{"kind":"code","text":"`window.__TAURI__.window`"},{"kind":"text","text":" when ["},{"kind":"code","text":"`build.withGlobalTauri`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":" is set to "},{"kind":"code","text":"`true`"},{"kind":"text","text":".\n\nThe APIs must be added to ["},{"kind":"code","text":"`tauri.allowlist.window`"},{"kind":"text","text":"](https://tauri.app/v1/api/config/#allowlistconfig.window) in "},{"kind":"code","text":"`tauri.conf.json`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```json\n{\n \"tauri\": {\n \"allowlist\": {\n \"window\": {\n \"all\": true, // enable all window APIs\n \"create\": true, // enable window creation\n \"center\": true,\n \"requestUserAttention\": true,\n \"setResizable\": true,\n \"setTitle\": true,\n \"maximize\": true,\n \"unmaximize\": true,\n \"minimize\": true,\n \"unminimize\": true,\n \"show\": true,\n \"hide\": true,\n \"close\": true,\n \"setDecorations\": true,\n \"setShadow\": true,\n \"setAlwaysOnTop\": true,\n \"setContentProtected\": true,\n \"setSize\": true,\n \"setMinSize\": true,\n \"setMaxSize\": true,\n \"setPosition\": true,\n \"setFullscreen\": true,\n \"setFocus\": true,\n \"setIcon\": true,\n \"setSkipTaskbar\": true,\n \"setCursorGrab\": true,\n \"setCursorVisible\": true,\n \"setCursorIcon\": true,\n \"setCursorPosition\": true,\n \"setIgnoreCursorEvents\": true,\n \"startDragging\": true,\n \"print\": true\n }\n }\n }\n}\n```"},{"kind":"text","text":"\nIt is recommended to allowlist only the APIs you use for optimal bundle size and security.\n\n## Window events\n\nEvents can be listened to using "},{"kind":"code","text":"`appWindow.listen`"},{"kind":"text","text":":\n"},{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nappWindow.listen(\"my-window-event\", ({ event, payload }) => { });\n```"}]},"children":[{"id":1017,"name":"UserAttentionType","kind":8,"kindString":"Enumeration","flags":{},"comment":{"summary":[{"kind":"text","text":"Attention type to request on a window."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":1018,"name":"Critical","kind":16,"kindString":"Enumeration Member","flags":{},"comment":{"summary":[{"kind":"text","text":"#### Platform-specific\n- **macOS:** Bounces the dock icon until the application is in focus.\n- **Windows:** Flashes both the window and the taskbar button until the application is in focus."}]},"sources":[{"fileName":"window.ts","line":226,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L226"}],"type":{"type":"literal","value":1}},{"id":1019,"name":"Informational","kind":16,"kindString":"Enumeration Member","flags":{},"comment":{"summary":[{"kind":"text","text":"#### Platform-specific\n- **macOS:** Bounces the dock icon once.\n- **Windows:** Flashes the taskbar button until the application is in focus."}]},"sources":[{"fileName":"window.ts","line":232,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L232"}],"type":{"type":"literal","value":2}}],"groups":[{"title":"Enumeration Members","children":[1018,1019]}],"sources":[{"fileName":"window.ts","line":220,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L220"}]},{"id":962,"name":"CloseRequestedEvent","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"children":[{"id":963,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"sources":[{"fileName":"window.ts","line":1963,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1963"}],"signatures":[{"id":964,"name":"new CloseRequestedEvent","kind":16384,"kindString":"Constructor signature","flags":{},"parameters":[{"id":965,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1075,"typeArguments":[{"type":"literal","value":null}],"name":"Event"}}],"type":{"type":"reference","id":962,"name":"CloseRequestedEvent"}}]},{"id":969,"name":"_preventDefault","kind":1024,"kindString":"Property","flags":{"isPrivate":true},"sources":[{"fileName":"window.ts","line":1961,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1961"}],"type":{"type":"intrinsic","name":"boolean"},"defaultValue":"false"},{"id":966,"name":"event","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name"}]},"sources":[{"fileName":"window.ts","line":1956,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1956"}],"type":{"type":"reference","id":63,"name":"EventName"}},{"id":968,"name":"id","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Event identifier used to unlisten"}]},"sources":[{"fileName":"window.ts","line":1960,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1960"}],"type":{"type":"intrinsic","name":"number"}},{"id":967,"name":"windowLabel","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The label of the window that emitted this event."}]},"sources":[{"fileName":"window.ts","line":1958,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1958"}],"type":{"type":"intrinsic","name":"string"}},{"id":972,"name":"isPreventDefault","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1973,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1973"}],"signatures":[{"id":973,"name":"isPreventDefault","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"intrinsic","name":"boolean"}}]},{"id":970,"name":"preventDefault","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1969,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1969"}],"signatures":[{"id":971,"name":"preventDefault","kind":4096,"kindString":"Call signature","flags":{},"type":{"type":"intrinsic","name":"void"}}]}],"groups":[{"title":"Constructors","children":[963]},{"title":"Properties","children":[969,966,968,967]},{"title":"Methods","children":[972,970]}],"sources":[{"fileName":"window.ts","line":1954,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1954"}]},{"id":998,"name":"LogicalPosition","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"A position represented in logical pixels."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":999,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"sources":[{"fileName":"window.ts","line":164,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L164"}],"signatures":[{"id":1000,"name":"new LogicalPosition","kind":16384,"kindString":"Constructor signature","flags":{},"parameters":[{"id":1001,"name":"x","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}},{"id":1002,"name":"y","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}}],"type":{"type":"reference","id":998,"name":"LogicalPosition"}}]},{"id":1003,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":160,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L160"}],"type":{"type":"intrinsic","name":"string"},"defaultValue":"'Logical'"},{"id":1004,"name":"x","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":161,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L161"}],"type":{"type":"intrinsic","name":"number"}},{"id":1005,"name":"y","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":162,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L162"}],"type":{"type":"intrinsic","name":"number"}}],"groups":[{"title":"Constructors","children":[999]},{"title":"Properties","children":[1003,1004,1005]}],"sources":[{"fileName":"window.ts","line":159,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L159"}]},{"id":979,"name":"LogicalSize","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"A size represented in logical pixels."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":980,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"sources":[{"fileName":"window.ts","line":118,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L118"}],"signatures":[{"id":981,"name":"new LogicalSize","kind":16384,"kindString":"Constructor signature","flags":{},"parameters":[{"id":982,"name":"width","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}},{"id":983,"name":"height","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}}],"type":{"type":"reference","id":979,"name":"LogicalSize"}}]},{"id":986,"name":"height","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":116,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L116"}],"type":{"type":"intrinsic","name":"number"}},{"id":984,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":114,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L114"}],"type":{"type":"intrinsic","name":"string"},"defaultValue":"'Logical'"},{"id":985,"name":"width","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":115,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L115"}],"type":{"type":"intrinsic","name":"number"}}],"groups":[{"title":"Constructors","children":[980]},{"title":"Properties","children":[986,984,985]}],"sources":[{"fileName":"window.ts","line":113,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L113"}]},{"id":1006,"name":"PhysicalPosition","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"A position represented in physical pixels."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":1007,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"sources":[{"fileName":"window.ts","line":180,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L180"}],"signatures":[{"id":1008,"name":"new PhysicalPosition","kind":16384,"kindString":"Constructor signature","flags":{},"parameters":[{"id":1009,"name":"x","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}},{"id":1010,"name":"y","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}}],"type":{"type":"reference","id":1006,"name":"PhysicalPosition"}}]},{"id":1011,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":176,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L176"}],"type":{"type":"intrinsic","name":"string"},"defaultValue":"'Physical'"},{"id":1012,"name":"x","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":177,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L177"}],"type":{"type":"intrinsic","name":"number"}},{"id":1013,"name":"y","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":178,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L178"}],"type":{"type":"intrinsic","name":"number"}},{"id":1014,"name":"toLogical","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":195,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L195"}],"signatures":[{"id":1015,"name":"toLogical","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Converts the physical position to a logical one."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst factor = await appWindow.scaleFactor();\nconst position = await appWindow.innerPosition();\nconst logical = position.toLogical(factor);\n```"}]}]},"parameters":[{"id":1016,"name":"scaleFactor","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}}],"type":{"type":"reference","id":998,"name":"LogicalPosition"}}]}],"groups":[{"title":"Constructors","children":[1007]},{"title":"Properties","children":[1011,1012,1013]},{"title":"Methods","children":[1014]}],"sources":[{"fileName":"window.ts","line":175,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L175"}]},{"id":987,"name":"PhysicalSize","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"A size represented in physical pixels."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":988,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"sources":[{"fileName":"window.ts","line":134,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L134"}],"signatures":[{"id":989,"name":"new PhysicalSize","kind":16384,"kindString":"Constructor signature","flags":{},"parameters":[{"id":990,"name":"width","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}},{"id":991,"name":"height","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}}],"type":{"type":"reference","id":987,"name":"PhysicalSize"}}]},{"id":994,"name":"height","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":132,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L132"}],"type":{"type":"intrinsic","name":"number"}},{"id":992,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":130,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L130"}],"type":{"type":"intrinsic","name":"string"},"defaultValue":"'Physical'"},{"id":993,"name":"width","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":131,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L131"}],"type":{"type":"intrinsic","name":"number"}},{"id":995,"name":"toLogical","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":149,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L149"}],"signatures":[{"id":996,"name":"toLogical","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Converts the physical size to a logical one."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst factor = await appWindow.scaleFactor();\nconst size = await appWindow.innerSize();\nconst logical = size.toLogical(factor);\n```"}]}]},"parameters":[{"id":997,"name":"scaleFactor","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"number"}}],"type":{"type":"reference","id":979,"name":"LogicalSize"}}]}],"groups":[{"title":"Constructors","children":[988]},{"title":"Properties","children":[994,992,993]},{"title":"Methods","children":[995]}],"sources":[{"fileName":"window.ts","line":129,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L129"}]},{"id":619,"name":"WebviewWindow","kind":128,"kindString":"Class","flags":{},"comment":{"summary":[{"kind":"text","text":"Create new webview windows and get a handle to existing ones.\n\nWindows are identified by a *label* a unique identifier that can be used to reference it later.\nIt may only contain alphanumeric characters "},{"kind":"code","text":"`a-zA-Z`"},{"kind":"text","text":" plus the following special characters "},{"kind":"code","text":"`-`"},{"kind":"text","text":", "},{"kind":"code","text":"`/`"},{"kind":"text","text":", "},{"kind":"code","text":"`:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`_`"},{"kind":"text","text":"."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\n// loading embedded asset:\nconst webview = new WebviewWindow('theUniqueLabel', {\n url: 'path/to/page.html'\n});\n// alternatively, load a remote URL:\nconst webview = new WebviewWindow('theUniqueLabel', {\n url: 'https://github.com/tauri-apps/tauri'\n});\n\nwebview.once('tauri://created', function () {\n // webview window successfully created\n});\nwebview.once('tauri://error', function (e) {\n // an error happened creating the webview window\n});\n\n// emit an event to the backend\nawait webview.emit(\"some event\", \"data\");\n// listen to an event from the backend\nconst unlisten = await webview.listen(\"event name\", e => {});\nunlisten();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"children":[{"id":623,"name":"constructor","kind":512,"kindString":"Constructor","flags":{},"sources":[{"fileName":"window.ts","line":2031,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2031"}],"signatures":[{"id":624,"name":"new WebviewWindow","kind":16384,"kindString":"Constructor signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Creates a new WebviewWindow."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { WebviewWindow } from '@tauri-apps/api/window';\nconst webview = new WebviewWindow('my-label', {\n url: 'https://github.com/tauri-apps/tauri'\n});\nwebview.once('tauri://created', function () {\n // webview window successfully created\n});\nwebview.once('tauri://error', function (e) {\n // an error happened creating the webview window\n});\n```"},{"kind":"text","text":"\n\n*"}]},{"tag":"@returns","content":[{"kind":"text","text":"The WebviewWindow instance to communicate with the webview."}]}]},"parameters":[{"id":625,"name":"label","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The unique webview window label. Must be alphanumeric: "},{"kind":"code","text":"`a-zA-Z-/:_`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":626,"name":"options","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1045,"name":"WindowOptions"},"defaultValue":"{}"}],"type":{"type":"reference","id":619,"name":"WebviewWindow"},"overwrites":{"type":"reference","name":"WindowManager.constructor"}}],"overwrites":{"type":"reference","name":"WindowManager.constructor"}},{"id":759,"name":"label","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The window label. It is a unique identifier for the window, can be used to reference it later."}]},"sources":[{"fileName":"window.ts","line":316,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L316"}],"type":{"type":"intrinsic","name":"string"},"inheritedFrom":{"type":"reference","name":"WindowManager.label"}},{"id":760,"name":"listeners","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Local event listeners."}]},"sources":[{"fileName":"window.ts","line":318,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L318"}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"},{"type":"array","elementType":{"type":"reference","id":1081,"typeArguments":[{"type":"intrinsic","name":"any"}],"name":"EventCallback"}}],"name":"Record","qualifiedName":"Record","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.listeners"}},{"id":653,"name":"center","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":780,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L780"}],"signatures":[{"id":654,"name":"center","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Centers the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.center();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.center"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.center"}},{"id":678,"name":"close","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1081,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1081"}],"signatures":[{"id":679,"name":"close","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Closes the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.close();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.close"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.close"}},{"id":771,"name":"emit","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":400,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L400"}],"signatures":[{"id":772,"name":"emit","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Emits an event to the backend, tied to the webview window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.emit('window-loaded', { loggedIn: true, token: 'authToken' });\n```"}]}]},"parameters":[{"id":773,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name. Must include only alphanumeric characters, "},{"kind":"code","text":"`-`"},{"kind":"text","text":", "},{"kind":"code","text":"`/`"},{"kind":"text","text":", "},{"kind":"code","text":"`:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`_`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":774,"name":"payload","kind":32768,"kindString":"Parameter","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Event payload."}]},"type":{"type":"intrinsic","name":"unknown"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.emit"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.emit"}},{"id":676,"name":"hide","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1056,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1056"}],"signatures":[{"id":677,"name":"hide","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window visibility to false."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.hide();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.hide"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.hide"}},{"id":629,"name":"innerPosition","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":470,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L470"}],"signatures":[{"id":630,"name":"innerPosition","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"The position of the top-left hand corner of the window's client area relative to the top-left hand corner of the desktop."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst position = await appWindow.innerPosition();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The window's inner position."}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":1006,"name":"PhysicalPosition"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.innerPosition"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.innerPosition"}},{"id":633,"name":"innerSize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":521,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L521"}],"signatures":[{"id":634,"name":"innerSize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"The physical size of the window's client area.\nThe client area is the content of the window, excluding the title bar and borders."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst size = await appWindow.innerSize();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The window's inner size."}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":987,"name":"PhysicalSize"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.innerSize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.innerSize"}},{"id":643,"name":"isDecorated","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":647,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L647"}],"signatures":[{"id":644,"name":"isDecorated","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current decorated state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst decorated = await appWindow.isDecorated();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"Whether the window is decorated or not."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.isDecorated"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.isDecorated"}},{"id":637,"name":"isFullscreen","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":572,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L572"}],"signatures":[{"id":638,"name":"isFullscreen","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current fullscreen state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst fullscreen = await appWindow.isFullscreen();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"Whether the window is in fullscreen mode or not."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.isFullscreen"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.isFullscreen"}},{"id":641,"name":"isMaximized","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":622,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L622"}],"signatures":[{"id":642,"name":"isMaximized","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current maximized state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst maximized = await appWindow.isMaximized();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"Whether the window is maximized or not."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.isMaximized"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.isMaximized"}},{"id":639,"name":"isMinimized","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":597,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L597"}],"signatures":[{"id":640,"name":"isMinimized","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current minimized state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst minimized = await appWindow.isMinimized();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.3.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.isMinimized"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.isMinimized"}},{"id":645,"name":"isResizable","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":672,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L672"}],"signatures":[{"id":646,"name":"isResizable","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current resizable state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst resizable = await appWindow.isResizable();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"Whether the window is resizable or not."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.isResizable"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.isResizable"}},{"id":647,"name":"isVisible","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":697,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L697"}],"signatures":[{"id":648,"name":"isVisible","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current visible state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst visible = await appWindow.isVisible();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"Whether the window is visible or not."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.isVisible"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.isVisible"}},{"id":761,"name":"listen","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":345,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L345"}],"signatures":[{"id":762,"name":"listen","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to an event emitted by the backend that is tied to the webview window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst unlisten = await appWindow.listen('state-changed', (event) => {\n console.log(`Got error: ${payload}`);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]}]},"typeParameter":[{"id":763,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":764,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name. Must include only alphanumeric characters, "},{"kind":"code","text":"`-`"},{"kind":"text","text":", "},{"kind":"code","text":"`/`"},{"kind":"text","text":", "},{"kind":"code","text":"`:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`_`"},{"kind":"text","text":"."}]},"type":{"type":"reference","id":63,"name":"EventName"}},{"id":765,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event handler."}]},"type":{"type":"reference","id":1081,"typeArguments":[{"type":"reference","id":763,"name":"T"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1086,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.listen"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.listen"}},{"id":664,"name":"maximize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":906,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L906"}],"signatures":[{"id":665,"name":"maximize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Maximizes the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.maximize();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.maximize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.maximize"}},{"id":670,"name":"minimize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":981,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L981"}],"signatures":[{"id":671,"name":"minimize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Minimizes the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.minimize();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.minimize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.minimize"}},{"id":738,"name":"onCloseRequested","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1763,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1763"}],"signatures":[{"id":739,"name":"onCloseRequested","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to window close requested. Emitted when the user requests to closes the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nimport { confirm } from '@tauri-apps/api/dialog';\nconst unlisten = await appWindow.onCloseRequested(async (event) => {\n const confirmed = await confirm('Are you sure?');\n if (!confirmed) {\n // user did not confirm closing the window; let's prevent it\n event.preventDefault();\n }\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":740,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reflection","declaration":{"id":741,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"sources":[{"fileName":"window.ts","line":1764,"character":13,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1764"}],"signatures":[{"id":742,"name":"__type","kind":4096,"kindString":"Call signature","flags":{},"parameters":[{"id":743,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":962,"name":"CloseRequestedEvent"}}],"type":{"type":"union","types":[{"type":"intrinsic","name":"void"},{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}]}}]}}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1086,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onCloseRequested"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onCloseRequested"}},{"id":753,"name":"onFileDropEvent","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1896,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1896"}],"signatures":[{"id":754,"name":"onFileDropEvent","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to a file drop event.\nThe listener is triggered when the user hovers the selected files on the window,\ndrops the files or cancels the operation."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nconst unlisten = await appWindow.onFileDropEvent((event) => {\n if (event.payload.type === 'hover') {\n console.log('User hovering', event.payload.paths);\n } else if (event.payload.type === 'drop') {\n console.log('User dropped', event.payload.paths);\n } else {\n console.log('File drop cancelled');\n }\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":755,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1081,"typeArguments":[{"type":"reference","id":1036,"name":"FileDropEvent"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1086,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onFileDropEvent"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onFileDropEvent"}},{"id":744,"name":"onFocusChanged","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1795,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1795"}],"signatures":[{"id":745,"name":"onFocusChanged","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to window focus change."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nconst unlisten = await appWindow.onFocusChanged(({ payload: focused }) => {\n console.log('Focus changed, window is focused? ' + focused);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":746,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1081,"typeArguments":[{"type":"intrinsic","name":"boolean"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1086,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onFocusChanged"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onFocusChanged"}},{"id":750,"name":"onMenuClicked","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1865,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1865"}],"signatures":[{"id":751,"name":"onMenuClicked","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to the window menu item click. The payload is the item id."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nconst unlisten = await appWindow.onMenuClicked(({ payload: menuId }) => {\n console.log('Menu clicked: ' + menuId);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":752,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1081,"typeArguments":[{"type":"intrinsic","name":"string"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1086,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onMenuClicked"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onMenuClicked"}},{"id":735,"name":"onMoved","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1735,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1735"}],"signatures":[{"id":736,"name":"onMoved","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to window move."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nconst unlisten = await appWindow.onMoved(({ payload: position }) => {\n console.log('Window moved', position);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":737,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1081,"typeArguments":[{"type":"reference","id":1006,"name":"PhysicalPosition"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1086,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onMoved"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onMoved"}},{"id":732,"name":"onResized","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1712,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1712"}],"signatures":[{"id":733,"name":"onResized","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to window resize."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nconst unlisten = await appWindow.onResized(({ payload: size }) => {\n console.log('Window resized', size);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":734,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1081,"typeArguments":[{"type":"reference","id":987,"name":"PhysicalSize"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1086,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onResized"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onResized"}},{"id":747,"name":"onScaleChanged","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1837,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1837"}],"signatures":[{"id":748,"name":"onScaleChanged","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to window scale change. Emitted when the window's scale factor has changed.\nThe following user actions can cause DPI changes:\n- Changing the display's resolution.\n- Changing the display's scale factor (e.g. in Control Panel on Windows).\n- Moving the window to a display with a different scale factor."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nconst unlisten = await appWindow.onScaleChanged(({ payload }) => {\n console.log('Scale changed', payload.scaleFactor, payload.size);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":749,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1081,"typeArguments":[{"type":"reference","id":1033,"name":"ScaleFactorChanged"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1086,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onScaleChanged"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onScaleChanged"}},{"id":756,"name":"onThemeChanged","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1946,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1946"}],"signatures":[{"id":757,"name":"onThemeChanged","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to the system theme change."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from \"@tauri-apps/api/window\";\nconst unlisten = await appWindow.onThemeChanged(({ payload: theme }) => {\n console.log('New theme: ' + theme);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"parameters":[{"id":758,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"reference","id":1081,"typeArguments":[{"type":"reference","id":1026,"name":"Theme"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1086,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.onThemeChanged"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.onThemeChanged"}},{"id":766,"name":"once","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":378,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L378"}],"signatures":[{"id":767,"name":"once","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Listen to an one-off event emitted by the backend that is tied to the webview window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst unlisten = await appWindow.once('initialized', (event) => {\n console.log(`Window initialized!`);\n});\n\n// you need to call unlisten if your handler goes out of scope e.g. the component is unmounted\nunlisten();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise resolving to a function to unlisten to the event.\nNote that removing the listener is required if your listener goes out of scope e.g. the component is unmounted."}]}]},"typeParameter":[{"id":768,"name":"T","kind":131072,"kindString":"Type parameter","flags":{}}],"parameters":[{"id":769,"name":"event","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event name. Must include only alphanumeric characters, "},{"kind":"code","text":"`-`"},{"kind":"text","text":", "},{"kind":"code","text":"`/`"},{"kind":"text","text":", "},{"kind":"code","text":"`:`"},{"kind":"text","text":" and "},{"kind":"code","text":"`_`"},{"kind":"text","text":"."}]},"type":{"type":"intrinsic","name":"string"}},{"id":770,"name":"handler","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Event handler."}]},"type":{"type":"reference","id":1081,"typeArguments":[{"type":"reference","id":768,"name":"T"}],"name":"EventCallback"}}],"type":{"type":"reference","typeArguments":[{"type":"reference","id":1086,"name":"UnlistenFn"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.once"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.once"}},{"id":631,"name":"outerPosition","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":495,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L495"}],"signatures":[{"id":632,"name":"outerPosition","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"The position of the top-left hand corner of the window relative to the top-left hand corner of the desktop."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst position = await appWindow.outerPosition();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The window's outer position."}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":1006,"name":"PhysicalPosition"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.outerPosition"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.outerPosition"}},{"id":635,"name":"outerSize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":547,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L547"}],"signatures":[{"id":636,"name":"outerSize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"The physical size of the entire window.\nThese dimensions include the title bar and borders. If you don't want that (and you usually don't), use inner_size instead."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst size = await appWindow.outerSize();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The window's outer size."}]}]},"type":{"type":"reference","typeArguments":[{"type":"reference","id":987,"name":"PhysicalSize"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.outerSize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.outerSize"}},{"id":655,"name":"requestUserAttention","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":816,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L816"}],"signatures":[{"id":656,"name":"requestUserAttention","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Requests user attention to the window, this has no effect if the application\nis already focused. How requesting for user attention manifests is platform dependent,\nsee "},{"kind":"code","text":"`UserAttentionType`"},{"kind":"text","text":" for details.\n\nProviding "},{"kind":"code","text":"`null`"},{"kind":"text","text":" will unset the request for user attention. Unsetting the request for\nuser attention might not be done automatically by the WM when the window receives input.\n\n#### Platform-specific\n\n- **macOS:** "},{"kind":"code","text":"`null`"},{"kind":"text","text":" has no effect.\n- **Linux:** Urgency levels have the same effect."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.requestUserAttention();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":657,"name":"requestType","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"union","types":[{"type":"literal","value":null},{"type":"reference","id":1017,"name":"UserAttentionType"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.requestUserAttention"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.requestUserAttention"}},{"id":627,"name":"scaleFactor","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":445,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L445"}],"signatures":[{"id":628,"name":"scaleFactor","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"The scale factor that can be used to map physical pixels to logical pixels."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst factor = await appWindow.scaleFactor();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The window's monitor scale factor."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"number"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.scaleFactor"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.scaleFactor"}},{"id":686,"name":"setAlwaysOnTop","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1171,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1171"}],"signatures":[{"id":687,"name":"setAlwaysOnTop","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Whether the window should always be on top of other windows."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setAlwaysOnTop(true);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":688,"name":"alwaysOnTop","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Whether the window should always be on top of other windows or not."}]},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setAlwaysOnTop"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setAlwaysOnTop"}},{"id":689,"name":"setContentProtected","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1199,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1199"}],"signatures":[{"id":690,"name":"setContentProtected","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Prevents the window contents from being captured by other apps."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setContentProtected(true);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]},{"tag":"@since","content":[{"kind":"text","text":"1.2.0"}]}]},"parameters":[{"id":691,"name":"protected_","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setContentProtected"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setContentProtected"}},{"id":715,"name":"setCursorGrab","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1519,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1519"}],"signatures":[{"id":716,"name":"setCursorGrab","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Grabs the cursor, preventing it from leaving the window.\n\nThere's no guarantee that the cursor will be hidden. You should\nhide it by yourself if you want so.\n\n#### Platform-specific\n\n- **Linux:** Unsupported.\n- **macOS:** This locks the cursor in a fixed location, which looks visually awkward."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setCursorGrab(true);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":717,"name":"grab","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"code","text":"`true`"},{"kind":"text","text":" to grab the cursor icon, "},{"kind":"code","text":"`false`"},{"kind":"text","text":" to release it."}]},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorGrab"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorGrab"}},{"id":721,"name":"setCursorIcon","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1579,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1579"}],"signatures":[{"id":722,"name":"setCursorIcon","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Modifies the cursor icon of the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setCursorIcon('help');\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":723,"name":"icon","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The new cursor icon."}]},"type":{"type":"reference","id":617,"name":"CursorIcon"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorIcon"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorIcon"}},{"id":724,"name":"setCursorPosition","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1606,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1606"}],"signatures":[{"id":725,"name":"setCursorPosition","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Changes the position of the cursor in window coordinates."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow, LogicalPosition } from '@tauri-apps/api/window';\nawait appWindow.setCursorPosition(new LogicalPosition(600, 300));\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":726,"name":"position","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The new cursor position."}]},"type":{"type":"union","types":[{"type":"reference","id":1006,"name":"PhysicalPosition"},{"type":"reference","id":998,"name":"LogicalPosition"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorPosition"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorPosition"}},{"id":718,"name":"setCursorVisible","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1552,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1552"}],"signatures":[{"id":719,"name":"setCursorVisible","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Modifies the cursor's visibility.\n\n#### Platform-specific\n\n- **Windows:** The cursor is only hidden within the confines of the window.\n- **macOS:** The cursor is hidden as long as the window has input focus, even if the cursor is\n outside of the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setCursorVisible(false);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":720,"name":"visible","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"If "},{"kind":"code","text":"`false`"},{"kind":"text","text":", this will hide the cursor. If "},{"kind":"code","text":"`true`"},{"kind":"text","text":", this will show the cursor."}]},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorVisible"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setCursorVisible"}},{"id":680,"name":"setDecorations","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1107,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1107"}],"signatures":[{"id":681,"name":"setDecorations","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Whether the window should have borders and bars."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setDecorations(false);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":682,"name":"decorations","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Whether the window should have borders and bars."}]},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setDecorations"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setDecorations"}},{"id":707,"name":"setFocus","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1417,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1417"}],"signatures":[{"id":708,"name":"setFocus","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Bring the window to front and focus."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setFocus();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setFocus"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setFocus"}},{"id":704,"name":"setFullscreen","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1391,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1391"}],"signatures":[{"id":705,"name":"setFullscreen","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window fullscreen state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setFullscreen(true);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":706,"name":"fullscreen","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Whether the window should go to fullscreen or not."}]},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setFullscreen"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setFullscreen"}},{"id":709,"name":"setIcon","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1450,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1450"}],"signatures":[{"id":710,"name":"setIcon","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window icon."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setIcon('/tauri/awesome.png');\n```"},{"kind":"text","text":"\n\nNote that you need the "},{"kind":"code","text":"`icon-ico`"},{"kind":"text","text":" or "},{"kind":"code","text":"`icon-png`"},{"kind":"text","text":" Cargo features to use this API.\nTo enable it, change your Cargo.toml file:\n"},{"kind":"code","text":"```toml\n[dependencies]\ntauri = { version = \"...\", features = [\"...\", \"icon-png\"] }\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":711,"name":"icon","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"Icon bytes or path to the icon file."}]},"type":{"type":"union","types":[{"type":"intrinsic","name":"string"},{"type":"reference","name":"Uint8Array","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array","qualifiedName":"Uint8Array","package":"typescript"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setIcon"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setIcon"}},{"id":727,"name":"setIgnoreCursorEvents","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1650,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1650"}],"signatures":[{"id":728,"name":"setIgnoreCursorEvents","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Changes the cursor events behavior."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setIgnoreCursorEvents(true);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":729,"name":"ignore","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"code","text":"`true`"},{"kind":"text","text":" to ignore the cursor events; "},{"kind":"code","text":"`false`"},{"kind":"text","text":" to process them as usual."}]},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setIgnoreCursorEvents"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setIgnoreCursorEvents"}},{"id":698,"name":"setMaxSize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1306,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1306"}],"signatures":[{"id":699,"name":"setMaxSize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window maximum inner size. If the "},{"kind":"code","text":"`size`"},{"kind":"text","text":" argument is undefined, the constraint is unset."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow, LogicalSize } from '@tauri-apps/api/window';\nawait appWindow.setMaxSize(new LogicalSize(600, 500));\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":700,"name":"size","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The logical or physical inner size, or "},{"kind":"code","text":"`null`"},{"kind":"text","text":" to unset the constraint."}]},"type":{"type":"union","types":[{"type":"intrinsic","name":"undefined"},{"type":"literal","value":null},{"type":"reference","id":987,"name":"PhysicalSize"},{"type":"reference","id":979,"name":"LogicalSize"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setMaxSize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setMaxSize"}},{"id":695,"name":"setMinSize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1264,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1264"}],"signatures":[{"id":696,"name":"setMinSize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window minimum inner size. If the "},{"kind":"code","text":"`size`"},{"kind":"text","text":" argument is not provided, the constraint is unset."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow, PhysicalSize } from '@tauri-apps/api/window';\nawait appWindow.setMinSize(new PhysicalSize(600, 500));\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":697,"name":"size","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The logical or physical inner size, or "},{"kind":"code","text":"`null`"},{"kind":"text","text":" to unset the constraint."}]},"type":{"type":"union","types":[{"type":"intrinsic","name":"undefined"},{"type":"literal","value":null},{"type":"reference","id":987,"name":"PhysicalSize"},{"type":"reference","id":979,"name":"LogicalSize"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setMinSize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setMinSize"}},{"id":701,"name":"setPosition","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1348,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1348"}],"signatures":[{"id":702,"name":"setPosition","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window outer position."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow, LogicalPosition } from '@tauri-apps/api/window';\nawait appWindow.setPosition(new LogicalPosition(600, 500));\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":703,"name":"position","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The new position, in logical or physical pixels."}]},"type":{"type":"union","types":[{"type":"reference","id":1006,"name":"PhysicalPosition"},{"type":"reference","id":998,"name":"LogicalPosition"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setPosition"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setPosition"}},{"id":658,"name":"setResizable","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":853,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L853"}],"signatures":[{"id":659,"name":"setResizable","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Updates the window resizable flag."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setResizable(false);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":660,"name":"resizable","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setResizable"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setResizable"}},{"id":683,"name":"setShadow","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1144,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1144"}],"signatures":[{"id":684,"name":"setShadow","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Whether or not the window should have shadow.\n\n#### Platform-specific\n\n- **Windows:**\n - "},{"kind":"code","text":"`false`"},{"kind":"text","text":" has no effect on decorated window, shadows are always ON.\n - "},{"kind":"code","text":"`true`"},{"kind":"text","text":" will make ndecorated window have a 1px white border,\nand on Windows 11, it will have a rounded corners.\n- **Linux:** Unsupported."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setShadow(false);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]},{"tag":"@since","content":[{"kind":"text","text":"2.0"}]}]},"parameters":[{"id":685,"name":"enable","kind":32768,"kindString":"Parameter","flags":{},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setShadow"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setShadow"}},{"id":692,"name":"setSize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1226,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1226"}],"signatures":[{"id":693,"name":"setSize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Resizes the window with a new inner size."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow, LogicalSize } from '@tauri-apps/api/window';\nawait appWindow.setSize(new LogicalSize(600, 500));\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":694,"name":"size","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The logical or physical inner size."}]},"type":{"type":"union","types":[{"type":"reference","id":987,"name":"PhysicalSize"},{"type":"reference","id":979,"name":"LogicalSize"}]}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setSize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setSize"}},{"id":712,"name":"setSkipTaskbar","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1484,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1484"}],"signatures":[{"id":713,"name":"setSkipTaskbar","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Whether the window icon should be hidden from the taskbar or not.\n\n#### Platform-specific\n\n- **macOS:** Unsupported."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setSkipTaskbar(true);\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":714,"name":"skip","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"true to hide window icon, false to show it."}]},"type":{"type":"intrinsic","name":"boolean"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setSkipTaskbar"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setSkipTaskbar"}},{"id":661,"name":"setTitle","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":880,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L880"}],"signatures":[{"id":662,"name":"setTitle","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window title."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.setTitle('Tauri');\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"parameters":[{"id":663,"name":"title","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The new title"}]},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.setTitle"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.setTitle"}},{"id":674,"name":"show","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1031,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1031"}],"signatures":[{"id":675,"name":"show","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Sets the window visibility to true."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.show();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.show"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.show"}},{"id":730,"name":"startDragging","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1676,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1676"}],"signatures":[{"id":731,"name":"startDragging","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Starts dragging the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.startDragging();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.startDragging"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.startDragging"}},{"id":651,"name":"theme","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":752,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L752"}],"signatures":[{"id":652,"name":"theme","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current theme.\n\n#### Platform-specific\n\n- **macOS:** Theme was introduced on macOS 10.14. Returns "},{"kind":"code","text":"`light`"},{"kind":"text","text":" on macOS 10.13 and below."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst theme = await appWindow.theme();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The window theme."}]}]},"type":{"type":"reference","typeArguments":[{"type":"union","types":[{"type":"literal","value":null},{"type":"reference","id":1026,"name":"Theme"}]}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.theme"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.theme"}},{"id":649,"name":"title","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":722,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L722"}],"signatures":[{"id":650,"name":"title","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the window's current title."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nconst title = await appWindow.title();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.3.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"string"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.title"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.title"}},{"id":668,"name":"toggleMaximize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":956,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L956"}],"signatures":[{"id":669,"name":"toggleMaximize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Toggles the window maximized state."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.toggleMaximize();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.toggleMaximize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.toggleMaximize"}},{"id":666,"name":"unmaximize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":931,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L931"}],"signatures":[{"id":667,"name":"unmaximize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Unmaximizes the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.unmaximize();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.unmaximize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.unmaximize"}},{"id":672,"name":"unminimize","kind":2048,"kindString":"Method","flags":{},"sources":[{"fileName":"window.ts","line":1006,"character":8,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L1006"}],"signatures":[{"id":673,"name":"unminimize","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Unminimizes the window."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { appWindow } from '@tauri-apps/api/window';\nawait appWindow.unminimize();\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"A promise indicating the success or failure of the operation."}]}]},"type":{"type":"reference","typeArguments":[{"type":"intrinsic","name":"void"}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"},"inheritedFrom":{"type":"reference","name":"WindowManager.unminimize"}}],"inheritedFrom":{"type":"reference","name":"WindowManager.unminimize"}},{"id":620,"name":"getByLabel","kind":2048,"kindString":"Method","flags":{"isStatic":true},"sources":[{"fileName":"window.ts","line":2063,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2063"}],"signatures":[{"id":621,"name":"getByLabel","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets the WebviewWindow for the webview associated with the given label."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { WebviewWindow } from '@tauri-apps/api/window';\nconst mainWindow = WebviewWindow.getByLabel('main');\n```"}]},{"tag":"@returns","content":[{"kind":"text","text":"The WebviewWindow instance to communicate with the webview or null if the webview doesn't exist."}]}]},"parameters":[{"id":622,"name":"label","kind":32768,"kindString":"Parameter","flags":{},"comment":{"summary":[{"kind":"text","text":"The webview window label."}]},"type":{"type":"intrinsic","name":"string"}}],"type":{"type":"union","types":[{"type":"literal","value":null},{"type":"reference","id":619,"name":"WebviewWindow"}]}}]}],"groups":[{"title":"Constructors","children":[623]},{"title":"Properties","children":[759,760]},{"title":"Methods","children":[653,678,771,676,629,633,643,637,641,639,645,647,761,664,670,738,753,744,750,735,732,747,756,766,631,635,655,627,686,689,715,721,724,718,680,707,704,709,727,698,695,701,658,683,692,712,661,674,730,651,649,668,666,672,620]}],"sources":[{"fileName":"window.ts","line":2011,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2011"}],"extendedTypes":[{"type":"reference","name":"WindowManager"}]},{"id":1028,"name":"Monitor","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Allows you to retrieve information about a given monitor."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":1029,"name":"name","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"Human-readable name of the monitor"}]},"sources":[{"fileName":"window.ts","line":81,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L81"}],"type":{"type":"union","types":[{"type":"literal","value":null},{"type":"intrinsic","name":"string"}]}},{"id":1031,"name":"position","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"the Top-left corner position of the monitor relative to the larger full screen area."}]},"sources":[{"fileName":"window.ts","line":85,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L85"}],"type":{"type":"reference","id":1006,"name":"PhysicalPosition"}},{"id":1032,"name":"scaleFactor","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The scale factor that can be used to map physical pixels to logical pixels."}]},"sources":[{"fileName":"window.ts","line":87,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L87"}],"type":{"type":"intrinsic","name":"number"}},{"id":1030,"name":"size","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The monitor's resolution."}]},"sources":[{"fileName":"window.ts","line":83,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L83"}],"type":{"type":"reference","id":987,"name":"PhysicalSize"}}],"groups":[{"title":"Properties","children":[1029,1031,1032,1030]}],"sources":[{"fileName":"window.ts","line":79,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L79"}]},{"id":1033,"name":"ScaleFactorChanged","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"The payload for the "},{"kind":"code","text":"`scaleChange`"},{"kind":"text","text":" event."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.2"}]}]},"children":[{"id":1034,"name":"scaleFactor","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The new window scale factor."}]},"sources":[{"fileName":"window.ts","line":97,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L97"}],"type":{"type":"intrinsic","name":"number"}},{"id":1035,"name":"size","kind":1024,"kindString":"Property","flags":{},"comment":{"summary":[{"kind":"text","text":"The new window size"}]},"sources":[{"fileName":"window.ts","line":99,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L99"}],"type":{"type":"reference","id":987,"name":"PhysicalSize"}}],"groups":[{"title":"Properties","children":[1034,1035]}],"sources":[{"fileName":"window.ts","line":95,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L95"}]},{"id":1045,"name":"WindowOptions","kind":256,"kindString":"Interface","flags":{},"comment":{"summary":[{"kind":"text","text":"Configuration for the window to create."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"children":[{"id":1072,"name":"acceptFirstMouse","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether clicking an inactive window also clicks through to the webview on macOS."}]},"sources":[{"fileName":"window.ts","line":2187,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2187"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1064,"name":"alwaysOnTop","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window should always be on top of other windows or not."}]},"sources":[{"fileName":"window.ts","line":2145,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2145"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1047,"name":"center","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Show window in the center of the screen.."}]},"sources":[{"fileName":"window.ts","line":2107,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2107"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1065,"name":"contentProtected","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Prevents the window contents from being captured by other apps."}]},"sources":[{"fileName":"window.ts","line":2147,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2147"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1063,"name":"decorations","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window should have borders and bars or not."}]},"sources":[{"fileName":"window.ts","line":2143,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2143"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1068,"name":"fileDropEnabled","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the file drop is enabled or not on the webview. By default it is enabled.\n\nDisabling it is required to use drag and drop on the frontend on Windows."}]},"sources":[{"fileName":"window.ts","line":2169,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2169"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1059,"name":"focus","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window will be initially focused or not."}]},"sources":[{"fileName":"window.ts","line":2131,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2131"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1058,"name":"fullscreen","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window is in fullscreen mode or not."}]},"sources":[{"fileName":"window.ts","line":2129,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2129"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1051,"name":"height","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The initial height."}]},"sources":[{"fileName":"window.ts","line":2115,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2115"}],"type":{"type":"intrinsic","name":"number"}},{"id":1071,"name":"hiddenTitle","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"If "},{"kind":"code","text":"`true`"},{"kind":"text","text":", sets the window title to be hidden on macOS."}]},"sources":[{"fileName":"window.ts","line":2183,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2183"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1055,"name":"maxHeight","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The maximum height. Only applies if "},{"kind":"code","text":"`maxWidth`"},{"kind":"text","text":" is also set."}]},"sources":[{"fileName":"window.ts","line":2123,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2123"}],"type":{"type":"intrinsic","name":"number"}},{"id":1054,"name":"maxWidth","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The maximum width. Only applies if "},{"kind":"code","text":"`maxHeight`"},{"kind":"text","text":" is also set."}]},"sources":[{"fileName":"window.ts","line":2121,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2121"}],"type":{"type":"intrinsic","name":"number"}},{"id":1061,"name":"maximized","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window should be maximized upon creation or not."}]},"sources":[{"fileName":"window.ts","line":2139,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2139"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1053,"name":"minHeight","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The minimum height. Only applies if "},{"kind":"code","text":"`minWidth`"},{"kind":"text","text":" is also set."}]},"sources":[{"fileName":"window.ts","line":2119,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2119"}],"type":{"type":"intrinsic","name":"number"}},{"id":1052,"name":"minWidth","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The minimum width. Only applies if "},{"kind":"code","text":"`minHeight`"},{"kind":"text","text":" is also set."}]},"sources":[{"fileName":"window.ts","line":2117,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2117"}],"type":{"type":"intrinsic","name":"number"}},{"id":1056,"name":"resizable","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window is resizable or not."}]},"sources":[{"fileName":"window.ts","line":2125,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2125"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1067,"name":"shadow","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether or not the window has shadow.\n\n#### Platform-specific\n\n- **Windows:**\n - "},{"kind":"code","text":"`false`"},{"kind":"text","text":" has no effect on decorated window, shadows are always ON.\n - "},{"kind":"code","text":"`true`"},{"kind":"text","text":" will make ndecorated window have a 1px white border,\nand on Windows 11, it will have a rounded corners.\n- **Linux:** Unsupported."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"2.0"}]}]},"sources":[{"fileName":"window.ts","line":2163,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2163"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1066,"name":"skipTaskbar","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether or not the window icon should be added to the taskbar."}]},"sources":[{"fileName":"window.ts","line":2149,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2149"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1073,"name":"tabbingIdentifier","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Defines the window [tabbing identifier](https://developer.apple.com/documentation/appkit/nswindow/1644704-tabbingidentifier) on macOS.\n\nWindows with the same tabbing identifier will be grouped together.\nIf the tabbing identifier is not set, automatic tabbing will be disabled."}]},"sources":[{"fileName":"window.ts","line":2194,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2194"}],"type":{"type":"intrinsic","name":"string"}},{"id":1069,"name":"theme","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The initial window theme. Defaults to the system theme.\n\nOnly implemented on Windows and macOS 10.14+."}]},"sources":[{"fileName":"window.ts","line":2175,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2175"}],"type":{"type":"reference","id":1026,"name":"Theme"}},{"id":1057,"name":"title","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Window title."}]},"sources":[{"fileName":"window.ts","line":2127,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2127"}],"type":{"type":"intrinsic","name":"string"}},{"id":1070,"name":"titleBarStyle","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The style of the macOS title bar."}]},"sources":[{"fileName":"window.ts","line":2179,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2179"}],"type":{"type":"reference","id":1027,"name":"TitleBarStyle"}},{"id":1060,"name":"transparent","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window is transparent or not.\nNote that on "},{"kind":"code","text":"`macOS`"},{"kind":"text","text":" this requires the "},{"kind":"code","text":"`macos-private-api`"},{"kind":"text","text":" feature flag, enabled under "},{"kind":"code","text":"`tauri.conf.json > tauri > macOSPrivateApi`"},{"kind":"text","text":".\nWARNING: Using private APIs on "},{"kind":"code","text":"`macOS`"},{"kind":"text","text":" prevents your application from being accepted to the "},{"kind":"code","text":"`App Store`"},{"kind":"text","text":"."}]},"sources":[{"fileName":"window.ts","line":2137,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2137"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1046,"name":"url","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Remote URL or local file path to open.\n\n- URL such as "},{"kind":"code","text":"`https://github.com/tauri-apps`"},{"kind":"text","text":" is opened directly on a Tauri window.\n- data: URL such as "},{"kind":"code","text":"`data:text/html,...`"},{"kind":"text","text":" is only supported with the "},{"kind":"code","text":"`window-data-url`"},{"kind":"text","text":" Cargo feature for the "},{"kind":"code","text":"`tauri`"},{"kind":"text","text":" dependency.\n- local file path or route such as "},{"kind":"code","text":"`/path/to/page.html`"},{"kind":"text","text":" or "},{"kind":"code","text":"`/users`"},{"kind":"text","text":" is appended to the application URL (the devServer URL on development, or "},{"kind":"code","text":"`tauri://localhost/`"},{"kind":"text","text":" and "},{"kind":"code","text":"`https://tauri.localhost/`"},{"kind":"text","text":" on production)."}]},"sources":[{"fileName":"window.ts","line":2105,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2105"}],"type":{"type":"intrinsic","name":"string"}},{"id":1074,"name":"userAgent","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The user agent for the webview."}]},"sources":[{"fileName":"window.ts","line":2198,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2198"}],"type":{"type":"intrinsic","name":"string"}},{"id":1062,"name":"visible","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"Whether the window should be immediately visible upon creation or not."}]},"sources":[{"fileName":"window.ts","line":2141,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2141"}],"type":{"type":"intrinsic","name":"boolean"}},{"id":1050,"name":"width","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The initial width."}]},"sources":[{"fileName":"window.ts","line":2113,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2113"}],"type":{"type":"intrinsic","name":"number"}},{"id":1048,"name":"x","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The initial vertical position. Only applies if "},{"kind":"code","text":"`y`"},{"kind":"text","text":" is also set."}]},"sources":[{"fileName":"window.ts","line":2109,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2109"}],"type":{"type":"intrinsic","name":"number"}},{"id":1049,"name":"y","kind":1024,"kindString":"Property","flags":{"isOptional":true},"comment":{"summary":[{"kind":"text","text":"The initial horizontal position. Only applies if "},{"kind":"code","text":"`x`"},{"kind":"text","text":" is also set."}]},"sources":[{"fileName":"window.ts","line":2111,"character":2,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2111"}],"type":{"type":"intrinsic","name":"number"}}],"groups":[{"title":"Properties","children":[1072,1064,1047,1065,1063,1068,1059,1058,1051,1071,1055,1054,1061,1053,1052,1056,1067,1066,1073,1069,1057,1070,1060,1046,1074,1062,1050,1048,1049]}],"sources":[{"fileName":"window.ts","line":2097,"character":10,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2097"}]},{"id":617,"name":"CursorIcon","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"window.ts","line":235,"character":12,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L235"}],"type":{"type":"union","types":[{"type":"literal","value":"default"},{"type":"literal","value":"crosshair"},{"type":"literal","value":"hand"},{"type":"literal","value":"arrow"},{"type":"literal","value":"move"},{"type":"literal","value":"text"},{"type":"literal","value":"wait"},{"type":"literal","value":"help"},{"type":"literal","value":"progress"},{"type":"literal","value":"notAllowed"},{"type":"literal","value":"contextMenu"},{"type":"literal","value":"cell"},{"type":"literal","value":"verticalText"},{"type":"literal","value":"alias"},{"type":"literal","value":"copy"},{"type":"literal","value":"noDrop"},{"type":"literal","value":"grab"},{"type":"literal","value":"grabbing"},{"type":"literal","value":"allScroll"},{"type":"literal","value":"zoomIn"},{"type":"literal","value":"zoomOut"},{"type":"literal","value":"eResize"},{"type":"literal","value":"nResize"},{"type":"literal","value":"neResize"},{"type":"literal","value":"nwResize"},{"type":"literal","value":"sResize"},{"type":"literal","value":"seResize"},{"type":"literal","value":"swResize"},{"type":"literal","value":"wResize"},{"type":"literal","value":"ewResize"},{"type":"literal","value":"nsResize"},{"type":"literal","value":"neswResize"},{"type":"literal","value":"nwseResize"},{"type":"literal","value":"colResize"},{"type":"literal","value":"rowResize"}]}},{"id":1036,"name":"FileDropEvent","kind":4194304,"kindString":"Type alias","flags":{},"comment":{"summary":[{"kind":"text","text":"The file drop event types."}]},"sources":[{"fileName":"window.ts","line":103,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L103"}],"type":{"type":"union","types":[{"type":"reflection","declaration":{"id":1037,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"children":[{"id":1039,"name":"paths","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":104,"character":21,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L104"}],"type":{"type":"array","elementType":{"type":"intrinsic","name":"string"}}},{"id":1038,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":104,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L104"}],"type":{"type":"literal","value":"hover"}}],"groups":[{"title":"Properties","children":[1039,1038]}],"sources":[{"fileName":"window.ts","line":104,"character":4,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L104"}]}},{"type":"reflection","declaration":{"id":1040,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"children":[{"id":1042,"name":"paths","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":105,"character":20,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L105"}],"type":{"type":"array","elementType":{"type":"intrinsic","name":"string"}}},{"id":1041,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":105,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L105"}],"type":{"type":"literal","value":"drop"}}],"groups":[{"title":"Properties","children":[1042,1041]}],"sources":[{"fileName":"window.ts","line":105,"character":4,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L105"}]}},{"type":"reflection","declaration":{"id":1043,"name":"__type","kind":65536,"kindString":"Type literal","flags":{},"children":[{"id":1044,"name":"type","kind":1024,"kindString":"Property","flags":{},"sources":[{"fileName":"window.ts","line":106,"character":6,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L106"}],"type":{"type":"literal","value":"cancel"}}],"groups":[{"title":"Properties","children":[1044]}],"sources":[{"fileName":"window.ts","line":106,"character":4,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L106"}]}}]}},{"id":1026,"name":"Theme","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"window.ts","line":71,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L71"}],"type":{"type":"union","types":[{"type":"literal","value":"light"},{"type":"literal","value":"dark"}]}},{"id":1027,"name":"TitleBarStyle","kind":4194304,"kindString":"Type alias","flags":{},"sources":[{"fileName":"window.ts","line":72,"character":5,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L72"}],"type":{"type":"union","types":[{"type":"literal","value":"visible"},{"type":"literal","value":"transparent"},{"type":"literal","value":"overlay"}]}},{"id":978,"name":"appWindow","kind":32,"kindString":"Variable","flags":{},"comment":{"summary":[{"kind":"text","text":"The WebviewWindow for the current window."}]},"sources":[{"fileName":"window.ts","line":2073,"character":4,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2073"}],"type":{"type":"reference","id":619,"name":"WebviewWindow"}},{"id":1024,"name":"availableMonitors","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"window.ts","line":2272,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2272"}],"signatures":[{"id":1025,"name":"availableMonitors","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the list of all the monitors available on the system."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { availableMonitors } from '@tauri-apps/api/window';\nconst monitors = availableMonitors();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"array","elementType":{"type":"reference","id":1028,"name":"Monitor"}}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":1020,"name":"currentMonitor","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"window.ts","line":2223,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2223"}],"signatures":[{"id":1021,"name":"currentMonitor","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the monitor on which the window currently resides.\nReturns "},{"kind":"code","text":"`null`"},{"kind":"text","text":" if current monitor can't be detected."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { currentMonitor } from '@tauri-apps/api/window';\nconst monitor = currentMonitor();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"union","types":[{"type":"reference","id":1028,"name":"Monitor"},{"type":"literal","value":null}]}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]},{"id":976,"name":"getAll","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"window.ts","line":293,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L293"}],"signatures":[{"id":977,"name":"getAll","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Gets a list of instances of "},{"kind":"code","text":"`WebviewWindow`"},{"kind":"text","text":" for all available webview windows."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"array","elementType":{"type":"reference","id":619,"name":"WebviewWindow"}}}]},{"id":974,"name":"getCurrent","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"window.ts","line":281,"character":9,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L281"}],"signatures":[{"id":975,"name":"getCurrent","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Get an instance of "},{"kind":"code","text":"`WebviewWindow`"},{"kind":"text","text":" for the current webview window."}],"blockTags":[{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","id":619,"name":"WebviewWindow"}}]},{"id":1022,"name":"primaryMonitor","kind":64,"kindString":"Function","flags":{},"sources":[{"fileName":"window.ts","line":2248,"character":15,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L2248"}],"signatures":[{"id":1023,"name":"primaryMonitor","kind":4096,"kindString":"Call signature","flags":{},"comment":{"summary":[{"kind":"text","text":"Returns the primary monitor of the system.\nReturns "},{"kind":"code","text":"`null`"},{"kind":"text","text":" if it can't identify any monitor as a primary one."}],"blockTags":[{"tag":"@example","content":[{"kind":"code","text":"```typescript\nimport { primaryMonitor } from '@tauri-apps/api/window';\nconst monitor = primaryMonitor();\n```"}]},{"tag":"@since","content":[{"kind":"text","text":"1.0.0"}]}]},"type":{"type":"reference","typeArguments":[{"type":"union","types":[{"type":"reference","id":1028,"name":"Monitor"},{"type":"literal","value":null}]}],"name":"Promise","externalUrl":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise","qualifiedName":"Promise","package":"typescript"}}]}],"groups":[{"title":"Enumerations","children":[1017]},{"title":"Classes","children":[962,998,979,1006,987,619]},{"title":"Interfaces","children":[1028,1033,1045]},{"title":"Type Aliases","children":[617,1036,1026,1027]},{"title":"Variables","children":[978]},{"title":"Functions","children":[1024,1020,976,974,1022]}],"sources":[{"fileName":"window.ts","line":66,"character":0,"url":"https://github.com/tauri-apps/tauri/blob/9f223491c/tooling/api/src/window.ts#L66"}]}],"groups":[{"title":"Modules","children":[1,12,62,97,202,216,229,244,340,346,576,594,616]}]} \ No newline at end of file diff --git a/tooling/api/src/globalShortcut.ts b/tooling/api/src/globalShortcut.ts deleted file mode 100644 index 32f63eaa3a6..00000000000 --- a/tooling/api/src/globalShortcut.ts +++ /dev/null @@ -1,152 +0,0 @@ -// Copyright 2019-2023 Tauri Programme within The Commons Conservancy -// SPDX-License-Identifier: Apache-2.0 -// SPDX-License-Identifier: MIT - -/** - * Register global shortcuts. - * - * This package is also accessible with `window.__TAURI__.globalShortcut` when [`build.withGlobalTauri`](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in `tauri.conf.json` is set to `true`. - * - * The APIs must be added to [`tauri.allowlist.globalShortcut`](https://tauri.app/v1/api/config/#allowlistconfig.globalshortcut) in `tauri.conf.json`: - * ```json - * { - * "tauri": { - * "allowlist": { - * "globalShortcut": { - * "all": true // enable all global shortcut APIs - * } - * } - * } - * } - * ``` - * It is recommended to allowlist only the APIs you use for optimal bundle size and security. - * @module - */ - -import { invokeTauriCommand } from './helpers/tauri' -import { transformCallback } from './tauri' - -export type ShortcutHandler = (shortcut: string) => void - -/** - * Register a global shortcut. - * @example - * ```typescript - * import { register } from '@tauri-apps/api/globalShortcut'; - * await register('CommandOrControl+Shift+C', () => { - * console.log('Shortcut triggered'); - * }); - * ``` - * - * @param shortcut Shortcut definition, modifiers and key separated by "+" e.g. CmdOrControl+Q - * @param handler Shortcut handler callback - takes the triggered shortcut as argument - * - * @since 1.0.0 - */ -async function register( - shortcut: string, - handler: ShortcutHandler -): Promise { - return invokeTauriCommand({ - __tauriModule: 'GlobalShortcut', - message: { - cmd: 'register', - shortcut, - handler: transformCallback(handler) - } - }) -} - -/** - * Register a collection of global shortcuts. - * @example - * ```typescript - * import { registerAll } from '@tauri-apps/api/globalShortcut'; - * await registerAll(['CommandOrControl+Shift+C', 'Ctrl+Alt+F12'], (shortcut) => { - * console.log(`Shortcut ${shortcut} triggered`); - * }); - * ``` - * - * @param shortcuts Array of shortcut definitions, modifiers and key separated by "+" e.g. CmdOrControl+Q - * @param handler Shortcut handler callback - takes the triggered shortcut as argument - * - * @since 1.0.0 - */ -async function registerAll( - shortcuts: string[], - handler: ShortcutHandler -): Promise { - return invokeTauriCommand({ - __tauriModule: 'GlobalShortcut', - message: { - cmd: 'registerAll', - shortcuts, - handler: transformCallback(handler) - } - }) -} - -/** - * Determines whether the given shortcut is registered by this application or not. - * @example - * ```typescript - * import { isRegistered } from '@tauri-apps/api/globalShortcut'; - * const isRegistered = await isRegistered('CommandOrControl+P'); - * ``` - * - * @param shortcut Array of shortcut definitions, modifiers and key separated by "+" e.g. CmdOrControl+Q - * - * @since 1.0.0 - */ -async function isRegistered(shortcut: string): Promise { - return invokeTauriCommand({ - __tauriModule: 'GlobalShortcut', - message: { - cmd: 'isRegistered', - shortcut - } - }) -} - -/** - * Unregister a global shortcut. - * @example - * ```typescript - * import { unregister } from '@tauri-apps/api/globalShortcut'; - * await unregister('CmdOrControl+Space'); - * ``` - * - * @param shortcut shortcut definition, modifiers and key separated by "+" e.g. CmdOrControl+Q - * - * @since 1.0.0 - */ -async function unregister(shortcut: string): Promise { - return invokeTauriCommand({ - __tauriModule: 'GlobalShortcut', - message: { - cmd: 'unregister', - shortcut - } - }) -} - -/** - * Unregisters all shortcuts registered by the application. - * @example - * ```typescript - * import { unregisterAll } from '@tauri-apps/api/globalShortcut'; - * await unregisterAll(); - * ``` - * - * @since 1.0.0 - */ -async function unregisterAll(): Promise { - return invokeTauriCommand({ - __tauriModule: 'GlobalShortcut', - message: { - cmd: 'unregisterAll' - } - }) -} - -export { register, registerAll, isRegistered, unregister, unregisterAll } diff --git a/tooling/api/src/index.ts b/tooling/api/src/index.ts index 64400bcff29..55a5a751b74 100644 --- a/tooling/api/src/index.ts +++ b/tooling/api/src/index.ts @@ -16,7 +16,6 @@ import * as app from './app' import * as dialog from './dialog' import * as event from './event' -import * as globalShortcut from './globalShortcut' import * as http from './http' import * as notification from './notification' import * as path from './path' @@ -35,7 +34,6 @@ export { app, dialog, event, - globalShortcut, http, notification, path,