@wcstack/router 1.20.0 → 1.21.1

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/index.d.ts CHANGED
@@ -13,7 +13,8 @@ interface IWcBindableCommand {
13
13
  }
14
14
  interface IWcBindable {
15
15
  readonly protocol: "wc-bindable";
16
- readonly version: 1;
16
+ /** Integer protocol version. All versions >= 1 are core-compatible. */
17
+ readonly version: number;
17
18
  readonly properties: readonly IWcBindableProperty[];
18
19
  readonly inputs?: readonly IWcBindableInput[];
19
20
  readonly commands?: readonly IWcBindableCommand[];
package/dist/index.esm.js CHANGED
@@ -1531,8 +1531,14 @@ class Router extends HTMLElement {
1531
1531
  { name: "navigateUrl", event: "wcs-router:navigate-url-changed" },
1532
1532
  { name: "path", event: "wcs-router:path-changed" },
1533
1533
  ],
1534
+ // `navigateUrl` は observable output であると同時に settable な書き込み面でもある
1535
+ // (setter が navigate() を起動し、完了後に自分で null へ戻す)。properties にだけ
1536
+ // 宣言すると binding core は output-only とみなし、state → element の書き込みを
1537
+ // 抑止するため、state 経由のプログラム遷移が成立しなくなる。`path` は setter が
1538
+ // navigate せず内部値の反映だけなので、意図的に output のままにしている。
1534
1539
  inputs: [
1535
1540
  { name: "basename", attribute: "basename" },
1541
+ { name: "navigateUrl" },
1536
1542
  ],
1537
1543
  commands: [
1538
1544
  { name: "navigate", async: true },
@@ -2233,7 +2239,7 @@ function bootstrapRouter(config) {
2233
2239
  registerComponents();
2234
2240
  }
2235
2241
 
2236
- var version = "1.20.0";
2242
+ var version = "1.21.1";
2237
2243
  var pkg = {
2238
2244
  version: version};
2239
2245