class UI::AppShortcuts

Overview

App-shell metadata container for App Shortcuts.

The model is intentionally export-oriented. Host code can collect one or more shortcuts here and serialize the declaration payload into a build step, Intents bundle, or other platform integration layer.

Defined in:

ui/app_shortcuts.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(application_name : String, bundle_identifier : String | Nil = nil, shortcuts : Array(AppShortcut) | Nil = nil) #

[View source]

Instance Method Detail

def add_shortcut(title : String, identifier : String | Nil = nil, subtitle : String | Nil = nil, summary : String | Nil = nil, icon : String | Nil = nil, phrases : Array(String) | Nil = nil, parameters : Array(AppShortcutParameter) | Nil = nil, is_enabled : Bool = true, is_discoverable : Bool = true, &block : AppShortcut -> Nil) : AppShortcut #

[View source]
def add_shortcut(title : String, identifier : String | Nil = nil, subtitle : String | Nil = nil, summary : String | Nil = nil, icon : String | Nil = nil, phrases : Array(String) | Nil = nil, parameters : Array(AppShortcutParameter) | Nil = nil, is_enabled : Bool = true, is_discoverable : Bool = true) : AppShortcut #

[View source]
def add_shortcut(shortcut : AppShortcut) : AppShortcut #

[View source]
def application_name : String #

[View source]
def application_name=(application_name : String) #

[View source]
def bundle_identifier : String | Nil #

[View source]
def bundle_identifier=(bundle_identifier : String | Nil) #

[View source]
def clear : Nil #

[View source]
def export_app_intents_scaffold : String #

[View source]
def find_shortcut(identifier : String) : AppShortcut | Nil #

[View source]
def remove_shortcut(identifier : String) : Bool #

[View source]
def shortcuts : Array(AppShortcut) #

[View source]
def shortcuts=(shortcuts : Array(AppShortcut)) #

[View source]
def to_payload : String #

[View source]