jdesiree commited on
Commit
94c43c8
·
verified ·
1 Parent(s): 2cb27b0

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +41 -5
app.py CHANGED
@@ -394,6 +394,41 @@ custom_css = """
394
  border-color: #4a3f3c !important;
395
  }
396
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
397
  /* Responsive design */
398
  @media (max-width: 768px) {
399
  .gradio-container-5-42-0 .gradio-chatbot .message.bot .markdown,
@@ -498,11 +533,12 @@ def create_interface():
498
  gr.HTML('<style>.main-container { height: 100vh !important; display: flex !important; flex-direction: column !important; }</style>')
499
 
500
  with gr.Column(elem_classes=["main-container"]):
501
- # Title Section - in its own row
502
- with gr.Row():
503
  gr.HTML('<div class="title-header"><h1>🎓 EduBot</h1></div>')
504
 
505
- # Chat Section - this should expand to fill ALL available space
 
506
  chatbot = gr.Chatbot(
507
  type="messages",
508
  show_copy_button=True,
@@ -519,8 +555,8 @@ def create_interface():
519
  msg = gr.Textbox(
520
  placeholder="Ask me about math, research, study strategies, or any educational topic...",
521
  show_label=False,
522
- lines=1,
523
- max_lines=1,
524
  elem_classes=["input-textbox"],
525
  container=False,
526
  scale=4
 
394
  border-color: #4a3f3c !important;
395
  }
396
 
397
+ /* Ensure Gradio footer is visible and properly positioned */
398
+ footer.svelte-czcr5b {
399
+ display: flex !important;
400
+ visibility: visible !important;
401
+ position: fixed !important;
402
+ bottom: 0 !important;
403
+ left: 0 !important;
404
+ right: 0 !important;
405
+ background-color: rgba(240, 236, 230, 0.95) !important;
406
+ backdrop-filter: blur(5px) !important;
407
+ border-top: 1pt solid #59524f !important;
408
+ padding: 8px 16px !important;
409
+ z-index: 1000 !important;
410
+ height: auto !important;
411
+ min-height: 40px !important;
412
+ }
413
+
414
+ /* Style the footer buttons to match your theme */
415
+ footer.svelte-czcr5b button {
416
+ background-color: transparent !important;
417
+ color: #120f0e !important;
418
+ border: none !important;
419
+ font-family: "Oswald", sans-serif !important;
420
+ font-size: 12px !important;
421
+ }
422
+
423
+ footer.svelte-czcr5b .divider {
424
+ color: #59524f !important;
425
+ }
426
+
427
+ /* Adjust main container to account for footer */
428
+ .main-container {
429
+ padding-bottom: 50px !important;
430
+ }
431
+
432
  /* Responsive design */
433
  @media (max-width: 768px) {
434
  .gradio-container-5-42-0 .gradio-chatbot .message.bot .markdown,
 
533
  gr.HTML('<style>.main-container { height: 100vh !important; display: flex !important; flex-direction: column !important; }</style>')
534
 
535
  with gr.Column(elem_classes=["main-container"]):
536
+ # Title Section
537
+ with gr.Row(height="10vh"):
538
  gr.HTML('<div class="title-header"><h1>🎓 EduBot</h1></div>')
539
 
540
+ # Chat Section
541
+ with gr.Row():
542
  chatbot = gr.Chatbot(
543
  type="messages",
544
  show_copy_button=True,
 
555
  msg = gr.Textbox(
556
  placeholder="Ask me about math, research, study strategies, or any educational topic...",
557
  show_label=False,
558
+ lines=4,
559
+ max_lines=6,
560
  elem_classes=["input-textbox"],
561
  container=False,
562
  scale=4