Spaces:
Sleeping
Sleeping
Update src/streamlit_app.py
Browse files- src/streamlit_app.py +5 -6
src/streamlit_app.py
CHANGED
|
@@ -384,12 +384,11 @@ elif search_query:
|
|
| 384 |
|
| 385 |
for _, movie in filtered.iterrows():
|
| 386 |
poster_url, _ = get_tmdb_data(movie["clean_title"], movie["year"])
|
| 387 |
-
|
| 388 |
-
|
| 389 |
-
<
|
| 390 |
-
|
| 391 |
-
|
| 392 |
-
|
| 393 |
st.markdown(f"""
|
| 394 |
<div class="movie-box">
|
| 395 |
{poster_html}
|
|
|
|
| 384 |
|
| 385 |
for _, movie in filtered.iterrows():
|
| 386 |
poster_url, _ = get_tmdb_data(movie["clean_title"], movie["year"])
|
| 387 |
+
poster_html = (
|
| 388 |
+
f"<img src='{poster_url}' class='poster' alt='Poster'>" if poster_url and "placeholder.com" not in poster_url
|
| 389 |
+
else "<div style='width:100px;height:150px;border:2px dashed gray;display:flex;align-items:center;justify-content:center;color:gray;font-size:12px;'>No<br>Image</div>"
|
| 390 |
+
)
|
| 391 |
+
|
|
|
|
| 392 |
st.markdown(f"""
|
| 393 |
<div class="movie-box">
|
| 394 |
{poster_html}
|