@wix/himalaya-cli 0.1750.0 → 0.1752.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (185) hide show
  1. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/dev-server/src/app-config.d.ts +1 -0
  2. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/dev-server/src/app-module.d.ts +3 -0
  3. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/dev-server/src/builder.d.ts +3 -0
  4. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/ts/src/define-app.d.ts +16 -1
  5. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/ts/src/himi-package.d.ts +478 -0
  6. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/ts/src/host-compatibility.d.ts +56 -0
  7. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/ts/src/icon-catalog.generated.d.ts +1 -1
  8. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/ts/src/schema.d.ts +4 -0
  9. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/ts/src/site-shell.d.ts +154 -7
  10. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/ts/src/validator.d.ts +3 -0
  11. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/auth-providers/wix/src/index.d.ts +1 -1
  12. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/auth-providers/wix/src/native-engine.d.ts +49 -3
  13. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/flows/auth/src/copy.generated.d.ts +16 -1
  14. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/flows/auth/src/feedback.d.ts +1 -1
  15. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/flows/screens/src/index.d.ts +2 -0
  16. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/flows/screens/src/podcast-service.d.ts +105 -0
  17. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/flows/screens/src/podcast.d.ts +116 -0
  18. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/auth.mjs +27 -2
  19. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/core.mjs +326 -13
  20. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/screens.mjs +757 -83
  21. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/sdui.mjs +156 -0
  22. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/wix-auth/worker.mjs +133 -13
  23. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/wix-auth.mjs +139 -13
  24. package/dist/browser-plane/assets.json +5 -5
  25. package/dist/browser-plane/preview-deferred/{b40ea5d0d6251898ff5617139fde8be008dd11e99a70b14c1052093685401700.bin → 2671d1cadb15daa5e59440f4c924e30c221ab3d405e8a56a0ab1cdbe4764af3d.bin} +1 -1
  26. package/dist/browser-plane/sw.js +7 -7
  27. package/dist/cli.mjs +37219 -33014
  28. package/dist/preview-assets.generated.bin +0 -0
  29. package/guides/app-config.md +1 -1
  30. package/guides/component-reference.json +1 -1
  31. package/guides/component-reference.md +4 -0
  32. package/guides/designing-himi-screens.md +7 -0
  33. package/guides/getting-started.md +2 -0
  34. package/guides/headless-loop.md +1 -1
  35. package/guides/himi-json-output.md +25 -3
  36. package/guides/himi-skill.md +2 -0
  37. package/guides/index.json +6 -0
  38. package/guides/push-cli-onboarding.md +13 -0
  39. package/guides/qa-builds.md +15 -2
  40. package/guides/recipe-podcast.md +149 -0
  41. package/guides/releasing-with-himi-serve.md +51 -0
  42. package/guides/store-submission.md +46 -1
  43. package/guides/tier-5-add-a-screen.md +16 -2
  44. package/guides/wix-business-context.md +29 -0
  45. package/guides/wix-platform-usage.md +7 -2
  46. package/package.json +10 -10
  47. package/template-icons/fitness-gym.png +0 -0
  48. package/templates/beauty-salon/dev/index.ts +1 -1
  49. package/templates/beauty-salon/l10n/en.json +1 -1
  50. package/templates/beauty-salon/tier5-src/_shared/program-fields.ts +16 -0
  51. package/templates/beauty-salon/tier5-src/_shared/programs-section.ts +5 -8
  52. package/templates/beauty-salon/tier5-src/himi-branded-lite-agenda/index.ts +37 -4
  53. package/templates/branded-lite/dev/index.ts +101 -1
  54. package/templates/branded-lite/l10n/en.json +22 -1
  55. package/templates/branded-lite/l10n/es.json +22 -0
  56. package/templates/branded-lite/l10n/fr.json +18 -0
  57. package/templates/branded-lite/l10n/he.json +15 -0
  58. package/templates/branded-lite/tier5-src/_shared/program-fields.ts +16 -0
  59. package/templates/branded-lite/tier5-src/_shared/programs-section.ts +5 -8
  60. package/templates/branded-lite/tier5-src/himi-branded-lite-agenda/index.ts +37 -4
  61. package/templates/branded-lite/tier5-src/himi-branded-lite-podcasts/index.ts +14 -234
  62. package/templates/brandy/README.md +33 -0
  63. package/templates/brandy/config.ts +51 -7
  64. package/templates/brandy/dev/index.ts +23 -9
  65. package/templates/community-club/l10n/en.json +1 -1
  66. package/templates/community-club/tier5-src/_shared/program-fields.ts +16 -0
  67. package/templates/community-club/tier5-src/_shared/programs-section.ts +5 -8
  68. package/templates/events-meetups/l10n/en.json +1 -1
  69. package/templates/events-meetups/tier5-src/_shared/program-fields.ts +16 -0
  70. package/templates/events-meetups/tier5-src/_shared/programs-section.ts +5 -8
  71. package/templates/fitness-gym/README.md +53 -0
  72. package/templates/fitness-gym/config.ts +560 -0
  73. package/templates/fitness-gym/dev/index.ts +25787 -0
  74. package/templates/fitness-gym/himalaya.content.json +64 -0
  75. package/templates/fitness-gym/himalaya.template.json +15 -0
  76. package/templates/fitness-gym/icon.png +0 -0
  77. package/templates/fitness-gym/platforms.json +1 -0
  78. package/templates/fitness-gym/tier5-src/_shared/app-locale.ts +61 -0
  79. package/templates/fitness-gym/tier5-src/_shared/booking-location.ts +147 -0
  80. package/templates/fitness-gym/tier5-src/_shared/booking-session.ts +224 -0
  81. package/templates/fitness-gym/tier5-src/_shared/branded-lite-hosted.ts +280 -0
  82. package/templates/fitness-gym/tier5-src/_shared/branded-load-state.ts +109 -0
  83. package/templates/fitness-gym/tier5-src/_shared/business-chat-copy.ts +40 -0
  84. package/templates/fitness-gym/tier5-src/_shared/business-chat-history.ts +51 -0
  85. package/templates/fitness-gym/tier5-src/_shared/business-chat-message-model.ts +177 -0
  86. package/templates/fitness-gym/tier5-src/_shared/business-chat-model.ts +56 -0
  87. package/templates/fitness-gym/tier5-src/_shared/business-chat-presenter.ts +576 -0
  88. package/templates/fitness-gym/tier5-src/_shared/business-chat-transport.ts +148 -0
  89. package/templates/fitness-gym/tier5-src/_shared/collection-contract.ts +228 -0
  90. package/templates/fitness-gym/tier5-src/_shared/collection-query.ts +193 -0
  91. package/templates/fitness-gym/tier5-src/_shared/collection-service.ts +400 -0
  92. package/templates/fitness-gym/tier5-src/_shared/detail-presence.ts +51 -0
  93. package/templates/fitness-gym/tier5-src/_shared/engine-intl.ts +523 -0
  94. package/templates/fitness-gym/tier5-src/_shared/himi-account.ts +194 -0
  95. package/templates/fitness-gym/tier5-src/_shared/himi-booking-saved.ts +88 -0
  96. package/templates/fitness-gym/tier5-src/_shared/himi-bookings.ts +318 -0
  97. package/templates/fitness-gym/tier5-src/_shared/himi-copy.ts +116 -0
  98. package/templates/fitness-gym/tier5-src/_shared/himi-media.ts +29 -0
  99. package/templates/fitness-gym/tier5-src/_shared/himi-store.ts +7 -0
  100. package/templates/fitness-gym/tier5-src/_shared/himi-text.ts +24 -0
  101. package/templates/fitness-gym/tier5-src/_shared/host-events.ts +66 -0
  102. package/templates/fitness-gym/tier5-src/_shared/hosted-checkout.ts +70 -0
  103. package/templates/fitness-gym/tier5-src/_shared/iap-attendance-form.ts +106 -0
  104. package/templates/fitness-gym/tier5-src/_shared/iap-attendance-purchase.ts +216 -0
  105. package/templates/fitness-gym/tier5-src/_shared/iap-attendance.ts +38 -0
  106. package/templates/fitness-gym/tier5-src/_shared/iap-worker.ts +127 -0
  107. package/templates/fitness-gym/tier5-src/_shared/inbox-rooms.ts +68 -0
  108. package/templates/fitness-gym/tier5-src/_shared/local-preferences.ts +38 -0
  109. package/templates/fitness-gym/tier5-src/_shared/member-access.ts +63 -0
  110. package/templates/fitness-gym/tier5-src/_shared/member-account-routes.ts +52 -0
  111. package/templates/fitness-gym/tier5-src/_shared/member-bookings.ts +107 -0
  112. package/templates/fitness-gym/tier5-src/_shared/member-screen.ts +99 -0
  113. package/templates/fitness-gym/tier5-src/_shared/notification-target.ts +141 -0
  114. package/templates/fitness-gym/tier5-src/_shared/offset-page.ts +10 -0
  115. package/templates/fitness-gym/tier5-src/_shared/online-actions.ts +76 -0
  116. package/templates/fitness-gym/tier5-src/_shared/owner-load-error.ts +348 -0
  117. package/templates/fitness-gym/tier5-src/_shared/payment-setup.ts +6 -0
  118. package/templates/fitness-gym/tier5-src/_shared/pricing-plan-display.ts +64 -0
  119. package/templates/fitness-gym/tier5-src/_shared/program-description.ts +11 -0
  120. package/templates/fitness-gym/tier5-src/_shared/program-fields.ts +16 -0
  121. package/templates/fitness-gym/tier5-src/_shared/program-standing.ts +46 -0
  122. package/templates/fitness-gym/tier5-src/_shared/rich-body.ts +78 -0
  123. package/templates/fitness-gym/tier5-src/_shared/rich-content-link.ts +34 -0
  124. package/templates/fitness-gym/tier5-src/_shared/sign-in-sheet.ts +18 -0
  125. package/templates/fitness-gym/tier5-src/_shared/staff-name.ts +18 -0
  126. package/templates/fitness-gym/tier5-src/_shared/weekly-goal.ts +107 -0
  127. package/templates/fitness-gym/tier5-src/_shared/wix-bi.ts +85 -0
  128. package/templates/fitness-gym/tier5-src/_shared/wix-member-links.ts +114 -0
  129. package/templates/fitness-gym/tier5-src/_shared/wix-service-price.ts +146 -0
  130. package/templates/fitness-gym/tier5-src/business-chat/index.ts +732 -0
  131. package/templates/fitness-gym/tier5-src/business-contact/index.ts +6 -0
  132. package/templates/fitness-gym/tier5-src/himi-booking-account/index.ts +267 -0
  133. package/templates/fitness-gym/tier5-src/himi-booking-bookings/index.ts +468 -0
  134. package/templates/fitness-gym/tier5-src/himi-booking-service/index.ts +1190 -0
  135. package/templates/fitness-gym/tier5-src/himi-booking-services/index.ts +791 -0
  136. package/templates/fitness-gym/tier5-src/himi-booking-time/index.ts +1729 -0
  137. package/templates/fitness-gym/tier5-src/himi-branded-lite-agenda/index.ts +988 -0
  138. package/templates/fitness-gym/tier5-src/himi-branded-lite-member-programs/index.ts +656 -0
  139. package/templates/fitness-gym/tier5-src/himi-branded-lite-notifications/index.ts +256 -0
  140. package/templates/fitness-gym/tier5-src/himi-branded-lite-plans/index.ts +495 -0
  141. package/templates/fitness-gym/tier5-src/himi-branded-lite-program/facts.ts +52 -0
  142. package/templates/fitness-gym/tier5-src/himi-branded-lite-program/index.ts +845 -0
  143. package/templates/fitness-gym/tier5-src/himi-fitcoach-goal/index.ts +190 -0
  144. package/templates/fitness-gym/tier5-src/himi-fitcoach-home/index.ts +619 -0
  145. package/templates/fitness-gym/tier5-src/himi-store-account/index.ts +1007 -0
  146. package/templates/fitness-gym/tier5-src/wix-spaces-my-subscriptions/index.ts +84 -0
  147. package/templates/fitness-gym/tier5-src/wix-spaces-subscription-detail/index.ts +139 -0
  148. package/templates/fitness-gym/tokens.json +414 -0
  149. package/templates/gym-fitness/dev/index.ts +1 -1
  150. package/templates/gym-fitness/l10n/en.json +1 -1
  151. package/templates/gym-fitness/tier5-src/_shared/program-fields.ts +16 -0
  152. package/templates/gym-fitness/tier5-src/_shared/programs-section.ts +5 -8
  153. package/templates/gym-fitness/tier5-src/himi-branded-lite-agenda/index.ts +37 -4
  154. package/templates/medical-services/dev/index.ts +2 -1
  155. package/templates/medical-services/tier5-src/himi-booking-account/index.ts +16 -1
  156. package/templates/nonprofit-cause/l10n/en.json +1 -1
  157. package/templates/nonprofit-cause/tier5-src/_shared/program-fields.ts +16 -0
  158. package/templates/nonprofit-cause/tier5-src/_shared/programs-section.ts +5 -8
  159. package/templates/personal-fitness-trainer/dev/index.ts +2 -2
  160. package/templates/personal-fitness-trainer/tier5-src/himi-branded-lite-agenda/index.ts +37 -4
  161. package/templates/podcast-creator/dev/index.ts +100 -0
  162. package/templates/podcast-creator/l10n/en.json +22 -1
  163. package/templates/podcast-creator/l10n/es.json +22 -0
  164. package/templates/podcast-creator/l10n/fr.json +18 -0
  165. package/templates/podcast-creator/l10n/he.json +15 -0
  166. package/templates/podcast-creator/tier5-src/_shared/program-fields.ts +16 -0
  167. package/templates/podcast-creator/tier5-src/_shared/programs-section.ts +5 -8
  168. package/templates/podcast-creator/tier5-src/himi-branded-lite-podcasts/index.ts +14 -234
  169. package/templates/portfolio-creative/l10n/en.json +1 -1
  170. package/templates/portfolio-creative/tier5-src/_shared/program-fields.ts +16 -0
  171. package/templates/portfolio-creative/tier5-src/_shared/programs-section.ts +5 -8
  172. package/templates/restaurant/l10n/en.json +1 -1
  173. package/templates/restaurant/tier5-src/_shared/program-fields.ts +16 -0
  174. package/templates/restaurant/tier5-src/_shared/programs-section.ts +5 -8
  175. package/templates/retail-store/l10n/en.json +1 -1
  176. package/templates/retail-store/tier5-src/_shared/program-fields.ts +16 -0
  177. package/templates/retail-store/tier5-src/_shared/programs-section.ts +5 -8
  178. package/templates/salon-spa/dev/index.ts +1 -1
  179. package/templates/salon-spa/tier5-src/himi-booking-account/index.ts +16 -1
  180. package/templates/salon-spa/tier5-src/himi-branded-lite-agenda/index.ts +37 -4
  181. package/templates/yoga-studio/dev/index.ts +1 -1
  182. package/templates/yoga-studio/l10n/en.json +1 -1
  183. package/templates/yoga-studio/tier5-src/_shared/program-fields.ts +16 -0
  184. package/templates/yoga-studio/tier5-src/_shared/programs-section.ts +5 -8
  185. package/templates/yoga-studio/tier5-src/himi-branded-lite-agenda/index.ts +37 -4
@@ -0,0 +1,16 @@
1
+ // How a worker reads an Online Program's lifecycle and name. Wix returns them in more than one
2
+ // shape (v3 `status` or `state`; `description.title`, `settings.title`, a flat `title` or
3
+ // `details.title`), so every screen that lists programs reads them here, the same way.
4
+ import type { WixProgram } from "@himalaya/wix-online-programs";
5
+ import { cleanTitle } from "./himi-text.js";
6
+
7
+ export function programStatus(p: WixProgram): string {
8
+ return (p.status ?? p.state ?? "").toUpperCase();
9
+ }
10
+ export const isProgramEnded = (p: WixProgram): boolean => programStatus(p) === "ENDED" || programStatus(p) === "FINISHED";
11
+ export const isProgramDraft = (p: WixProgram): boolean => programStatus(p) === "DRAFT";
12
+
13
+ /** The program's own name, cleaned; "" when it has none (the caller picks its own fallback word). */
14
+ export function programName(p: WixProgram): string {
15
+ return cleanTitle(p.description?.title ?? p.settings?.title ?? p.title ?? p.details?.title);
16
+ }
@@ -22,7 +22,8 @@ import { iapPriceFields, onlineProgramItem, type IapPollDirective } from "@himal
22
22
  import { createIapCommerce } from "@himalaya/iap-checkout";
23
23
  import { createCollectionQuery, type CollectionPage, type CollectionQueryState } from "./collection-query.js";
24
24
  import { memberAccess, memberAccessChanged, memberAccessDenied, type MemberAccess } from "./member-access.js";
25
- import { cleanTitle, initials } from "./himi-text.js";
25
+ import { initials } from "./himi-text.js";
26
+ import { isProgramDraft, isProgramEnded, programName } from "./program-fields.js";
26
27
  import { programImage } from "./himi-media.js";
27
28
  import { descriptionBody } from "./rich-body.js";
28
29
  import { programDescription } from "./program-description.js";
@@ -125,19 +126,15 @@ export interface State {
125
126
  const full = (p: WixProgram): WixProgramFull => p as WixProgramFull;
126
127
 
127
128
  function programTitle(p: WixProgram): string {
128
- return cleanTitle(p.description?.title ?? p.settings?.title ?? p.title ?? p.details?.title)
129
- || copyParam("memberPrograms.programFallbackName", "Program");
129
+ return programName(p) || copyParam("memberPrograms.programFallbackName", "Program");
130
130
  }
131
131
  function programDetails(p: WixProgram): string {
132
132
  // The body may be a Ricos document or serialized text: read it the way the catalog and detail do.
133
133
  const raw = descriptionBody(programDescription(p)).bodyText.replace(/\s+/g, " ").trim();
134
134
  return raw.length > 140 ? `${raw.slice(0, 139).trimEnd()}…` : raw;
135
135
  }
136
- function programStatus(p: WixProgram): string {
137
- return (p.status ?? p.state ?? "").toUpperCase();
138
- }
139
- const isEnded = (p: WixProgram) => programStatus(p) === "ENDED" || programStatus(p) === "FINISHED";
140
- const isDraft = (p: WixProgram) => programStatus(p) === "DRAFT";
136
+ const isEnded = isProgramEnded;
137
+ const isDraft = isProgramDraft;
141
138
  function accessType(p: WixProgram): string {
142
139
  return (full(p).restrictions?.accessType ?? "PUBLIC").toUpperCase();
143
140
  }
@@ -0,0 +1,53 @@
1
+ # __HIMI_APP_NAME__ — from the `fitness-gym` template
2
+
3
+ An online fitness coach / gym app over a real Wix site, dark with one lime accent: a Home that answers a member (next session, challenge progress ring, this week's bookings, plan, quick actions) and a visitor (a photo hero with one CTA); workout goals that explain the goal and book its first personal session; the class schedule in a month calendar with an All · Booked filter; Workouts — the shared Branded Lite booking flow; Challenges (Online Programs) with progress; Membership (Pricing Plans) and My plans; Chat with the coach (the Wix Inbox chat); About and Profile. Boots as a VISITOR; booking, joining, buying a plan and the chat open Branded Lite's sign-in form as a sheet.
4
+
5
+ Everything here is now yours to edit — screens in `dev/`, logic in `tier5-src/`,
6
+ identity and navigation in `config.ts`, look and feel in `tokens.json`.
7
+
8
+ ## Point at your Wix site
9
+
10
+ Your **Wix Headless `clientId` binds the data** — the visitor token minted from it already
11
+ names your site, so reads need nothing else. Set these before `himi build` / preview so calls
12
+ hit YOUR site (the placeholders are not a real backend):
13
+
14
+ export WIX_CLIENT_ID="<headless-oauth-client-id>"
15
+ export WIX_SITE_URL="https://your-site.wixsite.com/…"
16
+ export WIX_SITE_ID="<metasite-id>"
17
+
18
+ `WIX_SITE_ID` is the site that client belongs to. The member login takes it from the environment
19
+ while `WIX_CLIENT_ID` is the client the config uses. A native build needs it for member sign-up on
20
+ a CAPTCHA-protected site, push registration and in-app purchases.
21
+
22
+ Full details, including how to ship a binary a customer can install against their own
23
+ site: `himi docs branded-lite-site-binding`.
24
+
25
+ ## The loop
26
+
27
+ himi build # compile tier5-src/* -> dist/bundles
28
+ himi validate # screens, bindings and worker boot
29
+ himi render <screenId> --tree # render a screen right here, no device needed
30
+ himi test # exercise every action your screens declare
31
+ himi login --browser --target wix # sign in with your Wix account (once)
32
+ # no browser? export WIX_API_KEY, then himi login --wix --target wix
33
+ himi push --draft # publish a DRAFT release + get preview links
34
+
35
+ Build, validate, render and test run entirely on your machine. Only `login` and
36
+ `push` reach Wix. No per-app install is needed: the CLI ships the `@wix/himalaya`
37
+ runtime it compiles against.
38
+
39
+ ## Pattern index — where to look for each recipe
40
+
41
+ | Pattern | Screens |
42
+ |---|---|
43
+ | One Home for a member and a visitor (sections that collapse fully) | himi_fit_home |
44
+ | A progress ring from real data (Gauge) | himi_fit_home your progress |
45
+ | A photo hero with a gradient scrim (Shape fillGradient) | himi_fit_home hero, coach |
46
+ | App-owned CMS content with sample rows (workout goals) | himi_fit_home goals, himi_fit_goal |
47
+ | A shared screen restyled by node id (month calendar, filter) | himi_agenda |
48
+ | Reusing a shared screen in your own words (stock-string copy rewrite) | himi_services, himi_service, himi_time, himi_bookings |
49
+ | Your own design over a shared worker | himi_plans, himi_member_programs, himi_program, himi_account |
50
+ | Member chat with the business (Wix Inbox) | himi_business_chat |
51
+
52
+ Guides: `himi docs recipe-dynamic-list`, `himi docs tier-5-add-a-screen`,
53
+ `himi docs designing-himi-screens`. Seed references: `himi agent-init`.
@@ -0,0 +1,560 @@
1
+ // Your app's configuration — identity, auth, navigation, capabilities and tokens.
2
+ // Inspect the live values any time with `himi context`; see `himi docs app-config`.
3
+ import { defineApp } from "@himalaya/core";
4
+ import { WixConsumerAuthProvider } from "@himalaya/wix-auth";
5
+ import { ConsoleTelemetrySink } from "@himalaya/telemetry-console";
6
+
7
+ export default defineApp({
8
+ id: "__HIMI_APP_DOTID__",
9
+ name: "__HIMI_APP_NAME__",
10
+ bundleId: "__HIMI_APP_DOTID__",
11
+ applicationId: "__HIMI_APP_DOTID__",
12
+ // Placeholders — an over-the-air app never consumes these. Leave as-is.
13
+ schemaPackage: "@example/__HIMI_APP_SLUG__-schema",
14
+ schemaPackageRange: { min: 9900, max: 9909 },
15
+ // Placeholders — only a local server would read these. Leave as-is.
16
+ ports: { devServer: 8190, web: 5390 },
17
+ auth: WixConsumerAuthProvider({
18
+ // POINT THESE AT YOUR SITE — set WIX_CLIENT_ID (a public headless OAuth client id)
19
+ // and WIX_SITE_URL (your live site URL). The placeholders below are NOT a real
20
+ // backend; the app boots but reads nothing until you set them. The site needs
21
+ // Wix Bookings; Online Programs, Pricing Plans and the Wix Inbox chat are optional.
22
+ // Create the workout goals collection with `himi cms create`, then `himi cms seed`.
23
+ clientId: process.env.WIX_CLIENT_ID ?? "YOUR_WIX_CLIENT_ID",
24
+ siteUrl: process.env.WIX_SITE_URL ?? "https://your-site.example.com",
25
+ // The OAuth redirect must be ALLOWLISTED on the headless client in `clientId`.
26
+ redirectUri: process.env.WIX_REDIRECT_URI ?? "himalaya-__HIMI_APP_SLUG__://oauth/callback",
27
+ bootAsVisitor: true,
28
+ preserveVisitorOnSignOut: true,
29
+ }),
30
+ telemetry: ConsoleTelemetrySink(),
31
+ serverUrls: {
32
+ screen: "http://localhost:8190/v1",
33
+ actions: "http://localhost:8190/v1/actions",
34
+ sync: "http://localhost:8190/v1/sync",
35
+ },
36
+ capabilities: ["wix_api","local_database","open_url","share","secure_storage","wix_platform","app_info","iap","wix_chat","calendar","wix_cashier"],
37
+ designTokensPath: "./tokens.json",
38
+ navigation: {
39
+ "navKind": "responsive",
40
+ "scheme": "himalaya-__HIMI_APP_SLUG__",
41
+ "deepLinkPatterns": [],
42
+ "linkableScreens": [
43
+ {
44
+ "screenId": "himi_fit_home",
45
+ "isPublic": true,
46
+ "paramKeys": [],
47
+ "parentScreenId": "",
48
+ "tabId": "home"
49
+ },
50
+ {
51
+ "screenId": "himi_fit_goal",
52
+ "isPublic": true,
53
+ "paramKeys": [
54
+ "id"
55
+ ],
56
+ "parentScreenId": "himi_fit_home",
57
+ "tabId": "home"
58
+ },
59
+ {
60
+ "screenId": "himi_fit_about",
61
+ "isPublic": true,
62
+ "paramKeys": [],
63
+ "parentScreenId": "himi_fit_home",
64
+ "tabId": "home"
65
+ },
66
+ {
67
+ "screenId": "himi_plans",
68
+ "isPublic": true,
69
+ "paramKeys": [],
70
+ "parentScreenId": "himi_fit_home",
71
+ "tabId": "home"
72
+ },
73
+ {
74
+ "screenId": "himi_plan",
75
+ "isPublic": true,
76
+ "paramKeys": [
77
+ "id"
78
+ ],
79
+ "parentScreenId": "himi_plans",
80
+ "tabId": "home"
81
+ },
82
+ {
83
+ "screenId": "himi_business_chat",
84
+ "isPublic": false,
85
+ "paramKeys": [],
86
+ "parentScreenId": "himi_fit_home",
87
+ "tabId": "home"
88
+ },
89
+ {
90
+ "screenId": "himi_business_contact",
91
+ "isPublic": true,
92
+ "paramKeys": [],
93
+ "parentScreenId": "himi_account",
94
+ "tabId": "profile"
95
+ },
96
+ {
97
+ "screenId": "himi_notifications",
98
+ "isPublic": false,
99
+ "paramKeys": [],
100
+ "parentScreenId": "himi_fit_home",
101
+ "tabId": "home"
102
+ },
103
+ {
104
+ "screenId": "himi_agenda",
105
+ "isPublic": true,
106
+ "paramKeys": [],
107
+ "parentScreenId": "",
108
+ "tabId": "schedule"
109
+ },
110
+ {
111
+ "screenId": "himi_services",
112
+ "isPublic": true,
113
+ "paramKeys": [
114
+ "category",
115
+ "categoryActivation"
116
+ ],
117
+ "parentScreenId": "",
118
+ "tabId": "workouts"
119
+ },
120
+ {
121
+ "screenId": "himi_service",
122
+ "isPublic": true,
123
+ "paramKeys": [
124
+ "id",
125
+ "sessionId",
126
+ "start"
127
+ ],
128
+ "parentScreenId": "himi_services",
129
+ "tabId": "workouts"
130
+ },
131
+ {
132
+ "screenId": "himi_time",
133
+ "isPublic": true,
134
+ "paramKeys": [
135
+ "id",
136
+ "course",
137
+ "start",
138
+ "sessionId"
139
+ ],
140
+ "parentScreenId": "himi_service",
141
+ "tabId": "workouts"
142
+ },
143
+ {
144
+ "screenId": "himi_member_programs",
145
+ "isPublic": true,
146
+ "paramKeys": [
147
+ "filter"
148
+ ],
149
+ "parentScreenId": "",
150
+ "tabId": "challenges"
151
+ },
152
+ {
153
+ "screenId": "himi_program",
154
+ "isPublic": true,
155
+ "paramKeys": [
156
+ "id"
157
+ ],
158
+ "parentScreenId": "himi_member_programs",
159
+ "tabId": "challenges"
160
+ },
161
+ {
162
+ "screenId": "himi_account",
163
+ "isPublic": true,
164
+ "paramKeys": [],
165
+ "parentScreenId": "",
166
+ "tabId": "profile"
167
+ },
168
+ {
169
+ "screenId": "himi_bookings",
170
+ "isPublic": false,
171
+ "paramKeys": [],
172
+ "parentScreenId": "himi_account",
173
+ "tabId": "profile"
174
+ },
175
+ {
176
+ "screenId": "himi_my_subscriptions",
177
+ "isPublic": false,
178
+ "paramKeys": [],
179
+ "parentScreenId": "himi_account",
180
+ "tabId": "profile"
181
+ },
182
+ {
183
+ "screenId": "himi_subscription",
184
+ "isPublic": false,
185
+ "paramKeys": [
186
+ "id"
187
+ ],
188
+ "parentScreenId": "himi_my_subscriptions",
189
+ "tabId": "profile"
190
+ },
191
+ {
192
+ "screenId": "himi_sign_in",
193
+ "isPublic": true,
194
+ "paramKeys": [
195
+ "mode",
196
+ "intent",
197
+ "modal",
198
+ "returnTab",
199
+ "contextName",
200
+ "returnScreenId",
201
+ "returnId",
202
+ "returnChannelId",
203
+ "authContinuation"
204
+ ],
205
+ "parentScreenId": "himi_account",
206
+ "tabId": "profile"
207
+ }
208
+ ],
209
+ "tabBar": {
210
+ "presentation": "native",
211
+ "items": [
212
+ {
213
+ "id": "home",
214
+ "screenId": "himi_fit_home",
215
+ "label": "Home",
216
+ "icon": "home",
217
+ "selectedIcon": "home_fill"
218
+ },
219
+ {
220
+ "id": "schedule",
221
+ "screenId": "himi_agenda",
222
+ "label": "Schedule",
223
+ "icon": "calendar"
224
+ },
225
+ {
226
+ "id": "workouts",
227
+ "screenId": "himi_services",
228
+ "label": "Workouts",
229
+ "icon": "play_circle",
230
+ "selectedIcon": "play_circle_fill"
231
+ },
232
+ {
233
+ "id": "challenges",
234
+ "screenId": "himi_member_programs",
235
+ "label": "Challenges",
236
+ "icon": "layers"
237
+ },
238
+ {
239
+ "id": "profile",
240
+ "screenId": "himi_account",
241
+ "label": "Profile",
242
+ "icon": "person",
243
+ "selectedIcon": "person_fill"
244
+ }
245
+ ]
246
+ }
247
+ },
248
+ // This app talks to a language model (dual LLM / remote model).
249
+ agent: {
250
+ "onDevice": {
251
+ "ios": "foundation_models",
252
+ "android": "mediapipe"
253
+ },
254
+ "remote": {
255
+ "providerId": "anthropic",
256
+ "config": {
257
+ "model": "claude-haiku-4-5"
258
+ }
259
+ },
260
+ "privateModeToggle": false
261
+ },
262
+ entities: {},
263
+ // Your app's own CMS collections (Wix Data). Create them on your site with `himi cms create`;
264
+ // see `himi docs cms-collections`. Visitors read them; your site's admins edit them.
265
+ cms: {
266
+ "collections": [
267
+ {
268
+ "id": "himi___HIMI_APP_CMS_PREFIX___goals",
269
+ "displayName": "Workout goals",
270
+ "displayField": "title",
271
+ "readRole": "ANYONE",
272
+ "fields": [
273
+ {
274
+ "key": "title",
275
+ "displayName": "Goal",
276
+ "type": "TEXT"
277
+ },
278
+ {
279
+ "key": "slug",
280
+ "displayName": "Slug",
281
+ "type": "TEXT"
282
+ },
283
+ {
284
+ "key": "order",
285
+ "displayName": "Order on Home",
286
+ "type": "NUMBER"
287
+ },
288
+ {
289
+ "key": "summary",
290
+ "displayName": "Summary",
291
+ "type": "TEXT"
292
+ },
293
+ {
294
+ "key": "whatItIs",
295
+ "displayName": "What it is",
296
+ "type": "TEXT"
297
+ },
298
+ {
299
+ "key": "step1Title",
300
+ "displayName": "Step 1 title",
301
+ "type": "TEXT"
302
+ },
303
+ {
304
+ "key": "step1Text",
305
+ "displayName": "Step 1 text",
306
+ "type": "TEXT"
307
+ },
308
+ {
309
+ "key": "step2Title",
310
+ "displayName": "Step 2 title",
311
+ "type": "TEXT"
312
+ },
313
+ {
314
+ "key": "step2Text",
315
+ "displayName": "Step 2 text",
316
+ "type": "TEXT"
317
+ },
318
+ {
319
+ "key": "step3Title",
320
+ "displayName": "Step 3 title",
321
+ "type": "TEXT"
322
+ },
323
+ {
324
+ "key": "step3Text",
325
+ "displayName": "Step 3 text",
326
+ "type": "TEXT"
327
+ },
328
+ {
329
+ "key": "step4Title",
330
+ "displayName": "Step 4 title",
331
+ "type": "TEXT"
332
+ },
333
+ {
334
+ "key": "step4Text",
335
+ "displayName": "Step 4 text",
336
+ "type": "TEXT"
337
+ },
338
+ {
339
+ "key": "muscles",
340
+ "displayName": "Muscles worked",
341
+ "type": "ARRAY_STRING"
342
+ },
343
+ {
344
+ "key": "sessions",
345
+ "displayName": "Sessions",
346
+ "type": "NUMBER"
347
+ },
348
+ {
349
+ "key": "perWeek",
350
+ "displayName": "Sessions per week",
351
+ "type": "NUMBER"
352
+ },
353
+ {
354
+ "key": "image",
355
+ "displayName": "Illustration",
356
+ "type": "IMAGE"
357
+ },
358
+ {
359
+ "key": "imageAlt",
360
+ "displayName": "Illustration description",
361
+ "type": "TEXT"
362
+ },
363
+ {
364
+ "key": "serviceId",
365
+ "displayName": "Personal Workout service id",
366
+ "type": "TEXT"
367
+ }
368
+ ],
369
+ "seed": [
370
+ {
371
+ "title": "Posture Correction",
372
+ "slug": "posture-correction",
373
+ "order": 1,
374
+ "summary": "Ease neck and back tension and stand taller.",
375
+ "whatItIs": "Hours at a desk or on a phone pull the head forward and round the shoulders. Posture correction trains the muscles that hold your spine in line, so standing tall takes less effort.",
376
+ "muscles": [
377
+ "Upper back",
378
+ "Deep neck",
379
+ "Core",
380
+ "Glutes"
381
+ ],
382
+ "sessions": 8,
383
+ "perWeek": 2,
384
+ "image": "https://static.wixstatic.com/media/0fc611_03ea91d6a0374958860c00db9f0795c9~mv2.webp",
385
+ "imageAlt": "Illustration of a body in side view: an aligned spine and the back muscles that hold it, highlighted in lime.",
386
+ "serviceId": "",
387
+ "step1Title": "Assess",
388
+ "step1Text": "Michael checks how you stand, sit and move.",
389
+ "step2Title": "Release",
390
+ "step2Text": "Mobility work opens a tight chest and tight hips.",
391
+ "step3Title": "Strengthen",
392
+ "step3Text": "Targeted moves for the upper back, deep neck muscles and core.",
393
+ "step4Title": "Build the habit",
394
+ "step4Text": "Short daily drills that you can do at your desk."
395
+ },
396
+ {
397
+ "title": "Muscle Toning",
398
+ "slug": "muscle-toning",
399
+ "order": 2,
400
+ "summary": "Firm and strengthen every major muscle group.",
401
+ "whatItIs": "Toning builds lean muscle and lowers body fat at the same time, so your muscles look more defined. It comes from steady strength work with good form.",
402
+ "muscles": [
403
+ "Shoulders",
404
+ "Chest",
405
+ "Arms",
406
+ "Legs"
407
+ ],
408
+ "sessions": 12,
409
+ "perWeek": 3,
410
+ "image": "https://static.wixstatic.com/media/0fc611_9f02041af67c4f3b88f83b224b6d71e7~mv2.webp",
411
+ "imageAlt": "Illustration of a standing body from the front with the major muscle groups highlighted in lime.",
412
+ "serviceId": "",
413
+ "step1Title": "Find your baseline",
414
+ "step1Text": "Set your starting weights and reps with Michael.",
415
+ "step2Title": "Full-body circuits",
416
+ "step2Text": "Work the large muscle groups with controlled reps.",
417
+ "step3Title": "Add load",
418
+ "step3Text": "Add weight or reps each week as you get stronger.",
419
+ "step4Title": "Recover",
420
+ "step4Text": "Rest days let muscle fibres repair and grow."
421
+ },
422
+ {
423
+ "title": "Weight Loss",
424
+ "slug": "weight-loss",
425
+ "order": 3,
426
+ "summary": "Burn more energy and build habits that last.",
427
+ "whatItIs": "Your body uses stored fat when it uses more energy than it takes in. Training raises the energy you burn, and the muscle you build keeps using energy at rest.",
428
+ "muscles": [
429
+ "Legs",
430
+ "Back",
431
+ "Heart",
432
+ "Lungs"
433
+ ],
434
+ "sessions": 16,
435
+ "perWeek": 2,
436
+ "image": "https://static.wixstatic.com/media/0fc611_c14a361099b048cfb2de697dde82a1b5~mv2.webp",
437
+ "imageAlt": "Illustration of a running body with the legs, back, heart and lungs highlighted in lime.",
438
+ "serviceId": "",
439
+ "step1Title": "Set a goal",
440
+ "step1Text": "Agree a realistic target with Michael.",
441
+ "step2Title": "Mix cardio and strength",
442
+ "step2Text": "Sessions combine heart-rate work with strength moves.",
443
+ "step3Title": "Move every day",
444
+ "step3Text": "Small activity goals between sessions.",
445
+ "step4Title": "Check in",
446
+ "step4Text": "Review progress every two weeks and adjust."
447
+ },
448
+ {
449
+ "title": "Cardio Fitness",
450
+ "slug": "cardio-fitness",
451
+ "order": 4,
452
+ "summary": "Build stamina so everyday effort feels easier.",
453
+ "whatItIs": "Cardio training makes your heart and lungs more efficient. Each beat moves more blood, and your muscles get oxygen faster, so you can go longer before you tire.",
454
+ "muscles": [
455
+ "Heart",
456
+ "Lungs",
457
+ "Legs",
458
+ "Circulation"
459
+ ],
460
+ "sessions": 12,
461
+ "perWeek": 3,
462
+ "image": "https://static.wixstatic.com/media/0fc611_1cf20d9867c443f688aeabc3773eef6b~mv2.webp",
463
+ "imageAlt": "Illustration of a running body with the heart, lungs and blood vessels highlighted in lime.",
464
+ "serviceId": "",
465
+ "step1Title": "Learn your zones",
466
+ "step1Text": "Find the effort level for each part of a session.",
467
+ "step2Title": "Intervals",
468
+ "step2Text": "Short hard efforts with recovery in between.",
469
+ "step3Title": "Steady work",
470
+ "step3Text": "Longer efforts at a pace that you can hold.",
471
+ "step4Title": "Build up",
472
+ "step4Text": "Add a little time or intensity each week."
473
+ },
474
+ {
475
+ "title": "Core Strength",
476
+ "slug": "core-strength",
477
+ "order": 5,
478
+ "summary": "Build a strong, stable centre for every movement.",
479
+ "whatItIs": "Your core is a group of deep muscles around the spine: the diaphragm, the deep abdominal wall, the pelvic floor and the small back muscles. Together they hold your spine steady when you lift, run or sit.",
480
+ "muscles": [
481
+ "Deep abs",
482
+ "Obliques",
483
+ "Lower back",
484
+ "Pelvic floor"
485
+ ],
486
+ "sessions": 8,
487
+ "perWeek": 2,
488
+ "image": "https://static.wixstatic.com/media/0fc611_4276fe51a1b34466927dafc04b582cf5~mv2.webp",
489
+ "imageAlt": "Illustration of a torso with the spine and the deep core muscles around it highlighted in lime.",
490
+ "serviceId": "",
491
+ "step1Title": "Breathe",
492
+ "step1Text": "Learn to brace with the diaphragm.",
493
+ "step2Title": "Stabilise",
494
+ "step2Text": "Hold positions that keep the spine still under load.",
495
+ "step3Title": "Move",
496
+ "step3Text": "Add rotation and anti-rotation moves.",
497
+ "step4Title": "Apply",
498
+ "step4Text": "Use your core in lifts and everyday tasks."
499
+ }
500
+ ]
501
+ }
502
+ ]
503
+ },
504
+ // Your on-device database. It must declare every entity a worker reads or writes,
505
+ // or those calls fail closed — keep it in step with `local_database` above.
506
+ dataSchema: {
507
+ "version": 1,
508
+ "entities": [
509
+ {
510
+ "name": "services",
511
+ "encrypted": false,
512
+ "fields": [
513
+ {
514
+ "name": "id",
515
+ "type": "string",
516
+ "required": true
517
+ },
518
+ {
519
+ "name": "name",
520
+ "type": "string"
521
+ }
522
+ ]
523
+ },
524
+ {
525
+ "name": "booking_prefs",
526
+ "encrypted": false,
527
+ "fields": [
528
+ {
529
+ "name": "id",
530
+ "type": "string",
531
+ "required": true
532
+ },
533
+ {
534
+ "name": "locationId",
535
+ "type": "string"
536
+ },
537
+ {
538
+ "name": "locationLabel",
539
+ "type": "string"
540
+ }
541
+ ]
542
+ },
543
+ {
544
+ "name": "member_bookings",
545
+ "encrypted": true,
546
+ "fields": [
547
+ {
548
+ "name": "id",
549
+ "type": "string",
550
+ "required": true
551
+ },
552
+ {
553
+ "name": "serviceId",
554
+ "type": "string"
555
+ }
556
+ ]
557
+ }
558
+ ]
559
+ },
560
+ });