Fix table headers, logo size, and filter row styling
Browse files- Override Gradio 6 .header-content white-space:normal with nowrap
- Override Gradio 6 thead/tbody table-layout:fixed with auto
- Increase IBM logo from 40px to 64px height
- Polish filter row with flexbox alignment and spacing
app.py
CHANGED
|
@@ -472,7 +472,7 @@ CUSTOM_CSS = """
|
|
| 472 |
margin-bottom: 12px;
|
| 473 |
}
|
| 474 |
#hero-header .logo-row img {
|
| 475 |
-
height:
|
| 476 |
filter: brightness(0) invert(1);
|
| 477 |
opacity: 0.9;
|
| 478 |
}
|
|
@@ -509,50 +509,40 @@ CUSTOM_CSS = """
|
|
| 509 |
}
|
| 510 |
|
| 511 |
/* === Tables (Dataframe) === */
|
| 512 |
-
|
| 513 |
-
|
| 514 |
-
#leaderboard-table [class*="table"] {
|
| 515 |
border-radius: 12px !important;
|
| 516 |
-
overflow-x: auto !important;
|
| 517 |
border: 1px solid #e2e8f0 !important;
|
| 518 |
}
|
| 519 |
-
|
| 520 |
-
|
| 521 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 522 |
}
|
| 523 |
-
|
| 524 |
-
|
| 525 |
-
#leaderboard-table th {
|
| 526 |
background: #f1f5f9 !important;
|
| 527 |
color: #334155 !important;
|
| 528 |
font-weight: 600 !important;
|
| 529 |
font-size: 0.82rem !important;
|
| 530 |
text-transform: uppercase !important;
|
| 531 |
letter-spacing: 0.04em !important;
|
| 532 |
-
padding: 12px 16px !important;
|
| 533 |
border-bottom: 2px solid #e2e8f0 !important;
|
| 534 |
-
white-space: nowrap !important;
|
| 535 |
-
overflow: hidden !important;
|
| 536 |
-
text-overflow: ellipsis !important;
|
| 537 |
}
|
| 538 |
-
|
| 539 |
-
|
| 540 |
-
#leaderboard-table td {
|
| 541 |
-
padding: 10px 16px !important;
|
| 542 |
font-size: 0.88rem !important;
|
| 543 |
border-bottom: 1px solid #f1f5f9 !important;
|
| 544 |
-
white-space: nowrap !important;
|
| 545 |
-
overflow: hidden !important;
|
| 546 |
-
text-overflow: ellipsis !important;
|
| 547 |
}
|
| 548 |
-
|
| 549 |
-
|
| 550 |
background: #eff6ff !important;
|
| 551 |
}
|
| 552 |
-
/* Force horizontal layout for Gradio 6 dataframe cells */
|
| 553 |
-
#leaderboard-table .cell-wrap {
|
| 554 |
-
white-space: nowrap !important;
|
| 555 |
-
}
|
| 556 |
|
| 557 |
/* === Accordion (FAQ) === */
|
| 558 |
.faq-section .accordion {
|
|
@@ -593,13 +583,24 @@ CUSTOM_CSS = """
|
|
| 593 |
box-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.04) !important;
|
| 594 |
}
|
| 595 |
|
|
|
|
| 596 |
/* === Filter Row === */
|
| 597 |
.filter-row {
|
| 598 |
background: #f8fafc !important;
|
| 599 |
border: 1px solid #e2e8f0 !important;
|
| 600 |
-
border-radius:
|
| 601 |
-
padding:
|
| 602 |
-
margin-bottom:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 603 |
}
|
| 604 |
|
| 605 |
/* === Responsive === */
|
|
|
|
| 472 |
margin-bottom: 12px;
|
| 473 |
}
|
| 474 |
#hero-header .logo-row img {
|
| 475 |
+
height: 64px;
|
| 476 |
filter: brightness(0) invert(1);
|
| 477 |
opacity: 0.9;
|
| 478 |
}
|
|
|
|
| 509 |
}
|
| 510 |
|
| 511 |
/* === Tables (Dataframe) === */
|
| 512 |
+
/* Container styling */
|
| 513 |
+
.table-wrap {
|
|
|
|
| 514 |
border-radius: 12px !important;
|
|
|
|
| 515 |
border: 1px solid #e2e8f0 !important;
|
| 516 |
}
|
| 517 |
+
/* Override Gradio 6 internal: force nowrap on header text */
|
| 518 |
+
.header-content {
|
| 519 |
+
white-space: nowrap !important;
|
| 520 |
+
overflow-wrap: normal !important;
|
| 521 |
+
word-break: normal !important;
|
| 522 |
+
}
|
| 523 |
+
/* Override Gradio 6 internal: use auto layout instead of fixed */
|
| 524 |
+
table :is(thead, tfoot, tbody) {
|
| 525 |
+
table-layout: auto !important;
|
| 526 |
}
|
| 527 |
+
/* Header cell styling */
|
| 528 |
+
table thead th {
|
|
|
|
| 529 |
background: #f1f5f9 !important;
|
| 530 |
color: #334155 !important;
|
| 531 |
font-weight: 600 !important;
|
| 532 |
font-size: 0.82rem !important;
|
| 533 |
text-transform: uppercase !important;
|
| 534 |
letter-spacing: 0.04em !important;
|
|
|
|
| 535 |
border-bottom: 2px solid #e2e8f0 !important;
|
|
|
|
|
|
|
|
|
|
| 536 |
}
|
| 537 |
+
/* Data cell styling */
|
| 538 |
+
table tbody td {
|
|
|
|
|
|
|
| 539 |
font-size: 0.88rem !important;
|
| 540 |
border-bottom: 1px solid #f1f5f9 !important;
|
|
|
|
|
|
|
|
|
|
| 541 |
}
|
| 542 |
+
/* Row hover */
|
| 543 |
+
table tbody tr:hover {
|
| 544 |
background: #eff6ff !important;
|
| 545 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
| 546 |
|
| 547 |
/* === Accordion (FAQ) === */
|
| 548 |
.faq-section .accordion {
|
|
|
|
| 583 |
box-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.04) !important;
|
| 584 |
}
|
| 585 |
|
| 586 |
+
/* === Filter Row === */
|
| 587 |
/* === Filter Row === */
|
| 588 |
.filter-row {
|
| 589 |
background: #f8fafc !important;
|
| 590 |
border: 1px solid #e2e8f0 !important;
|
| 591 |
+
border-radius: 12px !important;
|
| 592 |
+
padding: 16px 20px !important;
|
| 593 |
+
margin-bottom: 16px !important;
|
| 594 |
+
display: flex !important;
|
| 595 |
+
align-items: end !important;
|
| 596 |
+
gap: 16px !important;
|
| 597 |
+
}
|
| 598 |
+
.filter-row > div {
|
| 599 |
+
flex: 1 !important;
|
| 600 |
+
min-width: 0 !important;
|
| 601 |
+
}
|
| 602 |
+
.filter-row .wrap {
|
| 603 |
+
gap: 4px !important;
|
| 604 |
}
|
| 605 |
|
| 606 |
/* === Responsive === */
|