Nischal Subedi
commited on
Commit
·
b62d4ec
1
Parent(s):
7ba0df4
updated UI_v2
Browse files
app.py
CHANGED
@@ -483,7 +483,7 @@ Answer:"""
|
|
483 |
/* Section titles within the unified main content area */
|
484 |
.section-title { /* For 'Know Your Rights' */
|
485 |
font-family: var(--font-family-header) !important;
|
486 |
-
font-size: 2.
|
487 |
font-weight: 800 !important; /* Extra bold */
|
488 |
color: var(--text-primary-dark) !important;
|
489 |
text-align: center !important;
|
@@ -495,7 +495,7 @@ Answer:"""
|
|
495 |
}
|
496 |
.sub-section-title { /* For 'Ask Your Question', 'Example Questions to Ask' */
|
497 |
font-family: var(--font-family-header) !important;
|
498 |
-
font-size: 2rem !important; /* Slightly smaller for sub-sections */
|
499 |
font-weight: 700 !important;
|
500 |
color: var(--text-primary-dark) !important;
|
501 |
text-align: center !important; /* Ensures centering for all sub-section titles */
|
@@ -609,8 +609,6 @@ Answer:"""
|
|
609 |
color: var(--text-primary-light) !important;
|
610 |
box-shadow: inset 0 1px 3px rgba(0,0,0,0.1);
|
611 |
}
|
612 |
-
.gradio-textbox textarea::placeholder,
|
613 |
-
.gradio-textbox input[type=password]::placeholder { color: #A0AEC0 !important; }
|
614 |
.gradio-textbox textarea:focus,
|
615 |
.gradio-dropdown select:focus,
|
616 |
.gradio-textbox input[type=password]:focus {
|
@@ -892,16 +890,19 @@ Answer:"""
|
|
892 |
}
|
893 |
.app-footer {
|
894 |
padding: 0 var(--padding-lg) !important;
|
895 |
-
|
896 |
display: flex;
|
897 |
flex-direction: column;
|
898 |
-
align-items:
|
|
|
|
|
899 |
}
|
900 |
.app-footer p {
|
901 |
font-size: 1.05rem !important;
|
902 |
color: var(--text-secondary-dark) !important;
|
903 |
margin-bottom: 1rem;
|
904 |
-
max-width: 900px;
|
|
|
905 |
transition: color var(--transition-speed);
|
906 |
}
|
907 |
.app-footer a {
|
@@ -977,7 +978,7 @@ Answer:"""
|
|
977 |
.main-dashboard-container { padding: var(--padding-md) !important; margin-bottom: 0.6rem; border-radius: var(--radius-md); gap: 2rem; }
|
978 |
.dashboard-card-section { padding: var(--padding-sm); border-radius: var(--radius-sm); }
|
979 |
.section-title { font-size: 2.2rem !important; margin-bottom: 1.5rem !important; }
|
980 |
-
.sub-section-title { font-size: 1.8rem !important; margin-
|
981 |
.section-divider { margin: 1.8rem 0; }
|
982 |
.input-row { gap: 1.5rem; }
|
983 |
.input-field { min-width: 280px; }
|
@@ -986,6 +987,7 @@ Answer:"""
|
|
986 |
.examples-section { padding-top: 1.2rem; }
|
987 |
.examples-section .gr-examples-table th, .examples-section .gr-examples-table td { padding: 0.9rem 1.1rem !important; }
|
988 |
.app-footer-wrapper { margin-top: 0.6rem; border-top-left-radius: var(--radius-md); border-top-right-radius: var(--radius-md); }
|
|
|
989 |
}
|
990 |
@media (max-width: 768px) {
|
991 |
.gradio-container > .flex.flex-col { padding: 0 1rem !important; }
|
@@ -1006,9 +1008,10 @@ Answer:"""
|
|
1006 |
.output-card .response-header { font-size: 1.5rem; }
|
1007 |
.output-card .response-icon { font-size: 1.7rem; }
|
1008 |
.output-card .placeholder { padding: 2.5rem 1.5rem; font-size: 1.1rem; }
|
1009 |
-
.examples-section { padding-top: 1.2rem; }
|
1010 |
-
.examples-section .gr-examples-table th, .examples-section .gr-examples-table td { padding: 0.9rem 1.1rem !important; font-size: 1.0rem !important; }
|
1011 |
.app-footer-wrapper { margin-top: 0.5rem; padding-top: 2rem; padding-bottom: 2rem; border-top-left-radius: var(--radius-md); border-top-right-radius: var(--radius-md); }
|
|
|
1012 |
}
|
1013 |
@media (max-width: 480px) {
|
1014 |
.gradio-container > .flex.flex-col { padding: 0 0.8rem !important; }
|
@@ -1030,6 +1033,7 @@ Answer:"""
|
|
1030 |
.examples-section { padding-top: 0.8rem; }
|
1031 |
.examples-section .gr-examples-table th, .examples-section .gr-examples-table td { padding: 0.6rem 0.8rem !important; font-size: 0.95rem !important; }
|
1032 |
.app-footer-wrapper { margin-top: 0.4rem; padding-top: 1.5rem; padding-bottom: 1.5rem; border-top-left-radius: var(--radius-sm); border-top-right-radius: var(--radius-sm); }
|
|
|
1033 |
}
|
1034 |
"""
|
1035 |
|
@@ -1063,7 +1067,8 @@ Answer:"""
|
|
1063 |
with gr.Group(elem_classes="dashboard-card-section"):
|
1064 |
gr.Markdown("<h3 class='sub-section-title'>OpenAI API Key</h3>")
|
1065 |
api_key_input = gr.Textbox(
|
1066 |
-
label="
|
|
|
1067 |
info="Required to process your query. Securely used per request, not stored. <a href='https://platform.openai.com/api-keys' target='_blank'>Get one free from OpenAI</a>.", lines=1
|
1068 |
)
|
1069 |
|
|
|
483 |
/* Section titles within the unified main content area */
|
484 |
.section-title { /* For 'Know Your Rights' */
|
485 |
font-family: var(--font-family-header) !important;
|
486 |
+
font-size: 2.8rem !important; /* Larger section titles */
|
487 |
font-weight: 800 !important; /* Extra bold */
|
488 |
color: var(--text-primary-dark) !important;
|
489 |
text-align: center !important;
|
|
|
495 |
}
|
496 |
.sub-section-title { /* For 'Ask Your Question', 'Example Questions to Ask' */
|
497 |
font-family: var(--font-family-header) !important;
|
498 |
+
font-size: 2.2rem !important; /* Slightly smaller for sub-sections, increased from 2rem */
|
499 |
font-weight: 700 !important;
|
500 |
color: var(--text-primary-dark) !important;
|
501 |
text-align: center !important; /* Ensures centering for all sub-section titles */
|
|
|
609 |
color: var(--text-primary-light) !important;
|
610 |
box-shadow: inset 0 1px 3px rgba(0,0,0,0.1);
|
611 |
}
|
|
|
|
|
612 |
.gradio-textbox textarea:focus,
|
613 |
.gradio-dropdown select:focus,
|
614 |
.gradio-textbox input[type=password]:focus {
|
|
|
890 |
}
|
891 |
.app-footer {
|
892 |
padding: 0 var(--padding-lg) !important;
|
893 |
+
/* Changed from align-items: center */
|
894 |
display: flex;
|
895 |
flex-direction: column;
|
896 |
+
align-items: flex-start; /* Align content to the start (left) */
|
897 |
+
max-width: 1120px; /* Match main content width */
|
898 |
+
margin: 0 auto; /* Center the footer content block */
|
899 |
}
|
900 |
.app-footer p {
|
901 |
font-size: 1.05rem !important;
|
902 |
color: var(--text-secondary-dark) !important;
|
903 |
margin-bottom: 1rem;
|
904 |
+
max-width: 900px; /* Keep max-width for readability */
|
905 |
+
text-align: left; /* Ensure text aligns left within its container */
|
906 |
transition: color var(--transition-speed);
|
907 |
}
|
908 |
.app-footer a {
|
|
|
978 |
.main-dashboard-container { padding: var(--padding-md) !important; margin-bottom: 0.6rem; border-radius: var(--radius-md); gap: 2rem; }
|
979 |
.dashboard-card-section { padding: var(--padding-sm); border-radius: var(--radius-sm); }
|
980 |
.section-title { font-size: 2.2rem !important; margin-bottom: 1.5rem !important; }
|
981 |
+
.sub-section-title { font-size: 1.8rem !important; margin-bottom: 0.7rem !important; } /* Adjusted for 1024px */
|
982 |
.section-divider { margin: 1.8rem 0; }
|
983 |
.input-row { gap: 1.5rem; }
|
984 |
.input-field { min-width: 280px; }
|
|
|
987 |
.examples-section { padding-top: 1.2rem; }
|
988 |
.examples-section .gr-examples-table th, .examples-section .gr-examples-table td { padding: 0.9rem 1.1rem !important; }
|
989 |
.app-footer-wrapper { margin-top: 0.6rem; border-top-left-radius: var(--radius-md); border-top-right-radius: var(--radius-md); }
|
990 |
+
.app-footer { padding: 0 1.5rem !important; } /* Match main content padding */
|
991 |
}
|
992 |
@media (max-width: 768px) {
|
993 |
.gradio-container > .flex.flex-col { padding: 0 1rem !important; }
|
|
|
1008 |
.output-card .response-header { font-size: 1.5rem; }
|
1009 |
.output-card .response-icon { font-size: 1.7rem; }
|
1010 |
.output-card .placeholder { padding: 2.5rem 1.5rem; font-size: 1.1rem; }
|
1011 |
+
.examples-section { padding-top: 1.2rem; }
|
1012 |
+
.examples-section .gr-examples-table th, .examples-section .gr-examples-table td { padding: 0.9rem 1.1rem !important; font-size: 1.0rem !important; }
|
1013 |
.app-footer-wrapper { margin-top: 0.5rem; padding-top: 2rem; padding-bottom: 2rem; border-top-left-radius: var(--radius-md); border-top-right-radius: var(--radius-md); }
|
1014 |
+
.app-footer { padding: 0 1rem !important; } /* Match main content padding */
|
1015 |
}
|
1016 |
@media (max-width: 480px) {
|
1017 |
.gradio-container > .flex.flex-col { padding: 0 0.8rem !important; }
|
|
|
1033 |
.examples-section { padding-top: 0.8rem; }
|
1034 |
.examples-section .gr-examples-table th, .examples-section .gr-examples-table td { padding: 0.6rem 0.8rem !important; font-size: 0.95rem !important; }
|
1035 |
.app-footer-wrapper { margin-top: 0.4rem; padding-top: 1.5rem; padding-bottom: 1.5rem; border-top-left-radius: var(--radius-sm); border-top-right-radius: var(--radius-sm); }
|
1036 |
+
.app-footer { padding: 0 0.8rem !important; } /* Match main content padding */
|
1037 |
}
|
1038 |
"""
|
1039 |
|
|
|
1067 |
with gr.Group(elem_classes="dashboard-card-section"):
|
1068 |
gr.Markdown("<h3 class='sub-section-title'>OpenAI API Key</h3>")
|
1069 |
api_key_input = gr.Textbox(
|
1070 |
+
label="", # Removed redundant label here
|
1071 |
+
type="password", placeholder="Enter your API key (e.g., sk-...)",
|
1072 |
info="Required to process your query. Securely used per request, not stored. <a href='https://platform.openai.com/api-keys' target='_blank'>Get one free from OpenAI</a>.", lines=1
|
1073 |
)
|
1074 |
|