Spaces:
Running
Running
seawolf2357
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
import streamlit as st
|
2 |
|
3 |
-
# νμ΄μ§
|
4 |
st.set_page_config(layout="wide")
|
5 |
|
6 |
# μ¬μ΄λλ° νμ΄ν μ€μ
|
@@ -15,10 +15,24 @@ menus = {
|
|
15 |
"Scripts": ["Script"]
|
16 |
}
|
17 |
|
18 |
-
# λ©λ΄ λ°
|
19 |
-
selected_menu =
|
20 |
-
|
21 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
22 |
|
23 |
# 'Template Video'κ° μ νλμμ λ λΉλμ€ κ°€λ¬λ¦¬λ₯Ό νμ
|
24 |
if selected_menu == "Free Stock" and selected_sub_menu == "Template Video":
|
|
|
1 |
import streamlit as st
|
2 |
|
3 |
+
# νμ΄μ§ μ€μ
|
4 |
st.set_page_config(layout="wide")
|
5 |
|
6 |
# μ¬μ΄λλ° νμ΄ν μ€μ
|
|
|
15 |
"Scripts": ["Script"]
|
16 |
}
|
17 |
|
18 |
+
# μ νλ λ©λ΄ λ° νλΆ λ©λ΄ μ΄κΈ°ν
|
19 |
+
selected_menu = None
|
20 |
+
selected_sub_menu = None
|
21 |
+
|
22 |
+
# κ° λ©λ΄λ³ νλΆ λ©λ΄λ₯Ό νΌμΉ¨
|
23 |
+
for menu_name, sub_menus in menus.items():
|
24 |
+
with st.sidebar.expander(menu_name):
|
25 |
+
# νλΆ λ©λ΄λ₯Ό μ νν μ μλ selectbox μμ±
|
26 |
+
selected = st.selectbox(f"Select {menu_name} option", [""] + sub_menus, key=menu_name)
|
27 |
+
if selected:
|
28 |
+
selected_menu = menu_name
|
29 |
+
selected_sub_menu = selected
|
30 |
+
|
31 |
+
# μ νλ λ©λ΄μ νλΆ λ©λ΄μ λ°λ₯Έ λ΄μ© νμ
|
32 |
+
if selected_menu and selected_sub_menu:
|
33 |
+
st.subheader(f"{selected_menu} > {selected_sub_menu}")
|
34 |
+
# μ¬κΈ°μ μ νλ λ©λ΄μ λ°λ₯Έ μ½ν
μΈ νμ λ‘μ§ μΆκ°
|
35 |
+
|
36 |
|
37 |
# 'Template Video'κ° μ νλμμ λ λΉλμ€ κ°€λ¬λ¦¬λ₯Ό νμ
|
38 |
if selected_menu == "Free Stock" and selected_sub_menu == "Template Video":
|