Control Center widget won't show snippet view

Has anyone been able to create a Control Center widget that opens a snippet view? There are stock Control Center widgets that do this, but I haven't been able to get it to work.

Here's what I tried:

struct SnippetButton: ControlWidget {
    var body: some ControlWidgetConfiguration {
        StaticControlConfiguration(
            kind: "***.***.snippetWidget"
        ) {
            ControlWidgetButton(action: SnippetIntent()) {
                Label("Show Snippet", systemImage: "map.fill")
            }
        }
        .displayName(LocalizedStringResource("Show Snippet"))
        .description("Show a snippet.")
    }
}

struct SnippetIntent: ControlConfigurationIntent {
    
    static var title: LocalizedStringResource = "Show a snippet"
    static var description = IntentDescription("Show a snippet with some text.")

    @MainActor
    func perform() async throws -> some IntentResult & ProvidesDialog & ShowsSnippetView {
        
        return .result(dialog: IntentDialog("Hello!"), view: SnippetView())
    }
}

struct SnippetView: View {

    var body: some View {
    
        Text("Hello!")
        
    }
    
}

It doesn't appear like this is supported at the moment, but would love to hear from Apple to learn more!

I have filed an enhancement request per OP's forum post: FB14587703. We would love to see this supported by Controls.

Control Center widget won't show snippet view
 
 
Q