Skip to content

chore: Dialogs examples in TestApp#157

Merged
abelonogov-ld merged 12 commits intomainfrom
andrey/dialogs-in-testapp
Mar 18, 2026
Merged

chore: Dialogs examples in TestApp#157
abelonogov-ld merged 12 commits intomainfrom
andrey/dialogs-in-testapp

Conversation

@abelonogov-ld
Copy link
Copy Markdown
Contributor

@abelonogov-ld abelonogov-ld commented Mar 18, 2026

Refactor Test app:

  • Dialogs
  • Metrics
image

Note

Low Risk
Changes are confined to the TestApp demo UI and observability/replay sample actions; no production logic or security-sensitive flows are modified.

Overview
Refactors the TestApp main menu into clearer sections for Session Replay, Observability, and Benchmark, replacing the old toggle-row navigation with a two-column UIKit/SwiftUI action grid and adding an in-app toggle to start/stop LDReplay.

Adds new dialog demo screens for both UIKit and SwiftUI, including alerts, confirmation/action sheets, bottom sheets, half-sheet overlays, view overlays, and oversized-UIWindow presentations via a new WindowSheetPresenter/DimSizing helper. Also expands the observability demo to record multiple metric types (gauge, histogram, count, incremental, upDownCounter) and updates the Observability serviceName to observability-ios-test-app.

Written by Cursor Bugbot for commit 56faf8b. This will update automatically on new commits. Configure here.

Squashed commits:
[bd9564d] res attr
* main:
  chore(main): release 0.24.0 (#151)
  feat: pod specs (#150)
  chore: update podspecs for observability and session replay (#148)
* main:
  feat: Identify Proxy, Record and Logs for MAUI (#149)
@abelonogov-ld abelonogov-ld enabled auto-merge (squash) March 18, 2026 20:22
Copy link
Copy Markdown

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 2 potential issues.

Fix All in Cursor

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

])

window.addSubview(dimView)
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Missing view controller containment causes timer leak

Low Severity

showCurrentWindowSizing adds timerVC.view as a subview of dimView without proper view controller containment (addChild/didMove(toParent:)), unlike the analogous methods showHalfSheetSizing, showWindowSizing, and showViewOverlay which all use proper containment. Without it, viewDidDisappear is never called when the dim view is tapped away, so stopTimer() never runs and the CountdownTimerViewController's repeating timer continues firing after dismissal. The cleanup closure also strongly captures timerVC, creating a retain cycle through onComplete.

Additional Locations (1)
Fix in Cursor Fix in Web

}

timerVC.onComplete = cleanup
dimView.onTap = cleanup
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Cleanup closures create retain cycles leaking view controllers

Low Severity

The cleanup closures in showHalfSheetSizing, showCurrentWindowSizing, and showViewOverlay strongly capture both timerVC and dimView, then get assigned to timerVC.onComplete and dimView.onTap. This creates retain cycles (timerVConComplete → closure → timerVC, and similarly for dimView), so neither object is ever deallocated after cleanup runs. Other methods in the same file (e.g. showFullSheet) correctly use [weak timerVC] to avoid this.

Additional Locations (2)
Fix in Cursor Fix in Web

@abelonogov-ld abelonogov-ld merged commit 17a5475 into main Mar 18, 2026
6 checks passed
@abelonogov-ld abelonogov-ld deleted the andrey/dialogs-in-testapp branch March 18, 2026 20:31
abelonogov-ld added a commit that referenced this pull request Mar 18, 2026
* main:
  chore: Dialogs examples in TestApp (#157)
abelonogov-ld added a commit that referenced this pull request Mar 18, 2026
* main:
  chore(main): release 0.26.1 (#160)
  chore: test app memory leaks (#158)
  fix: make iOS requests recognized by backend (#159)
  chore: Dialogs examples in TestApp (#157)

# Conflicts:
#	TestApp/Sources/AppDelegate.swift
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.

2 participants