Abhaykoul commited on
Commit
97a6b18
1 Parent(s): a65a694

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -5
app.py CHANGED
@@ -64,16 +64,17 @@ def main():
64
  # Sanitize the report text
65
  sanitized_report = sanitize_text(report + "\n\n" + outro)
66
 
67
- # Display the sanitized report
68
- report_element = st.text(sanitized_report)
69
-
 
 
 
70
  # Add a copy button to copy the output
71
  if st.button('Copy Report'):
72
  try:
73
  st.success("Report copied to clipboard!")
74
  st.write(sanitized_report)
75
- st.write(type(sanitized_report))
76
- st.write(len(sanitized_report))
77
  st.experimental_set_state({"report_copied": True})
78
  except Exception as e:
79
  st.error(f"Error copying report: {e}")
 
64
  # Sanitize the report text
65
  sanitized_report = sanitize_text(report + "\n\n" + outro)
66
 
67
+ # Create a text area for the output
68
+ output_box = st.empty()
69
+
70
+ # Display the sanitized report in the output box
71
+ output_box.text_area("Generated Report", value=sanitized_report, height=400)
72
+
73
  # Add a copy button to copy the output
74
  if st.button('Copy Report'):
75
  try:
76
  st.success("Report copied to clipboard!")
77
  st.write(sanitized_report)
 
 
78
  st.experimental_set_state({"report_copied": True})
79
  except Exception as e:
80
  st.error(f"Error copying report: {e}")