Valstorm Guide & Tour Builder Manual
Learn how to author, run, and debug interactive user walkthroughs and automated tours in the Valstorm Desktop platform using the Guide Builder.
Welcome to the comprehensive guide for authoring, running, and debugging interactive user walkthroughs and automated tests in the Valstorm Desktop platform.
📑 Table of Contents
- Overview & Architecture
- How to Access & Launch the Guide Builder
- Step Types: Tooltip vs Modal vs Banner
- Targeting Elements (The UX Prefix System)
- Advance Conditions (How Steps Progress)
- Auto-Execution & Tour Mode
- Step-by-Step Authoring Workflow
- Common Gotchas & Best Practices
- Complete JSON Schema Reference
1. Overview & Architecture
The Valstorm Guide System is built on the Observer Triad:
- DOM Ground Truth (UX Prefix System): Target any button, input, or section by its stable
#id(e.g.desktop-nav-left-panel-btn-new-chat,ai-chat-composer-textarea). - Action Ground Truth (Command Bus): Steps advance automatically when matching commands fire on the bus (e.g.
navigation:app_select,workspace:new_chat,commander:open). - Reactive Guide Runner (
GuideRunner): Uses an SVG Cutout Spotlight so users can click and type directly through the spotlight hole into targeted components without backdrop capture issues.
2. How to Access & Launch the Guide Builder
You can open the Guide Builder in Valstorm Desktop via three ways:
- Keyboard Shortcut: Press
Cmd + Shift + B(macOS) orCtrl + Shift + B(Windows/Linux). - DX Bottom Drawer: Open the Dev Console (
Cmd + \``), click the **GUIDES & TOURS** tab, and click **Open Guide Builder`**. - Top Navbar Menu: Click your user avatar / profile menu in the top right and select
Guide & Tour Builder.
Pro Tip: The Guide Builder panel is draggable. Grab the top title bar and park it anywhere on your screen so it never blocks the elements you are trying to target.
3. Step Types: Tooltip vs Modal vs Banner
Every step in a guide has a type property. Choosing the right type is critical for how the card is positioned:
| Step Type | When to Use | Positioning Behavior | Target Element Needed? |
|---|---|---|---|
tooltip | Pointing at a specific button, input, or card | Anchors directly to the target element (Top, Bottom, Left, Right) with an active pulsing spotlight cutout. | Yes (targetElementId) |
modal | Introduction, overview, or congratulations screens | Centered in the middle of the viewport as a focused dialog box. | No (Optional) |
banner | High-level page section callouts | Anchors with wider padding alongside the selected section. | Yes (targetElementId) |
⚠️ Crucial Nuance:
- If you set
"type": "modal", the engine treats it as a general popup dialog and centers the card in the middle of the screen, ignoring element positioning. - If you want the card to point at a button, input, or box, always choose
"type": "tooltip"!
4. Targeting Elements (The UX Prefix System)
To ensure guides never break when UI designs change, Valstorm uses deterministic UX Prefix Conventions:
| Layout Zone | Standard Prefix | Examples |
|---|---|---|
| Top Navigation | top-navigation- | top-navigation-search-btn, top-navigation-logo, top-navigation-command-palette-btn |
| Left Sidebar | desktop-nav- | desktop-nav-left-panel-btn-new-chat, desktop-nav-app-entry-btn-crm |
| AI Chat | ai-chat- | ai-chat-composer-textarea, ai-chat-composer-box, ai-chat-btn-send, ai-chat-header |
| DX Console | dx- | dx-drawer-toggle-btn, dx-tab-guides-btn, dx-tab-console-btn |
| Main Content | main-content- | main-content-table-root, main-content-form-submit |
Using the Smart "Pick Element" Tool:
- In GuideBuilder, click the
Pick Elementcrosshair button. - Hover over any element on the screen:
- Green Badge (
#id): Element has a valid UX ID. Clicking it binds the target ID instantly. - Orange Badge (
⚠️ Missing ID): Element does not have an ID.
- Green Badge (
- If you click an element without an ID:
- GuideBuilder displays a warning banner with a 💡 Suggested ID (e.g.
#desktop-nav-left-panel-btn-new-chat). - Click
Use Suggested IDto populate the step, then addid="..."to your React component.
- GuideBuilder displays a warning banner with a 💡 Suggested ID (e.g.
5. Advance Conditions (How Steps Progress)
The advanceCondition determines what triggers the guide to jump to the next step:
1. manual (Click Next)
- The user reads the card and clicks the "Next" button in the tooltip.
- Best for: Informational steps, explanations, and overview steps.
2. click (DOM Click / Focus)
- The step advances immediately when the user clicks or focuses into the targeted element.
- Best for: "Click the New Chat button", "Click into the search bar", "Click on CRM".
- Note: For inputs and textareas, both
clickandfocustrigger the advance.
3. command (Command Bus Event)
- The step advances as soon as a specific Command Bus action is dispatched anywhere in the app (even if triggered via keyboard shortcuts or subagents).
- Format:
domain:action(e.g.navigation:app_select,workspace:new_chat,commander:open,phone:dial). - Wildcard Matching: You can use
commander:*to match any commander action, or*to match any action. - Best for: Keyboard shortcuts (
Cmd+K), asynchronous processes, and multi-app switching.
4. delay (Timed Auto-Advance)
- Automatically advances after
delayMsmilliseconds (e.g. 3000ms). - Best for: Automated demo reels and quick splash cards.
6. Auto-Execution & Tour Mode
Guides can be configured to execute actions programmatically for Automated E2E Testing or AI-Driven Auto-Tours:
"autoExecuteCommand": {
"domain": "navigation",
"action": "app_select",
"payload": { "appName": "crm" }
}- In the Guide tooltip, an "Auto Perform" button appears.
- Clicking it dispatches the command directly through
commandBus.dispatch(...). - In headless automated test runners (like Playwright), the test runner can loop through each step and dispatch
autoExecuteCommandto drive the entire application autonomously!
7. Step-by-Step Authoring Workflow
Here is the ideal workflow to create a seamless interactive tour:
Step 1: Initialize
- Press
Cmd + Shift + Bto open the Guide Builder. - Click
+ Newto start a blank guide. - Type the Guide Name (e.g.
Getting Started with AI Chat) and a short description.
Step 2: Author Steps
- Step 1 (Click New Chat):
- Title:
1. Start New Chat - Type:
tooltip| Placement:right - Target:
desktop-nav-left-panel-btn-new-chat - Advance:
click
- Title:
- Step 2 (Interact with Input):
- Title:
2. Ask AI Anything - Type:
tooltip| Placement:top - Target:
ai-chat-composer-textarea - Advance:
click(advances as soon as user clicks into the box)
- Title:
- Step 3 (Type & Send):
- Title:
3. Send Message - Type:
tooltip| Placement:top - Target:
ai-chat-composer-box - Advance:
manual(user types and clicks "Finish")
- Title:
Step 3: Save & Test
- Click
💾 Save: Saves the guide to persistent browser storage. - Click
▶ Test: The builder closes and the interactive tour starts immediately so you can test the exact user experience live.
8. Common Gotchas & Best Practices
modalvstooltip: If you provide atargetElementId, make sure the type istooltip(orbanner), notmodal.- Asynchronous Page Transitions: When Step 1 navigates to a new tab (e.g.
/phoneorai_chat://new), child elements take ~100–200ms to mount. The GuideRunner automatically polls and waits for the element with aMutationObserver, but always ensure the target ID matches the mounted component. - Backdrop Click-Through: The GuideRunner uses an SVG
fillRule="evenodd"cutout mask. You can click, highlight, scroll, and type directly inside the spotlighted area without clicking the dark backdrop. - Copying / Version Controlling Guides: Click the
JSONbutton in the Guide Builder toolbar to copy the clean JSON schema directly to your clipboard or commit it to code.
9. Complete JSON Schema Reference
{
"id": "guide-sample-id",
"name": "Human-Readable Guide Title",
"description": "Short explanation of what this guide teaches.",
"category": "onboarding",
"version": 1,
"triggerContext": {
"route": "/crm",
"autoStart": false
},
"steps": [
{
"id": "step-1",
"title": "Step Title",
"content": "Markdown-formatted explanation for the user.",
"type": "tooltip",
"placement": "bottom",
"spotlight": true,
"highlightPadding": 6,
"targetElementId": "top-navigation-command-palette-btn",
"advanceCondition": {
"type": "command",
"commandPattern": "commander:open"
},
"autoExecuteCommand": {
"domain": "commander",
"action": "open"
}
}
]
}