@wix/himalaya-cli 0.1665.0 → 0.1666.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 (28) hide show
  1. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/ts/src/legacy-import.d.ts +15 -3
  2. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/core.mjs +21 -2
  3. package/dist/cli.mjs +1 -1
  4. package/package.json +2 -2
  5. package/templates/beauty-salon/l10n/en.json +1 -1
  6. package/templates/beauty-salon/l10n/he.json +4 -0
  7. package/templates/branded-lite/dev/index.ts +950 -170
  8. package/templates/branded-lite/l10n/en.json +36 -1
  9. package/templates/branded-lite/l10n/he.json +33 -0
  10. package/templates/branded-lite/tier5-src/wix-spaces-members/index.ts +50 -19
  11. package/templates/community-club/l10n/en.json +1 -1
  12. package/templates/community-club/l10n/he.json +4 -0
  13. package/templates/events-meetups/l10n/en.json +1 -1
  14. package/templates/events-meetups/l10n/he.json +4 -0
  15. package/templates/gym-fitness/l10n/en.json +1 -1
  16. package/templates/gym-fitness/l10n/he.json +4 -0
  17. package/templates/nonprofit-cause/l10n/en.json +1 -1
  18. package/templates/nonprofit-cause/l10n/he.json +4 -0
  19. package/templates/podcast-creator/l10n/en.json +1 -1
  20. package/templates/podcast-creator/l10n/he.json +4 -0
  21. package/templates/portfolio-creative/l10n/en.json +1 -1
  22. package/templates/portfolio-creative/l10n/he.json +4 -0
  23. package/templates/restaurant/l10n/en.json +1 -1
  24. package/templates/restaurant/l10n/he.json +4 -0
  25. package/templates/retail-store/l10n/en.json +1 -1
  26. package/templates/retail-store/l10n/he.json +4 -0
  27. package/templates/yoga-studio/l10n/en.json +1 -1
  28. package/templates/yoga-studio/l10n/he.json +4 -0
@@ -6,15 +6,25 @@ export type LegacyImportSourceKind = (typeof LEGACY_IMPORT_SOURCE_KINDS)[number]
6
6
  export declare const LEGACY_IMPORT_SINKS: readonly ["localDatabase", "state", "files", "report", "installationId", "drop"];
7
7
  export type LegacyImportSinkName = (typeof LEGACY_IMPORT_SINKS)[number];
8
8
  /** The container roots a `files` source may read under (the OLD app's container, which an
9
- * update shares). */
10
- export declare const LEGACY_IMPORT_FILE_ROOTS: readonly ["documents", "library", "caches"];
9
+ * update shares). iOS: `documents`, `library`, `caches`. Android (#4654): `files` (filesDir),
10
+ * `noBackup` (noBackupFilesDir), `cache` (cacheDir), `external` (the app-specific
11
+ * getExternalFilesDir(null), never shared storage). A source rooted at the other platform's name
12
+ * resolves to nothing there and is reported `invalid_options` — never read, never a crash. */
13
+ export declare const LEGACY_IMPORT_FILE_ROOTS: readonly ["documents", "library", "caches", "files", "noBackup", "cache", "external"];
11
14
  export type LegacyImportFileRoot = (typeof LEGACY_IMPORT_FILE_ROOTS)[number];
15
+ export declare const LEGACY_IMPORT_ANDROID_FILE_ROOTS: readonly ["files", "noBackup", "cache", "external"];
16
+ export type LegacyImportAndroidFileRoot = (typeof LEGACY_IMPORT_ANDROID_FILE_ROOTS)[number];
12
17
  /** Every file under `<root>/<path>`. An item's key is its path relative to that directory,
13
18
  * with `/` separators (e.g. `notes/a.json`); its value is the file. */
14
19
  export interface LegacyImportFilesSource {
15
20
  id: string;
16
21
  kind: "files";
17
22
  root: LegacyImportFileRoot;
23
+ /** #4654 — the root an Android binary reads instead of `root` (`files`, `noBackup`, `cache` or
24
+ * `external`), for a source whose old app kept the same tree in a different container folder on
25
+ * each platform. One source id, so its `map` rules and `principal` serve both platforms; iOS
26
+ * reads `root` and ignores this. */
27
+ androidRoot?: LegacyImportAndroidFileRoot;
18
28
  /** Relative directory under `root` — no leading `/`, no `..`. */
19
29
  path: string;
20
30
  }
@@ -118,7 +128,9 @@ export declare const LEGACY_IMPORT_RESERVED_IDS: readonly string[];
118
128
  * (WebKit, Preferences, Caches, …), so a source there is a folder of the old app's under
119
129
  * `Application Support`; that folder, and a `caches` source's first folder, is never a Himi-owned
120
130
  * one, never bundle-id shaped (`Caches/<bundleId>` is this bundle's URL cache), and never a system
121
- * cache folder. Mirror of `FilesLegacyImportSource.mayRead` on iOS. */
131
+ * cache folder. Every Android root holds Himi's and the system's own stores too, so an Android
132
+ * source's FIRST folder is the old app's: never Himi-owned, never package-name shaped (no `.`) and
133
+ * never WebView / pdf-share. Mirror of `FilesLegacyImportSource.mayRead` on iOS and Android. */
122
134
  export declare function mayReadLegacyFiles(root: string, path: string): boolean;
123
135
  /** Every problem with a `legacyImport` block, each prefixed with its field path. Empty ⇒ valid. */
124
136
  export declare function legacyImportProblems(cfg: unknown, at?: string): string[];
@@ -7446,7 +7446,8 @@ function gateScreenIdShapeProblem(id) {
7446
7446
  // ../../core/ts/src/legacy-import.ts
7447
7447
  var LEGACY_IMPORT_SOURCE_KINDS = ["files"];
7448
7448
  var LEGACY_IMPORT_SINKS = ["localDatabase", "state", "files", "report", "installationId", "drop"];
7449
- var LEGACY_IMPORT_FILE_ROOTS = ["documents", "library", "caches"];
7449
+ var LEGACY_IMPORT_FILE_ROOTS = ["documents", "library", "caches", "files", "noBackup", "cache", "external"];
7450
+ var LEGACY_IMPORT_ANDROID_FILE_ROOTS = ["files", "noBackup", "cache", "external"];
7450
7451
  var LEGACY_IMPORT_DEFAULT_RETAIN_DAYS = 30;
7451
7452
  var LEGACY_IMPORT_BUDGET_MS = 3e3;
7452
7453
  var LEGACY_IMPORT_MAX_ATTEMPTS = 3;
@@ -7464,13 +7465,24 @@ var nonEmpty = (v) => typeof v === "string" && v.trim().length > 0;
7464
7465
  var LEGACY_IMPORT_RESERVED_IDS = ["state-seeds", "installation-id"];
7465
7466
  var isHimiOwned = (segment) => /^(himalaya|himi|io\.himalaya)/i.test(segment);
7466
7467
  var SYSTEM_CACHE_FOLDERS = /* @__PURE__ */ new Set(["WebKit", "Snapshots", "fsCachedData"]);
7468
+ var ANDROID_RUNTIME_FOLDERS = /* @__PURE__ */ new Set(["WebView", "pdf-share"]);
7469
+ var ANDROID_FILE_ROOTS = /* @__PURE__ */ new Set(["files", "noBackup", "cache", "external"]);
7467
7470
  function mayReadLegacyFiles(root, path) {
7468
7471
  const segs = path.split("/");
7469
7472
  const appFolder = (s) => !isHimiOwned(s) && !s.includes(".") && !SYSTEM_CACHE_FOLDERS.has(s);
7470
7473
  if (root === "library") return segs.length >= 2 && segs[0] === "Application Support" && appFolder(segs[1]);
7471
7474
  if (root === "caches") return appFolder(segs[0]);
7475
+ if (ANDROID_FILE_ROOTS.has(root)) {
7476
+ return !isHimiOwned(segs[0]) && !segs[0].includes(".") && !ANDROID_RUNTIME_FOLDERS.has(segs[0]) && !isHimiAccountTree(segs);
7477
+ }
7472
7478
  return true;
7473
7479
  }
7480
+ function isHimiAccountTree(segs) {
7481
+ for (const i of [1, 2]) {
7482
+ if (segs.length > i + 1 && segs[i] === "files" && (segs[i + 1] === "bundle_docs" || segs[i + 1] === "worker_state")) return true;
7483
+ }
7484
+ return false;
7485
+ }
7474
7486
  function legacyImportProblems(cfg, at = "legacyImport") {
7475
7487
  const out = [];
7476
7488
  if (!isObj(cfg)) return [`${at}: must be an object`];
@@ -7497,9 +7509,16 @@ function legacyImportProblems(cfg, at = "legacyImport") {
7497
7509
  if (!LEGACY_IMPORT_FILE_ROOTS.includes(s.root)) {
7498
7510
  out.push(`${p}.root: must be one of ${LEGACY_IMPORT_FILE_ROOTS.join(", ")} (got ${JSON.stringify(s.root)})`);
7499
7511
  }
7512
+ if (s.androidRoot !== void 0) {
7513
+ if (!LEGACY_IMPORT_ANDROID_FILE_ROOTS.includes(s.androidRoot)) {
7514
+ out.push(`${p}.androidRoot: must be one of ${LEGACY_IMPORT_ANDROID_FILE_ROOTS.join(", ")} (got ${JSON.stringify(s.androidRoot)})`);
7515
+ } else if (isSafeRelativePath(s.path) && !mayReadLegacyFiles(s.androidRoot, s.path)) {
7516
+ out.push(`${p}.path: ${JSON.stringify(s.path)} could cover Himi's own storage under ${JSON.stringify(s.androidRoot)} \u2014 an Android root's first folder may not be a himalaya/himi folder, contain a "." (a package name's) or be WebView / pdf-share`);
7517
+ }
7518
+ }
7500
7519
  if (!isSafeRelativePath(s.path)) out.push(`${p}.path: must be a relative path with no "..", "." or empty segment (got ${JSON.stringify(s.path)})`);
7501
7520
  else if (!mayReadLegacyFiles(s.root, s.path)) {
7502
- out.push(`${p}.path: ${JSON.stringify(s.path)} could cover Himi's own storage under ${JSON.stringify(s.root)} \u2014 under "library" name the old app's folder under "Application Support" (e.g. "Application Support/OldApp"); that folder, and a "caches" source's first folder, may not be a himalaya/himi folder, contain a "." (a bundle id's) or be WebKit / Snapshots / fsCachedData`);
7521
+ out.push(`${p}.path: ${JSON.stringify(s.path)} could cover Himi's own storage under ${JSON.stringify(s.root)} \u2014 under "library" name the old app's folder under "Application Support" (e.g. "Application Support/OldApp"); that folder, and a "caches" source's first folder, may not be a himalaya/himi folder, contain a "." (a bundle id's) or be WebKit / Snapshots / fsCachedData; an Android root's first folder may not be a himalaya/himi folder, contain a "." (a package name's) or be WebView / pdf-share`);
7503
7522
  }
7504
7523
  }
7505
7524
  });
package/dist/cli.mjs CHANGED
@@ -15941,6 +15941,7 @@ function webViewOriginAllowed(url, origins) {
15941
15941
  }
15942
15942
  var init_webview_origin = __esm({
15943
15943
  "../../core/ts/src/webview-origin.ts"() {
15944
+ "use strict";
15944
15945
  init_define_HHP_CATALOG();
15945
15946
  }
15946
15947
  });
@@ -32796,7 +32797,6 @@ function shouldRevealError(args) {
32796
32797
  var EMAIL_RE, URL_HOST_RE, INTEGER_RE, NUMBER_RE, AUTHORED_PATTERN_LIMIT, authoredPatterns;
32797
32798
  var init_validation = __esm({
32798
32799
  "../../core/ts/src/validation.ts"() {
32799
- "use strict";
32800
32800
  init_define_HHP_CATALOG();
32801
32801
  EMAIL_RE = /^[A-Za-z0-9._%+-]+@[A-Za-z0-9-]+(\.[A-Za-z0-9-]+)*\.[A-Za-z]{2,}$/;
32802
32802
  URL_HOST_RE = /^[A-Za-z0-9-]+(\.[A-Za-z0-9-]+)*(:[0-9]+)?$/;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wix/himalaya-cli",
3
- "version": "0.1665.0",
3
+ "version": "0.1666.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": [
@@ -79,5 +79,5 @@
79
79
  "artifactId": "himalaya-cli"
80
80
  }
81
81
  },
82
- "falconPackageHash": "0086f659a1a58cab17816357b1ae8422092fe1134cb6cde3c9b04f3d"
82
+ "falconPackageHash": "6486d3e97cf49ddb1e2276d0e2510d568a7a0c7f4307ff4caccb98a1"
83
83
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "$source": "en",
3
- "$generated": "2026-11-11T20:18:46.092Z",
3
+ "$generated": "2026-11-11T22:30:17.102Z",
4
4
  "messages": {
5
5
  "h_0028d743eb44": {
6
6
  "source": "Sale",
@@ -2766,6 +2766,10 @@
2766
2766
  "source": "{n, plural, one {# view} other {# views}}",
2767
2767
  "translation": "{n, plural, one {צפייה אחת} other {# צפיות}}"
2768
2768
  },
2769
+ "h_972017cb7471": {
2770
+ "source": "1 member",
2771
+ "translation": "חבר אחד"
2772
+ },
2769
2773
  "h_19b27b0fd751": {
2770
2774
  "source": "You’re offline — nothing was saved. Try again when you reconnect.",
2771
2775
  "translation": "אין חיבור — דבר לא נשמר. נסו שוב כשהחיבור יחזור."