# tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44 architecture

> Architecture diagram of the GitHub repository tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-04-03). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44
- Repository: https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44

## Overview

##### Main Components
- Frontend Application: Since the entire project is built using ReactJS, the core of the system is the client-side application.
- Public Assets: The “public” folder holds the index.html, manifest, and other universal assets that are served to the browser.
- Components: Inside the “src/components” folder, there are logically separated UI elements:
- Header components ("headers/Navbar.jsx" and "headers/Slideshow.jsx") for site navigation and visual introduction.
- Content components ("contents/Achievement.jsx", "Album.jsx", "Folk.jsx", "Overview.jsx", "PoemStory.jsx") which represent different thematic sections.
- Footer components ("footers/Footer.jsx", "footers/ButtonScrollTop.jsx") for additional user interaction (like scroll-to-top functionality).
- Data Layer: The “src/data” directory contains JavaScript files such as "achievement.js", "album.js", etc., that feed static content to the UI components.
- Hooks: The “src/hook” folder (e.g., "useDarkLightMode.jsx") that provides custom logic, likely for toggling themes.
- Styling: Tailwind CSS configuration (via tailwind.config.js and postcss.config.js) ensures consistent styling across components.

##### Out Relationships and Interactions
- App.jsx serves as the main container; it imports and composes the header, content, and footer components.
- The header (Navbar, Slideshow) and footer (Footer, ButtonScrollTop) components provide consistent elements that span across multiple pages/sections.
- The custom hook (useDarkLightMode) communicates with the overall App to manage theme switching, affecting styling components configured through Tailwind.
- The “public/index.html” is the entry point that loads the bundled React application.

##### Architectural Patterns and Design Principles
- Separation of Concerns: The project clearly separates presentation (components), data (JSON/JS files in src/data), and styling (Tailwind).
- Component-Based Architecture: The UI is modularized into re-usable components (headers, content sections, footers) which interact through props and shared state.
- Declarative UI: Using React’s declarative approach where each component renders its part of the UI based on the incoming data.
- The project configuration files (package.json, tailwind.config.js, postcss.config.js) indicate reliance on modern build tools and package management, ensuring scalability and maintainability.

##### Elements
- A component for “Custom Hook” that modifies theme state.

## Diagram (Mermaid)

```mermaid
flowchart TD
    %% Public Assets
    Pub("Public Assets"):::asset

    %% UI Layer
    subgraph "User Interface Layer"
        App("App Shell (App.jsx)"):::ui
        subgraph "Header Components"
            Navbar("Navbar"):::ui
            Slideshow("Slideshow"):::ui
        end
        subgraph "Content Components"
            Achieve("Achievement"):::ui
            Album("Album"):::ui
            Folk("Folk"):::ui
            Overview("Overview"):::ui
            PoemStory("PoemStory"):::ui
        end
        subgraph "Footer Components"
            Footer("Footer"):::ui
            ScrollTop("ButtonScrollTop"):::ui
        end
        Hook("Custom Hook (useDarkLightMode)"):::hook
    end

    %% Data Layer
    subgraph "Data Layer"
        DataAch("Achievement Data"):::data
        DataAlb("Album Data"):::data
        DataFolk("Folk Data"):::data
        DataNav("Navigation Data"):::data
        DataOver("Overview Data"):::data
        DataPoem("PoemStory Data"):::data
        DataSlide("Slide Data"):::data
    end

    %% Styling & Configuration Layer
    subgraph "Styling & Config"
         Tailwind("Tailwind CSS Config"):::config
         PostCSS("PostCSS Config"):::config
    end

    %% Relationships
    Pub -->|"loads"| App

    App -->|"renders"| Navbar
    App -->|"renders"| Slideshow
    App -->|"renders"| Achieve
    App -->|"renders"| Album
    App -->|"renders"| Folk
    App -->|"renders"| Overview
    App -->|"renders"| PoemStory
    App -->|"renders"| Footer
    App -->|"renders"| ScrollTop

    DataAch -->|"importsData"| Achieve
    DataAlb -->|"importsData"| Album
    DataFolk -->|"importsData"| Folk
    DataOver -->|"importsData"| Overview
    DataPoem -->|"importsData"| PoemStory
    DataSlide -->|"importsData"| Slideshow
    DataNav -->|"providesNav"| Navbar

    Hook -->|"managesTheme"| App

    App -->|"appliesStyle"| Tailwind
    App -->|"appliesStyle"| PostCSS

    %% Styles
    classDef ui fill:#ADD8E6,stroke:#000,stroke-width:1px;
    classDef data fill:#90EE90,stroke:#000,stroke-width:1px;
    classDef config fill:#D3D3D3,stroke:#000,stroke-width:1px;
    classDef hook fill:#FFD700,stroke:#000,stroke-width:1px;
    classDef asset fill:#FFA07A,stroke:#000,stroke-width:1px;

    %% Click Events
    click App "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/App.jsx"
    click Pub "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/tree/main/public/"
    click Navbar "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/components/headers/Navbar.jsx"
    click Slideshow "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/components/headers/Slideshow.jsx"
    click Achieve "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/components/contents/Achievement.jsx"
    click Album "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/components/contents/Album.jsx"
    click Folk "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/components/contents/Folk.jsx"
    click Overview "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/components/contents/Overview.jsx"
    click PoemStory "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/components/contents/PoemStory.jsx"
    click Footer "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/components/footers/Footer.jsx"
    click ScrollTop "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/components/footers/ButtonScrollTop.jsx"
    click DataAch "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/data/achievement.js"
    click DataAlb "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/data/album.js"
    click DataFolk "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/data/folk.js"
    click DataNav "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/data/nav.js"
    click DataOver "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/data/overview.js"
    click DataPoem "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/data/poemStory.js"
    click DataSlide "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/data/slide.js"
    click Hook "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/src/hook/useDarkLightMode.jsx"
    click Tailwind "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/tailwind.config.js"
    click PostCSS "https://github.com/tuneofcode/web-bao-tuong-nhom-ky-thuat-phan-mem-k44/blob/main/postcss.config.js"
```
