@wix/himalaya-cli 0.1123.0 → 0.1125.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 (2) hide show
  1. package/dist/cli.mjs +19 -16
  2. package/package.json +2 -2
package/dist/cli.mjs CHANGED
@@ -6789,7 +6789,6 @@ function resolveTranslation(value, catalog, sourceCatalog) {
6789
6789
  var BINDING_SIGILS, BINDING_SIGIL_RE, TRANSLATION_PREFIX, TRANSLATION_KEY_RE;
6790
6790
  var init_bindings = __esm({
6791
6791
  "../../core/ts/src/bindings.ts"() {
6792
- "use strict";
6793
6792
  BINDING_SIGILS = ["service", "flag", "item", "t"];
6794
6793
  BINDING_SIGIL_RE = new RegExp(
6795
6794
  `^\\$(?:${BINDING_SIGILS.filter((s) => s !== "t").join("|")})\\b|^\\$t:`
@@ -42270,10 +42269,10 @@ function cmsAnswer(seed2, method, bare, body) {
42270
42269
  pagingMetadata: { count: rows.length, tooManyToCount: false }
42271
42270
  };
42272
42271
  }
42273
- function layeredTransport(layers2) {
42274
- const rules = layers2.rules?.length ? [...layers2.rules] : null;
42275
- const cms = layers2.cmsSeed && Object.keys(layers2.cmsSeed).length ? layers2.cmsSeed : null;
42276
- const canned = layers2.canned && Object.keys(layers2.canned).length ? layers2.canned : null;
42272
+ function layeredTransport(layers3) {
42273
+ const rules = layers3.rules?.length ? [...layers3.rules] : null;
42274
+ const cms = layers3.cmsSeed && Object.keys(layers3.cmsSeed).length ? layers3.cmsSeed : null;
42275
+ const canned = layers3.canned && Object.keys(layers3.canned).length ? layers3.canned : null;
42277
42276
  const label2 = [rules && "mocked", cms && "cms", canned && "canned"].filter(Boolean).join("+") || "offline";
42278
42277
  const call = async (method, path2, body) => {
42279
42278
  const m = String(method).toUpperCase();
@@ -48606,7 +48605,11 @@ function painted(text8, page) {
48606
48605
  }
48607
48606
  function errorMessageOf(s) {
48608
48607
  const e = s.error;
48609
- return str3(s.errorText) ?? str3(s.errorMessage) ?? str3(e) ?? (e && typeof e === "object" ? str3(e.message) : void 0);
48608
+ return str3(s.errorText) ?? str3(s.errorMessage) ?? str3(e) ?? (e && typeof e === "object" ? str3(e.message) : void 0) ?? str3(s.errorTitle);
48609
+ }
48610
+ function layers2(s) {
48611
+ const c = s.collection;
48612
+ return c && typeof c === "object" && !Array.isArray(c) ? [s, c] : [s];
48610
48613
  }
48611
48614
  function screenStateOf(services, html, opts = {}) {
48612
48615
  if (!services || typeof services !== "object") return null;
@@ -48615,17 +48618,17 @@ function screenStateOf(services, html, opts = {}) {
48615
48618
  const page = html === void 0 ? void 0 : visibleText(html);
48616
48619
  let loading = false;
48617
48620
  let empty;
48618
- for (const s of states) {
48621
+ for (const top of states) for (const s of layers2(top)) {
48619
48622
  const status = typeof s.status === "string" ? s.status.toLowerCase() : typeof s.phase === "string" ? s.phase.toLowerCase() : void 0;
48620
48623
  const message = errorMessageOf(s);
48621
- const flagged = status === "error" || status === "failed" || s.hasError === true || s.isError === true;
48624
+ const flagged = status === "error" || status === "failed" || s.hasError === true || s.isError === true || s.isErrored === true || s.errored === true || s.noError === false || s.notErrored === false;
48622
48625
  if (flagged && !(message && page !== void 0 && !painted(message, page)) || message && page !== void 0 && painted(message, page)) {
48623
48626
  const line = message && painted(message, page) ? quotableLine(message) : void 0;
48624
48627
  return { state: "error", ...line ? { line } : {} };
48625
48628
  }
48626
- if (status === "loading" || s.isLoading === true) loading = true;
48627
- const emptyText = str3(s.emptyText);
48628
- if (!empty && (status === "empty" || s.isEmpty === true || emptyText && page !== void 0 && painted(emptyText, page))) {
48629
+ if (status === "loading" || s.isLoading === true || s.noLoading === false) loading = true;
48630
+ const emptyText = str3(s.emptyText) ?? str3(s.emptySourceText);
48631
+ if (!empty && (status === "empty" || s.isEmpty === true || s.noEmptySource === false || emptyText && page !== void 0 && painted(emptyText, page))) {
48629
48632
  const line = emptyText && painted(emptyText, page) ? quotableLine(emptyText) : void 0;
48630
48633
  empty = { state: "empty", ...line ? { line } : {} };
48631
48634
  }
@@ -52147,12 +52150,12 @@ async function runCrawl(opts) {
52147
52150
  };
52148
52151
  }
52149
52152
  function describeTransport(net, opts, ran) {
52150
- const layers2 = [];
52151
- if (net) layers2.push(`mocked (${net.from})`);
52153
+ const layers3 = [];
52154
+ if (net) layers3.push(`mocked (${net.from})`);
52152
52155
  const cmsCount = Object.keys(opts.cmsSeed ?? {}).length;
52153
- if (cmsCount) layers2.push(`cms (${cmsCount} seeded collection${cmsCount === 1 ? "" : "s"})`);
52154
- if (opts.canned?.count) layers2.push(`canned (${opts.canned.count} frozen endpoints, ${opts.canned.from} \u2014 exercises code paths, not API-contract truth)`);
52155
- const base = layers2.length ? layers2.join(" + ") : "offline (no net fixture \u2014 screens are crawled against a rejecting transport, which exercises their failure UI)";
52156
+ if (cmsCount) layers3.push(`cms (${cmsCount} seeded collection${cmsCount === 1 ? "" : "s"})`);
52157
+ if (opts.canned?.count) layers3.push(`canned (${opts.canned.count} frozen endpoints, ${opts.canned.from} \u2014 exercises code paths, not API-contract truth)`);
52158
+ const base = layers3.length ? layers3.join(" + ") : "offline (no net fixture \u2014 screens are crawled against a rejecting transport, which exercises their failure UI)";
52156
52159
  const hostile = ran.hostile ? " + hostile boot passes (empty-lists, all-500)" : "";
52157
52160
  const relations = ran.relations ? " + relations" : "";
52158
52161
  const deep = ran.deep ? ` + deep chains (depth ${opts.deep})` : "";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wix/himalaya-cli",
3
- "version": "0.1123.0",
3
+ "version": "0.1125.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": "bc7e9b05c299d9a115e66dbcaa5f2a3e921d432a6ea71e69109a9f6c"
70
+ "falconPackageHash": "c3b3a5bf210d0f158623a297ddc8489309392a8c99ffa1af298ecb28"
71
71
  }