# raulmendezz/proyectosirvent architecture

> Architecture diagram of the GitHub repository raulmendezz/proyectosirvent, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-05-29). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/raulmendezz/proyectosirvent
- Repository: https://github.com/raulmendezz/proyectosirvent

## Overview

1. **Repository shape**
   - The repo looks like a **two-app workspace** rather than one single product.
   - `adminSystem/` is the main structured application area, and `webSirvent/` is a separate, simpler front-end/site bundle.
   - The root also includes `turbo.json`, which suggests the admin side is organized for workspace-style builds, even though the visible tree only shows one app.

2. **Admin system: primary application**
   - `adminSystem/apps/admin-dashboard` is a **Next.js admin dashboard** built with TypeScript.
   - It is the most architected subsystem in the repo and likely the main target for the architecture diagram.
   - The app uses the **Next.js App Router** pattern, with route folders under `app/` and also `src/app/`.

3. **Admin dashboard routing and pages**
   - The dashboard has a small route surface: a root page and a `/dashboard` page.
   - Key files include `app/page.tsx`, `app/layout.tsx`, and `app/dashboard/page.tsx`.
   - There is also a parallel `src/app/dashboard/page.tsx`, so the codebase appears to have **overlapping route sources** or a migration in progress; for architecture purposes, treat this as one UI app with duplicated route definitions that should be clarified.

4. **Presentation and layout layer**
   - `app/globals.css` provides the global styling baseline.
   - `src/DashboardLayout.tsx` suggests a reusable **shell/layout component** for the admin interface.
   - The overall structure implies the dashboard UI is composed as a layout shell plus routed content pages.

5. **Shared UI component library**
   - `components/ui/` contains reusable primitives such as `button`, `card`, `input`, `table`, `sidebar`, `sheet`, `dropdown-menu`, `tooltip`, `separator`, and `skeleton`.
   - This is a classic **design-system layer**: low-level, reusable UI building blocks used by page-level components.
   - The presence of `components.json` strongly suggests these are generated or standardized UI primitives, likely in the style of shadcn/ui.

6. **Client-side helpers**
   - `hooks/use-mobile.ts` provides responsive behavior detection for the dashboard.
   - `lib/utils.ts` is the shared utility layer, likely for class-name composition or small UI helpers.
   - These support the presentation layer rather than business logic.

7. **Admin dashboard build/tooling boundaries**
   - The admin app is configured with `next.config.ts`, `tsconfig.json`, `eslint.config.mjs`, and `postcss.config.mjs`.
   - That means the architecture is mostly **frontend-only application code** with framework/tooling configuration, not a separately exposed backend in this repo.
   - `package.json` and `package-lock.json` define the app dependencies and scripts.

8. **Admin dashboard data flow**
   - Based on the visible files, data flow appears **UI-first and local**: routes render pages, pages compose shared components, and components rely on utility/helpers.
   - No API client, server actions, database layer, or external service integration is visible in the tree.
   - For a diagram, this means the dashboard should be shown as a **self-contained front-end app** unless there are hidden services outside the repo.

9. **`webSirvent`: separate lightweight web app**
   - `webSirvent/` is a distinct front-end application with `index.html`, `index.css`, and `app.js`.
   - This is a much simpler architecture than the admin dashboard: a traditional static page plus browser-side JavaScript.
   - It is not organized like the Next.js app and should be drawn as a separate subsystem.

10. **`webSirvent` assets and content**
   - `webSirvent/img/` contains image assets, including a `Productos` directory.
   - `webSirvent/saboresTarrinas.txt` is a local text asset, likely content/data consumed by the page script.
   - This suggests the site’s data is mostly **bundled static content**, not fetched from a server.

11. **Likely separation between the two apps**
   - There is no visible shared code between `adminSystem` and `webSirvent`.
   - They appear to be **parallel, independently built front ends** in the same repo rather than a tightly coupled full-stack system.
   - An accurate diagram should show them as separate boxes unless external integration is known elsewhere.

12. **What is not present in the visible architecture**
   - No database, queue, auth service, CMS integration, or backend API is evident from the tree.
   - No shared domain model or server-side business layer is visible.
   - The repo is therefore best described as a **UI-centric multi-app repository** with one modern dashboard app and one static/vanilla web app.

Main entry points: [`adminSystem/apps/admin-dashboard`](https://github.com/raulmendezz/proyectosirvent/tree/main/adminSystem/apps/admin-dashboard) (Admin dashboard), [`adminSystem/apps/admin-dashboard/app`](https://github.com/raulmendezz/proyectosirvent/tree/main/adminSystem/apps/admin-dashboard/app) (App router), [`webSirvent/index.html`](https://github.com/raulmendezz/proyectosirvent/blob/main/webSirvent/index.html) (Web site), [`adminSystem/apps/admin-dashboard/app/page.tsx`](https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/app/page.tsx) (Home page)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_admin["adminSystem"]
  node_admin_app["Admin dashboard<br/>next app"]
  node_admin_app_router["App router<br/>routes"]
  node_admin_root_page["Home page<br/>route page<br/>[page.tsx]"]
  node_admin_dashboard_page["Dashboard page<br/>route page<br/>[page.tsx]"]
  node_admin_layout["Root layout<br/>[layout.tsx]"]
  node_admin_alt_routes["Route sources<br/>overlap routes"]
  node_admin_dashboard_layout["Dashboard shell<br/>layout component"]
  node_admin_ui_kit["UI kit<br/>ui primitives"]
  node_admin_hooks["Hooks<br/>client helpers<br/>[use-mobile.ts]"]
  node_admin_utils["Utils<br/>shared helpers<br/>[utils.ts]"]
  node_admin_styles["Global styles<br/>stylesheet<br/>[globals.css]"]
  node_admin_config["Tooling<br/>framework config<br/>[next.config.ts]"]
end

subgraph group_site["webSirvent"]
  node_site_app["Web site<br/>static site<br/>[index.html]"]
  node_site_script["Browser script<br/>client script<br/>[app.js]"]
  node_site_styles["Site styles<br/>stylesheet<br/>[index.css]"]
  node_site_assets["Assets"]
end

node_root["Workspace"]

node_root -->|"contains"| node_admin_app
node_root -->|"contains"| node_site_app
node_admin_app -->|"routes"| node_admin_app_router
node_admin_app_router -->|"page"| node_admin_root_page
node_admin_app_router -->|"page"| node_admin_dashboard_page
node_admin_app -->|"shell"| node_admin_layout
node_admin_root_page -->|"compose"| node_admin_dashboard_layout
node_admin_dashboard_page -->|"compose"| node_admin_dashboard_layout
node_admin_app -.->|"parallel source"| node_admin_alt_routes
node_admin_app -->|"uses"| node_admin_ui_kit
node_admin_app -->|"uses"| node_admin_hooks
node_admin_app -->|"uses"| node_admin_utils
node_admin_app -->|"styles"| node_admin_styles
node_admin_app -.->|"tooling"| node_admin_config
node_site_app -->|"loads"| node_site_script
node_site_app -->|"styles"| node_site_styles
node_site_script -->|"reads"| node_site_assets

click node_admin_app "https://github.com/raulmendezz/proyectosirvent/tree/main/adminSystem/apps/admin-dashboard"
click node_admin_app_router "https://github.com/raulmendezz/proyectosirvent/tree/main/adminSystem/apps/admin-dashboard/app"
click node_admin_root_page "https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/app/page.tsx"
click node_admin_dashboard_page "https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/app/dashboard/page.tsx"
click node_admin_layout "https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/app/layout.tsx"
click node_admin_alt_routes "https://github.com/raulmendezz/proyectosirvent/tree/main/adminSystem/apps/admin-dashboard/src/app"
click node_admin_dashboard_layout "https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/src/DashboardLayout.tsx"
click node_admin_ui_kit "https://github.com/raulmendezz/proyectosirvent/tree/main/adminSystem/apps/admin-dashboard/components/ui"
click node_admin_hooks "https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/hooks/use-mobile.ts"
click node_admin_utils "https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/lib/utils.ts"
click node_admin_styles "https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/app/globals.css"
click node_admin_config "https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/next.config.ts"
click node_site_app "https://github.com/raulmendezz/proyectosirvent/blob/main/webSirvent/index.html"
click node_site_script "https://github.com/raulmendezz/proyectosirvent/blob/main/webSirvent/app.js"
click node_site_styles "https://github.com/raulmendezz/proyectosirvent/blob/main/webSirvent/index.css"
click node_site_assets "https://github.com/raulmendezz/proyectosirvent/tree/main/webSirvent/img"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_admin_app,node_admin_app_router,node_admin_root_page,node_admin_dashboard_page,node_admin_layout,node_admin_alt_routes,node_admin_dashboard_layout,node_admin_ui_kit,node_admin_hooks,node_admin_utils,node_admin_styles,node_admin_config toneBlue
class node_site_app,node_site_script,node_site_styles,node_site_assets toneAmber
class node_root toneNeutral
```

## Components

### adminSystem

Workspace area for the Next.js admin dashboard

- [Admin dashboard](https://github.com/raulmendezz/proyectosirvent/tree/main/adminSystem/apps/admin-dashboard): next app · Main Next.js application in the repo · `adminSystem/apps/admin-dashboard`
- [App router](https://github.com/raulmendezz/proyectosirvent/tree/main/adminSystem/apps/admin-dashboard/app): routes · Primary route tree for the dashboard · `adminSystem/apps/admin-dashboard/app`
- [Home page](https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/app/page.tsx): route page · Dashboard landing route · `adminSystem/apps/admin-dashboard/app/page.tsx`
- [Dashboard page](https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/app/dashboard/page.tsx): route page · Main dashboard route · `adminSystem/apps/admin-dashboard/app/dashboard/page.tsx`
- [Root layout](https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/app/layout.tsx): layout · Next.js application shell · `adminSystem/apps/admin-dashboard/app/layout.tsx`
- [Route sources](https://github.com/raulmendezz/proyectosirvent/tree/main/adminSystem/apps/admin-dashboard/src/app): overlap routes · Parallel route definitions under src/app, likely a migration or duplication · `adminSystem/apps/admin-dashboard/src/app`
- [Dashboard shell](https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/src/DashboardLayout.tsx): layout component · Reusable dashboard layout component · `adminSystem/apps/admin-dashboard/src/DashboardLayout.tsx`
- [UI kit](https://github.com/raulmendezz/proyectosirvent/tree/main/adminSystem/apps/admin-dashboard/components/ui): ui primitives · Reusable design-system components · `adminSystem/apps/admin-dashboard/components/ui`
- [Hooks](https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/hooks/use-mobile.ts): client helpers · Client-side responsive and interaction helpers · `adminSystem/apps/admin-dashboard/hooks/use-mobile.ts`
- [Utils](https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/lib/utils.ts): shared helpers · Common utility functions for the dashboard · `adminSystem/apps/admin-dashboard/lib/utils.ts`
- [Global styles](https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/app/globals.css): stylesheet · Application-wide CSS baseline · `adminSystem/apps/admin-dashboard/app/globals.css`
- [Tooling](https://github.com/raulmendezz/proyectosirvent/blob/main/adminSystem/apps/admin-dashboard/next.config.ts): framework config · Next.js, TypeScript, PostCSS, and lint configuration boundary · `adminSystem/apps/admin-dashboard/next.config.ts`

### webSirvent

Separate static front-end site

- [Web site](https://github.com/raulmendezz/proyectosirvent/blob/main/webSirvent/index.html): static site · Separate lightweight front-end bundle · `webSirvent/index.html`
- [Browser script](https://github.com/raulmendezz/proyectosirvent/blob/main/webSirvent/app.js): client script · Vanilla JavaScript behavior for the site · `webSirvent/app.js`
- [Site styles](https://github.com/raulmendezz/proyectosirvent/blob/main/webSirvent/index.css): stylesheet · CSS for the static site · `webSirvent/index.css`
- [Assets](https://github.com/raulmendezz/proyectosirvent/tree/main/webSirvent/img): static assets · Local images and text content used by the site · `webSirvent/img`

### Other components

- **Workspace**: repo workspace · Top-level repository containing two independent front ends

## Connections

- Workspace → Admin dashboard: contains · Repository includes the admin dashboard workspace
- Workspace → Web site: contains · Repository also includes a separate static site
- Admin dashboard → App router: routes · Next.js app router drives the dashboard UI
- App router → Home page: page · Landing route
- App router → Dashboard page: page · Dashboard route
- Admin dashboard → Root layout: shell · Application shell around routed pages
- Home page → Dashboard shell: compose · Pages can be assembled with the dashboard shell
- Dashboard page → Dashboard shell: compose · Dashboard content is wrapped by the reusable shell
- Admin dashboard → Route sources: parallel source · Overlapping route tree under src/app
- Admin dashboard → UI kit: uses · Pages and layouts rely on shared UI primitives
- Admin dashboard → Hooks: uses · Client-side dashboard behavior support
- Admin dashboard → Utils: uses · Shared utility layer
- Admin dashboard → Global styles: styles · Global styling baseline
- Admin dashboard → Tooling: tooling · Framework and build configuration for the app
- Web site → Browser script: loads · HTML bootstraps the browser script
- Web site → Site styles: styles · HTML uses the site stylesheet
- Browser script → Assets: reads · Script consumes local image and text assets
