Mask-based button hiding, no backdrop#88
Conversation
|
Warning Rate limit exceeded
Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 3 minutes and 18 seconds. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Greptile SummaryThis PR refactors the split-button area in the tab bar to use a single unified mask ( Key changes:
Minor cleanup items found:
Confidence Score: 5/5
Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Tab bar frame] --> B[.mask combinedMask]
B --> C{shouldShowButtons?}
C -- Yes --> D[Left fade 24px\nif canScrollLeft]
C -- Yes --> E[Center solid black]
C -- Yes --> F[Right fade 24px\ncanScrollRight OR shouldShowButtons]
C -- Yes --> G[Clear area 90px\nhides scroll content behind buttons]
C -- No --> H[Left fade 24px\nif canScrollLeft]
C -- No --> I[Center solid black]
C -- No --> J[Right fade 24px\nif canScrollRight only]
B --> K[.overlay alignment trailing]
K --> L{showSplitButtons?}
L -- Yes --> M[splitButtons\nopacity controlled by shouldShow\neaseInOut 0.14s]
L -- No --> N[No overlay rendered]
|
| let fadeWidth: CGFloat = 24 | ||
| let shouldShowButtons = showSplitButtons && (presentationMode != "minimal" || isHoveringTabBar) | ||
| let buttonClearWidth: CGFloat = shouldShowButtons ? 90 : 0 | ||
| let buttonFadeWidth: CGFloat = shouldShowButtons ? fadeWidth : 0 |
There was a problem hiding this comment.
Unused variable
buttonFadeWidth
buttonFadeWidth is computed and assigned but never referenced anywhere in combinedMask. It appears to be a leftover from development. Consider removing it.
| let buttonFadeWidth: CGFloat = shouldShowButtons ? fadeWidth : 0 | |
| let buttonClearWidth: CGFloat = shouldShowButtons ? 90 : 0 |
Summary by cubic
Switches the tab bar to a single combined mask that fades scroll edges and hides the split-button area, letting buttons float without a backdrop. Removes the gradient/solid backdrop so the tab bar background shows through naturally.
fadeOverlayswith a newcombinedMaskapplied to the bar.splitButtonsrender above the bar.combinedMaskadds left/right fades and a clear button strip when shown, with a short animation.Written for commit fbb9057. Summary will update on new commits.