A streamlit module integrating cropperjs
Project description
Streamlit-cropperjs
Integrating the amazing cropperjs with streamlit.
This streamlit module is primarily built with mobile usage in mind.
Installation
pip install streamlit-cropperjs
Example
import streamlit as st
from streamlit_cropperjs import st_cropperjs
pic = st.file_uploader("Upload a picture", key="uploaded_pic")
if pic:
pic = pic.read()
cropped_pic = st_cropperjs(pic=pic, btn_text="Detect!", key="foo")
if cropped_pic:
st.image(cropped_pic, output_format="PNG")
Features
- Crop and return image data
- Supports touch (mobile)
- Supports cropping on demand with a button (customised button text)
Future Development
- Support for all cropperjs options
- Support for cropperjs v2
References
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
streamlit-cropperjs-0.0.7.tar.gz
(369.8 kB
view details)
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 streamlit-cropperjs-0.0.7.tar.gz.
File metadata
- Download URL: streamlit-cropperjs-0.0.7.tar.gz
- Upload date:
- Size: 369.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c666eee10b6c30c1b043d645a115de16fed9f55f13d38d0e0eb51633df838b71
|
|
| MD5 |
df56c113ff3534a30c649e33569b401a
|
|
| BLAKE2b-256 |
17c3aafee51da018ac2080997ad99cb7ae53fa2f189ce8e3990378d7d0f5e825
|
File details
Details for the file streamlit_cropperjs-0.0.7-py3-none-any.whl.
File metadata
- Download URL: streamlit_cropperjs-0.0.7-py3-none-any.whl
- Upload date:
- Size: 373.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c838c7856057831925b22c224cc9fb6614f942c560ff934c40cbe79b43cb3317
|
|
| MD5 |
4df05d8c2aeed4cc91e4b01c86a82e60
|
|
| BLAKE2b-256 |
3055e657081ce1edd1879a18a16e591a85532d9af439674cf332fc3ed39c31d1
|