Re-arrange existing UI in AI Features screen #8935
Open
anikiki wants to merge 4 commits into
Open
Conversation
…yout. This will be used later.
…gs layout when the flag is enabled.
joshliebe
approved these changes
Jun 22, 2026
joshliebe
left a comment
Contributor
There was a problem hiding this comment.
Tested, works as expected with the feature toggle enabled and disabled. LGTM! 🙂
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.

Task/Issue URL: https://app.asana.com/1/137249556945/project/1200581511062568/task/1215808956430402?focus=true
Tech Design URL (if applicable):
Description
Reorganizes the Duck Chat (AI Features) settings screen behind the aiFeaturesNativeControls feature flag.
The block of input-screen settings — the address-bar With AI / Without AI toggle, its description, "Default toggle position", Duck.ai shortcuts, automatic context attachment, and dividers — is extracted from activity_duck_chat_settings.xml into a reusable include_duck_ai_input_screen_settings.xml layout. This is a no-op refactor on its own (same views, same IDs, same behavior).
When aiFeaturesNativeControls is enabled, that block is relocated to the end of the settings screen (below the Search settings section) and gains its own "Duck.ai" section header with a top divider. The redundant searchSettingsSectionHeader is hidden in this mode. The new header + divider are only shown while the user has Duck.ai enabled. When the flag is disabled, the screen renders exactly as before.
Changes
Steps to test this PR
Flag OFF (default / regression check)
Flag ON
UI changes
Note
Low Risk
UI-only, feature-flagged layout reorder with no changes to settings storage or navigation; flag off preserves current production behavior.
Overview
Reorganizes the AI Features settings screen when
aiFeaturesNativeControlsis enabled, while keeping the default (flag off) layout unchanged.Input-screen settings (With/Without AI toggle, default toggle position, shortcuts, automatic context, dividers) are extracted into
include_duck_ai_input_screen_settings.xmland wired throughIncludeDuckAiInputScreenSettingsBindinginstead of the main activity layout.ViewState.isNativeControlsEnabledis added and sourced fromduckChatFeature.aiFeaturesNativeControls().When native controls are on, the activity moves that include to the bottom of the scroll content (below Search settings) once via
moveInputScreenSettingsToEnd(), shows a Duck.ai section header and top divider only when Duck.ai is user-enabled, and hides the redundant Search settings section header. ViewModel tests cover the new flag state; setting persistence and navigation are unchanged.Reviewed by Cursor Bugbot for commit 4a5c070. Bugbot is set up for automated code reviews on this repo. Configure here.