Serializable, resizable panel layouts for spaday, powered by regular-layout.
Documentation
- Build a resizable workspace — guided first layout.
- Persist user layout changes — task-focused state synchronization.
- API reference — layout nodes, components, and events.
- Why layouts are serialized — wrapper design and state model.
Quick example
from spaday import serve
from spaday_regular_layout import RegularLayout, RegularLayoutFrame
layout = {
"type": "split-layout",
"orientation": "horizontal",
"sizes": [0.3, 0.7],
"children": [
{"type": "tab-layout", "tabs": ["nav"]},
{"type": "tab-layout", "tabs": ["main"]},
],
}
page = RegularLayout(
RegularLayoutFrame("Navigation", name="nav"),
RegularLayoutFrame("Main", name="main"),
layout=layout,
style="height: 32rem",
).prop("class", "lorax")
serve(page, packages=["regular-layout"])
layout is the serializable split/tab tree returned by upstream save(). Bind it to application state to restore layouts reactively. Browser changes emit regular-layout-update; use a spaday event action to persist event.detail.
Each frame's content area (regular-layout-frame::part(container)) is display: block with a definite height, not a flex container, so flex: 1 on slotted content silently does nothing. Give slotted content height: 100% to fill a panel.
Run the local example
python -m pip install -e ".[examples]"
python -m spaday_regular_layout.example
Open http://127.0.0.1:8013 to resize and rearrange the complete three-panel example. It
receives a new server layout every five seconds and persists browser rearrangements back to Python. It passes
the local package descriptor directly, so it does not install or resolve the integration from GitHub.
Metadata
Release files for spaday-regular-layout 0.2.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| spaday_regular_layout-0.2.5.tar.gz | 99.2 kB | Details |
Release files / spaday_regular_layout-0.2.5.tar.gz
| Download URL | spaday_regular_layout-0.2.5.tar.gz |
|---|---|
| Size | 99.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e43432fb163365d3ca32b0a105140a7c6c4e79d7f0655b0ceb327f18fccb0fa5
|
|
BLAKE2b-256 checksum How to use checksums |
9c46bbd60213f02632fecea5cd78f9ed8bc64cfc3081578e82c5b45aeb8a36cb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.13
|