ControlWidget fails to render Image with asset image in a ControlWidgetButton

Hi there. I build a ControlWidget to let users perform action in the control center.

The Image View inside the ControlWidgetButton fails to render the images from the Assets. It seems like it can only render Symbols from SFSymbols using the Image(systemName:) API.

Here is the code to reproduce this issue:

struct LockedCamWidgetExtensionControl: ControlWidget {
    var body: some ControlWidgetConfiguration {
        StaticControlConfiguration(
            kind: "com.juniperphoton.widget.control"
        ) {
            ControlWidgetButton(action: MyAppCaptureIntent()) {
                Image(.actionButton)
            }
        }
        .displayName("Launch Camera")
        .description("A an example control that launch camera.")
    }
}

Note that I can ensure the image can be displayed in the normal Widget in Home Screen and its target also includes the Widget Extension itself.

So is this a feature or a bug? If we can only use the SFSymbols provided by the system, then users are hard to distinguish the difference between apps.

I tested the app built agains Xcode 16 Beta 5 and iOS 18 Developer Beta 6.

same here! i think custom image works in previous beta, like 1 or 2. but recently it does not work anymore.

I've got the same issue. Custom Images worked on beta 1, 2 and 3 of Xcode 16 but not since beta 4.

Same problem here in Xcode 16.1 Beta!

ControlWidget fails to render Image with asset image in a ControlWidgetButton
 
 
Q