Update app.py
Browse files
app.py
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
|
|
| 1 |
from PIL import Image, ImageColor
|
| 2 |
-
import os
|
|
|
|
|
|
|
|
|
|
| 3 |
|
| 4 |
def recolor_icons(zip_file, hex_color):
|
| 5 |
target_rgb = ImageColor.getrgb(hex_color) # Fixed: handles "red", "#ff0000", etc.
|
|
|
|
| 1 |
+
import gradio as gr
|
| 2 |
from PIL import Image, ImageColor
|
| 3 |
+
import os
|
| 4 |
+
import zipfile
|
| 5 |
+
import tempfile
|
| 6 |
+
import shutil
|
| 7 |
|
| 8 |
def recolor_icons(zip_file, hex_color):
|
| 9 |
target_rgb = ImageColor.getrgb(hex_color) # Fixed: handles "red", "#ff0000", etc.
|