DataMine commited on
Commit
fc7c86a
·
verified ·
1 Parent(s): 188f2bc

Update src/streamlit_app.py

Browse files
Files changed (1) hide show
  1. src/streamlit_app.py +2 -78
src/streamlit_app.py CHANGED
@@ -23,83 +23,7 @@ st.set_page_config(
23
  def load_custom_css():
24
  st.markdown("""
25
  <style>
26
- /* Force Light Theme */
27
- .stApp {
28
- background-color: #ffffff !important;
29
- color: #000000 !important;
30
- }
31
-
32
- /* Override Streamlit's dark theme detection */
33
- @media (prefers-color-scheme: dark) {
34
- .stApp {
35
- background-color: #ffffff !important;
36
- color: #000000 !important;
37
- }
38
- }
39
-
40
- /* Ensure all containers use light theme */
41
- .main .block-container {
42
- background-color: #ffffff !important;
43
- color: #000000 !important;
44
- }
45
-
46
- /* Sidebar light theme */
47
- .css-1d391kg, .css-1lcbmhc {
48
- background-color: #f8f9fa !important;
49
- color: #000000 !important;
50
- }
51
-
52
- /* Text elements */
53
- .stMarkdown, .stText, p, span, div {
54
- color: #000000 !important;
55
- }
56
-
57
- /* Input elements */
58
- .stTextInput input, .stSelectbox select, .stSlider {
59
- background-color: #ffffff !important;
60
- color: #000000 !important;
61
- border: 1px solid #cccccc !important;
62
- }
63
- /* Comprehensive Streamlit branding removal */
64
- #MainMenu {visibility: hidden !important;}
65
- footer {visibility: hidden !important;}
66
- header {visibility: hidden !important;}
67
- .stDeployButton {display: none !important;}
68
- .stDecoration {display: none !important;}
69
- .stActionButton {display: none !important;}
70
- [data-testid="stToolbar"] {display: none !important;}
71
- [data-testid="stDecoration"] {display: none !important;}
72
- [data-testid="stStatusWidget"] {display: none !important;}
73
- [data-testid="manage-app-button"] {display: none !important;}
74
- [data-testid="deployButton"] {display: none !important;}
75
-
76
-
77
-
78
- /* Hide footer */
79
- .css-h5rgaw.egzxvld1 {display: none !important;}
80
- .css-cio0dv.egzxvld1 {display: none !important;}
81
- footer.css-164nlkn.egzxvld1 {display: none !important;}
82
-
83
- /* Hide "Made with Streamlit" */
84
- .viewerBadge_container__1QSob {display: none !important;}
85
- .styles_viewerBadge__1yB5_ {display: none !important;}
86
- .viewerBadge_link__1S137 {display: none !important;}
87
- .viewerBadge_text__1JaDK {display: none !important;}
88
-
89
- /* Hide deploy button and related elements */
90
- .css-1rs6os {display: none !important;}
91
- .css-17eq0hr {display: none !important;}
92
- .css-1vbkxwb {display: none !important;}
93
- .css-1dp5vir {display: none !important;}
94
-
95
- /* Hide GitHub icon and deploy related buttons */
96
- [title="View source on GitHub"] {display: none !important;}
97
- [title="Deploy this app"] {display: none !important;}
98
- .css-1avcm0n {display: none !important;}
99
-
100
- /* Hide top padding */
101
- #root > div:nth-child(1) > div > div > div > div > section > div {padding-top: 0rem !important;}
102
-
103
  /* Import Google Fonts */
104
  @import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&family=Nunito:wght@300;400;500;600;700&display=swap');
105
 
@@ -439,7 +363,7 @@ class MathOlympiadExam:
439
  """Initialize Groq client with API key"""
440
  try:
441
  # Use Streamlit secrets for secure API key management
442
- api_key = st.secrets["GROQ_API_KEY"]
443
  if not api_key:
444
  st.error("⚠️ GROQ_API_KEY not found in secrets!")
445
  return None
 
23
  def load_custom_css():
24
  st.markdown("""
25
  <style>
26
+
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
27
  /* Import Google Fonts */
28
  @import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&family=Nunito:wght@300;400;500;600;700&display=swap');
29
 
 
363
  """Initialize Groq client with API key"""
364
  try:
365
  # Use Streamlit secrets for secure API key management
366
+ api_key = "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"
367
  if not api_key:
368
  st.error("⚠️ GROQ_API_KEY not found in secrets!")
369
  return None