fix(miniapp): restore strict WebKit rendering and floating chat - #1906
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
srcdocdocuments in Tauri WKWebViewabout:blank/about:srcdociframe navigations through the desktop navigation policy while preserving main-window reload blockingFixes: N/A (manual regression report)
Type and Areas
Type: regression fix
Areas: desktop/Tauri, Web UI, MiniApp runtime, Agent chat bridge
Motivation / Impact
Reviewed marketplace MiniApps using the strict runtime could open as an entirely blank surface on macOS. Wry forwards subframe navigation actions to Tauri's URL-only navigation callback, so BitFun's one-shot main-window navigation guard also cancelled the MiniApp iframe's Blob navigation.
Strict MiniApps now render reliably in WKWebView without weakening their opaque-origin sandbox. Their contextual Agent workflow can remain in the floating chat composer instead of navigating away from the MiniApp when the active runner owns the bound session.
Verification
pnpm --dir src/web-ui run test:run src/app/scenes/miniapps/components/MiniAppRunner.test.tsx src/app/scenes/miniapps/hooks/miniAppAgentVisibility.test.ts src/app/scenes/miniapps/hooks/useMiniAppBridge.test.tsx— 3 files, 7 tests passedpnpm run type-check:web— passedcargo test -p bitfun-desktop— 249 passed, 2 environment-dependent tests ignoredcargo check -p bitfun-desktop— passedcargo build -p bitfun-desktop— passedgit diff --check— passedReviewer Notes
http,https,tauri,data, and other page navigations. Only local Blob documents plusabout:blank/about:srcdocbypass the one-shot gate without consuming it.sandbox="allow-scripts";allow-same-originwas not added and the compiled MiniApp CSP is unchanged.Checklist