1

I was going through the WWDC 2020 Widget Code Along and I noticed that when they preview the widget placeholder in the video the redaction generates nicely. But whenever I preview or run the widget, the placeholder positioning is all wrong.

From the Apple WWDC video:

Apple placeholder

Mine:

placeholder unredacted

Notice the placeholder content goes past the bounds of the box.

One thing I did add was .minimumFontScale(0.5) to get Text elements to resize but this doesn't seem to matter for the placeholder. I assume there was some change in Xcode or SwiftUI since the Apple video was created that is causing this difference.

Is there a way to adjust the view or the placeholder so it displays nicely?

shim
  • 9,289
  • 12
  • 69
  • 108

0 Answers0