BikeControl (SwiftControl)
使用 Zwift Click、Zwift Play、Shimano Di2 或任何藍牙控制器,搭配 MyWhoosh、Rouvy、Zwift 等。iOS、Android、Windows、macOS 均可免費試用。
AI 翻译
尚未检测到更新。GitHub 发布版本后会显示在这里。
个人 GitHub 账号下公开仓库的所有者可以登录并验证所有权,自行管理介绍,无需管理员批准。
登录并生成验证文件,在 30 分钟内将其提交到此仓库的默认分支。其他分支或分叉仓库中的文件无效。然后在下方检查文件,即可无需管理员批准直接管理项目。请保留文件以维持管理权限。
如需登录,将前往登录页面。登录后请回到此处,再次点击所选的验证按钮。
在项目文件夹中运行 /nomorevibe verify,即可验证所有权并自行管理介绍。
一分钟完成验证制作者的介绍仅有上面的一句话。 更多详情请阅读仓库 README。 仓库 README ↗
正在加载完整 README。
查看完整 README ↗Personal installable PWA. Four exercises in strict rotation (Push-ups, Squats, Crunches, Run). Each exercise's target goes up one step every time that exercise is completed. Tracks streaks, backlog (actual minus target, all time), lifetime totals, history and charts.
TypeScript (strict), Vite, Vitest. No framework, no runtime dependencies. Data lives in the browser's localStorage.
npm install
npm run dev # local dev server
npm test # vitest
npm run typecheck
npm run build # typecheck + production build into dist/
Pushing to master redeploys on Vercel (framework preset: Vite, output dist).
| File | Job |
|---|---|
src/config.ts | The routine (PLAN) and tuning numbers. The one file to edit for most changes. |
src/types.ts | Data shapes. |
src/logic.ts | All rules, pure functions, no DOM or storage. Everything shown is derived from the log. |
src/store.ts | Persistence, undo snapshots, import and export. Storage is injected so tests use a fake. |
src/views.ts | Screens as pure functions returning HTML. |
src/html.ts, src/format.ts | Small markup and formatting helpers shared by the views. |
src/sync.ts | Cloud sync (Supabase). planSync is the pure decision logic and is unit tested. |
src/push.ts | Web Push subscription for the daily reminder. |
supabase/functions/wt-remind/ | Hourly reminder function. Deployed copy lives in the Supabase project; redeploy after editing. |
src/dom.ts | Form reading, toast, modal, download. |
src/app.ts | Wiring: state, rendering, the actions map (data-act="name"), events. |
src/styles.css | Theme variables at the top; per-exercise colours come from PLAN. |
public/ | Service worker (network first), manifest, icons. |
TEMPLATE in config.ts only feeds the first-run "four-exercise rotation" option and defaults for older saved data.logic.ts, then add a test in logic.test.ts.actions in app.ts and a data-act in the view.storageKey or snapshotKey in config.ts: they match the data already on the phone.iPhone: open the site in Safari, Share, Add to Home Screen. Android: Chrome menu, Install app. It must be the browser itself, not a link opened inside another app. The app also shows an install card under Backup.
Data is per browser. Use Backup > Download file or Copy as text now and then. The app also keeps the last few states automatically (Backup > Automatic snapshots).
Tables, all prefixed wt_: wt_state (one JSON document per user), wt_push_subscriptions, wt_config (VAPID private key, no client access). Row-level security allows only the owner's email. An hourly pg_cron job calls the wt-remind edge function. Sync is last-write-wins with a prompt when both sides changed; the phone copy always works offline.
Public values (project URL, publishable key, VAPID public key) are in CLOUD in src/config.ts.