NurseCitizenDeveloper commited on
Commit
3d6a80c
·
1 Parent(s): e3080e7

UI: Revert to clean white/light theme

Browse files
Files changed (1) hide show
  1. app.py +23 -27
app.py CHANGED
@@ -20,26 +20,24 @@ st.set_page_config(
20
  layout="wide"
21
  )
22
 
23
- # Enhanced Custom CSS
24
  st.markdown("""
25
  <style>
26
  .stApp {
27
- background: linear-gradient(135deg, #0f0c29 0%, #302b63 50%, #24243e 100%);
28
  }
29
  .main-header {
30
- background: linear-gradient(90deg, #00d2ff 0%, #3a7bd5 100%);
31
- -webkit-background-clip: text;
32
- -webkit-text-fill-color: transparent;
33
  font-size: 2.5rem;
34
  font-weight: bold;
35
  text-align: center;
36
  }
37
  .metric-card {
38
- background: rgba(255,255,255,0.1);
39
- backdrop-filter: blur(10px);
40
  border-radius: 15px;
41
  padding: 1.5rem;
42
- border: 1px solid rgba(255,255,255,0.2);
 
43
  margin: 0.5rem 0;
44
  }
45
  .gene-badge {
@@ -51,18 +49,20 @@ st.markdown("""
51
  display: inline-block;
52
  }
53
  .alert-box {
54
- background: rgba(255,75,75,0.2);
55
- border-left: 4px solid #ff4b4b;
56
  padding: 1rem;
57
  border-radius: 0 10px 10px 0;
58
  margin: 1rem 0;
 
59
  }
60
  .success-box {
61
- background: rgba(0,200,83,0.2);
62
- border-left: 4px solid #00c853;
63
  padding: 1rem;
64
  border-radius: 0 10px 10px 0;
65
  margin: 1rem 0;
 
66
  }
67
  </style>
68
  """, unsafe_allow_html=True)
@@ -70,7 +70,7 @@ st.markdown("""
70
  # Application Header
71
  st.markdown('<h1 class="main-header">🧬 Virtual Gene Scope v2.0</h1>', unsafe_allow_html=True)
72
  st.markdown("""
73
- <p style="text-align: center; color: #a0aec0; font-size: 1.1rem;">
74
  Explore the Regulatory Genome with Google DeepMind's AlphaGenome<br>
75
  <em>Multi-modal predictions: Expression • Splicing • Chromatin • Contact Maps</em>
76
  </p>
@@ -272,15 +272,11 @@ if not api_key:
272
  ax.set_xlabel('Genomic Position (relative)')
273
  ax.set_ylabel('Predicted Signal')
274
  ax.legend()
275
- ax.set_facecolor('#1a1a2e')
276
- fig.patch.set_facecolor('#1a1a2e')
277
- for spine in ax.spines.values():
278
- spine.set_color('white')
279
- ax.tick_params(colors='white')
280
- ax.xaxis.label.set_color('white')
281
- ax.yaxis.label.set_color('white')
282
- ax.title.set_color('white')
283
- ax.legend(facecolor='#2d2d44', labelcolor='white')
284
  st.pyplot(fig)
285
 
286
  if "Splicing" in output_modalities:
@@ -296,11 +292,11 @@ if not api_key:
296
  ax2.bar(x[350:360], splice_ref[350:360], width=0.5, alpha=0.6, color='#4CAF50')
297
  ax2.bar(x[350:360], splice_alt[350:360], width=0.3, alpha=0.8, color='#ff4b4b')
298
  ax2.set_title('Splice Site Usage')
299
- ax2.set_facecolor('#1a1a2e')
300
- fig2.patch.set_facecolor('#1a1a2e')
301
- ax2.tick_params(colors='white')
302
- ax2.title.set_color('white')
303
- ax2.legend(facecolor='#2d2d44', labelcolor='white')
304
  st.pyplot(fig2)
305
 
306
  else:
 
20
  layout="wide"
21
  )
22
 
23
+ # Clean Light Theme CSS
24
  st.markdown("""
25
  <style>
26
  .stApp {
27
+ background-color: #f8f9fa;
28
  }
29
  .main-header {
30
+ color: #2c3e50;
 
 
31
  font-size: 2.5rem;
32
  font-weight: bold;
33
  text-align: center;
34
  }
35
  .metric-card {
36
+ background: white;
 
37
  border-radius: 15px;
38
  padding: 1.5rem;
39
+ border: 1px solid #e0e0e0;
40
+ box-shadow: 0 2px 8px rgba(0,0,0,0.08);
41
  margin: 0.5rem 0;
42
  }
43
  .gene-badge {
 
49
  display: inline-block;
50
  }
51
  .alert-box {
52
+ background: #fff5f5;
53
+ border-left: 4px solid #e53e3e;
54
  padding: 1rem;
55
  border-radius: 0 10px 10px 0;
56
  margin: 1rem 0;
57
+ color: #c53030;
58
  }
59
  .success-box {
60
+ background: #f0fff4;
61
+ border-left: 4px solid #38a169;
62
  padding: 1rem;
63
  border-radius: 0 10px 10px 0;
64
  margin: 1rem 0;
65
+ color: #276749;
66
  }
67
  </style>
68
  """, unsafe_allow_html=True)
 
70
  # Application Header
71
  st.markdown('<h1 class="main-header">🧬 Virtual Gene Scope v2.0</h1>', unsafe_allow_html=True)
72
  st.markdown("""
73
+ <p style="text-align: center; color: #4a5568; font-size: 1.1rem;">
74
  Explore the Regulatory Genome with Google DeepMind's AlphaGenome<br>
75
  <em>Multi-modal predictions: Expression • Splicing • Chromatin • Contact Maps</em>
76
  </p>
 
272
  ax.set_xlabel('Genomic Position (relative)')
273
  ax.set_ylabel('Predicted Signal')
274
  ax.legend()
275
+ ax.set_facecolor('white')
276
+ fig.patch.set_facecolor('white')
277
+ ax.spines['top'].set_visible(False)
278
+ ax.spines['right'].set_visible(False)
279
+ ax.grid(True, alpha=0.3)
 
 
 
 
280
  st.pyplot(fig)
281
 
282
  if "Splicing" in output_modalities:
 
292
  ax2.bar(x[350:360], splice_ref[350:360], width=0.5, alpha=0.6, color='#4CAF50')
293
  ax2.bar(x[350:360], splice_alt[350:360], width=0.3, alpha=0.8, color='#ff4b4b')
294
  ax2.set_title('Splice Site Usage')
295
+ ax2.set_facecolor('white')
296
+ fig2.patch.set_facecolor('white')
297
+ ax2.spines['top'].set_visible(False)
298
+ ax2.spines['right'].set_visible(False)
299
+ ax2.grid(True, alpha=0.3)
300
  st.pyplot(fig2)
301
 
302
  else: