jwilles commited on
Commit
6fa5c81
·
1 Parent(s): 8596ab1

Push new font

Browse files
Files changed (2) hide show
  1. app.py +9 -1
  2. src/display/css_html_js.py +58 -0
app.py CHANGED
@@ -75,7 +75,15 @@ def init_leaderboard(dataframe, benchmark_type):
75
 
76
  demo = gr.Blocks(css=custom_css)
77
  with demo:
78
- gr.HTML(TITLE)
 
 
 
 
 
 
 
 
79
  gr.Markdown(INTRODUCTION_TEXT, elem_classes="markdown-text")
80
 
81
  with gr.Tabs(elem_classes="tab-buttons") as tabs:
 
75
 
76
  demo = gr.Blocks(css=custom_css)
77
  with demo:
78
+ gr.HTML(f"""
79
+ <div style="text-align:center; margin-top: 1rem;">
80
+ <h1 style="margin-bottom:0;">{TITLE}</h1>
81
+ <p style="color: #eb088a; font-size:1.1rem; margin:0;">
82
+ Performance Insights &amp; Comparison
83
+ </p>
84
+ </div>
85
+ """)
86
+ # gr.HTML(TITLE)
87
  gr.Markdown(INTRODUCTION_TEXT, elem_classes="markdown-text")
88
 
89
  with gr.Tabs(elem_classes="tab-buttons") as tabs:
src/display/css_html_js.py CHANGED
@@ -95,6 +95,64 @@ custom_css = """
95
  border: 0
96
  }
97
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
98
  """
99
 
100
  get_window_url_params = """
 
95
  border: 0
96
  }
97
 
98
+ @font-face {
99
+ font-family: 'Karbon';
100
+ font-weight: 400;
101
+ font-style: normal;
102
+ }
103
+
104
+ body, .gradio-container {
105
+ font-family: 'Karbon', sans-serif;
106
+ background-color: #ffffff;
107
+ color: #000000; /* main text color */
108
+ margin: 0;
109
+ padding: 0;
110
+ }
111
+
112
+ h1, h2, h3, h4, h5, h6 {
113
+ color: #eb088a; /* your brand color for headings */
114
+ font-weight: 600;
115
+ margin-bottom: 1rem;
116
+ }
117
+
118
+ .tab-buttons > .tabitem {
119
+ background-color: transparent;
120
+ border: 2px solid #eb088a;
121
+ color: #eb088a;
122
+ margin-right: 5px;
123
+ cursor: pointer;
124
+ transition: all 0.2s ease-in-out;
125
+ }
126
+ .tab-buttons > .tabitem:hover {
127
+ background-color: #eb088a;
128
+ color: #ffffff;
129
+ }
130
+
131
+ .markdown-text {
132
+ line-height: 1.6;
133
+ margin-bottom: 2rem;
134
+ }
135
+
136
+ /* Dataframe styling example */
137
+ .gr-dataframe table {
138
+ border: 1px solid #eb088a;
139
+ }
140
+ .gr-dataframe th {
141
+ background-color: #eb088a;
142
+ color: #ffffff;
143
+ }
144
+ .gr-dataframe td {
145
+ border-bottom: 1px solid #eb088a;
146
+ }
147
+
148
+ /* Example ‘intro-block’ styling if you want extra flair */
149
+ .intro-block {
150
+ background-color: #eb088a10; /* light tinted background */
151
+ padding: 1.5rem;
152
+ border-radius: 10px;
153
+ margin-bottom: 2rem;
154
+ }
155
+
156
  """
157
 
158
  get_window_url_params = """