shortCuts

struct MeditationShortcuts: AppShortcutsProvider
{
        AppShortcut(
            intent: OCRIntent(),
            phrases: [AppShortcutPhrase<OCRIntent>.init("OCR识别\(AppShortcutPhraseToken.applicationName)")],
            shortTitle: "文字识别",
            systemImageName: "checklist"
        )
    }
    
    static var shortcutTileColor: ShortcutTileColor {
        return .orange
    }
}

Why packaging shortcut instructions in the above way will not be displayed in the shortcut instruction app?

Defining a phrase in literal terms will show, for example

struct MeditationShortcuts: AppShortcutsProvider
{
    static var appShortcuts: [AppShortcut] {
        AppShortcut(
            intent: OCRIntent(),
            phrases: ["OCR识别\(.applicationName)"],
            shortTitle: "文字识别",
            systemImageName: "checklist"
        )
    }
    
    static var shortcutTileColor: ShortcutTileColor {
        return .orange
    }
}
shortCuts
 
 
Q