Skip to main content

- AthenaCSS -

pypi GitHub license Discord Downloads


Package Details

Details and features

  • A Python package which allows CSS to be written as a Python script
  • CSS output to file, string or console from the Python script

Python Version

  • Supported Python versions: 3.10
    • Other older versions of Python are not currently supported.
    • These older versions will probably not be supported by @AndreasSas himself, but if you want to contribute to the project and make this package compatible with older versions of Python, Pull requests are always welcome.

Quick Examples

The following example is only a very small CSS code piece, but should bring the idea across of how it works.

from AthenaCSS import *
from AthenaColor import RGB # Dependecy on own other package

with (css_generator := CSSGenerator()) as generator:
    with (rule0 := CSSRule()) as (selector, declaration):
        selector.add(
            SelectorElement.H1(CSSClass("title")),
        )
        declaration.add(
            Property.Color(RGB(128,64,32)),
        )
    generator.add_comment(
        "The following sets the Header with the class of 'title' to have a specific color"
    ).add_rule(
        rule0
    )
css_generator.to_console()

The above code will output the following CSS to the console:

/*The following sets the Header with the class of 'title' to have a specific color*/
h1.title {
    color: rgb(128, 64, 32);
}

Documentation

Full documentation can be found at: directiveathena.com (redirect to Obsidian.md publish site) (Reminder, the documentation is still under heavy development)


Install

To install the package in your Python environment

pip install AthenaCSS --upgrade

Project files can be found at:


Disclaimer

With No Dependency, the standard library is not counted as a dependency


Made By Andreas Sas, 2022

Metadata

Release files for AthenaCSS 0.8.0

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

Source distribution (sdist)

Source distribution for AthenaCSS 0.8.0
File Size Uploaded
AthenaCSS-0.8.0.tar.gz 18.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for AthenaCSS 0.8.0
File Interpreter ABI Platform
AthenaCSS-0.8.0-py3-none-any.whl Python 3 none any Details

Total release size: 36.4 kB

Release files / AthenaCSS-0.8.0.tar.gz

Download URL AthenaCSS-0.8.0.tar.gz
Size 18.5 kB
Tags Source
SHA-256 checksum
How to use checksums
da54433e5614dac318633bd6b0761a1fb02e83201e6d4a78a4401c5972e18af4
BLAKE2b-256 checksum
How to use checksums
ae76f9679c078ed833c82041e48291ba35f40d546de796b29942c5460d4466a8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.0 CPython/3.10.5

Release files / AthenaCSS-0.8.0-py3-none-any.whl

Download URL AthenaCSS-0.8.0-py3-none-any.whl
Size 17.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
9452acbed314ed375038de286c68d62dd40db6cb2a59eb9992df71b4430197db
BLAKE2b-256 checksum
How to use checksums
088812080762da81434f24f9b2a780b1c895c638c9e41783a8ba03f0c84a5dc3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.0 CPython/3.10.5

Release history Release notifications | RSS feed

This release

0.8.0 This release

2 release files

0.7.0

2 release files

0.6.0

2 release files

0.5.1

2 release files

0.5.0

2 release files

0.4.0

2 release files

0.3.0

2 release files

0.2.0

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

0.0.0

2 release files

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