Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -15,7 +15,7 @@ from streamlit_drawable_canvas import st_canvas
|
|
| 15 |
# Monkey-Patch to Add image_to_url
|
| 16 |
# ------------------------------
|
| 17 |
|
| 18 |
-
def image_to_url(image):
|
| 19 |
"""
|
| 20 |
Converts a PIL Image to a data URL.
|
| 21 |
"""
|
|
@@ -501,7 +501,7 @@ if uploaded_file:
|
|
| 501 |
|
| 502 |
st.header("🖌️ Interactive Text Addition")
|
| 503 |
|
| 504 |
-
#
|
| 505 |
canvas_result = st_canvas(
|
| 506 |
fill_color="rgba(255, 255, 255, 0)", # Transparent fill
|
| 507 |
stroke_width=0,
|
|
|
|
| 15 |
# Monkey-Patch to Add image_to_url
|
| 16 |
# ------------------------------
|
| 17 |
|
| 18 |
+
def image_to_url(image, *args, **kwargs):
|
| 19 |
"""
|
| 20 |
Converts a PIL Image to a data URL.
|
| 21 |
"""
|
|
|
|
| 501 |
|
| 502 |
st.header("🖌️ Interactive Text Addition")
|
| 503 |
|
| 504 |
+
# Display the canvas with drawable features
|
| 505 |
canvas_result = st_canvas(
|
| 506 |
fill_color="rgba(255, 255, 255, 0)", # Transparent fill
|
| 507 |
stroke_width=0,
|