mobenta commited on
Commit
e91bc53
·
verified ·
1 Parent(s): c0d5831

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -7
app.py CHANGED
@@ -93,9 +93,9 @@ def show_video(video_url):
93
  # Create the Gradio interface
94
  with gr.Blocks(css="""
95
  #search_output img {
96
- width: 150px !important;
97
- height: 150px !important;
98
- margin-right: 5px;
99
  }
100
  #search_output .gallery-item {
101
  display: flex !important;
@@ -105,7 +105,7 @@ with gr.Blocks(css="""
105
  #search_output .gallery-caption {
106
  text-align: left !important;
107
  padding-left: 20px;
108
- font-size: 100px !important;
109
  font-weight: bold !important;
110
  }
111
  """) as demo:
@@ -130,9 +130,8 @@ with gr.Blocks(css="""
130
  video_ids = []
131
  for item in search_results:
132
  image_url = item['thumbnail_url']
133
- title = item['title'] # Only show the title
134
- caption = f"<div><h3>{title}</h3></div>" # Use only the title
135
- gallery_items.append((image_url, caption))
136
  video_ids.append(item['video_id'])
137
  return gallery_items, video_ids
138
 
 
93
  # Create the Gradio interface
94
  with gr.Blocks(css="""
95
  #search_output img {
96
+ width: 500px !important;
97
+ height: auto !important;
98
+ margin-right: 20px;
99
  }
100
  #search_output .gallery-item {
101
  display: flex !important;
 
105
  #search_output .gallery-caption {
106
  text-align: left !important;
107
  padding-left: 20px;
108
+ font-size: 24px !important;
109
  font-weight: bold !important;
110
  }
111
  """) as demo:
 
130
  video_ids = []
131
  for item in search_results:
132
  image_url = item['thumbnail_url']
133
+ title = item['title'] # Only show the title as plain text
134
+ gallery_items.append((image_url, title)) # Pass the title directly as plain text
 
135
  video_ids.append(item['video_id'])
136
  return gallery_items, video_ids
137