From 7d353af8abdb00b6f428a7fa40c70bb8722078fc Mon Sep 17 00:00:00 2001 From: hyscodebase <193484132+hyscodebase@users.noreply.github.com> Date: Tue, 3 Nov 2026 15:17:30 +0900 Subject: [PATCH] Add optional member portal and database-enforced account management --- .github/workflows/portal.yml | 42 + README.md | 14 +- apps/portal/.env.example | 3 + apps/portal/.gitignore | 7 + apps/portal/AGENTS.md | 9 + apps/portal/README.md | 144 ++ apps/portal/next-env.d.ts | 7 + apps/portal/next.config.ts | 26 + apps/portal/package-lock.json | 1441 +++++++++++++++++ apps/portal/package.json | 31 + apps/portal/scripts/test-database.mjs | 235 +++ apps/portal/src/app/account/page.tsx | 98 ++ apps/portal/src/app/account/password/page.tsx | 52 + apps/portal/src/app/account/requests/page.tsx | 68 + .../src/app/account/restricted/page.tsx | 29 + apps/portal/src/app/actions.ts | 138 ++ apps/portal/src/app/admin/page.tsx | 220 +++ apps/portal/src/app/auth/callback/route.ts | 20 + apps/portal/src/app/auth/confirm/route.ts | 21 + apps/portal/src/app/error.tsx | 21 + apps/portal/src/app/forgot-password/page.tsx | 45 + apps/portal/src/app/globals.css | 805 +++++++++ apps/portal/src/app/layout.tsx | 18 + apps/portal/src/app/login/page.tsx | 40 + apps/portal/src/app/page.tsx | 80 + apps/portal/src/app/privacy/page.tsx | 49 + apps/portal/src/app/signup/page.tsx | 40 + apps/portal/src/components/auth-form.tsx | 75 + apps/portal/src/components/deletion-form.tsx | 25 + apps/portal/src/components/shell.tsx | 114 ++ apps/portal/src/components/submit-button.tsx | 20 + apps/portal/src/lib/config.ts | 23 + apps/portal/src/lib/member.ts | 34 + apps/portal/src/lib/security.d.mts | 5 + apps/portal/src/lib/security.mjs | 17 + apps/portal/src/lib/supabase/server.ts | 30 + apps/portal/src/proxy.ts | 34 + apps/portal/supabase/.gitignore | 8 + apps/portal/supabase/config.toml | 422 +++++ .../20261103060357_portal_members.sql | 149 ++ apps/portal/test/security.test.mjs | 46 + apps/portal/tsconfig.json | 41 + docs/README.ko.md | 5 + docs/privacy.md | 26 +- 44 files changed, 4774 insertions(+), 3 deletions(-) create mode 100644 .github/workflows/portal.yml create mode 100644 apps/portal/.env.example create mode 100644 apps/portal/.gitignore create mode 100644 apps/portal/AGENTS.md create mode 100644 apps/portal/README.md create mode 100644 apps/portal/next-env.d.ts create mode 100644 apps/portal/next.config.ts create mode 100644 apps/portal/package-lock.json create mode 100644 apps/portal/package.json create mode 100644 apps/portal/scripts/test-database.mjs create mode 100644 apps/portal/src/app/account/page.tsx create mode 100644 apps/portal/src/app/account/password/page.tsx create mode 100644 apps/portal/src/app/account/requests/page.tsx create mode 100644 apps/portal/src/app/account/restricted/page.tsx create mode 100644 apps/portal/src/app/actions.ts create mode 100644 apps/portal/src/app/admin/page.tsx create mode 100644 apps/portal/src/app/auth/callback/route.ts create mode 100644 apps/portal/src/app/auth/confirm/route.ts create mode 100644 apps/portal/src/app/error.tsx create mode 100644 apps/portal/src/app/forgot-password/page.tsx create mode 100644 apps/portal/src/app/globals.css create mode 100644 apps/portal/src/app/layout.tsx create mode 100644 apps/portal/src/app/login/page.tsx create mode 100644 apps/portal/src/app/page.tsx create mode 100644 apps/portal/src/app/privacy/page.tsx create mode 100644 apps/portal/src/app/signup/page.tsx create mode 100644 apps/portal/src/components/auth-form.tsx create mode 100644 apps/portal/src/components/deletion-form.tsx create mode 100644 apps/portal/src/components/shell.tsx create mode 100644 apps/portal/src/components/submit-button.tsx create mode 100644 apps/portal/src/lib/config.ts create mode 100644 apps/portal/src/lib/member.ts create mode 100644 apps/portal/src/lib/security.d.mts create mode 100644 apps/portal/src/lib/security.mjs create mode 100644 apps/portal/src/lib/supabase/server.ts create mode 100644 apps/portal/src/proxy.ts create mode 100644 apps/portal/supabase/.gitignore create mode 100644 apps/portal/supabase/config.toml create mode 100644 apps/portal/supabase/migrations/20261103060357_portal_members.sql create mode 100644 apps/portal/test/security.test.mjs create mode 100644 apps/portal/tsconfig.json diff --git a/.github/workflows/portal.yml b/.github/workflows/portal.yml new file mode 100644 index 0000000..fbad477 --- /dev/null +++ b/.github/workflows/portal.yml @@ -0,0 +1,42 @@ +name: Member portal checks + +on: + pull_request: + paths: + - apps/portal/** + - .github/workflows/portal.yml + push: + branches: [main] + paths: + - apps/portal/** + - .github/workflows/portal.yml + +permissions: + contents: read + +concurrency: + group: portal-${{ github.ref }} + cancel-in-progress: true + +jobs: + portal: + runs-on: ubuntu-latest + timeout-minutes: 15 + defaults: + run: + working-directory: apps/portal + env: + NEXT_TELEMETRY_DISABLED: "1" + steps: + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 + with: + persist-credentials: false + - uses: actions/setup-node@949feb2413d6458794dcd2491c4babbbce0c15c1 # v7.1.0 + with: + node-version: 24 + - run: npm ci + - run: npm test + - run: npm run typecheck + - run: npm run build + - name: Check database authorization in isolated PostgreSQL + run: npm run test:database diff --git a/README.md b/README.md index b1d1509..d00a8e6 100644 --- a/README.md +++ b/README.md @@ -99,10 +99,22 @@ npm run typecheck No runtime dependencies. Tests use synthetic records and local fake subprocesses; [live compatibility observations](docs/validation.md) are documented separately. Tag releases run the test matrix, install the packaged CLI in a temporary directory, and publish the tarball with its checksum; see [release maintenance](docs/releasing.md). +## Optional member portal + +[The separate web app](apps/portal/README.md) provides email authentication, +profiles, administrator member status management, account deletion review +requests, and an audit trail. Registration creates a least-privilege profile +automatically. The portal uses its own Supabase project and needs Auth, email, +and first-administrator setup before opening enrollment. Portal registrations +are not measurements of CLI usage or external pilot success. + +The CLI continues to run locally without a portal account. The portal receives +no CLI snapshots or usage events. Its source is excluded from the CLI npm package. + Try the [10-minute pilot](docs/pilot.md) to report installation friction or a useful support case. External pilot outcomes have not yet been established. For incomplete results, see [troubleshooting](docs/troubleshooting.md). Maintainers can use the [interview guide](docs/interviews.md) and [weekly metrics](docs/metrics.md) to track feedback. [npm distribution](docs/npm-publishing.md) records publication and clean-install evidence. [Contributing](CONTRIBUTING.md) · [Security](SECURITY.md) · [한국어](docs/README.ko.md) · [Roadmap](docs/roadmap.md) -MIT licensed. No default telemetry, accounts, or hosted service. +MIT licensed. The CLI has no default telemetry, account requirement, or hosted service dependency. diff --git a/apps/portal/.env.example b/apps/portal/.env.example new file mode 100644 index 0000000..e11b7b4 --- /dev/null +++ b/apps/portal/.env.example @@ -0,0 +1,3 @@ +NEXT_PUBLIC_SUPABASE_URL=http://127.0.0.1:54321 +NEXT_PUBLIC_SUPABASE_PUBLISHABLE_KEY=replace_with_project_publishable_key +PORTAL_SITE_URL=http://localhost:3000 diff --git a/apps/portal/.gitignore b/apps/portal/.gitignore new file mode 100644 index 0000000..d0ff32a --- /dev/null +++ b/apps/portal/.gitignore @@ -0,0 +1,7 @@ +node_modules/ +.next/ +.env* +!.env.example +*.tsbuildinfo +supabase/.temp/ +supabase/.branches/ diff --git a/apps/portal/AGENTS.md b/apps/portal/AGENTS.md new file mode 100644 index 0000000..af3b7c8 --- /dev/null +++ b/apps/portal/AGENTS.md @@ -0,0 +1,9 @@ + + +## This is NOT the Next.js you know + +This version has breaking changes — APIs, conventions, and file structure may all differ from your training data. Read the relevant guide in `node_modules/next/dist/docs/` (resolved from this file's directory; in monorepos the `next` package may not be visible from the repo root) before writing any code. Heed deprecation notices. + +This block is written and re-added by `next dev` — verify at `node_modules/next/dist/server/lib/generate-agent-files.js`. Removing it from a diff only re-creates the uncommitted change; committing it with your work keeps the tree clean. + + diff --git a/apps/portal/README.md b/apps/portal/README.md new file mode 100644 index 0000000..4a38d53 --- /dev/null +++ b/apps/portal/README.md @@ -0,0 +1,144 @@ +# SkillWhy optional member portal + +이 앱은 로컬 CLI와 별도로 실행하는 선택형 회원 포털입니다. CLI의 로그인, +설정 업로드, snapshot 수집, 사용 추적을 추가하지 않습니다. 루트 npm 패키지의 +배포 파일에는 `apps/portal`이 포함되지 않습니다. + +## 구현 범위 + +- 이메일·비밀번호 가입, 이메일 확인, 로그인·로그아웃, 비밀번호 재설정 +- 가입 시 최소 권한의 회원 프로필 자동 생성 +- 본인 표시 이름 수정, 본인 계정 요청 조회 +- 관리자 회원 목록(25명 단위), 활성/정지, 삭제 검토 요청, 변경 기록 +- 정지와 세션 폐기를 기존 JWT에도 반영하는 데이터베이스 권한 검사 +- 계정 삭제 **검토 요청**. 자동 영구 삭제나 보관기간 만료 삭제는 구현하지 않음 + +역할은 데이터베이스에 보관합니다. 가입 시 `user_metadata.role`을 보내거나 +프로필 요청에 `role`/`status`를 붙여도 관리자 권한을 얻지 못합니다. 첫 관리자는 +아래의 운영자 SQL 절차로만 지정합니다. 앱에는 service-role/secret 키가 없습니다. + +## 실행 + +Node.js 22 이상이 필요합니다. + +```sh +cd apps/portal +npm ci +cp .env.example .env.local +# .env.local에 전용 Supabase URL·publishable key·포털 origin 입력 +npm run dev +``` + +기본 주소는 `http://localhost:3000`입니다. `PORTAL_SITE_URL`과 같은 origin으로 +접속하세요. 다른 포트·`127.0.0.1` 주소를 쓴다면 환경변수도 그 주소로 맞춥니다. +`NEXT_PUBLIC_` 변수에는 publishable key만 넣습니다. `.env.local`은 Git에서 제외됩니다. + +## Supabase 준비 + +1. 새 전용 프로젝트를 준비합니다. 기존 서비스 데이터베이스와 섞지 않습니다. +2. 새 회원이 가입하기 **전에** `supabase/migrations/*_portal_members.sql`을 적용합니다. + 이 마이그레이션은 빈 전용 프로젝트용입니다. 기존 `auth.users`의 프로필을 + 자동으로 backfill하지 않습니다. 적용 전 기존 테이블을 확인하세요. +3. Auth 설정에서 Email provider와 회원가입을 활성화하고, 이메일 확인은 켜고, + anonymous sign-ins는 끕니다. 비밀번호 최소 길이를 **12**로 설정합니다. + 프런트엔드 입력 검사만으로 Auth API 전체의 정책이 강제되지는 않습니다. +4. 외부 회원의 인증·재설정 메일을 위해 **custom SMTP**를 설정합니다. Supabase의 + 기본 메일 서비스는 조직 팀원 주소만 허용하므로 외부 가입 완료의 근거가 되지 않습니다. +5. Auth Site URL을 `PORTAL_SITE_URL`로 설정합니다. 개발 중 허용할 redirect URL: + - `http://localhost:3000/auth/callback` + - `http://localhost:3000/auth/callback?flow=recovery` + 운영 배포에는 정확한 HTTPS 포털 주소를 사용합니다. 광범위한 wildcard는 사용하지 않습니다. + +메일을 다른 기기에서 열어도 작동하게 하려면 Email Templates의 링크를 다음처럼 +`token_hash` 확인 경로로 설정합니다. `SiteURL`은 정확한 포털 origin입니다. + +가입 확인: + +```html +이메일 확인 +``` + +비밀번호 재설정: + +```html +비밀번호 재설정 +``` + +기본 PKCE `/auth/callback`도 구현돼 있습니다. 확인 메일을 최초 가입 요청과 다른 +브라우저에서 열면 PKCE verifier cookie가 없을 수 있으므로 위의 token-hash 링크를 +권장합니다. 메일 템플릿·SMTP·Auth 설정은 앱 빌드만으로 구성되지 않습니다. + +## 첫 관리자 지정 + +운영자가 본인 계정으로 가입하고 이메일 확인을 완료한 다음, Supabase SQL Editor의 +인증된 프로젝트 소유자 권한으로 아래를 실행합니다. 이메일을 실제 운영자 주소로 +바꿉니다. 브라우저 입력이나 JWT의 사용자 메타데이터를 관리자 자격으로 사용하지 않습니다. + +```sql +update public.member_profiles p +set role = 'admin' +from auth.users u +where p.id = u.id + and u.email = 'REPLACE_WITH_VERIFIED_OPERATOR_EMAIL' + and u.email_confirmed_at is not null; +``` + +영향받은 행이 정확히 하나인지 확인하세요. 앱의 관리 화면에는 역할 부여 기능이 +없습니다. 관리자 상태 변경은 자신을 대상으로 할 수 없고, 같은 데이터베이스 잠금으로 +직렬화한 뒤 현재 관리자 자격을 다시 확인합니다. + +## 데이터와 권한 + +`member_profiles`는 본인 또는 활성 관리자만 읽을 수 있습니다. 회원이 직접 바꿀 수 +있는 열은 `display_name`뿐입니다. 생성 트리거가 역할을 `member`, 상태를 `active`로 +초기화하며, 이메일은 Auth 사용자 정보와 동기화됩니다. + +RLS guard는 신선한 프로필 역할·상태, JWT의 사용자/세션 식별자, +`auth.sessions` 존재와 `not_after`를 검사합니다. 정지하면 과거 JWT의 프로필/관리 +접근도 막힙니다. 정지 회원은 본인 삭제 검토 요청을 남길 수 있습니다. 이는 Supabase +Auth 자체에서 로그인을 차단하거나 모든 세션을 자동 폐기하는 기능은 아닙니다. + +`member_audit_events`는 관리자에게만 읽기를 허용합니다. 클라이언트의 직접 삽입·수정·삭제는 +허용하지 않습니다. 프로필 생성·이름 수정·앱을 통한 상태 변경·삭제 요청/검토를 기록하며, +응답 본문이나 비밀번호를 복제하지 않습니다. 프로젝트 소유자가 SQL로 직접 한 권한 변경은 +별도 운영 절차로 관리해야 합니다. + +공개 RPC는 security-invoker wrapper입니다. 필요한 privileged 구현은 노출하지 않는 +`private` 스키마에 있고, 고정 `search_path`, 명시적 EXECUTE grant, 호출자 검증을 사용합니다. +`private`를 Data API exposed schemas에 추가하지 마세요. + +프로필·관리 화면은 요청별로 조회하며, 인증 응답은 `private, no-store`입니다. 쿠키는 +HttpOnly/SameSite=Lax이고 운영 HTTPS origin에서는 Secure입니다. 모든 변경 Server Action은 +설정된 origin을 검사하며 세션과 데이터베이스 권한을 다시 확인합니다. 인증 callback은 +고정된 같은 origin의 경로만 사용하고 임의 `next` URL을 받지 않습니다. + +## 검증 + +```sh +npm test +npm run typecheck +npm run build +npm run test:database +``` + +마지막 명령은 Docker와 `postgres:17.11-bookworm` 이미지를 사용합니다. 외부 네트워크와 +호스트 포트가 없는 일회용 컨테이너에서 실제 PostgreSQL RLS/RPC를 실행하고 제거합니다. +테스트용 `auth` 테이블·JWT helper는 최소 fixture입니다. 이는 Supabase GoTrue, 실제 +이메일 배달, 프로덕션 쿠키·도메인·SMTP까지 검증한 결과가 아닙니다. + +검증한 핵심 사례: anon 접근, 다른 회원 조회/수정 차단, 역할·상태·ID 수정 차단, +user metadata 권한 위조 차단, 정지된 기존 JWT, 삭제된/만료 세션, anonymous-auth JWT, +관리자 자기 정지 금지, 중복 삭제 요청, 감사 기록 변경 금지, 실제 삭제가 아닌 검토. + +운영 전 실제 허용된 테스트 이메일로 가입 → 인증 → 로그인 → 프로필 수정 → 로그아웃 → +재설정을 확인하고, 일반 회원과 관리자 계정으로 각각 권한을 확인해야 합니다. 자동 테스트는 +외부 주소에 메일을 보내거나 실제 회원·관리자 계정을 임의 생성하지 않습니다. + +참고: [Supabase SSR](https://supabase.com/docs/guides/auth/server-side/creating-a-client), +[비밀번호 재설정](https://supabase.com/docs/reference/javascript/auth-resetpasswordforemail), +[custom SMTP](https://supabase.com/docs/guides/auth/auth-smtp), +[RLS](https://supabase.com/docs/guides/database/postgres/row-level-security). diff --git a/apps/portal/next-env.d.ts b/apps/portal/next-env.d.ts new file mode 100644 index 0000000..ce4e94a --- /dev/null +++ b/apps/portal/next-env.d.ts @@ -0,0 +1,7 @@ +/// +/// +import "./.next/types/routes.d.ts"; +import "./.next/types/root-params.d.ts"; + +// NOTE: This file should not be edited +// see https://nextjs.org/docs/app/api-reference/config/typescript for more information. diff --git a/apps/portal/next.config.ts b/apps/portal/next.config.ts new file mode 100644 index 0000000..3cf2c4f --- /dev/null +++ b/apps/portal/next.config.ts @@ -0,0 +1,26 @@ +import type { NextConfig } from "next"; +import { fileURLToPath } from "node:url"; +const portalRoot = fileURLToPath(new URL(".", import.meta.url)); +const config: NextConfig = { + poweredByHeader: false, + turbopack: { root: portalRoot }, + outputFileTracingRoot: portalRoot, + async headers() { + return [ + { + source: "/:path*", + headers: [ + { key: "X-Content-Type-Options", value: "nosniff" }, + { key: "Referrer-Policy", value: "strict-origin-when-cross-origin" }, + { key: "X-Frame-Options", value: "DENY" }, + { + key: "Permissions-Policy", + value: "camera=(), microphone=(), geolocation=()", + }, + { key: "Cache-Control", value: "private, no-store, max-age=0" }, + ], + }, + ]; + }, +}; +export default config; diff --git a/apps/portal/package-lock.json b/apps/portal/package-lock.json new file mode 100644 index 0000000..0ffea35 --- /dev/null +++ b/apps/portal/package-lock.json @@ -0,0 +1,1441 @@ +{ + "name": "@skillwhy/portal", + "version": "0.1.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "@skillwhy/portal", + "version": "0.1.0", + "dependencies": { + "@supabase/ssr": "0.12.7", + "@supabase/supabase-js": "2.118.0", + "next": "16.4.4", + "react": "19.3.1", + "react-dom": "19.3.1" + }, + "devDependencies": { + "@types/node": "22.20.5", + "@types/react": "19.3.0", + "@types/react-dom": "19.3.0", + "supabase": "3.0.0", + "typescript": "5.9.3" + }, + "engines": { + "node": ">=22" + } + }, + "node_modules/@ecies/ciphers": { + "version": "0.2.6", + "resolved": "https://registry.npmjs.org/@ecies/ciphers/-/ciphers-0.2.6.tgz", + "integrity": "sha512-patgsRPKGkhhoBjETV4XxD0En4ui5fbX0hzayqI3M8tvNMGUoUvmyYAIWwlxBc1KX5cturfqByYdj5bYGRpN9g==", + "dev": true, + "license": "MIT", + "engines": { + "bun": ">=1", + "deno": ">=2.7.10", + "node": ">=16" + }, + "peerDependencies": { + "@noble/ciphers": "^1.0.0" + } + }, + "node_modules/@emnapi/runtime": { + "version": "1.11.3", + "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.11.3.tgz", + "integrity": "sha512-Xz4Tpyki7XyrpbUK1jR1AhdAdaXyhhY4lZ3neLodmhpuWfy2PAQN5B46sAiU4liOXGLkHypn/qU+jvfWSCYYLA==", + "license": "MIT", + "optional": true, + "dependencies": { + "tslib": "^2.4.0" + } + }, + "node_modules/@img/colour": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@img/colour/-/colour-1.1.0.tgz", + "integrity": "sha512-Td76q7j57o/tLVdgS746cYARfSyxk8iEfRxewL9h4OMzYhbW4TAcppl0mT4eyqXddh6L/jwoM75mo7ixa/pCeQ==", + "license": "MIT", + "optional": true, + "engines": { + "node": ">=18" + } + }, + "node_modules/@img/sharp-darwin-arm64": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-darwin-arm64/-/sharp-darwin-arm64-0.35.5.tgz", + "integrity": "sha512-QRUlFQ0WxvdWyqqG/WtI3iupfD5rBzmCHXSdPsY91sAtVtTo7Q4cb6zOccZ3gqEqkr0f1As1ehLqmEpDsRf+lg==", + "cpu": [ + "arm64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-darwin-arm64": "1.3.4" + } + }, + "node_modules/@img/sharp-darwin-x64": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-darwin-x64/-/sharp-darwin-x64-0.35.5.tgz", + "integrity": "sha512-+BR255RhDlpygUpOc/Jdt1nT6DQ3XG/ERo5wbcdOf5Q320dKtPCKPLR1LJs9VGXRaMa8l1uUa0tkCNOXiAxZUw==", + "cpu": [ + "x64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-darwin-x64": "1.3.4" + } + }, + "node_modules/@img/sharp-freebsd-wasm32": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-freebsd-wasm32/-/sharp-freebsd-wasm32-0.35.5.tgz", + "integrity": "sha512-Y/z91nEZ4uIBX5X3nfTovjU9lHNKFYbL2lpHCLVNmXQK03VIZvXBBt0KxbPGp2SdGSF+2mQU4e+hQaWOt86iAw==", + "license": "Apache-2.0", + "optional": true, + "os": [ + "freebsd" + ], + "dependencies": { + "@img/sharp-wasm32": "0.35.5" + }, + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-darwin-arm64": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-arm64/-/sharp-libvips-darwin-arm64-1.3.4.tgz", + "integrity": "sha512-5R89nBYiRdUlSWJxPhO+GVtaXzXSxKnRu/xqMn3KTA3L9EB9Oy/P+Nn2f2vlhPuUdy/Zusb2DarbyTpGCfEDuw==", + "cpu": [ + "arm64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "darwin" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-darwin-x64": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-x64/-/sharp-libvips-darwin-x64-1.3.4.tgz", + "integrity": "sha512-iR2OKH80yi0U+dUplyh3/xdpFvps6YkCwsXenIJxqxR1v9o+xtKTGbS9H7cps+2Vxjc8B1j96p75NmTGjIhtpQ==", + "cpu": [ + "x64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "darwin" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-arm": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm/-/sharp-libvips-linux-arm-1.3.4.tgz", + "integrity": "sha512-LmRtTsOHuvM2+wlO2Db37dx5MiZhB0FvSunciw48YjdOkZz9KAiRbm8ujeMOA1INqmei5NapFxYEK1D1ZSidmw==", + "cpu": [ + "arm" + ], + "libc": [ + "glibc" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-arm64": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm64/-/sharp-libvips-linux-arm64-1.3.4.tgz", + "integrity": "sha512-Y3dgX/6lE2QhQb+Gxy0WZxfg9MEm/JBjamZpS2IklP7xIQoKN4hzAm7KcMVGtaVDt3neE9OKBC7vAfonA/Lr1A==", + "cpu": [ + "arm64" + ], + "libc": [ + "glibc" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-ppc64": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-ppc64/-/sharp-libvips-linux-ppc64-1.3.4.tgz", + "integrity": "sha512-Le6boB8Tai0Nis+gIxIpKx68UDVVIqdR8Tin5Yf1z2LJJQLDJvCDRqRu+jC2qCoD+eIomonmOwB4smBRxfVpYQ==", + "cpu": [ + "ppc64" + ], + "libc": [ + "glibc" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-riscv64": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-riscv64/-/sharp-libvips-linux-riscv64-1.3.4.tgz", + "integrity": "sha512-aHkkIEHPRdQEegJN20MLmGtxYD9R2wQr3Cwpddnu5+YKMt6Uzax7S9h5gpZTo8wyrGuZSlfQ63OevL5mTyOC7Q==", + "cpu": [ + "riscv64" + ], + "libc": [ + "glibc" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-s390x": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-s390x/-/sharp-libvips-linux-s390x-1.3.4.tgz", + "integrity": "sha512-ra/mB6MikESDUO7Yg+Mi95bFBb9GsObURuhnOv3OqknjGe9sZrG8tCe9q0xSIGrtLgvgw0gKnFWcK4blSgQOuQ==", + "cpu": [ + "s390x" + ], + "libc": [ + "glibc" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-x64": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-x64/-/sharp-libvips-linux-x64-1.3.4.tgz", + "integrity": "sha512-GJ//SSXbnwSDes02umB3nDJLFcQzw8a18V8fyhqr6tV515tOEMdImjjxj1AoafMRz56F3PHgftnj1QEKSU1zkw==", + "cpu": [ + "x64" + ], + "libc": [ + "glibc" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linuxmusl-arm64": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-arm64/-/sharp-libvips-linuxmusl-arm64-1.3.4.tgz", + "integrity": "sha512-hvulFwtjUcagsis6BBxHwGFwWoNZjgYmULGVrZcyfNbjA8hKILbRxGg15/7w5HDyXHXUos/j6baAWqnCyQ2DWA==", + "cpu": [ + "arm64" + ], + "libc": [ + "musl" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linuxmusl-x64": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-x64/-/sharp-libvips-linuxmusl-x64-1.3.4.tgz", + "integrity": "sha512-6zXKeE/p39I1AmA3cJG35eyBGNqNddLnUXjhwBnsGjFPWqf5VKkDBEqaEkPDoTEtkxwi2vv8Tcr2mDyP4So7Fg==", + "cpu": [ + "x64" + ], + "libc": [ + "musl" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-linux-arm": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm/-/sharp-linux-arm-0.35.5.tgz", + "integrity": "sha512-LEaXK2WdXVK5ykcw0buWyPMsmLLL2vpHLD6yrNSW+JGEL3BZPA4tpKN6iaMc4AxTTAoaX/sU1rOL51lcIz48ZQ==", + "cpu": [ + "arm" + ], + "libc": [ + "glibc" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-arm": "1.3.4" + } + }, + "node_modules/@img/sharp-linux-arm64": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm64/-/sharp-linux-arm64-0.35.5.tgz", + "integrity": "sha512-LYVx5JTsOM2CBzmxreh+nl64/3H6Xb09iSLknqH47z2T2DFFxDeFLP5y4dJwe6H7uGQlHPyEEtIqyo3DYsRwdQ==", + "cpu": [ + "arm64" + ], + "libc": [ + "glibc" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-arm64": "1.3.4" + } + }, + "node_modules/@img/sharp-linux-ppc64": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-ppc64/-/sharp-linux-ppc64-0.35.5.tgz", + "integrity": "sha512-QVxAAq8evVRI9ia2vqgwrmWucn5Dfv+JdWzj75pD8omHLPSP7f8p20O8jxzjCcuCEQEOtYOZUmX1hkiZ0kdevA==", + "cpu": [ + "ppc64" + ], + "libc": [ + "glibc" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-ppc64": "1.3.4" + } + }, + "node_modules/@img/sharp-linux-riscv64": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-riscv64/-/sharp-linux-riscv64-0.35.5.tgz", + "integrity": "sha512-LtdreXguaavKODPIfzJ4kffx7UNt1omwtK0rch4EBbbSTXPnxWmYSayXdLJw0fJzQ97kHt1gL/yh4tvU+nCyRQ==", + "cpu": [ + "riscv64" + ], + "libc": [ + "glibc" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-riscv64": "1.3.4" + } + }, + "node_modules/@img/sharp-linux-s390x": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-s390x/-/sharp-linux-s390x-0.35.5.tgz", + "integrity": "sha512-UZasTOFiYzotTsGOCu42BfUzP6Tu6Do/947iRm1RsLKvlllxwGcn4RN27LibGWceix4Y+Pmw3jsnTcCQIgWjqA==", + "cpu": [ + "s390x" + ], + "libc": [ + "glibc" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-s390x": "1.3.4" + } + }, + "node_modules/@img/sharp-linux-x64": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-x64/-/sharp-linux-x64-0.35.5.tgz", + "integrity": "sha512-SxFtLTeJInhAA9Q836kux2vZNeOBQEx658qvbboZScr0wIARym3IcGmW7KpVD5sbVg0Ojy+udFQdayYIZyoNog==", + "cpu": [ + "x64" + ], + "libc": [ + "glibc" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-x64": "1.3.4" + } + }, + "node_modules/@img/sharp-linuxmusl-arm64": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linuxmusl-arm64/-/sharp-linuxmusl-arm64-0.35.5.tgz", + "integrity": "sha512-9HbMclmI1zlNkFRs3z9/eBtDjfD0sGlrX1z6b1qwmiFY5ElDLh4BC0LPBdVp7z1DXFiKlIcznf+ZlsuZzLxQqg==", + "cpu": [ + "arm64" + ], + "libc": [ + "musl" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linuxmusl-arm64": "1.3.4" + } + }, + "node_modules/@img/sharp-linuxmusl-x64": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linuxmusl-x64/-/sharp-linuxmusl-x64-0.35.5.tgz", + "integrity": "sha512-4KOphqB035HrVdqLZfCgMzzERrQkkzOwRhl4OAkRO1YCldbaFjySXMaK534Mo0V+LndnlJk+sbUyLeU0ULyD1A==", + "cpu": [ + "x64" + ], + "libc": [ + "musl" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linuxmusl-x64": "1.3.4" + } + }, + "node_modules/@img/sharp-wasm32": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-wasm32/-/sharp-wasm32-0.35.5.tgz", + "integrity": "sha512-Ptsga1su4tQx+LLF1ECS9U6nz5kmrXKo6XVbtR48Ke3ZRxxgaWBu7IDtEe1quo8hiupwm6WFqxVlXaSf7IINGQ==", + "license": "Apache-2.0 AND LGPL-3.0-or-later AND MIT", + "optional": true, + "dependencies": { + "@emnapi/runtime": "^1.11.3" + }, + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-webcontainers-wasm32": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-webcontainers-wasm32/-/sharp-webcontainers-wasm32-0.35.5.tgz", + "integrity": "sha512-hfhF/FmoQyTUkA0bIKFOtw536BQSeBMe6BF6QyWlrPxT754+TFLaZ7sKKTfvvM0yJgKgaYTwnFCIZ/GuDw5SUA==", + "cpu": [ + "wasm32" + ], + "license": "Apache-2.0", + "optional": true, + "dependencies": { + "@img/sharp-wasm32": "0.35.5" + }, + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-win32-arm64": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-arm64/-/sharp-win32-arm64-0.35.5.tgz", + "integrity": "sha512-X4t7g+7ZA5DKblCBEXGjUqqemj4vczING/5viFwAL8h4N3qYeyjwdCvRLHi4EdOUI+2Z7UFlp1VM+p/AuEtm6Q==", + "cpu": [ + "arm64" + ], + "license": "Apache-2.0 AND LGPL-3.0-or-later", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-win32-ia32": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-ia32/-/sharp-win32-ia32-0.35.5.tgz", + "integrity": "sha512-5Zm82LoBc43nhwNybZlG7Y1KO//Zhsn306fQl29ZOuStHLGTo3BWL83q3cznX0poxSAMuYL1On/BHBxkBeKr6A==", + "cpu": [ + "ia32" + ], + "license": "Apache-2.0 AND LGPL-3.0-or-later", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-win32-x64": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-x64/-/sharp-win32-x64-0.35.5.tgz", + "integrity": "sha512-x76eH0vEiHlcMQu8Y8IenntaACtddpT6W0wmXtWrnKcnKI7ME5DdgqhAD6SEWOEl1v2zDvkZDhFA9KnURwpfqg==", + "cpu": [ + "x64" + ], + "license": "Apache-2.0 AND LGPL-3.0-or-later", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@next/env": { + "version": "16.4.4", + "resolved": "https://registry.npmjs.org/@next/env/-/env-16.4.4.tgz", + "integrity": "sha512-6/3ZuELR0tPLgNigvv8d/LAmfLIo1IpNfvrI/AHCAl9w9D0DNVGQGvo+OLPzAWR+WMW3vVyO7HaW0kfL97huBg==", + "license": "MIT" + }, + "node_modules/@next/swc-darwin-arm64": { + "version": "16.4.4", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-16.4.4.tgz", + "integrity": "sha512-1KlZ5IJ7zcLBZvqG1q7nuRWm2LAAN4C3iBqqoBCRRl1UEv0A4k6Rek+x3j23UiWf8Gz+VsN+M/LylAWkxpm2mg==", + "cpu": [ + "arm64" + ], + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-darwin-x64": { + "version": "16.4.4", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-16.4.4.tgz", + "integrity": "sha512-Tb7efFdhbS/ph74RS7wob84gXGM58qxoO/WrkiMsTmy/JZktKOKBeiM45W0E/b8JfBzZJdexQqSmvedBwDK0PA==", + "cpu": [ + "x64" + ], + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-linux-arm64-gnu": { + "version": "16.4.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-16.4.4.tgz", + "integrity": "sha512-wojSfLnH8RRImhtbcn3Dlx9JICh6aQHgDA33XDr+EPua2tt7Q/yjDn0FTAbqfNlLrBmOASAGhLh6NvBk9L3gzw==", + "cpu": [ + "arm64" + ], + "libc": [ + "glibc" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-linux-arm64-musl": { + "version": "16.4.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-16.4.4.tgz", + "integrity": "sha512-zgxpGOZaR+2O6dOk5ZAUkKgH92ZtqNg3ohzyg2HmWc2N+AZH4dEpTwdpB0e5MR9YRVdVDUkEM5g6c3TWWn8g1g==", + "cpu": [ + "arm64" + ], + "libc": [ + "musl" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-linux-x64-gnu": { + "version": "16.4.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-16.4.4.tgz", + "integrity": "sha512-fg3Wr030Y3BDkCXi6HGsPz0BUPTGZJS8TZSrCO0tS3O/KBsCyx4eP6aeaizCpGmcUKhtb4l7JoMc88QO2qBl2g==", + "cpu": [ + "x64" + ], + "libc": [ + "glibc" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-linux-x64-musl": { + "version": "16.4.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-16.4.4.tgz", + "integrity": "sha512-40cr71PSdCV9zU2g0B1XG27af10tYU+9g8F+FtF3qSguQg0jSZDoxn0NrAvgFQ0cy9s0ZBA/00P9g/XL1O43xg==", + "cpu": [ + "x64" + ], + "libc": [ + "musl" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-win32-arm64-msvc": { + "version": "16.4.4", + "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-16.4.4.tgz", + "integrity": "sha512-vFMiEbRZ+LYNeswslf4LuGuoPHE8JbtqV0GnmzbpnGNMs0uWaR2q98hu8M/UWGycNJERBXIUss+BGd3PIJ8VZg==", + "cpu": [ + "arm64" + ], + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@next/swc-win32-x64-msvc": { + "version": "16.4.4", + "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-16.4.4.tgz", + "integrity": "sha512-jy2P4V8BDZ+CFCzYABHYRZ1CmyFhfmYe22i8KA4uEafdYPrUjJ3Ot+lx265mLWLHiZRIfBzCn3V1F17m0vzl9Q==", + "cpu": [ + "x64" + ], + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">= 10" + } + }, + "node_modules/@noble/ciphers": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/@noble/ciphers/-/ciphers-1.3.0.tgz", + "integrity": "sha512-2I0gnIVPtfnMw9ee9h1dJG7tp81+8Ob3OJb3Mv37rx5L40/b0i7djjCVvGOVqc9AEIQyvyu1i6ypKdFw8R8gQw==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^14.21.3 || >=16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@noble/curves": { + "version": "1.9.7", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.9.7.tgz", + "integrity": "sha512-gbKGcRUYIjA3/zCCNaWDciTMFI0dCkvou3TL8Zmy5Nc7sJ47a0jtOeZoTaMxkuqRo9cRhjOdZJXegxYE5FN/xw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@noble/hashes": "1.8.0" + }, + "engines": { + "node": "^14.21.3 || >=16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@noble/hashes": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.8.0.tgz", + "integrity": "sha512-jCs9ldd7NwzpgXDIf6P3+NrHh9/sD6CQdxHyjQI+h/6rDNo88ypBxxz45UDuZHz9r3tNz7N/VInSVoVdtXEI4A==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^14.21.3 || >=16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@supabase/auth-js": { + "version": "2.118.0", + "resolved": "https://registry.npmjs.org/@supabase/auth-js/-/auth-js-2.118.0.tgz", + "integrity": "sha512-xWfPXyhS2KDSfAneMtI6p/tBnbdiz/5vaRKXEqUfzfC9WCniKr2Ds5o5G7RIGig0bom4z6wUY9zaV07WDVTfnQ==", + "license": "MIT", + "dependencies": { + "tslib": "2.8.1" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/@supabase/cli-darwin-arm64": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@supabase/cli-darwin-arm64/-/cli-darwin-arm64-3.0.0.tgz", + "integrity": "sha512-6N/clanDjhKWcPsHBqXcSt7HCZ0bBTjkGGrHgM4834zFu/PBIVBS6u9YJVXxOdQnbwyw/rTwumSYvgwwJgoIug==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@supabase/cli-darwin-x64": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@supabase/cli-darwin-x64/-/cli-darwin-x64-3.0.0.tgz", + "integrity": "sha512-e2DKOLIqK82XRp/GSmm0oMXx2CLBSTWJGobro1POPhmn3o+NWRQPI1QvjLFYIeI/9ZfSuo5PUJN4KI9OSjzAng==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@supabase/cli-linux-arm64": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@supabase/cli-linux-arm64/-/cli-linux-arm64-3.0.0.tgz", + "integrity": "sha512-sjdzBJGa+zfXSxUczRkqAJpuVgE2PFWXJazYxOnrqYWVPiS9Q0e2m06JdUXwZz/GqxKuLuDQN1OyLFu8DLfQDA==", + "cpu": [ + "arm64" + ], + "dev": true, + "libc": [ + "glibc" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@supabase/cli-linux-arm64-musl": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@supabase/cli-linux-arm64-musl/-/cli-linux-arm64-musl-3.0.0.tgz", + "integrity": "sha512-Bxe2bggo4dLW6tvlA6Qmjzth3VPGNEzjEaxYZohalP+q4jynov6OE6ibeLEdBtalykDMRbUXQ9j7r1p10RI/hQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "libc": [ + "musl" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@supabase/cli-linux-x64": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@supabase/cli-linux-x64/-/cli-linux-x64-3.0.0.tgz", + "integrity": "sha512-cR4S5e3nygMaBShbbt6FOiMumtrFJjwdKMXMimC1y7FpxITlwLv36BveaifQZ8aY+v1u+w8oYANU2H72Y4ibWA==", + "cpu": [ + "x64" + ], + "dev": true, + "libc": [ + "glibc" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@supabase/cli-linux-x64-musl": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@supabase/cli-linux-x64-musl/-/cli-linux-x64-musl-3.0.0.tgz", + "integrity": "sha512-ANyJ6h2X4HgM8f3PAFLGNH1XzYNho2M4kev/z5Ryq6on3ArI9FA+4KrrUqs1SFGji8E5WGyx/H+CHxmcXf5rTg==", + "cpu": [ + "x64" + ], + "dev": true, + "libc": [ + "musl" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@supabase/cli-windows-arm64": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@supabase/cli-windows-arm64/-/cli-windows-arm64-3.0.0.tgz", + "integrity": "sha512-Xox3X7BXpe+/X9XpAgo5/Qrv5qtJaItc3gLlAwJ2d2AcGrBnfh4/b0MvbNbyO7I2Fj1c7yrPmMI4lEicVvIGGw==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@supabase/cli-windows-x64": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@supabase/cli-windows-x64/-/cli-windows-x64-3.0.0.tgz", + "integrity": "sha512-nBfd1Rz8MwstIJXHo5fyIQgjmYgLxDbBIuCmuttYAQwTafc7jUOofIAAUUARkhalHu0kBOEyRuEqe2rfKr/l5w==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@supabase/functions-js": { + "version": "2.118.0", + "resolved": "https://registry.npmjs.org/@supabase/functions-js/-/functions-js-2.118.0.tgz", + "integrity": "sha512-4ofletPa/noKAU6KHeqsd3FztGzRPUEJRey1MKY0o+PIHaVePqRPShIXtl37gcVyIWaFM+zNg6r9zh0uUSFOSA==", + "license": "MIT", + "dependencies": { + "tslib": "2.8.1" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/@supabase/phoenix": { + "version": "0.4.5", + "resolved": "https://registry.npmjs.org/@supabase/phoenix/-/phoenix-0.4.5.tgz", + "integrity": "sha512-aAn9H9ovVyeApKy11OWOrrOGq8DV68yWeH4ud2lN9fzn4aO8Zb5GLL9m1pUg9nLqIcT+ZDfAcsZe0E/nqdv2lw==", + "license": "MIT" + }, + "node_modules/@supabase/postgrest-js": { + "version": "2.118.0", + "resolved": "https://registry.npmjs.org/@supabase/postgrest-js/-/postgrest-js-2.118.0.tgz", + "integrity": "sha512-JXy+37KPApHsyotaQACovv/Jy9E22rfiWLRuT+2UjoEAcAIelDFIrsF/FY47Dy19mO7lI0Tq+zDCX8oJ2Ozfiw==", + "license": "MIT", + "dependencies": { + "tslib": "2.8.1" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/@supabase/realtime-js": { + "version": "2.118.0", + "resolved": "https://registry.npmjs.org/@supabase/realtime-js/-/realtime-js-2.118.0.tgz", + "integrity": "sha512-pzCIEWjqD5/xqEZQerpt+q9rsgYkcrkgCJgf0W2ULqC4fYUeB/p9CFa3t9vn+IVh6dMN9r4ZCE262lZvUC+Bfw==", + "license": "MIT", + "dependencies": { + "@supabase/phoenix": "0.4.5", + "tslib": "2.8.1" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/@supabase/ssr": { + "version": "0.12.7", + "resolved": "https://registry.npmjs.org/@supabase/ssr/-/ssr-0.12.7.tgz", + "integrity": "sha512-wiBtEie1KkRJi9RrZWY3R2imRhX1JY7qMyUCH2z9AUk15gQebNEplM+urbCKamdxaTJLXUU6LlpkJsaxhojCEg==", + "license": "MIT", + "dependencies": { + "cookie": "^1.0.2" + }, + "peerDependencies": { + "@supabase/supabase-js": "^2.114.0" + } + }, + "node_modules/@supabase/storage-js": { + "version": "2.118.0", + "resolved": "https://registry.npmjs.org/@supabase/storage-js/-/storage-js-2.118.0.tgz", + "integrity": "sha512-5MNkKt2Moy7Jud/sPX7/28BwdDxZMCVHGJT00b8op3KRa9LKSjOAYU5IcfGWIstaasAqY8GkbA6oI3IRDgB1YQ==", + "license": "MIT", + "dependencies": { + "iceberg-js": "^0.8.1", + "tslib": "2.8.1" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/@supabase/supabase-js": { + "version": "2.118.0", + "resolved": "https://registry.npmjs.org/@supabase/supabase-js/-/supabase-js-2.118.0.tgz", + "integrity": "sha512-FxI8UXMVC2UG7IkeiI8fuQZqq2oI3JeSuN8MPIC2RLVaoEAxKS0nqE6kii9Ewpq8f9gNPM6git1Y8f0vN/QLFw==", + "license": "MIT", + "dependencies": { + "@supabase/auth-js": "2.118.0", + "@supabase/functions-js": "2.118.0", + "@supabase/postgrest-js": "2.118.0", + "@supabase/realtime-js": "2.118.0", + "@supabase/storage-js": "2.118.0" + }, + "engines": { + "node": ">=22.0.0" + }, + "peerDependencies": { + "@opentelemetry/api": ">=1.0.0" + }, + "peerDependenciesMeta": { + "@opentelemetry/api": { + "optional": true + } + } + }, + "node_modules/@swc/helpers": { + "version": "0.5.23", + "resolved": "https://registry.npmjs.org/@swc/helpers/-/helpers-0.5.23.tgz", + "integrity": "sha512-5lSsMOTXURePglDfvuAQUqkGek9Hg2kksOYay2m0+XR++b2NWYL/4sWyuvVBIs8oKnJaxkdi9whaL/sqN13afw==", + "license": "Apache-2.0", + "dependencies": { + "tslib": "^2.8.0" + } + }, + "node_modules/@types/node": { + "version": "22.20.5", + "resolved": "https://registry.npmjs.org/@types/node/-/node-22.20.5.tgz", + "integrity": "sha512-U2+DNr+wSjpsTS/wZGYHq7GcwfuSmKiKvoPvK22zwTlRhU91yOniN4qRR5KhIjvif7ysw/dz/hKmfDH0Ris4aA==", + "dev": true, + "license": "MIT", + "dependencies": { + "undici-types": "~6.21.0" + } + }, + "node_modules/@types/react": { + "version": "19.3.0", + "resolved": "https://registry.npmjs.org/@types/react/-/react-19.3.0.tgz", + "integrity": "sha512-N0rFCuH9YoxG9/m61l9MfpJKfmLOVU0em7ipIz6TRgSSkvReLB9vL85GB+yr8Bs5leqpvg96JSwF4ZS1s4viQg==", + "dev": true, + "license": "MIT", + "dependencies": { + "csstype": "^3.2.2" + } + }, + "node_modules/@types/react-dom": { + "version": "19.3.0", + "resolved": "https://registry.npmjs.org/@types/react-dom/-/react-dom-19.3.0.tgz", + "integrity": "sha512-ZI7bU42mZXXKHn/qNLEw2IrbiINU7X5+vfgdixBHkCNpYWXjKgfQ/P+uyGb5CjOLB9UcnTeg3rylQtV2hym44Q==", + "dev": true, + "license": "MIT", + "peerDependencies": { + "@types/react": "^19.3.0" + } + }, + "node_modules/baseline-browser-mapping": { + "version": "2.11.35", + "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.11.35.tgz", + "integrity": "sha512-GNk8KX52CHqeNKGk8+7tZnQab/2k1t/BgrUHPKNdijzpEhF1saPQZHVKb6m5loSAxB39gyrTYw34Qf9CQ3u1qQ==", + "license": "Apache-2.0", + "bin": { + "baseline-browser-mapping": "dist/cli.cjs" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/caniuse-lite": { + "version": "1.0.30001820", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001820.tgz", + "integrity": "sha512-gfWD6MxqVCqAOwmODfZf7DchWvlrA+SRdNX7ceLfg3xRqe5ssjjpF7EgslC/0tiLiNTajdaNN/q8c/5u/7Gz8w==", + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/caniuse-lite" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "CC-BY-4.0" + }, + "node_modules/client-only": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/client-only/-/client-only-0.0.1.tgz", + "integrity": "sha512-IV3Ou0jSMzZrd3pZ48nLkT9DA7Ag1pnPzaiQhpW7c3RbcqqzvzzVu+L8gfqMp/8IM2MQtSiqaCxrrcfu8I8rMA==", + "license": "MIT" + }, + "node_modules/cookie": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-1.1.1.tgz", + "integrity": "sha512-ei8Aos7ja0weRpFzJnEA9UHJ/7XQmqglbRwnf2ATjcB9Wq874VKH9kfjjirM6UhU2/E5fFYadylyhFldcqSidQ==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/csstype": { + "version": "3.2.3", + "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.2.3.tgz", + "integrity": "sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/detect-libc": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.1.2.tgz", + "integrity": "sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==", + "license": "Apache-2.0", + "optional": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/eciesjs": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/eciesjs/-/eciesjs-0.5.0.tgz", + "integrity": "sha512-s0J9SEVYAEPg7J63GFMApLYzPH9VNIQIyC6s15JpnqVc0TqcKWdbgFlnAweEBRyMmko2dcs2sfC83Hj4J43tuA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@ecies/ciphers": "^0.2.6", + "@noble/ciphers": "^1.3.0", + "@noble/curves": "^1.9.7", + "@noble/hashes": "^1.8.0" + }, + "engines": { + "bun": ">=1", + "deno": ">=2.7.10", + "node": ">=16" + } + }, + "node_modules/iceberg-js": { + "version": "0.8.1", + "resolved": "https://registry.npmjs.org/iceberg-js/-/iceberg-js-0.8.1.tgz", + "integrity": "sha512-1dhVQZXhcHje7798IVM+xoo/1ZdVfzOMIc8/rgVSijRK38EDqOJoGula9N/8ZI5RD8QTxNQtK/Gozpr+qUqRRA==", + "license": "MIT", + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/jose": { + "version": "6.2.15", + "resolved": "https://registry.npmjs.org/jose/-/jose-6.2.15.tgz", + "integrity": "sha512-qdF6ewcZARtef63fJ9AKKZPgxw+t7USH6HLXYcD4CrdmSvDp79rpJSPFEKc90QBeGS63u1KQtN2MZQHC0yDIzA==", + "dev": true, + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/panva" + } + }, + "node_modules/nanoid": { + "version": "3.3.20", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.20.tgz", + "integrity": "sha512-uKdg2G3GNCKQn9byYOpxbGqrT2fGO5KRt5J/8b3pok8rT6qxGWF6hxMyJiEYtAf+FVyYuD9hRaDqX5uPFYJ4ZQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "bin": { + "nanoid": "bin/nanoid.cjs" + }, + "engines": { + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" + } + }, + "node_modules/next": { + "version": "16.4.4", + "resolved": "https://registry.npmjs.org/next/-/next-16.4.4.tgz", + "integrity": "sha512-Hu4pOw2x0RQ0TQabNWbpsNg/3+SZf+rLQwvfhBLnptv98GS4dcIVMlfEyn9jb2/ZJDSahhnUKEs0YrfarjGX3A==", + "license": "MIT", + "dependencies": { + "@next/env": "16.4.4", + "@swc/helpers": "0.5.23", + "baseline-browser-mapping": "^2.9.19", + "caniuse-lite": "^1.0.30001579", + "postcss": "8.5.23", + "styled-jsx": "5.1.6" + }, + "bin": { + "next": "dist/bin/next" + }, + "engines": { + "node": ">=20.9.0" + }, + "optionalDependencies": { + "@next/swc-darwin-arm64": "16.4.4", + "@next/swc-darwin-x64": "16.4.4", + "@next/swc-linux-arm64-gnu": "16.4.4", + "@next/swc-linux-arm64-musl": "16.4.4", + "@next/swc-linux-x64-gnu": "16.4.4", + "@next/swc-linux-x64-musl": "16.4.4", + "@next/swc-win32-arm64-msvc": "16.4.4", + "@next/swc-win32-x64-msvc": "16.4.4", + "sharp": "^0.35.5" + }, + "peerDependencies": { + "@opentelemetry/api": "^1.1.0", + "@playwright/test": "^1.51.1", + "babel-plugin-react-compiler": "*", + "react": "^18.2.0 || 19.0.0-rc-de68d2f4-20241204 || ^19.0.0", + "react-dom": "^18.2.0 || 19.0.0-rc-de68d2f4-20241204 || ^19.0.0", + "sass": "^1.3.0" + }, + "peerDependenciesMeta": { + "@opentelemetry/api": { + "optional": true + }, + "@playwright/test": { + "optional": true + }, + "babel-plugin-react-compiler": { + "optional": true + }, + "sass": { + "optional": true + } + } + }, + "node_modules/picocolors": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", + "license": "ISC" + }, + "node_modules/postcss": { + "version": "8.5.23", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.23.tgz", + "integrity": "sha512-g50586zr4bZmwFiTlflMu8E0bDTb5I5gertgwAKmsdUlTQIhZtunzUlD1WSzwcVWPoAVpsrA6vlfCD7oXvRwgg==", + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "dependencies": { + "nanoid": "^3.3.16", + "picocolors": "^1.1.1", + "source-map-js": "^1.2.1" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "node_modules/react": { + "version": "19.3.1", + "resolved": "https://registry.npmjs.org/react/-/react-19.3.1.tgz", + "integrity": "sha512-QNhWdt7nrgVWWQG58QuGsAR3jv3Hbe4mb4vz7w2csnHavciZJgda1CPNaldF6eVxv90ud3jUXpKlHL69gO38yw==", + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/react-dom": { + "version": "19.3.1", + "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-19.3.1.tgz", + "integrity": "sha512-Y0bARz53lhEC1NMCASs0/j+faB/zqt3R8hpvg1e8+61ZVJ4UL0UdC4cBbXfZMcIuhrfgeILTLe+ZeBCavQPtKQ==", + "license": "MIT", + "dependencies": { + "scheduler": "^0.28.0" + }, + "peerDependencies": { + "react": "^19.3.1" + } + }, + "node_modules/scheduler": { + "version": "0.28.0", + "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.28.0.tgz", + "integrity": "sha512-juorfCmIkIw8tT+p5BXSm6PJjQF/ycEYmKyzURCIt/RaZIhL+PulbQ9Yu2z1HdOJDdqDTlxA1+xKBmHXJsczAw==", + "license": "MIT" + }, + "node_modules/semver": { + "version": "7.8.6", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.8.6.tgz", + "integrity": "sha512-9lpSSU4Mly3mrtruwLs1eLK6+gzbzqeBFwRNjIjE+9LuDpWdYctrQlQ3ej1Ilgi7gknpsTRnPoLP8DpCHqHIJw==", + "license": "ISC", + "optional": true, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/sharp": { + "version": "0.35.5", + "resolved": "https://registry.npmjs.org/sharp/-/sharp-0.35.5.tgz", + "integrity": "sha512-Ywn4OnzGukp7CDMrp08RQ50YKmuwG47brZgIVPTvBaaAfQlRlygrRqSrxdCiL9M+LlzLBiJ68IR1QqvzHyjC7g==", + "license": "Apache-2.0", + "optional": true, + "dependencies": { + "@img/colour": "^1.1.0", + "detect-libc": "^2.1.2", + "semver": "^7.8.5" + }, + "engines": { + "node": ">=20.9.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-darwin-arm64": "0.35.5", + "@img/sharp-darwin-x64": "0.35.5", + "@img/sharp-freebsd-wasm32": "0.35.5", + "@img/sharp-libvips-darwin-arm64": "1.3.4", + "@img/sharp-libvips-darwin-x64": "1.3.4", + "@img/sharp-libvips-linux-arm": "1.3.4", + "@img/sharp-libvips-linux-arm64": "1.3.4", + "@img/sharp-libvips-linux-ppc64": "1.3.4", + "@img/sharp-libvips-linux-riscv64": "1.3.4", + "@img/sharp-libvips-linux-s390x": "1.3.4", + "@img/sharp-libvips-linux-x64": "1.3.4", + "@img/sharp-libvips-linuxmusl-arm64": "1.3.4", + "@img/sharp-libvips-linuxmusl-x64": "1.3.4", + "@img/sharp-linux-arm": "0.35.5", + "@img/sharp-linux-arm64": "0.35.5", + "@img/sharp-linux-ppc64": "0.35.5", + "@img/sharp-linux-riscv64": "0.35.5", + "@img/sharp-linux-s390x": "0.35.5", + "@img/sharp-linux-x64": "0.35.5", + "@img/sharp-linuxmusl-arm64": "0.35.5", + "@img/sharp-linuxmusl-x64": "0.35.5", + "@img/sharp-webcontainers-wasm32": "0.35.5", + "@img/sharp-win32-arm64": "0.35.5", + "@img/sharp-win32-ia32": "0.35.5", + "@img/sharp-win32-x64": "0.35.5" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } + } + }, + "node_modules/source-map-js": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.2.tgz", + "integrity": "sha512-KGj/8Y43x35aZVDtt+J4mK1hoLGHULMYfSkODJNQjNDC3oW1PqPoxMwo0pLUsWM/UEGzON/NxeHywEfNXNP3Vw==", + "license": "BSD-3-Clause", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/styled-jsx": { + "version": "5.1.6", + "resolved": "https://registry.npmjs.org/styled-jsx/-/styled-jsx-5.1.6.tgz", + "integrity": "sha512-qSVyDTeMotdvQYoHWLNGwRFJHC+i+ZvdBRYosOFgC+Wg1vx4frN2/RG/NA7SYqqvKNLf39P2LSRA2pu6n0XYZA==", + "license": "MIT", + "dependencies": { + "client-only": "0.0.1" + }, + "engines": { + "node": ">= 12.0.0" + }, + "peerDependencies": { + "react": ">= 16.8.0 || 17.x.x || ^18.0.0-0 || ^19.0.0-0" + }, + "peerDependenciesMeta": { + "@babel/core": { + "optional": true + }, + "babel-plugin-macros": { + "optional": true + } + } + }, + "node_modules/supabase": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/supabase/-/supabase-3.0.0.tgz", + "integrity": "sha512-FB+V+RzXYTmCzbchaN3CUdxLPpcKzJd4RSOc/dAE6cAtI7TZE8J5OLJYXjJae9C/fbi2xxzZJLL/Y2N1zbzf9A==", + "dev": true, + "license": "MIT", + "dependencies": { + "eciesjs": "^0.5.0", + "jose": "^6.2.10" + }, + "bin": { + "supabase": "dist/supabase.js" + }, + "optionalDependencies": { + "@supabase/cli-darwin-arm64": "3.0.0", + "@supabase/cli-darwin-x64": "3.0.0", + "@supabase/cli-linux-arm64": "3.0.0", + "@supabase/cli-linux-arm64-musl": "3.0.0", + "@supabase/cli-linux-x64": "3.0.0", + "@supabase/cli-linux-x64-musl": "3.0.0", + "@supabase/cli-windows-arm64": "3.0.0", + "@supabase/cli-windows-x64": "3.0.0" + } + }, + "node_modules/tslib": { + "version": "2.8.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz", + "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==", + "license": "0BSD" + }, + "node_modules/typescript": { + "version": "5.9.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.9.3.tgz", + "integrity": "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==", + "dev": true, + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, + "node_modules/undici-types": { + "version": "6.21.0", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", + "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==", + "dev": true, + "license": "MIT" + } + } +} diff --git a/apps/portal/package.json b/apps/portal/package.json new file mode 100644 index 0000000..9f9eedb --- /dev/null +++ b/apps/portal/package.json @@ -0,0 +1,31 @@ +{ + "name": "@skillwhy/portal", + "version": "0.1.0", + "private": true, + "type": "module", + "engines": { + "node": ">=22" + }, + "scripts": { + "dev": "next dev --hostname 127.0.0.1", + "build": "next build", + "start": "next start --hostname 127.0.0.1", + "typecheck": "tsc --noEmit", + "test": "node --test test/*.test.mjs", + "test:database": "node scripts/test-database.mjs" + }, + "dependencies": { + "next": "16.4.4", + "react": "19.3.1", + "react-dom": "19.3.1", + "@supabase/supabase-js": "2.118.0", + "@supabase/ssr": "0.12.7" + }, + "devDependencies": { + "typescript": "5.9.3", + "@types/node": "22.20.5", + "@types/react": "19.3.0", + "@types/react-dom": "19.3.0", + "supabase": "3.0.0" + } +} diff --git a/apps/portal/scripts/test-database.mjs b/apps/portal/scripts/test-database.mjs new file mode 100644 index 0000000..83fa2fd --- /dev/null +++ b/apps/portal/scripts/test-database.mjs @@ -0,0 +1,235 @@ +import { randomBytes, randomUUID } from "node:crypto"; +import { readFileSync, readdirSync } from "node:fs"; +import { spawnSync } from "node:child_process"; + +// Actual PostgreSQL execution. auth.users/auth.sessions/auth.uid/auth.jwt are a +// small fixture, not a mock of PostgreSQL RLS. Hosted email/GoTrue are not tested. +const container = `skillwhy-portal-db-${randomUUID().slice(0, 8)}`; +const image = + process.env.PORTAL_TEST_POSTGRES_IMAGE || "postgres:17.11-bookworm"; +function command(args, input) { + const result = spawnSync("docker", args, { + input, + encoding: "utf8", + maxBuffer: 4 * 1024 * 1024, + }); + if (result.status !== 0) + throw new Error(result.stderr || result.stdout || "Docker command failed"); + return result.stdout.trim(); +} +function sql(input) { + return command( + [ + "exec", + "-i", + container, + "psql", + "-X", + "-v", + "ON_ERROR_STOP=1", + "-U", + "postgres", + "-A", + "-t", + ], + input, + ); +} +const admin = "10000000-0000-0000-0000-000000000001", + a = "10000000-0000-0000-0000-000000000002", + b = "10000000-0000-0000-0000-000000000003"; +const session = (id) => id.replace("10000000", "20000000"); +function as(id, body, extra = {}) { + return sql( + `begin; set local role authenticated; select set_config('request.jwt.claims', '${JSON.stringify({ sub: id, session_id: session(id), ...extra })}', true); ${body}; rollback;`, + ); +} +const assertion = (condition) => + `do $$ begin if not (${condition}) then raise exception 'ASSERTION_FAILED'; end if; end $$`; +const forbidden = (query) => + `do $$ begin begin ${query}; raise exception 'EXPECTED_DENIAL'; exception when insufficient_privilege then null; end; end $$`; +const zeroUpdates = (query) => + `do $$ declare affected integer; begin ${query}; get diagnostics affected = row_count; if affected <> 0 then raise exception 'UNEXPECTED_ROWS_UPDATED'; end if; end $$`; +const invalid = (query) => + `do $$ begin begin ${query}; raise exception 'EXPECTED_INVALID_ARGUMENT'; exception when invalid_parameter_value then null; end; end $$`; +let checks = 0; +const check = (name, fn) => { + fn(); + checks++; + console.log(`PASS ${name}`); +}; +try { + command([ + "run", + "--detach", + "--rm", + "--name", + container, + "--network", + "none", + "-e", + `POSTGRES_PASSWORD=${randomBytes(24).toString("hex")}`, + image, + ]); + for (let n = 0; n < 60; n++) { + const r = spawnSync( + "docker", + ["exec", container, "pg_isready", "-U", "postgres"], + { encoding: "utf8" }, + ); + if (r.status === 0) break; + if (n === 59) throw new Error("Postgres did not become ready"); + await new Promise((resolve) => setTimeout(resolve, 250)); + } + sql(`create role anon nologin; create role authenticated nologin; + create schema auth; + create table auth.users(id uuid primary key,email text,raw_user_meta_data jsonb not null default '{}'); + create table auth.sessions(id uuid primary key,user_id uuid references auth.users(id),not_after timestamptz); + create function auth.jwt() returns jsonb language sql stable as $$ select coalesce(nullif(current_setting('request.jwt.claims',true),''),'{}')::jsonb $$; + create function auth.uid() returns uuid language sql stable as $$ select nullif(auth.jwt()->>'sub','')::uuid $$; + grant usage on schema auth to authenticated; grant execute on function auth.jwt(),auth.uid() to authenticated;`); + const migration = readdirSync( + new URL("../supabase/migrations/", import.meta.url), + ).find((name) => name.endsWith("_portal_members.sql")); + if (!migration) throw new Error("Portal migration missing"); + sql( + readFileSync( + new URL("../supabase/migrations/" + migration, import.meta.url), + "utf8", + ), + ); + sql(`insert into auth.users(id,email,raw_user_meta_data) values + ('${admin}','admin@example.invalid','{"display_name":"Admin"}'), + ('${a}','member-a@example.invalid','{"display_name":"A"}'), + ('${b}','member-b@example.invalid','{"display_name":"B","role":"admin","status":"active"}'); + update public.member_profiles set role='admin' where id='${admin}'; + insert into auth.sessions(id,user_id) values ('${session(admin)}','${admin}'),('${session(a)}','${a}'),('${session(b)}','${b}');`); + check("registration trigger ignores user-editable role metadata", () => + sql( + assertion( + `(select role='member' from public.member_profiles where id='${b}')`, + ), + ), + ); + check( + "anonymous cannot select member data or invoke administrative RPC", + () => + sql( + `begin;set local role anon;${forbidden("perform * from public.member_profiles")};${forbidden(`perform public.portal_set_member_status('${a}','suspended')`)};rollback;`, + ), + ); + check("member sees own profile but not another member or audit history", () => + as( + a, + `${assertion("(select count(*)=1 from public.member_profiles)")};${assertion("(select count(*)=0 from public.member_audit_events)")}`, + ), + ); + check( + "member can edit own display name and cannot edit protected columns", + () => + as( + a, + `update public.member_profiles set display_name='Changed' where id='${a}';${assertion(`(select display_name='Changed' from public.member_profiles where id='${a}')`)};${forbidden(`update public.member_profiles set role='admin' where id='${a}'`)};${forbidden(`update public.member_profiles set status='active' where id='${a}'`)}`, + ), + ); + check( + "member cannot reassign identity, create profiles, or call admin RPC", + () => + as( + a, + `${forbidden(`update public.member_profiles set id='${b}' where id='${a}'`)};${forbidden(`insert into public.member_profiles(id,email) values(gen_random_uuid(),'x@example.invalid')`)};${forbidden(`perform public.portal_set_member_status('${b}','suspended')`)}`, + ), + ); + check("member cannot edit another profile through an allowed column", () => + as( + a, + `${zeroUpdates("update public.member_profiles set display_name='Hijack' where id='" + b + "'")};${assertion("(select count(*)=1 from public.member_profiles)")}`, + ), + ); + check("administrator can inspect members and cannot suspend self", () => + as( + admin, + `${assertion("(select count(*)=3 from public.member_profiles)")};${invalid(`perform public.portal_set_member_status('${admin}','suspended')`)}`, + ), + ); + sql( + `begin; set local role authenticated; select set_config('request.jwt.claims','${JSON.stringify({ sub: admin, session_id: session(admin) })}',true); select public.portal_set_member_status('${b}','suspended'); commit;`, + ); + check( + "suspension blocks existing JWT profile access and writes immediately", + () => + as( + b, + `${assertion("(select count(*)=0 from public.member_profiles)")};${zeroUpdates("update public.member_profiles set display_name='Bypass' where id='" + b + "'")};${forbidden(`perform public.portal_set_member_status('${a}','suspended')`)}`, + ), + ); + check( + "suspended member can still submit one idempotent deletion request", + () => + as( + b, + `select public.portal_request_account_deletion('Please review');select public.portal_request_account_deletion('Again');${assertion("(select count(*)=1 from public.account_deletion_requests)")};${forbidden("perform public.portal_review_account_deletion((select id from public.account_deletion_requests limit 1))")}`, + ), + ); + check( + "revoked session cannot see profiles or request deletion using old JWT", + () => { + sql(`delete from auth.sessions where user_id='${a}'`); + as( + a, + `${assertion("(select count(*)=0 from public.member_profiles)")};${forbidden("perform public.portal_request_account_deletion('stale')")}`, + ); + }, + ); + check("anonymous-auth JWT cannot access portal even with a profile", () => + as( + admin, + `${assertion("(select count(*)=0 from public.member_profiles)")};${forbidden("perform public.portal_request_account_deletion('anonymous')")}`, + { is_anonymous: true }, + ), + ); + check("timeboxed expired session cannot access portal", () => { + sql( + `update auth.sessions set not_after=now()-interval '1 minute' where user_id='${admin}'`, + ); + as( + admin, + `${assertion("(select count(*)=0 from public.member_profiles)")};${forbidden(`perform public.portal_set_member_status('${b}','active')`)}`, + ); + sql(`update auth.sessions set not_after=null where user_id='${admin}'`); + }); + check("audit records cannot be inserted or altered by administrator", () => + as( + admin, + `${forbidden("insert into public.member_audit_events(action) values('profile_updated')")};${forbidden("delete from public.member_audit_events")}`, + ), + ); + check( + "deletion review updates request without deleting the auth identity", + () => { + sql( + `insert into public.account_deletion_requests(user_id,reason) values('${b}','Test review');`, + ); + as( + admin, + `select public.portal_review_account_deletion((select id from public.account_deletion_requests where user_id='${b}' limit 1));${assertion(`(select status='reviewed' from public.account_deletion_requests where user_id='${b}' limit 1)`)}`, + ); + sql(assertion(`(select count(*)=1 from auth.users where id='${b}')`)); + }, + ); + const badFunctions = sql( + `select count(*) from pg_proc p join pg_namespace n on n.oid=p.pronamespace where n.nspname='public' and p.prosecdef;`, + ); + if (badFunctions !== "0") + throw new Error("Exposed SECURITY DEFINER function found"); + console.log( + JSON.stringify({ + checks, + postgres: image, + rlsExecuted: true, + hostedAuthOrEmailTested: false, + }), + ); +} finally { + spawnSync("docker", ["rm", "--force", container], { encoding: "utf8" }); +} diff --git a/apps/portal/src/app/account/page.tsx b/apps/portal/src/app/account/page.tsx new file mode 100644 index 0000000..6da3072 --- /dev/null +++ b/apps/portal/src/app/account/page.tsx @@ -0,0 +1,98 @@ +import Link from "next/link"; +import { activeMember } from "@/lib/member"; +import { + Header, + Footer, + Notice, + PageHeading, + dateLabel, +} from "@/components/shell"; +import { SubmitButton } from "@/components/submit-button"; +import { DeletionForm } from "@/components/deletion-form"; +import { updateProfile } from "@/app/actions"; +export const dynamic = "force-dynamic"; +export default async function Account({ + searchParams, +}: { + searchParams: Promise<{ notice?: string }>; +}) { + const { member } = await activeMember(); + const query = await searchParams; + return ( + <> +
+
+ + 프로필과 계정 상태를 확인하고 필요한 요청을 남기세요. + + +
+
+
+

프로필

+ 활성 +
+
+ + + 변경 사항 저장 +
+
+ +
+
+
+
+

ACCOUNT REQUEST

+

계정 삭제 검토

+
+
+

+ 운영자가 요청과 삭제 범위를 확인합니다. 검토 완료 표시와 실제 계정 + 삭제는 별개입니다. +

+ +
+
+