clementBE commited on
Commit
96b2741
·
verified ·
1 Parent(s): 1a66dd1

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +18 -19
app.py CHANGED
@@ -173,25 +173,25 @@ with gr.Blocks(title="Qualitative Coding Interface") as demo:
173
  # Stores the running list of codes (DataFrame)
174
  coded_data_state = gr.State(value=get_initial_df())
175
 
176
- # --- A. FILE UPLOAD & METADATA ---
177
- with gr.Row():
178
- file_input = gr.File(
179
- label="Upload Transcript (.docx, .vtt, .txt)",
180
- file_types=[".docx", ".vtt", ".txt"],
181
- scale=1
182
- )
183
- status_message = gr.Textbox(label="Status", value="Ready", scale=2)
184
-
185
- # File upload change event
186
- file_input.change(
187
- fn=process_file,
188
- inputs=file_input,
189
- outputs=[full_transcript_text, status_message, current_file_id, coded_data_state]
190
- )
191
-
192
- # --- MAIN CONTENT COLUMN (FIX) ---
193
- # Placing the rest of the UI inside a Column ensures proper vertical layout rendering
194
  with gr.Column():
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
195
  gr.Markdown("---")
196
  gr.Markdown("## 📝 Interview Metadata")
197
 
@@ -239,7 +239,6 @@ with gr.Blocks(title="Qualitative Coding Interface") as demo:
239
  gr.Markdown("---")
240
  gr.Markdown("## 📊 Coded Data")
241
 
242
- # FIX: Removed the 'height=300' argument
243
  coded_output_df = gr.Dataframe(
244
  label="Current Coded Segments",
245
  interactive=False,
 
173
  # Stores the running list of codes (DataFrame)
174
  coded_data_state = gr.State(value=get_initial_df())
175
 
176
+ # *** FIX IMPLEMENTATION: Put all visible UI inside a single Column ***
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
177
  with gr.Column():
178
+
179
+ # --- A. FILE UPLOAD & METADATA ---
180
+ with gr.Row():
181
+ file_input = gr.File(
182
+ label="Upload Transcript (.docx, .vtt, .txt)",
183
+ file_types=[".docx", ".vtt", ".txt"],
184
+ scale=1
185
+ )
186
+ status_message = gr.Textbox(label="Status", value="Ready", scale=2)
187
+
188
+ # File upload change event
189
+ file_input.change(
190
+ fn=process_file,
191
+ inputs=file_input,
192
+ outputs=[full_transcript_text, status_message, current_file_id, coded_data_state]
193
+ )
194
+
195
  gr.Markdown("---")
196
  gr.Markdown("## 📝 Interview Metadata")
197
 
 
239
  gr.Markdown("---")
240
  gr.Markdown("## 📊 Coded Data")
241
 
 
242
  coded_output_df = gr.Dataframe(
243
  label="Current Coded Segments",
244
  interactive=False,