Skip to main content

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 WebApp class.
  • 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

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. 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

web_in_python_lol-0.2.2.tar.gz (8.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

web_in_python_lol-0.2.2-py3-none-any.whl (9.5 kB view details)

Uploaded Python 3

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

Hashes for web_in_python_lol-0.2.2.tar.gz
Algorithm Hash digest
SHA256 a8642aa473c05f782a69107210aa17e340863254f230eb427366084fd7fb717b
MD5 a6cd0dfbc08ef4e5a398e7deae83195b
BLAKE2b-256 b6c4784e6d8b6072f2e0ed2469d3ad5ce9fdcf9755df4188a28490d4a65ed24f

See more details on using hashes here.

File details

Details for the file web_in_python_lol-0.2.2-py3-none-any.whl.

File metadata

File hashes

Hashes for web_in_python_lol-0.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 b2a825073f19c8bd5007e0e96f434a93c5bf43ae33028a3ece2d47e60d3da06f
MD5 76a626f2771c48869bfea66551f7833e
BLAKE2b-256 b2eda5efef7e00748fbff034bf91dff3cbe7278557c4f97ae51ad14a128a86f6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page