Spaces:
Sleeping
Sleeping
Update styles.py
Browse files
styles.py
CHANGED
@@ -1,81 +1,67 @@
|
|
1 |
-
import streamlit as st
|
2 |
-
|
3 |
-
def apply_styles():
|
4 |
-
return """
|
5 |
-
<style>
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
font-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
font-size: 1.1rem;
|
68 |
-
}
|
69 |
-
|
70 |
-
.element-container {
|
71 |
-
margin-bottom: 1.5rem;
|
72 |
-
}
|
73 |
-
</style>
|
74 |
-
""", unsafe_allow_html=True)
|
75 |
-
|
76 |
-
def format_story_output(story_text):
|
77 |
-
return f"""
|
78 |
-
<div class="story-output">
|
79 |
-
{story_text}
|
80 |
-
</div>
|
81 |
"""
|
|
|
1 |
+
import streamlit as st
|
2 |
+
|
3 |
+
def apply_styles():
|
4 |
+
return """
|
5 |
+
<style>
|
6 |
+
/* Headers */
|
7 |
+
h1 {
|
8 |
+
color: #2c3e50;
|
9 |
+
font-size: 2.5rem;
|
10 |
+
margin-bottom: 1rem;
|
11 |
+
text-align: center;
|
12 |
+
}
|
13 |
+
|
14 |
+
h3 {
|
15 |
+
color: #34495e;
|
16 |
+
font-size: 1.3rem;
|
17 |
+
font-weight: normal;
|
18 |
+
margin-bottom: 2rem;
|
19 |
+
text-align: center;
|
20 |
+
}
|
21 |
+
|
22 |
+
/* Input Labels */
|
23 |
+
.stTextArea > label,
|
24 |
+
.stSelectbox > label,
|
25 |
+
.stSlider > label {
|
26 |
+
font-size: 1.2rem;
|
27 |
+
font-weight: bold;
|
28 |
+
color: #2c3e50;
|
29 |
+
}
|
30 |
+
|
31 |
+
/* Button */
|
32 |
+
.stButton > button {
|
33 |
+
background-color: #4CAF50 !important; /* Green background */
|
34 |
+
color: black !important;
|
35 |
+
padding: 0.5rem 2rem;
|
36 |
+
font-size: 1.1rem;
|
37 |
+
font-weight: bold !important;
|
38 |
+
border: 1px solid black !important;
|
39 |
+
border-radius: 5px;
|
40 |
+
width: 80%;
|
41 |
+
margin-left: 10%;
|
42 |
+
}
|
43 |
+
|
44 |
+
.stButton > button:hover {
|
45 |
+
background-color: #45a049 !important; /* Slightly darker green on hover */
|
46 |
+
}
|
47 |
+
.stButton > button:hover {
|
48 |
+
background-color: #34495e;
|
49 |
+
}
|
50 |
+
|
51 |
+
/* Content */
|
52 |
+
.stMarkdown {
|
53 |
+
font-size: 1.1rem;
|
54 |
+
}
|
55 |
+
|
56 |
+
.element-container {
|
57 |
+
margin-bottom: 1.5rem;
|
58 |
+
}
|
59 |
+
</style>
|
60 |
+
"""
|
61 |
+
|
62 |
+
def format_story_output(story_text):
|
63 |
+
return f"""
|
64 |
+
<div class="story-output">
|
65 |
+
{story_text}
|
66 |
+
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
67 |
"""
|