title: ContextMenu on a rounded LinearGradient produces sharp edges in SwiftUI
body: <p>I have the following view:</p>
  <pre class="lang-swift prettyprint-override"><code>struct ContentView: View {
      var body: some View {
          LinearGradient(gradient: Gradient(colors: [.blue, .red]), startPoint: .topTrailing, endPoint: .bottomLeading)
              .cornerRadius(16)
              .frame(width: 140, height: 140)
              .contextMenu {
                  Button(&quot;&quot;, action: {})
              }
      }
  
  }
  </code></pre>
  <p>However, when the ContextMenu is invoked, the edges are not rounded:</p>
  <p><a href="https://i.stack.imgur.com/ACMiH.png" rel="noreferrer"><img src="https://i.stack.imgur.com/ACMiH.png" alt="enter image description here" /></a></p>
  <p>I've tried several things, such as:</p>
  <ul>
  <li>Applying the <code>clipShape</code> modifier to clip it to a <code>RoundedRectangle</code></li>
  <li>Wrapping the gradient as the background of a RoundedRectangle view</li>
  <li>Using a Color instead of a LinearGradient (which works as expected, but not what I need)</li>
  </ul>
  <p>However none work. Any advice would be appreciated, thanks!</p>