Mike0021 commited on
Commit
44fc532
·
verified ·
1 Parent(s): b73eb3a

Fix dataframe dark mode contrast

Browse files
Files changed (1) hide show
  1. app.py +51 -0
app.py CHANGED
@@ -640,6 +640,12 @@ CSS = """
640
  --button-primary-background-fill-hover: #0d9488;
641
  --button-primary-text-color: #f8fafc;
642
  --link-text-color: #67e8f9;
 
 
 
 
 
 
643
  background:
644
  radial-gradient(circle at 12% 0%, rgba(20, 184, 166, 0.18), transparent 28%),
645
  linear-gradient(135deg, #070b13 0%, #0f172a 52%, #111827 100%);
@@ -805,11 +811,39 @@ CSS = """
805
  color: #e5efff !important;
806
  border-color: rgba(148, 163, 184, 0.24) !important;
807
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
808
  .gradio-container th {
809
  background: #111827 !important;
810
  color: #f8fafc !important;
811
  border-color: rgba(148, 163, 184, 0.24) !important;
812
  }
 
 
 
 
 
 
 
 
 
 
 
 
813
  .gradio-container td {
814
  background: #0b1220 !important;
815
  color: #e2e8f0 !important;
@@ -818,6 +852,23 @@ CSS = """
818
  .gradio-container tr:nth-child(even) td {
819
  background: #0f172a !important;
820
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
821
  .gradio-container .plot-container,
822
  .gradio-container .js-plotly-plot {
823
  background: #0b1220 !important;
 
640
  --button-primary-background-fill-hover: #0d9488;
641
  --button-primary-text-color: #f8fafc;
642
  --link-text-color: #67e8f9;
643
+ --table-background-fill: #0b1220;
644
+ --table-even-background-fill: #0f172a;
645
+ --table-odd-background-fill: #0b1220;
646
+ --table-border-color: rgba(148, 163, 184, 0.24);
647
+ --table-text-color: #e5efff;
648
+ --table-row-focus: #1e293b;
649
  background:
650
  radial-gradient(circle at 12% 0%, rgba(20, 184, 166, 0.18), transparent 28%),
651
  linear-gradient(135deg, #070b13 0%, #0f172a 52%, #111827 100%);
 
811
  color: #e5efff !important;
812
  border-color: rgba(148, 163, 184, 0.24) !important;
813
  }
814
+ .gradio-container .table-container,
815
+ .gradio-container svelte-virtual-table-viewport,
816
+ .gradio-container button.disable_click,
817
+ .gradio-container button[aria-label*="Drop CSV"],
818
+ .gradio-container button[aria-label*="TSV"] {
819
+ background: #0b1220 !important;
820
+ color: #e5efff !important;
821
+ border-color: rgba(148, 163, 184, 0.24) !important;
822
+ }
823
+ .gradio-container table.table,
824
+ .gradio-container table.table thead,
825
+ .gradio-container table.table tbody,
826
+ .gradio-container table.table tfoot {
827
+ background: #0b1220 !important;
828
+ color: #e5efff !important;
829
+ }
830
  .gradio-container th {
831
  background: #111827 !important;
832
  color: #f8fafc !important;
833
  border-color: rgba(148, 163, 184, 0.24) !important;
834
  }
835
+ .gradio-container table.table thead,
836
+ .gradio-container table.table thead tr,
837
+ .gradio-container table.table th,
838
+ .gradio-container table.table th *,
839
+ .gradio-container table.table .header-content,
840
+ .gradio-container table.table .header-button,
841
+ .gradio-container table.table .cell-wrap {
842
+ background: #111827 !important;
843
+ color: #f8fafc !important;
844
+ border-color: rgba(148, 163, 184, 0.24) !important;
845
+ opacity: 1 !important;
846
+ }
847
  .gradio-container td {
848
  background: #0b1220 !important;
849
  color: #e2e8f0 !important;
 
852
  .gradio-container tr:nth-child(even) td {
853
  background: #0f172a !important;
854
  }
855
+ .gradio-container table.table tbody tr,
856
+ .gradio-container table.table tbody td,
857
+ .gradio-container table.table tbody .cell-wrap {
858
+ background: #0b1220 !important;
859
+ color: #e2e8f0 !important;
860
+ }
861
+ .gradio-container table.table tbody tr.row-odd,
862
+ .gradio-container table.table tbody tr.row-odd td,
863
+ .gradio-container table.table tbody tr.row-odd .cell-wrap {
864
+ background: #0f172a !important;
865
+ }
866
+ .gradio-container table.table span.text,
867
+ .gradio-container table.table button {
868
+ color: #e5efff !important;
869
+ -webkit-text-fill-color: #e5efff !important;
870
+ opacity: 1 !important;
871
+ }
872
  .gradio-container .plot-container,
873
  .gradio-container .js-plotly-plot {
874
  background: #0b1220 !important;