# tyuchx/portal architecture

> Architecture diagram of the GitHub repository tyuchx/portal, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-01-07). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/tyuchx/portal
- Repository: https://github.com/tyuchx/portal

## Overview

##### System Overview
The project appears to be a web-based portal for managing and displaying various tech conferences and events (COSCUP, HITCON, PyCon, SITCON, etc.). Let's break down the components:

##### Main Components

a) Static Web Frontend
- HTML (index.html)
- CSS (main.css)
- JavaScript (main.js)

b) Event Data Store
- JSON files organization
- Connection to schema validation

c) Build System
- Build.sh component
- Workflow connection to GitHub Actions

##### Data Flow and Relationships

**[GitHub Actions] --> [Build System]**
**[Event Schema] --> [Event Data Store]**
**[Event Data Store] --> [Static Web Frontend]**

##### Component Details

- Rectangle: Core components (Frontend, Data Store)
- Hexagon: Schema validation (event_schema.jsonc)
- Diamond: Build/Deploy processes

##### Important Elements to Highlight

a) Event Data Management:
- How event_schema.jsonc validates against individual event JSON files
- Events by conference type (COSCUP, HITCON, PyCon, etc.)

b) Build/Deploy Flow:
- GitHub Actions workflow
- Release.yml deployment process

##### Specific Implementation Details

- Static Asset Serving
- Event Data Processing
- Schema Validation
- CI/CD Pipeline

## Diagram (Mermaid)

```mermaid
graph TB
    subgraph Frontend
        WebFront["Static Web Frontend"]
        HTML["HTML"]:::frontend
        CSS["CSS"]:::frontend
        JS["JavaScript"]:::frontend
        WebFront --> HTML
        WebFront --> CSS
        WebFront --> JS
    end

    subgraph DataStore["Event Data Store"]
        EventData[("Event Data")]:::data
        COSCUP["COSCUP Events"]:::events
        HITCON["HITCON Events"]:::events
        PyCon["PyCon Events"]:::events
        SITCON["SITCON Events"]:::events
        Others["Other Events"]:::events
        
        EventData --> COSCUP
        EventData --> HITCON
        EventData --> PyCon
        EventData --> SITCON
        EventData --> Others
    end

    subgraph BuildDeploy["Build & Deploy"]
        BuildSystem["Build System"]:::build
        GHActions["GitHub Actions"]:::cicd
        SchemaVal{{"Schema Validation"}}:::schema
        
        GHActions --> BuildSystem
        SchemaVal --> BuildSystem
    end

    EventData --> WebFront
    SchemaVal --> EventData

    classDef frontend fill:#3498db,stroke:#2980b9,color:#fff
    classDef data fill:#2ecc71,stroke:#27ae60,color:#fff
    classDef events fill:#27ae60,stroke:#219a52,color:#fff
    classDef build fill:#e67e22,stroke:#d35400,color:#fff
    classDef cicd fill:#e74c3c,stroke:#c0392b,color:#fff
    classDef schema fill:#9b59b6,stroke:#8e44ad,color:#fff

    click HTML "https://github.com/tyuchx/Portal/blob/master/web/index.html"
    click CSS "https://github.com/tyuchx/Portal/blob/master/web/main.css"
    click JS "https://github.com/tyuchx/Portal/blob/master/web/main.js"
    click EventData "https://github.com/tyuchx/Portal/tree/master/events/"
    click COSCUP "https://github.com/tyuchx/Portal/blob/master/events/COSCUP_*.json"
    click HITCON "https://github.com/tyuchx/Portal/blob/master/events/HITCON_*.json"
    click PyCon "https://github.com/tyuchx/Portal/blob/master/events/PyCon_*.json"
    click SITCON "https://github.com/tyuchx/Portal/blob/master/events/SITCON_*.json"
    click BuildSystem "https://github.com/tyuchx/Portal/blob/master/build.sh"
    click GHActions "https://github.com/tyuchx/Portal/blob/master/.github/workflows/release.yml"
    click SchemaVal "https://github.com/tyuchx/Portal/blob/master/event_schema.jsonc"

    subgraph Legend
        Frontend_L["Frontend Component"]:::frontend
        Data_L["Data Store"]:::data
        Events_L["Event Category"]:::events
        Build_L["Build Component"]:::build
        CICD_L["CI/CD Component"]:::cicd
        Schema_L["Schema Component"]:::schema
    end
```
