vsj0702 commited on
Commit
0447084
·
verified ·
1 Parent(s): 0a67d05

improving ui

Browse files
Files changed (1) hide show
  1. layout.py +24 -2
layout.py CHANGED
@@ -33,7 +33,7 @@ def apply_theme():
33
  }
34
  ace_lang = ace_lang_map.get(lang, "python")
35
 
36
- # Inject polished theme CSS
37
  st.markdown(
38
  f"""
39
  <style>
@@ -105,10 +105,32 @@ def apply_theme():
105
  border-radius: 4px;
106
  overflow-x: auto;
107
  }}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
108
  </style>
109
  """,
110
  unsafe_allow_html=True,
111
  )
112
 
113
  return colors, ace_theme
114
-
 
33
  }
34
  ace_lang = ace_lang_map.get(lang, "python")
35
 
36
+ # Inject custom theme CSS
37
  st.markdown(
38
  f"""
39
  <style>
 
105
  border-radius: 4px;
106
  overflow-x: auto;
107
  }}
108
+
109
+ /* Style selectbox and file uploader */
110
+ .stSelectbox label, .stFileUploader label {{
111
+ color: {colors["text"]} !important;
112
+ }}
113
+ .stSelectbox div[data-baseweb="select"] {{
114
+ background-color: {colors["panel_bg"]} !important;
115
+ color: {colors["text"]} !important;
116
+ border: 1px solid {colors["border"]} !important;
117
+ border-radius: 6px;
118
+ padding: 0.25rem;
119
+ }}
120
+ .stFileUploader .stFileUploaderDropzone {{
121
+ background-color: {colors["panel_bg"]} !important;
122
+ color: {colors["text"]} !important;
123
+ border: 1px dashed {colors["border"]};
124
+ border-radius: 8px;
125
+ }}
126
+ .stFileUploader .row-widget.stButton > button {{
127
+ background-color: {colors["accent"]} !important;
128
+ color: white !important;
129
+ border-radius: 6px;
130
+ }}
131
  </style>
132
  """,
133
  unsafe_allow_html=True,
134
  )
135
 
136
  return colors, ace_theme