Update app.py
Browse files
app.py
CHANGED
@@ -1,14 +1,52 @@
|
|
1 |
import streamlit as st
|
2 |
-
from streamlit_option_menu import option_menu
|
3 |
#for k, v in st.session_state.items():
|
4 |
# st.session_state[k] = v
|
5 |
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
|
11 |
-
|
12 |
-
|
13 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
14 |
st.sidebar.text("Project by JA-RAD")
|
|
|
1 |
import streamlit as st
|
|
|
2 |
#for k, v in st.session_state.items():
|
3 |
# st.session_state[k] = v
|
4 |
|
5 |
+
# --- SHARED ON ALL PAGES ---
|
6 |
+
#st.logo(image=":material/medical_information:")
|
7 |
+
#st.logo(image="images/medical_information_24dp_1F1F1F_FILL0_wght400_GRAD0_opsz24.png")
|
8 |
+
st.logo(image="images/menu_book_60dp_75FBFD.png")
|
9 |
+
st.sidebar.title("SBS Codes V2.0 Mapper")
|
10 |
+
|
11 |
+
# --- PAGE SETUP ---
|
12 |
+
start_page = st.Page(
|
13 |
+
page="pages/chapter_index.py",
|
14 |
+
title="Chapters for selection",
|
15 |
+
icon=":material/home:",
|
16 |
+
default=True,)
|
17 |
+
|
18 |
+
type_text_page = st.Page(
|
19 |
+
page="pages/type_text.py",
|
20 |
+
title="DEMO for text entry",
|
21 |
+
icon=":material/keyboard:",
|
22 |
+
default=False,)
|
23 |
+
|
24 |
+
upload_file_page = st.Page(
|
25 |
+
page="pages/upload_file.py",
|
26 |
+
title="DEMO for file upload (work in progress)",
|
27 |
+
icon=":material/file_upload:",
|
28 |
+
default=False,)
|
29 |
+
|
30 |
+
about_page = st.Page(
|
31 |
+
page="pages/about.py",
|
32 |
+
title="About the app",
|
33 |
+
icon=":material/info:",
|
34 |
+
default=False)
|
35 |
+
|
36 |
+
#PAGES = {
|
37 |
+
# "Chapter Index": "pages/chapter_index.py" ,
|
38 |
+
# "DEMO type_text": "pages/type_text.py",
|
39 |
+
# "DEMO upload file (not yet active)": "pages/upload_file.py",
|
40 |
+
# "About": "pages/about.py",
|
41 |
+
#}
|
42 |
+
|
43 |
+
#selection = st.sidebar.radio("Pages", list(PAGES.keys()))
|
44 |
+
#selection = st.sidebar.radio("Pages", [start_page, type_text_page, upload_file_page, about_page])
|
45 |
+
#page = PAGES[selection]
|
46 |
+
|
47 |
+
# --- NAVIGATION SETUP ---
|
48 |
+
pg = st.navigation(pages=[start_page, type_text_page, upload_file_page, about_page]) # WITHOUT SECTIONS
|
49 |
+
#pg = st.navigation({"Chapter_Index": [start_page], "Demo": [type_text_page, upload_file_page], "About": [about_page]}) # WITH SECTIONS
|
50 |
+
pg.run()
|
51 |
+
|
52 |
st.sidebar.text("Project by JA-RAD")
|