SwiftUI-Tooltip icon indicating copy to clipboard operation
SwiftUI-Tooltip copied to clipboard

.toolTip size = .bottom falls behind other widgets in view

Open Heath-Bitrip opened this issue 1 year ago • 1 comments

Describe the bug When .toolTip(side: .bottom) is set the tool tip doesn't seem to respect Z stack. It puts the tooltip behind other widgets in the view.

To Reproduce Steps to reproduce the behavior:

  1. Set a tooltip to side: .bottom
  2. Observe tool tip in view is below other widgets.

Expected behavior It should respect Z stack; like .toolTip(side: .top) does.

Screenshots

.bottom .top
image image

Smartphone (please complete the following information):

  • Device: iphone SE (2023)
  • OS: iOS 17.3.1

Heath-Bitrip avatar Feb 22 '24 13:02 Heath-Bitrip

i face the sam issue

jeason147 avatar May 08 '24 16:05 jeason147

Put this tooltip in ZStack along with your views.

ZStack { YourView() TooltipButton() }

khawararbi avatar Mar 17 '25 22:03 khawararbi