@wix/himalaya-cli 0.1460.0 → 0.1461.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/cli.mjs +12 -0
- package/guides/hhp.md +3 -1
- package/package.json +2 -2
package/dist/cli.mjs
CHANGED
|
@@ -7310,6 +7310,18 @@ function compileV2(html, profile, options) {
|
|
|
7310
7310
|
mods[name2] = coerce(raw, field2);
|
|
7311
7311
|
structured(el2, mods[name2]);
|
|
7312
7312
|
}
|
|
7313
|
+
if (name2 === "onMeasure" && mods.onMeasure && typeof mods.onMeasure === "object") {
|
|
7314
|
+
for (const [key3, value] of Object.entries(mods.onMeasure)) {
|
|
7315
|
+
if (!key3.endsWith("Path") || typeof value !== "string") continue;
|
|
7316
|
+
if (value.startsWith("$service:") || info4?.paths.has(statePath(value))) {
|
|
7317
|
+
const axis = key3.replace(/Path$/, "");
|
|
7318
|
+
const taken = (k2) => !!info4?.paths.has(statePath(k2));
|
|
7319
|
+
let suggestion = taken(axis) ? `measured${axis[0].toUpperCase()}${axis.slice(1)}` : axis;
|
|
7320
|
+
for (let n2 = 2; taken(suggestion); n2++) suggestion = `measured${axis[0].toUpperCase()}${axis.slice(1)}${n2}`;
|
|
7321
|
+
error(el2, "HHP-MEASURE-TARGET", `onMeasure.${key3} ${value} names controller state; measurements publish only to the renderer's measure store.`, `Use a store key (e.g. "${suggestion}") and read it back with a $measure:<key> modifier path.`);
|
|
7322
|
+
}
|
|
7323
|
+
}
|
|
7324
|
+
}
|
|
7313
7325
|
continue;
|
|
7314
7326
|
}
|
|
7315
7327
|
const name = nativeField(attr3.startsWith("data-prop-") ? attr3.slice(10) : attr3);
|
package/guides/hhp.md
CHANGED
|
@@ -86,7 +86,9 @@ use a child `script type="application/himalaya-props"` containing JSON.
|
|
|
86
86
|
ordinary-control aliases. Explicit modifiers use `data-mod-*` or `himi-mod-*`.
|
|
87
87
|
A `…-path` modifier (`data-mod-hidden-path="full"`, `data-mod-background-color-path`)
|
|
88
88
|
names controller state exactly like `bind:*`, or `$item.<field>` in a row; an unknown
|
|
89
|
-
path is a lint error. `onMeasure` keys name the renderer's measure store instead
|
|
89
|
+
path is a lint error. `onMeasure` keys name the renderer's measure store instead
|
|
90
|
+
(read back with a `$measure:<key>` path); no renderer writes a measurement into worker
|
|
91
|
+
state, so an `onMeasure` key that names controller state is an `HHP-MEASURE-TARGET` error.
|
|
90
92
|
`style` and `title` are HTML globals: `style` is always CSS, so a native `style`
|
|
91
93
|
variant uses `variant="primary"`; `title="…"` sets a component's `title` field. CSS
|
|
92
94
|
`font` applies only to text components (Text, Label, Marquee). The profile's
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wix/himalaya-cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.1461.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": [
|
|
@@ -71,5 +71,5 @@
|
|
|
71
71
|
"artifactId": "himalaya-cli"
|
|
72
72
|
}
|
|
73
73
|
},
|
|
74
|
-
"falconPackageHash": "
|
|
74
|
+
"falconPackageHash": "383d7c17e59533d072b72cd7a7d5e46ef59606d5af81f0fc19cf1c52"
|
|
75
75
|
}
|