Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -191,6 +191,7 @@ latex_formatter = LatexFormatter()
|
|
191 |
def display_math_content(content: str):
|
192 |
"""μν λ΄μ©μ νλ©΄μ νμ"""
|
193 |
formatted_content = latex_formatter.format_expression(content)
|
|
|
194 |
st.markdown(formatted_content, unsafe_allow_html=True)
|
195 |
|
196 |
def format_answer_choice(choice: str) -> str:
|
@@ -228,19 +229,20 @@ def main():
|
|
228 |
# 보기 νμ
|
229 |
col1, col2 = st.columns(2)
|
230 |
with col1:
|
231 |
-
if st.button(
|
232 |
handle_answer('A', current_q)
|
233 |
st.rerun()
|
234 |
-
if st.button(
|
235 |
handle_answer('C', current_q)
|
236 |
st.rerun()
|
237 |
with col2:
|
238 |
-
if st.button(
|
239 |
handle_answer('B', current_q)
|
240 |
st.rerun()
|
241 |
-
if st.button(
|
242 |
handle_answer('D', current_q)
|
243 |
st.rerun()
|
|
|
244 |
# λ³΅μ΅ νλ©΄
|
245 |
elif st.session_state.current_step == 'review':
|
246 |
st.write("### νμ΅ κ²°κ³Ό")
|
|
|
191 |
def display_math_content(content: str):
|
192 |
"""μν λ΄μ©μ νλ©΄μ νμ"""
|
193 |
formatted_content = latex_formatter.format_expression(content)
|
194 |
+
st.latex(formatted_content)
|
195 |
st.markdown(formatted_content, unsafe_allow_html=True)
|
196 |
|
197 |
def format_answer_choice(choice: str) -> str:
|
|
|
229 |
# 보기 νμ
|
230 |
col1, col2 = st.columns(2)
|
231 |
with col1:
|
232 |
+
if st.button(f"A) {latex_formatter.format_expression(current_q['AnswerAText'])}", key="A"):
|
233 |
handle_answer('A', current_q)
|
234 |
st.rerun()
|
235 |
+
if st.button(f"C) {latex_formatter.format_expression(current_q['AnswerCText'])}", key="C"):
|
236 |
handle_answer('C', current_q)
|
237 |
st.rerun()
|
238 |
with col2:
|
239 |
+
if st.button(f"B) {latex_formatter.format_expression(current_q['AnswerBText'])}", key="B"):
|
240 |
handle_answer('B', current_q)
|
241 |
st.rerun()
|
242 |
+
if st.button(f"D) {latex_formatter.format_expression(current_q['AnswerDText'])}", key="D"):
|
243 |
handle_answer('D', current_q)
|
244 |
st.rerun()
|
245 |
+
|
246 |
# λ³΅μ΅ νλ©΄
|
247 |
elif st.session_state.current_step == 'review':
|
248 |
st.write("### νμ΅ κ²°κ³Ό")
|