Repository navigation
Getting Started
darsrc edited this page Jun 12, 2026
·
12 revisions
This page gets LCARS-WebUI installed and running. For a fuller application walkthrough, continue with Tutorial: Build a Dashboard.
- Python 3.10+
- Git
- Node.js 18+ only if you plan to edit frontend source
git clone https://github.com/darsrc/LCARS-WebUI.git
cd LCARS-WebUI/lcars-ui
python -m venv .venv
source .venv/bin/activate
pip install -e ".[dev]"Windows PowerShell activation:
.\.venv\Scripts\Activate.ps1PYTHONPATH=src python examples/dashboard.pyOpen http://127.0.0.1:8000/ if the browser does not open automatically.
To run without opening a browser:
LCARS_OPEN_BROWSER=0 PYTHONPATH=src python examples/dashboard.pyCreate my_dashboard.py:
import lcars_ui as lcars
def ui() -> None:
lcars.config("Bridge Ops", subtitle="Strict LCARS", theme="galaxy")
lcars.nav("Main", page="main", color="orange-peel")
with lcars.page("Main", id="main", layout="console"):
with lcars.data_panel("Operations", color="orange", id="operations"):
lcars.metric("Warp Core", "98%", status="ok", color="anakiwa", id="warp-core")
lcars.progress("Shield Recharge", 72.0, color="golden-tanoi", id="shield-recharge")
with lcars.control_panel("Commands", color="orange", id="commands"):
if lcars.button("Red Alert", color="red", id="red-alert"):
lcars.set_alert_condition("red")
lcars.notify("Battle stations", level="error")
if lcars.button("Stand Down", color="anakiwa", id="stand-down"):
lcars.set_alert_condition("normal")
lcars.notify("Alert cleared")
if __name__ == "__main__":
lcars.run(ui)Run it:
python my_dashboard.py-
lcars.config(...)sets app metadata, theme, and visual behavior. -
lcars.nav(...)links the sidebar to a page id. -
lcars.page(...)declares a page and layout archetype. -
data_panelandcontrol_panelgive the adaptive layout useful LCARS structure. -
metricandprogressare display widgets. -
buttonis a momentary action and returnsTrueonly for the click being handled. -
notifyandset_alert_conditionare effects, so they belong inside button branches.
The screenshots in this wiki come from the bundled kitchen sink app:
LCARS_PORT=8126 LCARS_OPEN_BROWSER=0 PYTHONPATH=src python examples/kitchen_sink/app.pyIt demonstrates:
-
Console: data panels, readouts, controls, live logs -
Telemetry: a dominant data view with side readouts -
Grid: repeated subsystem cells -
Widgets: primitives, data widgets, inputs, forms, and media widgets