Skip to content

Improve performance and Material 3 expressive UI - #1

Open
Rabkaps wants to merge 3 commits into
mainfrom
performance-and-ui-improvements-15161341920059722547
Open

Improve performance and Material 3 expressive UI#1
Rabkaps wants to merge 3 commits into
mainfrom
performance-and-ui-improvements-15161341920059722547

Conversation

@Rabkaps

@Rabkaps Rabkaps commented Jun 15, 2026

Copy link
Copy Markdown
Owner

This addresses the user's issue concerning app lag/stutter at launch and visual updates.
I have:

  • Re-architected heavy LaunchedEffect blocks handling network subscription updates and setting resolutions to run explicitly via Dispatchers.IO so that they don't block the UI thread during composition.
  • Overhauled the WaveVisualizer calculating arrays on every frame into proper Animatable transitions in loops with a long duration, reducing composition passes.
  • Increased the corner radius of generic cards, buttons, and chips matching closer to typical MD3 expressive layouts.
  • Updated AnimatedVisibility and AnimatedContent structures for transitions.
  • Allowed surface colors to propagate fully in dark mode rather than forcing them to pitch black, letting expressive components breathe.

PR created automatically by Jules for task 15161341920059722547 started by @Rabkaps

- Fixed UI stuttering at launch by moving heavy settings and subscription
parsing loads off the main UI thread during initial composition.
- Refactored `WaveVisualizer` animation loops using proper `Animatable`
float arrays inside coroutines rather than continuous `while(true)` loops
calculating sines and cosines on the main thread.
- Increased the prominence of the Material 3 Expressive shapes by making
corner radii closer to spec defaults.
- Updated the theme colors to not enforce pure black on surface containers
when using dark mode to allow natural expressive tints to show through.
- Used `AnimatedContent` for search bar toggle transitions to reduce layout
jumping and improve the UX.
- Resolved compile SDK dependency mismatch errors in build.gradle.kts.

Co-authored-by: Rabkaps <102897583+Rabkaps@users.noreply.github.com>
@google-labs-jules

Copy link
Copy Markdown

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

google-labs-jules Bot and others added 2 commits June 15, 2026 15:53
- Fixed UI stuttering at launch by moving heavy settings and subscription
parsing loads off the main UI thread during initial composition.
- Refactored `WaveVisualizer` animation loops using proper `Animatable`
float arrays inside coroutines rather than continuous `while(true)` loops
calculating sines and cosines on the main thread.
- Increased the prominence of the Material 3 Expressive shapes by making
corner radii closer to spec defaults.
- Updated the theme colors to not enforce pure black on surface containers
when using dark mode to allow natural expressive tints to show through.
- Used `AnimatedContent` for search bar toggle transitions to reduce layout
jumping and improve the UX.
- Resolved compile SDK dependency mismatch errors in build.gradle.kts.

Co-authored-by: Rabkaps <102897583+Rabkaps@users.noreply.github.com>
- Fixed UI stuttering at launch by moving heavy settings and subscription
parsing loads off the main UI thread during initial composition.
- Refactored `WaveVisualizer` animation loops using proper `Animatable`
float arrays inside coroutines rather than continuous `while(true)` loops
calculating sines and cosines on the main thread.
- Increased the prominence of the Material 3 Expressive shapes by making
corner radii closer to spec defaults.
- Updated the theme colors to not enforce pure black on surface containers
when using dark mode to allow natural expressive tints to show through.
- Used `AnimatedContent` for search bar toggle transitions to reduce layout
jumping and improve the UX.
- Resolved compile SDK dependency mismatch errors in build.gradle.kts.
- Added `.animateItem()` to List items for smoother UI.

Co-authored-by: Rabkaps <102897583+Rabkaps@users.noreply.github.com>
@Rabkaps
Rabkaps force-pushed the main branch 11 times, most recently from b79c72c to 91f02df Compare June 28, 2026 20:20
Rabkaps added a commit that referenced this pull request Aug 2, 2026
…race condition

BUG #1 (CRITICAL): MainActivity shortcut 'Connect Fastest' sequential pings
→ Now uses concurrent async pings (~2s instead of 100s), staying within
  the Android 12+ ForegroundService exemption window.

BUG #2 (CRITICAL): CdnIpScanner.getCleanIp() bare runBlocking
→ Now uses runBlocking(Dispatchers.IO) to prevent main-thread ANR.

BUG #3 (CRITICAL): CensorshipDiagnostics TLS test ignored SNI parameter
→ Now wraps plain socket with sslFactory.createSocket(socket, sni, port)
  so the SNI extension is properly set in the TLS ClientHello.

BUG #6/7 (HIGH): IpCountryResolver blocking IO + cache race condition
→ Added @synchronized to saveCache() to prevent file corruption.
→ Added NetworkOnMainThreadException catch for DNS resolution fallback.

BUG #8 (HIGH): VpnQuickSettingsTileService unlockAndRun delays FGS start
→ Removed unlockAndRun wrapper. VPN service starts immediately regardless
  of lock state, preventing ForegroundServiceStartNotAllowedException.
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