Skip to content

feat: Full UI customization for reel counter and mindful message overlays#236

Merged
nethical6 merged 5 commits into
kt-rewritefrom
copilot/customize-message-ui
Apr 29, 2026
Merged

feat: Full UI customization for reel counter and mindful message overlays#236
nethical6 merged 5 commits into
kt-rewritefrom
copilot/customize-message-ui

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Apr 23, 2026

  • Understand current code and all three issues
  • Add textOpacity field to ReelCounterOverlayConfig and MindfulMessageConfig
  • Apply textOpacity in ReelsOverlayManager and MindfulMessageOverlayManager
  • Add text_opacity_label/text_opacity_value strings
  • Add text opacity slider to both fragment layouts
  • Create OverlayDragHelper.kt — color chips + drag overlay (DRY extraction)
  • Fix position mismatch: getLocationOnScreen() for save; subtract decorView offset for initial placement
  • Rewrite ReelCounterFragment using helper, wire text opacity
  • Rewrite MindfulMessagesFragment using helper, wire text opacity
  • Add updateTextOpacity() to MindfulMessagesViewModel
  • Guard against division by zero in OverlayDragHelper position save

- Add textSize, bgColor, bgOpacity, positionX, positionY to MindfulMessageConfig
- Create ReelCounterOverlayConfig data class with same fields
- Add reelCounterOverlayConfig to Settings
- Add updateReelCounterOverlayConfig() to DataStoreManager
- Create OverlayPositionPickerView custom view for 2D position picking
- Update MindfulMessageOverlayManager to use config for styling and positioning
- Update ReelsOverlayManager to accept ReelCounterOverlayConfig
- Update ReelsCountTracker to propagate overlayConfig to startDisplaying()
- Update MindfulMessagesViewModel with new update methods for all config fields
- Update ReelCounterViewModel with overlayConfig StateFlow and updateOverlayConfig()
- Replace fragment_mindful_messages.xml with appearance customization UI
- Add appearance customization section to fragment_reel_counter.xml
- Update MindfulMessagesFragment and ReelCounterFragment for new UI
- Add string resources for appearance labels

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Co-authored-by: nethical6 <79095297+nethical6@users.noreply.github.com>
- OverlayPositionPickerView: override onMeasure to enforce 9:16 portrait aspect ratio
- fragment_reel_counter.xml: add live preview card, set picker height to wrap_content
- ReelCounterFragment.kt: drive live preview (color, opacity, text size, position)
- fragment_mindful_messages.xml: add live preview card, set picker height to wrap_content
- MindfulMessagesFragment.kt: drive live preview
- Add bg_preview_phone drawable and live_preview string resource

Agent-Logs-Url: https://github.com/nethical6/digipaws/sessions/0b9b241f-c254-4e21-972f-7bd05b986db7

Co-authored-by: nethical6 <79095297+nethical6@users.noreply.github.com>
…tion setting

- Remove OverlayPositionPickerView (custom grid picker) and mockup preview cards
- Add "Set Position" button to reel counter and mindful messages screens
- Tapping button shows actual overlay widget (overlay_usage_stat / mindfulmsg_overlay)
  on the decorView as a draggable view the user can move anywhere on screen
- OK button saves position as x/y fractions and dismisses the scrim
- Scrim is properly removed on fragment destroy to avoid leaks
- Delete OverlayPositionPickerView.kt and bg_preview_phone.xml (no longer used)

Agent-Logs-Url: https://github.com/nethical6/digipaws/sessions/65c81aee-b48f-4ca5-a27a-e105e5167cea

Co-authored-by: nethical6 <79095297+nethical6@users.noreply.github.com>
Copilot AI and others added 2 commits April 24, 2026 13:14
- Fix position mismatch: use getLocationOnScreen() on widget when saving
  to get screen-absolute coords matching WindowManager overlay managers;
  subtract decorView screen offset for correct initial placement
- Add textOpacity field to both overlay configs (default 80 for reel, 100 for mindful)
- Apply textOpacity in ReelsOverlayManager (alpha on TextViews) and
  MindfulMessageOverlayManager (argb text color alpha)
- Add text opacity sliders to both fragment layouts and string resources
- Create OverlayDragHelper: single place for PRESET_COLORS, buildColorChips,
  refreshChipSelection, and showDragOverlay (DRY extraction)
- Both fragments now delegate to OverlayDragHelper; all color chip and drag
  overlay code lives in one place
- Add updateTextOpacity() to MindfulMessagesViewModel

Agent-Logs-Url: https://github.com/nethical6/digipaws/sessions/05e3819c-47ba-42ee-8353-2bd39338f560

Co-authored-by: nethical6 <79095297+nethical6@users.noreply.github.com>
@nethical6 nethical6 marked this pull request as ready for review April 29, 2026 17:07
@nethical6 nethical6 merged commit 8028760 into kt-rewrite Apr 29, 2026
1 check passed
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