Update app.py
Browse filesUpdating the layout of the User Interface tab.
app.py
CHANGED
|
@@ -11,14 +11,14 @@ def show_stars():
|
|
| 11 |
.title-text {
|
| 12 |
color: white;
|
| 13 |
font-family: sans-serif;
|
| 14 |
-
font-size:
|
| 15 |
font-weight: bold;
|
| 16 |
}
|
| 17 |
|
| 18 |
/* Empty stars */
|
| 19 |
.star-rating {
|
| 20 |
display: inline-block;
|
| 21 |
-
font-size:
|
| 22 |
color: lightgray;
|
| 23 |
}
|
| 24 |
|
|
@@ -33,7 +33,7 @@ def show_stars():
|
|
| 33 |
background-color: #1f2937;
|
| 34 |
padding: 10px;
|
| 35 |
border-radius: 5px;
|
| 36 |
-
width:
|
| 37 |
margin-left: 0;
|
| 38 |
}
|
| 39 |
|
|
@@ -42,7 +42,7 @@ def show_stars():
|
|
| 42 |
border: 1px transparent;
|
| 43 |
background-color: #ca8a04;
|
| 44 |
padding: 3px;
|
| 45 |
-
border-radius:
|
| 46 |
display: inline-block;
|
| 47 |
margin-bottom: 6px;
|
| 48 |
}
|
|
@@ -104,14 +104,17 @@ with gr.Blocks(theme=theme) as demo:
|
|
| 104 |
|
| 105 |
# Basic user interface for company's view -Janika
|
| 106 |
with gr.Tab("User Interface"):
|
| 107 |
-
|
| 108 |
-
|
|
|
|
|
|
|
| 109 |
|
| 110 |
-
|
| 111 |
-
|
|
|
|
| 112 |
|
| 113 |
-
|
| 114 |
-
|
| 115 |
|
| 116 |
# Testing Area, for Piitu -Janika
|
| 117 |
with gr.Tab("Testing Area"):
|
|
|
|
| 11 |
.title-text {
|
| 12 |
color: white;
|
| 13 |
font-family: sans-serif;
|
| 14 |
+
font-size: 14px;
|
| 15 |
font-weight: bold;
|
| 16 |
}
|
| 17 |
|
| 18 |
/* Empty stars */
|
| 19 |
.star-rating {
|
| 20 |
display: inline-block;
|
| 21 |
+
font-size: 1.5em;
|
| 22 |
color: lightgray;
|
| 23 |
}
|
| 24 |
|
|
|
|
| 33 |
background-color: #1f2937;
|
| 34 |
padding: 10px;
|
| 35 |
border-radius: 5px;
|
| 36 |
+
width: 100%;
|
| 37 |
margin-left: 0;
|
| 38 |
}
|
| 39 |
|
|
|
|
| 42 |
border: 1px transparent;
|
| 43 |
background-color: #ca8a04;
|
| 44 |
padding: 3px;
|
| 45 |
+
border-radius: 8px;
|
| 46 |
display: inline-block;
|
| 47 |
margin-bottom: 6px;
|
| 48 |
}
|
|
|
|
| 104 |
|
| 105 |
# Basic user interface for company's view -Janika
|
| 106 |
with gr.Tab("User Interface"):
|
| 107 |
+
with gr.Row():
|
| 108 |
+
with gr.Column(scale=1, min_width=300):
|
| 109 |
+
# Summary
|
| 110 |
+
summary_output = gr.Textbox(label="Summary")
|
| 111 |
|
| 112 |
+
with gr.Column(scale=2, min_width=300):
|
| 113 |
+
# Star rating
|
| 114 |
+
star_rating = gr.HTML(value=show_stars())
|
| 115 |
|
| 116 |
+
# Keywords
|
| 117 |
+
keywords_output = gr.Textbox(label="Keywords")
|
| 118 |
|
| 119 |
# Testing Area, for Piitu -Janika
|
| 120 |
with gr.Tab("Testing Area"):
|