Spaces:
PhilSpiel
/
Running

PhilSpiel commited on
Commit
9ec326a
1 Parent(s): f4dac8c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -10
app.py CHANGED
@@ -103,22 +103,18 @@ def predict(user_input, history, access_granted):
103
  return history, ""
104
 
105
  with gr.Blocks(theme, css="""
106
- #chatbot { flex-grow: 1; height: 460px; overflow-y: auto; }
107
  .gradio-container { height: 680px; max-width: 100% !important; padding: 0 !important; }
108
- #component-0 { height: 100%; }
109
- #component-3 { height: calc(100% - 250px); }
110
  footer { display: none !important; }
111
  #submit-btn { margin-top: 10px; }
112
  #code_submit {
113
  height: 50px !important;
114
  font-size: 1.2em !important;
115
  }
116
-
117
- /* Add these new rules here */
118
- .message-wrap { max-height: 300px !important; overflow-y: auto !important; }
119
- .chat-wrap { max-height: 400px !important; overflow-y: auto !important; }
120
- .gradio-container { height: auto !important; min-height: 0 !important; }
121
-
122
  @media (max-width: 600px) {
123
  #code_submit {
124
  height: 60px !important;
@@ -140,7 +136,7 @@ with gr.Blocks(theme, css="""
140
  code_message = gr.Label(label="Status", elem_id="code_message")
141
 
142
  with gr.Tab("Chat"):
143
- chatbot = gr.Chatbot(label="Conversation", height=340) # Adjust the height as needed
144
  msg = gr.Textbox(
145
  label=f"Chat with {coach_name_short}",
146
  placeholder="Type your message here... (MAX: 1000 characters)",
 
103
  return history, ""
104
 
105
  with gr.Blocks(theme, css="""
106
+ #chatbot { flex-grow: 1; height: 340px; overflow-y: auto; }
107
  .gradio-container { height: 680px; max-width: 100% !important; padding: 0 !important; }
108
+ #component-0 { height: 95%; }
109
+ #component-3 { height: calc(95% - 250px); }
110
  footer { display: none !important; }
111
  #submit-btn { margin-top: 10px; }
112
  #code_submit {
113
  height: 50px !important;
114
  font-size: 1.2em !important;
115
  }
116
+ .message-wrap { max-height: none !important; overflow-y: auto !important; }
117
+ .chat-wrap { max-height: none !important; overflow-y: auto !important; }
 
 
 
 
118
  @media (max-width: 600px) {
119
  #code_submit {
120
  height: 60px !important;
 
136
  code_message = gr.Label(label="Status", elem_id="code_message")
137
 
138
  with gr.Tab("Chat"):
139
+ chatbot = gr.Chatbot(label="Conversation", elem_id="chatbot", height=340)
140
  msg = gr.Textbox(
141
  label=f"Chat with {coach_name_short}",
142
  placeholder="Type your message here... (MAX: 1000 characters)",