You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

44 KiB

Changelog

[1.3.0]

  • Return correct type for event.payload in onResized and onMoved window event handlers.
    • 0b46637e fix(api): construct correct object for onResized and onMoved, closes #6507 (#6509) on 2023-04-03
  • Added the WindowOptions::contentProtected option and WebviewWindow#setContentProtected to change it at runtime.
  • Allow setting the text of the dialog buttons.
    • 00e1efaa feat: customize button texts of message dialog (#4383) on 2022-12-28
  • Add is_minimized() window method.
  • Add title getter on window.

[1.2.0]

  • Added the acceptFirstMouse window option.
    • 95f467ad feat(core): add window accept_first_mouse option, closes #5347 (#5374) on 2022-10-17
  • Fix incorrect return type on fs/exists
    • ca3cd8b3 fix(api): fs/exists return type previously set to void when it should be boolean (#5252) on 2022-09-29
  • Initialize Monitor instances with the correct classes for position and size fields instead of plain object.
  • Breaking change: Node.js v12 is no longer supported.
    • 1129f4f5 refactor: simplify api.js bundling (#4277) on 2022-10-04
  • Add new app-specific 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.
  • Fix dialog.save return type
  • Added support to FormData on the Body.form function.
    • aa119f28 feat(api): add FormData support on Body.form, closes #5545 (#5546) on 2022-11-04
  • Added show and hide methods on the app module.
    • 39bf895b feat(macOS): Add application show and hide methods (#3689) on 2022-10-03
  • Added tabbingIdentifier window option for macOS.
  • Added tabbing_identifier to the window builder on macOS.
  • Added the user_agent option when creating a window.
    • a6c94119 feat(core): expose user_agent to window config (#5317) on 2022-10-02

[1.1.0]

  • Update mockIPC() handler signature to allow async handler functions.
    • 4fa968dc fix(api): add async mockIPC() handler signature (#5056) on 2022-08-26
  • Improve shell's Command, Command.stdout and Command.stderr events with new once, off, listenerCount, prependListener, prependOnceListener and removeAllListeners functions.
    • aa9f1243 Improved EventEmitter for tauri api shell (#4697) on 2022-07-26
  • Added the encoding option to the Command options.
    • d8cf9f9f Command support for specified character encoding, closes #4644 (#4772) on 2022-07-28
  • Add exists function to the fs module.
    • 3c62dbc9 feat(api): Add exists function to the fs module. (#5060) on 2022-09-15

[1.0.2]

  • Added helper functions to listen to updater and window events.
    • b02fc90f feat(api): add abstractions to updater and window event listeners (#4569) on 2022-07-05
  • Add support to ArrayBuffer in Body.bytes and writeBinaryFile.
    • 92aca55a feat(api): add support to ArrayBuffer (#4579) on 2022-07-05
  • Use toString() on message/confirm/ask dialogs title and message values.
    • b8cd2a79 feat(api): call toString() on dialog title and message, closes #4583 (#4588) on 2022-07-04
  • Remove the type-fest dependency, changing the OS types to the specific enum instead of allowing any string.

[1.0.1]

  • Fixes the writeBinaryFile sending an empty file contents when only the first argument is passed.
    • ea43cf52 fix(api): writeBinaryFile sends an empty contents with only one arg (#4368) on 2022-06-16

[1.0.0]

  • Allow choosing multiple folders in dialog.open.
  • Upgrade to stable!

[1.0.0-rc.7]

  • Fix FilePart usage in http.Body.form by renaming the value property to file.
    • 55f89d5f fix(api): Rename FormPart value to file to match docs and endpoint (#4307) on 2022-06-09
  • Fixes a memory leak in the command system.
    • f72cace3 fix: never remove ipc callback & mem never be released (#4274) on 2022-06-05
  • The notification's 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.
    • f482b094 fix: remove notification permission prompt (#4302) on 2022-06-09
  • Added the resolveResource API to the path module.
    • 7bba8db8 feat(api): add resolveResource API to the path module (#4234) on 2022-05-29
  • Renamed writeFile to writeTextFile but kept the original function for backwards compatibility.
    • 3f998ca2 feat(api): add writeTextFile and (path, contents, options) overload (#4228) on 2022-05-29
  • Added (path, contents[, options]) overload to the writeTextFile and writeBinaryFile APIs.
    • 3f998ca2 feat(api): add writeTextFile and (path, contents, options) overload (#4228) on 2022-05-29

[1.0.0-rc.6]

  • Expose option to set the dialog type.
    • f46175d5 feat(core): expose option to set dialog type, closes #4183 (#4187) on 2022-05-21
  • Expose title option in the message dialog API.
    • ae99f991 feat(core): expose message dialog's title option, ref #4183 (#4186) on 2022-05-21

[1.0.0-rc.5]

  • Fixes the type of http > connectTimeout.
    • f3c5ca89 fix(core): http api connect_timeout deserialization, closes #4004 (#4006) on 2022-04-29

[1.0.0-rc.4]

  • Encode the file path in the convertFileSrc function.
    • 42e8d9cf fix(api): encode file path in convertFileSrc function, closes #3841 (#3846) on 2022-04-02
  • Added theme getter to WebviewWindow.
  • Added theme field to WindowOptions.
  • Added the setCursorGrab, setCursorVisible, setCursorIcon and setCursorPosition methods to the WebviewWindow class.
  • Breaking change: The process Command API stdio lines now includes the trailing \r.
    • b5622882 fix(cli): exit on non-compilation Cargo errors, closes #3930 (#3942) on 2022-04-22
  • Added the tauri://theme-changed event.

[1.0.0-rc.3]

  • Properly define the appWindow type.
  • Added Temp to the BaseDirectory enum.
    • 266156a0 feat(core): add BaseDirectory::Temp and $TEMP variable (#3763) on 2022-03-24

[1.0.0-rc.2]

  • Do not crash if __TAURI_METADATA__ is not set, log an error instead.
    • 9cb1059a fix(api): do not throw an exception if TAURI_METADATA is not set, fixes #3554 (#3572) on 2022-03-03
  • Reimplement endpoint to read file as string for performance.
    • 834ccc51 feat(core): reimplement readTextFile for performance (#3631) on 2022-03-07
  • Fixes a regression on the unlisten command.
    • 76c791bd fix(core): regression on the unlisten function (#3623) on 2022-03-06

[1.0.0-rc.1]

  • Provide functions to mock IPC calls during testing and static site generation.
    • 7e04c072 feat: add mock functions for testing and SSG (#3437) on 2022-02-14
    • 6f5ed2e6 fix: change file on 2022-02-14

[1.0.0-rc.0]

  • Add fileDropEnabled property to WindowOptions so you can now disable it when creating windows from js.

    • 1bfc32a3 fix(api.js): add fileDropEnabled to WindowOptions, closes #2968 (#2989) on 2021-12-09
  • 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.

    • e98c1af4 feat(core): expose message dialog APIs, fix window.confirm, implement HasRawWindowHandle for Window, closes #2535 (#2700) on 2021-10-02
  • Event emit now automatically serialize non-string types.

    • 06000996 feat(api): support unknown types for event emit payload, closes #2929 (#2964) on 2022-01-07
  • Fix http.fetch throwing error if the response is successful but the body is empty.

    • 50c63900 fix(api.js): fix http.fetch throwing error if response body is empty, closes #2831 (#3008) on 2021-12-09
  • Add title option to file open/save dialogs.

    • e1d6a6e6 Create api-file-dialog-title.md (#3235) on 2022-01-16
    • 62c7a8ad chore(covector): prepare for rc release (#3376) on 2022-02-10
  • Fix os.platform returning macos and windows instead of darwin and win32.

    • 3924c3d8 fix(api.js): fix os.platform return on macos and windows, closes #2698 (#2699) on 2021-10-02
  • The formatCallback helper function now returns a number instead of a string.

    • a48b8b18 feat(core): validate callbacks and event names [TRI-038] [TRI-020] (#21) on 2022-01-09
  • Added rawHeaders to http > Response.

  • Removed the currentDir API from the path module.

    • a08509c6 fix(api): remove currentDir API from the path module on 2022-02-04
  • Remove .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.

    • cc8b1468 Fix(api): Window size and position returning wrong class (fix: #2599) (#2621) on 2021-09-22
  • Change the event field of the Event interface to type EventName instead of string.

    • b5d9bcb4 Consistent event name usage (#3228) on 2022-01-15
    • 62c7a8ad chore(covector): prepare for rc release (#3376) on 2022-02-10
  • Now resolve(), join() and normalize() from the path module, won't throw errors if the path doesn't exist, which matches NodeJS behavior.

    • fe381a0b fix: join no longer cares if path doesn't exist, closes #2499 (#2548) on 2021-09-21
  • Fixes the dialog defaultPath usage on Linux.

  • Fixes window.label property returning null instead of the actual label.

    • f5109e0c fix(api): window label null instead of actual value, closes #3295 (#3332) on 2022-02-04
  • Remove the BaseDirectory::Current enum variant for security reasons.

    • 696dca58 refactor(core): remove BaseDirectory::Current variant on 2022-01-26
  • Change WindowLabel type to string.

    • f68603ae chore(docs): simplify event system documentation on 2021-09-27
  • 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

[1.0.0-beta.8]

  • Revert target back to ES5.
    • 657c7dac fix(api): revert ES2021 target on 2021-08-23

[1.0.0-beta.7]

  • Fix missing asset protocol path.Now the protocol is https://asset.localhost/path/to/file on Windows. Linux and macOS is still asset://path/to/file.
    • 994b5325 fix: missing asset protocol path (#2484) on 2021-08-23

[1.0.0-beta.6]

  • bundle now exports clipboard module so you can import { clipboard } from "@tauri-apps/api".
    • 4f88c3fb fix(api.js): bundle now exports clipboard mod, closes #2243 (#2244) on 2021-07-19
  • Fix double window creation
  • Add os module which exports EOL, platform(), version(), type(), arch(), tempdir()
    • Add new nodejs-inspired functions which are join, resolve, normalize, dirname, basename and extname.
  • Add sep and delimiter constants.
  • Removed resolvePath API, use resolve instead.
  • 05b9d81e feat(api.js): add nodejs-inspired functions in path module (#2310) on 2021-08-02
  • Change target to ES2021.
    • 97bc52ee Tooling: [API] Changed target in tsconfig to es6 (#2362) on 2021-08-09
  • Add toggleMaximize() function to the WebviewWindow class.
    • 1a510066 fix(core): data-tauri-drag-region didn't respect resizable, closes #2314 (#2316) on 2021-08-02
  • Fix @ts-expect error usage
  • Fixes file drop events being swapped (file-drop-hover on drop and file-drop on hover).
    • c2b0fe1c fix(core): fix wrong file drop events (#2300) on 2021-07-31
  • Fixes the global bundle UMD code.
    • Fixes monitor api not working.
  • Fixes window.print() not working on macOS.
  • 0f63f5e7 fix(api): Fix monitor functions, closes #2294 (#2301) on 2021-07-29
  • Improve EventName type using type-fest's LiteralUnion.
    • 8e480297 feat(api): improve EventName type definition (#2379) on 2021-08-10
  • Update protocol url path with wry 0.12.1 on Windows.
    • 88382fe1 chore(api): update protocol url path with wry 0.12.1 on Windows (#2409) on 2021-08-13

[1.0.0-beta.5]

  • Adds convertFileSrc helper to the tauri module, simplifying the process of using file paths as webview source (img, video, etc).
    • 51a5cfe4 feat(api): add convertFileSrc helper (#2138) on 2021-07-02
  • You can now use emit, listen and once using the appWindow exported by the window module.
    • 5d7626f8 feat(api): WindowManager extends WebviewWindowHandle, add events docs (#2146) on 2021-07-03
  • Allow manipulating a spawned window directly using WebviewWindow, which now extends WindowManager.
    • d69b1cf6 feat(api): allow managing windows created on JS (#2154) on 2021-07-05

[1.0.0-beta.4]

  • Add asset custom protocol to access local file system.
    • ee60e424 feat: asset custom protocol to access local file system (#2104) on 2021-06-28

[1.0.0-beta.3]

  • Export Response and ResponseType as value instead of type.
    • 394b6e05 fix(api): http ResponseType export type error (#2065) on 2021-06-24

[1.0.0-beta.2]

  • Export BaseDirectory in path module
    • 277f5ca5 feat(api): export BaseDirectory in path module (#1885) on 2021-05-30
  • Use export type to export TS types, enums and interfaces.
    • 9a662d26 fix: Monitor if --isolatedModules is enabled (#1825) on 2021-05-13
    • 612cd8ec feat(api): finalize export type usage (#1847) on 2021-05-17
  • Adds focus?: boolean to the WindowOptions interface.
    • 5f351622 feat(core): add focus API to the WindowBuilder and WindowOptions, #1737 on 2021-05-30
  • Adds isDecorated getter on the window API.
    • f58a2114 feat(core): add is_decorated Window getter on 2021-05-30
  • Adds isResizable getter on the window API.
    • 1e8af280 feat(core): add is_resizable Window getter on 2021-05-30
  • Adds isVisible getter on the window API.
    • 36506c96 feat(core): add is_visible API on 2021-05-30
  • Adds requestUserAttention API to the window module.
  • Adds setFocus to the window API.
    • bb6992f8 feat(core): add set_focus window API, fixes #1737 on 2021-05-30
  • Adds setSkipTaskbar to the window API.
    • e06aa277 feat(core): add set_skip_taskbar API on 2021-05-30
  • Adds skipTaskbar?: boolean to the WindowOptions interface.
    • 5525b03a feat(core): add skip_taskbar API to the WindowBuilder/WindowOptions on 2021-05-30
  • Adds center?: boolean to WindowOptions and center() API to the appWindow.
  • Adds clipboard APIs (write and read text).
    • 285bf64b feat(core): add clipboard writeText and readText APIs (#2035) on 2021-06-21
    • dee71ad5 fix(workflows): update docs workflow syntax (#2054) on 2021-06-23
  • The http APIs now resolve the returned promise when the API call finishes with an error status code.
    • 47f75584 fix(core): resolve HTTP API on non-ok status code, fix binary response, closes #2046 (#2053) on 2021-06-23
  • Improve RPC security by requiring a numeric code to invoke commands. The codes are generated by the Rust side and injected into the app's code using a closure, so external scripts can't access the backend. This change doesn't protect withGlobalTauri (window.__TAURI__) usage.
  • Mark the WebviewWindow constructor as public.
    • 4aeb936e fix(api): WebviewWindow constructor is public (#1888) on 2021-05-21
  • Validate arguments on the window setLocation, setSize, setMinSize and setMaxSize API.
    • 7616e6cc feat(api): validate window API size and location arguments (#1846) on 2021-05-17

[1.0.0-beta.1]

  • Adds package.json to the exports object.
    • ab1ea96 chore(api): add package.json to the exports field (#1807) on 2021-05-12

[1.0.0-beta.0]

  • CommonJS chunks are now properly exported with .cjs extension
    • ddcd923 fix(api): export commonjs chunks with .cjs extension, fix #1625 (#1627) on 2021-04-26
  • Adds transparent?: boolean to the WindowOptions interface.
    • 08c1c5c fix(api): missing transparent flag on WindowOptions (#1764) on 2021-05-10
  • Adds options argument to the shell command API (env and cwd configuration).
    • 721e98f feat(core): add env, cwd to the command API, closes #1634 (#1635) on 2021-04-28
  • Adds startDragging API on the window module.
  • Move exit and relaunch APIs from app to process module.
    • b0bb796 refactor: rename command mod to process, move restart_application (#1667) on 2021-04-30
  • The window management API was refactored: removed setX, setY, setWidth, setHeight APIs, renamed resize to setSize and the size and position APIs now allow defining both logical and physical values.
    • 6bfac86 refactor(core): add window getters, physical & logical sizes/positions (#1723) on 2021-05-05
  • Adds window getters.
    • 6bfac86 refactor(core): add window getters, physical & logical sizes/positions (#1723) on 2021-05-05

[1.0.0-beta-rc.3]

  • Fixes distribution of the @tauri-apps/api package for older bundlers.
  • Update minimum Node.js version to v12.13.0
    • 1f089fb chore: update minimum nodejs version to 12.13.0 (#1562) on 2021-04-21

[1.0.0-beta-rc.2]

  • TS was wrongly re-exporting the module.

[1.0.0-beta-rc.1]

  • Missing the files property in the package.json which mean that the dist directory was not published and used.

[1.0.0-beta-rc.0]

  • Add current working directory to the path api module.
    • 52c2baf feat: add current working directory to path api module (#1375) on 2021-03-23
    • a6def70 Refactor(tauri): move tauri-api and tauri-updater to tauri (#1455) on 2021-04-11
  • The shell process spawning API was rewritten and now includes stream access.
    • 3713066 refactor(core): rewrite shell execute API, closes #1229 (#1408) on 2021-03-31
  • The file dialog API now uses rfd. The filter option is now an array of { name: string, extensions: string[] }.
    • 2326bcd refactor(core): use nfd for file dialogs, closes #1251 (#1257) on 2021-02-18
    • a6def70 Refactor(tauri): move tauri-api and tauri-updater to tauri (#1455) on 2021-04-11
  • The HTTP API was improved with client caching and better payload and response types.
    • a7bc472 refactor(core): improve HTTP API, closes #1098 (#1237) on 2021-02-15
    • a6def70 Refactor(tauri): move tauri-api and tauri-updater to tauri (#1455) on 2021-04-11
  • Update all code files to have our license header.
    • bf82136 feat(license): SPDX Headers (#1449) on 2021-04-11
    • a6def70 Refactor(tauri): move tauri-api and tauri-updater to tauri (#1455) on 2021-04-11
    • aea6145 refactor(repo): add /tooling folder (#1457) on 2021-04-12
  • Use secure RNG on callback function names.
  • The invoke function can now be called with the cmd as the first parameter and the args as the second.
    • 427d170 feat(api/invoke): separate cmd arg (#1321) on 2021-03-04
  • Adds a global shortcut API.
    • 855effa feat(core): globalShortcut API (#1232) on 2021-02-14
    • a6def70 Refactor(tauri): move tauri-api and tauri-updater to tauri (#1455) on 2021-04-11
  • Added window management and window creation APIs.
    • a3d6dff feat(core): window API (#1225) on 2021-02-13
    • 641374b feat(core): window creation at runtime (#1249) on 2021-02-17