Calendar System Migration Summary

Migration Date

July 16, 2026

Overview

Migrated the calendar system from scattered files in assets/js/pages/calendar/ and _sass/open-coding/calendar.scss into the unified _projects/systems/calendar/ workflow.

Before (Old Structure)

Source Files

assets/js/pages/calendar/
├── CalendarApi.js
├── CalendarData.js
├── CalendarTests.js
├── CalendarUI.js
├── EventBuilder.js
└── calendar.js

_sass/open-coding/
└── calendar.scss

Issues with Old Structure

After (New Structure)

Source Files (Tracked in Git)

_projects/systems/calendar/
├── README.md                   # Comprehensive documentation
├── Makefile                    # Automated build system
├── js/                         # All JavaScript in one place
│   ├── CalendarApi.js
│   ├── CalendarData.js
│   ├── CalendarTests.js
│   ├── CalendarUI.js
│   ├── EventBuilder.js
│   └── calendar.js
├── sass/                       # All styles in one place
│   └── main.scss
└── docs/                       # Project-specific docs
    └── MIGRATION.md           # This file

Generated Files (Ignored by Git)

assets/js/projects/calendar/    # Generated JavaScript
├── CalendarApi.js
├── CalendarData.js
├── CalendarTests.js
├── CalendarUI.js
├── EventBuilder.js
└── calendar.js

_sass/projects/calendar/        # Generated SASS
└── main.scss

assets/css/projects/calendar/   # Generated CSS entry
└── main.scss                   # (with Jekyll frontmatter)

Migration Steps Performed

  1. ✅ Created project structure at _projects/systems/calendar/
  2. ✅ Copied all JavaScript files to _projects/systems/calendar/js/
  3. ✅ Copied calendar.scss to _projects/systems/calendar/sass/main.scss
  4. ✅ Created Makefile with build, assets, clean, watch targets
  5. ✅ Registered systems/calendar:dev in _projects/.makeprojects
  6. ✅ Updated _includes/calendar.html script paths from pages/calendar to projects/calendar
  7. ✅ Updated _sass/open-coding/_main.scss import from calendar to projects/calendar/main
  8. ✅ Created comprehensive README.md documentation
  9. ✅ Tested build system successfully

Benefits of New Structure

1. Single Source of Truth

All calendar code (JS, SASS, docs) lives in one directory: _projects/systems/calendar/

2. Automated Build System

# Build the calendar
make build

# Watch for changes (auto-rebuild)
make watch

# Clean generated files
make clean

3. Better Documentation

4. Development Workflow

5. Consistent Patterns

File Path Changes

JavaScript Loads (in _includes/calendar.html)

Before:

<script src="/assets/js/pages/calendar/CalendarData.js"></script>
<script src="/assets/js/pages/calendar/EventBuilder.js"></script>
<script src="/assets/js/pages/calendar/CalendarApi.js"></script>
<script src="/assets/js/pages/calendar/CalendarUI.js"></script>
<script src="/assets/js/pages/calendar/calendar.js"></script>

After:

<script src="/assets/js/projects/calendar/CalendarData.js"></script>
<script src="/assets/js/projects/calendar/EventBuilder.js"></script>
<script src="/assets/js/projects/calendar/CalendarApi.js"></script>
<script src="/assets/js/projects/calendar/CalendarUI.js"></script>
<script src="/assets/js/projects/calendar/calendar.js"></script>

SASS Import (in _sass/open-coding/_main.scss)

Before:

@import "calendar";

After:

@import "projects/calendar/main";

Old Files Status

All old files have been removed:

The migration is complete and verified.

Testing Checklist

Migration complete and verified

Architecture Understanding

Interface Layer vs. Calendar Project

_includes/calendar.html is NOT part of this project:

This project provides:

The include is a consumer of the calendar system, not part of it.

References