# landoncrabtree/notes architecture

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

- Interactive diagram: https://gitdiagram.com/landoncrabtree/notes
- Repository: https://github.com/landoncrabtree/notes

## Overview

##### Main System Components

a) Content Layer
- Content Processing Pipeline
- File System Interface
- Markdown Processing

b) Core Engine Layer
- Plugin System
- Processors
- Transformers
- Emitters

c) Presentation Layer
- Components
- Styles
- Client-side Scripts

##### Key Relationships to Highlight

**Content Sources → Processing Pipeline → Generated Site**
- ↑                    ↓                  ↓
**File System         Plugin System        Static Assets**
- ↓
- Transformers → Emitters

##### Detailed Component Breakdown

a) Content Processing:
- Flow from raw content through processors (parse.ts, filter.ts, emit.ts)
- Transformers (markdown, latex, syntax highlighting)
- To the plugin system

b) Plugin Architecture:
- Divide into three types: transformers, filters, and emitters
- How plugins interact with the core system
- Extensibility points

c) Frontend Components:
- Component hierarchy
- Client-side features (search, graph view, dark mode)
- Demonstrate how styles and scripts are bundled

##### Technical Implementation Details

- Blue: Core processing components
- Green: Plugin system
- Orange: Frontend components
- Purple: Build/Deploy pipeline

##### Specific Implementation Notes

Technical details for:
- TypeScript/React component system
- Markdown processing pipeline
- Static asset handling
- Build optimization

Key Elements to Include:
- Content processing pipeline
- Plugin system architecture
- Component rendering system
- Build and deployment flow
- Client-side feature integration

Remember to:
- Use consistent styling for similar components
- Both build-time and runtime processes
- Extension points for plugins

This will provide a comprehensive view of how Quartz transforms markdown content into a fully-featured digital garden website while maintaining extensibility through its plugin system.

## Diagram (Mermaid)

```mermaid
graph TB
    subgraph Content
        FS["File System Interface"]:::fs
        MD["Markdown Files"]
        CP["Content Processing"]:::cp
    end

    subgraph "Core Engine"
        PS["Plugin System"]:::plugins
        
        subgraph "Processors"
            Parse["Parse Processor"]:::processor
            Filter["Filter Processor"]:::processor
            Emit["Emit Processor"]:::processor
        end
        
        subgraph "Plugin Types"
            Trans["Transformers"]:::plugin
            Filters["Filters"]:::plugin
            Emitters["Emitters"]:::plugin
        end
    end

    subgraph "Frontend"
        Components["Components"]:::frontend
        Styles["Styles"]:::styles
        Scripts["Client Scripts"]:::scripts
        
        subgraph "Features"
            Graph["Graph View"]:::feature
            Search["Search"]:::feature
            Dark["Dark Mode"]:::feature
        end
    end

    subgraph "Build System"
        Build["Build Process"]:::build
        Config["Configuration"]:::build
        Worker["Worker Process"]:::build
    end

    subgraph "Utilities"
        I18N["i18n System"]:::util
        Resources["Resource Management"]:::util
        PathHandler["Path Handling"]:::util
    end

    MD --> FS
    FS --> CP
    CP --> Parse
    Parse --> Filter
    Filter --> Emit
    PS --> Trans & Filters & Emitters
    Trans & Filters & Emitters --> Build
    Components --> Build
    Styles --> Build
    Scripts --> Build
    Build --> Worker
    Config --> Build
    I18N --> Components
    Resources --> Components
    PathHandler --> CP

    %% Click Events
    click FS "https://github.com/landoncrabtree/notes/blob/v4/quartz/util/glob.ts"
    click CP "https://github.com/landoncrabtree/notes/tree/v4/quartz/processors/"
    click PS "https://github.com/landoncrabtree/notes/tree/v4/quartz/plugins/"
    click Parse "https://github.com/landoncrabtree/notes/blob/v4/quartz/processors/parse.ts"
    click Filter "https://github.com/landoncrabtree/notes/blob/v4/quartz/processors/filter.ts"
    click Emit "https://github.com/landoncrabtree/notes/blob/v4/quartz/processors/emit.ts"
    click Trans "https://github.com/landoncrabtree/notes/tree/v4/quartz/plugins/transformers/"
    click Filters "https://github.com/landoncrabtree/notes/tree/v4/quartz/plugins/filters/"
    click Emitters "https://github.com/landoncrabtree/notes/tree/v4/quartz/plugins/emitters/"
    click Components "https://github.com/landoncrabtree/notes/tree/v4/quartz/components/"
    click Styles "https://github.com/landoncrabtree/notes/blob/v4/quartz/styles/base.scss"
    click Scripts "https://github.com/landoncrabtree/notes/tree/v4/quartz/components/scripts/"
    click Graph "https://github.com/landoncrabtree/notes/blob/v4/quartz/components/Graph.tsx"
    click Search "https://github.com/landoncrabtree/notes/blob/v4/quartz/components/Search.tsx"
    click Dark "https://github.com/landoncrabtree/notes/blob/v4/quartz/components/Darkmode.tsx"
    click Build "https://github.com/landoncrabtree/notes/blob/v4/quartz/build.ts"
    click Config "https://github.com/landoncrabtree/notes/blob/v4/quartz/cfg.ts"
    click Worker "https://github.com/landoncrabtree/notes/blob/v4/quartz/worker.ts"
    click I18N "https://github.com/landoncrabtree/notes/tree/v4/quartz/i18n/"
    click Resources "https://github.com/landoncrabtree/notes/blob/v4/quartz/util/resources.tsx"
    click PathHandler "https://github.com/landoncrabtree/notes/blob/v4/quartz/util/path.ts"

    %% Styling
    classDef fs fill:#f96,stroke:#333
    classDef cp fill:#69f,stroke:#333
    classDef plugins fill:#9c6,stroke:#333
    classDef processor fill:#69f,stroke:#333
    classDef plugin fill:#9c6,stroke:#333
    classDef frontend fill:#f69,stroke:#333
    classDef styles fill:#c9f,stroke:#333
    classDef scripts fill:#fc9,stroke:#333
    classDef feature fill:#f69,stroke:#333
    classDef build fill:#99f,stroke:#333
    classDef util fill:#c96,stroke:#333
```
