pub struct Item<'a> {Show 13 fields
pub title: Cow<'a, str>,
pub subtitle: Option<Cow<'a, str>>,
pub icon: Option<Icon<'a>>,
pub uid: Option<Cow<'a, str>>,
pub arg: Option<Cow<'a, str>>,
pub type_: ItemType,
pub valid: bool,
pub autocomplete: Option<Cow<'a, str>>,
pub text_copy: Option<Cow<'a, str>>,
pub text_large_type: Option<Cow<'a, str>>,
pub quicklook_url: Option<Cow<'a, str>>,
pub modifiers: HashMap<Modifier, ModifierData<'a>>,
pub variables: HashMap<Cow<'a, str>, Cow<'a, str>>,
/* private fields */
}Expand description
Representation of a script filter item.
Fields§
§title: Cow<'a, str>Title for the item.
subtitle: Option<Cow<'a, str>>Subtitle for the item.
The subtitle may be overridden by modifiers.
icon: Option<Icon<'a>>Icon for the item
uid: Option<Cow<'a, str>>Identifier for the results.
If given, must be unique among items, and is used for prioritizing feedback results based on usage. If blank, Alfred presents results in the order given and does not learn from them.
arg: Option<Cow<'a, str>>The value that is passed to the next portion of the workflow when this item is selected.
The arg may be overridden by modifiers.
type_: ItemTypeWhat type of result this is.
valid: boolWhether or not the result is valid.
When false, actioning the result will populate the search field with
the autocomplete value instead.
The validity may be overridden by modifiers.
autocomplete: Option<Cow<'a, str>>Autocomplete data for the item.
This value is populated into the search field if the tab key is
pressed. If valid = false, this value is populated if the item is
actioned.
text_copy: Option<Cow<'a, str>>What text the user gets when copying the result.
This value is copied if the user presses ⌘C.
text_large_type: Option<Cow<'a, str>>What text the user gets when displaying large type.
This value is displayed if the user presses ⌘L.
quicklook_url: Option<Cow<'a, str>>A URL to use for Quick Look.
modifiers: HashMap<Modifier, ModifierData<'a>>Optional overrides of subtitle, arg, and valid by modifiers.
variables: HashMap<Cow<'a, str>, Cow<'a, str>>Variables to pass out of the script filter if this item is selected in Alfred’s results.
This property is only used with JSON output and only affects Alfred 3.4.1 or later.