help() view modifier

I have a bunch of Buttons with a .help(Text("Help text")) modifier, inside of a VStack which has its own .help() modifier describing the entire section.

The VStack help shows up only when I hover over the buttons, and the Button help never shows at all.

If I comment out the VStack help, the individual button helps show.

How do I get both to show up properly? I want the VStack to show if I am in the roundedBorder, unless I am over a Button with its own .help modifier.

import SwiftUI

struct BugReport: View {
  @State private var testp1 = false
  @State private var testp2 = false
    var body: some View {
      VStack {
        Text("Hello, World!")
        Button("Test1") {
          testp1.toggle()
        }
        .help("Change the test1")
        Button("Test2") {
          testp2.toggle()
        }
        .help("Change the test2")
      }
      .help("Testing stuff")
      .roundedBorder(color: .black)
    }
}

#Preview {
    BugReport()
}

Hello hacksaw,

For clarification, is this for a macOS application? And what is the .roundedBorder modifier you are referring to?

Thank you for your patience,

Richard Yeh ||  Developer Technical Support

Ooops, forgot I wrote that modifier, here it is:

extension View {
  func roundedBorder(style: StrokeStyle = StrokeStyle(lineWidth: 1.0), color: Color = Color(#colorLiteral(red: 0.8039215803, green: 0.8039215803, blue: 0.8039215803, alpha: 1))) -> some View {
    modifier(RoundedBorder(strokeStyle: style, color: color))
  }
}

This is for macOS, yep.

Note commenting out the roundedBorder modifier doesn't change this behaviour.

help() view modifier
 
 
Q