acceptFirstMouse
window option.
fs/exists
Monitor
instances with the correct classes for position
and size
fields instead of plain object.
BaseDirectory
enum variants AppConfig
, AppData
, AppLocalData
, AppCache
and AppLog
along with equivalent functions in path
module and deprecated ambiguous variants Log
and App
along with their equivalent functions in path
module.
dialog.save
return type
FormData
on the Body.form
function.
show
and hide
methods on the app
module.
tabbingIdentifier
window option for macOS.
tabbing_identifier
to the window builder on macOS.
user_agent
option when creating a window.
mockIPC()
handler signature to allow async handler functions.
Command
, Command.stdout
and Command.stderr
events with new once
, off
, listenerCount
, prependListener
, prependOnceListener
and removeAllListeners
functions.
encoding
option to the Command
options.
exists
function to the fs module.
ArrayBuffer
in Body.bytes
and writeBinaryFile
.
toString()
on message/confirm/ask dialogs title and message values.
type-fest
dependency, changing the OS types to the specific enum instead of allowing any string.
writeBinaryFile
sending an empty file contents when only the first argument is passed.
dialog.open
.
stable
!
FilePart
usage in http.Body.form
by renaming the value
property to file
.
isPermissionGranted
function now returns boolean
instead of boolean | null
. The response is never null
because we won't check the permission for now, always returning true
instead.
resolveResource
API to the path module.
writeFile
to writeTextFile
but kept the original function for backwards compatibility.
(path, contents[, options])
overload to the writeTextFile
and writeBinaryFile
APIs.
title
option in the message dialog API.
http > connectTimeout
.
convertFileSrc
function.
theme
getter to WebviewWindow
.
theme
field to WindowOptions
.
setCursorGrab
, setCursorVisible
, setCursorIcon
and setCursorPosition
methods to the WebviewWindow
class.
\r
.
tauri://theme-changed
event.
appWindow
type.
Temp
to the BaseDirectory
enum.
__TAURI_METADATA__
is not set, log an error instead.
unlisten
command.
Add fileDropEnabled
property to WindowOptions
so you can now disable it when creating windows from js.
Add logDir
function to the path
module to access the suggested log directory.
Add BaseDirectory.Log
to the fs
module.
Expose ask
, message
and confirm
APIs on the dialog module.
Event emit
now automatically serialize non-string types.
Fix http.fetch
throwing error if the response is successful but the body is empty.
Add title
option to file open/save dialogs.
Fix os.platform
returning macos
and windows
instead of darwin
and win32
.
The formatCallback
helper function now returns a number instead of a string.
Added rawHeaders
to http > Response
.
Removed the currentDir
API from the path
module.
currentDir
API from the path
module on 2022-02-04Remove .ts
files on the published package.
Breaking change: Replaces all usages of number[]
with Uint8Array
to be closer aligned with the wider JS ecosystem.
WindowManager
methods innerPosition
outerPosition
now correctly return instance of PhysicalPosition
.
WindowManager
methods innerSize
outerSize
now correctly return instance of PhysicalSize
.
Change the event
field of the Event
interface to type EventName
instead of string
.
Now resolve()
, join()
and normalize()
from the path
module, won't throw errors if the path doesn't exist, which matches NodeJS behavior.
Fixes the dialog defaultPath
usage on Linux.
Fixes window.label
property returning null instead of the actual label.
Remove the BaseDirectory::Current
enum variant for security reasons.
BaseDirectory::Current
variant on 2022-01-26Change WindowLabel
type to string
.
When building Universal macOS Binaries through the virtual target universal-apple-darwin
:
Expect a universal binary to be created by the user
Ensure that binary is bundled and accessed correctly at runtime
3035e458 Remove target triple from sidecar bin paths, closes #3355 (#3356) on 2022-02-07
https://asset.localhost/path/to/file
on Windows. Linux and macOS
is still asset://path/to/file
.
bundle
now exports clipboard
module so you can import { clipboard } from "@tauri-apps/api"
.
os
module which exports EOL
, platform()
, version()
, type()
, arch()
, tempdir()
join
, resolve
, normalize
, dirname
, basename
and extname
.sep
and delimiter
constants.resolvePath
API, use resolve
instead.path
module (#2310) on 2021-08-02toggleMaximize()
function to the WebviewWindow
class.
@ts-expect
error usage
file-drop-hover
on drop and file-drop
on hover).
EventName
type using type-fest
's LiteralUnion
.
convertFileSrc
helper to the tauri
module, simplifying the process of using file paths as webview source (img
, video
, etc).
emit
, listen
and once
using the appWindow
exported by the window module.
WebviewWindow
, which now extends WindowManager
.
Response
and ResponseType
as value instead of type.
BaseDirectory
in path
module
export type
to export TS types, enums and interfaces.
focus?: boolean
to the WindowOptions interface.
isDecorated
getter on the window API.
is_decorated
Window getter on 2021-05-30isResizable
getter on the window API.
is_resizable
Window getter on 2021-05-30isVisible
getter on the window API.
is_visible
API on 2021-05-30requestUserAttention
API to the window
module.
setFocus
to the window API.
setSkipTaskbar
to the window API.
set_skip_taskbar
API on 2021-05-30skipTaskbar?: boolean
to the WindowOptions interface.
skip_taskbar
API to the WindowBuilder/WindowOptions on 2021-05-30center?: boolean
to WindowOptions
and center()
API to the appWindow
.
clipboard
APIs (write and read text).
http
APIs now resolve the returned promise when the API call finishes with an error status code.
withGlobalTauri
(window.__TAURI__
) usage.
WebviewWindow
constructor as public.
setLocation
, setSize
, setMinSize
and setMaxSize
API.
package.json
to the exports
object.
.cjs
extension
transparent?: boolean
to the WindowOptions
interface.
options
argument to the shell command API (env
and cwd
configuration).
startDragging
API on the window module.
exit
and relaunch
APIs from app
to process
module.
setX
, setY
, setWidth
, setHeight
APIs, renamed resize
to setSize
and the size and position APIs now allow defining both logical and physical values.
@tauri-apps/api
package for older bundlers.
files
property in the package.json which mean that the dist
directory was not published and used.
{ name: string, extensions: string[] }
.