@trintel/zooy 1.0.12 → 1.0.14

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 (152) hide show
  1. package/dist/chunks/{button-CRxkguK3.js → button-D2VKJsLS.js} +1 -1
  2. package/dist/chunks/{button-By7aRhFi.js → button-pZ-DRK6v.js} +4 -4
  3. package/dist/chunks/{button-skeleton-CZmGLr_c.js → button-skeleton-CDETU1qG.js} +1 -1
  4. package/dist/chunks/{button-skeleton-DlCzuT6h.js → button-skeleton-CtG4NQzT.js} +4 -4
  5. package/dist/chunks/{checkbox-BMZ3_jkv.js → checkbox-CVge6cOk.js} +5 -5
  6. package/dist/chunks/{checkbox-GUazWfM6.js → checkbox-DUGLQnd6.js} +1 -1
  7. package/dist/chunks/{class-map-Bpavh3zd.js → class-map-C8RyF4hT.js} +1 -1
  8. package/dist/chunks/{class-map-CewEiUeS.js → class-map-CLDu36Gc.js} +1 -1
  9. package/dist/chunks/{content-switcher-item-BzWtaEk8.js → content-switcher-item-CA0doXHf.js} +4 -4
  10. package/dist/chunks/{content-switcher-item-DBiwY_5f.js → content-switcher-item-DgEJ6RFq.js} +1 -1
  11. package/dist/chunks/{dropdown-item-C1hnXvNw.js → dropdown-item-C6ff_rA-.js} +6 -6
  12. package/dist/chunks/{dropdown-item-B8fOInIi.js → dropdown-item-DTnshNe4.js} +1 -1
  13. package/dist/chunks/{icon-loader-BX6j0QV9.js → icon-loader-DdCPeV1F.js} +1 -1
  14. package/dist/chunks/{icon-loader-Cv5XYGqj.js → icon-loader-bqbv6v-z.js} +1 -1
  15. package/dist/chunks/{icon-loader-utils-CjBhA13V.js → icon-loader-utils-BWrg3bpN.js} +1 -1
  16. package/dist/chunks/{icon-loader-utils-C_72Dnig.js → icon-loader-utils-wU7uJZWU.js} +1 -1
  17. package/dist/chunks/{if-defined-Zq_Rpirs.js → if-defined-JokaXq_5.js} +1 -1
  18. package/dist/chunks/{if-defined-B-VZmIag.js → if-defined-LYYEqErp.js} +1 -1
  19. package/dist/chunks/{if-non-empty-CaK_h1Vn.js → if-non-empty-B3vx66n4.js} +1 -1
  20. package/dist/chunks/if-non-empty-UE5WDWwQ.js +1 -0
  21. package/dist/chunks/{index-B4O0_8IT.js → index-0kDKmcUn.js} +1 -1
  22. package/dist/chunks/{index-BsVpu7Ej.js → index-2-nMkC0u.js} +1 -1
  23. package/dist/chunks/{index-ChbKcl-Z.js → index-3GQJ_7On.js} +5 -5
  24. package/dist/chunks/{index-C9adbF3V.js → index-7nNy5WEl.js} +1 -1
  25. package/dist/chunks/{index-Bz-sh-N4.js → index-9LzZzz4u.js} +1 -1
  26. package/dist/chunks/{index-BERUsrwS.js → index-B0ZKf4SU.js} +1 -1
  27. package/dist/chunks/{index-DEH3Oujh.js → index-B3rHrWp1.js} +5 -5
  28. package/dist/chunks/{index-BftJaPKS.js → index-B76lqoqT.js} +1 -1
  29. package/dist/chunks/{index-TelAKDy3.js → index-BC4YWTSF.js} +5 -5
  30. package/dist/chunks/{index-DVTOmcgu.js → index-BCzt9Ccn.js} +2 -2
  31. package/dist/chunks/{index-CuZwN_ME.js → index-BDgfSKzL.js} +3 -3
  32. package/dist/chunks/{index-pT9YwIX-.js → index-BGMe0w5_.js} +1 -1
  33. package/dist/chunks/{index-DW24dyDr.js → index-BHJC9GSR.js} +1 -1
  34. package/dist/chunks/{index-m978pani.js → index-BL3nrhct.js} +3 -3
  35. package/dist/chunks/{index-DLt6oTR3.js → index-BL8bOR9n.js} +1 -1
  36. package/dist/chunks/{index-C6YhnCuw.js → index-BNX9EJIE.js} +1 -1
  37. package/dist/chunks/{index-Bx5tyF27.js → index-BRODR18b.js} +3 -3
  38. package/dist/chunks/{index-DQhfyFM4.js → index-BRT0gqo3.js} +4 -4
  39. package/dist/chunks/{index-DqWolj0i.js → index-BWsnXW01.js} +1 -1
  40. package/dist/chunks/{index-CwXwz8dA.js → index-BYHPRyAK.js} +1 -1
  41. package/dist/chunks/{index-XY3TWQ_7.js → index-BYeH-Lx8.js} +1 -1
  42. package/dist/chunks/{index-CDpK5GU3.js → index-Bgmh4Nfq.js} +1 -1
  43. package/dist/chunks/{index-D-20UbuG.js → index-BiW01Ou8.js} +1 -1
  44. package/dist/chunks/{index-DrRc4GOh.js → index-BjPqbngg.js} +5 -5
  45. package/dist/chunks/{index-BfiLUJJ3.js → index-BoCQVLwG.js} +1 -1
  46. package/dist/chunks/{index-BeQ7ZTCw.js → index-BrjlYyR4.js} +5 -5
  47. package/dist/chunks/{index-CyeWQ9VJ.js → index-Bumb78BV.js} +1 -1
  48. package/dist/chunks/{index-D2B2bs5k.js → index-C21uRpcN.js} +2 -2
  49. package/dist/chunks/{index-DxlTsgQ8.js → index-C2valRve.js} +5 -5
  50. package/dist/chunks/{index-LSL0pD4U.js → index-C3wd1Ce9.js} +1 -1
  51. package/dist/chunks/{index-C2Q5YPz1.js → index-C50tGv-j.js} +1 -1
  52. package/dist/chunks/{index-B_Lmpm35.js → index-C5GJatuZ.js} +8 -8
  53. package/dist/chunks/{index-DbT4fJLV.js → index-C5TJ62J9.js} +7 -7
  54. package/dist/chunks/{index-CvnLooVH.js → index-C5dTaeYU.js} +1 -1
  55. package/dist/chunks/{index-BugJTHwJ.js → index-CH2IVG4V.js} +1 -1
  56. package/dist/chunks/{index-D1xYcspc.js → index-CIWTMX9s.js} +1 -1
  57. package/dist/chunks/{index-BXPG0d_k.js → index-CIbCDWFV.js} +2 -2
  58. package/dist/chunks/{index-BoIS4S70.js → index-CPxaESxc.js} +3 -3
  59. package/dist/chunks/{index-C6nmbFvI.js → index-CR49u8S9.js} +1 -1
  60. package/dist/chunks/{index-CVqAaFaO.js → index-CTQAWlOg.js} +5 -5
  61. package/dist/chunks/{index-CCOIDxIB.js → index-CTt8Y8HC.js} +1 -1
  62. package/dist/chunks/{index-1eFOI8oe.js → index-CUhfQp9_.js} +5 -5
  63. package/dist/chunks/{index-Dcs-4ouA.js → index-CaLO9pKf.js} +4 -4
  64. package/dist/chunks/{index-DU7E0qo4.js → index-CiXoGI6W.js} +7 -7
  65. package/dist/chunks/{index-Bv0Kq6vx.js → index-CjEivsuj.js} +1 -1
  66. package/dist/chunks/{index-f2QnoTe2.js → index-Cke1JFeD.js} +3 -3
  67. package/dist/chunks/index-Cm-qH0_A.js +1 -0
  68. package/dist/chunks/{index-D2Z_PWuf.js → index-CmqyRYtd.js} +1 -1
  69. package/dist/chunks/{index-Smwc4F8-.js → index-CmxDyzAj.js} +1 -1
  70. package/dist/chunks/{index-CuuD-d5b.js → index-CnQZDqa3.js} +2 -2
  71. package/dist/chunks/{index-ePccMpcM.js → index-Cpo2cg14.js} +1 -1
  72. package/dist/chunks/index-CqV7rF6Y.js +2 -0
  73. package/dist/chunks/{index-DKOcsQER.js → index-CsJ-eqZ9.js} +1 -1
  74. package/dist/chunks/{index-ScGZvs71.js → index-CvZ0FZoz.js} +10 -10
  75. package/dist/chunks/{index-UDUbB14y.js → index-CyFniodw.js} +1 -1
  76. package/dist/chunks/{index-B7CvW1Hr.js → index-Cz0qsW9k.js} +9 -9
  77. package/dist/chunks/{index-CQY3cMqQ.js → index-D3bm4dv9.js} +1 -1
  78. package/dist/chunks/{index-DFzKxIGc.js → index-D46OGW4a.js} +7 -7
  79. package/dist/chunks/{index-UfSJPzl_.js → index-D5TR0TpO.js} +5 -5
  80. package/dist/chunks/{index-CyHAdAxX.js → index-D5reIinO.js} +7 -7
  81. package/dist/chunks/{index-DW9xYANG.js → index-D79_j0Y6.js} +3 -3
  82. package/dist/chunks/{index-DD3tbFs9.js → index-DDpWWnYg.js} +4 -4
  83. package/dist/chunks/{index-Cit60IYk.js → index-DFku2wwc.js} +1 -1
  84. package/dist/chunks/{index-DayFRhmw.js → index-DIXYEqKa.js} +8 -8
  85. package/dist/chunks/{index-CYLJDFiF.js → index-DJ58_keq.js} +5 -5
  86. package/dist/chunks/{index-Do0fzNBP.js → index-DKKcCZD0.js} +4 -4
  87. package/dist/chunks/{index-C7bz1V4O.js → index-DLd78Rbz.js} +3 -3
  88. package/dist/chunks/{index-Cm3Uqia6.js → index-DRBWg6SP.js} +6 -6
  89. package/dist/chunks/{index-Cdk8HqBZ.js → index-DUN06aMm.js} +1 -1
  90. package/dist/chunks/{index-ByxUjlpc.js → index-DVIeirxu.js} +1 -1
  91. package/dist/chunks/{index-s53NHb2d.js → index-DVJk-q4a.js} +8 -8
  92. package/dist/chunks/{index-BATw38c7.js → index-DYPDRQjH.js} +3 -3
  93. package/dist/chunks/{index-BX1au7I9.js → index-DYSNxsmk.js} +1 -1
  94. package/dist/chunks/{index-DYtqDqPL.js → index-Dc46GN9v.js} +1 -1
  95. package/dist/chunks/{index-DvbDUmZp.js → index-DiMhcmKq.js} +7 -7
  96. package/dist/chunks/{index-1OOPg4-d.js → index-DlaJ2UYi.js} +1 -1
  97. package/dist/chunks/{index-DRYB8Q2c.js → index-DmgEkYDC.js} +1 -1
  98. package/dist/chunks/{index-BpfNVIsW.js → index-DnIZrTPt.js} +1 -1
  99. package/dist/chunks/{index-DScZj-56.js → index-Dnrd-ghp.js} +1 -1
  100. package/dist/chunks/{index-BmMr-B9I.js → index-DoT9doqj.js} +1 -1
  101. package/dist/chunks/{index-BlfAhx-m.js → index-DoiyAuJa.js} +1 -1
  102. package/dist/chunks/{index-BwpbR54Z.js → index-DpqoWgT9.js} +4 -4
  103. package/dist/chunks/{index-o7Ly8WNV.js → index-DraQgvgl.js} +1 -1
  104. package/dist/chunks/{index-B4L1iU-L.js → index-DsCjIWpO.js} +7 -7
  105. package/dist/chunks/{index-DKJCj-0F.js → index-DsShxfRw.js} +1 -1
  106. package/dist/chunks/{index-Bb8PCTuf.js → index-DscKTLkM.js} +1 -1
  107. package/dist/chunks/{index-B-OulI8n.js → index-DvpeF28r.js} +1 -1
  108. package/dist/chunks/{index-C0JKLTdV.js → index-Fd-LYjkR.js} +1 -1
  109. package/dist/chunks/{index-CbKeQETj.js → index-MzshInpG.js} +3 -3
  110. package/dist/chunks/{index-BJ0SBIwX.js → index-OboyKoLD.js} +6 -6
  111. package/dist/chunks/{index-ZmTVduMY.js → index-QtI2aP7P.js} +4 -4
  112. package/dist/chunks/{index-jRYYdv4C.js → index-SS-8a0z5.js} +5 -5
  113. package/dist/chunks/{index-Cy5Gs96d.js → index-Sc6xBZpS.js} +1 -1
  114. package/dist/chunks/{index-DhwMNjJj.js → index-UfmYZ2gl.js} +4 -4
  115. package/dist/chunks/{index-CZi-f4G4.js → index-XCgnYslF.js} +1 -1
  116. package/dist/chunks/{index-DYmmXHAT.js → index-_8VNB8cM.js} +5 -5
  117. package/dist/chunks/{index-BIWPmvxN.js → index-boHTic51.js} +6 -6
  118. package/dist/chunks/{index-DdzuoIsX.js → index-cfYcnLla.js} +6 -6
  119. package/dist/chunks/{index-DRsjyMRL.js → index-cxbnAO6M.js} +4 -4
  120. package/dist/chunks/{index-D5_-tX11.js → index-frG4A1ZV.js} +1 -1
  121. package/dist/chunks/{index-yIVEgAA_.js → index-gXB8HHp-.js} +1 -1
  122. package/dist/chunks/{index-CVH7Hv6v.js → index-skQF78KL.js} +5 -5
  123. package/dist/chunks/{index-CRvczclO.js → index-wCs-JduP.js} +6 -6
  124. package/dist/chunks/{index-CW3NpEbP.js → index-yQy9Zqt6.js} +1 -1
  125. package/dist/chunks/{loading-icon-Dx2ktHir.js → loading-icon-aUR93XFj.js} +1 -1
  126. package/dist/chunks/{loading-icon-Co-jn71c.js → loading-icon-kRHi53Yj.js} +1 -1
  127. package/dist/chunks/{main-BqOledN0.js → main-C7DwFPRv.js} +190 -146
  128. package/dist/chunks/{main-DHy75dVb.js → main-CBogFjAz.js} +4 -4
  129. package/dist/chunks/{property-B0b41oBL.js → property-CsJ7ixLW.js} +1 -1
  130. package/dist/chunks/{property-Dg6D0XVD.js → property-DlFpsdD_.js} +1 -1
  131. package/dist/chunks/{register-BH6NpHIA.js → register-AR8jupzJ.js} +1 -1
  132. package/dist/chunks/{register-h6ZQPYju.js → register-CWsYpCXE.js} +1 -1
  133. package/dist/chunks/{register-DgYdd65A.js → register-CpwdnySd.js} +2 -2
  134. package/dist/chunks/{register-bMHOSpvM.js → register-D3mJ58Cv.js} +1 -1
  135. package/dist/chunks/{search-CdbmNKGt.js → search-Cftx2dVp.js} +6 -6
  136. package/dist/chunks/{search-hgh8azYe.js → search-CuOnNcnw.js} +1 -1
  137. package/dist/chunks/{select-item-bxxL-G6O.js → select-item-BPKT7Wm1.js} +1 -1
  138. package/dist/chunks/{select-item-B7Nispm3.js → select-item-DENN36wG.js} +7 -7
  139. package/dist/chunks/{state-8K5PPQVS.js → state-BUoEDghj.js} +1 -1
  140. package/dist/chunks/{state-C1eYNc3M.js → state-C8_dQr4b.js} +1 -1
  141. package/dist/chunks/{text-input-Cax4HzgZ.js → text-input-CQrOXfMO.js} +5 -5
  142. package/dist/chunks/{text-input-BFGnBN6w.js → text-input-CnlqMvsE.js} +1 -1
  143. package/dist/chunks/{tooltip-content-CF2lm8EZ.js → tooltip-content-CKqz0OvQ.js} +1 -1
  144. package/dist/chunks/{tooltip-content-l8Mg7xk8.js → tooltip-content-CLu411r7.js} +3 -3
  145. package/dist/chunks/{unsafe-html-Hoj8nqTC.js → unsafe-html-BiLL5zaQ.js} +1 -1
  146. package/dist/chunks/{unsafe-html-Dw4MFH2g.js → unsafe-html-CPchn7UI.js} +1 -1
  147. package/dist/zooy.cjs.js +1 -1
  148. package/dist/zooy.es.js +1 -1
  149. package/package.json +1 -1
  150. package/dist/chunks/if-non-empty-Dy-cc4QJ.js +0 -1
  151. package/dist/chunks/index-CNQHUhaQ.js +0 -1
  152. package/dist/chunks/index-DjLSW4tB.js +0 -2
@@ -1,4 +1,4 @@
1
- "use strict";const n=require("./main-DHy75dVb.js"),e=require("./settings-Bgpv8zuU.js");var s=({description:i,small:c})=>{const r=c?"42":"44";return n.x`
1
+ "use strict";const n=require("./main-CBogFjAz.js"),e=require("./settings-Bgpv8zuU.js");var s=({description:i,small:c})=>{const r=c?"42":"44";return n.x`
2
2
  <svg class="${e.prefix}--loading__svg" viewBox="0 0 100 100">
3
3
  ${i?n.x` <title>${i}</title> `:void 0}
4
4
  <circle
@@ -1,4 +1,4 @@
1
- import { x as e } from "./main-BqOledN0.js";
1
+ import { x as e } from "./main-C7DwFPRv.js";
2
2
  import { p as r } from "./settings-jvP7vP60.js";
3
3
  var g = ({ description: c, small: i }) => {
4
4
  const o = i ? "42" : "44";
@@ -1229,16 +1229,16 @@ class UserManager {
1229
1229
  * @param {AbortSignal|undefined} signal
1230
1230
  * @return {Promise}
1231
1231
  */
1232
- async fetchJson(w, D = void 0) {
1233
- const O = new Request(w.toString()), F = genCatchClause(`fetchJson: ${w}`, {}), q = basicGetInit(this.jwt, D);
1232
+ async fetchJson(w, D = void 0, O = void 0) {
1233
+ const F = new Request(w.toString()), q = genCatchClause(`fetchJson: ${w}`, O), W = basicGetInit(this.jwt, D);
1234
1234
  await startSpin();
1235
- let W = {};
1235
+ let Y = {};
1236
1236
  try {
1237
- W = await (await fetch(O, q)).json();
1238
- } catch (Y) {
1239
- return F(Y);
1237
+ Y = await (await fetch(F, W)).json();
1238
+ } catch (G) {
1239
+ return q(G);
1240
1240
  }
1241
- return await stopSpin(), W;
1241
+ return await stopSpin(), Y;
1242
1242
  }
1243
1243
  /**
1244
1244
  * @param {string} uri
@@ -2377,6 +2377,7 @@ const convertElToSplit = (U, w) => (U.classList.add("zoo_split", `zoo_split__${w
2377
2377
  class View extends Evt {
2378
2378
  #t = void 0;
2379
2379
  #e = void 0;
2380
+ #s = {};
2380
2381
  //--[ Static ]--
2381
2382
  /**
2382
2383
  * Returns the view event type code used for dispatching view events.
@@ -2404,6 +2405,12 @@ class View extends Evt {
2404
2405
  get registerViewConstructor() {
2405
2406
  return this.#t;
2406
2407
  }
2408
+ set utils(w) {
2409
+ this.#s = w;
2410
+ }
2411
+ get utils() {
2412
+ return this.#s;
2413
+ }
2407
2414
  set split(w) {
2408
2415
  this.split_ = w, this.listen(this.split_, UiEventType.SPLIT, (D) => {
2409
2416
  const O = D.detail.getValue(), F = D.detail.getData();
@@ -2665,142 +2672,6 @@ class View extends Evt {
2665
2672
  return this.metaData_.has(w);
2666
2673
  }
2667
2674
  }
2668
- class Conductor extends Evt {
2669
- #t = /* @__PURE__ */ new Map();
2670
- #e = null;
2671
- /**
2672
- * @type {!UserManager|undefined}
2673
- * @private
2674
- */
2675
- #s = void 0;
2676
- #r = void 0;
2677
- #n = /* @__PURE__ */ new Map();
2678
- /**
2679
- * Creates a new Conductor instance. Sets up browser history listening
2680
- * and initializes view event handling.
2681
- */
2682
- constructor() {
2683
- super(), this.#n = this.#i(), window.addEventListener("popstate", (w) => {
2684
- w.state !== null && this.navTo(w.state);
2685
- }), this.doOnBeat(() => {
2686
- document.dispatchEvent(new CustomEvent("zoo-tick-60", {
2687
- detail: { timestamp: Date.now() }
2688
- }));
2689
- }, 6e4);
2690
- }
2691
- set split(w) {
2692
- this.#r = w;
2693
- }
2694
- get split() {
2695
- if (!this.#r)
2696
- throw new Error("No SPLIT component available");
2697
- return this.#r;
2698
- }
2699
- /**
2700
- * @param {!UserManager} user
2701
- */
2702
- set user(w) {
2703
- this.#s = w, this.#e && (this.#e.user = this.user);
2704
- }
2705
- /**
2706
- * @return {!UserManager}
2707
- */
2708
- get user() {
2709
- return this.#s || (this.#s = new UserManager()), this.#s;
2710
- }
2711
- /**
2712
- * Initializes the internal view event map with default event handlers.
2713
- * Sets up handlers for common view events like 'switch_view'.
2714
- * @return {!Map<string, !Function>} Map of event names to handler functions
2715
- * @private
2716
- */
2717
- #i() {
2718
- return (/* @__PURE__ */ new Map()).set("switch_view", (w, D) => {
2719
- if (this.#t.has(w.view)) {
2720
- const O = this.#t.get(w.view)(
2721
- w.pk || w.recordId,
2722
- w
2723
- );
2724
- this.switchView(O);
2725
- }
2726
- });
2727
- }
2728
- /**
2729
- * Maps a view event name to a handler function. Allows dynamic registration
2730
- * of custom view event handlers at runtime.
2731
- * @param {string} s The event name to map
2732
- * @param {!Function} func The handler function that receives (eventData, eView)
2733
- */
2734
- mapViewEv(w, D) {
2735
- this.#n.set(w, D);
2736
- }
2737
- /**
2738
- * Registers a view constructor function that can be used to create instances
2739
- * of a specific view type.
2740
- * @param {string} s The view type identifier
2741
- * @param {!Function} f Constructor function that receives (pk, data) and returns a View
2742
- */
2743
- registerViewConstructor(w, D) {
2744
- this.#t.set(w, D);
2745
- }
2746
- /**
2747
- * @param {!CustomEvent} e Event object.
2748
- */
2749
- onViewEvent(w) {
2750
- const D = w.detail.getValue(), O = w.detail.getData(), F = (
2751
- /** @type {Panel} */
2752
- w.target
2753
- );
2754
- this.#n.has(D) ? this.#n.get(D)(O, F) : console.warn("Unhandled VIEW Event:", w, D, O, F);
2755
- }
2756
- /**
2757
- * Make the given view active.
2758
- * @param {!View} view
2759
- */
2760
- setActiveView(w) {
2761
- this.#e && (this.stopListeningTo(this.#e), this.#e.dispose(), this.#e = null), this.#e = w, this.#e.render();
2762
- }
2763
- /**
2764
- * @param {!View} view
2765
- * @returns {!View}
2766
- */
2767
- initView(w) {
2768
- return w.user = this.user, w.split = this.split, w.recordHistory = this.recordHistory.bind(this), w.registerViewConstructor = this.registerViewConstructor.bind(this), this.listen(w, View.viewEventCode(), this.onViewEvent.bind(this)), w;
2769
- }
2770
- //--[ Views Utilities ]--
2771
- /**
2772
- * @param {!View} view The view we want active.
2773
- */
2774
- switchView(w) {
2775
- this.setActiveView(this.initView(w));
2776
- }
2777
- //--[ History and Navigation ]--
2778
- /**
2779
- * Records the given item in browser history. If item.init is true, replaces
2780
- * the current history state. Otherwise, pushes a new history state unless
2781
- * item.history is true.
2782
- * @param {!Object} item The history item containing view state
2783
- */
2784
- recordHistory(w) {
2785
- this.debugMe("HISTORY", w), w.init ? history.replaceState(w, "", document.location.href) : w.history || history.pushState(w, "", null);
2786
- }
2787
- /**
2788
- * Navigates to a specific view based on the history item. Attempts to use
2789
- * the active view's switchViewMap first, falling back to registered view
2790
- * constructors if needed.
2791
- * @param {!Object} item History item containing {view, pk, ...} properties
2792
- */
2793
- navTo = (w) => {
2794
- w.history = !0;
2795
- const D = w.view, O = this.#e;
2796
- if (O.switchViewMap_.has(D))
2797
- this.debugMe("NAV:VIEW:MAP", w), O.switchViewMap_.get(D)(w);
2798
- else if (this.#t.has(D)) {
2799
- const F = this.#t.get(D)(w.pk, w);
2800
- this.debugMe("NAV:NEW:VIEW", w), this.switchView(F);
2801
- }
2802
- };
2803
- }
2804
2675
  function _isPlaceholder(U) {
2805
2676
  return U != null && typeof U == "object" && U["@@functional/placeholder"] === !0;
2806
2677
  }
@@ -3134,6 +3005,19 @@ var liftN = /* @__PURE__ */ _curry2(function U(w, D) {
3134
3005
  }), has = /* @__PURE__ */ _curry2(function U(w, D) {
3135
3006
  return hasPath([w], D);
3136
3007
  });
3008
+ function _objectAssign(U) {
3009
+ if (U == null)
3010
+ throw new TypeError("Cannot convert undefined or null to object");
3011
+ for (var w = Object(U), D = 1, O = arguments.length; D < O; ) {
3012
+ var F = arguments[D];
3013
+ if (F != null)
3014
+ for (var q in F)
3015
+ _has(q, F) && (w[q] = F[q]);
3016
+ D += 1;
3017
+ }
3018
+ return w;
3019
+ }
3020
+ const _objectAssign$1 = typeof Object.assign == "function" ? Object.assign : _objectAssign;
3137
3021
  function _path(U, w) {
3138
3022
  for (var D = w, O = 0; O < U.length; O += 1) {
3139
3023
  if (D == null)
@@ -3143,7 +3027,167 @@ function _path(U, w) {
3143
3027
  }
3144
3028
  return D;
3145
3029
  }
3146
- var path = /* @__PURE__ */ _curry2(_path);
3030
+ var mergeRight = /* @__PURE__ */ _curry2(function U(w, D) {
3031
+ return _objectAssign$1({}, w, D);
3032
+ }), path = /* @__PURE__ */ _curry2(_path);
3033
+ class Conductor extends Evt {
3034
+ #t = /* @__PURE__ */ new Map();
3035
+ #e = null;
3036
+ /**
3037
+ * @type {!UserManager|undefined}
3038
+ * @private
3039
+ */
3040
+ #s = void 0;
3041
+ #r = void 0;
3042
+ #n = /* @__PURE__ */ new Map();
3043
+ /**
3044
+ * This is a userspace map where consuming applications can register shared functions
3045
+ * that are available to all views and panels.
3046
+ * @type {{}}
3047
+ */
3048
+ #i = {};
3049
+ /**
3050
+ * Creates a new Conductor instance. Sets up browser history listening
3051
+ * and initializes view event handling.
3052
+ */
3053
+ constructor() {
3054
+ super(), this.#n = this.#o(), window.addEventListener("popstate", (w) => {
3055
+ w.state !== null && this.navTo(w.state);
3056
+ }), this.doOnBeat(() => {
3057
+ document.dispatchEvent(new CustomEvent("zoo-tick-60", {
3058
+ detail: { timestamp: Date.now() }
3059
+ }));
3060
+ }, 6e4);
3061
+ }
3062
+ set split(w) {
3063
+ this.#r = w;
3064
+ }
3065
+ get split() {
3066
+ if (!this.#r)
3067
+ throw new Error("No SPLIT component available");
3068
+ return this.#r;
3069
+ }
3070
+ /**
3071
+ * @param {!UserManager} user
3072
+ */
3073
+ set user(w) {
3074
+ this.#s = w, this.#e && (this.#e.user = this.user);
3075
+ }
3076
+ /**
3077
+ * @return {!UserManager}
3078
+ */
3079
+ get user() {
3080
+ return this.#s || (this.#s = new UserManager()), this.#s;
3081
+ }
3082
+ get utils() {
3083
+ return this.#i;
3084
+ }
3085
+ /**
3086
+ * Register utility functions that will be made available to all views.
3087
+ * @Example:
3088
+ * const myUtil = () => {console.log("hello")};
3089
+ * c.registerUtil({myUtil});
3090
+ *
3091
+ * // Elsewhere in the panel or view code:
3092
+ * view.utils.myUtil(); // Prints "hello"
3093
+ * @param obj
3094
+ */
3095
+ registerUtil(w) {
3096
+ this.#i = mergeRight(this.#i, w);
3097
+ }
3098
+ /**
3099
+ * Initializes the internal view event map with default event handlers.
3100
+ * Sets up handlers for common view events like 'switch_view'.
3101
+ * @return {!Map<string, !Function>} Map of event names to handler functions
3102
+ * @private
3103
+ */
3104
+ #o() {
3105
+ return (/* @__PURE__ */ new Map()).set("switch_view", (w, D) => {
3106
+ if (this.#t.has(w.view)) {
3107
+ const O = this.#t.get(w.view)(
3108
+ w.pk || w.recordId,
3109
+ w
3110
+ );
3111
+ this.switchView(O);
3112
+ }
3113
+ });
3114
+ }
3115
+ /**
3116
+ * Maps a view event name to a handler function. Allows dynamic registration
3117
+ * of custom view event handlers at runtime.
3118
+ * @param {string} s The event name to map
3119
+ * @param {!Function} func The handler function that receives (eventData, eView)
3120
+ */
3121
+ mapViewEv(w, D) {
3122
+ this.#n.set(w, D);
3123
+ }
3124
+ /**
3125
+ * Registers a view constructor function that can be used to create instances
3126
+ * of a specific view type.
3127
+ * @param {string} s The view type identifier
3128
+ * @param {!Function} f Constructor function that receives (pk, data) and returns a View
3129
+ */
3130
+ registerViewConstructor(w, D) {
3131
+ this.#t.set(w, D);
3132
+ }
3133
+ /**
3134
+ * @param {!CustomEvent} e Event object.
3135
+ */
3136
+ onViewEvent(w) {
3137
+ const D = w.detail.getValue(), O = w.detail.getData(), F = (
3138
+ /** @type {Panel} */
3139
+ w.target
3140
+ );
3141
+ this.#n.has(D) ? this.#n.get(D)(O, F) : console.warn("Unhandled VIEW Event:", w, D, O, F);
3142
+ }
3143
+ /**
3144
+ * Make the given view active.
3145
+ * @param {!View} view
3146
+ */
3147
+ setActiveView(w) {
3148
+ this.#e && (this.stopListeningTo(this.#e), this.#e.dispose(), this.#e = null), this.#e = w, this.#e.render();
3149
+ }
3150
+ /**
3151
+ * @param {!View} view
3152
+ * @returns {!View}
3153
+ */
3154
+ initView(w) {
3155
+ return w.user = this.user, w.split = this.split, w.utils = this.utils, w.recordHistory = this.recordHistory.bind(this), w.registerViewConstructor = this.registerViewConstructor.bind(this), this.listen(w, View.viewEventCode(), this.onViewEvent.bind(this)), w;
3156
+ }
3157
+ //--[ Views Utilities ]--
3158
+ /**
3159
+ * @param {!View} view The view we want active.
3160
+ */
3161
+ switchView(w) {
3162
+ this.setActiveView(this.initView(w));
3163
+ }
3164
+ //--[ History and Navigation ]--
3165
+ /**
3166
+ * Records the given item in browser history. If item.init is true, replaces
3167
+ * the current history state. Otherwise, pushes a new history state unless
3168
+ * item.history is true.
3169
+ * @param {!Object} item The history item containing view state
3170
+ */
3171
+ recordHistory(w) {
3172
+ this.debugMe("HISTORY", w), w.init ? history.replaceState(w, "", document.location.href) : w.history || history.pushState(w, "", null);
3173
+ }
3174
+ /**
3175
+ * Navigates to a specific view based on the history item. Attempts to use
3176
+ * the active view's switchViewMap first, falling back to registered view
3177
+ * constructors if needed.
3178
+ * @param {!Object} item History item containing {view, pk, ...} properties
3179
+ */
3180
+ navTo = (w) => {
3181
+ w.history = !0;
3182
+ const D = w.view, O = this.#e;
3183
+ if (O.switchViewMap_.has(D))
3184
+ this.debugMe("NAV:VIEW:MAP", w), O.switchViewMap_.get(D)(w);
3185
+ else if (this.#t.has(D)) {
3186
+ const F = this.#t.get(D)(w.pk, w);
3187
+ this.debugMe("NAV:NEW:VIEW", w), this.switchView(F);
3188
+ }
3189
+ };
3190
+ }
3147
3191
  const DEFAULT_FORMATTERS = {
3148
3192
  /**
3149
3193
  * Format as JSON (useful for debugging)
@@ -4140,11 +4184,11 @@ const zoo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty(
4140
4184
  getSemanticAttributes
4141
4185
  }, Symbol.toStringTag, { value: "Module" }));
4142
4186
  async function registerCarbonLibrary(U = {}) {
4143
- const { registerCarbonLibrary: w } = await import("./register-DgYdd65A.js");
4187
+ const { registerCarbonLibrary: w } = await import("./register-CpwdnySd.js");
4144
4188
  return w(U);
4145
4189
  }
4146
4190
  async function registerMdcLibrary() {
4147
- const { registerMdcLibrary: U } = await import("./register-bMHOSpvM.js");
4191
+ const { registerMdcLibrary: U } = await import("./register-D3mJ58Cv.js");
4148
4192
  return U();
4149
4193
  }
4150
4194
  const zooy = {