ZoyaRabail commited on
Commit
d2f7599
Β·
verified Β·
1 Parent(s): fcae4a8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +17 -3
app.py CHANGED
@@ -62,9 +62,8 @@ if "tz" not in st.session_state:
62
  st.session_state.tz = pytz.timezone("Asia/Karachi") # default Lahore
63
 
64
  # ---------------------------
65
- # Page setup
66
  # ---------------------------
67
- st.set_page_config(page_title="AI Disaster Assistant", layout="wide")
68
  st.markdown("""
69
  <style>
70
  body { background-color: #0d1117; color: white; }
@@ -73,15 +72,30 @@ st.markdown("""
73
  .chat-bubble { background-color: #f0f0f0; color: #000; padding: 0.5rem; margin-bottom: 0.5rem; border-radius: 10px; }
74
  .answer-box { background-color: #d6f5f5; padding: 1rem; border-radius: 12px; color: #000; }
75
  .contact-box { background-color: #ffeecc; padding: 1rem; border-radius: 10px; color: #000; }
 
 
76
  </style>
77
  """, unsafe_allow_html=True)
78
 
 
 
 
 
 
 
 
 
 
 
 
 
79
  st.markdown("""
80
  <h1 style='text-align: center; background-color: #008080; color: white; padding: 1rem; border-radius: 12px;'>
81
- 🌍 AI Disaster Response Assistant
82
  </h1>
83
  """, unsafe_allow_html=True)
84
 
 
85
  # ---------------------------
86
  # Language Selection
87
  # ---------------------------
 
62
  st.session_state.tz = pytz.timezone("Asia/Karachi") # default Lahore
63
 
64
  # ---------------------------
65
+ # CSS Styling
66
  # ---------------------------
 
67
  st.markdown("""
68
  <style>
69
  body { background-color: #0d1117; color: white; }
 
72
  .chat-bubble { background-color: #f0f0f0; color: #000; padding: 0.5rem; margin-bottom: 0.5rem; border-radius: 10px; }
73
  .answer-box { background-color: #d6f5f5; padding: 1rem; border-radius: 12px; color: #000; }
74
  .contact-box { background-color: #ffeecc; padding: 1rem; border-radius: 10px; color: #000; }
75
+ [data-testid="stSidebar"] { background-color: #161b22; }
76
+ .sidebar .sidebar-content { background-color: #161b22; }
77
  </style>
78
  """, unsafe_allow_html=True)
79
 
80
+ # ---------------------------
81
+ # Sidebar Navigation
82
+ # ---------------------------
83
+ st.sidebar.markdown("# 🌍 AI Disaster Response Assistant")
84
+ page = st.sidebar.radio("Navigation", ["Chat Assistant", "Image Analysis"])
85
+
86
+ if page == "Image Analysis":
87
+ st.switch_page("pages/image_analysis.py")
88
+
89
+ # ---------------------------
90
+ # Main Page (Chat Assistant)
91
+ # ---------------------------
92
  st.markdown("""
93
  <h1 style='text-align: center; background-color: #008080; color: white; padding: 1rem; border-radius: 12px;'>
94
+ πŸ’¬ AI Disaster Chat Assistant
95
  </h1>
96
  """, unsafe_allow_html=True)
97
 
98
+
99
  # ---------------------------
100
  # Language Selection
101
  # ---------------------------