Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -39,15 +39,18 @@ def main():
|
|
| 39 |
|
| 40 |
# Display caption table with CSS class names
|
| 41 |
st.write("## Caption Table")
|
|
|
|
| 42 |
st.write(
|
| 43 |
-
"<
|
|
|
|
| 44 |
unsafe_allow_html=True,
|
| 45 |
)
|
|
|
|
| 46 |
|
| 47 |
for i in range(start_index, min(end_index, len(captions_list))):
|
| 48 |
st.write(
|
| 49 |
-
f"<tr><td
|
| 50 |
-
f"<td
|
| 51 |
unsafe_allow_html=True,
|
| 52 |
)
|
| 53 |
|
|
|
|
| 39 |
|
| 40 |
# Display caption table with CSS class names
|
| 41 |
st.write("## Caption Table")
|
| 42 |
+
st.write("<table style='border-collapse: collapse; width: 100%;'>", unsafe_allow_html=True)
|
| 43 |
st.write(
|
| 44 |
+
"<tr><th style='padding: 8px; border: 1px solid black; background-color: #f2f2f2; font-weight: bold; text-align: center; width: 50%;'>Timestamp</th>"
|
| 45 |
+
"<th style='padding: 8px; border: 1px solid black; background-color: #f2f2f2; font-weight: bold; text-align: center; width: 50%;'>Original</th></tr>",
|
| 46 |
unsafe_allow_html=True,
|
| 47 |
)
|
| 48 |
+
|
| 49 |
|
| 50 |
for i in range(start_index, min(end_index, len(captions_list))):
|
| 51 |
st.write(
|
| 52 |
+
f"<tr><td style='padding: 8px; border: 1px solid black; background-color: rgb(255, 0, 0); color: rgb(128, 128, 128); text-align: center;'>{captions_list[i]['Timestamp']}</td>"
|
| 53 |
+
f"<td style='padding: 8px; border: 1px solid black; background-color: rgb(0, 0, 0); color: rgb(255, 255, 255); text-align: center;'>{captions_list[i]['Original']}</td></tr>",
|
| 54 |
unsafe_allow_html=True,
|
| 55 |
)
|
| 56 |
|