Commit ·
fc2c058
1
Parent(s): a458bc0
Remove Tailwind CSS and force inline text color for visibility fix
Browse files- gradio_app.py +7 -1
gradio_app.py
CHANGED
|
@@ -89,7 +89,7 @@ def copy_to_clipboard(text):
|
|
| 89 |
# --- Custom HTML/JS/CSS for animated background and chips ---
|
| 90 |
custom_html = '''
|
| 91 |
<!-- Tailwind CSS CDN -->
|
| 92 |
-
<link href="https://cdn.jsdelivr.net/npm/tailwindcss@3.4.1/dist/tailwind.min.css" rel="stylesheet">
|
| 93 |
<style>
|
| 94 |
body {
|
| 95 |
background: linear-gradient(135deg, #f0fdfa 0%, #e0e7ff 100%) !important;
|
|
@@ -203,6 +203,12 @@ document.addEventListener("DOMContentLoaded", function() {
|
|
| 203 |
document.body.addEventListener("mouseleave", () => {
|
| 204 |
overlay.style.setProperty("--glow-opacity", "0");
|
| 205 |
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 206 |
});
|
| 207 |
</script>
|
| 208 |
'''
|
|
|
|
| 89 |
# --- Custom HTML/JS/CSS for animated background and chips ---
|
| 90 |
custom_html = '''
|
| 91 |
<!-- Tailwind CSS CDN -->
|
| 92 |
+
<!-- <link href="https://cdn.jsdelivr.net/npm/tailwindcss@3.4.1/dist/tailwind.min.css" rel="stylesheet"> -->
|
| 93 |
<style>
|
| 94 |
body {
|
| 95 |
background: linear-gradient(135deg, #f0fdfa 0%, #e0e7ff 100%) !important;
|
|
|
|
| 203 |
document.body.addEventListener("mouseleave", () => {
|
| 204 |
overlay.style.setProperty("--glow-opacity", "0");
|
| 205 |
});
|
| 206 |
+
// Force inline color for all relevant elements after rendering
|
| 207 |
+
setTimeout(() => {
|
| 208 |
+
document.querySelectorAll('h1, h2, h3, h4, h5, h6, p, li, strong, em, .gr-markdown, .prose, .gr-block, .gradio-container').forEach(el => {
|
| 209 |
+
el.style.color = "#222";
|
| 210 |
+
});
|
| 211 |
+
}, 1000);
|
| 212 |
});
|
| 213 |
</script>
|
| 214 |
'''
|