17 lines
402 B
Python
17 lines
402 B
Python
import streamlit as st
|
|
|
|
def render_editor():
|
|
st.subheader("Code Editor")
|
|
|
|
if st.session_state.selected_file:
|
|
st.text_area(
|
|
"Edit your code here:",
|
|
value=st.session_state.file_content,
|
|
height=400,
|
|
key="code_editor"
|
|
)
|
|
else:
|
|
st.info("Please select a file to edit.")
|
|
|
|
if __name__ == "__main__":
|
|
render_editor() |