# luis-cvqz/inmobify-frontend architecture

> Architecture diagram of the GitHub repository luis-cvqz/inmobify-frontend, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-03-30). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/luis-cvqz/inmobify-frontend
- Repository: https://github.com/luis-cvqz/inmobify-frontend

## Overview

##### Main Components
- Frontend Application: This is the Angular application consisting of multiple components and modules.
- UI Components: Break out key elements such as the AppComponent, HomeComponent, LoginComponent, and PropertyCardComponent. Each of these components is responsible for its own section of the UI.
- Services: Highlight the PropertiesService that likely handles data interactions (e.g., calls to APIs or mock data handling) and any other service components.
- Models: Include the models directory (e.g., property-summary.ts) to indicate the data structures used.

##### Relationships & Interactions
- Routing: Introduce the Angular routing mechanism (referenced by app.routes.ts) which connects different components based on paths (login, home).

##### Architectural Patterns and Design Principles
- Component-Based Architecture: Emphasize that Angular uses a modular, component-based design.
- Separation of Concerns: Clearly separate UI (components), data logic (services), and data structures (models).
- Routing/Navigation: The routing module within the app handles navigation between the main features (login, home, property summary details).

##### Relevant Technologies & Frameworks
- Angular Framework: Mark it as the core framework that handles templating, data binding, dependency injection, and routing.
- Angular CLI: Note its role in code scaffolding and project configuration.
- Unit Testing Tools: Mention the Karma test runner and associated test files (e.g., *.spec.ts files) that ensure component and service reliability.
- Build Tools: Indicate that Angular’s build system (using commands like “ng build”) compiles the project and optimizes the artifacts.

## Diagram (Mermaid)

```mermaid
flowchart TD
    %% Framework & Tools
    subgraph "Framework & Tools"
        AF["Angular Framework"]:::tool
        CLI["Angular CLI"]:::tool
        UT["Karma & Unit Testing"]:::tool
    end

    %% UI Layer
    subgraph "UI Layer"
        APP["AppComponent"]:::component
        RTR["Routing Module"]:::routing
        HC["HomeComponent"]:::component
        LC["LoginComponent"]:::component
        PCC["PropertyCardComponent"]:::component
    end

    %% Services & Models
    subgraph "Services & Models"
        PS["PropertiesService"]:::service
        PM["PropertySummary (Model)"]:::model
    end

    %% Relationships between Framework and UI Layer
    AF --> CLI
    CLI --> UT

    %% UI Component Hierarchy and Routing
    APP -->|"routes"| RTR
    RTR -->|"navigates"| HC
    RTR -->|"navigates"| LC
    APP -->|"hosts"| PCC

    %% Service Injection and Data Flow
    HC -->|"injects"| PS
    PCC -->|"injects"| PS
    PS -->|"handles"| PM

    %% Click Events for Components
    click APP "https://github.com/luis-cvqz/inmobify-frontend/blob/master/src/app/app.component.ts"
    click HC "https://github.com/luis-cvqz/inmobify-frontend/blob/master/src/app/home/home.component.ts"
    click LC "https://github.com/luis-cvqz/inmobify-frontend/blob/master/src/app/login/login.component.ts"
    click PCC "https://github.com/luis-cvqz/inmobify-frontend/blob/master/src/app/property-card/property-card.component.ts"
    click PS "https://github.com/luis-cvqz/inmobify-frontend/blob/master/src/app/services/properties.service.ts"
    click PM "https://github.com/luis-cvqz/inmobify-frontend/blob/master/src/app/models/property-summary.ts"
    click RTR "https://github.com/luis-cvqz/inmobify-frontend/blob/master/src/app/app.routes.ts"

    %% Styles
    classDef component fill:#ADD8E6,stroke:#000,stroke-width:1px;
    classDef service fill:#98FB98,stroke:#000,stroke-width:1px;
    classDef model fill:#FFD700,stroke:#000,stroke-width:1px;
    classDef routing fill:#FFB6C1,stroke:#000,stroke-width:1px;
    classDef tool fill:#DDA0DD,stroke:#000,stroke-width:1px;
```
