Repository navigation
Conversation
… Settings components
…estyled storage sheet
445f8d7 to
3a4d98c
Compare
There was a problem hiding this comment.
5 issues found across 45 files
Confidence score: 4/5
- The changelog entry in
app/changelog/unreleased/20261005-design-foundation.jsonwill keep the Offline Sync redesign out of mobile release notes. Replace the exemption with a user-facingchangeentry. - In
OmiButton, long labels can overflow whenwrapLabelis used with the legacywidthoption because the height stays fixed. Let the height grow while preserving the requested width. - Long transcript segments can make discarded-conversation rows dominate the list in
synced_conversation_list_item.dart. Cap the title withtitleMaxLines. DeviceTileinapp/lib/widgets/device_tile.dartis not constructed by production code, so its glyph and status presentations never appear in app rows. Wire it into the intended row before adding the component.
You’re at about 93% of the monthly reviewed-line limit. You may want to disable incremental reviews to conserve quota. Reviews will continue until that limit is exceeded. If you need help avoiding interruptions, please contact [email protected].
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="app/lib/widgets/device_tile.dart">
<violation number="1" location="app/lib/widgets/device_tile.dart:14">
P3: No production code constructs `DeviceTile`, so this widget’s glyph and status presentations never reach app rows. Wire it into the intended row before adding the unused component.</violation>
</file>
<file name="app/lib/ui/components/omi_icon_button.dart">
<violation number="1" location="app/lib/ui/components/omi_icon_button.dart:71">
P3: The grouped-page default is `OmiColors.iconTile`, not `OmiColors.surface1`; document the `OmiGroupedScope` case so callers can predict the filled circle.</violation>
</file>
<file name="app/lib/pages/conversations/widgets/synced_conversation_list_item.dart">
<violation number="1" location="app/lib/pages/conversations/widgets/synced_conversation_list_item.dart:81">
P2: Discarded rows use the first transcript segment as the title, so long speech can make one row dominate the list; set `titleMaxLines` to cap it.</violation>
</file>
<file name="app/changelog/unreleased/20261005-design-foundation.json">
<violation number="1" location="app/changelog/unreleased/20261005-design-foundation.json:2">
P2: This marks the PR as having no user-facing change, so release collection omits the Offline Sync redesign from mobile release notes. Replace the exemption with a user-facing `change` entry.</violation>
</file>
<file name="app/lib/ui/components/omi_button.dart">
<violation number="1" location="app/lib/ui/components/omi_button.dart:260">
P2: A wrapped label still gets a fixed `visualHeight` when callers use the legacy `width` option, so long labels can overflow instead of growing. Allow height to grow when `wrapLabel` is true while preserving the requested width.</violation>
</file>
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
| ? const FaIcon(FontAwesomeIcons.waveSquare) | ||
| : Text(conversation.structured.getEmoji(), style: OmiType.title3), | ||
| ), | ||
| title: title, |
There was a problem hiding this comment.
P2: Discarded rows use the first transcript segment as the title, so long speech can make one row dominate the list; set titleMaxLines to cap it.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At app/lib/pages/conversations/widgets/synced_conversation_list_item.dart, line 81:
<comment>Discarded rows use the first transcript segment as the title, so long speech can make one row dominate the list; set `titleMaxLines` to cap it.</comment>
<file context>
@@ -58,135 +60,68 @@ class _SyncedConversationListItemState extends State<SyncedConversationListItem>
+ ? const FaIcon(FontAwesomeIcons.waveSquare)
+ : Text(conversation.structured.getEmoji(), style: OmiType.title3),
),
+ title: title,
+ subtitle: subtitle,
+ trailing: widget.showReprocess || conversation.discarded
</file context>
| title: title, | |
| title: title, | |
| titleMaxLines: 2, |
| @@ -0,0 +1,3 @@ | |||
| { | |||
| "kind": "none" | |||
There was a problem hiding this comment.
P2: This marks the PR as having no user-facing change, so release collection omits the Offline Sync redesign from mobile release notes. Replace the exemption with a user-facing change entry.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At app/changelog/unreleased/20261005-design-foundation.json, line 2:
<comment>This marks the PR as having no user-facing change, so release collection omits the Offline Sync redesign from mobile release notes. Replace the exemption with a user-facing `change` entry.</comment>
<file context>
@@ -0,0 +1,3 @@
+{
+ "kind": "none"
+}
</file context>
| "kind": "none" | |
| "change": "Manage offline recordings more easily with grouped lists and sync status filters" |
| ); | ||
|
|
||
| Widget label = Text(widget.label, style: textStyle, maxLines: 1, overflow: TextOverflow.ellipsis); | ||
| Widget label = widget.wrapLabel |
There was a problem hiding this comment.
P2: A wrapped label still gets a fixed visualHeight when callers use the legacy width option, so long labels can overflow instead of growing. Allow height to grow when wrapLabel is true while preserving the requested width.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At app/lib/ui/components/omi_button.dart, line 260:
<comment>A wrapped label still gets a fixed `visualHeight` when callers use the legacy `width` option, so long labels can overflow instead of growing. Allow height to grow when `wrapLabel` is true while preserving the requested width.</comment>
<file context>
@@ -239,7 +257,9 @@ class _OmiButtonState extends State<OmiButton> {
);
- Widget label = Text(widget.label, style: textStyle, maxLines: 1, overflow: TextOverflow.ellipsis);
+ Widget label = widget.wrapLabel
+ ? Text(widget.label, style: textStyle, textAlign: TextAlign.center)
+ : Text(widget.label, style: textStyle, maxLines: 1, overflow: TextOverflow.ellipsis);
</file context>
| /// with no device of its own (an older row, an unknown source) shows a conversation bubble. A caller | ||
| /// can pass an [icon] instead, and a recap's tile holds its day [emoji]. Decorative: the row names | ||
| /// what it is. | ||
| class DeviceTile extends StatelessWidget { |
There was a problem hiding this comment.
P3: No production code constructs DeviceTile, so this widget’s glyph and status presentations never reach app rows. Wire it into the intended row before adding the unused component.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At app/lib/widgets/device_tile.dart, line 14:
<comment>No production code constructs `DeviceTile`, so this widget’s glyph and status presentations never reach app rows. Wire it into the intended row before adding the unused component.</comment>
<file context>
@@ -0,0 +1,137 @@
+/// with no device of its own (an older row, an unknown source) shows a conversation bubble. A caller
+/// can pass an [icon] instead, and a recap's tile holds its day [emoji]. Decorative: the row names
+/// what it is.
+class DeviceTile extends StatelessWidget {
+ const DeviceTile(
+ {super.key, this.source, this.icon, this.emoji, this.status, this.faded = false, this.missing = false});
</file context>
| /// Circle colour for [OmiIconButton.filled]. Defaults to [OmiColors.surface1]; on an [OmiCanvas] | ||
| /// screen the circle is [OmiGlass] and this tints it. |
There was a problem hiding this comment.
P3: The grouped-page default is OmiColors.iconTile, not OmiColors.surface1; document the OmiGroupedScope case so callers can predict the filled circle.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At app/lib/ui/components/omi_icon_button.dart, line 71:
<comment>The grouped-page default is `OmiColors.iconTile`, not `OmiColors.surface1`; document the `OmiGroupedScope` case so callers can predict the filled circle.</comment>
<file context>
@@ -65,7 +68,8 @@ class OmiIconButton extends StatelessWidget {
final bool filled;
- /// Circle colour for [OmiIconButton.filled]. Defaults to [OmiColors.surface1].
+ /// Circle colour for [OmiIconButton.filled]. Defaults to [OmiColors.surface1]; on an [OmiCanvas]
+ /// screen the circle is [OmiGlass] and this tints it.
final Color? fillColor;
</file context>
| /// Circle colour for [OmiIconButton.filled]. Defaults to [OmiColors.surface1]; on an [OmiCanvas] | |
| /// screen the circle is [OmiGlass] and this tints it. | |
| /// Circle colour for [OmiIconButton.filled]. Defaults to [OmiColors.iconTile] in an [OmiGroupedScope], | |
| /// [OmiColors.surface1] elsewhere; on an [OmiCanvas] it tints the [OmiGlass] fill. |
|
Thanks @Itaxh1 — this is a careful, well-documented piece of work. Reviewed the significant files at the current head:
Two asks before this moves forward:
Leaving for human maintainer review: this is part 4 of the v2 series and sets the Settings typeface and grouped-page/canvas design language, so it needs a product/design-direction sign-off rather than an automated approval. by AI on behalf of David — if you need David’s attention urgently, please @Git-on-my-level and escalate with |
|
Reviewed the Offline Sync rework on head 3a4d98c. What holds up well, file by file where it matters most:
Two things for a maintainer before merge:
No blocking issues found in the code itself; leaving for human maintainer review on the v2 direction and sequencing rather than requesting changes. by AI on behalf of David — if you need David’s attention urgently, please @Git-on-my-level and escalate with |
…ile (#20874) ## What changed and why **What a customer sees today.** Open Offline Sync and one afternoon of recording is a wall of near-identical rows: `1m 15s`, `1m 13s`, `9s`, `29s`, `3m`, `3m`, `3m`… Ten rows from the same afternoon each say *"Too old to sync"*, each with its own **Delete** button. A real user's history is thousands of these. Someone who doesn't know how capture works reads it as a broken app, not as backup files. **Why it looks like that.** Each row is a backup **file**, not a recording. Capture writes a phone file every 75 s (`chunkSizeInSeconds` + `newFrameSyncDelaySeconds`), and the pendant handed storage over in fixed chunks (`sdcardChunkSizeSecs`, 180 s until it became 60 s). Nothing joined them back together for display. **What this PR does.** Offline Sync (`AutoSyncPage`) now shows **one row per recording**: - **Grouping:** files from the same device and place (on the device vs on the phone) join when the gap between them is at most **120 s**, the backend's default `conversation_timeout`. A pause short enough not to end a conversation doesn't end a recording either. Each device and place keeps its own open recording, because their files interleave in the newest-first list (the same audio on phone and device, or two devices recording at once). - **The row:** start time, total length, and the status of its **most serious** file (failed > rejected > unreadable > too old > retrying > backing up > waiting > processing > synced). A recording is never shown healthier than its worst part. - **One action for the recording:** *Try again* re-sends the files that failed. *Delete* (only when nothing can move the recording forward) removes all its files after one confirmation. - **Tap a recording** to open a sheet titled with that recording, listing its files with the existing rows, detail page and actions, so nothing is lost for debugging. - **A one-file recording** keeps today's row exactly, including swipe-to-delete. No new strings: the row and sheet title reuse the existing date, time and duration formatting, and the statuses reuse the existing labels. ## Before / after Same synthetic history (shaped on a customer's real Offline Sync) rendered by `app/scripts/visual_audit.sh` on `main` and on this branch: six 75 s files today, ten 3 min files too old to sync, twelve 9 s–75 s synced files, and fourteen 3 min synced files. | Before (`main`), 42 rows across three screens | | | |---|---|---| | <img src=".agent-artifacts/ui-evidence/20874/001-mobile-ios-offline-sync-before-top.png" width="240"> | <img src=".agent-artifacts/ui-evidence/20874/002-mobile-ios-offline-sync-before-middle.png" width="240"> | <img src=".agent-artifacts/ui-evidence/20874/003-mobile-ios-offline-sync-before-bottom.png" width="240"> | | After (this branch), 4 rows | Tap a recording | |---|---| | <img src=".agent-artifacts/ui-evidence/20874/004-mobile-ios-offline-sync-after.png" width="240"> | <img src=".agent-artifacts/ui-evidence/20874/005-mobile-ios-offline-sync-after-files.png" width="240"> | **In the running app** (iOS Simulator, iPhone 16 Pro, iOS 26.5, local emulator backend, 43 seeded files): | Offline Sync, All | One recording's files | |---|---| | <img src=".agent-artifacts/ui-evidence/20874/006-mobile-ios-offline-sync-simulator-list.png" width="240"> | <img src=".agent-artifacts/ui-evidence/20874/007-mobile-ios-offline-sync-simulator-files.png" width="240"> | ## Product invariants affected none ## How it was verified - **Running app, iOS Simulator:** I seeded 43 files into the app's real recording store (`wals.json` + placeholder audio, via `WalFileManager.saveWals` over the VM service) and hot-restarted so the real load path picked them up. Offline Sync showed **5 rows** (the lone 40 s recording stays a plain single row). - Tapping the 12:56 PM recording opened its 12 files; tapping a file opened its Recording Details page. - **Delete** on the "too old" recording, after one confirmation, removed all 10 files from `wals.json` (43 → 33) and their audio files from disk (43 → 33), and the "10 recordings need attention" card cleared. - **Visual audit:** `app/scripts/visual_audit.sh --base origin/main --head HEAD --only conversations-offline-sync-history,conversations-offline-sync-recording-files` (images above). The files scenario fails on `main` by design, since there is no recording row to tap there. - **Not covered:** the legacy `SyncPage` (devices without multi-file sync) still lists one row per file. It has the same clutter, and I left it out to keep this change reviewable. Happy to follow up with the same grouping there. - **Overlap:** #20715 restyles this page (grouped by day, still one row per file). The grouping lives in its own file (`recording_blocks.dart`) and the page change is small, so whichever lands second merges simply. ## Tests - `test/pages/conversations/recording_blocks_test.dart`: back-to-back 75 s files make one recording; 3 min chunks join and a pause longer than the gap splits; a different device, or the device copy of phone audio, never merges; interleaved phone/device copies and two devices recording at once each group into their own recording (2 rows, not 4); a recording reports its most serious file. - `test/pages/conversations/offline_sync_recording_blocks_test.dart` (page level): ten too-old files render as one row with one Delete; that Delete removes all ten; tapping a recording lists its files. **All three fail with grouping switched off** (checked by replacing the grouping with one block per file). - Severity is an exhaustive `switch`, so a new sync state cannot compile without a rank. - New visual-audit scenarios `conversations-offline-sync-history` and `conversations-offline-sync-recording-files` pass `test/visual_audit/visual_audit_smoke_test.dart` (113 scenarios). - 128 tests across the 11 related suites passed; `app/scripts/analyze_ratchet.sh` passed. ## Failure class (fixes) Failure-Class: none <!-- This is an auto-generated description by cubic. --> <a href="https://cubic.dev/pr/BasedHardware/omi/pull/20874?utm_source=github" target="_blank" rel="noopener noreferrer" data-no-image-dialog="true"><picture><source media="(prefers-color-scheme: dark)" srcset="https://www.cubic.dev/buttons/review-in-cubic-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://www.cubic.dev/buttons/review-in-cubic-light.svg"><img alt="Review in cubic" src="https://www.cubic.dev/buttons/review-in-cubic-dark.svg"></picture></a> <!-- End of auto-generated description by cubic. -->
|
Superseded by #20835. Closing; please follow that PR. |
|
Hey @Itaxh1 👋 Thank you so much for taking the time to contribute to Omi! We truly appreciate you putting in the effort to submit this pull request. After careful review, we've decided not to merge this particular PR. Please don't take this personally — we genuinely try to merge as many contributions as possible, but sometimes we have to make tough calls based on:
Before your next PR, please skim:
If this was declined for direction or taste, maintainers should cite an invariant ID or open a proposed one — ask if that citation is missing. Your contribution is still valuable to us, and we'd love to see you contribute again in the future! If you'd like feedback on how to improve this PR or want to discuss alternative approaches, please don't hesitate to reach out. Thank you for being part of the Omi community! |
TL;DR: Offline Sync gets the Settings look. Recordings are grouped by day under small labels, each day drawn as one outlined card, with All / Pending / Synced as a segmented control, and the page stays lazy with thousands of recordings. Status is black and white, with amber only when something is held up and red when it failed. The status card keeps main's download meter. The storage sheet, a recording's page, synced conversations, the legacy sync page and the storage card follow. Part 4 of 9 of the v2 cleaner UX; it needs #20342 first.
What changed and why
Offline Sync is the busiest page behind Settings. On
maineach recording was its own card with coloured status pills, so a long list read as noise and mounted every row at once.auto_sync_page.dart):OmiGroupedSlice), so only what is on screen is built;OmiSegmentedControl, and the label over the list says "Recordings 12" with the sort order.DeviceDownloadMeterwhile the pendant's files come down. A recording coming down shows a slim meter under its row.offline_sync_storage_sheet.dart): icons in tiles, no status colours. The counts and subtitles use ink at 70%, which is still 4.5:1 on the card in light and dark.wal_item_detail_page.dart), synced conversations, the legacy sync page (sync_page.dart), local storage and private cloud. Each is on the grouped page with outlined cards.status_action_pill.dart(replaced by compactOmiButton.secondary), andutils/responsive/responsive_helper.dart, whose last caller was the storage card.Screenshots
Before is
main(4bdcc56d0d), after is this branch (with #20342 under it). Rendered byapp/scripts/visual_audit.sh(real widgets, flutter-tester, 390×844 at 2×, fixture data, light theme). An emulator would need a real sign-in, so these are the repo's own before/after renders. The edge-case scenarios come from #20714'ssettings_edge.dart, run against both sides.main)Product invariants affected
none
How it was verified
flutter analyze: no errors or warnings (the 89 infos are all onmain).dart format --line-length 120: clean.flutter test) on this branch: 4,669 passed, 14 skipped, 1 failed. The failure wastest/unit/omi_ring_custody_test.dart("persisted durable frontier replays…"), pendant custody code this PR doesn't touch: it deletes its temp folder while the store may still be writing to it, and failed while two suites ran on the machine at once. Run alone on this branch it passed 15/15, three times in a row.scripts/pr-preflightwith this body: passed.Tests
test/widgets/synced_conversation_list_item_test.dart(new): a screen reader opens a synced row and reaches Reprocess as its action, not as a separate button.test/widgets/device_storage_card_test.dart: the usage bar turnsOmiColors.warningnear full andOmiColors.dangerwhen critical (it read the removedResponsiveHelpercolours before).test/widgets/sync_error_card_test.dart: the long error still reflows in full, now inside a scroll view as on the sync pages, because at 2× text the whole message is taller than the test screen.test/widgets/device_download_meter_test.dart: the meter's Cancel is a compactOmiButton.secondary.Failure class (fixes)
Failure-Class: none