/changelog
Änderungsprotokoll
Jede nennenswerte Änderung an SarvStack.
Unreleased
- Nothing yet.
v1.2.1 — 2026-07-05
- Invite flow: signed-out invitees now get a sign-up path, and after login/signup you reliably land back on the invite. A navigation race could previously strand new members on the dashboard.
- Settings deep links: `/settings#team` (and `#api`, `#security`, …) now open the matching tab. Notification clicks and ⌘K "Create organization" land where they should.
- Purchase side effects: order confirmation email, in-app "Purchase confirmed" notification and the audit event now fire reliably. Polar can deliver `order.created` already in `paid` status; side effects are now keyed on the status transition, not the event name. Covered by new unit tests.
- Audit log and notification inserts are now awaited before responses return. In serverless runtimes, fire-and-forget writes could be silently dropped.
- Team dialogs: cancel buttons were mislabeled "Remove"; role changes now show the correct toast; switching organizations no longer shows stale data.
- In-app notifications are localized (EN/DE/ES) for known event types.
- Blog: markdown link rendering now enforces a protocol allowlist (`http`/`https`/`mailto`/relative) — hardening for anyone reusing the renderer with untrusted content.
- Projects ownership columns (`user_id` / `organization_id`) are frozen by a database trigger. Org members can no longer re-home shared rows via the Data API.
- `EXECUTE` on the org helper functions revoked from `anon`; notifications `UPDATE` grant scoped to `read_at`, matching the documented contract.
- Invite links now derive their origin from the deployment (`PUBLIC_SITE_URL` / forwarded host) instead of a hardcoded domain.
- GitHub Actions is now genuinely green: the typecheck step used a binary that only existed in the original dev sandbox (`bunx tsgo` → npm 404), so CI failed at step 1 on every run. Typecheck now runs via `@typescript/native-preview` and `bun run typecheck` everywhere — CI, docs, and agent commands.
- Fixed an ARIA violation (Copy button inside `role="tablist"`) found once axe actually ran in CI.
- Playwright suite made hydration-safe and deterministic in CI.
v1.2.0 — 2026-07-04 — Teams, API keys & content platform
- **Teams / Organizations**: create orgs from Settings → Team, invite members by email (7-day tokenized links, hashed at rest, copyable fallback when email isn't configured), owner/admin/member roles with a last-owner guard, and dashboard project switcher (Personal | each org). New `/invite?token=...` accept page. RLS on `public.projects` extends transparently: personal projects behave identically; org projects are visible and editable by every member. See CLAUDE.md → "Organizations".
- **API keys pattern**: `sk_live_*` keys with SHA-256 hashing, 16-char prefix, one-time reveal, revoke (soft-delete for audit trail). Reference `/api/v1/me` endpoint using bearer auth + `requireApiKey`. Managed from Settings → API. Ships with unit tests for the pure key/hash helpers.
- **In-app notifications**: per-user inbox at `public.notifications` (RLS: select own, mark-read own). Header bell + unread badge in the authed shell. Only real events trigger notifications — invites accepted, members joined, purchases confirmed. No fake demo events.
- **Audit log pattern**: `public.audit_events` (admin-only SELECT via `has_role`, service-role writes). Fire-and-forget `recordAudit(...)` helper wired into API-key create/revoke, org create/delete/invite/ accept/remove, account deletion, and paid orders. Latest 50 events visible on `/admin`.
- **Waitlist mode**: one boolean in `src/config/site.ts` flips landing + pricing into email-capture mode. Rate-limited public server function (5/min/IP), service-role-only writes, admin viewer at `/admin`.
- **Agent commands**: `.claude/commands/` ships with `new-table`, `new-page`, `new-server-fn` recipes; `.cursor/rules/sarvstack.mdc` mirrors the load-bearing conventions from CLAUDE.md and is auto- applied on every Cursor request.
- **Seed script**: `bun run seed` (see `scripts/seed.ts`) scaffolds a demo user and sample projects for local development.
- **Blog module**: content-marketing engine at `/blog` with a lightweight markdown renderer, RSS feed (`/blog/rss.xml`), Article + BreadcrumbList JSON-LD, and sitemap coverage. Chrome localized (EN/DE/ES); articles EN-only. Ships with two launch posts on merchant-of-record billing and agent-ready codebases.
- **Extended profiles**: `bio`, `company`, `job_title`, `location`, `website_url`, `github_handle`, `x_handle` — all optional, all validated by the pure `validateProfileInput` helper (unit-tested).
- **Roadmap**: `/changelog` now shows a "Planned" block above the timeline. The CHANGELOG.md file itself stays shipped-only so it can double as our release-notes source of truth.
v1.1.0 — 2026-07-08 — Website polish
- Command palette (⌘K / Ctrl+K): global dialog to navigate pages, switch theme (light/dark/system), and switch language (EN/DE/ES). Localized labels, keyboard navigable, no external deps.
- SSR-safe reveal animations: server HTML now renders fully visible (no hidden pre-animation state); the reveal is armed client-side via a layout effect. Hero blocks no longer wrap in Reveal — instant LCP.
- SEO: added Organization + WebSite JSON-LD at the root; BreadcrumbList JSON-LD on /features, /faq, /compare, /changelog, /verify-license; per-page unique titles + descriptions for all auth routes; `theme-color` meta (light + dark variants); `og:site_name`; sitemap `<lastmod>` on every URL; robots.txt disallows /admin and /checkout in addition to /dashboard and /settings; llms.txt lists every current page.
v1.0.0 — 2026-07-08 — Product Hunt launch
- Account deletion flow (GDPR): auth-gated server function that removes storage avatars, cascades DB rows via FKs, and calls `auth.admin.deleteUser`. Orders and subscriptions are retained (SET NULL) as financial records.
- Playwright coverage expanded to 404 pages (EN + DE), locale switcher, `/verify-license` invalid key flow, and full footer link crawl.
- Unit tests for `webhook-verify` (HMAC) and `resolvePlan` (entitlements).
- CI pipeline: typecheck → lint → i18n check → unit tests → Playwright.
- Buyer-facing license card in the dashboard: masked key with reveal + copy, status badge, direct link to `/verify-license`.
- Public `/changelog` page for release transparency.
v0.9.0 — 2026-07-03 — Security hardening
- Closed the open mail relay: transactional senders are no longer public server functions. `sendWelcomeEmail` requires `requireSupabaseAuth` and sends only to the authenticated user's own email.
- Rate-limited public license endpoints (validate/activate/deactivate): 10 req/minute per IP, in-process fixed window.
- Timeouts on all outbound API calls (Polar checkout, Polar license, Lovable AI Gateway).
- Polar webhook receiver paginates `auth.admin.listUsers` and is case-insensitive on email matching; order confirmation email is retry-safe.
- Admin server functions: full type-safety, no `any` casts.
v0.8.0 — 2026-07-03 — Roles, admin area, license key pattern
- `user_roles` table with `SECURITY DEFINER has_role()` — never stored on `profiles`.
- Admin server functions and `/admin` route (client-side gate is UX only; server always re-checks the role).
- Polar License Key API wrappers: `validateLicenseKey`, `activateLicenseKey`, `deactivateLicenseKey`.
- `/verify-license` demo page usable by anyone.
v0.7.0 — 2026-07-03 — Subscriptions + entitlements
- Config-driven Polar subscription support: set a product id in `src/config/billing.ts` and the UI lights up.
- Webhook coverage for `subscription.created`, `.updated`, `.canceled`, `.active`, `.revoked`.
- `usePlan()` resolves `free` / `early_adopter` / `subscriber` from orders + subscriptions.
- Any paying signal grants entitlements.
v0.6.0 — 2026-07-03 — Transactional emails (Resend)
- Fail-safe email wrapper: missing `RESEND_API_KEY` never breaks signup or checkout — it logs and skips.
- Welcome email on signup.
- Order confirmation email from the Polar webhook.
v0.5.0 — 2026-07-03 — AI module with metering
- Lovable AI Gateway wired server-side; no external key required.
- `ai_usage` table + `enforceAiQuota` (5 calls/month for free users, unlimited for paying users).
- Dashboard shows the monthly usage indicator; upsell path to `/pricing` when the free cap is hit.
v0.4.0 — 2026-07-03 — i18n (EN / DE / ES)
- Trilingual UI across every public route.
- `bun run check:i18n` validates dictionary parity, placeholders, and array shapes.
- Localized URLs (`/de/*`, `/es/*`) with `hreflang` alternates and per- locale canonicals.
v0.3.0 — 2026-07-03 — Polar billing (MoR) + webhook
- Hosted Polar checkout via authenticated server function; buyers redirect to Polar and back to `/checkout/success`.
- `public.orders` table (webhook is the sole writer; users SELECT-only).
- Standard Webhooks signature verification with timing-safe compare.
v0.2.0 — 2026-07-03 — RLS patterns
- Canonical `profiles` example: auto-created via `AFTER INSERT` trigger, RLS scoped to `auth.uid() = id`, `updated_at` maintained by trigger.
- `projects` table demonstrating the full user-owned CRUD pattern with four `auth.uid() = user_id` policies.
- Private `avatars` bucket with per-user folder policies + signed URLs.
v0.1.0 — 2026-07-03 — Auth foundation
- Initial release: TanStack Start + Supabase Auth + shadcn/ui.
- Email + password sign-up / sign-in, password reset.
- `_authenticated/` layout gate with `ssr: false` and `supabase.auth.getUser()`.
- Google OAuth via the Lovable Cloud OAuth broker.