diff --git a/specs/.DS_Store b/specs/.DS_Store new file mode 100644 index 0000000..e6fbeff Binary files /dev/null and b/specs/.DS_Store differ diff --git a/specs/001-users-pukpuk-dev/tasks.md b/specs/001-users-pukpuk-dev/tasks.md new file mode 100644 index 0000000..3bbd9b9 --- /dev/null +++ b/specs/001-users-pukpuk-dev/tasks.md @@ -0,0 +1,83 @@ +# Tasks for Website Migration + +**Feature**: Website Migration to Astro with Payload CMS +**Branch**: `001-users-pukpuk-dev` + +This document outlines the tasks required to complete the feature. + +--- + +## Phase 1: Project Setup + +- **T001**: Initialize a new Astro project in the `frontend` directory. +- **T002**: Initialize a new Payload CMS project in the `backend` directory. +- **T003**: Install all necessary dependencies for both projects, including `better-auth`, `vitest`, and `playwright`. +- **T004**: Configure linting and formatting for both projects. + +## Phase 2: Backend Development (Payload CMS) + +- **T005**: **[P]** Create the `Users` collection in Payload CMS, as defined in `data-model.md`. +- **T006**: **[P]** Create the `Blog Posts` collection in Payload CMS, as defined in `data-model.md`. +- **T007**: **[P]** Create the `Portfolio Items` collection in Payload CMS, as defined in `data-model.md`. +- **T008**: **[P]** Create the `Categories` collection in Payload CMS, as defined in `data-model.md`. +- **T009**: Configure role-based access control for `admin` and `editor` roles. +- **T010**: Implement the authentication logic using `better-auth`. + +## Phase 3: Frontend Development (Astro) + +- **T011**: **[P]** Create the main layout for the website, including the header and footer. +- **T012**: **[P]** Create the blog listing page, fetching data from the Payload CMS. +- **T013**: **[P]** Create the individual blog post page. +- **T014**: **[P]** Create the portfolio listing page. +- **T015**: **[P]** Create the individual portfolio item page. +- **T016**: **[P]** Create the contact page with a functional contact form. +- **T017**: Implement the login page. +- **T018**: Implement protected routes for the `/admin` section. + +## Phase 4: Testing + +- **T019**: **[P]** Write contract tests for the `/admin/login` endpoint. +- **T020**: **[P]** Write contract tests for the `/contact` endpoint. +- **T021**: **[P]** Write integration tests for the user login flow. +- **T022**: **[P]** Write integration tests for the contact form submission. +- **T023**: **[P]** Write unit tests for the main Astro components. + +## Phase 5: Content Migration and Deployment + +- **T024**: Write scripts to migrate content from the old site to the new Payload CMS. +- **T025**: Implement 301 redirects for all old URLs. +- **T026**: Configure the deployment pipeline to Cloudflare Pages. +- **T027**: Perform a final performance and accessibility audit using Google Lighthouse. + +--- + +## Parallel Execution Examples + +The following tasks can be run in parallel: + +```bash +# Backend collections +gemini execute --task T005 & +gemini execute --task T006 & +gemini execute --task T007 & +gemini execute --task T008 & +``` + +```bash +# Frontend pages +gemini execute --task T011 & +gemini execute --task T012 & +gemini execute --task T013 & +gemini execute --task T014 & +gemini execute --task T015 & +gemini execute --task T016 & +``` + +```bash +# Tests +gemini execute --task T019 & +gemini execute --task T020 & +gemini execute --task T021 & +gemini execute --task T022 & +gemini execute --task T023 & +```