@wix/himalaya-cli 0.1648.0 → 0.1649.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.
- package/package.json +2 -2
- package/template-icons/wholesale-store.png +0 -0
- package/templates/wholesale-store/README.md +53 -0
- package/templates/wholesale-store/config.ts +247 -0
- package/templates/wholesale-store/dev/index.ts +12194 -0
- package/templates/wholesale-store/himalaya.content.json +43 -0
- package/templates/wholesale-store/himalaya.template.json +14 -0
- package/templates/wholesale-store/icon.png +0 -0
- package/templates/wholesale-store/platforms.json +1 -0
- package/templates/wholesale-store/tier5-src/_shared/app-locale.ts +61 -0
- package/templates/wholesale-store/tier5-src/_shared/branded-lite-hosted.ts +279 -0
- package/templates/wholesale-store/tier5-src/_shared/business-chat-copy.ts +40 -0
- package/templates/wholesale-store/tier5-src/_shared/business-chat-history.ts +51 -0
- package/templates/wholesale-store/tier5-src/_shared/business-chat-message-model.ts +177 -0
- package/templates/wholesale-store/tier5-src/_shared/business-chat-model.ts +56 -0
- package/templates/wholesale-store/tier5-src/_shared/business-chat-presenter.ts +576 -0
- package/templates/wholesale-store/tier5-src/_shared/business-chat-transport.ts +148 -0
- package/templates/wholesale-store/tier5-src/_shared/collection-contract.ts +228 -0
- package/templates/wholesale-store/tier5-src/_shared/collection-query-legacy.ts +194 -0
- package/templates/wholesale-store/tier5-src/_shared/collection-query.ts +252 -0
- package/templates/wholesale-store/tier5-src/_shared/collection-service.ts +423 -0
- package/templates/wholesale-store/tier5-src/_shared/detail-presence.ts +51 -0
- package/templates/wholesale-store/tier5-src/_shared/empty-flags.ts +33 -0
- package/templates/wholesale-store/tier5-src/_shared/engine-intl.ts +508 -0
- package/templates/wholesale-store/tier5-src/_shared/exclusive-writes.ts +66 -0
- package/templates/wholesale-store/tier5-src/_shared/himi-account.ts +164 -0
- package/templates/wholesale-store/tier5-src/_shared/himi-copy.ts +89 -0
- package/templates/wholesale-store/tier5-src/_shared/himi-store-categories.ts +108 -0
- package/templates/wholesale-store/tier5-src/_shared/himi-store-collection.ts +22 -0
- package/templates/wholesale-store/tier5-src/_shared/himi-store-saved.ts +57 -0
- package/templates/wholesale-store/tier5-src/_shared/himi-store.ts +7 -0
- package/templates/wholesale-store/tier5-src/_shared/himi-text.ts +24 -0
- package/templates/wholesale-store/tier5-src/_shared/hosted-checkout.ts +70 -0
- package/templates/wholesale-store/tier5-src/_shared/iap-presentation.ts +207 -0
- package/templates/wholesale-store/tier5-src/_shared/iap-worker.ts +125 -0
- package/templates/wholesale-store/tier5-src/_shared/inbox-rooms.ts +68 -0
- package/templates/wholesale-store/tier5-src/_shared/live-session.ts +172 -0
- package/templates/wholesale-store/tier5-src/_shared/local-preferences.ts +38 -0
- package/templates/wholesale-store/tier5-src/_shared/member-access.ts +52 -0
- package/templates/wholesale-store/tier5-src/_shared/member-account-routes.ts +52 -0
- package/templates/wholesale-store/tier5-src/_shared/member-orders.ts +8 -0
- package/templates/wholesale-store/tier5-src/_shared/member-screen.ts +99 -0
- package/templates/wholesale-store/tier5-src/_shared/online-actions.ts +76 -0
- package/templates/wholesale-store/tier5-src/_shared/owner-editor-value.ts +164 -0
- package/templates/wholesale-store/tier5-src/_shared/owner-load-error.ts +348 -0
- package/templates/wholesale-store/tier5-src/_shared/payment-setup.ts +6 -0
- package/templates/wholesale-store/tier5-src/_shared/read-service.ts +255 -0
- package/templates/wholesale-store/tier5-src/_shared/restaurant-ordering.ts +201 -0
- package/templates/wholesale-store/tier5-src/_shared/rich-body.ts +78 -0
- package/templates/wholesale-store/tier5-src/_shared/rich-content-link.ts +34 -0
- package/templates/wholesale-store/tier5-src/_shared/sign-in-sheet.ts +18 -0
- package/templates/wholesale-store/tier5-src/_shared/store-order-presentation.ts +56 -0
- package/templates/wholesale-store/tier5-src/_shared/store-product-info.ts +50 -0
- package/templates/wholesale-store/tier5-src/business-chat/index.ts +724 -0
- package/templates/wholesale-store/tier5-src/himi-branded-lite-cart/index.ts +602 -0
- package/templates/wholesale-store/tier5-src/himi-branded-lite-order/index.ts +472 -0
- package/templates/wholesale-store/tier5-src/himi-branded-lite-orders/index.ts +327 -0
- package/templates/wholesale-store/tier5-src/himi-store-account/index.ts +998 -0
- package/templates/wholesale-store/tier5-src/himi-store-product/index.ts +889 -0
- package/templates/wholesale-store/tier5-src/himi-store-saved/index.ts +68 -0
- package/templates/wholesale-store/tier5-src/himi-store-shop/index.ts +150 -0
- package/templates/wholesale-store/tier5-src/himi-wholesale-home/index.ts +507 -0
- package/templates/wholesale-store/tier5-src/wix-spaces-collection-detail/index.ts +195 -0
- package/templates/wholesale-store/tokens.json +340 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wix/himalaya-cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.1649.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "himi — the Himalaya authoring CLI. Build a Tier-5 content package on your own machine, push it to the production serve as a draft, preview it on web + Himi Player, and read worker logs back — the remote dev loop. Wraps @himalaya/serve-cli for transport.",
|
|
6
6
|
"keywords": [
|
|
@@ -72,5 +72,5 @@
|
|
|
72
72
|
"artifactId": "himalaya-cli"
|
|
73
73
|
}
|
|
74
74
|
},
|
|
75
|
-
"falconPackageHash": "
|
|
75
|
+
"falconPackageHash": "15b3fdb90c7bf8373a512d4bd491d09f663cb0adb58371bb9df208c1"
|
|
76
76
|
}
|
|
Binary file
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
# __HIMI_APP_NAME__ — from the `wholesale-store` template
|
|
2
|
+
|
|
3
|
+
A wholesale / distributor store app over a real Wix Stores site: a home with the newest arrival, round category tiles, Deals (real % off from compare-at prices) and Best sellers; Categories with a catalog search; All products; the shared Branded Lite product screen in a wholesaler's words, with quantity and a Request a bulk quote card; Saved; a cart with quantity steppers and the Wix checkout; My orders with Order These Again; Bulk quotes & help (the Wix Inbox chat). Boots as a VISITOR (catalog and cart work with no login); orders 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
|
+
| Data-derived category tiles (own image, else a product photo) | wholesale_home categories, himi_collections |
|
|
44
|
+
| Deals from compare-at prices (% OFF badge) | wholesale_home deals |
|
|
45
|
+
| Horizontal rails (bound LazyList) | wholesale_home deals, best sellers |
|
|
46
|
+
| Reusing a shared screen in your own words (stock-string copy rewrite) | himi_product, himi_collection, himi_saved_products |
|
|
47
|
+
| Adding a card to a shared screen by node id | himi_product bulk-quote card |
|
|
48
|
+
| A paged list Android recycles (plain root column) | himi_shop, himi_orders |
|
|
49
|
+
| Your own design over a shared worker | himi_cart, himi_account, himi_orders, himi_order |
|
|
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,247 @@
|
|
|
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 Stores; the Wix Inbox chat (bulk quotes) is optional.
|
|
22
|
+
clientId: process.env.WIX_CLIENT_ID ?? "YOUR_WIX_CLIENT_ID",
|
|
23
|
+
siteUrl: process.env.WIX_SITE_URL ?? "https://your-site.example.com",
|
|
24
|
+
// The OAuth redirect must be ALLOWLISTED on the headless client in `clientId`.
|
|
25
|
+
redirectUri: process.env.WIX_REDIRECT_URI ?? "himalaya-__HIMI_APP_SLUG__://oauth/callback",
|
|
26
|
+
bootAsVisitor: true,
|
|
27
|
+
preserveVisitorOnSignOut: true,
|
|
28
|
+
}),
|
|
29
|
+
telemetry: ConsoleTelemetrySink(),
|
|
30
|
+
serverUrls: {
|
|
31
|
+
screen: "http://localhost:8190/v1",
|
|
32
|
+
actions: "http://localhost:8190/v1/actions",
|
|
33
|
+
sync: "http://localhost:8190/v1/sync",
|
|
34
|
+
},
|
|
35
|
+
capabilities: ["wix_api","local_database","open_url","share","secure_storage","wix_platform","app_info","iap","wix_chat","live_activity","wix_cashier"],
|
|
36
|
+
designTokensPath: "./tokens.json",
|
|
37
|
+
navigation: {
|
|
38
|
+
"navKind": "responsive",
|
|
39
|
+
"scheme": "himalaya-__HIMI_APP_SLUG__",
|
|
40
|
+
"deepLinkPatterns": [],
|
|
41
|
+
"linkableScreens": [
|
|
42
|
+
{
|
|
43
|
+
"screenId": "wholesale_home",
|
|
44
|
+
"isPublic": true,
|
|
45
|
+
"paramKeys": [],
|
|
46
|
+
"parentScreenId": "",
|
|
47
|
+
"tabId": "home"
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"screenId": "himi_collections",
|
|
51
|
+
"isPublic": true,
|
|
52
|
+
"paramKeys": [
|
|
53
|
+
"focus"
|
|
54
|
+
],
|
|
55
|
+
"parentScreenId": "",
|
|
56
|
+
"tabId": "categories"
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"screenId": "himi_collection",
|
|
60
|
+
"isPublic": true,
|
|
61
|
+
"paramKeys": [
|
|
62
|
+
"id"
|
|
63
|
+
],
|
|
64
|
+
"parentScreenId": "himi_collections",
|
|
65
|
+
"tabId": "categories"
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
"screenId": "himi_shop",
|
|
69
|
+
"isPublic": true,
|
|
70
|
+
"paramKeys": [],
|
|
71
|
+
"parentScreenId": "himi_collections",
|
|
72
|
+
"tabId": "categories"
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
"screenId": "himi_product",
|
|
76
|
+
"isPublic": true,
|
|
77
|
+
"paramKeys": [
|
|
78
|
+
"id"
|
|
79
|
+
],
|
|
80
|
+
"parentScreenId": "himi_shop",
|
|
81
|
+
"tabId": "home"
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
"screenId": "himi_cart",
|
|
85
|
+
"isPublic": true,
|
|
86
|
+
"paramKeys": [],
|
|
87
|
+
"parentScreenId": "",
|
|
88
|
+
"tabId": "cart"
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
"screenId": "himi_saved_products",
|
|
92
|
+
"isPublic": true,
|
|
93
|
+
"paramKeys": [],
|
|
94
|
+
"parentScreenId": "",
|
|
95
|
+
"tabId": "saved"
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
"screenId": "himi_account",
|
|
99
|
+
"isPublic": true,
|
|
100
|
+
"paramKeys": [],
|
|
101
|
+
"parentScreenId": "",
|
|
102
|
+
"tabId": "account"
|
|
103
|
+
},
|
|
104
|
+
{
|
|
105
|
+
"screenId": "himi_sign_in",
|
|
106
|
+
"isPublic": true,
|
|
107
|
+
"paramKeys": [
|
|
108
|
+
"mode",
|
|
109
|
+
"intent",
|
|
110
|
+
"modal",
|
|
111
|
+
"returnTab",
|
|
112
|
+
"contextName",
|
|
113
|
+
"returnScreenId",
|
|
114
|
+
"returnId",
|
|
115
|
+
"returnChannelId",
|
|
116
|
+
"authContinuation"
|
|
117
|
+
],
|
|
118
|
+
"parentScreenId": "himi_account",
|
|
119
|
+
"tabId": "account"
|
|
120
|
+
},
|
|
121
|
+
{
|
|
122
|
+
"screenId": "himi_orders",
|
|
123
|
+
"isPublic": false,
|
|
124
|
+
"paramKeys": [],
|
|
125
|
+
"parentScreenId": "himi_account",
|
|
126
|
+
"tabId": "account"
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
"screenId": "himi_order",
|
|
130
|
+
"isPublic": false,
|
|
131
|
+
"paramKeys": [
|
|
132
|
+
"id"
|
|
133
|
+
],
|
|
134
|
+
"parentScreenId": "himi_orders",
|
|
135
|
+
"tabId": "account"
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
"screenId": "himi_business_chat",
|
|
139
|
+
"isPublic": false,
|
|
140
|
+
"paramKeys": [],
|
|
141
|
+
"parentScreenId": "wholesale_home",
|
|
142
|
+
"tabId": "home"
|
|
143
|
+
}
|
|
144
|
+
],
|
|
145
|
+
"tabBar": {
|
|
146
|
+
"presentation": "native",
|
|
147
|
+
"items": [
|
|
148
|
+
{
|
|
149
|
+
"id": "home",
|
|
150
|
+
"screenId": "wholesale_home",
|
|
151
|
+
"label": "Home",
|
|
152
|
+
"icon": "home",
|
|
153
|
+
"selectedIcon": "home_fill"
|
|
154
|
+
},
|
|
155
|
+
{
|
|
156
|
+
"id": "categories",
|
|
157
|
+
"screenId": "himi_collections",
|
|
158
|
+
"label": "Categories",
|
|
159
|
+
"icon": "grid"
|
|
160
|
+
},
|
|
161
|
+
{
|
|
162
|
+
"id": "cart",
|
|
163
|
+
"screenId": "himi_cart",
|
|
164
|
+
"label": "Cart",
|
|
165
|
+
"icon": "cart"
|
|
166
|
+
},
|
|
167
|
+
{
|
|
168
|
+
"id": "saved",
|
|
169
|
+
"screenId": "himi_saved_products",
|
|
170
|
+
"label": "Saved",
|
|
171
|
+
"icon": "heart",
|
|
172
|
+
"selectedIcon": "heart_fill"
|
|
173
|
+
},
|
|
174
|
+
{
|
|
175
|
+
"id": "account",
|
|
176
|
+
"screenId": "himi_account",
|
|
177
|
+
"label": "Account",
|
|
178
|
+
"icon": "person",
|
|
179
|
+
"selectedIcon": "person_fill"
|
|
180
|
+
}
|
|
181
|
+
]
|
|
182
|
+
}
|
|
183
|
+
},
|
|
184
|
+
// This app talks to a language model (dual LLM / remote model).
|
|
185
|
+
agent: {
|
|
186
|
+
"onDevice": {
|
|
187
|
+
"ios": "foundation_models",
|
|
188
|
+
"android": "mediapipe"
|
|
189
|
+
},
|
|
190
|
+
"remote": {
|
|
191
|
+
"providerId": "anthropic",
|
|
192
|
+
"config": {
|
|
193
|
+
"model": "claude-haiku-4-5"
|
|
194
|
+
}
|
|
195
|
+
},
|
|
196
|
+
"privateModeToggle": false
|
|
197
|
+
},
|
|
198
|
+
entities: {},
|
|
199
|
+
// Your on-device database. It must declare every entity a worker reads or writes,
|
|
200
|
+
// or those calls fail closed — keep it in step with `local_database` above.
|
|
201
|
+
dataSchema: {
|
|
202
|
+
"version": 1,
|
|
203
|
+
"entities": [
|
|
204
|
+
{
|
|
205
|
+
"name": "products",
|
|
206
|
+
"encrypted": false,
|
|
207
|
+
"fields": [
|
|
208
|
+
{
|
|
209
|
+
"name": "id",
|
|
210
|
+
"type": "string",
|
|
211
|
+
"required": true
|
|
212
|
+
},
|
|
213
|
+
{
|
|
214
|
+
"name": "name",
|
|
215
|
+
"type": "string"
|
|
216
|
+
},
|
|
217
|
+
{
|
|
218
|
+
"name": "subtitle",
|
|
219
|
+
"type": "string"
|
|
220
|
+
}
|
|
221
|
+
]
|
|
222
|
+
},
|
|
223
|
+
{
|
|
224
|
+
"name": "cart",
|
|
225
|
+
"encrypted": true,
|
|
226
|
+
"fields": [
|
|
227
|
+
{
|
|
228
|
+
"name": "id",
|
|
229
|
+
"type": "string",
|
|
230
|
+
"required": true
|
|
231
|
+
}
|
|
232
|
+
]
|
|
233
|
+
},
|
|
234
|
+
{
|
|
235
|
+
"name": "orders",
|
|
236
|
+
"encrypted": true,
|
|
237
|
+
"fields": [
|
|
238
|
+
{
|
|
239
|
+
"name": "id",
|
|
240
|
+
"type": "string",
|
|
241
|
+
"required": true
|
|
242
|
+
}
|
|
243
|
+
]
|
|
244
|
+
}
|
|
245
|
+
]
|
|
246
|
+
},
|
|
247
|
+
});
|