How cgbm-unimagdalena/pagina-web-cgbm works
Purpose and Runtime
CGBM-WEB is a Vite-served React/TypeScript informational site for CGBM, covering institutional content, research, services, news, and service-request forms. Browser rendering begins at src/main.tsx, mounts the application in src/app/App.tsx, and is configured by vite.config.ts.
Application Shell and Navigation
src/app/App.tsx is the primary composition and route-selection boundary. Shared chrome and page behavior are provided by src/app/components/Header.tsx, src/app/components/Footer.tsx, and src/app/components/ScrollToTop.tsx. src/app/components/ui/PageLayout.tsx likely standardizes page framing for route-level content.
Route-Level Content Domains
Page modules separate the site into institutional, research, service, and news domains:
• Institutional/contact: src/app/pages/AboutPage.tsx, src/app/pages/ContactPage.tsx, src/app/pages/EducationPage.tsx
• Research: src/app/pages/ResearchGroupsPage.tsx, src/app/pages/ResearchProjectsPage.tsx, src/app/pages/ResearchersPage.tsx
• Services: src/app/pages/ServicesPage.tsx, src/app/pages/ServiceFormPage.tsx
• News: src/app/pages/NewsPage.tsx, src/app/pages/NewsDetailPage.tsx
Navigation flows from the shared header into these page modules; pages compose domain components and static data/assets.
Home Page as Content Aggregator
src/app/pages/HomePage.tsx assembles the landing experience from focused sections: src/app/components/home/ImageCarousel.tsx, src/app/components/home/MetricsSection.tsx, src/app/components/home/NewsEventsSection.tsx, src/app/components/home/ProjectsPreview.tsx, and src/app/components/home/ServicesPreview.tsx. This is a presentation aggregation layer rather than a backend-driven dashboard.
Service Request Forms
Service inquiry flows are split by specialty, allowing tailored form pages for PCR, NGS, barcoding, veterinary PCR, consultancy, and education: src/app/pages/PCRFormPage.tsx, src/app/pages/NGSFormPage.tsx, src/app/pages/BarcodingFormPage.tsx, src/app/pages/VeterinaryPCRFormPage.tsx, src/app/pages/ConsultancyFormPage.tsx, and src/app/pages/EducationFormPage.tsx. Reusable service-facing UI includes src/app/components/Services.tsx and src/app/components/ServiceForm.tsx. The tree does not identify a server/API integration, so submission handling should be treated as a boundary requiring verification.
Content and Asset Boundaries
Static application content is centralized in src/app/data/cgbmdata.ts and src/app/data/noticias.ts; news views likely consume the latter for listing and detail rendering. Visual and document resources are bundled under src/assets, while deployable public files include downloadable sample-submission material at public/formato-de-envio-de-muestras.xlsx and news static content under public/noticias.
Deployment and External Edge Handling
The site is a static frontend build with hosting rewrite/redirect rules in public/.htaccess and public/_redirects, indicating compatibility with Apache- and Netlify-style static hosts. og-proxy.php is the only PHP entry point and likely provides an Open Graph/proxy edge function outside the React runtime. Styling is globally layered through src/styles/index.css, src/styles/tailwind.css, and src/styles/theme.css.
Main entry points: App.tsx App and route selection · _redirects Static hosting rules · ServicesPage.tsx Services pages · NewsPage.tsx News list and detail
Components 21
Frontend Runtime
- Vite configuration
vite.config.ts - Browser entry
src/main.tsx - App and route selection
src/app/App.tsx
UI & Routes
- Shared chrome · Header, footer, and scroll behavior.
- Page layout
src/app/components/ui/PageLayout.tsx - Home page
src/app/pages/HomePage.tsx - Home sections · Carousel, metrics, news, projects, and services previews.
- Institutional pages · About, contact, and education content.
- Research pages · Groups, projects, and researchers.
- Services pages · Service catalogue and request landing page.
src/app/pages/ServicesPage.tsx - Specialty request forms · PCR, NGS, barcoding, veterinary, consultancy, and education requests.
- Reusable service UI
src/app/components/ServiceForm.tsx - Submission handling · No server or API integration is identified.
- News list and detail
src/app/pages/NewsPage.tsx
Content & Assets
- Institutional content
src/app/data/cgbmdata.ts - News content
src/app/data/noticias.ts - Bundled assets
src/assets - Global styles · Index, Tailwind, and theme styles.
Static Delivery
- Static hosting rules · Apache and Netlify rewrite support.
public/_redirects - Public downloads and news · Includes sample-submission spreadsheet and static news content.
public/formato-de-envio-de-muestras.xlsx - Open Graph proxy · Outside the React runtime.
og-proxy.php
Connections 27
- Vite configuration → Browser entry: serves and builds
- Browser entry → App and route selection: mounts
- App and route selection → Shared chrome: composes
- App and route selection → Page layout: frames routes
- App and route selection → Home page: selects route
- App and route selection → Institutional pages: selects routes
- App and route selection → Research pages: selects routes
- App and route selection → Services pages: selects route
- App and route selection → Specialty request forms: selects routes
- App and route selection → News list and detail: selects routes
- Shared chrome → Institutional pages: navigates to
- Shared chrome → Research pages: navigates to
- Shared chrome → Services pages: navigates to
- Shared chrome → News list and detail: navigates to
- Home page → Home sections: aggregates
- Home sections → News content: previews
- Services pages → Reusable service UI: uses
- Specialty request forms → Reusable service UI: reuse
- Specialty request forms → Submission handling: submit to
- Institutional pages → Institutional content: reads
- Research pages → Institutional content: reads
- News list and detail → News content: reads
- App and route selection → Global styles: applies
- App and route selection → Bundled assets: renders
- Static hosting rules → App and route selection: serves with rewrites
- Static hosting rules → Public downloads and news: serves
- Static hosting rules → Open Graph proxy: routes edge request