@wix/himalaya-cli 0.1232.0 → 0.1234.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/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/dev-server/src/app-config.d.ts +2 -2
- package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/ts/src/define-app.d.ts +2 -2
- package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/ts/src/wix-push-links.d.ts +9 -4
- package/dist/cli.mjs +34 -13
- package/guides/push-cli-onboarding.md +7 -5
- package/guides/testing-himi-apps.md +7 -0
- package/package.json +2 -2
|
@@ -189,8 +189,8 @@ export interface DevGatewayConfig {
|
|
|
189
189
|
* `passthrough` (default) forwards it to the real host; `fail` answers a deterministic
|
|
190
190
|
* `404 HIMI_HERMETIC_NO_FIXTURE` and sends nothing upstream (#3019). Honoured by the
|
|
191
191
|
* dev-server's `/v1/__webwix/call` bridge (web host) and `/__dev/{wix,net}/proxy`
|
|
192
|
-
* (native redirect). On-device `NetFake`
|
|
193
|
-
*
|
|
192
|
+
* (native redirect). On-device `NetFake` (iOS/Android, DEBUG) reads it too: a sealed scenario
|
|
193
|
+
* answers a miss with the same 404 and never calls the real capability. */
|
|
194
194
|
unmatched?: "passthrough" | "fail";
|
|
195
195
|
}
|
|
196
196
|
/** Derive the OTA authConfig block from a defineApp auth block
|
package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/ts/src/define-app.d.ts
CHANGED
|
@@ -1038,8 +1038,8 @@ export interface DevGatewayConfig {
|
|
|
1038
1038
|
* `passthrough` (default) forwards it to the real host; `fail` answers a deterministic
|
|
1039
1039
|
* `404 HIMI_HERMETIC_NO_FIXTURE` and sends nothing upstream (#3019). Honoured by the
|
|
1040
1040
|
* dev-server's `/v1/__webwix/call` bridge (web host) and `/__dev/{wix,net}/proxy`
|
|
1041
|
-
* (native redirect). On-device `NetFake`
|
|
1042
|
-
*
|
|
1041
|
+
* (native redirect). On-device `NetFake` (iOS/Android, DEBUG) reads it too: a sealed scenario
|
|
1042
|
+
* answers a miss with the same 404 and never calls the real capability. */
|
|
1043
1043
|
unmatched?: "passthrough" | "fail";
|
|
1044
1044
|
}
|
|
1045
1045
|
export declare function defineApp(config: AppConfig): AppConfig;
|
|
@@ -1,10 +1,15 @@
|
|
|
1
1
|
import type { PushRoute } from "./push-routes.js";
|
|
2
2
|
/**
|
|
3
|
-
* The Ping app family a customer app's members register under
|
|
4
|
-
*
|
|
5
|
-
*
|
|
3
|
+
* The Ping app family a customer app's members register under: member recipients, the site's own
|
|
4
|
+
* credentials by `filterForMetaSite`, the BRANDED link format. Not `WixWebShell`, the family Ping
|
|
5
|
+
* renamed `WixBrandedWebApp` to: a send with `isForBrandedApp` (Ping automations addressed to a
|
|
6
|
+
* contact, and the hosted test send) targets `Branded` and keeps only registrations whose family
|
|
7
|
+
* starts with `WixBranded` (`RegistrationsFetcher.getMobileRegistrationsForTarget`). One constant,
|
|
8
|
+
* so a change of family is a one-line change.
|
|
6
9
|
*/
|
|
7
|
-
export declare const DEFAULT_PING_APP_NAME = "
|
|
10
|
+
export declare const DEFAULT_PING_APP_NAME = "WixBrandedLite";
|
|
11
|
+
/** The family to register under instead of `name`, or undefined when `name` is not retired. */
|
|
12
|
+
export declare function replacementPingFamily(name: string): string | undefined;
|
|
8
13
|
/** One place a member notification can open, and every Wix link shape that names it. */
|
|
9
14
|
export interface WixPushDestination {
|
|
10
15
|
/** `<vertical>.<thing>`, the key an author uses in `push.screens`. */
|
package/dist/cli.mjs
CHANGED
|
@@ -6827,7 +6827,6 @@ function walk(node, registry, path2, out2) {
|
|
|
6827
6827
|
var SYSTEM_FONT_FAMILY, TONAL_ELEVATION_ALPHA, COLOR_TOKEN_PROPS, TYPOGRAPHY_TOKEN_PROPS;
|
|
6828
6828
|
var init_tokens = __esm({
|
|
6829
6829
|
"../../core/ts/src/tokens.ts"() {
|
|
6830
|
-
"use strict";
|
|
6831
6830
|
SYSTEM_FONT_FAMILY = "$system";
|
|
6832
6831
|
TONAL_ELEVATION_ALPHA = [0, 0.05, 0.08, 0.11, 0.12, 0.14];
|
|
6833
6832
|
COLOR_TOKEN_PROPS = {
|
|
@@ -6878,7 +6877,6 @@ function resolveTranslation(value, catalog, sourceCatalog) {
|
|
|
6878
6877
|
var BINDING_SIGILS, BINDING_SIGIL_RE, TRANSLATION_PREFIX, TRANSLATION_KEY_RE;
|
|
6879
6878
|
var init_bindings = __esm({
|
|
6880
6879
|
"../../core/ts/src/bindings.ts"() {
|
|
6881
|
-
"use strict";
|
|
6882
6880
|
BINDING_SIGILS = ["service", "flag", "item", "t"];
|
|
6883
6881
|
BINDING_SIGIL_RE = new RegExp(
|
|
6884
6882
|
`^\\$(?:${BINDING_SIGILS.filter((s2) => s2 !== "t").join("|")})\\b|^\\$t:`
|
|
@@ -24173,6 +24171,9 @@ var init_l10n = __esm({
|
|
|
24173
24171
|
});
|
|
24174
24172
|
|
|
24175
24173
|
// ../../core/ts/src/wix-push-links.ts
|
|
24174
|
+
function replacementPingFamily(name) {
|
|
24175
|
+
return RETIRED_PING_FAMILIES.has(name) ? DEFAULT_PING_APP_NAME : void 0;
|
|
24176
|
+
}
|
|
24176
24177
|
function derivesWixPushRoutes(push, installedVerticals) {
|
|
24177
24178
|
return push?.payloadAdapter === "wix-ping" && push.routes === void 0 && installedVerticals !== void 0;
|
|
24178
24179
|
}
|
|
@@ -24216,10 +24217,14 @@ function itemParamKey(paramKeys) {
|
|
|
24216
24217
|
if (paramKeys.includes("id")) return "id";
|
|
24217
24218
|
return paramKeys.length === 1 ? paramKeys[0] : void 0;
|
|
24218
24219
|
}
|
|
24219
|
-
var DEFAULT_PING_APP_NAME, EVENTS_APP_ID, WIX_MEMBER_PUSH_DESTINATIONS;
|
|
24220
|
+
var DEFAULT_PING_APP_NAME, RETIRED_PING_FAMILIES, EVENTS_APP_ID, WIX_MEMBER_PUSH_DESTINATIONS;
|
|
24220
24221
|
var init_wix_push_links = __esm({
|
|
24221
24222
|
"../../core/ts/src/wix-push-links.ts"() {
|
|
24222
|
-
DEFAULT_PING_APP_NAME = "
|
|
24223
|
+
DEFAULT_PING_APP_NAME = "WixBrandedLite";
|
|
24224
|
+
RETIRED_PING_FAMILIES = /* @__PURE__ */ new Set([
|
|
24225
|
+
// Renamed to WixWebShell by wix-private/wixos #22625, 2026-10-04.
|
|
24226
|
+
"WixBrandedWebApp"
|
|
24227
|
+
]);
|
|
24223
24228
|
EVENTS_APP_ID = "140603ad-af8d-84a5-2c80-a0f60cb47351";
|
|
24224
24229
|
WIX_MEMBER_PUSH_DESTINATIONS = [
|
|
24225
24230
|
{
|
|
@@ -28946,7 +28951,10 @@ function applyNetMocks(gw, mocks) {
|
|
|
28946
28951
|
function resolveNetMocks(fileMocks, appDeclared) {
|
|
28947
28952
|
if (fileMocks) return { mocks: fileMocks, source: "file" };
|
|
28948
28953
|
const declared = Array.isArray(appDeclared?.rules) ? appDeclared.rules : [];
|
|
28949
|
-
if (declared.length > 0
|
|
28954
|
+
if (declared.length > 0 || appDeclared?.mode !== void 0 || appDeclared?.unmatched !== void 0) {
|
|
28955
|
+
const mode = appDeclared?.mode ?? (appDeclared?.unmatched === "fail" ? "mock" : void 0);
|
|
28956
|
+
return { mocks: { mode, rules: declared, unmatched: appDeclared?.unmatched }, source: "app" };
|
|
28957
|
+
}
|
|
28950
28958
|
return null;
|
|
28951
28959
|
}
|
|
28952
28960
|
function readNetMocksFile(path2) {
|
|
@@ -126506,13 +126514,6 @@ function createDevServer(opts = {}) {
|
|
|
126506
126514
|
const from = resolved2.source === "file" ? netMocksPath : `${state.appName} devGateway.rules`;
|
|
126507
126515
|
console.error(`[himalaya-dev] net-mocks: seeded ${seeded.rules} rule(s), mode=${seeded.mode} from ${from}`);
|
|
126508
126516
|
}
|
|
126509
|
-
const appScenario = state.app?.meta.devGateway;
|
|
126510
|
-
if (!netMocksDisabled && appScenario?.rules?.length && state.wix.rules.length === 0) {
|
|
126511
|
-
const seeded = applyNetMocks(state.wix, { mode: appScenario.mode, rules: appScenario.rules, unmatched: appScenario.unmatched });
|
|
126512
|
-
state.wixSeededOn = todayYmd();
|
|
126513
|
-
state.wixSeededFromApp = true;
|
|
126514
|
-
console.error(`[himalaya-dev] net-mocks: seeded ${seeded.rules} rule(s), mode=${seeded.mode} from the app's devGateway scenario`);
|
|
126515
|
-
}
|
|
126516
126517
|
if (state.hotReloadEnabled) {
|
|
126517
126518
|
state.bundleWatcher = startBundleArtifactWatcher(state);
|
|
126518
126519
|
state.bundleSourceWatcher = startBundleSourceWatcher(state);
|
|
@@ -133565,7 +133566,7 @@ import { lstatSync as lstatSync11, readFileSync as readFileSync53 } from "node:f
|
|
|
133565
133566
|
import { basename as basename13, join as join46 } from "node:path";
|
|
133566
133567
|
import ts2 from "typescript";
|
|
133567
133568
|
function enablePushInConfig(source, options) {
|
|
133568
|
-
const pingAppName =
|
|
133569
|
+
const pingAppName = DEFAULT_PING_APP_NAME;
|
|
133569
133570
|
const fileName = options.fileName ?? "config.ts";
|
|
133570
133571
|
const kind = fileName.endsWith(".ts") ? ts2.ScriptKind.TS : ts2.ScriptKind.JS;
|
|
133571
133572
|
const file = ts2.createSourceFile(fileName, source, ts2.ScriptTarget.Latest, true, kind);
|
|
@@ -133606,6 +133607,7 @@ function planPush(app, pingAppName, plan) {
|
|
|
133606
133607
|
}
|
|
133607
133608
|
const block = push.kind === "written" ? push.node.initializer : void 0;
|
|
133608
133609
|
plan.pushOn = !!block && stringValue(block, "registrar") === "wix-ping" && stringValue(block, "payloadAdapter") === "wix-ping";
|
|
133610
|
+
if (block && stringValue(block, "registrar") === "wix-ping") planRetiredFamily(block, plan);
|
|
133609
133611
|
const lacking = [
|
|
133610
133612
|
...block && stringValue(block, "registrar") === "wix-ping" ? [] : ['registrar: "wix-ping"'],
|
|
133611
133613
|
...block && stringValue(block, "pingAppName") ? [] : [`pingAppName: ${JSON.stringify(pingAppName)}`],
|
|
@@ -133617,6 +133619,15 @@ function planPush(app, pingAppName, plan) {
|
|
|
133617
133619
|
);
|
|
133618
133620
|
}
|
|
133619
133621
|
}
|
|
133622
|
+
function planRetiredFamily(block, plan) {
|
|
133623
|
+
const literal = unwrap(block);
|
|
133624
|
+
const found = ts2.isObjectLiteralExpression(literal) ? lookup2(literal, "pingAppName") : void 0;
|
|
133625
|
+
const value = found?.kind === "written" ? unwrap(found.node.initializer) : void 0;
|
|
133626
|
+
const replacement = value && ts2.isStringLiteralLike(value) ? replacementPingFamily(value.text) : void 0;
|
|
133627
|
+
if (!value || !replacement) return;
|
|
133628
|
+
plan.splices.push({ at: value.getStart(), end: value.end, text: JSON.stringify(replacement) });
|
|
133629
|
+
plan.applied.push(`pingAppName ${JSON.stringify(replacement)} in place of ${value.getText()}`);
|
|
133630
|
+
}
|
|
133620
133631
|
function planCapability(app, plan) {
|
|
133621
133632
|
const capabilities = lookup2(app, "capabilities");
|
|
133622
133633
|
if (capabilities.kind === "absent") {
|
|
@@ -136675,6 +136686,7 @@ async function navIssues(dir, strict) {
|
|
|
136675
136686
|
pushRouteIssues(cfg.push, nav, provisioning, warn3);
|
|
136676
136687
|
pushScreenMapIssues(cfg.push, provisioning, warn3);
|
|
136677
136688
|
pushAuthIssues(cfg.push, cfg.auth, provisioning, warn3);
|
|
136689
|
+
pushFamilyIssues(cfg.push, warn3);
|
|
136678
136690
|
if (nav === void 0 || nav === null) return issues;
|
|
136679
136691
|
if (!isPlainObject2(nav)) {
|
|
136680
136692
|
error("nav-not-an-object", `navigation must be an object (got ${Array.isArray(nav) ? "array" : typeof nav}).`);
|
|
@@ -136795,6 +136807,15 @@ function pushAuthIssues(push, auth, provisioning, warn3) {
|
|
|
136795
136807
|
`push.registrar is "wix-ping", which registers a signed-in member's device with Wix Ping, but ${problem}. Use auth: WixConsumerAuthProvider({ siteId: "${provisioning.siteId ?? "<metaSiteId>"}", \u2026 }).`
|
|
136796
136808
|
);
|
|
136797
136809
|
}
|
|
136810
|
+
function pushFamilyIssues(push, warn3) {
|
|
136811
|
+
if (!isPlainObject2(push) || push.registrar !== "wix-ping" || typeof push.pingAppName !== "string") return;
|
|
136812
|
+
const replacement = replacementPingFamily(push.pingAppName);
|
|
136813
|
+
if (!replacement) return;
|
|
136814
|
+
warn3(
|
|
136815
|
+
"push-ping-family-retired",
|
|
136816
|
+
`push.pingAppName "${push.pingAppName}" is a family Ping no longer has, and it kept no alias: a device registering under it gets no notifications. Use pingAppName: "${replacement}".`
|
|
136817
|
+
);
|
|
136818
|
+
}
|
|
136798
136819
|
function pushRouteAdvisories(pushRoutes) {
|
|
136799
136820
|
if (!pushRoutes) return [];
|
|
136800
136821
|
const linked = new Set(WIX_MEMBER_PUSH_DESTINATIONS.map((d2) => d2.vertical));
|
|
@@ -116,16 +116,18 @@ capabilities: ["push" /* , … */],
|
|
|
116
116
|
// Routes are derived at build time from provisioning.json and your screens; see himi validate.
|
|
117
117
|
push: {
|
|
118
118
|
registrar: "wix-ping",
|
|
119
|
-
pingAppName: "
|
|
119
|
+
pingAppName: "WixBrandedLite",
|
|
120
120
|
requestPermissionOnLaunch: true,
|
|
121
121
|
payloadAdapter: "wix-ping",
|
|
122
122
|
},
|
|
123
123
|
```
|
|
124
124
|
|
|
125
|
-
- `pingAppName` is the Ping app family the device registers under. Use `
|
|
126
|
-
Ping allows it for site members
|
|
127
|
-
the site. A build signed for the APNs
|
|
128
|
-
do not add it.
|
|
125
|
+
- `pingAppName` is the Ping app family the device registers under. Use `WixBrandedLite`:
|
|
126
|
+
Ping allows it for site members, uses the credentials `himi notify setup` stored for the
|
|
127
|
+
site, and delivers the site's member notifications to it. A build signed for the APNs
|
|
128
|
+
development environment appends `.sandbox` itself; do not add it. `WixBrandedWebApp` no
|
|
129
|
+
longer exists in Ping: `himi validate` reports it as `push-ping-family-retired`, and
|
|
130
|
+
re-running `himi notify setup` replaces it.
|
|
129
131
|
- The device registers only after a member signs in; a visitor's device receives nothing.
|
|
130
132
|
Keep `siteId` in `auth` on the site `himi notify setup` configured. A changed `siteId` or
|
|
131
133
|
`clientId` ships with `himi push` like the rest of the config, and the app picks it up on
|
|
@@ -379,6 +379,13 @@ snapshot tests. `FakeServiceProvider` answers `value(at: "counter.value")` from
|
|
|
379
379
|
-himalaya.fake.services '{"ownerInbox":{"count":3,"items":[{"title":"New order"}]}}'
|
|
380
380
|
```
|
|
381
381
|
|
|
382
|
+
**From an XCUITest, write every `'` in the blob as `\u0027`.** `XCUIApplication.launchArguments`
|
|
383
|
+
are re-quoted shell-style on the way to the app: an apostrophe opens a quoted run whose spaces and
|
|
384
|
+
`"` arrive backslash-escaped, so `"today's"` turns a valid fixture into invalid JSON. The launch
|
|
385
|
+
manifest then keeps the value as a plain string, `fake.services` is silently off, and the screen
|
|
386
|
+
renders its live worker. `xcrun simctl launch` passes argv untouched, so the same blob works by
|
|
387
|
+
hand. `BrandedLiteUITestCase.launchSafeJSON` does the escaping for the branded-lite target.
|
|
388
|
+
|
|
382
389
|
The **web/headless** tier has the same seam: `POST /__dev/render { descriptor, services: {…} }`
|
|
383
390
|
builds a `FakeServiceProvider` (core/web-renderer/src/FakeServiceProvider.ts) so the browser-free
|
|
384
391
|
render resolves the same `$service:`/`$item.` bindings — text filled and repeaters expanded — with
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wix/himalaya-cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.1234.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": [
|
|
@@ -67,5 +67,5 @@
|
|
|
67
67
|
"artifactId": "himalaya-cli"
|
|
68
68
|
}
|
|
69
69
|
},
|
|
70
|
-
"falconPackageHash": "
|
|
70
|
+
"falconPackageHash": "eeef93bad6f73772bf97da835fa24f3c52b393873be055a3ae232dfe"
|
|
71
71
|
}
|