TipKit: Popover Tip w/ use of Menu in Toolbar

As the title states, I'm trying to apply a .popoverTip to a Menu { } which is inside of a .toolbar { }. The toolbar has default placement and the menu includes a toggle button, and a NavigationLink.

I've ensured that tips can show on the view by using a TipView(tip: ) within my view which displays. Am I missing something? Is this not possible?

Alternatively, can anyone recommend a method to potentially debug why a tip won't show for future debugging?

Answered by hallux in 792184022

It appears that the fix is to apply the .popoverTip to the Menu's label contents, not the .toolBarItem itself.

For example:

Menu {
   // Menu Actions
} label: {
   Text("This is my fancy button!")
      .popoverTip(MenuTipView())
}

This seems as the appropriate method because a user sees the label, therefore the Tip anchors itself to the view, which in this case is the label.

Accepted Answer

It appears that the fix is to apply the .popoverTip to the Menu's label contents, not the .toolBarItem itself.

For example:

Menu {
   // Menu Actions
} label: {
   Text("This is my fancy button!")
      .popoverTip(MenuTipView())
}

This seems as the appropriate method because a user sees the label, therefore the Tip anchors itself to the view, which in this case is the label.

TipKit: Popover Tip w/ use of Menu in Toolbar
 
 
Q