Repository navigation
feat(native): reach HTML render frame parity (TR-HTML) - #363
Merged
Merged
Conversation
Completes native HTML render frame parity: WebKit image clicks to MediaViewer, download navigation guard, WebView cutout masking and hover tracking for the inline expand button, scrollable-container wheel pass-through, OS clipboard shortcuts via Edit menu actions, thread/environment switch auto-close, and live-follow pausing while full-screen HTML or media viewer is open.
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.
Closes #87
Ref #244
Summary
Completes native HTML render frame parity (
TR-HTML->done):html_host.jspostst3/notifications/open-imageon trusted<img>clicks (unless insidea[href]/buttonordefaultPrevented);t3-core::html_rendervalidateshttp(s):///data:image/(<= 16 MiB) and trims titles (ImageRequest/Action::OpenImage);html_render.rsreleases WebView focus and opensMediaViewer.PagePolicy::allowsblocksWKNavigationAction::shouldPerformDownload()on macOS.8px) of.group("html-render"), hidden whileSlot::Viewis unhovered, masked viawebview::cutout(T3WebContainerView::hitTest:+CALayermask complement), and tracked by a localHoverTargetmonitor (MouseMoved | MouseExited).html_host.jsreportsscroll-areas(rAF-throttled +MutationObserver);webview::page_consumes_vertical_scrollandScrollTarget::pass_throughonly consume vertical wheel events when the inner container or document can scroll in that direction.menus.rsroutes Cut/Copy/Paste/Select All throughMenuItem::os_action(OsAction::*), andwebview/macos.rsActivationforwardsCmd+X/C/V/Ato the active responder whenWKWebViewowns focus.HtmlFullscreencloses when the owning thread/environment changes;ThreadViewpauses live-follow (anchor::capture_pinned, deferred disclosure settling) wheneverHtmlFullscreenorMediaVieweris open.Snapshots (
1440x900,--html-fixture)Note:
--snapshotrenders offscreen (webview::is_offscreen() == true), showing theSlot::Cardfallback with hovered top-right expand chrome. Live WebKit interactive DOM/mouse/keyboard events (hover,Cmd+C, wheel pass-through,<img>click) are covered by Rust/GPUI unit tests and manual macOS integration rather than headless WebKit driving.Verification
cargo test --manifest-path apps/native/Cargo.toml -p t3-core -p t3-client: 1341 unit + 8 conformance tests (t3-core), 108 unit tests (t3-client) passed.cargo clippy --manifest-path apps/native/Cargo.toml --workspace --all-targets -- -D warnings: passed (0warnings/errors).t3-native(--features snapshot,--test-threads=1,menus:: webview:: transcript:: thread_view::): 46 passed, 0 failed.node --test apps/native/parity/sync.test.ts: 42/42 passed;vp fmt --check apps/native/parity/LEDGER.md: passed.