Flask-FomanticUI
Flask-FomanticUI is a collection of Jinja macros for Fomantic UI and Flask for the global style. Very similar to Bootstrap-Flask.
Features
- Table generation: Render data objects (dict or class objects) to Fomantic UI Table.
- Paginate generation: Render Flask-SQLAlchemy
Paginationobject to Fomantic UI Pagination. - Form generation: Render Flask-WTF/WTForms form object to Fomantic UI Form, etc.
Requirements
Python 3.8+
Dependecies for this project.
- Flask(>=2.0.2) for build the backend.
intallation
You can install via pip:
$> pip install Flask-FomanticUI
Example
Register the extension:
from flask import Flask
# To follow the naming rule of Flask extension, although
# this project's name is Flask-FomanticUI, the actual package
# installed is named `flask_fomanticui`.
from flask_fomanticui import FomanticUI
app = Flask(__name__)
fomantic = FomanticUI(app)
Assuming you have a Flask-WTF form like this:
class LoginForm(FlaskForm):
username = StringField('Username', validators=[DataRequired(), Length(1, 20)])
password = PasswordField('Password', validators=[DataRequired(), Length(8, 150)])
submit = SubmitField()
remember = BooleanField('Remember me')
Now with the render_ui_form macro:
{% from 'fomanticui/form_ui.html' import render_ui_form %}
<html>
<head>
<!-- Fomantic UI - CSS -->
</head>
<body>
<h2>Login</h2>
{{ render_ui_form(form) }}
<!-- Fomantic UI - JS -->
</body>
</html>
You will get a form like this with only one line code (i.e. {{ render_ui_form(form) }}):
When the validation fails, the error messages will be rendered with proper style:
Read the Basic Usage docs for more details.
Links
Authors
- Ferreira, Juan David
Please submit bug reports, suggestions for improvements and patches via the (E-mail: juandavid9a0@gmail.com).
Contributors
Credits goes to these peoples:
Official repository and Issues
License
Flask-FomanticUI is free software you can redistribute it and/or modify it
under the terms of the MIT License. For more information, you can see the
LICENSE file
for details.
Metadata
Release files for Flask-FomanticUI 0.0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| Flask-FomanticUI-0.0.3.tar.gz | 3.7 MB | Without provenance | Details for Flask-FomanticUI-0.0.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| Flask_FomanticUI-0.0.3-py3-none-any.whl | Python 3 | none | any | Details for Flask_FomanticUI-0.0.3-py3-none-any.whl |
Total release size: 7.4 MB
Release files / Flask-FomanticUI-0.0.3.tar.gz
| Download URL | Flask-FomanticUI-0.0.3.tar.gz |
|---|---|
| Size | 3.7 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ce203f3ecf3efc16d39af6315b942d03469fe8494d319e2bbb5685d6564e0c86
|
|
BLAKE2b-256 checksum How to use checksums |
8393d6ec09f91770633a63d5c96623df3ecd3dd6e82b78580f43c7177391654f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.16
|
Release files / Flask_FomanticUI-0.0.3-py3-none-any.whl
| Download URL | Flask_FomanticUI-0.0.3-py3-none-any.whl |
|---|---|
| Size | 3.7 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
bc2caab272671195d08865b123e6727be1b2e4b126d14558e8565c313443b9f5
|
|
BLAKE2b-256 checksum How to use checksums |
a696c176bd00b62adf73d9d7a3269bfae00210994d231767c5672494729b5e93
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.16
|
Security for Flask-FomanticUI 0.0.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.