The card file
Where cards show
The menu, menu bar, Dock, pop-out, Dashboard, iPhone, widgets, shortcuts and Siri.
One card shows up in many places. Give each a deliberate answer: most cards need one good card and a short status, and add a separate pop-out or iPhone card only when that place needs something different.
Every surface
| Surface | What people see | What drives it |
|---|---|---|
| TailApps menu | The card in the stacked menu, at narrow width, or one row that opens into it. | views.menubar: card, in_menu |
| Menu bar status | The card’s own item in the macOS menu bar, if the person keeps it there. | views.menubar: label, label_tone, label_icon, label_fill |
| Dock status | A round button in TailApps’ Dock that opens into a coloured pill when busy, warn or bad. | The same label, label_tone and label_icon |
| Pop-out window | The card in its own floating window, from ⋯ › Pop Out, a Dock click or a shortcut. | views.floating: card, width, pin, chrome, tabs |
| Dashboard | A tile on the Mac’s Dashboard grid. | The menu card, in full |
| iPhone | The card’s screen on the phone, and its tile on the Home list. | views.phone: card or tabs |
| iPhone notifications | A banner even with TailApps closed, and an item in the phone’s Inbox. | alert on a send step; notify on the device that runs it |
| Widgets | A widget on the iPhone Home Screen or the Mac desktop that shows the card. | Nothing to declare: the card, with its last values |
| Shortcuts, Siri and Spotlight | “Run Mute in System Controls”. | "expose": true on an action |
| Keyboard | A global shortcut that opens the card or runs an action, and hold-to-talk. | shortcuts: open, actions, on_release |
views
"views": {
"menubar": {
"icon": "cloud",
"label": "$deploys.0.status | upper",
"card": "main"
},
"floating": {
"card": "main",
"pin": true
}
}
Optional: how the app looks when popped out into its own window (any app can pop out from its ⋯ menu; this picks the card, width and whether it starts on top). The user's Keep on Top choice wins over pin
| card | card id |
| pin | bool: always on top |
| width | narrow | default | wide |
| chrome | default | none: no header or frame, just the card (a card starting with a tile becomes the window); the user can switch the header back from a right-click |
| tabs | app tabs instead of card (SPEC §65.7): 2 to 5 { "card", "label" (at most 24), "icon" (SF Symbols) }, a segmented control under the header; the menu and Dashboard show the first. The pick is remembered |
Optional: the card the iPhone shows. Add it only when the phone should do something different, not just smaller (the renderer adapts to width). Without it the phone shows the menubar card, else the floating card, else the first card
| card | card id |
| tabs | app tabs instead of card (SPEC §65.7): 2 to 5 { "card", "label" (at most 24), "icon" (SF Symbols) }, along the bottom like the system's tab bar; the Home tile shows the first. The pick is remembered |
Rules of thumb
- Always give a status (
label, pluslabel_toneandlabel_iconwhen the state changes). Without one the card can’t appear in the menu bar or the Dock’s status area. - Card or row: something you glance at (a monitor, a status) is a
rowwith a good label; a tool with buttons and fields is acard. - Design the menu card to stand alone. The Dashboard shows it, and so does the iPhone unless you set
views.phone. - Pop-outs for things people keep open (a log, a chat, a checklist, a timer): set
views.floating, itswidth, andpinto float on top."chrome": "none"drops the header for a bare timer or a camera bubble. - Countdowns never poll. Store the end time and show it with a
timerpart or$ends_at | until: they redraw every second by themselves. - Tokens only. Tone, size, emphasis, gap and one
style.accent; no pixel sizes or colours.
On the iPhone
- Without
views.phonethe phone shows the menu card. Give the phone its own card when its buttons must do something different, for example send a command to your computer. - A button whose action can’t run on the phone (a command, a script, a screen recording) shows Needs a Mac. Give a Mac-only part
"platforms": ["macos"]to hide it on the phone instead. - Two to five separate screens: app tabs,
"views": { "phone": { "tabs": [{ "card": "list", "label": "List", "icon": "list.bullet" }, …] } }, a bottom bar on the phone and a segmented control in the Mac’s pop-out. - Keys meant for a finger: a
gridof buttons with"size": "l".
Widgets
Widgets on the iPhone Home Screen and the Mac desktop show a card with the values TailApps saved when it was last on screen; the iPhone widget draws the card the phone shows. Widgets run no sources, so put the number or status that matters at the top of that card, not in a map or an image. A card whose state is over 256 KB gets no widget. There’s nothing to declare: the person adds the widget and picks the card.
Shortcuts, Siri and Spotlight
"expose": true on an action offers it to Shortcuts, Siri and Spotlight as “Run <action> in <card>”. The name is the action’s key made readable (mute → Mute), so give exposed actions clear keys. Only for actions with no arguments, no confirm and no tap-only step. The other way round, a shortcuts.run step runs one of the person’s own Shortcuts.
Keyboard shortcuts
| Keys | Modifiers mod (⌘), ctrl, opt, shift joined with +, then one key: "mod+opt+d", "ctrl+shift+2". Global shortcuts need a modifier. |
| Scopes | global, app |
Global keys are suggestions; the user confirms them at setup. An action's global shortcut may add on_release: another action (no args) that runs when the keys are let go, for hold-to-talk: start recording on press, stop and transcribe on release.
"shortcuts": {
"open": {
"keys": "mod+opt+q",
"scope": "global"
},
"actions": {
"grab": {
"keys": "ctrl+shift+2",
"scope": "global"
},
"listen": {
"keys": "ctrl+opt+d",
"on_release": "transcribe"
}
}
}