Skip to main content
spaday-regular-layout logo, a picnic blanket and basket inside a browser window

Serializable, resizable panel layouts for spaday, powered by regular-layout.

Build Status codecov License PyPI

Documentation

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

Run the complete example in your browser — Python runs locally through Pyodide; no install or server required.

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.3.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for spaday-regular-layout 0.3.3
File Size Uploaded Provenance Actions
spaday_regular_layout-0.3.3.tar.gz 119.1 kB Without provenance Details for spaday_regular_layout-0.3.3.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for spaday-regular-layout 0.3.3
File Interpreter ABI Platform Actions
spaday_regular_layout-0.3.3-py3-none-any.whl Python 3 none any Details for spaday_regular_layout-0.3.3-py3-none-any.whl

Total release size: 191.9 kB

Release files / spaday_regular_layout-0.3.3.tar.gz

Download URL spaday_regular_layout-0.3.3.tar.gz
Size 119.1 kB
Tags Source
SHA-256 checksum
How to use checksums
20c9f59138ee485e1bbd7581e61650a445c2659f5d2a8d70338524043c20e364
BLAKE2b-256 checksum
How to use checksums
e67fa6fac7145e9971430c81b6c546ce71c1f62d86e09fd5a2a813776a759781
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.15

Release files / spaday_regular_layout-0.3.3-py3-none-any.whl

Download URL spaday_regular_layout-0.3.3-py3-none-any.whl
Size 72.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6fc549f3eeac8cdbd52ddcd33877e34eabc2409ad4e4d3237ba1162227114210
BLAKE2b-256 checksum
How to use checksums
9b60e26d924d46ee8646f89e3c1f7a961ff4e5fd48f1a2fd148142f112b9af40
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.15

Security for spaday-regular-layout 0.3.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page