Commit Graph

12 Commits

Author SHA1 Message Date
Andrew de Waal d7a0bb325d feat(dialog) - Support fileAccessMode for open dialog (#3030) (#3136)
* feat(dialog) - Support fileAccessMode for open dialog (#3030)

On iOS, when trying to access a file that exists outside of the app sandbox, one of 2 things need to happen to be able to perform any operations on said file:

* A copy of the file needs to be made to the internal app sandbox
* The method startAccessingSecurityScopedResource needs to be called.

Previously, a copy of the file was always being made when a file was selected through the picker dialog.

While this did ensure there were no file access exceptions when reading from the file, it does not scale well for large files.

To resolve this, we now support `fileAccessMode`, which allows a file handle to be returned without copying the file to the app sandbox.

This MR only supports this change for iOS; MacOS has a different set of needs for security scoped resources.

See discussion in #3716 for more discussion of the difference between iOS and MacOS.
See MR #3185 to see how these scoped files will be accessible using security scoping.

* fmt, clippy

* use enum

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2026-01-14 08:35:06 -03:00
Andrew de Waal dff6fa986a feat(dialog) - Support picker mode for open dialog (#3030) (#3034)
Co-authored-by: Andrew de Waal <andrewldewaal@gmail.com>
2025-11-20 22:28:13 +01:00
Amr Bashir 509eba8d44 feat: support message dialogs with 3 buttons (#2641)
* feat: support message dialogs with 3 buttons

* change file

* From<String>

* untagged & YesNoCancel

* revert package.json

* Update plugins/dialog/src/desktop.rs

Co-authored-by: Tony <68118705+Legend-Master@users.noreply.github.com>

* no optional

* Update desktop.rs

* Update plugins/dialog/src/models.rs

Co-authored-by: Tony <68118705+Legend-Master@users.noreply.github.com>

* change to an enum

* convert back into union

* regen

* update @since

* map buttons for linux

* enhance type

* Add examples

---------

Co-authored-by: Tony <68118705+Legend-Master@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
Co-authored-by: Tony <legendmastertony@gmail.com>
2025-08-27 09:40:47 -03:00
Lucas Fernandes Nogueira feb1e93fcb feat(dialog): implement save API on iOS (#1707) 2024-09-02 21:13:43 -03:00
Lucas Fernandes Nogueira 0cb99bdaf1 fix(dialog): iOS file picker default to file selection instead of photo (#1706) 2024-09-02 17:43:13 +03:00
mikoto2000 448846b834 feat(fs): resolve content URIs on Android (#1658)
* Implemented writeTextFile on Android.

* Added license headers.

* fix fmt checks.

* implement more file APIs

* change file

* cleanup

* refactor dialog plugin to leverage new FS APIs

* implement metadata functions

* fix build

* expose FS rust API

* resolve resources on android

* update pnpm

* update docs

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2024-08-23 13:35:53 -03:00
Lucas Fernandes Nogueira b914775898 fix: explicitly set a minimum macOS version for older Swift versions (#1679)
ref https://github.com/tauri-apps/tauri/pull/10687
2024-08-19 16:29:22 -03:00
Lucas Fernandes Nogueira 326df68839 fix(ios): decoding with default value is not supported (#1236) 2024-04-22 23:35:47 -03:00
Lucas Fernandes Nogueira e438e0a62d feat: update to alpha.17, typed mobile plugin IPC arguments (#676)
Co-authored-by: Amr Bashir <amr.bashir2015@gmail.com>
2023-10-29 16:06:44 -03:00
Lucas Fernandes Nogueira 5914fb9f36 chore: add license headers (#384)
* feat: check for license headers

* add headers

* format
2023-05-21 16:56:10 -03:00
Lucas Fernandes Nogueira d677f73495 feat(ci): test mobile targets (#378) 2023-05-19 09:46:06 -07:00
Lucas Fernandes Nogueira 7a8633f429 feat(dialog): add plugin (#306) 2023-04-18 22:41:12 -03:00