* Expose `ScrollBarStyle` webview option to tauri.
This commit exposes the scroll_bar_style option from wry via the tauri
WebviewWindowBuilder API. By itself, the commit does not include changes
to the configuration file or JavaScript APIs: These will be added in a
later commit.
* Fix a compile error on macOS and Linux.
* Add `scroll_bar_style` to WindowConfig.
This commit exposes the `scroll_bar_style` option in tauri.conf.json/
.json5/.toml as `scrollBarStyle` and `scroll-bar-style`.
* Expose `scroll_bar_style` to JavaScript API.
This commit exposes the `scroll_bar_style` in the options object passed
to the JavaScript API `Webview` and `WebviewWindow` constructors.
While testing this, I discovered that on Windows, attempting to create
a webview from the JavaScript API will cause the hosting window to
immediately hang if it attempts to use the same data directory as
another webview without sharing the same environment options. This
commit includes no mitigation for this behaviour, as I will be opening
a separate issue about it at some point in the near future.
* Document WebView2 environment requirements.
This commit adds a message to the documentation for all components of
the `scroll_bar_style` configuration option, telling users that all
webviews that use the same data directory must use the same value for
this option.
* Fix formatting.
* Add change files to .changes directory.
* Remove `tauri-schema-generator` from change file.
* Remove quotes from change tags.
* Add tags to change files.
I did not realise that these were needed, as the pull request that I
used as my reference when building this feature did not have them.
* update conf
---------
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
* fix(tauri-runtime-wry): ignore about:blank initial URL
fixes a macOS warning when a navigation handler is registered and you choose to create a new window on the on_new_window hook - in this case we shouldn't perform the initial navigation since the URL is provided by the webview configuration from the hook
* change tag
* bump min wry
* fix: a few regressions from previous PRs
* rename with_window_features to window_features
* Clippy
* clippy
---------
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
* Adds the ability to set the focused property from tauri.conf.json -- windows
* add set_focusable, pin tao
* fmt
---------
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
* add "new window" and "document title changed" webview handler
* take document title changed handler
* update example, add missing api, change files
* allow creating tauri window for the window.open call
* set size and position, fix linux, example
* enhance document title change
* fix windows deadlock
* wry 0.53
* update wry
---------
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
* fix: double free of resizing handler's userdata on Windows
Using WM_NCDESTROY instead of WM_DESTROY is more correct for freeing userdata, as windows can receive multiple WM_DESTROY events if they're parented.
* chore: add change entry for resizing handler double-free fix
* test: make some of window id + stores public
* test: make window wrapper label pub
* feat: make label accessible for windowwrapper
* chore: adds wry runtime changefile
* chore: avoid forced clone on label
Co-authored-by: Tony <68118705+Legend-Master@users.noreply.github.com>
---------
Co-authored-by: Tony <68118705+Legend-Master@users.noreply.github.com>
* apply version updates
* minor bump for build, plugin, macros and runtime
---------
Co-authored-by: lucasfernog <20051258+lucasfernog@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
* fix: dont depend on private schemars api
* tauri-cli/deps: update kuchikiki and html5ever
tauri-utils/deps: update kuchikiki and html5ever
tauri-runtime-wry/deps: update wry to match kuchikiki and html5ever versions
* fix: specify exact patch version of schemars
Without this, cargo resolves the patch version of schemars to one that
does not include the _private module on which tauri-utils v1 depends,
which is a dependency of tauri-cli. As a result of this, the build breaks.
* tauri-utils/fix: inline tauri-utils v1 config module
* deps: upgrade and pin schemars 0.8.21 to pick up crate patch in Cargo.toml
* update tao, wry
* lint, license
* lint
---------
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
* refactor: put dynamic acl to a feature
* Add change file
* Tweak remove_unused_commands's docs
* License header
* Document the feature
* Merge remote-tracking branch 'upstream/dev' into dynamic-acl-feature
* Use a inner non generic fn for add_capability
* Clippy and macro stability notice
* Merge remote-tracking branch 'upstream/dev' into dynamic-acl-feature
* Format
macOS uses a different coordinate system for visibleFrame, so to get accurate values we should only get the diff between frame() and visibleFrame() and apply that to the standard monitor position returned by CGDisplayBounds. Size isn't impacted by this, and properly returns the value (accounting for dock position).