com3dian commited on
Commit
c843614
·
verified ·
1 Parent(s): 57fad31

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -4
app.py CHANGED
@@ -214,7 +214,7 @@ if (summ_text is not None) or ('summ_text' in st.session_state):
214
  # CSS styling to create a frame
215
  frame_css = """
216
  <style>
217
- .framed-text {
218
  border: 2px solid #4CAF50; /* Border color */
219
  padding: 10px; /* Space inside the border */
220
  border-radius: 5px; /* Rounded corners */
@@ -227,9 +227,12 @@ if (summ_text is not None) or ('summ_text' in st.session_state):
227
  # Inject CSS into the Streamlit app
228
  st.markdown(frame_css, unsafe_allow_html=True)
229
 
230
- # Display text within a div that uses the framed-text class
231
- st.markdown(f'<div class="framed-text">{st.session_state.current_text}</div>', unsafe_allow_html=True)
232
-
 
 
 
233
  def render_markdown_to_html(markdown_str):
234
  return markdown.markdown(markdown_str)
235
 
 
214
  # CSS styling to create a frame
215
  frame_css = """
216
  <style>
217
+ .framed-markdown {
218
  border: 2px solid #4CAF50; /* Border color */
219
  padding: 10px; /* Space inside the border */
220
  border-radius: 5px; /* Rounded corners */
 
227
  # Inject CSS into the Streamlit app
228
  st.markdown(frame_css, unsafe_allow_html=True)
229
 
230
+ # Render the markdown content within the framed box
231
+ st.markdown(
232
+ f'<div class="framed-markdown">{st.session_state.current_text}</div>',
233
+ unsafe_allow_html=True
234
+ )
235
+
236
  def render_markdown_to_html(markdown_str):
237
  return markdown.markdown(markdown_str)
238