Yuxuan-Zhang-Dexter commited on
Commit
0e935df
·
1 Parent(s): 6fcfa6c
Files changed (1) hide show
  1. app.py +22 -6
app.py CHANGED
@@ -33,6 +33,7 @@ from gallery_tab import create_video_gallery
33
  # Try to import enhanced leaderboard, use standard DataFrame if not available
34
 
35
  from gradio_leaderboard import Leaderboard, SelectColumns, ColumnFilter
 
36
  HAS_ENHANCED_LEADERBOARD = True
37
 
38
 
@@ -496,20 +497,36 @@ def build_app():
496
 
497
  /* Enhanced table styling - SIMPLIFIED */
498
  .table-container {
499
- height: 800px !important;
500
- max-height: 1000px !important;
501
- overflow-y: auto !important; /* ONLY the outer container gets scrolling */
502
  border-radius: 8px;
503
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
504
  }
505
 
506
- /* Prevent inner containers from having scrollbars */
507
  .table-container > div,
508
  .table-container > div > div,
509
  .gradio-dataframe > div,
510
  [data-testid="dataframe"] > div {
511
  overflow: visible !important;
512
  height: auto !important;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
513
  }
514
 
515
  /* Fix table styling */
@@ -655,8 +672,7 @@ def build_app():
655
  interactive=True,
656
  elem_id="leaderboard-table",
657
  elem_classes="table-container",
658
- wrap=True,
659
- column_widths={"Player": "25%", "Organization": "20%"}
660
  )
661
 
662
  # Add the score note below the table
 
33
  # Try to import enhanced leaderboard, use standard DataFrame if not available
34
 
35
  from gradio_leaderboard import Leaderboard, SelectColumns, ColumnFilter
36
+
37
  HAS_ENHANCED_LEADERBOARD = True
38
 
39
 
 
497
 
498
  /* Enhanced table styling - SIMPLIFIED */
499
  .table-container {
500
+ height: auto !important;
501
+ max-height: none !important;
502
+ overflow: visible !important;
503
  border-radius: 8px;
504
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
505
  }
506
 
507
+ /* Remove unnecessary container styles */
508
  .table-container > div,
509
  .table-container > div > div,
510
  .gradio-dataframe > div,
511
  [data-testid="dataframe"] > div {
512
  overflow: visible !important;
513
  height: auto !important;
514
+ max-height: none !important;
515
+ }
516
+
517
+ /* Large screen adjustments */
518
+ @media screen and (min-height: 1200px) {
519
+ .table-container {
520
+ height: auto !important;
521
+ max-height: none !important;
522
+ overflow: visible !important;
523
+ }
524
+
525
+ .gradio-container {
526
+ height: auto !important;
527
+ max-height: none !important;
528
+ overflow: visible !important;
529
+ }
530
  }
531
 
532
  /* Fix table styling */
 
672
  interactive=True,
673
  elem_id="leaderboard-table",
674
  elem_classes="table-container",
675
+ wrap=True
 
676
  )
677
 
678
  # Add the score note below the table