Native Shell
Native Shell:AI 生成的 UI,在你的應用中原生呈現,涵蓋每個平台。iOS、Android、macOS、Windows 與 Linux 上的應用、GPUI 應用與網頁在執行時載入已簽名、沙箱隔離的 TSX 模組並繪製 th
AI 翻譯
尚未偵測到更新。GitHub 發布版本後會顯示在這裡。
個人 GitHub 帳號下公開儲存庫的擁有者可以登入並驗證所有權,自行管理介紹,無需管理員核准。
登入並產生驗證檔案,在 30 分鐘內將其提交至此儲存庫的預設分支。其他分支或分叉儲存庫中的檔案無效。然後在下方檢查檔案,即可無需管理員核准直接管理專案。請保留檔案以維持管理權限。
如需登入,將前往登入頁面。登入後請回到此處,再次點擊所選的驗證按鈕。
在專案資料夾中執行 /nomorevibe verify,即可驗證所有權並自行管理介紹。
一分鐘完成驗證製作者的介紹僅有上面的一句話。 更多詳情請閱讀儲存庫 README。 儲存庫 README ↗
正在載入完整 README。
檢視完整 README ↗You can view a fully working demo at demo-nextjs-with-supabase.vercel.app.
Vercel deployment will guide you through creating a Supabase account and project.
After installation of the Supabase integration, all relevant environment variables will be assigned to the project so the deployment is fully functioning.
The above will also clone the Starter kit to your GitHub, you can clone that locally and develop locally.
If you wish to just develop locally and not deploy to Vercel, follow the steps below.
You'll first need a Supabase project which can be made via the Supabase dashboard
Create a Next.js app using the Supabase Starter template npx command
npx create-next-app --example with-supabase with-supabase-app
yarn create next-app --example with-supabase with-supabase-app
pnpm create next-app --example with-supabase with-supabase-app
Use cd to change into the app's directory
cd with-supabase-app
Rename .env.example to .env.local and update the following:
NEXT_PUBLIC_SUPABASE_URL=[INSERT SUPABASE PROJECT URL]
NEXT_PUBLIC_SUPABASE_PUBLISHABLE_KEY=[INSERT SUPABASE PROJECT API PUBLISHABLE OR ANON KEY]
[!NOTE] This example uses
NEXT_PUBLIC_SUPABASE_PUBLISHABLE_KEY, which refers to Supabase's new publishable key format. Both legacy anon keys and new publishable keys can be used with this variable name during the transition period. Supabase's dashboard may showNEXT_PUBLIC_SUPABASE_ANON_KEY; its value can be used in this example. See the full announcement for more information.
Both NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_PUBLISHABLE_KEY can be found in your Supabase project's API settings
You can now run the Next.js local development server:
npm run dev
The starter kit should now be running on localhost:3000.
This template comes with the default shadcn/ui style initialized. If you instead want other ui.shadcn styles, delete components.json and re-install shadcn/ui
Check out the docs for Local Development to also run Supabase locally.
To enable the queue reservation system, run the SQL migration in your Supabase project:
supabase/migrations/001_create_reservations.sqlreservations table in Database > ReplicationThe current frontend uses API polling. If migration 034 was applied fully or partially, run 035_restore_api_polling.sql to roll back that optimization. Migration 035 is also safe on a database already at 033, and safe to rerun. It preserves reservations, quotas, windows, staff assignments, and ownership protections while removing only 034's derived metadata and helper RPCs. Keep migrations 032 and 033 for the quota and exclusive-window features.
On an office's queue dashboard, first select an available window to claim it. Then choose Configure Quotas, enable its quota, and enter today's periods and positive whole-number limits. Staff can configure only their currently claimed window. Times use Asia/Manila; periods include their start and exclude their end. Quotas expire at midnight and must be configured again for the next day.
Only waiting and serving tickets count, including priority tickets and backlog from earlier periods. Completed and skipped tickets free capacity. With a quota enabled, a window accepts new tickets only during configured periods; existing tickets can still be served outside them. Reducing a quota preserves existing tickets. A window cannot be closed while serving a ticket, or when its waiting queue cannot fit within the remaining windows' limits.
Availability is refreshed through the existing server action every five seconds. Window queues refresh every ten seconds. Polling pauses in hidden/offline tabs and scheduled requests do not overlap. PostgreSQL remains authoritative for admission capacity and window ownership. Quota configuration changes are recorded in Activity Logs.
Run npm run test:quotas for validation and availability tests. Run npm run test:quotas:db with PostgreSQL binaries on PATH (or set PG_BIN to their directory) for integration and concurrency tests. The database test runner creates a temporary local cluster, applies the complete migration history with a minimal Supabase Auth fixture, and removes the cluster afterward; it does not connect to the configured application database.
Each staff account can claim one active window in its office. A window occupied by another staff account is unavailable. Switching claims the new window and releases the previous one atomically; a failed switch preserves the current assignment. Reloading the dashboard restores the claim, and another tab of the same account follows the same assignment.
The dashboard checks assignments and renews its held claim through the existing server action every fifteen seconds while visible and online. Claims expire after two minutes without renewal. Release Window and signing out release the claim immediately. Hidden/offline dashboards pause polling; a returning staff member must select an available window again if the previous claim has expired. Unclaimed or expired sessions cannot call, skip, recall, or change a quota. Existing queue tickets stay with their window when an operator switches or releases it.
Queue actions, quota writes, and direct reservation updates enforce ownership in the database. Priority tickets go first within the selected window's queue; dispatch never pulls a ticket from another window. Recall announcements are written by the authorized database RPC to window_recalls; displays read the latest recall nonce while polling every five seconds and announce changes after the initial load. Staff can view and operate their selected window's queue. Shared window-count and display controls are limited to the super admin; even the super admin must claim a window to operate its queue or quota. A window with a live staff claim cannot be closed until released or expired.
The database test suite also checks claim conflicts, concurrent switches, failed-switch rollback, direct-write restrictions, stale tabs, heartbeat renewal, expiry, and authenticated recall events.
The dashboard, quota forms, display, and activity-log UI use periodic API reads instead of Supabase Realtime channels. Display updates and recall announcements may take up to five seconds; window occupancy may take up to fifteen seconds to refresh. All mutations still validate the current state in PostgreSQL, so a stale browser view cannot steal an occupied window or exceed a quota.
Apply 035_restore_api_polling.sql to the application database and reload the frontend to finish the rollback. It restores migration 033's combined assignment read/renew behavior and removes migration 034's optimization tables, triggers, helper functions, and added quota publication membership in one transaction. The historical 034 migration remains in source control so the upgrade/rollback sequence is reproducible. Run npm run test:quotas for quota validation and npm run test:quotas:db for integration, concurrency, and rollback preservation tests.
Please file feedback and issues over on the Supabase GitHub org.