shadok-ai 0.19.28 → 0.19.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +10 -3
- package/package.json +1 -1
- package/public/tour-steps.js +127 -15
package/README.md
CHANGED
|
@@ -533,11 +533,18 @@ Enter to skip; you can add it later from the web UI).
|
|
|
533
533
|
rename, change profile, mirror to Telegram, close — and closing it brings the
|
|
534
534
|
card back. Desktop only: the agents column is hidden on phones.
|
|
535
535
|
- **Guided tour** — on a browser's first visit, a welcome card explains what
|
|
536
|
-
shadok-ai is, then a spotlight walks the real controls
|
|
537
|
-
|
|
536
|
+
shadok-ai is, then a spotlight walks the real controls, in up to eleven stops:
|
|
537
|
+
the groups column, the agents list (and rooms), an agent's own bar (gallery,
|
|
538
|
+
about, terminal), its ⋯ menu, schedules and webhooks, the composer (attach, add
|
|
539
|
+
a skill, dictate), the toolbar (secrets, ledger, Skill Factory, profiles,
|
|
540
|
+
Telegram, sound, and what the ⋯ holds), the people buttons (Users, Reports,
|
|
541
|
+
Security), the quota bars, and the cockpit's name and settings menu. Skip and
|
|
538
542
|
Escape end it at any point; ⋯ → *Guided tour* replays it. A step whose target
|
|
539
543
|
isn't on screen is **dropped rather than faked** — an empty cockpit has no
|
|
540
|
-
agent menu,
|
|
544
|
+
agent menu, a cockpit with no group has no groups column, a member has no
|
|
545
|
+
Reports button — so it gets a shorter tour instead of a spotlight on nothing.
|
|
546
|
+
The bubble sits below its target, above it, or **beside** it when the target
|
|
547
|
+
is a full-height column, so it never covers what it describes. The
|
|
541
548
|
**phone gets the whole tour**, because a step can name the landmark on either
|
|
542
549
|
layout (the agents column *or* the channel picker) and is framed on whichever
|
|
543
550
|
one is rendered. On a brand-new instance it comes **before** the sign-in card
|
package/package.json
CHANGED
package/public/tour-steps.js
CHANGED
|
@@ -8,8 +8,16 @@
|
|
|
8
8
|
// See docs/superpowers/specs/2026-08-11-guided-tour-design.md.
|
|
9
9
|
|
|
10
10
|
/**
|
|
11
|
-
* The tour, grouped on purpose: a spotlight frames a REGION, so
|
|
12
|
-
* fit in
|
|
11
|
+
* The tour, grouped on purpose: a spotlight frames a REGION, so some thirty
|
|
12
|
+
* controls fit in ten stops. A step per button is a tour people abandon.
|
|
13
|
+
*
|
|
14
|
+
* It is also a set of CLAIMS about the page, and the page moves faster than
|
|
15
|
+
* this file: it sat at six steps while the cockpit gained groups, rooms, the
|
|
16
|
+
* Skill Factory, webhooks, a composer with three buttons, accounts and a
|
|
17
|
+
* settings menu — none of which a first-time visitor was shown. So when a
|
|
18
|
+
* landmark is added to the page, it is added to a step here (or gets its own),
|
|
19
|
+
* in the same change. `test/tour-steps.test.ts` holds the list of what must be
|
|
20
|
+
* named; it cannot notice a landmark nobody told it about.
|
|
13
21
|
*
|
|
14
22
|
* `target` is a CSS selector, an array of them (framed as one rectangle), or
|
|
15
23
|
* null for the centred welcome card.
|
|
@@ -31,13 +39,30 @@ export const TOUR_STEPS = [
|
|
|
31
39
|
"You drive them from this page — or from Telegram, where one topic is one agent.",
|
|
32
40
|
target: null,
|
|
33
41
|
},
|
|
42
|
+
{
|
|
43
|
+
id: "groups",
|
|
44
|
+
title: "Groups sort the work",
|
|
45
|
+
// Says "can also be a wall" rather than listing private/restricted as
|
|
46
|
+
// things to click: a single-tenant instance (the `npx` default) refuses to
|
|
47
|
+
// create either, and a tour promising a control that answers "not here" is
|
|
48
|
+
// the copy twin of a spotlight on empty space.
|
|
49
|
+
body:
|
|
50
|
+
"Agents are filed into groups — one per project, team or subject. Pick a group to " +
|
|
51
|
+
"narrow the list to it. On a cockpit set up for several people a group can also be a " +
|
|
52
|
+
"wall: restricted to a team or private to you, with its own secrets, and agents that " +
|
|
53
|
+
"run apart from everyone else's.",
|
|
54
|
+
// The rail is hidden when there is nothing to show in it, and a phone lists
|
|
55
|
+
// the groups inside the closed agents sheet — both drop this step honestly.
|
|
56
|
+
target: "#groupRail",
|
|
57
|
+
},
|
|
34
58
|
{
|
|
35
59
|
id: "agents",
|
|
36
60
|
title: "Your agents live here",
|
|
37
61
|
body:
|
|
38
62
|
"Every agent gets its own git worktree and branch, so several never collide. " +
|
|
39
63
|
"Pick one here to follow it, and “+ New agent” starts another. One of them is this " +
|
|
40
|
-
"cockpit's home agent: the only one that cannot be closed."
|
|
64
|
+
"cockpit's home agent: the only one that cannot be closed. A room is the exception: " +
|
|
65
|
+
"a conversation between people, with no agent behind it and no quota spent.",
|
|
41
66
|
// The column on desktop, the agents-picker button on a phone — never both at
|
|
42
67
|
// once. The phone's `#chanPicker` opens the SAME column as a bottom sheet, so
|
|
43
68
|
// "+ New agent" and Tweak are reachable there too now — but the spotlight
|
|
@@ -47,12 +72,26 @@ export const TOUR_STEPS = [
|
|
|
47
72
|
// moment of the spotlight is the same failure as a spotlight on empty space.
|
|
48
73
|
target: ["#tabbar", "#chanPicker"],
|
|
49
74
|
},
|
|
75
|
+
{
|
|
76
|
+
id: "bar",
|
|
77
|
+
title: "Look inside an agent",
|
|
78
|
+
// A list of functions, not of icons in a row — see the toolbar step for
|
|
79
|
+
// what "left to right" cost. Schedule and webhooks sit inside this frame
|
|
80
|
+
// too and are deliberately NOT described here: they get their own stop.
|
|
81
|
+
body:
|
|
82
|
+
"The bar above the conversation is about the agent on screen. The gallery gathers " +
|
|
83
|
+
"every photo and video exchanged with it, “About” lists the skills it uses and its " +
|
|
84
|
+
"schedules, and the terminal shows the raw Claude Code screen — for the rare moment " +
|
|
85
|
+
"the chat is not enough.",
|
|
86
|
+
target: ["#chanGallery", "#chanCron", "#chanWebhooks", "#chanInfo", "#chanTerm"],
|
|
87
|
+
},
|
|
50
88
|
{
|
|
51
89
|
id: "tab",
|
|
52
90
|
title: "Each agent has its own menu",
|
|
53
91
|
body:
|
|
54
|
-
"This ⋯ holds an agent's controls: mute, reload, rename, change its profile,
|
|
55
|
-
"
|
|
92
|
+
"This ⋯ holds an agent's controls: mute, reload, rename, change its profile, its model " +
|
|
93
|
+
"or how hard it thinks, read its token stats, mirror it to a Telegram topic, or have " +
|
|
94
|
+
"it report to another agent when it finishes. " +
|
|
56
95
|
"“Context sent” shows exactly what shadok told it at spawn — and, except for the home " +
|
|
57
96
|
"agent, this is where you close it.",
|
|
58
97
|
// `#chanMenu`, NOT `.tab.active`. Two reasons, and the second is why it
|
|
@@ -70,11 +109,26 @@ export const TOUR_STEPS = [
|
|
|
70
109
|
// prominent thing in the tour, and a first-time visitor never met it.
|
|
71
110
|
id: "schedule",
|
|
72
111
|
title: "They can work while you're away",
|
|
112
|
+
// It said "in that same ⋯ menu" and pointed at the menu, which stayed true
|
|
113
|
+
// (the entries are still there) while the bar grew a button for each — so
|
|
114
|
+
// the tour described a detour past the control in plain sight. It frames
|
|
115
|
+
// the two buttons now, and the menu remains the fallback target for a
|
|
116
|
+
// layout that would not render them.
|
|
73
117
|
body:
|
|
74
|
-
"
|
|
75
|
-
"
|
|
76
|
-
"
|
|
77
|
-
|
|
118
|
+
"A schedule pairs a recurring prompt with a shell check that runs without the model. " +
|
|
119
|
+
"Silent check → nothing happened, the agent stays asleep at zero tokens. Otherwise it " +
|
|
120
|
+
"wakes up holding the finding, and tells you here or on Telegram. A webhook is the " +
|
|
121
|
+
"same idea from outside: an HTTP call from another system wakes the agent.",
|
|
122
|
+
target: ["#chanCron", "#chanWebhooks"],
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
id: "composer",
|
|
126
|
+
title: "Talk to it — with more than text",
|
|
127
|
+
body:
|
|
128
|
+
"Write to the agent here. Attach a file, or paste or drop one in; add one of its " +
|
|
129
|
+
"skills to the prompt; or dictate instead of typing. It works the other way too: " +
|
|
130
|
+
"when an agent's result is a file, it arrives in the conversation as a download.",
|
|
131
|
+
target: "#composer",
|
|
78
132
|
},
|
|
79
133
|
{
|
|
80
134
|
id: "tools",
|
|
@@ -90,9 +144,10 @@ export const TOUR_STEPS = [
|
|
|
90
144
|
// no test here can hold; a list of functions is not.
|
|
91
145
|
body:
|
|
92
146
|
"The secret vault injected into agents that need it, the shared ledger of what your " +
|
|
93
|
-
"agents have already resolved,
|
|
94
|
-
"
|
|
95
|
-
"
|
|
147
|
+
"agents have already resolved, the Skill Factory where skills are written, released " +
|
|
148
|
+
"and shared, profiles (role, guardrails, model), Telegram, and the notification sound. " +
|
|
149
|
+
"On a narrow screen they fold into the ⋯ — which also holds the diff of an agent's " +
|
|
150
|
+
"work, the whole instance's stats, light or dark mode, the palette, and this tour.",
|
|
96
151
|
// NOT `.hdr-tools`, which is `display: contents` on desktop and therefore
|
|
97
152
|
// generates no box at all — its rect is all zeros, so the step would have
|
|
98
153
|
// been dropped as "not visible" on the very layout where the toolbar is
|
|
@@ -107,23 +162,58 @@ export const TOUR_STEPS = [
|
|
|
107
162
|
"#usersBtn",
|
|
108
163
|
"#secretsBtn",
|
|
109
164
|
"#ledgerBtn",
|
|
165
|
+
"#factoryBtn",
|
|
110
166
|
"#profilesBtn",
|
|
167
|
+
"#securityBtn",
|
|
168
|
+
"#reportsBtn",
|
|
111
169
|
"#telegramBtn",
|
|
112
170
|
"#muteNotif",
|
|
113
171
|
"#moreBtn",
|
|
114
172
|
"#starBtn",
|
|
115
173
|
],
|
|
116
174
|
},
|
|
175
|
+
{
|
|
176
|
+
id: "people",
|
|
177
|
+
title: "People, not only agents",
|
|
178
|
+
// Its own step BECAUSE it is conditional: all three buttons start `hidden`
|
|
179
|
+
// and which ones show depends on the role (`loadMe`). Folded into the
|
|
180
|
+
// toolbar body they would be named to people who do not have them. Here the
|
|
181
|
+
// step is dropped when none is rendered — the tour's one rule — and the
|
|
182
|
+
// body says "depends on your role" for the partial case.
|
|
183
|
+
//
|
|
184
|
+
// It does NOT say "this instance has accounts": the lone admin of a
|
|
185
|
+
// no-password instance sees all three, and has none.
|
|
186
|
+
body:
|
|
187
|
+
"A few buttons are about people rather than agents — which ones you see depends on " +
|
|
188
|
+
"your role. Users is where people are invited and where you add a passkey for " +
|
|
189
|
+
"two-factor sign-in, Reports is where a stuck agent asks an admin for help, and " +
|
|
190
|
+
"Security shows what happened to your own account.",
|
|
191
|
+
target: ["#securityBtn", "#reportsBtn", "#usersBtn"],
|
|
192
|
+
},
|
|
117
193
|
{
|
|
118
194
|
id: "quota",
|
|
119
195
|
title: "Watch your quota",
|
|
120
196
|
body:
|
|
121
197
|
"Your 5h and 7d subscription usage. Each bar fills with what you've spent, and the " +
|
|
122
198
|
"white marker is the pace that would spend the window exactly on time — a fill past " +
|
|
123
|
-
"the marker means you're burning faster.
|
|
124
|
-
"
|
|
199
|
+
"the marker means you're burning faster. Past the pace, a new prompt is held back " +
|
|
200
|
+
"unless you choose to send it anyway.",
|
|
125
201
|
target: ["#quota5h", "#quota7d"],
|
|
126
202
|
},
|
|
203
|
+
{
|
|
204
|
+
id: "settings",
|
|
205
|
+
title: "The cockpit's own settings",
|
|
206
|
+
// Was one trailing sentence of the quota step ("to the left… the version
|
|
207
|
+
// beside it"), i.e. a position, on a control the spotlight was not on. The
|
|
208
|
+
// menu behind the version has since become where an instance is configured,
|
|
209
|
+
// which a clause could no longer carry.
|
|
210
|
+
body:
|
|
211
|
+
"The name tells this cockpit apart when you run several; an admin can change it. The " +
|
|
212
|
+
"version opens this instance's settings, most of them an admin's: the Claude account " +
|
|
213
|
+
"and when its sign-in expires, updates and their channel, the permission mode and " +
|
|
214
|
+
"default model for new agents, and the instance context every agent here receives.",
|
|
215
|
+
target: ["#brandName", "#verView", "#verChan"],
|
|
216
|
+
},
|
|
127
217
|
];
|
|
128
218
|
|
|
129
219
|
/** Pure: the steps whose target is on screen, in order. */
|
|
@@ -167,12 +257,34 @@ const clamp = (v, lo, hi) => Math.max(lo, Math.min(v, hi));
|
|
|
167
257
|
*
|
|
168
258
|
* Below by default, flipped above when it would overflow the bottom, and
|
|
169
259
|
* clamped to the viewport on both axes so it is never partly off screen.
|
|
260
|
+
*
|
|
261
|
+
* BESIDE when neither fits, which is every full-height column. Flipping above
|
|
262
|
+
* a target that starts near the top has nowhere to go, so the clamp dropped
|
|
263
|
+
* the bubble ON the column it was describing: the groups step hid the very
|
|
264
|
+
* group names it was pointing at, under a card explaining what groups are.
|
|
265
|
+
* Clamped is "on screen", not "out of the way" — only a side placement is
|
|
266
|
+
* both. When no side has room either (a phone), the old clamp still applies:
|
|
267
|
+
* covering part of the target beats leaving the viewport.
|
|
170
268
|
*/
|
|
171
269
|
export function bubblePlacement({ target, bubble, viewport, gap = 12 }) {
|
|
172
270
|
const below = target.top + target.height + gap;
|
|
173
271
|
const fitsBelow = below + bubble.height + gap <= viewport.height;
|
|
272
|
+
const above = target.top - bubble.height - gap;
|
|
273
|
+
if (!fitsBelow && above < gap) {
|
|
274
|
+
const right = target.left + target.width + gap;
|
|
275
|
+
const left = target.left - bubble.width - gap;
|
|
276
|
+
const beside =
|
|
277
|
+
right + bubble.width + gap <= viewport.width ? right : left >= gap ? left : null;
|
|
278
|
+
if (beside !== null) {
|
|
279
|
+
return {
|
|
280
|
+
side: beside === right ? "right" : "left",
|
|
281
|
+
top: clamp(target.top, gap, viewport.height - bubble.height - gap),
|
|
282
|
+
left: beside,
|
|
283
|
+
};
|
|
284
|
+
}
|
|
285
|
+
}
|
|
174
286
|
const side = fitsBelow ? "below" : "above";
|
|
175
|
-
const rawTop = fitsBelow ? below :
|
|
287
|
+
const rawTop = fitsBelow ? below : above;
|
|
176
288
|
const rawLeft = target.left + target.width / 2 - bubble.width / 2;
|
|
177
289
|
return {
|
|
178
290
|
side,
|