import AppIntents
import Foundation
import SwiftUI

public struct CreateShortcutsProvider: AppShortcutsProvider {
    public init() {}

    public static var appShortcuts: [AppShortcut] {
        AppShortcut(
            intent: CreateClipWithTextIntent(),
            phrases: [
                "Make a new song with \(.applicationName)", // First one in this list shows up in the `Recent Searches` section in Spotlight
                "Create a new song with \(.applicationName)",
                "Create a new clip with \(.applicationName)",
                "New song with \(.applicationName)",
                "Make a song with \(.applicationName)",
                "Create new song with \(.applicationName)",
                "Create new clip with \(.applicationName)",
                "Make a song with \(.applicationName)", // First one with \(.applicationName) shows up in the `Siri Suggestions` section in Spotlight
                "Make a new song with \(.applicationName)",
                "\(.applicationName) make a new song",
                "\(.applicationName) create a new song",
            ],
            shortTitle: LocalizedStringResource("create_shortcut_make_a_song", table: "CreateAppShortcutsAndIntents"),
            systemImageName: "square.and.pencil"
        )
        AppShortcut(
            intent: CreateClipWithAudioIntent(),
            phrases: [
                "Record a new clip with \(.applicationName)",
                "Start recording with \(.applicationName)",
                "Upload a clip to \(.applicationName)",
                "Record a clip with \(.applicationName)",
                "\(.applicationName) record a clip",
            ],
            shortTitle: LocalizedStringResource("create_shortcut_record_a_clip", table: "CreateAppShortcutsAndIntents"),
            systemImageName: "music.mic"
        )
        AppShortcut(
            intent: CreateClipWithCameraIntent(),
            phrases: [
                "Take a photo or video with \(.applicationName)",
                "Take a photo on \(.applicationName)",
                "Take a selfie with \(.applicationName)",
                "Record a video on \(.applicationName)",
                "Upload a photo to \(.applicationName)",
                "Upload a video to \(.applicationName)",
                "New scene with \(.applicationName)",
                "Create a new scene with \(.applicationName)",
                "Open camera in \(.applicationName)",
                "Take a photo with \(.applicationName)",
                "Record a video with \(.applicationName)",
                "Create a scene with \(.applicationName)",
                "Open \(.applicationName) camera",
                "Make a scene with  \(.applicationName)",
                "Open camera with \(.applicationName)",
            ],
            shortTitle: LocalizedStringResource("create_shortcut_take_a_photo", table: "CreateAppShortcutsAndIntents"),
            systemImageName: "camera.fill"
        )
    }
}
