Skip to content

Disable WebView zoom on Duck.ai pages - #9775

Open
malmstein wants to merge 1 commit into
developfrom
feature/david/disable_zoom_duckai
Open

Disable WebView zoom on Duck.ai pages#9775
malmstein wants to merge 1 commit into
developfrom
feature/david/disable_zoom_duckai

Conversation

@malmstein

@malmstein malmstein commented Sep 10, 2026

Copy link
Copy Markdown
Contributor

Task/Issue URL: https://app.asana.com/1/137249556945/project/1174433894299346/task/1218241023018339
Tech Design URL (if applicable):
API Proposals URL(s) (if applicable):

Description

Pinch and double-tap zoom distort the Duck.ai chat layout, so zoom is now disabled while Duck.ai is showing. In a browser tab this rides the existing EnableDuckAIFullScreen / DuckAIFullScreenDisabled commands, so zoom comes back as soon as the tab navigates to any other site. The contextual sheet WebViews only ever host Duck.ai and disable zoom at creation. Search result pages are out of scope here and still zoom.

Steps to test this PR

Duck.ai in a browser tab

  • Open a Duck.ai chat in a tab, try to pinch-zoom and double-tap-zoom, neither should do anything
  • From that tab navigate to any other website, pinch-zoom should work again
  • Go back to Duck.ai, zoom should be blocked again

Duck.ai contextual sheet

  • Open the contextual Duck.ai sheet from a page, try to pinch-zoom and double-tap-zoom, neither should do anything

Search unaffected

  • Run a search, pinch-zoom on the results page should still work

UI changes

No UI changes.


Note

Low Risk
Localized WebView settings toggles around Duck.ai entry/exit with no auth or data-path changes; main regression risk is zoom staying off after leaving Duck.ai in a tab.

Overview
Disables pinch and double-tap zoom on Duck.ai because zoom breaks the chat layout. Regular browsing and SERP zoom behavior are unchanged.

In browser tabs, a new setWebViewZoomSupported helper turns zoom off when EnableDuckAIFullScreen runs and turns it back on when DuckAIFullScreenDisabled fires (leaving Duck.ai for another URL).

In the contextual Duck.ai sheet, both contextual WebView fragments no longer enable built-in zoom controls and call setSupportZoom(false) at setup, since those WebViews only load Duck.ai.

Reviewed by Cursor Bugbot for commit 2492939. Bugbot is set up for automated code reviews on this repo. Configure here.

Pinch and double-tap zoom distort the Duck.ai chat layout, which is
laid out for a fixed viewport. Zoom is now turned off while a Duck.ai
page is showing in a browser tab, reusing the existing Duck.ai
page-recognition commands, and turned back on when the tab navigates
elsewhere. The contextual sheet WebViews only ever host Duck.ai, so
they disable zoom at creation time and never re-enable it.

Search result pages are unchanged and still zoom.
@malmstein
malmstein marked this pull request as ready for review September 10, 2026 15:06

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Claude Code Review

This repository is configured for manual code reviews. Comment @claude review for a one-time review, or @claude review always to subscribe this PR to a review on every future push.

Tip: disable this comment in your organization's Code Review settings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant