A responsive, Python-only UI engine for rapid dashboards
Project description
🌑 web-in-python-lol Engine
A lightweight, Python-only UI engine designed for building rapid dashboards and web interfaces without touching HTML, CSS, or JavaScript. Built on top of a standard HTTP server with zero external Python dependencies.
✨ Features
- Python-Native: Write your entire UI in pure Python classes.
- Zero Dependencies: Uses only the standard library (
http.server,sqlite3, etc.). - Hot Reloading: Automatic page refreshes when the database state changes.
- Built-in Persistence: SQLite3 backend integrated directly into the
WebAppclass. - Responsive by Default: Modern flexbox/grid components that work on mobile and desktop.
- Lucide Icons: Integrated professional SVG icons out of the box.
🚀 Quick Start
1. Installation
pip install web-in-python-lol
2. Create your first App
from Engine.core import WebApp, Container, Card, Text, Button, Navbar
# Initialize the App
app = WebApp(name="MyDashboard")
@app.page("/")
def home(instance, params):
return [
Navbar("App", [("Home", "/"), ("Settings", "/settings")]),
Container([
Card([
Text("Welcome to ShadowUI").font_size("24px").weight("bold"),
Text("Building UIs in Python has never been this easy."),
Button("Get Started").m_top("20px")
])
])
]
if __name__ == "__main__":
app.start(port=8080)
🛠 Component Toolkit
ShadowUI provides a declarative way to build layouts. Every component supports method chaining for styling.
| Component | Description |
|---|---|
Container |
Centers content with a max-width (ideal for main pages). |
Row / Column |
Flexbox-based layouts for horizontal or vertical stacking. |
Grid |
Responsive CSS Grid for cards and galleries. |
Card |
A styled container with borders and padding. |
Navbar |
Responsive navigation bar with mobile hamburger menu support. |
Icon |
Embed 1,000+ professional icons via Lucide. |
💾 Database & State
includes a thread-safe SQLite wrapper. Use it to store settings or app state that triggers auto-reloads.
# Save data
app.store("user_theme", "dark")
# Fetch data
theme = app.fetch("user_theme", default="light")
📱 Mobile Support
includes a built-in "hamburger" menu system. When the screen width drops below 768px, the Navbar automatically collapses into a mobile-friendly toggle.
🤝 Contributing
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature) - Commit your Changes (
git commit -m 'Add some AmazingFeature') - Push to the Branch (
git push origin feature/AmazingFeature) - Open a Pull Request
📄 License
Distributed under the MIT License. See LICENSE for more information.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file web_in_python_lol-0.2.2.tar.gz.
File metadata
- Download URL: web_in_python_lol-0.2.2.tar.gz
- Upload date:
- Size: 8.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a8642aa473c05f782a69107210aa17e340863254f230eb427366084fd7fb717b
|
|
| MD5 |
a6cd0dfbc08ef4e5a398e7deae83195b
|
|
| BLAKE2b-256 |
b6c4784e6d8b6072f2e0ed2469d3ad5ce9fdcf9755df4188a28490d4a65ed24f
|
File details
Details for the file web_in_python_lol-0.2.2-py3-none-any.whl.
File metadata
- Download URL: web_in_python_lol-0.2.2-py3-none-any.whl
- Upload date:
- Size: 9.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b2a825073f19c8bd5007e0e96f434a93c5bf43ae33028a3ece2d47e60d3da06f
|
|
| MD5 |
76a626f2771c48869bfea66551f7833e
|
|
| BLAKE2b-256 |
b2eda5efef7e00748fbff034bf91dff3cbe7278557c4f97ae51ad14a128a86f6
|