Skip to content

fix: improve locked conversation UI with subtle frosted previews - #20044

Merged
Git-on-my-level merged 4 commits into
BasedHardware:mainfrom
Itaxh1:fix/flutter-locked-conversation-preview
Oct 1, 2026
Merged

Git-on-my-level merged 4 commits into
BasedHardware:mainfrom
Itaxh1:fix/flutter-locked-conversation-preview

Conversation

@Itaxh1

@Itaxh1 Itaxh1 commented Oct 1, 2026 •

Copy link
Copy Markdown
Collaborator

What changed and why

Improves the Flutter locked-conversation UI with a subtle frosted preview and a small lock beside a transparent, readable upgrade action. Locked titles previously remained sharp behind an overlapping upgrade label; the new treatment obscures the card content consistently in light and dark mode while preserving the existing paywall and selection behavior.

Closes #20035.

Before and after

The after screenshots are from the updated app on a physical iPhone, reviewed and approved by the reporter.

Before — reported issue After — improved light UI After — improved dark UI
Before: locked conversation titles overlap the upgrade label After in light mode: softly blurred cards with a clear transparent upgrade action After in dark mode: softly blurred cards with a clear transparent upgrade action

Product invariants affected

  • INV-UI-1: uses the existing neutral palette in both appearances.
  • INV-UI-3: adds and documents the shared OmiLockedPreview primitive, using OmiButton.tertiary, existing tokens, and the localized upgrade label. Obscured content is excluded from pointer input and accessibility semantics; the upgrade action retains the user's text scale.

How it was verified

  • flutter test --no-pub test/widgets/conversation_locked_preview_test.dart — all 7 tests passed.
  • Focused dart analyze on the component, conversation row, regression tests, and visual-audit scenario — no issues.
  • OMI_PR_BODY_FILE=/tmp/omi-frosted-pr-final.md make preflight and scripts/pr-preflight --pr-body-file /tmp/omi-frosted-pr-final.md — all 22 repository contract checks passed.
  • Light and dark visual audits passed using the real conversation list with synthetic data.
  • A clean, signed iOS profile build was installed and launched on an iPhone 15 Pro Max. The reporter verified the revised cards in both appearances and supplied the screenshots above.

Local limitations: the full app test suite did not finish under resource pressure. The full analyzer ratchet reported an existing unused import in unchanged app/test/support/recording_analytics.dart; focused analysis is clean. Full-suite success is not claimed.

Tests

app/test/widgets/conversation_locked_preview_test.dart exercises the production conversation row in light/dark mode at 100% and 200% text size. It verifies that the content is blurred and excluded from semantics, the action remains outside the blur with a transparent background, text contrast is at least 4.5:1, the tap target is at least 44 points, unlocked rows stay readable, and paywall navigation and selection behavior are preserved.

The conversations-locked-preview visual-audit scenario covers a mixed list of unlocked and locked conversations. A mobile changelog entry records the UI improvement.

Failure class (fixes)

Failure-Class: none

This defect is caused by the locked-preview rendering composition; the existing selection-layout and tap-activation classes describe different causes.

Review in cubic

@cubic-dev-ai cubic-dev-ai 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.

No issues found across 7 files

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Re-trigger cubic

@Git-on-my-level

Copy link
Copy Markdown
Member

Reviewed this head (1e94e51) file by file — this is a clean, cohesive fix for #20035. Thanks @Itaxh1, the reporter-approved before/after and the invariant citations made this easy to verify.

Per file:

  • app/lib/ui/components/omi_locked_preview.dart (new): Good shape as a shared primitive. The child-only ImageFiltered blur is bounded by ClipRRect(OmiRadius.xlAll) so it can't bleed onto the scrolling backdrop; IgnorePointer + ExcludeSemantics wrap the obscured content; MediaQuery.withNoTextScaling keeps the decorative blurred content from exploding at large text scales; and the non-positioned action participating in the card's height is the right call. All colors/spacing come from Omi tokens — INV-UI-1 clean in both modes.
  • conversation_list_item.dart: Behavior-preserving refactor. Extracting the tap handler and reusing it as the preview's onPressed keeps the UsagePage(showUpgradeDialog: true) paywall destination and the selection-mode guard (haptic + "cannot be merged" toast for ineligible rows) exactly as before — the new widget test confirms both. Adding conversation.isLocked to the Selector visualSignature was the right catch so locked→unlocked transitions rebuild the row.
  • conversation_locked_preview_test.dart (new): Solid coverage — blur containment, semantics exclusion, ≥44 pt target, computed 4.5:1 contrast against least-favorable content in both brightnesses and text scales {1.0, 2.0}, the unlocked-row regression, paywall destination, and selection mode. Hermetic (mocked prefs, injectable fetchers, NavigatorObserver instead of pumping the network-backed usage screen).
  • visual_audit/scenarios/conversations.dart: The conversations-locked-preview scenario with one unlocked + three locked synthetic rows is a good addition.
  • ux-contract.md, ui.dart, changelog JSON: The new contract row matches the implementation, the export is consistent with siblings, and the changelog line is accurate.

Two non-blocking notes for a maintainer:

  1. ExcludeSemantics removes the locked conversation's title entirely from the semantics tree. Sighted users see a frosted preview; screen-reader users get only "Upgrade to Unlimited" with no way to tell locked rows apart. Defensible (locked content shouldn't be advertised), but an a11y/product call — e.g. a redacted "Locked conversation" semantics label would preserve distinguishability. Leaving for human maintainer review on that trade-off.
  2. The Dart Analyze & Tests lane was skipped on this head, so the new widget tests currently have only the reported local run as evidence. Nothing alarming given the passing Hygiene/Formatting/eligibility gates, but worth confirming the suite runs them before merge.

No approval from automation here — leaving the formal sign-off to a human maintainer (paywall surface + the a11y trade-off above). Content-wise this looks merge-ready to me.


AI-generated maintainer feedback on behalf of the Omi maintainers.


by AI on behalf of David — if you need David’s attention urgently, please @Git-on-my-level and escalate with need human response.

@Git-on-my-level Git-on-my-level added flutter flutter work positive-signal Automation verified a genuine fix/quality contribution labels Oct 1, 2026
@Itaxh1 Itaxh1 added the needs-maintainer-review Needs a human maintainer to sign off before merge label Oct 1, 2026
Resolve conversation_list_item.dart conflict: keep main's _SwipeDeleteRow
structure and route the card through the PR's OmiLockedPreview content
builder (_buildCardContent) with the extracted onTap handler.
@Git-on-my-level
Git-on-my-level self-requested a review as a code owner October 1, 2026 12:48
Resolve conversation_list_item.dart conflict: keep main's _SwipeDeleteRow
structure and route the card through the PR's OmiLockedPreview content
builder (_buildCardContent) with the extracted onTap handler.
@Git-on-my-level
Git-on-my-level merged commit d54a620 into BasedHardware:main Oct 1, 2026
34 checks passed
Git-on-my-level added a commit that referenced this pull request Oct 1, 2026
…ge argument so main compiles (#20216)

* fix(app): restore the locked-preview card content and drop a stale ChatPage argument so main compiles

The merge of #20044 kept the call to _buildCardContent but dropped the method,
the isLocked row signature and the removal of the old locked overlay. The
conversation-detail merge re-added startFresh: true, which #20015 removed.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* chore(app): changelog for the locked preview overlay

Co-Authored-By: Claude Opus 5.5 <[email protected]>

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

flutter flutter work needs-maintainer-review Needs a human maintainer to sign off before merge positive-signal Automation verified a genuine fix/quality contribution

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Flutter: blur locked conversation previews and keep the upgrade action readable

2 participants