Spaces:
Sleeping
Sleeping
| import gradio as gr | |
| def build_welcome_page(): | |
| """ | |
| Builds the welcome/landing page: logo + title + two navigation cards. | |
| Each "card" is a Column containing a primary button plus a short | |
| Markdown caption underneath (since gr.Button only supports plain, | |
| single-line text and cannot render a styled subtitle itself). | |
| Returns (btn_single, btn_multi) so the caller can wire up | |
| page-switching logic in interface.py. | |
| """ | |
| with gr.Column(elem_classes="welcome-page"): | |
| with gr.Column(elem_classes="welcome-logo"): | |
| gr.Image( | |
| value="assets/logo.png", | |
| show_label=False, | |
| interactive=False, | |
| container=False, | |
| height=160 | |
| ) | |
| gr.Markdown( | |
| "# UniTor ESG Insights System", | |
| elem_classes="welcome-title" | |
| ) | |
| gr.Markdown( | |
| "Choose how you'd like to analyze sustainability reports.", | |
| elem_classes="welcome-title" | |
| ) | |
| with gr.Row(): | |
| with gr.Column(): | |
| btn_single = gr.Button( | |
| "π Single Report Analysis", | |
| variant="primary", | |
| elem_classes="welcome-btn" | |
| ) | |
| gr.Markdown( | |
| "Traceable, paragraph-level analysis of one company report.", | |
| elem_classes="welcome-caption" | |
| ) | |
| with gr.Column(): | |
| btn_multi = gr.Button( | |
| "π Multi-Report Comparative Analysis", | |
| variant="primary", | |
| elem_classes="welcome-btn" | |
| ) | |
| gr.Markdown( | |
| "Compare and benchmark multiple companies' reports side by side.", | |
| elem_classes="welcome-caption" | |
| ) | |
| return btn_single, btn_multi | |