[bug] Native `CommandOrControl+F` for search in a webview works on Windows but not on macOS
Describe the bug
On Windows, without any special config, eg: globalshortcut, press ctrl+f in a webview - and native webview search shows up as expected. On macOS, do the same but with cmd+f instead, and the native browser search does not show up.
Reproduction
No response
Expected behavior
I'd expect both platforms to behave the same - I'd either see the native find menu show up, or not show up.
Personally - we want the find window for our app on macOS, and haven't found an obvious way to make it show up, and would appreciate any tips you have there too!
Full tauri info output
[✔] Environment
- OS: Mac OS 14.4.1 X64
✔ Xcode Command Line Tools: installed
✔ rustc: 1.76.0 (07dca489a 2024-02-04)
✔ cargo: 1.76.0 (c84b36747 2024-01-18)
✔ rustup: 1.26.0 (5af9b9484 2023-04-05)
✔ Rust toolchain: stable-aarch64-apple-darwin (default)
- node: 20.10.0
- pnpm: 8.11.0
- yarn: 1.22.19
- npm: 8.1.2
[-] Packages
- tauri [RUST]: 2.0.0-beta.12
- tauri-build [RUST]: 2.0.0-beta.10
- wry [RUST]: 0.37.0
- tao [RUST]: 0.26.0
- @tauri-apps/api [NPM]: 2.0.0-beta.0
- @tauri-apps/cli [NPM]: 2.0.0-beta.3
[-] App
- build-type: bundle
- CSP: unset
- frontendDist: http://localhost:5173/
- devUrl: http://localhost:5173/
- framework: React
- bundler: Vite
Stack trace
No response
Additional context
No response
Looks like this might ultimately be at the underlying WebView implementation level and not something fixable in Tauri. Looking through WKWebView docs, it seems like you can enable "Find in page" support, but only on iOS: https://developer.apple.com/documentation/webkit/wkwebview/4002044-isfindinteractionenabled
This is perhaps an enhancement instead.
Same need
AreBrowserAcceleratorKeysEnabled might be used for fixing inconsistent behavior. however, we have to implement ctrl + r and other shortcuts.