From d41e5daa7173269eed849a4675e1692b598f1afe Mon Sep 17 00:00:00 2001 From: Thomas Date: Thu, 25 Jun 2026 11:49:23 +0200 Subject: [PATCH] Delete .cursor/goal directory --- .../archive/scratchpad-20260616T164024.md | 53 ------------------- .cursor/goal/criteria.txt | 6 --- .cursor/goal/scratchpad.md | 46 ---------------- 3 files changed, 105 deletions(-) delete mode 100644 .cursor/goal/archive/scratchpad-20260616T164024.md delete mode 100644 .cursor/goal/criteria.txt delete mode 100644 .cursor/goal/scratchpad.md diff --git a/.cursor/goal/archive/scratchpad-20260616T164024.md b/.cursor/goal/archive/scratchpad-20260616T164024.md deleted file mode 100644 index aac7b2957..000000000 --- a/.cursor/goal/archive/scratchpad-20260616T164024.md +++ /dev/null @@ -1,53 +0,0 @@ ---- -iteration: 1 -max_iterations: 12 -status: done -goal: "Verify the widget/CSS store feature is fully implemented end-to-end per the plan: PocketBase backend (apps/store), docs /store page, in-app install in nextjs, with passing tests/build/typecheck and a live PocketBase runtime check." -success_criteria: - - "PocketBase backend exists in apps/store with docker-compose.yml, version-controlled pb_migrations creating submissions/votes/reports collections with correct access rules and GitHub OAuth, pb_hooks enforcing ownership and recomputing vote counters, and a README" - - "Store schema-version validation helper exists (apps/docs/src/lib/store-schema.ts) and its test (store-schema.spec.ts) passes via vitest" - - "Docs /store page and components exist (browse/filter/sort, GitHub login, submit, vote, report, copy/download), catalog pocketbase dep + customFields.storeUrl + navbar Store link + management/store docs are wired, and `pnpm -F @homarr/docs build` succeeds" - - "In-app Install-from-store is wired into the Next.js custom-widgets manage page (reusing customWidget.import) and the board custom-CSS settings, NEXT_PUBLIC_WIDGET_STORE_URL is documented, and `pnpm -F nextjs typecheck` passes" - - "End-to-end runtime check: `docker compose up` in apps/store boots PocketBase, the init migration applies cleanly (submissions/votes/reports collections present), and the public REST API responds (GET /api/health and GET /api/collections/submissions/records return 200) and access rules behave (anonymous create on submissions is rejected)" - - "No regressions: oxlint reports no errors on the new/changed files and the git diff contains only intended store-related changes" -last_verdict: DONE -last_reason: "All 6 success criteria satisfied (runtime + static evidence)" -last_next: null -engine: cursor ---- - -## Progress log - -- Iteration 1: Verified all 6 criteria. Booted PocketBase via docker-compose (had to map to free port 8095 since unrelated `beszel-dev` holds 8090; made host port env-configurable). Migration applied collections; REST + access rules confirmed live. Reverted unintended oxfmt CSS churn so diff is store-only. - -## Blockers - -(none) - -## Verification - -Runtime (PocketBase 0.30.0 via `apps/store/docker-compose.yml`, port 8095): -- `GET /api/health` -> 200 -- `GET /api/collections/submissions/records` -> 200 `{"items":[],...}` (public read, collection created by migration) -- `GET /api/collections/votes/records` -> 200 (public) -- `GET /api/collections/reports/records` -> 403 (superuser-only, as designed) -- `POST /api/collections/submissions/records` anonymous -> 400 (createRule requires auth) -- `users` auth-methods -> oauth2.enabled=true, providers=[] (GitHub gated behind env, as designed) -- Teardown `docker compose down -v` clean; pb_data removed (gitignored) - -Static: -- `vitest run store-schema.spec.ts` -> 4/4 pass -- `pnpm -F nextjs typecheck` -> pass -- `pnpm -F @homarr/docs typecheck` + `build` -> pass (earlier this session, post-fix) -- oxlint errors on store files: 0 (docs + nextjs store-install) - -Wiring confirmed by file inspection: -- docs navbar Store link + customFields.storeUrl in docusaurus.config.ts; pocketbase in catalog (pnpm-workspace.yaml) + apps/docs deps -- InstallWidgetFromStoreButton in custom-widgets/page.tsx (reuses clientApi.customWidget.import) -- InstallCssFromStoreButton in boards .../settings/_customCss.tsx (sets form value) -- NEXT_PUBLIC_WIDGET_STORE_URL documented in .env.example -- git diff (tracked) is store-only: .env.example, docusaurus.config.ts, package.json, _customCss.tsx, custom-widgets/page.tsx, pnpm-lock.yaml, pnpm-workspace.yaml - -## Task - -Verify the widget/CSS store feature is fully implemented end-to-end per the plan: PocketBase backend (apps/store), docs /store page, in-app install in nextjs, with passing tests/build/typecheck and a live PocketBase runtime check. diff --git a/.cursor/goal/criteria.txt b/.cursor/goal/criteria.txt deleted file mode 100644 index f30358c8c..000000000 --- a/.cursor/goal/criteria.txt +++ /dev/null @@ -1,6 +0,0 @@ -PocketBase backend exists in apps/store with docker-compose.yml, version-controlled pb_migrations creating submissions/votes/reports collections with correct access rules and GitHub OAuth, pb_hooks enforcing ownership and recomputing vote counters, and a README -Store schema-version validation helper exists (apps/docs/src/lib/store-schema.ts) and its test (store-schema.spec.ts) passes via vitest -Docs /store page and components exist (browse/filter/sort, GitHub login, submit, vote, report, copy/download), catalog pocketbase dep + customFields.storeUrl + navbar Store link + management/store docs are wired, and `pnpm -F @homarr/docs build` succeeds -In-app Install-from-store is wired into the Next.js custom-widgets manage page (reusing customWidget.import) and the board custom-CSS settings, NEXT_PUBLIC_WIDGET_STORE_URL is documented, and `pnpm -F nextjs typecheck` passes -End-to-end runtime check: `docker compose up` in apps/store boots PocketBase, the init migration applies cleanly (submissions/votes/reports collections present), and the public REST API responds (GET /api/health and GET /api/collections/submissions/records return 200) and access rules behave (anonymous create on submissions is rejected) -No regressions: oxlint reports no errors on the new/changed files and the git diff contains only intended store-related changes diff --git a/.cursor/goal/scratchpad.md b/.cursor/goal/scratchpad.md deleted file mode 100644 index 58b146528..000000000 --- a/.cursor/goal/scratchpad.md +++ /dev/null @@ -1,46 +0,0 @@ ---- -goal: "Verify marketplace feature works end-to-end for CSS and custom widgets. Handle all errors gracefully. Run reviews and simplify code." -status: done -iteration: 3 -max_iterations: 5 -criteria: - - Both CSS and widget submission flows work end-to-end - - All error paths handled gracefully with user-visible feedback - - Code reviews (bugbot, code-reviewer, silent-failure-hunter) pass with no critical issues remaining - - Code simplified via code-simplifier — no verbose/redundant patterns - - NEXT_PUBLIC_WIDGET_STORE_URL fallback works correctly - - Store schema tests pass - - No lint errors ---- - -## Progress - -### Iteration 0-1: Reviews + Critical Fixes -- [x] 3 parallel reviews (bugbot, silent-failure-hunter, code-reviewer) — all critical fixed -- [x] code-simplifier ran on all 10 files -- [x] URL fallback: `STORE_URL = process.env.NEXT_PUBLIC_WIDGET_STORE_URL || "https://store.homarr.dev"` - -### Iteration 2: Error Handling Gaps -- [x] SubmitForm error visible on ALL steps (moved above step content) -- [x] submit() returns boolean; form only closes on success -- [x] Clipboard copy failure shows "Failed" with X icon -- [x] Non-null assertion removed from store-browser-modal.tsx - -### Iteration 3: Lint Verification -- [x] oxfmt: all 10 files formatted (exit 0, no changes needed) -- [x] oxlint on Next.js store-install files: 0 errors, 0 warnings -- [x] ReadLints on all edited files: no errors -- [x] docs .oxlintrc.json has pre-existing config issue (`reportUnusedDisableDirectives` in wrong location) — blocks oxlint on docs app; NOT introduced by this branch -- [x] label.tsx jsx-a11y concern: component passes htmlFor via props (standard shadcn pattern); callers in SubmitForm use semantic HTML labels with nested controls -- [x] All 4 store-schema tests pass - -## Verification Summary -| Criterion | Status | -|-----------|--------| -| CSS + widget flows | ✅ Code paths verified — submit, validate, install all wired | -| Error handling | ✅ All async ops have try/catch, user-visible feedback | -| Reviews pass | ✅ All critical/important issues from 3 reviews fixed | -| Code simplified | ✅ code-simplifier ran, lookup tables, shared helpers | -| URL fallback | ✅ env var ?? hard-coded default | -| Tests pass | ✅ 4/4 | -| Lint clean | ✅ oxfmt + oxlint + ReadLints all clean on our files |