giangvo / alfred-workflow-nodejs

A small library providing helpers to create Alfred Workflow

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

AlfredNode.Item.mods Example?

kobitate opened this issue · comments

Hello,

I see in the documentation that there is a mods option for the AlfredNode.Item object. Is this to support separate attributes when using modifier keys? I can't seem to find any examples within the repo.

Thanks!
Kobi

Hi,
I will update example to include "mods".

var item3 = new Item({
    title: "item 3",
    subtitle: "sub 3",
    mods: {
        cmd: {
            valid: true,
            arg: "cmd arg",
            subtitle: "pressing cmd"
        },
        alt: {
            valid: false,
            arg: "alt arg",
            subtitle: "pressing alt"
        }
    }
});

Awesome! Thanks for the example.