.md →
CellTour API#
Bases: DriverTour
Simplified tour widget for marimo notebooks.
Wraps DriverTour with cell-aware step helpers so you can reference
marimo cells by index or data-cell-name attributes. Works in both
marimo edit mode and app mode (marimo run / molab); the cell
selectors require marimo >= 0.23, when app mode started rendering
.marimo-cell and [data-cell-name] on cell containers.
Examples:
Using cell indices:
import marimo as mo
from wigglystuff import CellTour
tour = mo.ui.anywidget(CellTour(steps=[
{"cell": 0, "title": "Imports", "description": "Load libraries"},
{"cell": 2, "title": "Processing", "description": "Data transformation"},
]))
tour
Using cell names (requires naming cells in marimo):
import marimo as mo
from wigglystuff import CellTour
tour = mo.ui.anywidget(CellTour(steps=[
{"cell_name": "imports", "title": "Imports", "description": "Load libraries"},
{"cell_name": "process", "title": "Processing", "description": "Transform data"},
]))
tour
Create a CellTour widget.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
steps
|
Sequence[dict]
|
List of step dictionaries with cell, title, description keys. |
()
|
auto_start
|
bool
|
Start tour automatically on render. |
False
|
show_progress
|
bool
|
Show step progress indicator. |
True
|
**kwargs
|
Any
|
Forwarded to |
{}
|
Source code in wigglystuff/cell_tour.py
CellTour works in both marimo edit mode and app mode (marimo run /
molab). The cell selectors it emits (.marimo-cell and
[data-cell-name="…"]) require marimo >= 0.23, when app mode started
rendering those markers on cell containers.
Synced traitlets#
| Traitlet | Type | Notes |
|---|---|---|
steps |
list[dict] |
DriverTour-style steps (CellTour inputs are normalized). |
auto_start |
bool |
Start tour automatically on render. |
show_progress |
bool |
Show progress indicator when true. |
active |
bool |
Whether the tour is currently running. |
current_step |
int |
Index of the active step. |